/* EHTTI — layout concept: one fixed screen. Sky at the back, the Earth in front of
   it, then two paper sheets (EHTTI from the left, R&D from the right) that are laid
   on top of each other like folders. Heritage pulls both sheets aside and brings
   the Earth to the middle. */
:root {
  color-scheme: dark;

  /* colour */
  --space: #05060d;          /* the sky */
  --paper: #f5f2ea;          /* ivory marble: the sheet on top, ribbon */
  --paper-back: #dbd4c4;     /* the sheet underneath */
  --paper-lift: #fcfaf5;     /* a tab under the pointer */
  --slot: #e7e1d3;           /* placeholder blocks */
  --rule: #ded6c4;
  --ink: #1f1a2c;
  --ink-soft: #5e574a;
  --gold: #b08a3a;           /* inlay lines, bullets, underlines */
  --gold-deep: #7a5d1c;      /* gold when it has to be read as text */
  --gold-line: rgba(176, 138, 58, 0.62);
  --violet: #4b2a7a;         /* from the EHTTI seal */
  --atmo: #86c6ff;           /* the atmosphere; used only on dark */
  --on-space: #f4f6ff;

  /* type */
  --display: "Marcellus", "Cinzel", "Trajan Pro", Georgia, serif;
  --body: "Manrope", "Segoe UI", system-ui, -apple-system, Arial, sans-serif;

  /* layout */
  --g: clamp(8px, 1.1vw, 16px);                       /* gap between sheets and screen edge */
  --ribbon-h: 46px;
  --top: calc(var(--g) + var(--ribbon-h));            /* bottom edge of the floating ribbon */
  --peek-h: max(10vh, calc(var(--tab-h) + 18px));     /* Heritage: how much of the bottom sheet waits on screen */
  --hero-h: min(clamp(150px, 30vw, 400px), 40vh);     /* band where the Earth shows as a dome */
  --tab-h: 46px;
  --tab-w: clamp(92px, 24%, 340px);                   /* side tabs while their sheet is in place */
  --tab-w-away: clamp(66px, 9vw, 124px);              /* side tabs parked at the screen edge */
  --rest: calc(var(--hero-h) - var(--tab-h) - var(--g));  /* how far below the ribbon the sheets rest */
  --lift: 0px;                                        /* how far scrolling has raised them (set by app.js) */
  --peek: 12px;                                       /* how far the lower sheet shows above the top one */
  --radius: 12px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --move: 0.95s;
}

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

html, body { height: 100%; }
html { background: var(--space); }
body {
  margin: 0;
  overflow: hidden;
  background: var(--space);
  color: var(--ink);
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
a { color: inherit; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--atmo); outline-offset: 3px; border-radius: 4px; }
.sheet :focus-visible, .more :focus-visible, .ribbon :focus-visible, .drawer :focus-visible { outline-color: var(--gold-deep); }

.app { position: relative; height: 100%; overflow: hidden; background: var(--space); }

/* ---------- layer 0: sky ---------- */
.sky {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
  object-position: 50% 50%;
  pointer-events: none;
  user-select: none;
}

/* ---------- layer 1: the Earth ---------- */
.stage {
  position: absolute;
  inset: 0;
  z-index: 1;
  touch-action: none;
  cursor: grab;
}
.stage.dragging { cursor: grabbing; }
.earth { position: absolute; inset: 0; width: 100%; height: 100%; display: block; opacity: calc(1 - var(--sink, 0)); }
.stage.over-region { cursor: pointer; }
.earth-fallback {
  position: absolute;
  left: var(--fb-left, 50%);
  top: var(--fb-top, 30px);
  width: var(--fb-size, 800px);
  height: var(--fb-size, 800px);
  max-width: none;
  border-radius: 50%;
  object-fit: cover;
  box-shadow: 0 0 0 2px rgba(134, 198, 255, 0.35), 0 0 46px 10px rgba(134, 198, 255, 0.28);
  transition: left var(--move) var(--ease), top var(--move) var(--ease), width var(--move) var(--ease), height var(--move) var(--ease);
}
/* the planet falls into shadow where the sheets meet it */
.shade {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(var(--top) + var(--hero-h) - 120px);
  height: 120px;
  background: linear-gradient(to bottom, rgba(5, 6, 13, 0), rgba(5, 6, 13, 0.85));
  pointer-events: none;
  transition: opacity 0.6s;
}
.mode-heritage:not(.more-open) .shade { opacity: 0; }

/* ---------- layer 2: sheets ---------- */
.stack {
  position: absolute;
  z-index: 2;
  left: var(--g);
  right: var(--g);
  top: calc(var(--top) + var(--g));                   /* as high as the sheets can go: just under the ribbon */
  bottom: var(--g);
  pointer-events: none;
}
/* everything in here rests lower down and rises as the open sheet is scrolled */
.tablist { position: absolute; inset: 0; transform: translateY(calc(var(--rest) - var(--lift))); }
.settling .tablist { transition: transform 0.6s var(--ease); }
.settling .earth { transition: opacity 0.6s var(--ease); }
.probe { position: absolute; left: 0; top: 0; width: 0; height: var(--rest); visibility: hidden; pointer-events: none; }

.sheet {
  --tone: var(--paper);
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  transform-origin: 50% 0;
  transition: transform var(--move) var(--ease), filter 0.6s var(--ease);
}

/* on top */
.sheet[data-state="front"] {
  z-index: 2;
  filter: drop-shadow(0 -4px 14px rgba(0, 0, 0, 0.55));
}
/* underneath: a little higher, a little smaller, in the top sheet's shadow */
.sheet[data-state="back"] {
  --tone: var(--paper-back);
  z-index: 1;
  transform: translateY(calc(-1 * var(--peek))) scale(0.988);
  filter: drop-shadow(0 -2px 8px rgba(0, 0, 0, 0.35));
}
/* pulled aside for Heritage: the sheet leaves the screen, its tab stays at the edge */
.sheet[data-state="away"] { filter: drop-shadow(0 4px 14px rgba(0, 0, 0, 0.55)); }
.sheet[data-state="away"][data-side="left"] { transform: translateX(calc(-100% - var(--g) - 40px)); }
.sheet[data-state="away"][data-side="right"] { transform: translateX(calc(100% + var(--g) + 40px)); }

/* a sheet being laid on top of the other one */
.sheet.is-landing[data-side="left"] { animation: land-left 0.9s both; }
.sheet.is-landing[data-side="right"] { animation: land-right 0.9s both; }
@keyframes land-left {
  0% { z-index: 0; opacity: 1; transform: translateY(calc(-1 * var(--peek))) scale(0.988); animation-timing-function: ease-in; }
  13% { z-index: 0; opacity: 0; transform: translateY(0) scale(0.988); animation-timing-function: step-end; }
  14% { z-index: 3; opacity: 0; transform: translate(-7%, -34px) rotate(-1.1deg) scale(1.02); filter: drop-shadow(0 44px 46px rgba(0, 0, 0, 0.7)); animation-timing-function: cubic-bezier(0.22, 1, 0.36, 1); }
  34% { opacity: 1; }
  100% { z-index: 3; opacity: 1; transform: none; filter: drop-shadow(0 -4px 14px rgba(0, 0, 0, 0.55)); }
}
@keyframes land-right {
  0% { z-index: 0; opacity: 1; transform: translateY(calc(-1 * var(--peek))) scale(0.988); animation-timing-function: ease-in; }
  13% { z-index: 0; opacity: 0; transform: translateY(0) scale(0.988); animation-timing-function: step-end; }
  14% { z-index: 3; opacity: 0; transform: translate(7%, -34px) rotate(1.1deg) scale(1.02); filter: drop-shadow(0 44px 46px rgba(0, 0, 0, 0.7)); animation-timing-function: cubic-bezier(0.22, 1, 0.36, 1); }
  34% { opacity: 1; }
  100% { z-index: 3; opacity: 1; transform: none; filter: drop-shadow(0 -4px 14px rgba(0, 0, 0, 0.55)); }
}

/* the tab is part of its sheet */
.sheet-tab {
  position: absolute;
  top: 0;
  width: var(--tab-w);
  height: calc(var(--tab-h) + 1px);
  display: grid;
  place-items: center;
  padding: 0 8px;
  background: var(--tone);
  color: var(--ink);
  pointer-events: auto;
  transition:
    transform var(--move) var(--ease),
    width var(--move) var(--ease),
    border-radius var(--move) var(--ease),
    background-color 0.5s;
  -webkit-tap-highlight-color: transparent;
}
[data-side="left"] > .sheet-tab { left: 0; border-radius: var(--radius) var(--radius) 0 0; }
[data-side="right"] > .sheet-tab { right: 0; border-radius: var(--radius) var(--radius) 0 0; }

