/* =========================================================================
   Bengoa Reyes & Asociados — Sistema visual
   Paleta basada en el logo: sage charcoal + champagne gold
   ========================================================================= */

:root {
  /* ── Palette (sage classic, default) ── */
  --bg:        #f6f3ec;
  --bg-2:      #efeae0;
  --surface:   #ffffff;
  --ink:       #1b2320;
  --ink-2:     #4b554f;
  --ink-3:     #828c85;
  --line:      rgba(27, 35, 32, 0.10);
  --line-2:    rgba(27, 35, 32, 0.18);
  --sage:      #2e3833;
  --sage-deep: #1a211e;
  --gold:      #b9a36f;
  --gold-deep: #957f4d;
  --gold-soft: #e6d9b8;

  --on-sage:   #f3eede;
  --on-sage-2: rgba(243, 238, 222, 0.62);

  /* Typography */
  --f-serif: "Cormorant Garamond", "Cormorant", "Times New Roman", Georgia, serif;
  --f-sans:  "Inter", "Söhne", system-ui, -apple-system, "Segoe UI", sans-serif;
  --f-mono:  "JetBrains Mono", ui-monospace, "SF Mono", monospace;

  /* Scale */
  --max-w: 1320px;
  --gutter: clamp(20px, 4vw, 56px);
  --section-y: clamp(80px, 9vw, 140px);

  --r-sm: 4px;
  --r-md: 8px;
  --r-lg: 14px;
}

/* ── Modes ── */
[data-mode="dark"] {
  --bg:        #11161a;
  --bg-2:      #161d20;
  --surface:   #1c2428;
  --ink:       #ece6d5;
  --ink-2:     #aab2af;
  --ink-3:     #6c7670;
  --line:      rgba(236, 230, 213, 0.10);
  --line-2:    rgba(236, 230, 213, 0.20);
  --sage:      #d4cfb8;        /* invert role so sage acts as light foreground */
  --sage-deep: #ece6d5;
  --gold:      #d8c084;
  --gold-deep: #b9a36f;
  --gold-soft: #3d3724;
  --on-sage:   #11161a;
  --on-sage-2: rgba(17, 22, 26, 0.65);
}

[data-mode="sepia"] {
  --bg:        #efe6d2;
  --bg-2:      #e6dabf;
  --surface:   #f6efde;
  --ink:       #2a221a;
  --ink-2:     #5c4f3d;
  --ink-3:     #897659;
  --line:      rgba(60, 40, 20, 0.13);
  --line-2:    rgba(60, 40, 20, 0.22);
  --sage:      #3a4a3b;
  --sage-deep: #243023;
  --gold:      #8c6f3c;
  --gold-deep: #6e5527;
  --gold-soft: #d8c69a;
  --on-sage:   #efe6d2;
  --on-sage-2: rgba(239, 230, 210, 0.65);
}

/* ── Alt palettes (toggle via data-palette) ── */
[data-palette="forest"] {
  --sage:      #1f2d27;
  --sage-deep: #0e1612;
  --gold:      #c9b27a;
  --gold-deep: #a78d50;
}
[data-palette="stone"] {
  --sage:      #3a3d39;
  --sage-deep: #232524;
  --gold:      #ad9870;
  --gold-deep: #8a7855;
  --gold-soft: #e8dec2;
}
[data-palette="onyx"] {
  --sage:      #0e1210;
  --sage-deep: #000000;
  --gold:      #c9a45a;
  --gold-deep: #a07f3c;
}

/* =========================================================================
   Section tinting — derived from --bg so they shift with mode + palette.
   Use these classes on <section> to vary the visual rhythm.
   ========================================================================= */
