/* ==========================================================================
   牌乐门主站 shared kit — /assets/site.css
   ========================================================================== */

:root {
  --ink-900: #0D1013;
  --ink-700: #20272E;
  --paper-0: #FAF7F1;
  --sand-100: #F0E4D2;
  --azure-600: #1B4FA0;
  --azure-100: #D5E2F7;
  --crimson-600: #B0243C;
  --gold-500: #C98A1E;
  --oasis-500: #17786F;
  --gray-400: #8B9198;

  --line: rgba(32, 39, 46, 0.14);
  --line-strong: rgba(32, 39, 46, 0.26);
  --line-ink: rgba(250, 247, 241, 0.16);
  --line-gold: rgba(201, 138, 30, 0.38);

  --font-display: "Noto Serif SC", "Source Han Serif SC", "Songti SC", "SimSun", serif;
  --font-body: "Noto Sans SC", "HarmonyOS Sans", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --r-pill: 999px;
  --r-card: 14px;
  --shell: 1180px;
  --shadow-soft: 0 1px 2px rgba(13, 16, 19, 0.04), 0 16px 34px -28px rgba(13, 16, 19, 0.55);
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background-color: var(--paper-0);
  background-image:
    repeating-linear-gradient(115deg, rgba(27, 79, 160, 0.022) 0 1px, transparent 1px 16px),
    radial-gradient(circle at 10% 4%, rgba(201, 138, 30, 0.06), transparent 42%),
    radial-gradient(circle at 92% 26%, rgba(23, 120, 111, 0.05), transparent 40%);
  color: var(--ink-700);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.75;
  font-weight: 400;
  overflow-x: hidden;
}

img,
svg { display: block; max-width: 100%; }

button { font: inherit; color: inherit; background: none; border: 0; }

ul[class],
ol[class] {
  margin: 0;
  padding: 0;
  list-style: none;
}

/* ------------------------------------------------------------ typography -- */
h1, h2, h3, h4, h5, h6 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--ink-900);
}

h1 { font-size: clamp(34px, 6vw, 56px); line-height: 1.07; }
h2 { font-size: clamp(27px, 4.4vw, 44px); line-height: 1.18; }
h3 { font-size: clamp(21px, 2.6vw, 32px); line-height: 1.31; }
h4 { font-size: clamp(18px, 1.8vw, 20px); line-height: 1.5; }

p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }

strong { color: var(--ink-900); font-weight: 600; }

a { color: var(--azure-600); text-decoration: none; }

:focus-visible {
  outline: 2px solid var(--azure-600);
  outline-offset: 3px;
  border-radius: 6px;
}

.site-footer :focus-visible { outline-color: var(--gold-500); }

#main-content { scroll-margin-top: 96px; }

/* ------------------------------------------------------------- utilities -- */
.wrap {
  width: 100%;
  max-width: var(--shell);
  margin: 0 auto;
  padding: 0 24px;
}

.wrap--narrow { max-width: 820px; }

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

.lead {
  font-size: clamp(17px, 1.6vw, 19px);
  line-height: 1.8;
  color: var(--ink-700);
}

.t-subheading { font-size: 20px; line-height: 1.5; }
.t-label { font-size: 13px; line-height: 1.54; letter-spacing: 0.02em; }
.t-mono {
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 1.5;
  letter-spacing: 0.06em;
}
.muted { color: var(--gray-400); }

.stack > * + * { margin-top: 16px; }

