/* ==========================================================================
   Imori Advisory Group
   Palette: tanzanite (the gem found only in Tanzania), night, pearl,
   savanna gold. Type: Bricolage Grotesque (interface and display),
   Newsreader (long-form reading and quotation).
   ========================================================================== */

@font-face {
  font-family: "Bricolage Grotesque";
  src: url("fonts/bricolage-grotesque.woff2") format("woff2");
  font-weight: 200 800;
  font-stretch: 75% 100%;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Newsreader";
  src: url("fonts/newsreader.woff2") format("woff2");
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Newsreader";
  src: url("fonts/newsreader-italic.woff2") format("woff2");
  font-weight: 200 800;
  font-style: italic;
  font-display: swap;
}

:root {
  --night: #0c0926;
  --night-2: #141039;
  --night-3: #1d1752;
  --tanzanite: #4438a6;
  --tanzanite-deep: #2c256e;
  --violet: #8f83cf;
  --pearl: #f3f3fa;
  --pearl-2: #e8e8f5;
  --gold: #e0aa3e;
  --gold-deep: #c98a1e;

  --ink: #14112e;
  --ink-2: #4f4c74;
  --ink-3: #7a779c;
  --on-night: #f1f0fb;
  --on-night-2: #b9b5e0;
  --on-night-3: #8884b8;

  --rule: rgba(20, 17, 46, 0.12);
  --rule-night: rgba(241, 240, 251, 0.13);
  --error: #b3261e;
  --error-night: #ff9d8f;

  --sans: "Bricolage Grotesque", "Helvetica Neue", Arial, sans-serif;
  --serif: "Newsreader", Georgia, "Times New Roman", serif;

  --t-small: 0.875rem;
  --t-body: clamp(1.0625rem, 1rem + 0.2vw, 1.1875rem);
  --t-lead: clamp(1.25rem, 1.1rem + 0.6vw, 1.5rem);
  --t-h3: clamp(1.5rem, 1.2rem + 1.1vw, 2.125rem);
  --t-h2: clamp(2.25rem, 1.4rem + 3.4vw, 4.25rem);
  --t-h1: clamp(3rem, 1rem + 6.3vw, 6.4rem);

  --shell: 1280px;
  --gutter: clamp(1.25rem, 4vw, 3rem);
  --band: clamp(5rem, 11vw, 9.5rem);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --r-lg: 28px;
  --r-md: 16px;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 6rem; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--pearl);
  color: var(--ink);
  font-family: var(--sans);
  font-size: var(--t-body);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4, p, dl, dd, ul, ol, figure, blockquote { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; text-decoration: none; }
img, svg { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; }

::selection { background: var(--tanzanite); color: #fff; }

:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
  border-radius: 6px;
}
.on-pearl :focus-visible, .prose :focus-visible { outline-color: var(--tanzanite); }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

.skip {
  position: absolute; left: 1rem; top: -4rem; z-index: 200;
  background: var(--gold); color: var(--night); padding: 0.7rem 1rem; border-radius: 10px; font-weight: 600;
}
.skip:focus { top: 1rem; }

.shell { width: min(var(--shell), 100% - var(--gutter) * 2); margin-inline: auto; }

h1, h2, h3, h4 { font-weight: 600; font-stretch: 88%; letter-spacing: -0.028em; line-height: 1.02; text-wrap: balance; }
h2 { font-size: var(--t-h2); }
h3 { font-size: var(--t-h3); line-height: 1.1; }
p { text-wrap: pretty; }

/* ---------- Links and buttons ---------- */

.text-link {
  font-weight: 600;
  color: var(--tanzanite);
  background: linear-gradient(currentColor, currentColor) 0 100% / 100% 1.5px no-repeat;
  padding-bottom: 2px;
  transition: background-size 0.35s var(--ease), color 0.2s;
}
.text-link:hover { background-size: 0 1.5px; background-position: 100% 100%; }
.band--night .text-link, .footer .text-link { color: var(--gold); }

.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  min-height: 3.25rem;
  padding: 0.85rem 1.6rem;
  border: 0;
  border-radius: 999px;
  font-weight: 600;
  font-size: 1rem;
  line-height: 1.1;
  letter-spacing: -0.005em;
  cursor: pointer;
  overflow: hidden;
  isolation: isolate;
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease), background-color 0.25s;
}
/* The gloss: a hard specular band across the top half, like light on lacquer */
.btn::before {
  content: "";
  position: absolute;
  inset: 1px 1px 52% 1px;
  border-radius: 999px 999px 60% 60% / 999px 999px 14px 14px;
  background: linear-gradient(rgba(255, 255, 255, 0.5), rgba(255, 255, 255, 0.06));
  z-index: -1;
  pointer-events: none;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }

