/* ==========================================================================
   REVORA — core styles
   Hybrid luxury system: dark cinematic ↔ light editorial
   ========================================================================== */

:root {
  /* Dark */
  --charcoal: #111315;
  --graphite: #1C2024;
  --black: #08090A;
  /* Light */
  --ivory: #F4F2ED;
  --white: #FFFFFF;
  --grey: #E6E5E1;
  /* Accent */
  --silver: #B9BDC2;
  --gold: #B89A6A;

  --ink: #111315;
  --ink-soft: rgba(17, 19, 21, .62);
  --paper-soft: rgba(244, 242, 237, .66);
  --hair-dark: rgba(255, 255, 255, .14);
  --hair-light: rgba(17, 19, 21, .14);

  --f-head: 'Manrope', system-ui, sans-serif;
  --f-body: 'Inter', system-ui, sans-serif;
  --f-serif: 'Cormorant Garamond', Georgia, serif;

  --gutter: clamp(20px, 4vw, 64px);
  --max: 1520px;
  --ease: cubic-bezier(.22, .8, .2, 1);
  --ease-io: cubic-bezier(.65, 0, .35, 1);
  --nav-h: 68px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: auto; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: hidden; }

body {
  margin: 0;
  font-family: var(--f-body);
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--black);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
body.is-loading { overflow: hidden; }
body.no-scroll { overflow: hidden; }

img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
h1, h2, h3, h4, p, ul, ol, dl, dd, figure { margin: 0; padding: 0; }
ul, ol { list-style: none; }
em { font-family: var(--f-serif); font-style: italic; font-weight: 500; letter-spacing: -.01em; }

:focus-visible { outline: 1.5px solid var(--gold); outline-offset: 4px; }

.skip-link { position: fixed; left: 12px; top: -60px; z-index: 200; padding: 10px 16px; background: var(--ivory); color: var(--ink); font-size: 13px; transition: top .2s; }
.skip-link:focus { top: 12px; }

.container { width: 100%; max-width: var(--max); margin-inline: auto; padding-inline: var(--gutter); }

/* ---- Sections ---- */
.section--dark { background: var(--charcoal); color: var(--ivory); }
.section--graphite { background: var(--graphite); color: var(--ivory); }
.section--black { background: var(--black); color: var(--ivory); }
.section--ivory { background: var(--ivory); color: var(--ink); }
.section--white { background: var(--white); color: var(--ink); }

/* ---- Type ---- */
.label {
  font-family: var(--f-head);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .22em;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  gap: 14px;
  opacity: .8;
}
.label--gold { color: var(--gold); opacity: 1; }
.line { display: inline-block; width: 36px; height: 1px; background: currentColor; opacity: .7; }

.h2 {
  font-family: var(--f-head);
  font-weight: 600;
  font-size: clamp(34px, 5.2vw, 84px);
  line-height: 1.02;
  letter-spacing: -.035em;
  margin-top: 22px;
}

/* Wordmark: REV + ring O + RA */
.wordmark {
  display: inline-flex;
  align-items: center;
  font-family: var(--f-head);
  font-weight: 700;
  font-size: 20px;
  letter-spacing: .34em;
  line-height: 1;
  margin-right: -.34em;
}
.wordmark span { display: inline-block; }
.wordmark__o {
  display: inline-block;
  width: .86em; height: .86em;
  margin: 0 .34em 0 0;
  border-radius: 50%;
  border: .13em solid currentColor;
  position: relative;
}
.wordmark__o::after { /* tachometer needle */
  content: ""; position: absolute; left: 50%; top: 50%;
  width: .32em; height: .08em; background: var(--gold);
  transform-origin: 0 50%; transform: rotate(-38deg);
}
.wordmark--xl { font-size: clamp(34px, 6vw, 84px); }