.cluster {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

/* ------------------------------------------------------------ skip link -- */
.skip-link {
  position: absolute;
  left: 14px;
  top: -72px;
  z-index: 200;
  padding: 10px 18px;
  border-radius: var(--r-pill);
  background: var(--ink-900);
  color: var(--paper-0);
  font-size: 14px;
  text-decoration: none;
  transition: top 0.22s var(--ease);
}

.skip-link:focus {
  top: 12px;
  color: var(--paper-0);
}

/* ---------------------------------------------------------------- header -- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  padding: 12px 0;
  transition: padding 0.3s var(--ease);
}

.header-shell {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 18px;
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 56px;
}

.island {
  background: rgba(250, 247, 241, 0.86);
  border: 0.5px solid var(--line);
  border-radius: var(--r-pill);
  -webkit-backdrop-filter: blur(10px) saturate(1.2);
  backdrop-filter: blur(10px) saturate(1.2);
  box-shadow: 0 6px 20px -18px rgba(13, 16, 19, 0.85);
  transition: background-color 0.3s var(--ease), box-shadow 0.3s var(--ease),
    border-color 0.3s var(--ease);
}

.site-header[data-scrolled="true"] { padding: 7px 0; }

.site-header[data-scrolled="true"] .island {
  background: rgba(250, 247, 241, 0.95);
  border-color: var(--line-strong);
  box-shadow: 0 14px 30px -22px rgba(13, 16, 19, 0.9);
}

/* brand island */
.brand-island {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 16px 6px 7px;
  color: var(--ink-900);
  text-decoration: none;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: var(--azure-600);
  color: var(--paper-0);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 16px;
  line-height: 1;
  letter-spacing: 0;
}

.brand-text {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
}

.brand-name {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 17px;
  line-height: 1.2;
  letter-spacing: 0.01em;
  color: var(--ink-900);
}

.brand-tag {
  font-size: 10.5px;
  line-height: 1.3;
  letter-spacing: 0.04em;
  color: var(--gray-400);
  white-space: nowrap;
}

.brand-island:hover .brand-mark { background: var(--azure-600); }
.brand-island:hover .brand-tag { color: var(--azure-600); }

/* nav island */
.nav-island {
  flex: 0 0 auto;
  margin-inline: auto;
  padding: 5px;
  display: flex;
  align-items: center;
}

.nav-list {
  display: flex;
  align-items: center;
  gap: 2px;
}

.nav-link {
  display: inline-block;
  padding: 8px 14px;
  border-radius: var(--r-pill);
  font-size: 14px;
  line-height: 1.3;
  color: var(--ink-700);
  text-decoration: none;
  white-space: nowrap;
  transition: background-color 0.22s var(--ease), color 0.22s var(--ease);
}

.nav-link:hover {
  background: rgba(27, 79, 160, 0.09);
  color: var(--azure-600);
}

.nav-link[aria-current="page"] {
  background: var(--azure-600);
  color: var(--paper-0);
}

.nav-link[aria-current="page"]:hover {
  background: var(--azure-600);
  color: var(--paper-0);
}

.site-header[data-scrolled="true"] .nav-link { padding: 6px 12px; font-size: 13.5px; }

/* action island */
.action-island {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px;
}

/* nav toggle */
.nav-toggle {
  display: none;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  cursor: pointer;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--ink-900);
  flex: 0 0 auto;
}

.nav-toggle-icon {
  position: relative;
  display: inline-block;
  width: 16px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
}

.nav-toggle-icon::before,
.nav-toggle-icon::after {
  content: "";
  position: absolute;
  left: 0;
  width: 16px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  transition: transform 0.24s var(--ease), top 0.24s var(--ease);
}

.nav-toggle-icon::before { top: -5px; }
.nav-toggle-icon::after { top: 5px; }

.nav-toggle[aria-expanded="true"] .nav-toggle-icon { background: transparent; }
.nav-toggle[aria-expanded="true"] .nav-toggle-icon::before { top: 0; transform: rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-icon::after { top: 0; transform: rotate(-45deg); }

/* ---------------------------------------------------------------- footer -- */
.site-footer {
  position: relative;
  overflow: hidden;
  background: var(--ink-900);
  color: rgba(250, 247, 241, 0.7);
  font-size: 14px;
  line-height: 1.7;
  padding: 0 0 26px;
}

.site-footer::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    repeating-linear-gradient(115deg, rgba(201, 138, 30, 0.055) 0 1px, transparent 1px 18px),
    radial-gradient(circle at 86% -10%, rgba(27, 79, 160, 0.4), transparent 46%);
}