:root {
  --sect-base: var(--bg);
  --sect-warm: color-mix(in oklab, var(--bg) 86%, var(--gold) 14%);
  --sect-cool: color-mix(in oklab, var(--bg) 90%, var(--sage) 10%);
  --sect-deep: var(--bg-2);
}
[data-mode="dark"] {
  --sect-base: var(--bg);
  --sect-warm: color-mix(in oklab, var(--bg) 80%, var(--gold) 12%);
  --sect-cool: color-mix(in oklab, var(--bg) 80%, var(--sage-deep) 20%);
  --sect-deep: var(--bg-2);
}
[data-mode="sepia"] {
  --sect-base: var(--bg);
  --sect-warm: color-mix(in oklab, var(--bg) 80%, var(--gold) 18%);
  --sect-cool: color-mix(in oklab, var(--bg) 86%, var(--sage) 14%);
  --sect-deep: var(--bg-2);
}
.sect-warm { background: var(--sect-warm); }
.sect-cool { background: var(--sect-cool); }
.sect-deep { background: var(--sect-deep); }
.sect-base { background: var(--sect-base); }

/* Soft top hairline so the change of tint reads as intentional */
.sect-warm + .sect-cool::before,
.sect-cool + .sect-warm::before,
.sect-warm + .sect-deep::before,
.sect-deep + .sect-warm::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 1px;
  background: var(--line);
  pointer-events: none;
}

/* =========================================================================
   Reset & base
   ========================================================================= */
*,*::before,*::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--f-sans);
  font-size: 16px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-feature-settings: "ss01", "cv11";
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; }

/* =========================================================================
   Typography
   ========================================================================= */
.serif { font-family: var(--f-serif); font-weight: 500; }
.display {
  font-family: var(--f-serif);
  font-weight: 400;
  line-height: 1.02;
  letter-spacing: -0.015em;
  font-feature-settings: "ss01", "lnum";
}
.display em {
  font-style: italic;
  color: var(--gold-deep);
  font-weight: 400;
}
.eyebrow {
  font-family: var(--f-sans);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-2);
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.eyebrow::before {
  content: "";
  width: 24px;
  height: 1px;
  background: var(--gold);
}
.eyebrow.no-rule::before { display: none; }
.eyebrow.eyebrow-light { color: var(--on-sage-2); }
.eyebrow.eyebrow-light::before { background: var(--gold); }

.h-meta {
  font-family: var(--f-sans);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-3);
}

.lead {
  font-family: var(--f-serif);
  font-weight: 400;
  font-size: clamp(20px, 2.1vw, 28px);
  line-height: 1.4;
  color: var(--ink);
  letter-spacing: -0.005em;
}

.muted { color: var(--ink-2); }
.muted-3 { color: var(--ink-3); }

/* =========================================================================
   Layout
   ========================================================================= */
.wrap {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 var(--gutter);
  width: 100%;
}
section { position: relative; }
.section { padding: var(--section-y) 0; }
.section-tight { padding: calc(var(--section-y) * 0.65) 0; }

.rule { height: 1px; background: var(--line); width: 100%; }
.rule-strong { background: var(--line-2); }

/* index marker — "S/01" */
.index-tag {
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.04em;
  color: var(--ink-3);
}

/* =========================================================================
   Buttons
   ========================================================================= */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  height: 48px;
  padding: 0 22px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-family: var(--f-sans);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.01em;
  cursor: pointer;
  transition: all .25s cubic-bezier(.2,.6,.2,1);
  white-space: nowrap;
}
.btn .arr {
  width: 16px; height: 16px;
  display: inline-flex; align-items: center; justify-content: center;
  transition: transform .25s ease;
}
.btn:hover .arr { transform: translateX(3px); }

.btn-primary {
  background: var(--sage);
  color: var(--on-sage);
  border-color: var(--sage);
}
.btn-primary:hover {
  background: var(--sage-deep);
  border-color: var(--gold);
  box-shadow: 0 0 0 4px color-mix(in oklab, var(--gold) 18%, transparent);
}
.btn-ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--line-2);
}
.btn-ghost:hover {
  border-color: var(--gold);
  color: var(--gold-deep);
}
.btn-gold {
  background: var(--gold);
  color: var(--sage-deep);
  border-color: var(--gold);
}
.btn-gold:hover { background: var(--gold-deep); border-color: var(--gold-deep); color: var(--on-sage); }