/* ---- Buttons ---- */
.btn {
  position: relative; overflow: hidden; isolation: isolate;
  display: inline-flex; align-items: center; gap: 14px;
  padding: 16px 28px;
  font-family: var(--f-head); font-size: 11.5px; font-weight: 700;
  letter-spacing: .2em; text-transform: uppercase;
  border: 1px solid currentColor;
  border-radius: 2px;
  transition: color .45s var(--ease), border-color .45s var(--ease);
}
.btn::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: var(--fill, var(--ivory));
  transform: translateY(101%);
  transition: transform .55s var(--ease);
}
.btn svg { transition: transform .45s var(--ease); flex: none; }
.btn:hover svg { transform: translateX(4px); }
.btn:hover::before { transform: translateY(0); }

.btn--solid { background: var(--ivory); color: var(--ink); border-color: var(--ivory); --fill: var(--gold); }
.btn--solid:hover { border-color: var(--gold); }
.btn--line { color: var(--ivory); --fill: var(--ivory); }
.btn--line:hover { color: var(--ink); }
.btn--dark { background: var(--ink); color: var(--ivory); border-color: var(--ink); --fill: var(--gold); }
.btn--dark:hover { color: var(--ink); border-color: var(--gold); }
.btn--nav { padding: 11px 20px; font-size: 10.5px; --fill: var(--ivory); }
.nav .btn--nav:hover { color: var(--ink); }

.icon-btn {
  width: 40px; height: 40px; display: inline-grid; place-items: center;
  border-radius: 50%; border: 1px solid transparent;
  transition: border-color .3s, background .3s;
}
.icon-btn:hover { border-color: currentColor; }

.linklike { font-size: 14px; opacity: .72; text-align: left; transition: opacity .3s; }
.linklike:hover { opacity: 1; }

/* ==========================================================================
   Intro curtain
   ========================================================================== */
.intro {
  position: fixed; inset: 0; z-index: 300; display: grid; place-content: center; justify-items: center; gap: 28px;
  background: var(--black); color: var(--ivory);
}
.intro__mark { font-size: clamp(22px, 3vw, 34px); }
.intro__bar { width: 120px; height: 1px; background: var(--hair-dark); overflow: hidden; }
.intro__bar span { display: block; height: 100%; width: 100%; background: var(--gold); transform: scaleX(0); transform-origin: 0 50%; }
html.no-js .intro { display: none; }

/* ==========================================================================
   Navigation
   ========================================================================== */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 100; height: var(--nav-h);
  color: var(--ivory);
  transition: transform .6s var(--ease), background-color .5s var(--ease), color .4s var(--ease), border-color .4s;
  border-bottom: 1px solid transparent;
}
.nav__inner {
  height: 100%; max-width: var(--max); margin-inline: auto; padding-inline: var(--gutter);
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
}
.nav__brand { justify-self: start; }
.nav__links { display: flex; gap: clamp(22px, 3.4vw, 52px); }
.nav__links a {
  position: relative; font-family: var(--f-head); font-size: 12px; font-weight: 600;
  letter-spacing: .16em; text-transform: uppercase; padding: 8px 0; opacity: .86; transition: opacity .3s;
}
.nav__links a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 2px; height: 1px; background: currentColor;
  transform: scaleX(0); transform-origin: 100% 50%; transition: transform .5s var(--ease);
}
.nav__links a:hover { opacity: 1; }
.nav__links a:hover::after, .nav__links a.is-current::after { transform: scaleX(1); transform-origin: 0 50%; }
.nav__links a.is-current { opacity: 1; }
.nav__actions { justify-self: end; display: flex; align-items: center; gap: 10px; }

/* Scrolled states */
.nav.is-scrolled { background: rgba(8, 9, 10, .82); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-bottom-color: var(--hair-dark); }
.nav.is-light { background: rgba(244, 242, 237, .86); color: var(--ink); border-bottom-color: var(--hair-light); }
.nav.is-light .btn--nav { --fill: var(--ink); }
.nav.is-light .btn--nav:hover { color: var(--ivory); }
.nav.is-hidden { transform: translateY(-100%); }
body.menu-open .nav { transform: none; background: transparent; color: var(--ivory); border-color: transparent; backdrop-filter: none; }