.site-footer::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--line-gold) 22%, var(--line-gold) 78%, transparent);
}

.site-footer > * { position: relative; z-index: 1; }

.footer-shell {
  max-width: var(--shell);
  margin: 0 auto;
  padding: 0 24px;
}

.footer-top {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.5fr);
  gap: 44px;
  padding: 56px 0 40px;
  border-bottom: 0.5px solid var(--line-ink);
}

.footer-brandline {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 19px;
  line-height: 1.45;
  letter-spacing: -0.01em;
  color: var(--paper-0);
}

.footer-blurb {
  margin: 12px 0 0;
  max-width: 36ch;
  color: rgba(250, 247, 241, 0.58);
}

.footer-cols {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 26px;
}

.footer-col:nth-child(2) { padding-top: 18px; }
.footer-col:nth-child(3) { padding-top: 36px; }

.footer-col h3 {
  margin: 0 0 14px;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold-500);
}

.footer-list li + li { margin-top: 9px; }

.footer-list a {
  color: rgba(250, 247, 241, 0.72);
  text-decoration: none;
  border-bottom: 0.5px solid transparent;
  transition: color 0.2s var(--ease), border-color 0.2s var(--ease);
}

.footer-list a:hover {
  color: var(--paper-0);
  border-bottom-color: var(--gold-500);
}

.footer-contact {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 16px 30px;
  padding: 32px 0;
  border-bottom: 0.5px solid var(--line-ink);
}

.contact-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.contact-item--wide { grid-column: 1 / -1; }

.contact-key {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(201, 138, 30, 0.85);
}

.contact-val {
  font-family: var(--font-mono);
  font-size: 13px;
  line-height: 1.6;
  letter-spacing: 0.02em;
  color: rgba(250, 247, 241, 0.82);
  overflow-wrap: anywhere;
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 24px;
  padding-top: 22px;
}

.footer-bottom p { margin: 0; }

.footer-legal,
.footer-area {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.05em;
  color: rgba(250, 247, 241, 0.48);
}

/* ------------------------------------------------------------- sections -- */
.section {
  position: relative;
  padding: clamp(56px, 9vw, 104px) 0;
}

.section--sand { background: var(--sand-100); }
.section--azure { background: var(--azure-100); }

.section--ink {
  background: var(--ink-900);
  color: rgba(250, 247, 241, 0.78);
}

.section--ink :is(h1, h2, h3, h4, h5, h6) { color: var(--paper-0); }
.section--ink .lead { color: rgba(250, 247, 241, 0.72); }
.section--ink .muted { color: rgba(250, 247, 241, 0.5); }
.section--ink .sec-num { color: var(--gold-500); }
.section--ink strong { color: var(--paper-0); }

.sec-num {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--azure-600);
}

.sec-num::before {
  content: "";
  width: 22px;
  height: 1px;
  background: currentColor;
  opacity: 0.65;
}

.band {
  height: 1px;
  border: 0;
  margin: 0;
  background: linear-gradient(90deg, transparent, var(--line-strong) 16%, var(--line-strong) 84%, transparent);
}

.band--gold {
  background: linear-gradient(90deg, transparent, var(--line-gold) 26%, var(--line-gold) 74%, transparent);
}

/* ---------------------------------------------------------- breadcrumbs -- */
.crumbs-wrap { padding: 18px 0 0; }

.crumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.06em;
  color: var(--gray-400);
}

.crumbs li {
  display: flex;
  align-items: center;
  gap: 8px;
}

.crumbs li + li::before {
  content: "/";
  color: rgba(139, 145, 152, 0.7);
}

.crumbs a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s var(--ease);
}