[data-mode="dark"] .btn-primary { background: var(--gold); color: var(--sage-deep); border-color: var(--gold); }
[data-mode="dark"] .btn-primary:hover { background: var(--gold-deep); border-color: var(--gold-deep); }

/* =========================================================================
   Nav
   ========================================================================= */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  transition: background .3s ease, border-color .3s ease, backdrop-filter .3s ease;
  border-bottom: 1px solid transparent;
}
.nav.is-scrolled {
  background: color-mix(in oklab, var(--bg) 88%, transparent);
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-bottom-color: var(--line);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 78px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: var(--f-serif);
  font-size: 20px;
  letter-spacing: -0.01em;
  color: var(--ink);
}
.brand-mark {
  width: 34px; height: 34px;
  display: inline-flex; align-items: center; justify-content: center;
}
.brand-mark svg { width: 100%; height: 100%; }

/* Image-based isotipo: swap variant per mode */
.brand-mark-img {
  position: relative;
  display: inline-flex;
  flex-shrink: 0;
}
.brand-mark-img img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
}
.brand-mark-img .bm-dark  { opacity: 0; }
[data-mode="dark"] .brand-mark-img .bm-light { opacity: 0; }
[data-mode="dark"] .brand-mark-img .bm-dark  { opacity: 1; }
.brand-word b { font-weight: 500; }
.brand-word span { color: var(--gold-deep); font-weight: 500; }
.brand-word small {
  display: block;
  font-family: var(--f-sans);
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-top: -2px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
}
.nav-links a {
  font-size: 13px;
  color: var(--ink-2);
  padding: 8px 14px;
  border-radius: 999px;
  transition: color .2s, background .2s;
}
.nav-links a:hover {
  color: var(--gold-deep);
}
.nav-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.nav-burger {
  display: none;
  width: 40px; height: 40px;
  border: 1px solid var(--line-2);
  border-radius: 999px;
  background: transparent;
  align-items: center; justify-content: center;
  cursor: pointer;
}

/* nav: protect brand from wrapping & give it room */
.brand { flex-shrink: 0; }
.brand-word { white-space: nowrap; }

@media (max-width: 1100px) {
  .brand-word small { display: none; }
}
@media (max-width: 1000px) {
  .nav-links a { padding: 8px 10px; font-size: 12.5px; }
}
@media (max-width: 960px) {
  .nav-links, .nav-cta { display: none; }
  .nav-burger { display: inline-flex; }
}

/* mobile drawer */
.drawer {
  position: fixed; inset: 0;
  background: var(--bg);
  z-index: 60;
  padding: 100px var(--gutter) 40px;
  display: flex; flex-direction: column;
  gap: 4px;
  overflow: hidden;
  transform: translateY(-101%);
  transition: transform .35s cubic-bezier(.2,.7,.2,1), visibility 0s linear .35s;
  visibility: hidden;
  pointer-events: none;
}
.drawer.open {
  transform: translateY(0);
  visibility: visible;
  pointer-events: auto;
  transition: transform .35s cubic-bezier(.2,.7,.2,1), visibility 0s linear 0s;
}
.drawer a {
  font-family: var(--f-serif);
  font-size: 36px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}
.drawer-close {
  position: absolute; top: 22px; right: var(--gutter);
  width: 40px; height: 40px;
  border: 1px solid var(--line-2);
  border-radius: 999px;
  background: transparent;
  cursor: pointer;
}

/* =========================================================================
   Hero
   ========================================================================= */
.hero {
  padding: 140px 0 60px;
  position: relative;
  overflow: hidden;
}
.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr);
  gap: clamp(28px, 5vw, 80px);
  align-items: end;
}
.hero h1.display {
  font-size: clamp(48px, 7.2vw, 104px);
  margin: 24px 0 0;
}
.hero-sub {
  margin-top: 28px;
  font-size: clamp(16px, 1.3vw, 19px);
  line-height: 1.55;
  color: var(--ink-2);
  max-width: 56ch;
}
.hero-ctas {
  display: flex;
  gap: 12px;
  margin-top: 40px;
  flex-wrap: wrap;
}