/* Burger */
.burger { display: none; width: 40px; height: 40px; position: relative; }
.burger span { position: absolute; left: 9px; right: 9px; height: 1.5px; background: currentColor; transition: transform .5s var(--ease), top .5s var(--ease); }
.burger span:nth-child(1) { top: 16px; }
.burger span:nth-child(2) { top: 23px; }
.burger[aria-expanded="true"] span:nth-child(1) { top: 20px; transform: rotate(45deg); }
.burger[aria-expanded="true"] span:nth-child(2) { top: 20px; transform: rotate(-45deg); }

/* Mobile menu */
.menu {
  position: fixed; inset: 0; z-index: 90; background: var(--black); color: var(--ivory);
  display: flex; flex-direction: column; justify-content: center; padding: 96px var(--gutter) 48px;
  clip-path: inset(0 0 100% 0); visibility: hidden;
  transition: clip-path .8s var(--ease-io), visibility 0s .8s;
}
.menu.is-open { clip-path: inset(0 0 0 0); visibility: visible; transition: clip-path .8s var(--ease-io), visibility 0s; }
.menu__nav { display: flex; flex-direction: column; gap: 6px; }
.menu__nav a {
  display: flex; align-items: baseline; gap: 18px;
  font-family: var(--f-head); font-weight: 500; font-size: clamp(34px, 10vw, 56px); letter-spacing: -.03em; line-height: 1.15;
  padding: 6px 0; border-bottom: 1px solid var(--hair-dark);
  opacity: 0; transform: translateY(24px);
  transition: opacity .6s var(--ease), transform .7s var(--ease);
}
.menu__nav small { font-size: 11px; letter-spacing: .2em; color: var(--gold); min-width: 26px; }
.menu.is-open .menu__nav a { opacity: 1; transform: none; }
.menu.is-open .menu__nav a:nth-child(1) { transition-delay: .25s; }
.menu.is-open .menu__nav a:nth-child(2) { transition-delay: .32s; }
.menu.is-open .menu__nav a:nth-child(3) { transition-delay: .39s; }
.menu.is-open .menu__nav a:nth-child(4) { transition-delay: .46s; }
.menu.is-open .menu__nav a:nth-child(5) { transition-delay: .53s; }
.menu.is-open .menu__nav a:nth-child(6) { transition-delay: .6s; }
.menu__foot { margin-top: 36px; font-family: var(--f-serif); font-style: italic; font-size: 20px; color: var(--paper-soft); }

/* ==========================================================================
   Hero
   ========================================================================== */
.hero {
  position: relative; min-height: 100vh; min-height: 100svh;
  display: flex; align-items: flex-end; overflow: hidden; isolation: isolate;
}
.hero__media { position: absolute; inset: -6% 0; z-index: -1; will-change: transform; }
.hero__img {
  width: 100%; height: 100%; object-fit: cover; object-position: 50% 58%;
  filter: grayscale(.85) contrast(1.08) brightness(.82);
  transform: scale(1.14); will-change: transform;
}
.hero__shade {
  position: absolute; inset: 0;
  background:
    linear-gradient(180deg, rgba(8,9,10,.62) 0%, rgba(8,9,10,0) 28%, rgba(8,9,10,0) 42%, rgba(8,9,10,.92) 100%),
    linear-gradient(90deg, rgba(8,9,10,.75) 0%, rgba(8,9,10,0) 62%);
}
.hero__content { padding-bottom: clamp(88px, 12vh, 140px); }
.hero__label { margin-bottom: 26px; color: var(--silver); }
.hero__title {
  font-family: var(--f-head); font-weight: 700;
  font-size: clamp(42px, 8.4vw, 136px); line-height: .94; letter-spacing: -.045em;
  text-transform: uppercase; max-width: 12ch;
}
.hero__title em { text-transform: none; font-weight: 500; letter-spacing: -.02em; color: var(--gold); }
.mask { display: block; overflow: hidden; padding-bottom: .08em; margin-bottom: -.08em; }
.mask__in { display: block; will-change: transform; }