.btn--gold {
  color: var(--night);
  background: linear-gradient(180deg, #ffd27a 0%, var(--gold) 45%, #dc9d2b 100%);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.5) inset, 0 -2px 0 rgba(120, 70, 0, 0.25) inset, 0 14px 34px -12px rgba(240, 185, 74, 0.6);
}
.btn--gold:hover { box-shadow: 0 1px 0 rgba(255, 255, 255, 0.5) inset, 0 -2px 0 rgba(120, 70, 0, 0.25) inset, 0 20px 44px -12px rgba(240, 185, 74, 0.75); }

.btn--glass {
  color: var(--on-night);
  background: rgba(241, 240, 251, 0.08);
  box-shadow: 0 0 0 1px rgba(241, 240, 251, 0.22) inset;
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}
.btn--glass::before { background: linear-gradient(rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0)); }
.btn--glass:hover { background: rgba(241, 240, 251, 0.14); }

.btn--gem {
  color: #fff;
  background: linear-gradient(180deg, #6a5cff 0%, var(--tanzanite) 48%, var(--tanzanite-deep) 100%);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.35) inset, 0 -2px 0 rgba(10, 0, 90, 0.35) inset, 0 16px 36px -14px rgba(74, 58, 232, 0.75);
}
.btn--gem::before { background: linear-gradient(rgba(255, 255, 255, 0.38), rgba(255, 255, 255, 0.03)); }
.btn[disabled] { opacity: 0.6; cursor: progress; transform: none; }

/* ---------- Navigation: one floating glass bar ---------- */

.nav {
  position: fixed;
  top: clamp(0.6rem, 1.6vw, 1.1rem);
  left: 0; right: 0;
  z-index: 100;
  pointer-events: none;
}
.nav__bar {
  pointer-events: auto;
  width: min(var(--shell), 100% - var(--gutter) * 2 + 1rem);
  margin-inline: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.5rem 0.5rem 0.5rem 1.4rem;
  border-radius: 999px;
  color: var(--on-night);
  background: rgba(12, 9, 38, 0.62);
  box-shadow: 0 0 0 1px rgba(241, 240, 251, 0.14) inset, 0 1px 0 rgba(255, 255, 255, 0.16) inset, 0 20px 50px -24px rgba(12, 9, 38, 0.8);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  backdrop-filter: blur(18px) saturate(160%);
  transition: background-color 0.3s;
}
.nav.is-scrolled .nav__bar, .on-pearl .nav__bar { background: rgba(12, 9, 38, 0.9); }

.brand { display: inline-flex; align-items: center; gap: 0.7rem; font-weight: 700; font-size: 1.125rem; letter-spacing: -0.02em; white-space: nowrap; }
.brand__gem { width: 1.5rem; height: 1.5rem; flex: none; }
.brand span span { font-weight: 400; color: var(--on-night-2); }

.nav__links { display: flex; align-items: center; gap: 0.25rem; }
.nav__links a {
  padding: 0.6rem 0.95rem;
  border-radius: 999px;
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--on-night-2);
  transition: color 0.2s, background-color 0.2s;
}
.nav__links a:hover { color: var(--on-night); background: rgba(241, 240, 251, 0.08); }
.nav__contact { display: none; }
.nav__end { display: flex; align-items: center; gap: 0.4rem; }
.nav .btn { min-height: 2.6rem; padding: 0.55rem 1.15rem; font-size: 0.9375rem; }

.nav__toggle {
  display: none;
  width: 2.6rem; height: 2.6rem;
  border: 0; border-radius: 50%;
  background: rgba(241, 240, 251, 0.1);
  cursor: pointer;
  place-items: center;
}
.nav__toggle span { display: block; width: 1.05rem; height: 1.5px; background: var(--on-night); transition: transform 0.3s var(--ease); }
.nav__toggle span + span { margin-top: 5px; }
.nav__toggle[aria-expanded="true"] span:first-child { transform: translateY(3.25px) rotate(45deg); }
.nav__toggle[aria-expanded="true"] span:last-child { transform: translateY(-3.25px) rotate(-45deg); }

@media (max-width: 900px) {
  .nav__toggle { display: grid; }
  .nav__links {
    position: absolute;
    top: calc(100% + 0.5rem);
    left: 50%;
    width: min(var(--shell), 100% - var(--gutter) * 2 + 1rem);
    transform: translateX(-50%) translateY(-8px);
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 0.6rem;
    border-radius: var(--r-lg);
    background: rgba(12, 9, 38, 0.96);
    box-shadow: 0 0 0 1px rgba(241, 240, 251, 0.14) inset, 0 30px 60px -20px rgba(12, 9, 38, 0.9);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s, transform 0.35s var(--ease), visibility 0.25s;
  }
  .nav__links.is-open { opacity: 1; visibility: visible; transform: translateX(-50%) translateY(0); }
  .nav__links a { padding: 1rem 1.1rem; font-size: 1.125rem; color: var(--on-night); }
}
@media (max-width: 520px) {
  .nav .btn { display: none; }
  .nav__links a.nav__contact { display: block; color: var(--gold); }
  .nav__bar { padding-left: 1.1rem; }
}

/* ---------- Hero ---------- */