.crumbs a:hover { color: var(--azure-600); }

.crumbs [aria-current="page"] { color: var(--ink-700); }

/* --------------------------------------------------------------- buttons -- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 20px;
  border-radius: var(--r-pill);
  border: 0.5px solid transparent;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 600;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
  transition: transform 0.22s var(--ease), background-color 0.22s var(--ease),
    color 0.22s var(--ease), border-color 0.22s var(--ease), box-shadow 0.22s var(--ease);
}

.btn--primary {
  background: var(--azure-600);
  color: #FFFFFF;
  box-shadow: 0 12px 24px -18px rgba(27, 79, 160, 0.95);
}

.btn--primary:hover {
  background: #17458C;
  color: #FFFFFF;
  transform: translateY(-2px);
}

.btn--ghost {
  background: transparent;
  color: var(--ink-900);
  border-color: var(--line-strong);
}

.btn--ghost:hover {
  color: var(--azure-600);
  border-color: var(--azure-600);
  transform: translateY(-2px);
}

.btn--gold {
  background: var(--gold-500);
  color: var(--ink-900);
}

.btn--gold:hover {
  background: #B87C16;
  transform: translateY(-2px);
}

.btn--sm { padding: 9px 16px; font-size: 13px; }
.btn--block { width: 100%; }

.section--ink .btn--ghost {
  color: var(--paper-0);
  border-color: rgba(250, 247, 241, 0.32);
}

.section--ink .btn--ghost:hover {
  color: var(--ink-900);
  background: var(--paper-0);
  border-color: var(--paper-0);
}

/* ------------------------------------------------------------------ tags -- */
.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 10px;
  border-radius: var(--r-pill);
  border: 0.5px solid currentColor;
  background: transparent;
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 1.5;
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.tag--azure { color: var(--azure-600); background: rgba(213, 226, 247, 0.55); }
.tag--gold { color: #8A5F12; background: rgba(201, 138, 30, 0.14); }
.tag--crimson { color: var(--crimson-600); background: rgba(176, 36, 60, 0.1); }
.tag--oasis { color: var(--oasis-500); background: rgba(23, 120, 111, 0.1); }
.tag--muted { color: var(--gray-400); background: rgba(139, 145, 152, 0.1); }

.section--ink .tag--azure { color: var(--azure-100); background: rgba(27, 79, 160, 0.32); }
.section--ink .tag--gold { color: var(--gold-500); background: rgba(201, 138, 30, 0.14); }
.section--ink .tag--muted { color: rgba(250, 247, 241, 0.62); background: rgba(250, 247, 241, 0.08); }

/* ----------------------------------------------------------------- cards -- */
.card {
  position: relative;
  padding: 22px;
  border: 0.5px solid var(--line);
  border-radius: var(--r-card);
  background: var(--paper-0);
  box-shadow: var(--shadow-soft);
  transition: transform 0.24s var(--ease), border-color 0.24s var(--ease),
    box-shadow 0.24s var(--ease);
}

.card:hover {
  transform: translateY(-2px);
  border-color: rgba(27, 79, 160, 0.42);
  box-shadow: 0 2px 4px rgba(13, 16, 19, 0.05), 0 22px 44px -30px rgba(13, 16, 19, 0.6);
}

.card--sand {
  background: var(--sand-100);
  border-color: rgba(27, 79, 160, 0.28);
}

.card--ink {
  background: var(--ink-900);
  border-color: var(--line-gold);
  color: rgba(250, 247, 241, 0.78);
}

.card--ink :is(h1, h2, h3, h4) { color: var(--paper-0); }
.card--ink .muted { color: rgba(250, 247, 241, 0.5); }

.card--flat { transition: none; }
.card--flat:hover { transform: none; border-color: var(--line); box-shadow: var(--shadow-soft); }

/* ----------------------------------------------------------------- grids -- */
.grid { display: grid; gap: 20px; }
.grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid--sidebar { grid-template-columns: minmax(0, 1.85fr) minmax(0, 1fr); gap: 32px; }

/* ------------------------------------------------------------ media box -- */
.media-frame {
  position: relative;
  overflow: hidden;
  border-radius: 12px;
  border: 0.5px solid var(--line);
  background-color: var(--sand-100);
  background-image:
    repeating-linear-gradient(115deg, rgba(27, 79, 160, 0.07) 0 1px, transparent 1px 12px),
    linear-gradient(135deg, rgba(240, 228, 210, 0.9), rgba(213, 226, 247, 0.85));
}

.media-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image: repeating-radial-gradient(circle at 24% 118%, rgba(201, 138, 30, 0.12) 0 1px, transparent 1px 20px);
}