.hero__row { margin-top: clamp(28px, 4vh, 48px); display: flex; align-items: center; gap: clamp(24px, 5vw, 80px); flex-wrap: wrap; }
.hero__lede { max-width: 38ch; font-size: clamp(15px, 1.2vw, 18px); color: var(--paper-soft); }

.hero__scroll {
  position: absolute; left: 50%; bottom: 26px; transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: 12px;
  font-family: var(--f-head); font-size: 10px; letter-spacing: .26em; text-transform: uppercase; color: var(--silver);
}
.hero__scroll i { width: 1px; height: 44px; background: var(--hair-dark); position: relative; overflow: hidden; }
.hero__scroll i::after { content: ""; position: absolute; inset: 0; background: var(--ivory); transform: translateY(-100%); animation: scrollcue 2.4s var(--ease-io) infinite; }
.hero__index { position: absolute; right: var(--gutter); bottom: 34px; text-align: right; font-size: 11px; letter-spacing: .18em; text-transform: uppercase; color: var(--silver); line-height: 1.9; }
.hero__index b { font-family: var(--f-serif); font-style: italic; font-weight: 500; font-size: 17px; letter-spacing: 0; text-transform: none; color: var(--ivory); }

/* ==========================================================================
   Featured
   ========================================================================== */
.featured { padding: clamp(96px, 14vw, 200px) 0 clamp(80px, 10vw, 160px); position: relative; }
.featured__head { margin-bottom: clamp(36px, 5vw, 72px); }
.featured__stage { position: relative; max-width: 1760px; margin-inline: auto; padding-inline: var(--gutter); }
.featured__figure { overflow: hidden; aspect-ratio: 16/9; background: var(--charcoal); }
.featured__img { width: 100%; height: 118%; object-fit: cover; object-position: 50% 55%; transition: transform 1.4s var(--ease); will-change: transform; }
.featured__stage:hover .featured__img { transform: scale(1.035); }

.featured__card {
  position: absolute; right: calc(var(--gutter) + clamp(0px, 2vw, 32px)); bottom: -56px;
  width: min(440px, 38vw);
  background: var(--black); color: var(--ivory);
  padding: clamp(26px, 2.6vw, 44px);
  border: 1px solid var(--hair-dark);
}
.featured__name { font-family: var(--f-head); font-weight: 600; font-size: clamp(34px, 3.6vw, 58px); line-height: 1; letter-spacing: -.035em; margin: 14px 0 24px; }
.featured__name small { display: block; font-size: 11px; letter-spacing: .26em; text-transform: uppercase; font-weight: 600; color: var(--silver); margin-bottom: 10px; }
.specs { border-top: 1px solid var(--hair-dark); margin-bottom: 22px; }
.specs div { display: flex; justify-content: space-between; gap: 20px; padding: 11px 0; border-bottom: 1px solid var(--hair-dark); font-size: 13px; }
.specs dt { color: var(--silver); letter-spacing: .08em; text-transform: uppercase; font-size: 11px; font-family: var(--f-head); font-weight: 600; padding-top: 2px; }
.specs dd { text-align: right; }
.featured__text { font-size: 14px; color: var(--paper-soft); margin-bottom: 26px; }

/* ==========================================================================
   Collections
   ========================================================================== */
.collections { padding: clamp(96px, 12vw, 180px) 0; position: relative; }
.collections__headrow { display: grid; grid-template-columns: 1.3fr 1fr; gap: clamp(24px, 6vw, 120px); align-items: end; }
.collections__intro { color: var(--ink-soft); max-width: 44ch; font-size: 16px; padding-bottom: 8px; }
.collections__head { margin-bottom: clamp(48px, 6vw, 96px); }