.hero {
  position: relative;
  color: var(--on-night);
  background:
    radial-gradient(60rem 40rem at 88% 18%, rgba(74, 58, 232, 0.55), transparent 62%),
    radial-gradient(46rem 34rem at 4% 96%, rgba(157, 144, 255, 0.2), transparent 60%),
    radial-gradient(30rem 22rem at 62% 110%, rgba(240, 185, 74, 0.14), transparent 60%),
    var(--night);
  padding-top: clamp(7.5rem, 13vw, 11rem);
  overflow: hidden;
}
/* a single slow sheen that crosses the hero once on load */
.hero::after {
  content: "";
  position: absolute;
  inset: -20% auto -20% -40%;
  width: 34%;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.07) 45%, rgba(255, 255, 255, 0.11) 50%, rgba(255, 255, 255, 0.07) 55%, transparent);
  transform: skewX(-14deg) translateX(-120%);
  animation: sheen 2.6s 0.5s var(--ease) forwards;
  pointer-events: none;
}
@keyframes sheen { 85% { opacity: 1; } to { transform: skewX(-14deg) translateX(560%); opacity: 0; } }

.hero__grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
  gap: clamp(2rem, 5vw, 5rem);
  align-items: center;
}

.hero__kicker { color: var(--on-night-2); font-size: 1rem; font-weight: 500; margin-bottom: 1.6rem; }

.hero h1 {
  font-size: var(--t-h1);
  font-weight: 700;
  font-stretch: 78%;
  line-height: 0.9;
  letter-spacing: -0.04em;
  text-wrap: initial;
}
.hero h1 span { display: block; }
/* The map is an outline. The ground is solid. */
.outline {
  color: var(--on-night);
  letter-spacing: -0.02em;
}
.solid {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 400;
  color: #fff;
  padding-bottom: 0.08em;
}

.hero__lede { max-width: 34rem; margin-top: 2rem; font-size: var(--t-lead); line-height: 1.45; color: var(--on-night-2); }
.hero__lede strong { color: var(--on-night); font-weight: 500; }
.hero__cta { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 2.4rem; }

.rise { animation: rise 0.9s var(--ease) both; }
.rise--2 { animation-delay: 0.12s; }
.rise--3 { animation-delay: 0.24s; }
.rise--4 { animation-delay: 0.36s; }
@keyframes rise { from { opacity: 0; transform: translateY(18px); } }