/* concave foot on the inner side, as on a file folder */
.sheet-tab::after {
  content: "";
  position: absolute;
  bottom: 1px;
  width: 10px;
  height: 10px;
  background: var(--tone);
  transition: background-color 0.5s, opacity 0.4s;
}
[data-side="left"] > .sheet-tab::after {
  left: 100%;
  -webkit-mask: radial-gradient(circle at 100% 0, transparent 9.5px, #000 10px);
  mask: radial-gradient(circle at 100% 0, transparent 9.5px, #000 10px);
}
[data-side="right"] > .sheet-tab::after {
  right: 100%;
  -webkit-mask: radial-gradient(circle at 0 0, transparent 9.5px, #000 10px);
  mask: radial-gradient(circle at 0 0, transparent 9.5px, #000 10px);
}

/* parked: the tab hugs the screen edge while its sheet is off screen */
[data-state="away"][data-side="left"] > .sheet-tab {
  width: var(--tab-w-away);
  transform: translateX(calc(var(--stack-w, 100vw) + 40px));
  border-radius: 0 var(--radius) var(--radius) 0;
}
[data-state="away"][data-side="right"] > .sheet-tab {
  width: var(--tab-w-away);
  transform: translateX(calc(-1 * var(--stack-w, 100vw) - 40px));
  border-radius: var(--radius) 0 0 var(--radius);
}
[data-state="away"] > .sheet-tab::after { opacity: 0; }

.sheet:not([data-state="front"]) > .sheet-tab:hover { background-color: var(--paper-lift); }
.sheet[data-state="front"] > .sheet-tab { cursor: default; }

.label {
  position: relative;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-family: var(--display);
  font-size: 14px;
  letter-spacing: 0.22em;
  text-indent: 0.22em;
  text-transform: uppercase;
  line-height: 1.2;
  padding: 7px 0;
}
.label::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 0;
  width: 30px;
  height: 2px;
  margin-left: -15px;
  border-radius: 2px;
  background: var(--gold);
  transform: scaleX(0);
  transition: transform 0.6s var(--ease) 0.15s;
}
.sheet-tab[aria-selected="true"] .label::after { transform: scaleX(1); }

.sheet-body {
  position: absolute;
  top: var(--tab-h);
  left: 0;
  right: 0;
  bottom: 0;                                          /* a fixed size: it reaches below the screen until raised */
  overflow: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: var(--rule) transparent;
  background: var(--tone);
  color: var(--ink);
  pointer-events: auto;
  transition: background-color 0.5s;
}
.sheet-body:focus { outline: none; }
[data-side="left"] .sheet-body { border-radius: 0 var(--radius) var(--radius) var(--radius); }
[data-side="right"] .sheet-body { border-radius: var(--radius) 0 var(--radius) var(--radius); }

/* Heritage: an open label over the planet; becomes the title when active */
.heritage-tab {
  position: absolute;
  z-index: 5;
  top: 0;
  left: 50%;
  height: var(--tab-h);
  padding: 0 22px;
  display: grid;
  place-items: center;
  color: var(--on-space);
  pointer-events: auto;
  transform: translateX(-50%);
  transition: transform var(--move) var(--ease);
  -webkit-tap-highlight-color: transparent;
}
.heritage-tab .label {
  letter-spacing: 0.3em;
  text-indent: 0.3em;
  font-size: 15px;
  text-shadow: 0 1px 14px rgba(0, 0, 0, 0.95), 0 0 2px rgba(0, 0, 0, 0.8);
  opacity: 0.86;
  transition: opacity 0.3s;
}
.heritage-tab:hover .label { opacity: 1; }
.heritage-tab .label::after { background: var(--atmo); box-shadow: 0 0 12px var(--atmo); }
.heritage-tab[aria-selected="true"] {
  cursor: default;
  transform: translateX(-50%) translateY(calc(-1 * (var(--hero-h) - var(--tab-h)) + 14px)) scale(1.4);
}
.heritage-tab[aria-selected="true"] .label { opacity: 1; }
.heritage-tab[aria-selected="true"] .label::after { transform: scaleX(1); }

/* ---------- placeholder content (layout only) ---------- */
/* while the sheet is still rising, its content rides with it; after that it scrolls */
.skeleton { transform: translateY(var(--lift)); }
.sheet-body::after, .more-body::after { content: ""; display: block; height: var(--pad-end, 0px); }   /* room to rise fully and to read past the footer */
.tablist, .skeleton { will-change: transform; }
.skeleton {
  display: flex;
  flex-direction: column;
  gap: clamp(26px, 4vw, 44px);
  padding: clamp(24px, 4.5vw, 56px) clamp(18px, 5vw, 72px);
  max-width: 1280px;
  margin-inline: auto;
}
.topic {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  column-gap: clamp(24px, 4vw, 64px);
  row-gap: 16px;
}
.topic.has-image {
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.42fr);
  grid-template-areas: "head image" "body image";
  grid-template-rows: auto 1fr;
}
.topic.has-image h2 { grid-area: head; }
.topic.has-image .slot-content { grid-area: body; }
.topic.has-image .slot-image { grid-area: image; }

h2 {
  margin: 0;
  justify-self: start;
  position: relative;
  padding: 0 4px 7px 22px;
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(19px, 2.2vw, 23px);
  line-height: 1.25;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border-bottom: 2px solid var(--gold);
}
h2::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 0.42em;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gold);
}