.grid { display: grid; grid-template-columns: repeat(12, 1fr); gap: clamp(36px, 4vw, 64px) clamp(16px, 2vw, 32px); align-items: start; }
.tile { display: block; position: relative; }
.tile figure { overflow: hidden; background: var(--grey); position: relative; }
.tile img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease); will-change: transform; }
.tile:hover img { transform: scale(1.05); }
.tile__meta { display: grid; grid-template-columns: auto 1fr auto; column-gap: 14px; row-gap: 4px; align-items: baseline; padding-top: 16px; }
.tile__no { font-size: 11px; letter-spacing: .18em; color: var(--gold); font-family: var(--f-head); font-weight: 700; grid-row: 1; }
.tile h3 { font-family: var(--f-head); font-weight: 600; font-size: clamp(20px, 1.8vw, 28px); letter-spacing: -.025em; grid-column: 2; }
.tile__meta p { grid-column: 2; font-size: 14px; color: var(--ink-soft); }
.tile__go { grid-column: 3; grid-row: 1 / span 2; align-self: center; display: inline-flex; align-items: center; gap: 10px; font-family: var(--f-head); font-size: 10.5px; font-weight: 700; letter-spacing: .2em; text-transform: uppercase; }
.tile__go i { width: 26px; height: 1px; background: currentColor; position: relative; transition: width .5s var(--ease); }
.tile__go i::after { content: ""; position: absolute; right: 0; top: -3px; width: 7px; height: 7px; border-top: 1px solid currentColor; border-right: 1px solid currentColor; transform: rotate(45deg); }
.tile:hover .tile__go i { width: 44px; }

/* Editorial composition — varied proportions & offsets */
.tile--a { grid-column: 1 / span 7;  } .tile--a figure { aspect-ratio: 4/3; }
.tile--b { grid-column: 9 / span 4;  margin-top: clamp(40px, 9vw, 150px); } .tile--b figure { aspect-ratio: 3/4; }
.tile--c { grid-column: 2 / span 4;  } .tile--c figure { aspect-ratio: 4/5; }
.tile--d { grid-column: 6 / span 7;  margin-top: clamp(20px, 6vw, 100px); } .tile--d figure { aspect-ratio: 16/10; }
.tile--e { grid-column: 1 / span 5;  } .tile--e figure { aspect-ratio: 1/1; }
.tile--f { grid-column: 7 / span 6;  margin-top: clamp(20px, 5vw, 80px); } .tile--f figure { aspect-ratio: 3/2; }

/* ==========================================================================
   3D Studio
   ========================================================================== */
.studio { padding: clamp(96px, 12vw, 180px) 0; position: relative; overflow: hidden; }
.studio::before { content: ""; position: absolute; inset: 0; background: radial-gradient(70% 60% at 70% 50%, rgba(28,32,36,.9), transparent 70%); pointer-events: none; }
.studio__grid { position: relative; display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.25fr); gap: clamp(32px, 5vw, 96px); align-items: center; }
.studio__title { font-size: clamp(34px, 4.6vw, 76px); }
.studio__text { margin: 28px 0 32px; color: var(--paper-soft); max-width: 42ch; }

.hints { display: flex; gap: 32px; margin-bottom: 36px; padding: 20px 0; border-block: 1px solid var(--hair-dark); }
.hints li { display: flex; align-items: center; gap: 14px; font-size: 13px; color: var(--silver); }
.hints b { display: block; font-family: var(--f-head); font-size: 11px; letter-spacing: .18em; text-transform: uppercase; color: var(--ivory); margin-bottom: 2px; }

.studio__vehicle { margin-bottom: 36px; }
.studio__name { font-family: var(--f-head); font-weight: 500; font-size: 22px; letter-spacing: -.02em; margin: 8px 0 16px; }
.swatches { display: flex; gap: 12px; }
.swatch { width: 28px; height: 28px; border-radius: 50%; background: var(--c); border: 1px solid var(--hair-dark); position: relative; transition: transform .35s var(--ease); }
.swatch::after { content: ""; position: absolute; inset: -5px; border-radius: 50%; border: 1px solid var(--ivory); opacity: 0; transform: scale(.85); transition: opacity .3s, transform .4s var(--ease); }
.swatch:hover { transform: scale(1.08); }
.swatch.is-active::after { opacity: 1; transform: none; }