/* The lens: formal map on top, the ground underneath */
.lens {
  --x: 30%;
  --y: 66%;
  --r: clamp(84px, 10.5vw, 132px);
  position: relative;
  aspect-ratio: 520 / 600;
  border-radius: var(--r-lg);
  background: linear-gradient(160deg, rgba(241, 240, 251, 0.1), rgba(241, 240, 251, 0.03) 40%, rgba(74, 58, 232, 0.16));
  box-shadow:
    0 0 0 1px rgba(241, 240, 251, 0.16) inset,
    0 1px 0 rgba(255, 255, 255, 0.3) inset,
    0 50px 90px -40px rgba(4, 2, 20, 0.9);
  overflow: hidden;
  touch-action: pan-y;
  cursor: crosshair;
}
.lens svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.lens text { font-family: var(--sans); }
.lens__ground {
  -webkit-mask-image: radial-gradient(circle var(--r) at var(--x) var(--y), #000 97%, transparent 100%);
  mask-image: radial-gradient(circle var(--r) at var(--x) var(--y), #000 97%, transparent 100%);
}
.lens__ring {
  position: absolute;
  left: var(--x); top: var(--y);
  width: calc(var(--r) * 2); height: calc(var(--r) * 2);
  transform: translate(-50%, -50%);
  border-radius: 50%;
  pointer-events: none;
  box-shadow:
    0 0 0 1.5px rgba(240, 185, 74, 0.9),
    0 0 0 6px rgba(240, 185, 74, 0.12),
    0 0 50px 4px rgba(240, 185, 74, 0.22),
    inset 0 14px 22px -12px rgba(255, 255, 255, 0.5),
    inset 0 -18px 26px -16px rgba(240, 185, 74, 0.5);
}
.lens__tag {
  position: absolute;
  left: 1.1rem; top: 1.1rem;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--on-night-2);
}
.lens__tag b { color: var(--gold); font-weight: 600; }
.lens-caption { margin-top: 1rem; font-size: var(--t-small); color: var(--on-night-3); max-width: 30rem; }

.strip {
  position: relative;
  z-index: 1;
  margin-top: clamp(3.5rem, 7vw, 6rem);
  border-top: 1px solid var(--rule-night);
}
.strip dl { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.strip div { padding: 1.6rem 1.5rem 1.9rem 0; }
.strip div + div { padding-left: 1.5rem; border-left: 1px solid var(--rule-night); }
.strip dt { font-weight: 600; font-size: 1.125rem; letter-spacing: -0.015em; }
.strip dd { margin-top: 0.25rem; font-size: var(--t-small); color: var(--on-night-3); }

@media (max-width: 960px) {
  .hero__grid { grid-template-columns: 1fr; }
  .lens { max-width: 30rem; --r: clamp(84px, 24vw, 120px); }
  .strip dl { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .strip div:nth-child(3) { padding-left: 0; border-left: 0; }
  .strip div:nth-child(n + 3) { border-top: 1px solid var(--rule-night); }
}
@media (max-width: 480px) {
  .strip div { padding-right: 0.75rem; }
  .strip div + div { padding-left: 1rem; }
  .strip div:nth-child(3) { padding-left: 0; }
}

/* ---------- Bands ---------- */

.band { padding-block: var(--band); }
.band--tint { background: var(--pearl-2); }
.band--night {
  color: var(--on-night);
  background:
    radial-gradient(50rem 30rem at 100% 0%, rgba(74, 58, 232, 0.4), transparent 62%),
    radial-gradient(40rem 28rem at 0% 100%, rgba(157, 144, 255, 0.13), transparent 60%),
    var(--night);
}

.head {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr);
  gap: 1.5rem clamp(2rem, 6vw, 6rem);
  align-items: end;
  margin-bottom: clamp(2.5rem, 6vw, 4.5rem);
}
.head h2 { max-width: 16ch; }
.head p { color: var(--ink-2); max-width: 26rem; }
.band--night .head p { color: var(--on-night-2); }
@media (max-width: 760px) { .head { grid-template-columns: 1fr; } }

/* ---------- Premise ---------- */

.premise { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 2rem clamp(2rem, 6vw, 6rem); align-items: start; }
.premise__big {
  font-family: var(--serif);
  font-size: clamp(1.75rem, 1.1rem + 2.6vw, 3.25rem);
  font-weight: 400;
  line-height: 1.14;
  letter-spacing: -0.018em;
}
.premise__big em { font-style: italic; color: var(--tanzanite); }
.premise__after { color: var(--ink-2); font-size: var(--t-lead); line-height: 1.5; padding-top: 0.6rem; }
@media (max-width: 860px) { .premise { grid-template-columns: 1fr; } }

/* ---------- Who we serve ---------- */

.serve { border-top: 1px solid var(--rule); }
.serve li {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr) minmax(0, 1.6fr);
  gap: 0.5rem 2rem;
  align-items: baseline;
  padding: 1.9rem 0;
  border-bottom: 1px solid var(--rule);
  transition: padding-left 0.4s var(--ease);
}
.serve li:hover { padding-left: 0.75rem; }
.serve__kind { color: var(--ink-3); font-size: 1rem; font-weight: 500; }
.serve h3 { font-size: var(--t-h3); }
.serve p { color: var(--ink-2); }
@media (max-width: 860px) {
  .serve li { grid-template-columns: 1fr; padding: 1.5rem 0; }
  .serve li:hover { padding-left: 0; }
}

/* ---------- Practice ---------- */

.practice { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: 2.5rem clamp(2rem, 6vw, 6rem); align-items: start; }

.dossier {
  position: relative;
  padding: clamp(1.6rem, 3vw, 2.4rem);
  border-radius: var(--r-lg);
  color: var(--on-night);
  background:
    radial-gradient(26rem 18rem at 100% 0%, rgba(157, 144, 255, 0.55), transparent 65%),
    linear-gradient(150deg, var(--tanzanite) 0%, var(--tanzanite-deep) 42%, var(--night-2) 100%);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.35) inset, 0 0 0 1px rgba(255, 255, 255, 0.1) inset, 0 40px 70px -36px rgba(47, 34, 184, 0.75);
  overflow: hidden;
}
.dossier::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 38%;
  background: linear-gradient(rgba(255, 255, 255, 0.14), transparent);
  pointer-events: none;
}
.dossier > * { position: relative; }
.dossier__name { font-size: clamp(2.25rem, 1.6rem + 2.4vw, 3.5rem); font-weight: 700; font-stretch: 80%; letter-spacing: -0.035em; line-height: 0.95; }
.dossier__role { margin-top: 0.6rem; color: rgba(241, 240, 251, 0.8); }
.dossier dl { margin-top: 2rem; border-top: 1px solid rgba(241, 240, 251, 0.2); }
.dossier dl div { display: grid; grid-template-columns: 7.5rem minmax(0, 1fr); gap: 1rem; padding: 1rem 0; border-bottom: 1px solid rgba(241, 240, 251, 0.2); }
.dossier dt { font-size: var(--t-small); color: rgba(241, 240, 251, 0.7); padding-top: 0.15rem; }
.dossier dd { font-size: 1rem; line-height: 1.45; }
.dossier dd a { color: var(--gold); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
@media (max-width: 420px) { .dossier dl div { grid-template-columns: 1fr; gap: 0.2rem; } }

.practice__copy > * + * { margin-top: 1.3rem; }
.practice__copy p { color: var(--ink-2); max-width: 36rem; }
.practice__copy .lead { font-family: var(--serif); font-size: clamp(1.5rem, 1.2rem + 1.2vw, 2.125rem); line-height: 1.22; letter-spacing: -0.012em; color: var(--ink); }
.practice__copy .keyline {
  color: var(--ink);
  font-weight: 600;
  font-size: var(--t-lead);
  line-height: 1.35;
  padding: 1.3rem 0 1.3rem 1.4rem;
  border-left: 3px solid var(--tanzanite);
  margin-top: 2rem;
}
@media (max-width: 860px) { .practice { grid-template-columns: 1fr; } }

/* ---------- Engagements ---------- */

.engagements { border-top: 1px solid var(--rule-night); }
.engagement {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr);
  gap: 1.5rem clamp(2rem, 6vw, 6rem);
  padding: clamp(2.2rem, 4.5vw, 3.6rem) 0;
  border-bottom: 1px solid var(--rule-night);
}
.engagement h3 { font-size: clamp(1.9rem, 1.3rem + 2.2vw, 3rem); font-stretch: 82%; }
.engagement__for { margin-top: 0.8rem; color: var(--gold); font-weight: 500; }
.chips { display: flex; flex-wrap: wrap; gap: 0.45rem; margin-top: 1.4rem; }
.chips li {
  padding: 0.38rem 0.85rem;
  border-radius: 999px;
  font-size: var(--t-small);
  color: var(--on-night-2);
  background: rgba(241, 240, 251, 0.06);
  box-shadow: 0 0 0 1px rgba(241, 240, 251, 0.14) inset;
}
.engagement__body > p { color: var(--on-night-2); max-width: 38rem; }
.engagement__body > p + p { margin-top: 1rem; }
.engagement__body > p:first-child { color: var(--on-night); font-size: var(--t-lead); line-height: 1.4; }
.fit {
  margin-top: 1.8rem;
  padding: 1.15rem 1.3rem;
  border-radius: var(--r-md);
  background: rgba(241, 240, 251, 0.05);
  box-shadow: 0 0 0 1px rgba(241, 240, 251, 0.1) inset;
  max-width: 38rem;
}
.fit dt { font-size: var(--t-small); font-weight: 600; color: var(--violet); }
.fit dd { margin-top: 0.3rem; font-size: 1rem; color: var(--on-night-2); }
@media (max-width: 860px) { .engagement { grid-template-columns: 1fr; } }