.slot {
  display: grid;
  place-items: center;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
.slot span { padding: 4px 12px; border-radius: 4px; background: var(--tone, var(--paper)); transition: background-color 0.5s; }
.slot-content {
  min-height: clamp(96px, 16vh, 150px);
  margin-left: 22px;
  background: repeating-linear-gradient(to bottom, var(--slot) 0 10px, transparent 10px 28px);
  background-position: 0 6px;
}
.slot-image {
  min-height: 150px;
  border: 1.5px dashed #b0a58a;
  text-align: center;
}
.slot-image span { background: none; }

/* ---------- layer 3: info ribbon ---------- */
.ribbon {
  position: absolute;
  top: calc(var(--g) + env(safe-area-inset-top, 0px));
  left: var(--g);
  right: var(--g);
  z-index: 30;
  height: var(--ribbon-h);
  border-radius: var(--radius);
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding-inline: clamp(16px, 2vw, 24px);
  background: var(--paper);
  color: var(--ink);
  box-shadow: 0 6px 22px rgba(0, 0, 0, 0.6), inset 0 0 0 1px var(--gold-line);
}
.menu-btn {
  width: 36px;
  height: 36px;
  margin-left: -8px;
  display: grid;
  place-content: center;
  gap: 4px;
  border-radius: 8px;
}
.menu-btn span {
  display: block;
  width: 20px;
  height: 2px;
  border-radius: 2px;
  background: var(--ink);
  transition: transform 0.35s var(--ease), opacity 0.2s;
}
.menu-btn[aria-expanded="true"] span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.menu-btn[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu-btn[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

.ribbon-info {
  margin: 0;
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  text-align: center;
  font-family: var(--display);
  font-size: 13px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--ink-soft);
}
.lang { display: flex; gap: 2px; margin-right: -6px; }
.lang button {
  min-width: 36px;
  height: 30px;
  padding: 0 8px;
  border-radius: 7px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--ink-soft);
  transition: background 0.25s, color 0.25s;
}
.lang button:hover { color: var(--ink); }
.lang button[aria-pressed="true"] { background: var(--ink); color: var(--paper); }

/* ---------- menu drawer ---------- */
.scrim {
  position: absolute;
  inset: 0;
  z-index: 24;
  background: rgba(3, 4, 10, 0.55);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s;
}
.scrim.on { opacity: 1; pointer-events: auto; }
.drawer {
  position: absolute;
  top: calc(var(--top) + var(--g) + env(safe-area-inset-top, 0px));
  left: var(--g);
  bottom: var(--g);
  border-radius: var(--radius);
  z-index: 26;
  width: min(360px, 88vw);
  padding: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--paper);
  color: var(--ink);
  box-shadow: 0 14px 44px rgba(0, 0, 0, 0.6);
  transform: translateX(calc(-100% - var(--g) - 40px));
  visibility: hidden;
  transition: transform 0.45s var(--ease), visibility 0.45s;
}
.drawer.open { transform: none; visibility: visible; }
.drawer-scroll { flex: 1; min-height: 0; overflow: auto; overscroll-behavior: contain; scrollbar-width: thin; scrollbar-color: var(--rule) transparent; padding: 24px clamp(16px, 2vw, 24px) 20px; display: flex; flex-direction: column; gap: 18px; }
.brand-row { display: flex; align-items: center; gap: 14px; }
.seal { flex: none; width: 54px; height: 54px; border-radius: 50%; filter: drop-shadow(0 2px 4px rgba(40, 20, 60, 0.35)); }
.drawer-brand { font-family: var(--display); font-weight: 400; font-size: 22px; letter-spacing: 0.24em; }
.brand-sub { margin: 2px 0 0; font-size: 11.5px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-soft); }
.slogan { margin: 0; font-family: var(--display); font-size: 15px; line-height: 1.5; color: var(--gold-deep); }
.drawer-sec h4 { margin: 0 0 10px; font-size: 11px; font-weight: 700; letter-spacing: 0.18em; text-transform: uppercase; color: var(--gold-deep); }
.zone-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.zone-chips button { padding: 5px 10px; border-radius: 999px; font-size: 12.5px; color: var(--ink); box-shadow: inset 0 0 0 1px var(--gold-line); transition: background-color 0.2s, box-shadow 0.2s; }
.zone-chips button:hover, .zone-chips button:focus-visible { background: var(--paper-lift); box-shadow: inset 0 0 0 1px var(--gold); }
.zone-chips button.sea { color: #2f5f86; box-shadow: inset 0 0 0 1px rgba(47, 95, 134, 0.45); }
.contact-line { font-size: 14px; color: var(--ink); text-decoration-color: var(--gold-line); }
.social { margin: 8px 0 0; display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 13px; }
.social a, .foot-col a, .legal-links a { color: var(--ink-soft); text-decoration: none; transition: color 0.2s; }
.social a:hover, .foot-col a:hover, .legal-links a:hover { color: var(--gold-deep); }
.fine { margin: auto 0 0; padding-top: 10px; border-top: 1px solid var(--rule); font-size: 11.5px; letter-spacing: 0.08em; color: var(--ink-soft); }
.drawer-nav { display: flex; flex-direction: column; border-top: 1px solid var(--rule); }
.drawer-nav a {
  padding: 12px 2px;
  border-bottom: 1px solid var(--rule);
  font-family: var(--display);
  font-size: 15px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  text-decoration: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: color 0.2s, padding-left 0.3s var(--ease);
}
.drawer-nav a::after { content: "\2192"; font-family: var(--body); letter-spacing: 0; color: var(--ink-soft); }
.drawer-nav a > span { display: flex; flex-direction: column; gap: 3px; }
.drawer-nav b { font-weight: 400; }
.drawer-nav small { font-family: var(--body); font-size: 12px; letter-spacing: 0.01em; text-transform: none; color: var(--ink-soft); }
.drawer-nav a:hover { color: var(--gold-deep); padding-left: 8px; }
.drawer-nav a[aria-current="true"] { color: var(--gold-deep); }

/* ---------- Heritage: the sheet that waits along the bottom ---------- */
.more {
  --tone: var(--paper);
  position: absolute;
  inset: 0;
  z-index: 6;
  pointer-events: none;
  transform: translateY(calc(100% + var(--g) + 60px));          /* out of sight outside Heritage */
  filter: drop-shadow(0 -4px 16px rgba(0, 0, 0, 0.6));
  transition: transform var(--move) var(--ease);
}
.mode-heritage .more { transform: translateY(calc(100% + var(--g) - var(--peek-h) - var(--rest))); }
.mode-heritage.more-open .more { transform: none; }

.more-tab {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  margin-inline: auto;
  width: clamp(150px, 26%, 360px);
  height: calc(var(--tab-h) + 1px);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 0 12px;
  background: var(--tone);
  color: var(--ink);
  border-radius: var(--radius) var(--radius) 0 0;
  pointer-events: auto;
  transition: background-color 0.3s;
  -webkit-tap-highlight-color: transparent;
}
.more-tab:hover { background-color: var(--paper-lift); }
.more-tab::before, .more-tab::after {
  content: "";
  position: absolute;
  bottom: 1px;
  width: 10px;
  height: 10px;
  background: var(--tone);
}
.more-tab::before {
  right: 100%;
  -webkit-mask: radial-gradient(circle at 0 0, transparent 9.5px, #000 10px);
  mask: radial-gradient(circle at 0 0, transparent 9.5px, #000 10px);
}
.more-tab::after {
  left: 100%;
  -webkit-mask: radial-gradient(circle at 100% 0, transparent 9.5px, #000 10px);
  mask: radial-gradient(circle at 100% 0, transparent 9.5px, #000 10px);
}
.more-open .more-tab .label::after { transform: scaleX(1); }
.chev {
  width: 9px;
  height: 9px;
  margin-top: 4px;
  border-left: 2px solid var(--gold);
  border-top: 2px solid var(--gold);
  transform: rotate(45deg);
  transition: transform 0.5s var(--ease), margin 0.5s var(--ease);
}
.more-open .chev { transform: rotate(225deg); margin-top: -5px; }
.more-body {
  position: absolute;
  top: var(--tab-h);
  left: 0;
  right: 0;
  bottom: 0;
  overflow: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: var(--rule) transparent;
  background: var(--tone);
  color: var(--ink);
  border-radius: var(--radius);
  pointer-events: auto;
}
.more-body:focus { outline: none; }
.mode-heritage:not(.more-open) .more-body { overflow: hidden; }

/* gold inlay along the top edge of every tab */
.sheet-tab, .more-tab { box-shadow: inset 0 2px 0 var(--gold-line); }
.drawer { box-shadow: 0 14px 44px rgba(0, 0, 0, 0.6), inset 0 0 0 1px var(--gold-line); }

/* ---------- the paper: ivory marble with gold veins and a faint inlaid map ---------- */
.ribbon, .drawer, .sheet-tab, .sheet-body, .more-tab, .more-body, .site-foot {
  background-image: url("assets/paper.jpg");
  background-size: 760px 760px;
  background-blend-mode: multiply;
}
.sheet-body, .more-body { background-position: 0 -46px; }
[data-side="right"] > .sheet-tab { background-position: right 0 top 0; }
.more-tab { background-position: center top; }

/* ---------- narrow screens ---------- */
@media (max-width: 760px) {
  .topic.has-image {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas: "head" "image" "body";
    grid-template-rows: auto;
  }
  .slot-image { min-height: 120px; }
}
@media (max-width: 560px) {
  :root { --tab-h: 42px; --radius: 10px; --peek: 7px; }
  .label { font-size: 11.5px; letter-spacing: 0.14em; text-indent: 0.14em; }
  .heritage-tab { padding: 0 10px; }
  .heritage-tab .label { font-size: 12px; letter-spacing: 0.2em; text-indent: 0.2em; }
  .slot-content { margin-left: 0; }
}

.no-anim *, .no-anim *::before, .no-anim *::after { transition: none !important; animation: none !important; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
}

/* ---------- Heritage: landmarks standing on the globe ---------- */
.marks { position: absolute; inset: 0; pointer-events: none; opacity: 0; transition: opacity 0.6s; }
.marks-on .marks { opacity: 1; transition-delay: 0.5s; }
.mark {
  position: absolute;
  left: 0;
  top: 0;
  width: 40px;
  height: 40px;
  padding: 0;
  border-radius: 50%;
  opacity: 0;
  pointer-events: none;
  will-change: transform;
  display: grid;
  place-items: end center;
}
.mark[hidden] { display: none; }
.mark:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
/* without 3D graphics a small gold pin marks each wonder */
.mark .pin { width: 14px; height: 14px; margin-bottom: 4px; border-radius: 50% 50% 50% 0; rotate: -45deg; background: radial-gradient(circle at 40% 40%, #ffe7a6, #c99a36 60%, #7a5717); box-shadow: 0 2px 4px rgba(0, 0, 0, 0.5); }
.mark.mark-n .pin { background: radial-gradient(circle at 40% 40%, #dff4c8, #6fa04a 60%, #2f5a2c); }
.has-3d .mark .pin { display: none; }

.hover-tip {
  position: absolute;
  left: 0;
  top: 0;
  z-index: 3;
  margin: 0;
  padding: 6px 12px 7px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
  translate: -50% -100%;
  border-radius: 8px;
  background: var(--paper) url("assets/paper.jpg") 0 0 / 760px 760px;
  background-blend-mode: multiply;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.5), inset 0 0 0 1px var(--gold-line);
  color: var(--ink);
  white-space: nowrap;
  pointer-events: none;
}
.hover-tip strong { font-family: var(--display); font-weight: 400; font-size: 14px; letter-spacing: 0.14em; text-transform: uppercase; }
.hover-tip span { font-size: 12px; color: var(--ink-soft); }

.globe-hint {
  position: absolute;
  left: 50%;
  top: calc(var(--top) + 70px);
  margin: 0;
  translate: -50% 0;
  font-size: 12px;
  letter-spacing: 0.08em;
  color: rgba(244, 246, 255, 0.62);
  white-space: nowrap;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.5s;
}
.mode-heritage:not(.more-open):not(.region-open) .globe-hint { opacity: 1; transition-delay: 0.9s; }
.mode-heritage.zoomed .globe-hint { opacity: 0; transition-delay: 0s; }

/* ---------- Heritage: the story of a region ---------- */
.region {
  --tone: var(--paper);
  position: absolute;
  z-index: 8;
  top: calc(var(--top) + var(--g));
  right: var(--g);
  bottom: var(--g);
  width: min(40vw, 540px);
  border-radius: var(--radius);
  background: var(--paper) url("assets/paper.jpg") 0 0 / 760px 760px;
  background-blend-mode: multiply;
  color: var(--ink);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.6), inset 0 0 0 1px var(--gold-line);
  transform: translateX(calc(100% + var(--g) + 60px));
  transition: transform var(--move) var(--ease) 0.12s;
  overflow: hidden;
}
.region-open .region { transform: none; }
.region-inner {
  height: 100%;
  overflow: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: var(--rule) transparent;
  padding: clamp(22px, 3vw, 40px);
  display: flex;
  flex-direction: column;
  gap: 22px;
}
.region.swap .region-inner > * { animation: region-in 0.7s var(--ease) both; }
.region.swap .region-inner > :nth-child(2) { animation-delay: 0.08s; }
.region.swap .region-inner > :nth-child(3) { animation-delay: 0.16s; }
.region.swap .region-inner > :nth-child(n+4) { animation-delay: 0.24s; }
@keyframes region-in { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.region-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.region .kicker { margin: 0; font-size: 12px; font-weight: 700; letter-spacing: 0.2em; text-transform: uppercase; color: var(--gold-deep); }
.region-close {
  padding: 7px 12px;
  border-radius: 8px;
  font-size: 13px;
  color: var(--ink-soft);
  box-shadow: inset 0 0 0 1px var(--gold-line);
  transition: background-color 0.2s, color 0.2s;
}
.region-close:hover { background: var(--paper-lift); color: var(--ink); }
.region-head { display: flex; align-items: center; gap: 18px; }
.region-emblem { flex: none; width: 96px; height: 96px; border-radius: 50%; display: grid; place-items: center; box-shadow: inset 0 0 0 1px var(--gold-line), 0 0 0 5px rgba(176, 138, 58, 0.08); }
.region-emblem img { width: 100%; height: 100%; object-fit: contain; }
.region-emblem.empty { background: radial-gradient(circle, rgba(176, 138, 58, 0.14), transparent 70%); }
.region-title { margin: 0; font-family: var(--display); font-weight: 400; font-size: clamp(26px, 2.6vw, 34px); line-height: 1.15; text-wrap: balance; }
.region-coords { margin: 6px 0 0; font-size: 12.5px; letter-spacing: 0.08em; color: var(--ink-soft); font-variant-numeric: tabular-nums; }
.region-text { margin: 0; font-size: 16px; line-height: 1.7; max-width: 60ch; }
.region .slot-content { margin-left: 0; }
.region-nav { margin-top: auto; padding-top: 16px; border-top: 1px solid var(--rule); display: flex; justify-content: space-between; gap: 12px; }
.region-nav button { padding: 8px 12px; border-radius: 8px; font-size: 13px; letter-spacing: 0.06em; color: var(--ink-soft); transition: background-color 0.2s, color 0.2s; }
.region-nav button:hover { background: var(--paper-lift); color: var(--ink); }

/* while a region is open the side tabs and the bottom sheet step back */
.region-open .more { transform: translateY(calc(100% + var(--g) + 60px)) !important; }
.sheet-tab { transition: transform var(--move) var(--ease), width var(--move) var(--ease), border-radius var(--move) var(--ease), background-color 0.5s, opacity 0.4s; }
.region-open .sheet[data-state="away"] > .sheet-tab { opacity: 0; pointer-events: none; }

@media (max-width: 759px) {
  .region { top: auto; left: var(--g); width: auto; height: 54%; transform: translateY(calc(100% + var(--g) + 40px)); }
  .region-inner { gap: 16px; }
  .region-emblem { width: 58px; height: 58px; }
  .region-emblem { width: 70px; height: 70px; }
  .globe-hint { font-size: 11px; white-space: normal; text-align: center; width: calc(100% - 40px); }
}

/* the panel carries its own title, so the Heritage title steps aside */
.heritage-tab { transition: transform var(--move) var(--ease), opacity 0.4s; }
.region-open .heritage-tab { opacity: 0; pointer-events: none; }
@media (max-width: 560px) {
  .more-tab { width: clamp(190px, 56%, 360px); }
}

/* ---------- under-construction notice in the ribbon ---------- */
.ribbon-info span { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.warn { flex: none; width: 21px; height: 19px; overflow: visible; }
.warn path { fill: #f4c21b; stroke: #6b4f00; stroke-width: 1.2; stroke-linejoin: round; }
.warn .bang { fill: none; stroke: #2a2100; stroke-width: 2.2; stroke-linecap: round; }
.warn .dot { fill: #2a2100; }
@media (max-width: 760px) { .ribbon-info { gap: 7px; } .warn { width: 17px; height: 15px; } }

.ribbon-info .info-short { display: none; }
@media (max-width: 560px) {
  .ribbon-info .info-long { display: none; }
  .ribbon-info .info-short { display: inline; }
  .ribbon-info { letter-spacing: 0.12em; }
}

/* ---------- 3D landmarks laid over the globe ---------- */
.earth3d { position: absolute; inset: 0; width: 100%; height: 100%; display: block; pointer-events: none; opacity: 0; transition: opacity 0.6s; }
.marks-on .earth3d { opacity: 1; transition-delay: 0.5s; }
@media (max-width: 560px) {
  .ribbon-info { letter-spacing: 0.06em; font-size: 10.5px; gap: 5px; }
  .warn { width: 15px; height: 13px; }
}

/* ---------- Heritage panel: a continent or ocean, then its wonders ---------- */
.region.is-zone .wonder-only { display: none; }
.region.is-wonder .zone-list { display: none; }
.region-badge { margin: 8px 0 0; display: inline-flex; align-items: center; gap: 7px; font-size: 11.5px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-soft); }
.region-badge:empty { display: none; }
.region-badge::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 0 2px rgba(176, 138, 58, 0.2); }
.region-badge.badge-n::before { background: #5f9a3e; box-shadow: 0 0 0 2px rgba(95, 154, 62, 0.2); }
.region-badge.badge-legend::before { background: #7c63b8; box-shadow: 0 0 0 2px rgba(124, 99, 184, 0.2); }
.zone-list { display: flex; flex-direction: column; gap: 10px; }
.zone-list h4 { margin: 8px 0 0; font-size: 12px; font-weight: 700; letter-spacing: 0.18em; text-transform: uppercase; color: var(--gold-deep); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 13px 8px 11px; border-radius: 999px;
  font-size: 14px; line-height: 1.2; color: var(--ink); text-align: left;
  background: rgba(255, 255, 255, 0.32);
  box-shadow: inset 0 0 0 1px var(--gold-line);
  transition: background-color 0.2s, box-shadow 0.2s, transform 0.2s var(--ease);
}
.chip:hover, .chip:focus-visible { background: var(--paper-lift); box-shadow: inset 0 0 0 1px var(--gold); transform: translateY(-1px); }
.chip .dot { flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--gold); }
.chip-n .dot { background: #5f9a3e; }
.zone-empty { margin: 0; font-size: 14px; color: var(--ink-soft); font-style: italic; }
.region-nav { align-items: center; }
.region-count { font-size: 12.5px; letter-spacing: 0.1em; color: var(--ink-soft); font-variant-numeric: tabular-nums; }
.region-nav button:disabled { opacity: 0.35; pointer-events: none; }

/* ---------- smooth scrolling: where the browser supports scroll-driven animations, the sheet rises with the
   scroll position itself (on the compositor), so it never lags or steps behind the finger ---------- */
@keyframes sheet-rise { from { transform: translateY(var(--rest)); } to { transform: translateY(0); } }
@keyframes sheet-ride { from { transform: translateY(0); } to { transform: translateY(var(--rest)); } }
@keyframes planet-sink { from { opacity: 1; } to { opacity: 0; } }
@supports (animation-timeline: scroll()) {
  .sdt { timeline-scope: --sc-ehtti, --sc-rd, --sc-more; }
  .sdt #panel-ehtti { scroll-timeline: --sc-ehtti block; }
  .sdt #panel-rd { scroll-timeline: --sc-rd block; }
  .sdt #morePanel { scroll-timeline: --sc-more block; }
  .sdt.on-ehtti .tablist, .sdt.on-rd .tablist, .sdt.more-open .tablist,
  .sdt #panel-ehtti > .skeleton, .sdt #panel-rd > .skeleton, .sdt #morePanel > .skeleton,
  .sdt.on-ehtti .earth, .sdt.on-rd .earth, .sdt.more-open .earth { animation-duration: auto; animation-timing-function: linear; animation-fill-mode: both; animation-range: 0px var(--rest); }
  .sdt.on-ehtti .tablist, .sdt.on-rd .tablist, .sdt.more-open .tablist { animation-name: sheet-rise; }
  .sdt #panel-ehtti > .skeleton, .sdt #panel-rd > .skeleton, .sdt #morePanel > .skeleton { animation-name: sheet-ride; }
  .sdt.on-ehtti .earth, .sdt.on-rd .earth, .sdt.more-open .earth { animation-name: planet-sink; animation-range: calc(var(--rest) * 0.25) calc(var(--rest) * 0.85); }
  .sdt.on-ehtti .tablist, .sdt.on-ehtti .earth, .sdt #panel-ehtti > .skeleton { animation-timeline: --sc-ehtti; }
  .sdt.on-rd .tablist, .sdt.on-rd .earth, .sdt #panel-rd > .skeleton { animation-timeline: --sc-rd; }
  .sdt.more-open .tablist, .sdt.more-open .earth, .sdt #morePanel > .skeleton { animation-timeline: --sc-more; }
  .sdt.settling .tablist, .sdt.settling .earth, .sdt.settling .skeleton { animation: none !important; }
}

/* ---------- the footer ribbon ---------- */
.site-foot {
  position: absolute;
  z-index: 20;
  left: var(--g);
  right: var(--g);
  bottom: calc(var(--g) + env(safe-area-inset-bottom, 0px));
  max-height: calc(100% - var(--top) - 3 * var(--g));
  overflow: auto;
  border-radius: var(--radius);
  background-color: var(--paper);
  color: var(--ink);
  box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.55), inset 0 0 0 1px var(--gold-line), inset 0 2px 0 var(--gold-line);
  padding: clamp(18px, 2.4vw, 28px) clamp(18px, 3vw, 40px) 14px;
  transform: translateY(calc(100% + var(--g) + 40px));
  visibility: hidden;
  transition: transform 0.55s var(--ease), visibility 0.55s;
}
.foot-on .site-foot { transform: none; visibility: visible; }
.foot-grid { display: grid; grid-template-columns: minmax(0, 1.6fr) repeat(3, minmax(0, 1fr)); gap: 18px clamp(18px, 3vw, 44px); }
.foot-brand { display: flex; align-items: flex-start; gap: 14px; }
.foot-brand .seal { width: 58px; height: 58px; }
.foot-brand strong { display: block; font-family: var(--display); font-weight: 400; font-size: 21px; letter-spacing: 0.24em; }
.foot-brand span { display: block; margin-top: 2px; font-size: 11.5px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-soft); }
.foot-brand em { display: block; margin-top: 8px; font-family: var(--display); font-style: normal; font-size: 14px; line-height: 1.45; color: var(--gold-deep); }
.foot-col { display: flex; flex-direction: column; gap: 7px; font-size: 13.5px; }
.foot-col h4 { margin: 2px 0 4px; font-size: 11px; font-weight: 700; letter-spacing: 0.18em; text-transform: uppercase; color: var(--gold-deep); }
.foot-col .social { margin: 2px 0 0; font-size: 12.5px; }
.foot-legal { margin-top: 16px; padding-top: 12px; border-top: 1px solid var(--rule); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 18px; font-size: 11.5px; letter-spacing: 0.06em; color: var(--ink-soft); }
.legal-links { display: flex; gap: 16px; }
@media (max-width: 860px) {
  .foot-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .foot-brand { grid-column: 1 / -1; }
}
@media (max-width: 560px) {
  .site-foot { padding: 16px 16px 10px; }
  .foot-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 16px; }
  .foot-brand .seal { width: 46px; height: 46px; }
  .foot-brand strong { font-size: 18px; }
  .foot-brand em { font-size: 13px; margin-top: 5px; }
  .foot-col { font-size: 13px; gap: 5px; }
  .foot-col:last-child { grid-column: 1 / -1; }
  .foot-legal { margin-top: 12px; font-size: 11px; }
}

/* ---------- the pages: EHTTI, R&D and Heritage's "More info" ---------- */
.page { gap: clamp(40px, 6vw, 76px); max-width: 1120px; }
.page p { margin: 0; }
.page h3 { margin: 0; font-family: var(--display); font-weight: 400; font-size: clamp(19px, 1.9vw, 22px); line-height: 1.25; letter-spacing: 0.02em; }
.kick { font-size: 12px; font-weight: 700; letter-spacing: 0.22em; text-transform: uppercase; color: var(--gold-deep); }
.display { margin: 14px 0 0; font-family: var(--display); font-weight: 400; font-size: clamp(38px, 6.2vw, 72px); line-height: 1.04; letter-spacing: 0.01em; text-wrap: balance; }
.lead { margin-top: 20px !important; max-width: 46ch; font-size: clamp(17px, 1.7vw, 20px); line-height: 1.6; color: var(--ink-soft); text-wrap: pretty; }
.hero { padding-top: clamp(6px, 2vw, 24px); }
.hero-sm .display { font-size: clamp(34px, 5vw, 58px); }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 13px 20px; border-radius: 999px;
  font: 600 14.5px/1 var(--body); letter-spacing: 0.02em; text-decoration: none;
  background: var(--ink); color: var(--paper);
  box-shadow: 0 6px 18px rgba(31, 26, 44, 0.22);
  transition: transform 0.25s var(--ease), box-shadow 0.25s, background-color 0.25s;
}
.btn .arr { transition: transform 0.25s var(--ease); }
.btn:hover { transform: translateY(-1px); box-shadow: 0 10px 24px rgba(31, 26, 44, 0.28); }
.btn:hover .arr { transform: translateX(3px); }
.btn-ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--gold-line); }
.btn-ghost:hover { background: var(--paper-lift); box-shadow: inset 0 0 0 1.5px var(--gold); }
.btn.soon { cursor: default; }
.btn.soon:hover { transform: none; }
.fine-note { margin-top: 14px !important; font-size: 12.5px; color: var(--ink-soft); }
.block > h2 { margin-bottom: 26px; }
.block p + p { margin-top: 14px; }
.block > p, .split-text p, .proj-intro { font-size: 16.5px; line-height: 1.75; max-width: 64ch; }

/* why Type I: text beside the scale */
.split { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr); gap: clamp(28px, 5vw, 72px); align-items: center; }
.split-text h2 { margin-bottom: 24px; }
.kscale { margin: 0; padding: 26px 22px 18px; border-radius: var(--radius); background: rgba(255, 255, 255, 0.34); box-shadow: inset 0 0 0 1px var(--gold-line); }
.ks-track { position: relative; height: 10px; margin: 44px 4px 0; border-radius: 99px; background: linear-gradient(90deg, #e5dcc7, #d8ccb0); box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.15); }
.ks-fill { position: absolute; inset: 0 27% 0 0; border-radius: 99px; background: linear-gradient(90deg, #8a6a2a, var(--gold) 70%, #d9b45a); }
.ks-mark { position: absolute; left: 73%; top: 50%; }
.ks-dot { position: absolute; left: -9px; top: -9px; width: 18px; height: 18px; border-radius: 50%; background: var(--paper); box-shadow: 0 0 0 3px var(--gold), 0 2px 6px rgba(0, 0, 0, 0.3); }
.ks-label { position: absolute; bottom: 16px; left: 0; translate: -50% 0; white-space: nowrap; font-size: 12.5px; font-weight: 700; letter-spacing: 0.04em; color: var(--gold-deep); }
.ks-ticks { display: flex; justify-content: space-between; margin: 10px 0 0; font-family: var(--display); font-size: 15px; color: var(--ink-soft); }
.ks-goal { color: var(--gold-deep); font-size: 18px; }
.kscale figcaption { margin-top: 14px; font-size: 12.5px; line-height: 1.5; color: var(--ink-soft); }

/* what we are building */
.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(14px, 2vw, 22px); }
.card {
  position: relative; display: flex; flex-direction: column; gap: 12px;
  padding: 24px 22px 26px; border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.36);
  box-shadow: inset 0 0 0 1px var(--gold-line);
  cursor: pointer;
  transition: transform 0.3s var(--ease), box-shadow 0.3s, background-color 0.3s;
}
.card:hover, .card:focus-visible { transform: translateY(-3px); background: rgba(255, 255, 255, 0.58); box-shadow: inset 0 0 0 1px var(--gold), 0 14px 30px rgba(60, 45, 20, 0.14); outline: none; }
.card p { font-size: 15px; line-height: 1.65; color: var(--ink-soft); }
.card-more { margin-top: auto; padding-top: 4px; color: var(--gold-deep); transition: transform 0.3s var(--ease); }
.card:hover .card-more { transform: translateX(4px); }
.card-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.card-cat { font-size: 11.5px; font-weight: 700; letter-spacing: 0.18em; text-transform: uppercase; color: var(--gold-deep); }
.ico { width: 46px; height: 46px; fill: none; stroke: var(--gold-deep); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.status { display: inline-flex; align-items: center; gap: 6px; padding: 4px 9px; border-radius: 99px; font-size: 11px; font-weight: 700; letter-spacing: 0.06em; white-space: nowrap; }
.status::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.status-dev { color: #8a6418; background: rgba(217, 164, 60, 0.16); }
.status-live { color: #3f7a2e; background: rgba(95, 154, 62, 0.16); }
.status-live::before { box-shadow: 0 0 0 3px rgba(95, 154, 62, 0.25); }

/* what guides us */
.principles { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 26px clamp(24px, 4vw, 56px); }
.principles li { display: flex; gap: 18px; align-items: flex-start; }
.principles .num { flex: none; width: 44px; height: 44px; display: grid; place-items: center; border-radius: 50%; font-family: var(--display); font-size: 15px; color: var(--gold-deep); box-shadow: inset 0 0 0 1px var(--gold-line); }
.principles p { margin-top: 6px; font-size: 15px; line-height: 1.65; color: var(--ink-soft); }

/* the slogan */
.quote-band { padding: clamp(10px, 2vw, 20px) 0; text-align: center; }
.quote { margin: 0 auto !important; max-width: 30ch; font-family: var(--display); font-size: clamp(22px, 3vw, 34px); line-height: 1.35; color: var(--gold-deep); text-wrap: balance; }
.quote-band::before, .quote-band::after { content: ""; display: block; width: 64px; height: 1px; margin: 0 auto; background: var(--gold); }
.quote-band::before { margin-bottom: 24px; }
.quote-band::after { margin-top: 24px; }

/* follow the journey */
.cta-card { padding: clamp(26px, 4vw, 44px); border-radius: var(--radius); background: rgba(255, 255, 255, 0.34); box-shadow: inset 0 0 0 1px var(--gold-line); }
.cta-card .cta-row { margin-top: 22px; }

/* R&D projects */
.project { padding-top: 6px; }
.proj-head { display: flex; align-items: center; gap: 18px; margin-bottom: 22px; }
.proj-head .ico { width: 54px; height: 54px; }
.proj-head > div { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; }
.proj-head h2 { margin: 0; }
.aims { list-style: none; margin: 24px 0 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.aims li { display: flex; flex-direction: column; gap: 3px; padding: 14px 16px 14px 18px; border-radius: 10px; background: rgba(255, 255, 255, 0.32); box-shadow: inset 2px 0 0 var(--gold); font-size: 14.5px; line-height: 1.5; color: var(--ink-soft); }
.aims strong { color: var(--ink); font-size: 15px; }
.two-col .aims { grid-template-columns: minmax(0, 1fr); }
.now { margin-top: 22px !important; display: flex; flex-wrap: wrap; gap: 4px 12px; font-size: 14.5px; color: var(--ink-soft); }
.now strong { font-size: 11.5px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--gold-deep); padding-top: 2px; }
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; counter-reset: step; }
.steps li { counter-increment: step; display: flex; flex-direction: column; gap: 6px; padding: 18px 16px; border-top: 2px solid var(--gold); font-size: 14.5px; line-height: 1.55; color: var(--ink-soft); }
.steps li::before { content: counter(step, upper-roman); font-family: var(--display); font-size: 14px; color: var(--gold-deep); }
.steps strong { font-family: var(--display); font-weight: 400; font-size: 19px; color: var(--ink); }
.stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: 28px; }
.stat { display: flex; flex-direction: column; gap: 6px; padding: 18px 18px 20px; border-radius: var(--radius); background: rgba(255, 255, 255, 0.34); box-shadow: inset 0 0 0 1px var(--gold-line); }
.stat-n { font-family: var(--display); font-size: clamp(34px, 4vw, 46px); line-height: 1; color: var(--gold-deep); }
.stat-l { font-size: 14px; line-height: 1.45; color: var(--ink-soft); }
.two-col { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(28px, 4vw, 56px); }
.two-col h2 { margin-bottom: 22px; }
.two-col p { font-size: 15.5px; line-height: 1.7; }

@media (max-width: 900px) {
  .cards { grid-template-columns: minmax(0, 1fr); }
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 760px) {
  .split, .two-col { grid-template-columns: minmax(0, 1fr); }
  .principles, .aims { grid-template-columns: minmax(0, 1fr); }
  .stats { grid-template-columns: minmax(0, 1fr); }
  .stat { flex-direction: row; align-items: baseline; gap: 14px; }
}
@media (max-width: 560px) {
  .steps { grid-template-columns: minmax(0, 1fr); }
  .btn { padding: 12px 17px; font-size: 14px; }
}

/* ---------- "not active yet" ---------- */
.warn-s { width: 15px; height: 13px; flex: none; }
.soon { display: inline-flex; align-items: center; gap: 7px; }
.foot-col a.soon, .drawer a.soon { color: var(--ink-soft); cursor: default; }
.soon-note { margin: 4px 0 0; font-size: 11.5px; color: var(--ink-soft); font-style: italic; }
.contact-line { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; font-size: 14px; text-decoration: none; }

/* ---------- when the footer is up, the open page ends above it, with the same gap as everywhere else ---------- */
.site-foot { box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5), inset 0 0 0 1px var(--gold-line), inset 0 2px 0 var(--gold-line); }

/* ---------- privacy, terms and cookies ---------- */
.legal-scrim { position: absolute; inset: 0; z-index: 40; background: rgba(3, 4, 10, 0.6); opacity: 0; pointer-events: none; transition: opacity 0.35s; }
.legal-open .legal-scrim { opacity: 1; pointer-events: auto; }
.legal {
  position: absolute; z-index: 41;
  left: 50%; top: calc(var(--top) + var(--g));
  bottom: calc(var(--g) + env(safe-area-inset-bottom, 0px));
  width: min(760px, calc(100% - 2 * var(--g)));
  display: flex; flex-direction: column;
  border-radius: var(--radius);
  background: var(--paper) url("assets/paper.jpg") 0 0 / 760px 760px; background-blend-mode: multiply;
  color: var(--ink);
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.6), inset 0 0 0 1px var(--gold-line);
  transform: translate(-50%, 24px); opacity: 0; visibility: hidden;
  transition: transform 0.45s var(--ease), opacity 0.35s, visibility 0.45s;
}
.legal-open .legal { transform: translate(-50%, 0); opacity: 1; visibility: visible; }
.legal-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 16px 12px 20px; border-bottom: 1px solid var(--rule); }
.legal-tabs { display: flex; gap: 4px; padding: 3px; border-radius: 10px; box-shadow: inset 0 0 0 1px var(--gold-line); }
.legal-tabs button { padding: 7px 14px; border-radius: 8px; font-size: 13px; font-weight: 600; color: var(--ink-soft); }
.legal-tabs button[aria-selected="true"] { background: var(--ink); color: var(--paper); }
.legal-close { width: 36px; height: 36px; border-radius: 50%; font-size: 22px; line-height: 1; color: var(--ink-soft); box-shadow: inset 0 0 0 1px var(--gold-line); }
.legal-close:hover { background: var(--paper-lift); color: var(--ink); }
.legal-body { flex: 1; min-height: 0; overflow: auto; overscroll-behavior: contain; padding: 26px clamp(20px, 4vw, 44px) 36px; scrollbar-width: thin; scrollbar-color: var(--rule) transparent; }
.legal-body:focus { outline: none; }
.legal-body h2 { margin-bottom: 8px; }
.legal-date { margin: 0 0 18px; font-size: 12.5px; color: var(--ink-soft); }
.legal-body h3 { margin: 22px 0 6px; font-family: var(--display); font-weight: 400; font-size: 18px; }
.legal-body p { margin: 0 0 10px; font-size: 15px; line-height: 1.7; max-width: 68ch; }
.legal-body table { width: 100%; margin: 6px 0 10px; border-collapse: collapse; font-size: 13.5px; }
.legal-body th, .legal-body td { padding: 8px 10px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--rule); }
.legal-body th { font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--gold-deep); }
@media (max-width: 560px) { .legal-tabs button { padding: 7px 10px; font-size: 12.5px; } .legal-body table { font-size: 12.5px; } }
.page h2 { width: fit-content; max-width: 100%; }
.proj-head h2 { padding-left: 4px; }
.proj-head h2::before { display: none; }
.legal-body td:first-child { white-space: nowrap; }
@media (max-width: 560px) {
  .block > p, .split-text p, .proj-intro { font-size: 15.5px; line-height: 1.7; }
  .lead { font-size: 16.5px; }
}

/* ---------- a wonder's page: turntable, facts, one note ---------- */
.region.is-wonder .region-emblem { display: none; }
.viewer { position: relative; margin: 0; height: clamp(190px, 30vh, 280px); border-radius: var(--radius); overflow: hidden;
  background: radial-gradient(ellipse at 50% 70%, rgba(176, 138, 58, 0.16), transparent 65%), linear-gradient(180deg, rgba(255, 255, 255, 0.4), rgba(214, 200, 168, 0.28));
  box-shadow: inset 0 0 0 1px var(--gold-line); }
.viewer canvas { display: block; width: 100%; height: 100%; cursor: grab; touch-action: pan-y; }
.viewer canvas:active { cursor: grabbing; }
.viewer figcaption { position: absolute; left: 12px; bottom: 9px; font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-soft); pointer-events: none; }
#app:not(.has-3d) .viewer { display: none; }
.facts h4, .note h4 { margin: 0 0 10px; font-size: 11.5px; font-weight: 700; letter-spacing: 0.18em; text-transform: uppercase; color: var(--gold-deep); }
.facts dl { margin: 0; display: grid; grid-template-columns: max-content minmax(0, 1fr); border-top: 1px solid var(--rule); }
.facts dt, .facts dd { margin: 0; padding: 9px 0; border-bottom: 1px solid var(--rule); font-size: 14px; line-height: 1.5; }
.facts dt { padding-right: 18px; font-size: 11.5px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-soft); padding-top: 11px; }
.facts dd { color: var(--ink); }
.note { padding: 16px 18px 17px; border-radius: var(--radius); background: rgba(255, 255, 255, 0.36); box-shadow: inset 3px 0 0 var(--gold), inset 0 0 0 1px var(--gold-line); }
.note p { margin: 0; font-size: 14.5px; line-height: 1.65; }
.note h4::before { content: ""; display: inline-block; width: 13px; height: 13px; margin-right: 8px; vertical-align: -2px;
  background: currentColor; -webkit-mask: var(--note-icon) center / contain no-repeat; mask: var(--note-icon) center / contain no-repeat; }
.note-sci { --note-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.4' stroke-linecap='round'%3E%3Ccircle cx='10' cy='10' r='6.5'/%3E%3Cpath d='m15 15 6 6'/%3E%3C/svg%3E"); }
.note-know { --note-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.4' stroke-linecap='round'%3E%3Cpath d='M9 18h6M10 21h4M12 3a6 6 0 0 0-3.5 10.9c.8.6 1.5 1.6 1.5 2.6V17h4v-.5c0-1 .7-2 1.5-2.6A6 6 0 0 0 12 3z'/%3E%3C/svg%3E"); }
@media (max-width: 560px) {
  .viewer { height: 180px; }
  .facts dl { grid-template-columns: minmax(0, 1fr); }
  .facts dt { padding-bottom: 0; border-bottom: 0; }
  .facts dd { padding-top: 3px; }
}
.viewer, .facts, .note { flex: none; }

/* =====================================================================================
   v22 · depth and motion
   Every panel floats over what is below it: a lit top, a soft gold inlay, an inner
   shade at the foot, and shadows that grow softer and wider the further they fall.
   No hard edges — only light and shadow.
   ===================================================================================== */
:root {
  --gold-light: #f0d68e;
  --paper-light: linear-gradient(180deg, rgba(255, 255, 255, 0.62) 0%, rgba(252, 249, 242, 0.36) 34%, rgba(246, 240, 226, 0.26) 100%);
  --wash: linear-gradient(rgba(251, 248, 240, 0.3), rgba(251, 248, 240, 0.3));
  --float: inset 0 1px 0 rgba(255, 255, 255, 0.95), inset 0 0 0 1px rgba(176, 138, 58, 0.55), inset 0 -12px 20px -16px rgba(110, 85, 40, 0.4),
    0 6px 7px rgba(0, 0, 0, 0.32), 0 18px 28px -8px rgba(0, 0, 0, 0.55), 0 38px 64px -22px rgba(0, 0, 0, 0.65);
  --raised: inset 0 1px 0 rgba(255, 255, 255, 0.85), inset 0 0 0 1px var(--gold-line),
    0 2px 3px rgba(70, 52, 20, 0.14), 0 10px 22px -10px rgba(70, 52, 20, 0.35);
  --sheet-shadow: drop-shadow(0 -1px 0 rgba(255, 255, 255, 0.4)) drop-shadow(0 0 1px rgba(0, 0, 0, 0.75)) drop-shadow(0 -8px 12px rgba(0, 0, 0, 0.38)) drop-shadow(0 -26px 40px rgba(0, 0, 0, 0.5));
  --sheet-shadow-back: drop-shadow(0 0 1px rgba(0, 0, 0, 0.6)) drop-shadow(0 -6px 12px rgba(0, 0, 0, 0.35));
}
/* phones: the same look with fewer blurs, so scrolling stays smooth */
@media (max-width: 760px), (pointer: coarse) {
  :root {
    --sheet-shadow: drop-shadow(0 0 1px rgba(0, 0, 0, 0.75)) drop-shadow(0 -10px 18px rgba(0, 0, 0, 0.5));
    --sheet-shadow-back: drop-shadow(0 -4px 10px rgba(0, 0, 0, 0.35));
  }
}

/* ---------- the marble: lit from above ---------- */
.ribbon, .drawer, .region, .legal, .site-foot, .hover-tip {
  background-color: var(--paper);
  background-image: var(--paper-light), url("assets/paper.jpg");
  background-size: 100% 100%, 760px 760px;
  background-blend-mode: normal, multiply;
}
.sheet-tab, .more-tab {
  background-image: linear-gradient(180deg, rgba(255, 255, 255, 0.42), rgba(255, 255, 255, 0) 70%), var(--wash), url("assets/paper.jpg");
  background-size: 100% 100%, 100% 100%, 760px 760px;
  background-blend-mode: normal, normal, multiply;
}
.sheet-body, .more-body {
  background-image: var(--wash), url("assets/paper.jpg");
  background-size: 100% 100%, 760px 760px;
  background-blend-mode: normal, multiply;
  background-position: 0 0, 0 -46px;
}
[data-side="right"] > .sheet-tab { background-position: 0 0, 0 0, right 0 top 0; }
.more-tab { background-position: 0 0, 0 0, center top; }

/* ---------- floating panels ---------- */
.ribbon, .drawer, .region, .legal { box-shadow: var(--float); }
.hover-tip { box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.95), inset 0 0 0 1px rgba(176, 138, 58, 0.55), 0 4px 6px rgba(0, 0, 0, 0.35), 0 14px 24px -8px rgba(0, 0, 0, 0.6); }
.site-foot {
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.95), inset 0 0 0 1px rgba(176, 138, 58, 0.55), inset 0 -12px 20px -16px rgba(110, 85, 40, 0.4),
    0 -4px 8px rgba(0, 0, 0, 0.3), 0 -18px 30px -10px rgba(0, 0, 0, 0.5), 0 10px 30px rgba(0, 0, 0, 0.45);
}

/* ---------- the sheets: they lie on top of the planet, and on top of each other ---------- */
.sheet[data-state="front"] { filter: var(--sheet-shadow); }
.sheet[data-state="back"] { filter: var(--sheet-shadow-back); }
.sheet[data-state="away"] { filter: drop-shadow(0 0 1px rgba(0, 0, 0, 0.7)) drop-shadow(0 8px 18px rgba(0, 0, 0, 0.5)); }
.more { filter: var(--sheet-shadow); }
@keyframes land-left {
  0% { z-index: 0; opacity: 1; transform: translateY(calc(-1 * var(--peek))) scale(0.988); animation-timing-function: ease-in; }
  13% { z-index: 0; opacity: 0; transform: translateY(0) scale(0.988); animation-timing-function: step-end; }
  14% { z-index: 3; opacity: 0; transform: translate(-7%, -34px) rotate(-1.1deg) scale(1.02); filter: drop-shadow(0 0 1px rgba(0, 0, 0, 0.6)) drop-shadow(0 44px 46px rgba(0, 0, 0, 0.7)); animation-timing-function: cubic-bezier(0.22, 1, 0.36, 1); }
  34% { opacity: 1; }
  100% { z-index: 3; opacity: 1; transform: none; filter: var(--sheet-shadow); }
}
@keyframes land-right {
  0% { z-index: 0; opacity: 1; transform: translateY(calc(-1 * var(--peek))) scale(0.988); animation-timing-function: ease-in; }
  13% { z-index: 0; opacity: 0; transform: translateY(0) scale(0.988); animation-timing-function: step-end; }
  14% { z-index: 3; opacity: 0; transform: translate(7%, -34px) rotate(1.1deg) scale(1.02); filter: drop-shadow(0 0 1px rgba(0, 0, 0, 0.6)) drop-shadow(0 44px 46px rgba(0, 0, 0, 0.7)); animation-timing-function: cubic-bezier(0.22, 1, 0.36, 1); }
  34% { opacity: 1; }
  100% { z-index: 3; opacity: 1; transform: none; filter: var(--sheet-shadow); }
}
/* the tab's lit top edge and its gold inlay */
.sheet-tab, .more-tab { box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.95), inset 0 2px 0 rgba(176, 138, 58, 0.45); }
/* the sheet underneath sits in the shadow of the one on top: darker towards where it disappears under it */
.sheet-tab::before { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; opacity: 0; transition: opacity 0.5s;
  background: linear-gradient(180deg, transparent 40%, rgba(60, 44, 18, 0.14)); }