.media-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.media-frame--16x9 { aspect-ratio: 16 / 9; }
.media-frame--4x3 { aspect-ratio: 4 / 3; }
.media-frame--3x4 { aspect-ratio: 3 / 4; }
.media-frame--1x1 { aspect-ratio: 1 / 1; }
.media-frame--wide { aspect-ratio: 21 / 9; }

.media-frame__cap {
  position: absolute;
  left: 12px;
  bottom: 12px;
  z-index: 2;
  padding: 4px 10px;
  border-radius: var(--r-pill);
  background: rgba(13, 16, 19, 0.72);
  color: var(--paper-0);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
}

/* -------------------------------------------------------------- textures -- */
.tex-dune {
  background-image: repeating-radial-gradient(circle at 18% 122%, rgba(201, 138, 30, 0.11) 0 1px, transparent 1px 18px);
}

.tex-oasis {
  background-image:
    linear-gradient(rgba(23, 120, 111, 0.09) 1px, transparent 1px),
    linear-gradient(90deg, rgba(23, 120, 111, 0.09) 1px, transparent 1px);
  background-size: 28px 28px;
}

.tex-atlas {
  background-image:
    repeating-linear-gradient(45deg, rgba(27, 79, 160, 0.08) 0 1px, transparent 1px 11px),
    repeating-linear-gradient(-45deg, rgba(176, 36, 60, 0.055) 0 1px, transparent 1px 11px);
}

/* --------------------------------------------------------------- indices -- */
.index-list {
  display: grid;
  border-top: 0.5px solid var(--line-strong);
}

.index-item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: baseline;
  gap: 14px;
  padding: 13px 4px;
  border-bottom: 0.5px solid var(--line);
  transition: background-color 0.2s var(--ease);
}

.index-item:hover { background: rgba(213, 226, 247, 0.4); }

.index-item__code {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.06em;
  color: var(--gray-400);
}

.index-item__title {
  font-weight: 600;
  color: var(--ink-900);
  text-decoration: none;
}

.index-item__title:hover { color: var(--azure-600); }

.section--ink .index-list { border-top-color: var(--line-ink); }
.section--ink .index-item { border-bottom-color: var(--line-ink); }
.section--ink .index-item:hover { background: rgba(250, 247, 241, 0.05); }
.section--ink .index-item__title { color: var(--paper-0); }
.section--ink .index-item__title:hover { color: var(--gold-500); }

/* ---------------------------------------------------------------- tables -- */
.table-wrap {
  overflow-x: auto;
  border: 0.5px solid var(--line);
  border-radius: 12px;
  background: var(--paper-0);
  -webkit-overflow-scrolling: touch;
}

.table-wrap table {
  width: 100%;
  min-width: 560px;
  border-collapse: collapse;
  font-size: 15px;
}

.table-wrap th,
.table-wrap td {
  padding: 12px 16px;
  text-align: left;
  border-bottom: 0.5px solid var(--line);
  vertical-align: top;
}

.table-wrap thead th {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gray-400);
  background: rgba(240, 228, 210, 0.55);
}

