.page-clientes {
  --case-pad: clamp(2.4rem, 7vw, 6.5rem);
}

.clients-open {
  min-height: calc(100svh - var(--nav-h) - var(--frame) * 2 - 3.5rem);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: clamp(3rem, 8vw, 6rem) var(--container) clamp(2.2rem, 4vw, 3.2rem);
  border-bottom: 1px solid var(--border);
  position: relative;
}

.clients-open::after {
  content: "12";
  position: absolute;
  right: var(--container);
  top: 18%;
  font-family: var(--font-serif);
  font-size: clamp(7rem, 22vw, 18rem);
  line-height: 0.8;
  color: color-mix(in srgb, var(--ink) 7%, transparent);
  pointer-events: none;
  letter-spacing: -0.06em;
}

.clients-open h1 {
  font-size: clamp(3.2rem, 9vw, 7.4rem);
  max-width: 8ch;
  margin: 0 0 1.4rem;
  position: relative;
}

.clients-open-line {
  margin: 0;
  max-width: 28rem;
  font-size: clamp(1.05rem, 1.4vw, 1.25rem);
  line-height: 1.55;
  color: var(--muted);
  text-wrap: pretty;
}

.clients-roster {
  position: sticky;
  top: var(--page-header-clear);
  z-index: var(--z-sticky);
  display: flex;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  scrollbar-width: none;
}

.clients-roster::-webkit-scrollbar { display: none; }

.clients-roster a {
  flex: 0 0 auto;
  padding: 0.85rem 1.35rem;
  font-family: var(--font-serif);
  font-size: 1.02rem;
  line-height: 1.2;
  white-space: nowrap;
  border-right: 1px solid var(--border);
  color: var(--ink);
  transition: background 0.35s var(--ease), color 0.35s var(--ease);
}

.clients-roster a:first-child { padding-left: var(--container); }

.clients-roster a:hover,
.clients-roster a.is-active,
.clients-roster a:focus-visible {
  background: var(--ink);
  color: var(--bg);
  outline: none;
}

.case {
  position: relative;
  min-height: calc(100svh - var(--page-header-clear) - 3.2rem);
  display: grid;
  align-items: end;
  overflow: hidden;
  border-bottom: 1px solid var(--border);
  scroll-margin-top: calc(var(--page-header-clear) + 3.2rem);
}

.case-ghost {
  position: absolute;
  left: -0.06em;
  bottom: -0.28em;
  margin: 0;
  font-family: var(--font-serif);
  font-size: clamp(6rem, 22vw, 16rem);
  line-height: 0.8;
  letter-spacing: -0.05em;
  white-space: nowrap;
  pointer-events: none;
  user-select: none;
  color: color-mix(in srgb, var(--ink) 8%, transparent);
}

.case--ink .case-ghost,
.case--plum .case-ghost {
  color: color-mix(in srgb, var(--bg) 10%, transparent);
}

.case-frame {
  position: relative;
  z-index: 1;
  width: min(38rem, 100%);
  padding: var(--case-pad) var(--container);
}

.case-frame--end {
  margin-left: auto;
  text-align: right;
}

.case h2 {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(2rem, 4.4vw, 3.6rem);
  line-height: 1.05;
  letter-spacing: -0.03em;
  margin: 0 0 0.55rem;
  text-wrap: balance;
}

.case-aside {
  margin: 0 0 0.7rem;
  font-family: var(--font-serif);
  font-style: italic;
  font-size: clamp(1.05rem, 1.6vw, 1.35rem);
  color: var(--muted);
}

.case-field {
  margin: 0 0 1.35rem;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}

.case p:not(.case-ghost):not(.case-field):not(.case-aside) {
  margin: 0 0 0.85rem;
  font-size: clamp(1.02rem, 1.25vw, 1.18rem);
  line-height: 1.7;
  color: var(--muted);
  text-wrap: pretty;
}

.case p:not(.case-ghost):not(.case-field):not(.case-aside):last-child {
  margin-bottom: 0;
}

.case--paper {
  background: var(--bg);
}

.case--surface {
  background: var(--surface);
}

.case--ink {
  background: var(--ink);
  color: var(--bg);
  border-bottom-color: color-mix(in srgb, var(--bg) 12%, transparent);
}

.case--ink .case-field,
.case--ink .case-aside,
.case--ink p:not(.case-ghost):not(.case-field):not(.case-aside) {
  color: color-mix(in srgb, var(--bg) 62%, transparent);
}

.case--plum {
  background: var(--accent);
  color: var(--bg);
  border-bottom-color: color-mix(in srgb, var(--bg) 16%, transparent);
}

.case--plum .case-field,
.case--plum .case-aside,
.case--plum p:not(.case-ghost):not(.case-field):not(.case-aside) {
  color: color-mix(in srgb, var(--bg) 72%, transparent);
}

.clients-close {
  padding: clamp(5rem, 12vw, 9rem) var(--container);
  background: var(--bg);
}

.clients-close h2 {
  font-size: clamp(2.6rem, 6vw, 5rem);
  max-width: 10ch;
  margin: 0 0 1.2rem;
}

.clients-close p {
  margin: 0 0 2rem;
  max-width: 28rem;
  color: var(--muted);
  font-size: clamp(1.05rem, 1.4vw, 1.25rem);
  line-height: 1.6;
}

@media (max-width: 900px) {
  .clients-open {
    min-height: auto;
    padding-top: 5.5rem;
  }

  .clients-open::after { display: none; }

  .clients-roster a {
    font-size: 0.95rem;
    padding: 0.8rem 1.1rem;
  }

  .case {
    min-height: auto;
    padding-top: 4rem;
  }

  .case-ghost {
    font-size: clamp(4.5rem, 28vw, 8rem);
    bottom: auto;
    top: 0.4rem;
  }

  .case-frame,
  .case-frame--end {
    margin: 0;
    text-align: left;
    width: 100%;
  }

  .clients-open::after { top: 8%; }
}

@media (prefers-reduced-motion: reduce) {
  .clients-roster a { transition: none; }
}