.hero-meta {
  border-top: 1px solid var(--line-2);
  padding-top: 18px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px 32px;
  align-self: end;
  margin-bottom: 8px;
}
.hero-meta dt {
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 6px;
  font-weight: 500;
}
.hero-meta dd {
  margin: 0;
  font-family: var(--f-serif);
  font-size: 18px;
  line-height: 1.25;
  color: var(--ink);
}

.hero-strip {
  margin-top: clamp(60px, 7vw, 100px);
  padding: 22px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  display: flex; align-items: center; gap: 40px;
  overflow: hidden;
}
.hero-strip-label {
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-3);
  white-space: nowrap;
  flex-shrink: 0;
}
.hero-strip-items {
  display: flex; gap: 48px;
  font-family: var(--f-serif);
  font-size: 18px;
  color: var(--ink-2);
  flex-wrap: wrap;
}
.hero-strip-items span {
  display: inline-flex; align-items: center; gap: 14px;
}
.hero-strip-items span::after {
  content: "";
  width: 4px; height: 4px;
  border-radius: 50%;
  background: var(--gold);
  margin-left: 14px;
}
.hero-strip-items span:last-child::after { display: none; }

/* Hero backdrop ornament — soft echo of the isotipo */
.hero-orn {
  position: absolute;
  right: -8%;
  top: 8%;
  width: 56%;
  height: 78%;
  pointer-events: none;
  opacity: 0.07;
  z-index: 0;
}
.hero-orn-img,
.authority-orn .hero-orn-img {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
}
.hero-orn-img img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center right;
}
.hero-orn-img .bm-dark { opacity: 0; }
[data-mode="dark"] .hero-orn-img .bm-light { opacity: 0; }
[data-mode="dark"] .hero-orn-img .bm-dark  { opacity: 1; }
[data-mode="dark"] .hero-orn { opacity: 0.10; }

/* fine top-of-page gridlines */
.gridlines {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(to right, var(--line) 1px, transparent 1px);
  background-size: calc(100%/6) 100%;
  opacity: 0.5;
  mask-image: linear-gradient(to bottom, rgba(0,0,0,0.7), transparent 65%);
}

@media (max-width: 900px) {
  .hero { padding-top: 110px; }
  .hero-grid { grid-template-columns: 1fr; }
  .hero-meta { border-top: 1px solid var(--line); padding-top: 32px; margin-top: 16px; }
}

/* =========================================================================
   About
   ========================================================================= */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1.6fr;
  gap: clamp(28px, 5vw, 80px);
}
.about-grid h2.display {
  font-size: clamp(36px, 4.4vw, 64px);
  margin: 16px 0 0;
}
.about-copy p {
  font-size: 17px;
  line-height: 1.7;
  color: var(--ink-2);
  max-width: 60ch;
  margin: 0 0 18px;
}
.about-copy p:first-child {
  font-family: var(--f-serif);
  font-size: clamp(22px, 2.2vw, 28px);
  line-height: 1.4;
  color: var(--ink);
}

.about-stats {
  margin-top: 56px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--line-2);
  border-bottom: 1px solid var(--line);
}
.about-stat {
  padding: 28px 0;
  border-right: 1px solid var(--line);
}
.about-stat:last-child { border-right: 0; }
.about-stat-k {
  font-family: var(--f-serif);
  font-size: clamp(40px, 4.4vw, 56px);
  line-height: 1;
  color: var(--ink);
  letter-spacing: -0.02em;
}
.about-stat-k sup {
  font-size: 0.45em;
  color: var(--gold-deep);
  vertical-align: top;
  margin-left: 2px;
}
.about-stat-v {
  margin-top: 12px;
  font-size: 13px;
  color: var(--ink-2);
  max-width: 22ch;
}

@media (max-width: 900px) {
  .about-grid { grid-template-columns: 1fr; }
  .about-stats { grid-template-columns: repeat(2, 1fr); }
  .about-stat:nth-child(2) { border-right: 0; }
  .about-stat:nth-child(1), .about-stat:nth-child(2) { border-bottom: 1px solid var(--line); }
}