/* Viewer */
.viewer {
  position: relative; aspect-ratio: 4/3; min-height: 340px; overflow: hidden; background:
    radial-gradient(80% 70% at 50% 40%, #2a3036 0%, #15181b 55%, #0b0c0d 100%);
  border: 1px solid var(--hair-dark);
  touch-action: pan-y;
}
.viewer canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; cursor: grab; opacity: 0; transition: opacity 1.2s var(--ease); touch-action: none; outline: none; }
.viewer canvas:active { cursor: grabbing; }
.viewer[data-state="ready"] canvas { opacity: 1; }
.viewer__status { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 18px; font-size: 12px; letter-spacing: .16em; text-transform: uppercase; color: var(--silver); transition: opacity .6s; pointer-events: none; }
.viewer[data-state="ready"] .viewer__status, .viewer[data-state="fallback"] .viewer__status { opacity: 0; }
.viewer__ring { width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--hair-dark); border-top-color: var(--gold); animation: spin 1s linear infinite; }
.viewer[data-state="idle"] .viewer__ring { animation-play-state: paused; }
.viewer__fallback { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; text-align: center; padding: 32px; color: var(--paper-soft); font-size: 14px; }
.viewer__fallback[hidden] { display: none; }
.viewer__fallback p { max-width: 36ch; }
.viewer__controls { position: absolute; left: 16px; bottom: 16px; display: flex; gap: 6px; opacity: 0; transition: opacity .6s; }
.viewer[data-state="ready"] .viewer__controls { opacity: 1; }
.viewer__controls .icon-btn { border-color: var(--hair-dark); background: rgba(8,9,10,.5); backdrop-filter: blur(6px); }
.viewer__controls .icon-btn:hover { background: var(--ivory); color: var(--ink); }
.viewer__controls .icon-btn[aria-pressed="false"] { opacity: .55; }
.viewer__exit { display: none !important; }
.viewer__credit { position: absolute; right: 14px; bottom: 12px; font-size: 10px; letter-spacing: .06em; color: rgba(255,255,255,.4); max-width: 46%; text-align: right; pointer-events: none; }

.viewer.is-expanded { position: fixed; inset: 0; z-index: 150; aspect-ratio: auto; border: 0; }
.viewer.is-expanded .viewer__exit { display: inline-grid !important; position: absolute; }
.viewer.is-expanded .viewer__controls { left: 50%; transform: translateX(-50%); bottom: 28px; }
.viewer.is-expanded .viewer__exit { position: fixed; top: 20px; right: 20px; }

/* ==========================================================================
   Heritage
   ========================================================================== */
.heritage { padding: clamp(96px, 12vw, 180px) 0; position: relative; }
.heritage__head { margin-bottom: clamp(40px, 5vw, 80px); }
.heritage__grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: clamp(28px, 5vw, 96px); align-items: stretch; }
.heritage__stage { position: relative; aspect-ratio: 4/3; background: var(--grey); overflow: hidden; }
.stage__fig { position: absolute; inset: 0; clip-path: inset(0 0 0 100%); transition: clip-path 1.1s var(--ease-io); }
.stage__fig.is-active { clip-path: inset(0 0 0 0); z-index: 2; }
.stage__fig.is-prev { clip-path: inset(0 0 0 0); z-index: 1; }
.stage__fig img { width: 100%; height: 100%; object-fit: cover; filter: sepia(.18) contrast(1.04) saturate(.9); transform: scale(1.06); transition: transform 2.4s var(--ease); }
.stage__fig.is-active img { transform: scale(1); }
.heritage__cap { position: absolute; left: 0; bottom: 0; z-index: 5; padding: 10px 16px; background: var(--ivory); font-size: 11px; font-family: var(--f-head); font-weight: 700; letter-spacing: .16em; text-transform: uppercase; }