.aside-cta {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1.2rem 2rem;
  margin-top: clamp(2rem, 4vw, 3rem);
}
.aside-cta p { max-width: 34rem; font-size: var(--t-lead); line-height: 1.4; }
.band--night .aside-cta p { color: var(--on-night); }
.aside-cta--pearl p { color: var(--ink-2); font-size: var(--t-body); }

/* ---------- Process (a real sequence, so it is numbered) ---------- */

.steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); counter-reset: step; }
.steps li { counter-increment: step; position: relative; padding: 2.2rem 1.75rem 0 0; }
.steps li::before {
  content: counter(step);
  display: grid; place-items: center;
  width: 2.75rem; height: 2.75rem;
  border-radius: 50%;
  font-weight: 700;
  color: #fff;
  background: linear-gradient(180deg, #6a5cff, var(--tanzanite-deep));
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.45) inset, 0 12px 22px -10px rgba(74, 58, 232, 0.8);
  position: relative; z-index: 1;
}
.steps li::after {
  content: "";
  position: absolute;
  top: calc(2.2rem + 1.375rem);
  left: 2.75rem; right: 0;
  height: 1px;
  background: var(--rule);
}
.steps li:last-child::after { display: none; }
.steps h3 { font-size: 1.5rem; margin-top: 1.5rem; }
.steps p { margin-top: 0.6rem; color: var(--ink-2); font-size: 1rem; }
@media (max-width: 900px) {
  .steps { grid-template-columns: 1fr; }
  .steps li { padding: 0 0 2rem 4rem; }
  .steps li::before { position: absolute; left: 0; top: 0; }
  .steps li::after { top: 2.75rem; bottom: 0; left: 1.375rem; right: auto; width: 1px; height: auto; }
  .steps h3 { margin-top: 0; padding-top: 0.45rem; }
}

/* ---------- Perspectives ---------- */

.feature {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  border-radius: var(--r-lg);
  overflow: hidden;
  background: #fff;
  box-shadow: 0 40px 80px -50px rgba(20, 17, 46, 0.45), 0 0 0 1px rgba(20, 17, 46, 0.06);
}
.feature__body { padding: clamp(1.8rem, 4vw, 3.5rem); display: flex; flex-direction: column; align-items: flex-start; gap: 1.2rem; }
.feature__place { color: var(--ink-3); font-size: 1rem; font-weight: 500; }
.feature__body h3 { font-size: clamp(1.9rem, 1.3rem + 2.2vw, 3rem); font-stretch: 82%; }
.feature__body p { color: var(--ink-2); max-width: 32rem; }
.feature__meta { margin-top: auto; padding-top: 1rem; font-size: var(--t-small); color: var(--ink-3); }
.feature__quote {
  position: relative;
  display: grid; align-content: center;
  padding: clamp(1.8rem, 4vw, 3.5rem);
  color: var(--on-night);
  background:
    radial-gradient(24rem 18rem at 100% 0%, rgba(157, 144, 255, 0.5), transparent 65%),
    linear-gradient(150deg, var(--tanzanite), var(--tanzanite-deep) 50%, var(--night-2));
}
.feature__quote p {
  font-family: var(--serif);
  font-size: clamp(1.5rem, 1.1rem + 1.6vw, 2.375rem);
  font-style: italic;
  line-height: 1.2;
  letter-spacing: -0.012em;
}
.feature__quote cite { display: block; margin-top: 1.4rem; font-style: normal; font-size: var(--t-small); color: rgba(241, 240, 251, 0.75); }
@media (max-width: 860px) { .feature { grid-template-columns: 1fr; } }