/* =========================================================================
   Services
   ========================================================================= */
.services-head {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: end;
  margin-bottom: 60px;
}
.services-head h2.display {
  font-size: clamp(36px, 4.4vw, 60px);
  margin: 18px 0 0;
}
.services-head p {
  font-size: 16px;
  color: var(--ink-2);
  max-width: 48ch;
}

.svc-list {
  border-top: 1px solid var(--line-2);
}
.svc-row {
  display: grid;
  grid-template-columns: 64px minmax(0, 1.1fr) minmax(0, 1.8fr) 40px;
  gap: clamp(20px, 3vw, 56px);
  padding: 32px 0;
  border-bottom: 1px solid var(--line);
  align-items: start;
  position: relative;
  cursor: pointer;
  transition: background .3s ease;
}
.svc-row::before {
  content: "";
  position: absolute;
  left: 0; right: 0; top: 0;
  height: 1px;
  background: var(--gold);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .45s cubic-bezier(.2,.7,.2,1);
}
.svc-row:hover::before { transform: scaleX(1); }
.svc-row:hover .svc-cta { color: var(--gold-deep); transform: translateX(4px); }
.svc-row:hover h3 { color: var(--gold-deep); }

.svc-num {
  font-family: var(--f-mono);
  font-size: 12px;
  letter-spacing: 0.06em;
  color: var(--ink-3);
  padding-top: 6px;
}
.svc-title h3 {
  font-family: var(--f-serif);
  font-weight: 500;
  font-size: clamp(22px, 2vw, 28px);
  margin: 0 0 8px;
  line-height: 1.15;
  transition: color .25s;
}
.svc-tags {
  display: flex; flex-wrap: wrap; gap: 6px;
  margin-top: 12px;
}
.svc-tag {
  font-size: 11px;
  letter-spacing: 0.04em;
  padding: 3px 8px;
  border: 1px solid var(--line-2);
  border-radius: 999px;
  color: var(--ink-2);
  background: transparent;
}
.svc-desc {
  font-size: 15px;
  line-height: 1.65;
  color: var(--ink-2);
  max-width: 56ch;
  padding-top: 4px;
}
.svc-cta {
  align-self: center;
  font-family: var(--f-mono);
  font-size: 13px;
  color: var(--ink-3);
  transition: color .25s, transform .25s;
  justify-self: end;
}

@media (max-width: 900px) {
  .services-head { grid-template-columns: 1fr; }
  .svc-row { grid-template-columns: 40px 1fr; gap: 16px; }
  .svc-row .svc-desc { grid-column: 1 / -1; padding-top: 0; }
  .svc-row .svc-cta { display: none; }
}

/* =========================================================================
   Why us
   ========================================================================= */
.why {
  background: var(--sect-deep);
}
.why-grid {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: clamp(28px, 5vw, 80px);
}
.why-grid h2.display {
  font-size: clamp(34px, 4.2vw, 58px);
  margin: 18px 0 0;
}
.why-points {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0;
}
.why-point {
  padding: 28px 24px 28px 0;
  border-top: 1px solid var(--line);
  position: relative;
}
.why-point:nth-child(odd) { padding-right: 32px; border-right: 1px solid var(--line); padding-left: 0; }
.why-point:nth-child(even) { padding-left: 32px; }
.why-point-n {
  font-family: var(--f-mono);
  font-size: 11px;
  color: var(--gold-deep);
  letter-spacing: 0.06em;
  margin-bottom: 10px;
}
.why-point h4 {
  font-family: var(--f-serif);
  font-size: 22px;
  font-weight: 500;
  line-height: 1.25;
  margin: 0 0 8px;
  letter-spacing: -0.005em;
}
.why-point p {
  font-size: 14.5px;
  color: var(--ink-2);
  margin: 0;
  line-height: 1.6;
}

@media (max-width: 900px) {
  .why-grid { grid-template-columns: 1fr; }
  .why-points { grid-template-columns: 1fr; }
  .why-point { padding: 24px 0 !important; border-right: 0 !important; }
}