.sheet[data-state="back"] > .sheet-tab::before { opacity: 1; }
.sheet[data-state="back"] > .sheet-tab .label { color: var(--ink-soft); transition: color 0.3s; }
.sheet[data-state="back"] > .sheet-tab:hover { transform: translateY(-4px); }
.sheet[data-state="back"] > .sheet-tab:hover .label { color: var(--ink); }
.sheet[data-state="back"] > .sheet-tab:hover::before { opacity: 0.55; }

/* ---------- the sky drifts a few pixels with the pointer ---------- */
.sky { transform: translate3d(var(--px, 0px), var(--py, 0px), 0) scale(1.03); transition: transform 1.2s var(--ease); will-change: transform; }

/* ---------- buttons: a dark lacquer with a lit edge; a gleam crosses on hover ---------- */
.btn { position: relative; overflow: hidden; isolation: isolate;
  color: var(--paper); background: linear-gradient(180deg, #2e2742 0%, #1a1524 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.18), inset 0 0 0 1px rgba(240, 214, 142, 0.18), 0 1px 0 #0d0a13, 0 6px 14px -4px rgba(31, 26, 44, 0.55);
  transition: transform 0.3s var(--ease), box-shadow 0.3s; }
.btn::after { content: ""; position: absolute; z-index: -1; top: 0; bottom: 0; left: -60%; width: 40%; pointer-events: none;
  background: linear-gradient(100deg, transparent, rgba(255, 236, 180, 0.38), transparent); transform: skewX(-20deg); transition: left 0.7s var(--ease); }
.btn > * { position: relative; }
.btn:hover { transform: translateY(-2px); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), inset 0 0 0 1px rgba(240, 214, 142, 0.3), 0 1px 0 #0d0a13, 0 12px 22px -6px rgba(31, 26, 44, 0.6); }
.btn:hover::after { left: 120%; }
.btn:active { transform: translateY(0); }
.btn:hover .arr { transform: translateX(4px); }
.btn-ghost { color: var(--ink); background: linear-gradient(180deg, rgba(255, 255, 255, 0.55), rgba(255, 255, 255, 0.15));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9), inset 0 0 0 1.5px var(--gold-line), 0 2px 6px -2px rgba(70, 52, 20, 0.25); }
.btn-ghost:hover { background: linear-gradient(180deg, rgba(255, 255, 255, 0.7), rgba(255, 255, 255, 0.3));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9), inset 0 0 0 1.5px var(--gold), 0 10px 18px -8px rgba(70, 52, 20, 0.4); }
.btn-ghost::after { background: linear-gradient(100deg, transparent, rgba(240, 214, 142, 0.45), transparent); }
.btn.soon:hover { transform: none; }
.btn.soon::after { display: none; }
/* X: the letter on a light badge, until the official icon is added */
.xslot { display: inline-grid; place-items: center; flex: none; width: 22px; height: 22px; margin: -4px -6px -4px -3px; border-radius: 6px;
  font: 800 13px/1 var(--body); letter-spacing: 0; color: #0c0a12; background: var(--paper); box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.12); }
.btn-ghost .xslot, .foot-col .xslot, .drawer .xslot { color: var(--paper); background: #14111c; box-shadow: none; }
.foot-col .xslot, .drawer .xslot { width: 18px; height: 18px; margin: 0 0 0 -2px; border-radius: 5px; font-size: 11px; }

/* ---------- inner pieces stand slightly proud of the sheet ---------- */
.card, .stat, .cta-card, .note { box-shadow: var(--raised); }
.card, .stat, .cta-card { background: linear-gradient(180deg, rgba(255, 255, 255, 0.66), rgba(255, 255, 255, 0.24)); }
.aims li { background: linear-gradient(180deg, rgba(255, 255, 255, 0.6), rgba(255, 255, 255, 0.22));
  box-shadow: inset 2px 0 0 var(--gold), inset 0 1px 0 rgba(255, 255, 255, 0.85), 0 1px 2px rgba(70, 52, 20, 0.12), 0 8px 16px -10px rgba(70, 52, 20, 0.3); }
.note { box-shadow: inset 3px 0 0 var(--gold), var(--raised); }
.principles .num { background: radial-gradient(circle at 35% 30%, #fffdf7, #efe6d1 70%);
  box-shadow: inset 0 0 0 1px var(--gold-line), inset 0 -2px 3px rgba(110, 85, 40, 0.18), 0 2px 4px rgba(70, 52, 20, 0.18); }
.cards { perspective: 900px; }
.card { transform: rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)) translateY(var(--ty, 0px)); transform-style: preserve-3d;
  transition: transform 0.5s var(--ease), box-shadow 0.4s, background-color 0.3s; }
.card::before { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; opacity: 0; transition: opacity 0.4s;
  background: radial-gradient(260px circle at var(--mx, 50%) var(--my, 0%), rgba(255, 245, 214, 0.75), transparent 60%); mix-blend-mode: soft-light; }
.card:hover, .card:focus-visible, .card.hot { --ty: -4px; transform: rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)) translateY(var(--ty, 0px));
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.74), rgba(255, 255, 255, 0.32));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9), inset 0 0 0 1px var(--gold), 0 18px 34px -14px rgba(70, 52, 20, 0.5); }
.card.hot { transition: transform 0.12s linear, box-shadow 0.4s; }
.card.hot::before { opacity: 1; }
.card .ico { transform: translateZ(30px); }
.status-live::before { animation: beat 2.4s ease-in-out infinite; }
@keyframes beat { 0%, 100% { box-shadow: 0 0 0 0 rgba(95, 154, 62, 0.5); } 50% { box-shadow: 0 0 0 5px rgba(95, 154, 62, 0); } }