.legends { display: flex; flex-direction: column; border-top: 1px solid var(--hair-light); }
.legend { width: 100%; display: grid; grid-template-columns: 40px 1fr; column-gap: 8px; text-align: left; padding: 22px 0; border-bottom: 1px solid var(--hair-light); position: relative; transition: padding .5s var(--ease), color .3s; color: var(--ink-soft); }
.legend__no { font-size: 11px; font-family: var(--f-head); font-weight: 700; letter-spacing: .18em; color: var(--gold); padding-top: 9px; }
.legend__name { font-family: var(--f-head); font-weight: 600; letter-spacing: -.03em; font-size: clamp(24px, 2.8vw, 42px); line-height: 1.1; transition: color .3s; }
.legend__note { grid-column: 2; font-size: 14px; max-height: 0; opacity: 0; overflow: hidden; transition: max-height .6s var(--ease), opacity .5s, margin .5s; max-width: 40ch; }
.legend:hover { color: var(--ink); }
.legend.is-active { color: var(--ink); padding-bottom: 28px; }
.legend.is-active .legend__note { max-height: 120px; opacity: 1; margin-top: 10px; color: var(--ink-soft); }
.legend::after { content: ""; position: absolute; left: 0; bottom: -1px; height: 1px; width: 100%; background: var(--ink); transform: scaleX(0); transform-origin: 0 50%; transition: transform .7s var(--ease); }
.legend.is-active::after { transform: scaleX(1); }

.heritage__cta { margin-top: clamp(40px, 5vw, 72px); display: flex; align-items: center; justify-content: space-between; gap: 28px; flex-wrap: wrap; }
.heritage__cta p { font-family: var(--f-serif); font-style: italic; font-size: clamp(20px, 2vw, 30px); max-width: 30ch; line-height: 1.25; }

/* ==========================================================================
   Journal
   ========================================================================== */
.journal { padding: clamp(96px, 12vw, 180px) 0; }
.journal__head { margin-bottom: clamp(40px, 5vw, 80px); }
.journal__grid { display: grid; grid-template-columns: 1.15fr 1fr; gap: clamp(32px, 5vw, 96px); align-items: start; }
.lead a { display: block; }
.lead figure { overflow: hidden; aspect-ratio: 4/5; background: var(--grey); margin-bottom: 24px; }
.lead figure img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease); }
.lead a:hover img, .item a:hover img { transform: scale(1.04); }
.lead h3 { font-family: var(--f-head); font-weight: 600; font-size: clamp(26px, 3vw, 46px); letter-spacing: -.03em; line-height: 1.06; margin: 12px 0 14px; max-width: 18ch; }
.lead p:last-of-type { color: var(--ink-soft); max-width: 46ch; margin-bottom: 20px; }
.read { display: inline-flex; align-items: center; gap: 10px; font-family: var(--f-head); font-size: 10.5px; font-weight: 700; letter-spacing: .2em; text-transform: uppercase; }
.read i { width: 24px; height: 1px; background: currentColor; transition: width .5s var(--ease); }
a:hover > .read i, a:hover .read i { width: 42px; }

.journal__list { display: flex; flex-direction: column; }
.item { border-top: 1px solid var(--hair-light); }
.item:last-child { border-bottom: 1px solid var(--hair-light); }
.item a { display: grid; grid-template-columns: clamp(110px, 12vw, 190px) 1fr; gap: clamp(16px, 2vw, 28px); padding: 22px 0; align-items: center; }
.item figure { overflow: hidden; aspect-ratio: 4/3; background: var(--grey); }
.item img { width: 100%; height: 100%; object-fit: cover; transition: transform 1s var(--ease); }
.item h3 { font-family: var(--f-head); font-weight: 600; font-size: clamp(17px, 1.5vw, 23px); letter-spacing: -.02em; line-height: 1.2; margin: 8px 0 12px; }
.item .label { color: var(--gold); opacity: 1; }

/* ==========================================================================
   Footer
   ========================================================================== */