/* =========================================================================
   Method
   ========================================================================= */
.method-head h2.display {
  font-size: clamp(36px, 4.4vw, 60px);
  margin: 18px 0 32px;
  max-width: 16ch;
}
.method-steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  border-top: 1px solid var(--line-2);
  margin-top: 40px;
  counter-reset: stp;
}
.method-step {
  padding: 36px 28px 36px 0;
  border-right: 1px solid var(--line);
  position: relative;
}
.method-step:last-child { border-right: 0; }
.method-step::before {
  content: "";
  position: absolute;
  top: -1px; left: 0;
  height: 3px;
  background: var(--gold);
  width: 56px;
}
.method-step .step-n {
  font-family: var(--f-mono);
  font-size: 11px;
  color: var(--ink-3);
  letter-spacing: 0.08em;
  margin-bottom: 26px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.method-step .step-n b {
  font-family: var(--f-serif);
  font-weight: 500;
  font-size: 28px;
  color: var(--ink);
}
.method-step h4 {
  font-family: var(--f-serif);
  font-size: 26px;
  font-weight: 500;
  margin: 0 0 12px;
  letter-spacing: -0.01em;
}
.method-step p {
  font-size: 14.5px;
  color: var(--ink-2);
  line-height: 1.6;
  margin: 0;
  max-width: 26ch;
}

@media (max-width: 900px) {
  .method-steps { grid-template-columns: 1fr; }
  .method-step { border-right: 0; border-bottom: 1px solid var(--line); padding: 28px 0; }
  .method-step:last-child { border-bottom: 0; }
}

/* =========================================================================
   Audience
   ========================================================================= */
.aud-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: clamp(28px, 5vw, 80px);
  align-items: start;
}
.aud-grid h2.display {
  font-size: clamp(36px, 4.2vw, 58px);
  margin: 18px 0 0;
}
.aud-grid > div:first-child p {
  margin-top: 24px;
  color: var(--ink-2);
  font-size: 16.5px;
  max-width: 46ch;
}
.aud-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}
.aud-item {
  background: var(--surface);
  padding: 22px;
  display: flex;
  align-items: baseline;
  gap: 14px;
  transition: background .2s;
}
.aud-item:hover { background: var(--bg-2); }
.aud-item .n {
  font-family: var(--f-mono);
  font-size: 11px;
  color: var(--gold-deep);
  letter-spacing: 0.04em;
  min-width: 22px;
}
.aud-item .t {
  font-family: var(--f-serif);
  font-size: 19px;
  line-height: 1.25;
  letter-spacing: -0.005em;
}

@media (max-width: 700px) {
  .aud-grid { grid-template-columns: 1fr; }
  .aud-list { grid-template-columns: 1fr; }
}

/* =========================================================================
   Team
   ========================================================================= */
.team-head {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: end;
  margin-bottom: 56px;
}
.team-head h2.display {
  font-size: clamp(36px, 4.4vw, 60px);
  margin: 18px 0 0;
}
.team-head p { color: var(--ink-2); max-width: 46ch; font-size: 16px; }

.team-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(24px, 3.2vw, 48px);
  max-width: 1200px;
}
.team-card {
  border-top: 1px solid var(--line-2);
  padding-top: 22px;
}
.team-photo {
  aspect-ratio: 5 / 6;
  background: linear-gradient(160deg, var(--bg-2), var(--surface));
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  position: relative;
  overflow: hidden;
  display: flex; align-items: center; justify-content: center;
}
.team-photo.team-photo-static img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 1.2s cubic-bezier(.2,.6,.2,1);
}
.team-card:hover .team-photo.team-photo-static img {
  transform: scale(1.025);
}
.team-photo .initials {
  font-family: var(--f-serif);
  font-size: clamp(88px, 9vw, 132px);
  color: var(--sage);
  opacity: 0.35;
  letter-spacing: -0.02em;
  font-weight: 500;
}