/* ---------- a wonder on a lit plinth ---------- */
.viewer { background: radial-gradient(ellipse 60% 70% at 50% 18%, rgba(255, 248, 225, 0.9), transparent 70%), linear-gradient(180deg, #efe6d2, #d9ccad);
  box-shadow: inset 0 0 0 1px var(--gold-line), inset 0 -30px 40px -20px rgba(80, 60, 25, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.8); }
.viewer::before { content: ""; position: absolute; left: 50%; bottom: 7%; width: 64%; height: 17%; translate: -50% 0; border-radius: 50%; pointer-events: none;
  background: radial-gradient(closest-side, rgba(60, 44, 18, 0.32), transparent); box-shadow: 0 0 0 1.5px rgba(176, 138, 58, 0.45); }
.viewer canvas { position: relative; }

/* ---------- hero: the words beside a slowly turning astrolabe ---------- */
.hero-main { display: grid; grid-template-columns: minmax(0, 1.12fr) minmax(0, 0.88fr); align-items: center; gap: clamp(16px, 3vw, 40px); position: relative; }
.hero-text { min-width: 0; position: relative; }
.foil { background: linear-gradient(100deg, #6e5216 0%, #b48a33 22%, #f1d88f 40%, #c79a3b 55%, #7a5d1c 78%, #a9822f 100%); background-size: 260% 100%;
  -webkit-background-clip: text; background-clip: text; color: transparent; animation: foil 9s ease-in-out infinite; }
@keyframes foil { 0%, 100% { background-position: 100% 0; } 50% { background-position: 0% 0; } }
.astro { width: min(100%, 420px); justify-self: center; aspect-ratio: 1; pointer-events: none; }
.astro svg { display: block; width: 100%; height: 100%; overflow: visible; }
.astro .ln { fill: none; stroke: var(--gold-deep); stroke-width: 1.1; opacity: 0.75; }
.astro .ln-soft { fill: none; stroke: var(--gold); stroke-width: 0.8; opacity: 0.45; }
.astro .tick { stroke: var(--gold-deep); stroke-width: 1; opacity: 0.6; }
.astro .tick.big { stroke-width: 1.6; opacity: 0.9; }
.astro text { font-family: var(--display); fill: var(--gold-deep); font-size: 15px; text-anchor: middle; dominant-baseline: middle; }
.astro .small { font-family: var(--body); font-size: 10px; font-weight: 700; letter-spacing: 0.12em; fill: var(--ink-soft); }
.astro .arc { fill: none; stroke: url(#astroGold); stroke-width: 5; stroke-linecap: round; }
.astro .r1 { animation: spin 160s linear infinite; }
.astro .r2 { animation: spin 240s linear infinite reverse; }
.astro .r3 { animation: spin 60s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (max-width: 760px) {
  .hero-main { grid-template-columns: minmax(0, 1fr); }
  .astro { position: absolute; z-index: 0; right: -96px; top: -34px; width: 260px; opacity: 0.2; }
}

/* ---------- the Kardashev scale as a journey through time ---------- */
.kt { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: clamp(24px, 4vw, 48px); align-items: start; }
.kt-intro h2 { margin-bottom: 24px; }
.kt-intro p { font-size: 16.5px; line-height: 1.75; max-width: 46ch; }
.tm { position: relative; margin: 0; padding: 22px 22px 16px; border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; gap: 16px;
  color: var(--on-space); background: radial-gradient(120% 90% at 0% 0%, #2c2447 0%, #16121f 55%, #0c0a12 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12), inset 0 0 0 1px rgba(240, 214, 142, 0.22), 0 18px 34px -16px rgba(20, 12, 30, 0.7); }
.tm :focus-visible { outline-color: var(--atmo); }
.tm-sweep { position: absolute; inset: 0; pointer-events: none; opacity: 0; background: linear-gradient(100deg, transparent 30%, rgba(240, 214, 142, 0.16) 48%, rgba(134, 198, 255, 0.1) 52%, transparent 70%); }
.tm.go-f .tm-sweep { animation: sweep-f 0.9s var(--ease); }
.tm.go-b .tm-sweep { animation: sweep-b 0.9s var(--ease); }
@keyframes sweep-f { 0% { opacity: 1; transform: translateX(-100%); } 100% { opacity: 0; transform: translateX(100%); } }
@keyframes sweep-b { 0% { opacity: 1; transform: translateX(100%); } 100% { opacity: 0; transform: translateX(-100%); } }
.tm-top { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; }
.tm-k { display: flex; align-items: baseline; gap: 10px; }
.tm-k-label { font-size: 11px; font-weight: 700; letter-spacing: 0.2em; text-transform: uppercase; color: var(--gold-light); opacity: 0.8; }
.tm-k-num { min-width: 2.6ch; font-family: var(--display); font-size: clamp(44px, 6vw, 64px); line-height: 1; font-variant-numeric: tabular-nums;
  background: linear-gradient(180deg, #fff3cf, #d9b45a 70%, #a7802c); -webkit-background-clip: text; background-clip: text; color: transparent; }
.tm-meta { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; text-align: right; }
.tm-when { font-family: var(--display); font-size: 18px; letter-spacing: 0.04em; }
.tm-power { font-size: 12.5px; letter-spacing: 0.08em; color: rgba(244, 246, 255, 0.64); font-variant-numeric: tabular-nums; }
.tm-era { min-height: 136px; display: flex; flex-direction: column; gap: 6px; }
.tm-tag { align-self: flex-start; padding: 3px 9px; border-radius: 99px; font-size: 10.5px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: #0c0a12; background: var(--gold-light); }
.tm-tag.past { background: #cdbf9e; }
.tm-tag.future { background: var(--atmo); }
.tm-era h3 { margin: 0; font-family: var(--display); font-weight: 400; font-size: 25px; line-height: 1.15; letter-spacing: 0; color: var(--on-space); }
.tm-era p { margin: 0; font-size: 15px; line-height: 1.6; color: rgba(244, 246, 255, 0.82); max-width: 54ch; }
.tm-era.out-f > * { animation: out-f 0.26s ease-in both; }
.tm-era.out-b > * { animation: out-b 0.26s ease-in both; }
.tm-era.in-f > * { animation: in-f 0.6s var(--ease) both; }
.tm-era.in-b > * { animation: in-b 0.6s var(--ease) both; }
.tm-era.in-f > :nth-child(2), .tm-era.in-b > :nth-child(2) { animation-delay: 0.05s; }
.tm-era.in-f > :nth-child(3), .tm-era.in-b > :nth-child(3) { animation-delay: 0.1s; }
@keyframes out-f { to { opacity: 0; transform: translateX(-28px); filter: blur(4px); } }
@keyframes out-b { to { opacity: 0; transform: translateX(28px); filter: blur(4px); } }
@keyframes in-f { from { opacity: 0; transform: translateX(34px); filter: blur(5px); } }
@keyframes in-b { from { opacity: 0; transform: translateX(-34px); filter: blur(5px); } }
.tm-rail { padding: 18px 10px 0; }
.tm-track { position: relative; height: 10px; border-radius: 99px; background: rgba(255, 255, 255, 0.1); box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.6); cursor: pointer; touch-action: none; }
.tm-fill { position: absolute; left: 0; top: 0; bottom: 0; width: 73%; border-radius: 99px; background: linear-gradient(90deg, #6e5216, var(--gold) 55%, var(--gold-light)); box-shadow: 0 0 14px rgba(240, 214, 142, 0.4); transition: width 0.6s var(--ease); }
.tm-stops { position: absolute; inset: 0; }
.tm-stop { position: absolute; top: 50%; width: 24px; height: 24px; margin: -12px 0 0 -12px; border-radius: 50%; padding: 0; }
.tm-stop::before { content: ""; position: absolute; left: 50%; top: 50%; width: 6px; height: 6px; margin: -3px 0 0 -3px; border-radius: 50%; background: rgba(244, 246, 255, 0.55); transition: transform 0.3s var(--ease), background 0.3s; }
.tm-stop:hover::before { transform: scale(1.6); background: #fff; }
.tm-stop.tm-now::before { width: 8px; height: 8px; margin: -4px 0 0 -4px; background: var(--atmo); box-shadow: 0 0 0 3px rgba(134, 198, 255, 0.25); }
.tm-knob { position: absolute; top: 50%; left: 73%; width: 24px; height: 24px; margin: -12px 0 0 -12px; border-radius: 50%; cursor: grab; transition: left 0.6s var(--ease);
  background: radial-gradient(circle at 35% 30%, #fff, #f5f2ea 45%, #d8cba8); box-shadow: 0 0 0 3px var(--gold), 0 0 18px rgba(240, 214, 142, 0.7), 0 3px 8px rgba(0, 0, 0, 0.6); }
.tm-knob:focus-visible { outline: 2px solid var(--atmo); outline-offset: 4px; }
.tm.dragging .tm-knob, .tm.dragging .tm-fill { transition: none; }
.tm.dragging .tm-knob { cursor: grabbing; }
.tm-ticks { display: flex; justify-content: space-between; margin-top: 12px; font-family: var(--display); font-size: 14px; color: rgba(244, 246, 255, 0.64); }
.tm-ctrl { display: flex; flex-wrap: wrap; gap: 8px; justify-content: space-between; }
.tm-btn { display: inline-flex; align-items: center; gap: 8px; padding: 8px 13px; border-radius: 999px; font-size: 13px; font-weight: 600; color: var(--on-space); box-shadow: inset 0 0 0 1px rgba(240, 214, 142, 0.35); transition: background 0.25s, box-shadow 0.25s; }
.tm-btn:hover { background: rgba(240, 214, 142, 0.1); box-shadow: inset 0 0 0 1px var(--gold-light); }
.tm-btn:disabled { opacity: 0.35; pointer-events: none; }
.tm-play { color: #0c0a12; background: linear-gradient(180deg, #f6e2a6, #cfa64d); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.6), 0 4px 12px -4px rgba(240, 214, 142, 0.6); }
.tm-play:hover { background: linear-gradient(180deg, #fbeabb, #d9b45a); }
.tm-play svg { width: 11px; height: 11px; fill: currentColor; }
.tm figcaption { font-size: 11.5px; line-height: 1.5; color: rgba(244, 246, 255, 0.5); }
@media (max-width: 900px) { .kt { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 560px) { .tm { padding: 18px 16px 14px; } .tm-era { min-height: 190px; } .tm-btn { padding: 8px 11px; font-size: 12.5px; } .tm-when { font-size: 16px; } }

/* ---------- reveals: complete at rest; plays once as it comes into view ---------- */
.rv.in { animation: up 0.9s var(--ease) backwards; animation-delay: calc(var(--i, 0) * 90ms); }
@keyframes up { from { transform: translateY(18px); opacity: 0; } }

/* ---------- the entrance ---------- */
.intro-wait .ribbon, .intro-wait .stage, .intro-wait .stack { opacity: 0; }
.intro .ribbon { animation: drop 1.1s var(--ease) 0.1s both; }
.intro .stage { animation: rise-globe 1.6s var(--ease) both; }
.intro .stack { animation: rise-stack 1.3s var(--ease) 0.35s both; }
.intro .hero-main .hero-text > * { animation: up 1s var(--ease) both; }
.intro .hero-main .hero-text > :nth-child(1) { animation-delay: 0.8s; }
.intro .hero-main .hero-text > :nth-child(2) { animation-delay: 0.9s; }
.intro .hero-main .hero-text > :nth-child(3) { animation-delay: 1.02s; }
.intro .hero-main .hero-text > :nth-child(4) { animation-delay: 1.14s; }
.intro .astro { animation: astro-in 1.6s var(--ease) 0.9s both; }
.intro .astro .draw { stroke-dasharray: var(--len); animation: draw 2.2s var(--ease) 1s both; }
@keyframes drop { from { transform: translateY(-90px); } }
@keyframes rise-globe { from { transform: translateY(70px) scale(0.94); opacity: 0.2; } }
@keyframes rise-stack { from { transform: translateY(100%); } }
@keyframes astro-in { from { transform: rotate(-24deg) scale(0.9); opacity: 0; } }
@keyframes draw { from { stroke-dashoffset: var(--len); } }
@media (max-width: 760px) { @keyframes astro-in { from { transform: rotate(-24deg) scale(0.9); opacity: 0; } to { opacity: 0.2; } } }

/* =====================================================================================
   v23 · speed
   The same look, drawn once. Shadows are painted on their own and only move with
   their sheet; nothing that loops forces the page to be redrawn; lite mode
   (phones, low-memory devices, slow computers) holds the extras still.
   ===================================================================================== */
:root {
  --cast: 0 0 1px rgba(0, 0, 0, 0.7), 0 -8px 12px rgba(0, 0, 0, 0.36), 0 -26px 40px -4px rgba(0, 0, 0, 0.48);
  --cast-back: 0 0 1px rgba(0, 0, 0, 0.55), 0 -6px 12px rgba(0, 0, 0, 0.32);
  --cast-away: 0 0 1px rgba(0, 0, 0, 0.6), 0 6px 16px rgba(0, 0, 0, 0.5);
  --tab-lit: inset 0 1px 0 rgba(255, 255, 255, 0.95), inset 0 2px 0 rgba(176, 138, 58, 0.45);
}
html.lite {
  --cast: 0 0 1px rgba(0, 0, 0, 0.7), 0 -10px 18px rgba(0, 0, 0, 0.45);
  --cast-back: 0 -4px 10px rgba(0, 0, 0, 0.3);
}

/* no live filters on the sheets: their shadows are ordinary painted shadows, cast by the tab and by a ghost of the page body */
.tablist .sheet[data-state], .sheet, .more { filter: none; }
.sheet { transition: transform var(--move) var(--ease); }
.sheet::before, .more::before {
  content: ""; position: absolute; z-index: -1; top: var(--tab-h); left: 0; right: 0; bottom: 0; pointer-events: none;
  box-shadow: var(--cast); transition: box-shadow 0.4s;
}
[data-side="left"].sheet::before { border-radius: 0 var(--radius) var(--radius) var(--radius); }
[data-side="right"].sheet::before { border-radius: var(--radius) 0 var(--radius) var(--radius); }
.more::before { border-radius: var(--radius); }
.sheet[data-state="back"]::before { box-shadow: var(--cast-back); }
.sheet[data-state="away"]::before { box-shadow: var(--cast-away); }
.sheet-tab, .more-tab { box-shadow: var(--tab-lit), var(--cast); }
.sheet[data-state="back"] > .sheet-tab { box-shadow: var(--tab-lit), var(--cast-back); }
.sheet[data-state="away"] > .sheet-tab { box-shadow: var(--tab-lit), var(--cast-away); }
@keyframes land-left {
  0% { z-index: 0; opacity: 1; transform: translateY(calc(-1 * var(--peek))) scale(0.988); animation-timing-function: ease-in; }
  13% { z-index: 0; opacity: 0; transform: translateY(0) scale(0.988); animation-timing-function: step-end; }
  14% { z-index: 3; opacity: 0; transform: translate(-7%, -34px) rotate(-1.1deg) scale(1.02); animation-timing-function: cubic-bezier(0.22, 1, 0.36, 1); }
  34% { opacity: 1; }
  100% { z-index: 3; opacity: 1; transform: none; }
}
@keyframes land-right {
  0% { z-index: 0; opacity: 1; transform: translateY(calc(-1 * var(--peek))) scale(0.988); animation-timing-function: ease-in; }
  13% { z-index: 0; opacity: 0; transform: translateY(0) scale(0.988); animation-timing-function: step-end; }
  14% { z-index: 3; opacity: 0; transform: translate(7%, -34px) rotate(1.1deg) scale(1.02); animation-timing-function: cubic-bezier(0.22, 1, 0.36, 1); }
  34% { opacity: 1; }
  100% { z-index: 3; opacity: 1; transform: none; }
}

/* the astrolabe: each ring is its own layer, turned by the graphics card; paused while off screen */
.astro { position: relative; }
.astro > svg, .astro > .ring { position: absolute; inset: 0; }
.astro .ring svg { display: block; width: 100%; height: 100%; overflow: visible; }
.astro .r1, .astro .r2, .astro .r3 { animation-play-state: paused; }
.astro.spin-on .r1, .astro.spin-on .r2, .astro.spin-on .r3 { animation-play-state: running; }

/* the gold word shines once as the page opens, and again when pointed at, instead of shimmering forever */
.foil { animation: none; background-position: 0% 0; }
.intro .foil { animation: foil-once 2.4s ease-in-out 1.1s both; }
h1:hover .foil { animation: foil-once 1.6s ease-in-out; }
@keyframes foil-once { from { background-position: 100% 0; } to { background-position: 0% 0; } }

/* the "live" dot keeps its ring without pulsing */
.status-live::before { animation: none; }

/* the sky only becomes a moving layer where it drifts */
.sky { transform: none; transition: none; will-change: auto; }
html.drift .sky { transform: translate3d(var(--px, 0px), var(--py, 0px), 0) scale(1.03); transition: transform 1.2s var(--ease); will-change: transform; }

/* a lighter entrance: the planet fades in where it is; the paper and ribbon still arrive */
.intro .ribbon { animation: drop 0.8s var(--ease) 0.05s both; }
.intro .stage { animation: fade-in 1.1s ease-out both; }
.intro .stack { animation: rise-stack 1s var(--ease) 0.2s both; }
.intro .hero-main .hero-text > :nth-child(1) { animation-delay: 0.55s; }
.intro .hero-main .hero-text > :nth-child(2) { animation-delay: 0.65s; }
.intro .hero-main .hero-text > :nth-child(3) { animation-delay: 0.75s; }
.intro .hero-main .hero-text > :nth-child(4) { animation-delay: 0.85s; }
.intro .hero-main .hero-text > * { animation-duration: 0.8s; }
.intro .astro { animation: astro-in 1.2s var(--ease) 0.6s both; }
.intro .astro .draw { animation: draw 1.8s var(--ease) 0.7s both; }
@keyframes fade-in { from { opacity: 0; } }

/* lite mode: the extras hold still */
html.lite .card, html.lite .card:hover { transform: translateY(var(--ty, 0px)); }
html.lite .card::before { display: none; }
html.lite .card .ico { transform: none; }
html.lite .btn::after { display: none; }
html.lite .rv.in { animation-duration: 0.6s; }
@media (max-width: 760px) { .astro { position: absolute; } }

/* =====================================================================================
   v24 · steady scrolling and a smooth footer
   Each page sits in a window. When the footer rises, the window's lower edge slides up
   while the page inside slides back down by the same amount: the page stays still and
   ends above the footer. Both are plain movements the graphics card does on its own,
   so nothing is redrawn while the footer arrives.
   ===================================================================================== */
.sheet-win, .more-win {
  position: absolute; top: var(--tab-h); left: 0; right: 0; bottom: 0;
  overflow: hidden; pointer-events: none;
  border-radius: 0 0 var(--radius) var(--radius);
  transition: transform 0.55s var(--ease);
}
.sheet-win > .sheet-body, .more-win > .more-body { top: 0; transition: transform 0.55s var(--ease), background-color 0.5s; }
.foot-on .sheet-win, .foot-on .more-win { transform: translateY(calc(-1 * (var(--foot-h, 0px) + var(--g)))); }
.foot-on .sheet-win > .sheet-body, .foot-on .more-win > .more-body { transform: translateY(calc(var(--foot-h, 0px) + var(--g))); }

/* the footer is drawn once when the page loads, waiting just below the screen, so it arrives ready */
.site-foot { visibility: visible; will-change: transform; transition: transform 0.55s var(--ease); }

/* lite mode: content is simply there, no rise as it scrolls into view */
html.lite .rv.in { animation: none; }

/* ==========================================================================
   v25 · the planet's foot
   The planet used to stop in a hard line 24px below the shade, which showed as a lighter strip
   while the sheets were still rising. The shade now runs past that line and feathers out, and the
   shader (app.js, uFade) dissolves the planet over those same 24px.
   ========================================================================== */
.shade {
  height: 180px;
  background: linear-gradient(to bottom, rgba(5, 6, 13, 0) 0, rgba(5, 6, 13, 0.85) 120px, rgba(5, 6, 13, 0.85) 144px, rgba(5, 6, 13, 0) 180px);
}