.table-wrap tbody tr:last-child th,
.table-wrap tbody tr:last-child td { border-bottom: 0; }

.section--ink .table-wrap {
  background: rgba(250, 247, 241, 0.04);
  border-color: var(--line-ink);
}

.section--ink .table-wrap th,
.section--ink .table-wrap td { border-bottom-color: var(--line-ink); }

.section--ink .table-wrap thead th {
  background: rgba(201, 138, 30, 0.1);
  color: var(--gold-500);
}

/* --------------------------------------------------------- scroll & motion -- */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 120;
  width: 0;
  height: 2px;
  pointer-events: none;
  background: linear-gradient(90deg, var(--azure-600), var(--gold-500));
}

[data-reveal] {
  transition: opacity 0.32s var(--ease), transform 0.32s var(--ease);
  transition-delay: var(--reveal-delay, 0ms);
}

.js-reveal [data-reveal] {
  opacity: 0;
  transform: translateY(12px);
}

.js-reveal [data-reveal].is-in {
  opacity: 1;
  transform: none;
}

/* ----------------------------------------------------------- responsive -- */
@media (max-width: 1180px) {
  .nav-link { padding: 8px 11px; font-size: 13px; }
  .action-secondary { display: none; }
}

@media (max-width: 980px) {
  .brand-tag { display: none; }
  .footer-top { grid-template-columns: minmax(0, 1fr); gap: 34px; padding: 46px 0 34px; }
  .footer-col:nth-child(2),
  .footer-col:nth-child(3) { padding-top: 0; }
  .grid--sidebar { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .grid--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 900px) {
  .site-header { padding: 10px 0; }
  .site-header[data-scrolled="true"] { padding: 7px 0; }

  .header-shell { padding: 0 14px; gap: 8px; }

  .nav-toggle { display: inline-flex; }
  .action-island { margin-left: auto; }
  .action-island .btn { padding: 9px 14px; font-size: 13px; }

  .nav-island {
    position: fixed;
    top: 74px;
    left: 14px;
    right: 14px;
    z-index: 70;
    margin: 0;
    padding: 10px;
    flex-direction: column;
    align-items: stretch;
    border-radius: 20px;
    background: rgba(250, 247, 241, 0.98);
    box-shadow: 0 26px 60px -32px rgba(13, 16, 19, 0.85);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: opacity 0.24s var(--ease), transform 0.24s var(--ease), visibility 0.24s;
  }

  .nav-island[data-open] {
    opacity: 1;
    visibility: visible;
    transform: none;
  }

  .nav-list {
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
  }

  .nav-link {
    display: block;
    padding: 12px 14px;
    border-radius: 12px;
    font-size: 15px;
  }

  .site-header[data-scrolled="true"] .nav-link { padding: 12px 14px; font-size: 15px; }
  .nav-link[aria-current="page"] { border-radius: 12px; }
}

@media (max-width: 720px) {
  .wrap { padding: 0 18px; }
  .footer-shell { padding: 0 18px; }
  .grid--2,
  .grid--3 { grid-template-columns: minmax(0, 1fr); }
  .footer-cols { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid--sidebar { gap: 20px; }
  .index-item { grid-template-columns: auto minmax(0, 1fr); }
}

@media (max-width: 460px) {
  .brand-name { font-size: 15.5px; }
  .brand-mark { width: 30px; height: 30px; font-size: 14px; }
  .action-island .btn { padding: 8px 12px; font-size: 12.5px; }
  .nav-toggle { padding: 9px 12px; }
  .nav-toggle-text { display: none; }
  .footer-cols { grid-template-columns: minmax(0, 1fr); }
  .footer-bottom { justify-content: flex-start; }
}

/* ------------------------------------------------------- reduced motion -- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }

  .js-reveal [data-reveal] {
    opacity: 1 !important;
    transform: none !important;
  }

  .card:hover,
  .btn:hover { transform: none; }
}