/* image-slot version */
.team-photo-slot {
  display: block;
  width: 100%;
  aspect-ratio: 5 / 6;
  --slot-bg: linear-gradient(160deg, var(--bg-2), var(--surface));
  --slot-border: 1px solid var(--line);
  --slot-caption-color: var(--ink-3);
  background: linear-gradient(160deg, var(--bg-2), var(--surface));
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  overflow: hidden;
}
.team-photo::after,
.team-card .team-photo-slot::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 3px;
  background: var(--gold);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .5s cubic-bezier(.2,.7,.2,1);
  z-index: 2;
  pointer-events: none;
}
.team-card { position: relative; }
.team-card .team-photo-slot { position: relative; }
.team-card:hover .team-photo::after,
.team-card:hover .team-photo-slot::after { transform: scaleX(1); }

.team-name {
  font-family: var(--f-serif);
  font-size: clamp(22px, 2vw, 28px);
  font-weight: 500;
  margin: 22px 0 6px;
  letter-spacing: -0.01em;
  line-height: 1.15;
}
.team-role {
  font-size: 12px;
  color: var(--gold-deep);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 500;
}
.team-cred {
  margin-top: 14px;
  font-size: 15px;
  color: var(--ink-2);
  line-height: 1.6;
  max-width: 46ch;
}

@media (max-width: 960px) {
  .team-grid { grid-template-columns: repeat(2, 1fr); max-width: 100%; }
}
@media (max-width: 600px) {
  .team-head { grid-template-columns: 1fr; }
  .team-grid { grid-template-columns: 1fr; max-width: 520px; }
}

/* =========================================================================
   Authority strip (dark band)
   ========================================================================= */
.authority {
  background: var(--sage-deep);
  color: var(--on-sage);
  padding: clamp(80px, 9vw, 140px) 0;
  position: relative;
  overflow: hidden;
}
[data-mode="dark"] .authority { background: #0a0d10; }
.authority-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: clamp(28px, 5vw, 80px);
}
.authority .display {
  font-size: clamp(36px, 4.6vw, 64px);
  color: var(--on-sage);
  letter-spacing: -0.015em;
  max-width: 18ch;
}
.authority .display em { color: var(--gold); }
.authority-aside {
  align-self: end;
}
.authority-aside p {
  color: var(--on-sage-2);
  font-size: 16.5px;
  line-height: 1.7;
  max-width: 48ch;
}
.authority .eyebrow {
  color: var(--on-sage-2);
}
.authority .eyebrow::before { background: var(--gold); }

.authority-marquee {
  margin-top: clamp(56px, 6vw, 80px);
  padding-top: 28px;
  border-top: 1px solid rgba(243, 238, 222, 0.18);
  display: flex; gap: 40px;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
}
.authority-marquee span {
  font-family: var(--f-serif);
  font-size: 15px;
  color: var(--on-sage-2);
  letter-spacing: 0.04em;
}
.authority-marquee b {
  color: var(--gold);
  font-weight: 500;
  margin-right: 8px;
  font-family: var(--f-mono);
  font-size: 12px;
}

.authority-orn {
  position: absolute;
  right: -10%; top: -10%;
  width: 50%; height: 120%;
  opacity: 0.08;
  pointer-events: none;
}
.authority-orn .hero-orn-img img { object-position: center; }

@media (max-width: 900px) {
  .authority-grid { grid-template-columns: 1fr; }
}

/* =========================================================================
   Contact
   ========================================================================= */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: clamp(40px, 6vw, 100px);
}
.contact-grid h2.display {
  font-size: clamp(36px, 4.4vw, 60px);
  margin: 18px 0 24px;
}
.contact-grid > div:first-child > p {
  color: var(--ink-2);
  font-size: 16.5px;
  max-width: 44ch;
  margin: 0 0 36px;
}