/* ---------- Library ---------- */

.books { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(1.25rem, 2.5vw, 2.25rem); }
.book { display: flex; flex-direction: column; }
.cover {
  position: relative;
  display: flex; flex-direction: column; justify-content: space-between;
  aspect-ratio: 2 / 3;
  padding: 1.4rem 1.3rem 1.3rem 1.7rem;
  border-radius: 4px 12px 12px 4px;
  color: #fff;
  overflow: hidden;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.35) inset, 0 34px 50px -28px var(--shade), 0 10px 18px -10px rgba(20, 17, 46, 0.4);
  transition: transform 0.5s var(--ease), box-shadow 0.5s var(--ease);
}
/* spine */
.cover::before {
  content: "";
  position: absolute; inset: 0 auto 0 0;
  width: 0.7rem;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.35), rgba(255, 255, 255, 0.18) 55%, rgba(0, 0, 0, 0.12));
}
/* lacquer highlight that sweeps on hover */
.cover::after {
  content: "";
  position: absolute; inset: -30% -60%;
  background: linear-gradient(105deg, transparent 40%, rgba(255, 255, 255, 0.22) 47%, rgba(255, 255, 255, 0.06) 53%, transparent 60%);
  transform: translateX(-28%);
  transition: transform 0.9s var(--ease);
  pointer-events: none;
}
a:hover > .cover, a:focus-visible > .cover { transform: translateY(-8px) rotate(-1deg); }
a:hover > .cover::after, a:focus-visible > .cover::after { transform: translateX(28%); }
.cover__kind { font-size: 0.8125rem; font-weight: 500; opacity: 0.85; }
.cover__title { font-size: clamp(1.5rem, 0.9rem + 1.5vw, 2.25rem); font-weight: 700; font-stretch: 76%; line-height: 0.98; letter-spacing: -0.03em; hyphens: manual; }
.cover__author { font-size: 0.875rem; font-weight: 500; opacity: 0.9; }
.cover--tanzanite { --shade: rgba(47, 34, 184, 0.8); background: radial-gradient(120% 80% at 100% 0%, #8a7dff, transparent 60%), linear-gradient(160deg, #5546ee, #25198f); }
.cover--lake { --shade: rgba(9, 84, 92, 0.8); background: radial-gradient(120% 80% at 100% 0%, rgba(63,193,196,0.45), transparent 60%), linear-gradient(160deg, #0e6d76, #063f47); }
.cover--garnet { --shade: rgba(122, 22, 62, 0.8); background: radial-gradient(120% 80% at 100% 0%, #e2618c, transparent 60%), linear-gradient(160deg, #a52357, #4f0c28); }
.cover--gold { --shade: rgba(176, 116, 18, 0.8); color: var(--night); background: radial-gradient(120% 80% at 100% 0%, #ffe6a8, transparent 60%), linear-gradient(160deg, #f4c257, #c98a1e); }
.book__info { padding-top: 1.5rem; display: flex; flex-direction: column; gap: 0.5rem; flex: 1; }
.book__subject { font-size: var(--t-small); color: var(--ink-3); font-weight: 500; }
.book__info h3 { font-size: 1.5rem; }
.book__info p { color: var(--ink-2); font-size: 1rem; }
.book__info p { margin-bottom: 0.5rem; }
.book__info .text-link { align-self: flex-start; margin-top: auto; font-size: 1rem; }
@media (max-width: 1020px) { .books { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2.5rem 1.5rem; } }
@media (max-width: 520px) {
  .books { grid-template-columns: 1fr; }
  .book { display: grid; grid-template-columns: 7.5rem minmax(0, 1fr); gap: 1.25rem; align-items: start; }
  .cover { padding: 0.8rem 0.6rem 0.7rem 1rem; }
  .cover__title { font-size: 1.05rem; }
  .cover__kind, .cover__author { font-size: 0.625rem; }
  .book__info { padding-top: 0; }
}

/* ---------- Contact ---------- */

.contact { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: 3rem clamp(2rem, 6vw, 6rem); align-items: start; }
.contact h2 { max-width: 15ch; }
.contact__intro > p { margin-top: 1.5rem; color: var(--on-night-2); font-size: var(--t-lead); line-height: 1.45; max-width: 32rem; }
.contact__meta { margin-top: 2.2rem; border-top: 1px solid var(--rule-night); max-width: 32rem; }
.contact__meta div { display: grid; grid-template-columns: 7rem minmax(0, 1fr); gap: 1rem; padding: 0.9rem 0; border-bottom: 1px solid var(--rule-night); font-size: 1rem; }
.contact__meta dt { color: var(--on-night-3); }
.whatsapp { margin-top: 2rem; }
.whatsapp svg { width: 1.25rem; height: 1.25rem; fill: currentColor; }

.card {
  position: relative;
  padding: clamp(1.5rem, 3.2vw, 2.6rem);
  border-radius: var(--r-lg);
  background: linear-gradient(160deg, rgba(241, 240, 251, 0.12), rgba(241, 240, 251, 0.04));
  box-shadow: 0 0 0 1px rgba(241, 240, 251, 0.16) inset, 0 1px 0 rgba(255, 255, 255, 0.28) inset, 0 50px 90px -50px rgba(4, 2, 20, 0.9);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
}
.card__head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 0.4rem 1rem; margin-bottom: 1.6rem; }
.card__head h3 { font-size: 1.75rem; }
.card__head span { font-size: var(--t-small); color: var(--on-night-3); }

.fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.1rem; }
.field { display: flex; flex-direction: column; gap: 0.4rem; }
.field--full { grid-column: 1 / -1; }
.field label { font-size: var(--t-small); font-weight: 500; color: var(--on-night-2); }
.field input, .field select, .field textarea {
  width: 100%;
  padding: 0.85rem 1rem;
  border: 0;
  border-radius: 12px;
  background: rgba(12, 9, 38, 0.55);
  box-shadow: 0 0 0 1px rgba(241, 240, 251, 0.18) inset;
  color: var(--on-night);
  font-size: 1rem;
  transition: box-shadow 0.2s, background-color 0.2s;
}
.field textarea { resize: vertical; min-height: 7.5rem; line-height: 1.5; }
.field select {
  appearance: none; -webkit-appearance: none;
  padding-right: 2.6rem;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M2.5 4.5 6 8l3.5-3.5' fill='none' stroke='%23b9b5e0' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 1rem center; background-size: 0.8rem;
}
.field select option { color: #14112e; background: #fff; }
.field ::placeholder { color: var(--on-night-3); opacity: 1; }
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none;
  background-color: rgba(12, 9, 38, 0.8);
  box-shadow: 0 0 0 2px var(--gold) inset;
}
.field__error { display: none; font-size: var(--t-small); color: var(--error-night); }
.field.is-invalid input, .field.is-invalid textarea { box-shadow: 0 0 0 2px var(--error-night) inset; }
.field.is-invalid .field__error { display: block; }
.hp { position: absolute; left: -9999px; }

.card__foot { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 1.4rem; margin-top: 1.6rem; }
.card__foot small { font-size: var(--t-small); color: var(--on-night-3); }
.form-status { margin-top: 1rem; font-size: 1rem; color: var(--error-night); }
.form-status:empty { display: none; }

.sent { display: none; }
.card.is-sent form { display: none; }
.card.is-sent .sent { display: block; }
.sent__check {
  display: grid; place-items: center;
  width: 3.5rem; height: 3.5rem; border-radius: 50%;
  background: linear-gradient(180deg, #ffd27a, var(--gold) 50%, #dc9d2b);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.6) inset, 0 16px 30px -12px rgba(240, 185, 74, 0.7);
  margin-bottom: 1.5rem;
}
.sent__check svg { width: 1.5rem; height: 1.5rem; fill: none; stroke: var(--night); stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; }
.sent h3 { font-size: 2.25rem; }
.sent p { margin: 0.9rem 0 1.5rem; color: var(--on-night-2); max-width: 28rem; }

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

/* ---------- Footer ---------- */

.footer { background: #07051a; color: var(--on-night-2); padding: clamp(3.5rem, 7vw, 5.5rem) 0 2rem; font-size: 1rem; }
.footer__grid { display: grid; grid-template-columns: minmax(0, 1.6fr) repeat(3, minmax(0, 1fr)); gap: 2.5rem 2rem; }
.footer .brand { color: var(--on-night); }
.footer__tag { margin-top: 1rem; max-width: 22rem; }
.footer h2 { font-size: var(--t-small); font-weight: 600; font-stretch: 100%; letter-spacing: 0; color: var(--on-night-3); margin-bottom: 0.9rem; }
.footer li + li { margin-top: 0.55rem; }
.footer li a { transition: color 0.2s; }
.footer li a:hover { color: var(--gold); }
.footer__bar {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.75rem 2rem;
  margin-top: clamp(2.5rem, 6vw, 4.5rem); padding-top: 1.5rem;
  border-top: 1px solid var(--rule-night);
  font-size: var(--t-small); color: var(--on-night-3);
  font-variant-numeric: tabular-nums;
}
.footer__coords { display: flex; flex-wrap: wrap; gap: 0.3rem 1.75rem; }
@media (max-width: 860px) { .footer__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .footer__grid > :first-child { grid-column: 1 / -1; } }

/* ---------- Essay ---------- */

.progress {
  position: fixed; inset: 0 0 auto 0; height: 3px; z-index: 150;
  background: linear-gradient(90deg, var(--tanzanite), var(--violet), var(--gold));
  transform: scaleX(0); transform-origin: 0 50%;
}

.essay-hero { padding: clamp(8rem, 14vw, 12rem) 0 clamp(2.5rem, 5vw, 4rem); }
.essay-hero__back { display: inline-block; margin-bottom: 2.2rem; }
.essay-hero__place { color: var(--ink-3); font-weight: 500; margin-bottom: 1.2rem; }
.essay-hero h1 { font-size: clamp(2.6rem, 1.2rem + 6vw, 6.25rem); font-weight: 700; font-stretch: 78%; letter-spacing: -0.04em; line-height: 0.94; max-width: 15ch; }
.byline { display: flex; flex-wrap: wrap; gap: 0.4rem 2rem; margin-top: 2.4rem; padding-top: 1.4rem; border-top: 1px solid var(--rule); color: var(--ink-2); font-size: 1rem; }
.byline b { color: var(--ink); font-weight: 600; }

.essay { display: grid; grid-template-columns: minmax(0, 17rem) minmax(0, 41rem); gap: 3rem clamp(2rem, 7vw, 7rem); padding-bottom: var(--band); align-items: start; }
.brief { position: sticky; top: 7rem; padding: 1.5rem; border-radius: var(--r-md); background: #fff; box-shadow: 0 0 0 1px rgba(20, 17, 46, 0.06), 0 30px 50px -40px rgba(20, 17, 46, 0.5); }
.brief h2 { font-size: 1.125rem; font-stretch: 100%; letter-spacing: -0.01em; }
.brief p { margin-top: 0.8rem; font-size: 1rem; color: var(--ink-2); }
.brief .text-link { font-size: 1rem; }

.prose { font-family: var(--serif); font-size: clamp(1.25rem, 1.15rem + 0.4vw, 1.4375rem); line-height: 1.62; color: #221f42; }
.prose > p + p { margin-top: 1.25em; }
.prose > p:first-child { font-size: clamp(2rem, 1.4rem + 2.4vw, 3.25rem); line-height: 1.1; letter-spacing: -0.02em; color: var(--ink); margin-bottom: 0.9em; }
/* stand-alone bold lines are the essay's turning points */
.prose > p.turn {
  font-family: var(--sans);
  font-size: clamp(1.5rem, 1.2rem + 1.3vw, 2.25rem);
  font-weight: 600; font-stretch: 84%;
  line-height: 1.12; letter-spacing: -0.028em;
  color: var(--tanzanite);
  margin-block: 1.6em;
  padding-left: 1.2rem;
  border-left: 3px solid var(--gold);
  text-wrap: balance;
}
.prose hr {
  width: 0.7rem; height: 0.7rem; margin: 3.2rem auto;
  border: 0; transform: rotate(45deg);
  background: linear-gradient(135deg, var(--violet), var(--tanzanite-deep));
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.6) inset;
}
.prose .bio { margin-top: 3.5rem; padding-top: 1.6rem; border-top: 1px solid var(--rule); font-family: var(--sans); font-size: 1rem; line-height: 1.55; color: var(--ink-2); }
.prose .bio em { font-family: var(--serif); font-size: 1.1em; }
.prose .after { margin-top: 2.2rem; font-family: var(--sans); }
@media (max-width: 900px) {
  .essay { grid-template-columns: 1fr; }
  .brief { position: static; }
}

/* ---------- 404 ---------- */

.lost {
  min-height: 100vh; min-height: 100svh;
  display: grid; align-items: center;
  color: var(--on-night);
  background:
    radial-gradient(60rem 40rem at 90% 10%, rgba(74, 58, 232, 0.55), transparent 62%),
    radial-gradient(40rem 30rem at 0% 100%, rgba(240, 185, 74, 0.12), transparent 60%),
    var(--night);
  padding: 9rem 0 5rem;
}
.lost h1 { font-size: var(--t-h1); font-weight: 700; font-stretch: 78%; line-height: 0.9; letter-spacing: -0.04em; text-wrap: initial; }
.lost h1 span { display: block; }
.lost p { margin: 2rem 0 2.4rem; max-width: 30rem; font-size: var(--t-lead); color: var(--on-night-2); line-height: 1.45; }
.lost__code { color: var(--on-night-3); font-weight: 500; margin-bottom: 1.4rem; }

/* ---------- Motion preferences ---------- */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition-duration: 0.01ms !important; }
  .hero::after { display: none; }
}

@media print {
  .nav, .progress, .lens, .hero::after { display: none !important; }
  .hero, .band--night, .footer, .lost { background: #fff !important; color: #000 !important; }
}

.dossier__photo { width: 84px; height: 84px; border-radius: 50%; object-fit: cover; display: block; margin-bottom: 1rem; border: 2px solid var(--gold); }

/* Single featured book */
.books--single { grid-template-columns: minmax(0, 880px); }
.books--single .book { flex-direction: row; gap: clamp(1.75rem, 4vw, 3rem); align-items: start; }
.books--single .book > a { flex: 0 0 clamp(220px, 26vw, 300px); }
.books--single .book__info { padding-top: 0.5rem; }
.books--single .book__info h3 { font-size: 2rem; }
.books--single .book__info p { font-size: 1.125rem; max-width: 46ch; }
.library-more { margin-top: 2.75rem; color: var(--ink-2); }
@media (max-width: 700px) {
  .books--single .book { flex-direction: column; }
  .books--single .book > a { flex-basis: auto; width: min(240px, 70vw); }
}