.footer { padding-top: clamp(72px, 9vw, 140px); }
.footer__top { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: clamp(28px, 4vw, 72px); padding-bottom: clamp(48px, 6vw, 96px); }
.footer__brand p { color: var(--paper-soft); max-width: 40ch; margin-top: 28px; font-size: 14px; }
.footer__brand .footer__tag { font-family: var(--f-serif); font-style: italic; font-size: 24px; color: var(--gold); margin-top: 22px; }
.footer__col { display: flex; flex-direction: column; gap: 12px; align-items: flex-start; }
.footer__col .label { margin-bottom: 10px; color: var(--silver); }
.footer__col a { font-size: 14px; opacity: .72; transition: opacity .3s, transform .4s var(--ease); }
.footer__col a:hover { opacity: 1; transform: translateX(4px); }
.footer__credits { border-top: 1px solid var(--hair-dark); padding-block: 20px; font-size: 12px; color: var(--silver); }
.footer__credits summary { cursor: pointer; letter-spacing: .1em; text-transform: uppercase; font-family: var(--f-head); font-size: 10.5px; font-weight: 600; }
.footer__credits ul { columns: 2; column-gap: 40px; margin-top: 16px; line-height: 1.9; }
.footer__bottom { display: flex; justify-content: space-between; gap: 16px; padding-block: 22px 30px; border-top: 1px solid var(--hair-dark); font-size: 12px; color: var(--silver); }

/* ==========================================================================
   Dialogs, toast
   ========================================================================== */
dialog { border: 0; padding: 0; color: inherit; background: none; max-width: none; max-height: none; }
dialog::backdrop { background: rgba(8, 9, 10, .72); backdrop-filter: blur(6px); }

.search { width: 100%; margin: 0; top: 0; background: var(--black); color: var(--ivory); }
.search[open] { animation: dropIn .6s var(--ease); }
.search__form { max-width: 860px; margin: 0 auto; padding: 120px var(--gutter) 56px; }
.search__field { display: flex; align-items: center; gap: 12px; border-bottom: 1px solid var(--hair-dark); margin-top: 18px; }
.search__field input { flex: 1; background: none; border: 0; outline: 0; color: inherit; font-family: var(--f-head); font-size: clamp(26px, 4vw, 48px); letter-spacing: -.03em; padding: 14px 0; min-width: 0; }
.search__field input::placeholder { color: rgba(255,255,255,.28); }
.search__results { margin-top: 24px; }
.search__results li a { display: flex; justify-content: space-between; gap: 16px; padding: 16px 0; border-bottom: 1px solid var(--hair-dark); font-family: var(--f-head); font-size: 20px; font-weight: 500; letter-spacing: -.02em; transition: padding .4s var(--ease), color .3s; }
.search__results li a small { font-size: 11px; letter-spacing: .18em; text-transform: uppercase; color: var(--gold); align-self: center; }
.search__results li a:hover, .search__results li a:focus-visible { padding-left: 12px; }
.search__empty { padding: 18px 0; color: var(--silver); font-size: 14px; }

.sheet { width: min(980px, calc(100% - 32px)); margin: auto; background: var(--ivory); color: var(--ink); }
.sheet[open] { display: grid; grid-template-columns: 1fr 1fr; animation: sheetIn .7s var(--ease); }
.sheet__media { background: var(--grey); min-height: 320px; }
.sheet__media img { width: 100%; height: 100%; object-fit: cover; }
.sheet__body { position: relative; padding: clamp(28px, 4vw, 56px); display: flex; flex-direction: column; justify-content: center; gap: 16px; }
.sheet__close { position: absolute; top: 12px; right: 12px; }
.sheet__title { font-family: var(--f-head); font-weight: 600; font-size: clamp(26px, 3vw, 42px); letter-spacing: -.03em; line-height: 1.05; }
.sheet__text { color: var(--ink-soft); font-size: 15px; }
.sheet__note { font-size: 12px; color: var(--ink-soft); padding-top: 14px; border-top: 1px solid var(--hair-light); }
.sheet .btn--line { color: var(--ink); --fill: var(--ink); align-self: flex-start; }
.sheet .btn--line:hover { color: var(--ivory); }

.toast { position: fixed; left: 50%; bottom: 28px; z-index: 400; transform: translate(-50%, 24px); opacity: 0; padding: 14px 22px; background: var(--ivory); color: var(--ink); font-size: 13px; pointer-events: none; transition: opacity .4s, transform .6s var(--ease); }
.toast.is-on { opacity: 1; transform: translate(-50%, 0); }

.journal__all { margin-top: clamp(40px, 5vw, 72px); }