.contact-channels {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  border-top: 1px solid var(--line-2);
}
.cc-row {
  display: grid;
  grid-template-columns: 110px 1fr auto;
  align-items: center;
  gap: 16px;
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
}
.cc-row dt {
  font-size: 10.5px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-3);
  font-weight: 500;
}
.cc-row dd {
  margin: 0;
  font-family: var(--f-serif);
  font-size: 18px;
  color: var(--ink);
}
.cc-row .cc-act {
  font-size: 12px;
  color: var(--ink-3);
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

/* Form */
.form {
  background: var(--surface);
  border: 1px solid var(--line);
  padding: clamp(28px, 3vw, 44px);
  border-radius: var(--r-md);
}
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px 20px;
}
.field { display: flex; flex-direction: column; gap: 8px; position: relative; }
.field.span-2 { grid-column: 1 / -1; }
.field label {
  font-size: 10.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-3);
  font-weight: 500;
}
.field label .req { color: var(--gold-deep); margin-left: 2px; }
.field input, .field select, .field textarea {
  appearance: none;
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--line-2);
  padding: 10px 0;
  font-family: var(--f-sans);
  font-size: 15px;
  color: var(--ink);
  outline: none;
  transition: border-color .2s;
  border-radius: 0;
}
.field input:focus, .field select:focus, .field textarea:focus {
  border-color: var(--gold);
}
.field textarea { resize: vertical; min-height: 96px; font-family: inherit; }
.field select {
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'><path fill='%23828c85' d='M0 0h10L5 6z'/></svg>");
  background-repeat: no-repeat;
  background-position: right 0 center;
  padding-right: 22px;
}
.field .err {
  position: absolute;
  bottom: -16px; left: 0;
  font-size: 11px;
  color: #b34a3a;
}
.field.invalid input, .field.invalid select, .field.invalid textarea {
  border-bottom-color: #b34a3a;
}

.form-foot {
  margin-top: 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.form-note {
  font-size: 12px;
  color: var(--ink-3);
  max-width: 38ch;
}

/* success state */
.form-success {
  text-align: center;
  padding: 24px 0;
}
.form-success .ok {
  width: 56px; height: 56px;
  border-radius: 50%;
  background: color-mix(in oklab, var(--gold) 25%, transparent);
  display: inline-flex; align-items: center; justify-content: center;
  margin-bottom: 18px;
  border: 1px solid var(--gold);
  animation: pop .4s ease;
}
.form-success h3 {
  font-family: var(--f-serif);
  font-size: 28px;
  font-weight: 500;
  margin: 0 0 8px;
}
.form-success p {
  color: var(--ink-2);
  margin: 0 auto;
  max-width: 36ch;
}

@keyframes pop {
  0%{transform:scale(.6);opacity:0}
  100%{transform:scale(1);opacity:1}
}

@media (max-width: 900px) {
  .contact-grid { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
}

/* =========================================================================
   Footer
   ========================================================================= */
.foot {
  background: var(--sect-deep);
  padding: 60px 0 24px;
  margin-top: 0;
}
.foot-top {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 48px;
  border-bottom: 1px solid var(--line);
}
.foot h5 {
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin: 0 0 16px;
  font-weight: 500;
}
.foot ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.foot li a {
  font-size: 14px;
  color: var(--ink-2);
  transition: color .2s;
}
.foot li a:hover { color: var(--gold-deep); }
.foot-claim {
  font-family: var(--f-serif);
  font-size: 22px;
  line-height: 1.4;
  max-width: 28ch;
  color: var(--ink);
}
.foot-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 24px;
  font-size: 12px;
  color: var(--ink-3);
  flex-wrap: wrap;
  gap: 12px;
}

@media (max-width: 900px) {
  .foot-top { grid-template-columns: 1fr 1fr; }
  .foot-top > div:first-child { grid-column: 1 / -1; }
}

/* =========================================================================
   Reveal on scroll
   ========================================================================= */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity .8s ease, transform .8s cubic-bezier(.2,.7,.2,1);
}
.reveal.in {
  opacity: 1;
  transform: translateY(0);
}

/* =========================================================================
   Misc
   ========================================================================= */
.hidden { display: none !important; }
.mono { font-family: var(--f-mono); }

/* scrollbar */
::selection { background: var(--gold); color: var(--sage-deep); }
