/* Pearl Tech Foundation — design system
   Palette from the Pearl emblem: flame orange on deep navy, with teal for the Virtual Lab. */
:root {
  --navy-950: #08111e;
  --navy-900: #0b1626;
  --navy-800: #0f1f35;
  --navy-700: #17304f;
  --navy-100: #e8eef6;
  --flame: #f26b1d;
  --flame-600: #dd5a10;
  --flame-700: #b4460a;
  --flame-50: #fff3ea;
  --amber: #ffad1f;
  --teal: #0e8c7f;
  --teal-50: #e7f6f3;
  --sand-50: #fbf8f4;
  --sand-100: #f4eee6;
  --ink: #152033;
  --slate: #566173;
  --line: #e3e7ee;
  --white: #fff;

  --head: "Plus Jakarta Sans", "Segoe UI", system-ui, sans-serif;
  --body: "Inter", "Segoe UI", system-ui, sans-serif;

  --radius: 14px;
  --radius-lg: 22px;
  --shadow-sm: 0 1px 2px rgba(15, 31, 53, 0.06), 0 2px 8px rgba(15, 31, 53, 0.05);
  --shadow: 0 10px 30px -12px rgba(15, 31, 53, 0.22);
  --shadow-lg: 0 30px 60px -24px rgba(15, 31, 53, 0.35);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --container: 1200px;

  /* Semantic colours: light theme (dark theme overrides these) */
  --bg: #fff;
  --surface: #fff;
  --surface-2: var(--sand-50);
  --surface-3: var(--sand-100);
  --text: var(--ink);
  --muted: var(--slate);
  --heading: var(--navy-800);
  --border: var(--line);
  --input-border: #cfd6e0;
  --header-bg: rgba(255, 255, 255, 0.96);
  --tag-bg: rgba(255, 255, 255, 0.95);
  --accent-ink: var(--flame-700);
  --flame-soft: var(--flame-50);
  --teal-soft: var(--teal-50);
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; font: 400 17px/1.65 var(--body); color: var(--text); background: var(--bg); -webkit-font-smoothing: antialiased; overflow-x: hidden; }
img, svg { display: block; max-width: 100%; }
a { color: inherit; }
button { font: inherit; cursor: pointer; }
h1, h2, h3, h4 { font-family: var(--head); line-height: 1.15; margin: 0 0 0.5em; color: var(--heading); letter-spacing: -0.02em; }
h1 { font-size: clamp(2.4rem, 5.2vw, 4rem); font-weight: 800; }
h2 { font-size: clamp(1.9rem, 3.4vw, 2.7rem); font-weight: 800; }
h3 { font-size: 1.28rem; font-weight: 700; }
h4 { font-size: 1.05rem; font-weight: 700; }
p { margin: 0 0 1em; }
.container { width: min(var(--container), 100% - 40px); margin-inline: auto; }
/* visually hidden without pushing anything off-screen (a negative offset scrolls sideways in right-to-left pages) */
.skip { position: absolute; top: 0; left: 0; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip:focus { width: auto; height: auto; clip-path: none; top: 16px; left: 16px; z-index: 1000; padding: 10px 16px; background: var(--navy-800); color: #fff; border-radius: 8px; }
:focus-visible { outline: 3px solid var(--amber); outline-offset: 2px; }

/* ---------- Buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; padding: 14px 24px; border-radius: 999px; border: 2px solid transparent;
  font: 700 0.95rem/1 var(--head); text-decoration: none; transition: background 0.25s, color 0.25s, border-color 0.25s, transform 0.25s var(--ease), box-shadow 0.25s; white-space: nowrap; }
.btn svg { width: 18px; height: 18px; transition: transform 0.3s var(--ease); }
.btn:hover svg { transform: translateX(3px); }
.btn:hover { transform: translateY(-1px); }
.btn--primary { background: var(--flame); color: var(--navy-900); box-shadow: 0 8px 20px -8px rgba(242, 107, 29, 0.7); }
.btn--primary:hover { background: var(--amber); }
.btn--navy { background: var(--navy-800); color: #fff; }
.btn--navy:hover { background: var(--navy-700); }
.btn--outline { border-color: var(--heading); color: var(--heading); background: transparent; }
.btn--outline:hover { background: var(--heading); color: var(--bg); }
.btn--light { border-color: rgba(255, 255, 255, 0.7); color: #fff; background: rgba(255, 255, 255, 0.06); backdrop-filter: blur(4px); }
.btn--light:hover { background: var(--surface); color: var(--heading); }
.btn--teal { background: var(--teal); color: #fff; }
.btn--teal:hover { background: #0b7469; }
.btn--sm { padding: 10px 18px; font-size: 0.85rem; }
.link { display: inline-flex; align-items: center; gap: 8px; font: 700 0.95rem var(--head); color: var(--accent-ink); text-decoration: none; }
.link svg { width: 18px; height: 18px; transition: transform 0.3s var(--ease); }
.link:hover svg { transform: translateX(4px); }

/* ---------- Header ---------- */
.topbar { background: var(--navy-900); color: #c4cedd; font-size: 0.82rem; }
.topbar .container { display: flex; justify-content: space-between; gap: 20px; padding: 8px 0; }
.topbar a { color: #fff; text-decoration: none; }
.topbar a:hover { color: var(--amber); }
.topbar__links { display: flex; gap: 22px; }
.header { position: sticky; top: 0; z-index: 100; background: var(--header-bg); border-bottom: 1px solid transparent; transition: box-shadow 0.3s, border-color 0.3s; }
/* The blur sits on a layer behind the header: a backdrop-filter on .header itself would trap the
   fixed-position mobile menu inside the 78px header instead of letting it cover the screen. */
.header::before { content: ""; position: absolute; inset: 0; z-index: -1; -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); pointer-events: none; }
.header.scrolled { box-shadow: var(--shadow-sm); border-color: var(--border); }
.header .container { display: flex; align-items: center; gap: 28px; height: 78px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; margin-right: auto; }
.brand img { width: 46px; height: 46px; }
.brand__name { font: 800 1.15rem/1 var(--head); color: var(--heading); letter-spacing: -0.01em; }
.brand__name small { display: block; margin-top: 4px; font: 600 0.68rem/1 var(--body); letter-spacing: 0.18em; text-transform: uppercase; color: var(--accent-ink); }
.nav { display: flex; align-items: center; gap: 4px; list-style: none; margin: 0; padding: 0; }
.nav a { display: block; padding: 10px 12px; border-radius: 8px; font: 600 0.92rem var(--head); color: var(--text); text-decoration: none; transition: color 0.2s, background 0.2s; }
.nav a:hover { color: var(--accent-ink); background: var(--flame-soft); }
.nav a[aria-current="page"] { color: var(--accent-ink); }
.nav a[aria-current="page"]::after { content: ""; display: block; height: 2px; margin-top: 4px; border-radius: 2px; background: var(--flame); }
.nav-toggle { display: none; width: 46px; height: 46px; border: 1px solid var(--border); border-radius: 10px; background: var(--surface); }
.nav-toggle span, .nav-toggle span::before, .nav-toggle span::after { display: block; width: 20px; height: 2px; margin: 0 auto; background: var(--heading); border-radius: 2px; transition: transform 0.3s, opacity 0.3s; position: relative; }
.nav-toggle span::before, .nav-toggle span::after { content: ""; position: absolute; left: 0; }
.nav-toggle span::before { top: -6px; } .nav-toggle span::after { top: 6px; }
.menu-open .nav-toggle span { background: transparent; }
.menu-open .nav-toggle span::before { transform: translateY(6px) rotate(45deg); }
.menu-open .nav-toggle span::after { transform: translateY(-6px) rotate(-45deg); }

/* ---------- Heroes ---------- */
.hero { position: relative; min-height: min(88vh, 760px); display: flex; align-items: center; color: #fff; overflow: hidden; background: var(--navy-800); }
.hero__bg, .page-hero__bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; animation: kenburns 18s ease-out both; }
@keyframes kenburns { from { transform: scale(1.08); } to { transform: scale(1); } }
.hero::before, .page-hero::before { content: ""; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(95deg, rgba(8, 17, 30, 0.92) 0%, rgba(11, 22, 38, 0.78) 42%, rgba(11, 22, 38, 0.25) 100%); }
.hero .container, .page-hero .container { position: relative; z-index: 2; }
.hero__content { max-width: 700px; padding: 90px 0 150px; }
.kicker { display: inline-flex; align-items: center; gap: 10px; margin-bottom: 22px; padding: 7px 14px; border-radius: 999px; background: rgba(255, 255, 255, 0.1); border: 1px solid rgba(255, 255, 255, 0.18);
  font: 600 0.8rem var(--head); letter-spacing: 0.06em; text-transform: uppercase; color: #fff; }
.kicker i { width: 8px; height: 8px; border-radius: 50%; background: var(--flame); box-shadow: 0 0 0 4px rgba(242, 107, 29, 0.25); }
.hero h1, .page-hero h1 { color: #fff; }
.hl { color: var(--amber); }
.hero__lead { font-size: 1.2rem; color: #dbe3ee; max-width: 600px; margin-bottom: 34px; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 14px; }
.hero__note { margin-top: 30px; font-size: 0.88rem; color: #b8c4d4; display: flex; flex-wrap: wrap; gap: 8px 22px; }
.hero__note span::before { content: "✓"; color: var(--amber); font-weight: 700; margin-right: 8px; }

.page-hero { position: relative; color: #fff; background: var(--navy-800); overflow: hidden; }
.page-hero .container { padding: 84px 0 92px; }
.page-hero h1 { font-size: clamp(2.2rem, 4.4vw, 3.4rem); max-width: 820px; }
.page-hero p { font-size: 1.15rem; color: #dbe3ee; max-width: 660px; margin: 0; }
.crumbs { display: flex; gap: 10px; margin-bottom: 18px; font-size: 0.85rem; color: #b8c4d4; }
.crumbs a { color: #fff; text-decoration: none; }
.crumbs a:hover { color: var(--amber); }
.page-hero--plain { background: linear-gradient(135deg, var(--navy-800), var(--navy-700)); }
.page-hero--plain::before { display: none; }

/* ---------- Stats strip (overlaps the home hero) ---------- */
.stats { position: relative; z-index: 5; margin-top: -86px; }
.stats__grid { display: grid; grid-template-columns: repeat(4, 1fr); background: var(--surface); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); overflow: hidden; }
.stat { padding: 30px 28px; border-right: 1px solid var(--border); }
.stat:last-child { border-right: 0; }
.stat b { display: block; font: 800 clamp(2rem, 3.4vw, 2.7rem)/1 var(--head); color: var(--heading); margin-bottom: 8px; }
.stat b em { font-style: normal; color: var(--flame); }
.stat > span { font-size: 0.92rem; color: var(--muted); }
.stats__note { margin: 14px 0 0; font-size: 0.82rem; color: var(--muted); text-align: center; }

/* ---------- Sections ---------- */
.section { padding: clamp(72px, 9vw, 120px) 0; }
.section--sand { background: var(--surface-2); }
.section--tint { background: linear-gradient(180deg, var(--surface-2), var(--bg)); }
.section--navy { background: var(--navy-800); color: #c9d3e1; }
.section--navy h2, .section--navy h3, .section--navy h4 { color: #fff; }
.section--teal { background: linear-gradient(160deg, #0b2a35 0%, var(--navy-800) 70%); color: #c9d3e1; }
.section--teal h2, .section--teal h3 { color: #fff; }
.section--tight { padding: 56px 0; }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; margin: 0 0 14px; font: 700 0.8rem var(--head); letter-spacing: 0.14em; text-transform: uppercase; color: var(--accent-ink); }
.eyebrow::before { content: ""; width: 26px; height: 3px; border-radius: 3px; background: var(--flame); }
.section--navy .eyebrow, .section--teal .eyebrow { color: var(--amber); }
.eyebrow--teal { color: var(--teal); } .eyebrow--teal::before { background: var(--teal); }
.section--teal .eyebrow--teal { color: #5fd3c4; } .section--teal .eyebrow--teal::before { background: #5fd3c4; }
.lead { font-size: 1.15rem; color: var(--muted); }
.section--navy .lead, .section--teal .lead { color: #b8c4d4; }
.head { max-width: 760px; margin-bottom: clamp(40px, 5vw, 60px); }
.head--center { margin-inline: auto; text-align: center; }
.head--center .eyebrow { justify-content: center; }
.head--row { max-width: none; display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 20px; }
.head--row > div { max-width: 700px; }
.muted { color: var(--muted); }
.small { font-size: 0.88rem; }
.note { font-size: 0.85rem; color: var(--muted); margin-top: 22px; }
.center { text-align: center; }

/* ---------- Split layouts and media ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(36px, 6vw, 80px); align-items: center; }
.split--wide { grid-template-columns: 1.15fr 1fr; }
.split--reverse > :first-child { order: 2; }
.media { position: relative; }
.media img { width: 100%; border-radius: var(--radius-lg); box-shadow: var(--shadow); object-fit: cover; }
.media--tall img { aspect-ratio: 4 / 5; }
.media--wide img { aspect-ratio: 4 / 3; }
.media__badge { position: absolute; left: -22px; bottom: 28px; max-width: 250px; padding: 18px 20px; border-radius: var(--radius); background: var(--surface); box-shadow: var(--shadow); }
.media__badge b { display: block; font: 800 1.6rem/1 var(--head); color: var(--flame); margin-bottom: 4px; }
.media__badge span { font-size: 0.88rem; color: var(--muted); }
.media__caption { margin-top: 12px; font-size: 0.82rem; color: var(--muted); }
.duo { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.duo figure { margin: 0; }
.duo img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; border-radius: var(--radius); }
.duo figure:last-child { margin-top: 48px; }
.duo figcaption { margin-top: 10px; font: 700 0.95rem var(--head); color: var(--heading); }
.duo figcaption span { display: block; font: 400 0.85rem var(--body); color: var(--muted); }

.checks { list-style: none; padding: 0; margin: 0 0 1.4em; display: grid; gap: 12px; }
.checks li { position: relative; padding-left: 34px; }
.checks li::before { content: ""; position: absolute; left: 0; top: 3px; width: 22px; height: 22px; border-radius: 50%;
  background: var(--flame-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='m6 12 4 4 8-8' fill='none' stroke='%23b4460a' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 14px no-repeat; }
.section--navy .checks li::before, .section--teal .checks li::before { background-color: rgba(255, 255, 255, 0.1); }

/* ---------- Cards ---------- */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 26px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.card { display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); overflow: hidden; text-decoration: none; color: inherit;
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease), border-color 0.35s; }
a.card:hover, .card--lift:hover { transform: translateY(-6px); box-shadow: var(--shadow); border-color: transparent; }
.card__img { position: relative; aspect-ratio: 16 / 10; overflow: hidden; background: var(--surface-3); }
.card__img img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.8s var(--ease); }
a.card:hover .card__img img, .card--lift:hover .card__img img { transform: scale(1.05); }
.card__tag { position: absolute; left: 14px; top: 14px; padding: 6px 12px; border-radius: 999px; background: var(--tag-bg); font: 700 0.72rem var(--head); letter-spacing: 0.08em; text-transform: uppercase; color: var(--heading); }
.card__tag--teal { background: var(--teal); color: #fff; }
.card__body { display: flex; flex-direction: column; flex: 1; padding: 24px 24px 26px; }
.card__body p { color: var(--muted); font-size: 0.97rem; }
.card__body ul { margin: 0 0 18px; padding-left: 1.1em; color: var(--muted); font-size: 0.93rem; }
.card__body li { margin-bottom: 4px; }
.card__body .link { margin-top: auto; }
.card__num { font: 800 0.85rem var(--head); color: var(--flame); margin-bottom: 8px; }

.icon-card { padding: 30px 28px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); transition: transform 0.35s var(--ease), box-shadow 0.35s; }
.icon-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.icon-card .ico { display: grid; place-items: center; width: 54px; height: 54px; margin-bottom: 20px; border-radius: 14px; background: var(--flame-soft); color: var(--accent-ink); }
.icon-card .ico svg { width: 26px; height: 26px; }
.icon-card p { color: var(--muted); margin: 0; font-size: 0.97rem; }
.icon-card--teal .ico { background: var(--teal-soft); color: var(--teal); }
.section--navy .icon-card, .section--teal .icon-card { background: rgba(255, 255, 255, 0.04); border-color: rgba(255, 255, 255, 0.1); }
.section--navy .icon-card p, .section--teal .icon-card p { color: #b8c4d4; }
.section--navy .icon-card .ico, .section--teal .icon-card .ico { background: rgba(242, 107, 29, 0.15); color: var(--amber); }
.section--teal .icon-card--teal .ico { background: rgba(14, 140, 127, 0.2); color: #5fd3c4; }

/* ---------- How it works steps ---------- */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; counter-reset: step; position: relative; }
.steps::before { content: ""; position: absolute; left: 6%; right: 6%; top: 31px; height: 2px; background: repeating-linear-gradient(90deg, var(--flame) 0 10px, transparent 10px 18px); opacity: 0.6; }
.step { position: relative; padding: 0 18px; text-align: center; }
.step__n { position: relative; display: grid; place-items: center; width: 64px; height: 64px; margin: 0 auto 20px; border-radius: 50%; background: var(--surface); border: 2px solid var(--flame); color: var(--accent-ink); font: 800 1.3rem var(--head); }
.step--core .step__n { background: var(--flame); color: var(--navy-900); }
.step p { color: var(--muted); font-size: 0.95rem; }
.section--navy .step__n { background: var(--navy-800); }
.section--navy .step--core .step__n { background: var(--flame); }
.section--navy .step p { color: #b8c4d4; }

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: var(--radius-lg); background: var(--surface); }
table { width: 100%; border-collapse: collapse; font-size: 0.95rem; }
th, td { padding: 16px 20px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--border); }
th { font: 700 0.78rem var(--head); letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); background: var(--surface-2); }
tr:last-child td { border-bottom: 0; }
td:first-child { font-weight: 600; color: var(--heading); }

/* ---------- Quote ---------- */
.quote { display: grid; grid-template-columns: 0.9fr 1.1fr; border-radius: var(--radius-lg); overflow: hidden; background: var(--navy-800); color: #fff; box-shadow: var(--shadow-lg); }
.quote img { width: 100%; height: 100%; min-height: 360px; object-fit: cover; }
.quote__body { padding: clamp(32px, 5vw, 64px); display: flex; flex-direction: column; justify-content: center; }
.quote blockquote { margin: 0 0 26px; font: 700 clamp(1.35rem, 2.4vw, 1.9rem)/1.35 var(--head); letter-spacing: -0.01em; }
.quote blockquote::before { content: "“"; display: block; font-size: 4rem; line-height: 0.6; color: var(--flame); margin-bottom: 10px; }
.quote cite { font-style: normal; color: #b8c4d4; font-size: 0.95rem; }
.quote cite b { display: block; color: #fff; font-family: var(--head); }

/* ---------- CTA band ---------- */
.cta { position: relative; overflow: hidden; border-radius: var(--radius-lg); color: #fff; background: var(--navy-800); }
.cta__bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.cta::before { content: ""; position: absolute; inset: 0; z-index: 1; background: linear-gradient(90deg, rgba(8, 17, 30, 0.94), rgba(11, 22, 38, 0.7) 60%, rgba(242, 107, 29, 0.35)); }
.cta__inner { position: relative; z-index: 2; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 28px; padding: clamp(40px, 6vw, 72px); }
.cta h2 { color: #fff; margin: 0 0 8px; max-width: 640px; }
.cta p { color: #dbe3ee; margin: 0; max-width: 560px; }
.cta__actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- Browser frame for screenshots ---------- */
.browser { border-radius: 14px; overflow: hidden; background: #1c2330; box-shadow: var(--shadow-lg); border: 1px solid rgba(255, 255, 255, 0.08); }
.browser__bar { display: flex; align-items: center; gap: 7px; padding: 11px 14px; background: #262e3c; }
.browser__bar i { width: 11px; height: 11px; border-radius: 50%; background: #ff5f57; }
.browser__bar i:nth-child(2) { background: #febc2e; } .browser__bar i:nth-child(3) { background: #28c840; }
.browser__bar span { margin-left: 12px; flex: 1; padding: 5px 12px; border-radius: 6px; background: #1a212c; color: #8c97a8; font-size: 0.75rem; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.browser img { width: 100%; }
.browser--float { transform: perspective(1600px) rotateY(-6deg) rotateX(2deg); transition: transform 0.8s var(--ease); }
.browser--float:hover { transform: none; }

/* ---------- Chips ---------- */
.chips { display: flex; flex-wrap: wrap; gap: 10px; margin: 0 0 26px; padding: 0; list-style: none; }
.chips li { padding: 8px 14px; border-radius: 999px; background: rgba(255, 255, 255, 0.08); border: 1px solid rgba(255, 255, 255, 0.14); font: 600 0.85rem var(--head); color: #fff; }
.chips--light li { background: var(--surface-2); border-color: var(--border); color: var(--heading); }

/* ---------- Virtual Lab ---------- */
.lab-facts { display: grid; grid-template-columns: repeat(6, 1fr); gap: 1px; background: rgba(255, 255, 255, 0.12); border: 1px solid rgba(255, 255, 255, 0.12); border-radius: var(--radius-lg); overflow: hidden; }
.lab-facts div { padding: 26px 18px; background: var(--navy-800); text-align: center; }
.lab-facts b { display: block; font: 800 2.2rem/1 var(--head); color: #fff; margin-bottom: 8px; }
.lab-facts span { font-size: 0.85rem; color: #b8c4d4; }
.lab-card .card__img { aspect-ratio: 16 / 8; }
.lab-card .card__img img { object-position: left top; }
.lab-card h3 { display: flex; align-items: center; gap: 10px; }
.lab-card .pill { font: 700 0.7rem var(--head); letter-spacing: 0.06em; text-transform: uppercase; padding: 4px 10px; border-radius: 999px; background: var(--teal-soft); color: var(--teal); }
.projects { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.project { margin: 0; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; transition: transform 0.35s var(--ease), box-shadow 0.35s; }
.project:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.project img { width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; background: var(--surface-3); }
.project figcaption { padding: 14px 16px 16px; }
.project b { display: block; font: 700 0.98rem/1.3 var(--head); color: var(--heading); margin-bottom: 6px; }
.project span { font-size: 0.8rem; color: var(--muted); }
.project .lvl { display: inline-block; margin-right: 6px; padding: 2px 8px; border-radius: 999px; font: 700 0.68rem var(--head); text-transform: uppercase; letter-spacing: 0.05em; }
.lvl--beginner { background: #e5f6ea; color: #1c7a3a; } .lvl--intermediate { background: var(--flame-soft); color: var(--accent-ink); } .lvl--advanced { background: #ece8fb; color: #5b3fc4; }
.filter { display: flex; flex-wrap: wrap; gap: 8px; }
.filter button { padding: 9px 16px; border-radius: 999px; border: 1px solid var(--border); background: var(--surface); font: 600 0.88rem var(--head); color: var(--text); }
.filter button[aria-pressed="true"] { background: var(--navy-800); border-color: var(--navy-800); color: #fff; }
.section--navy .filter button { background: transparent; border-color: rgba(255, 255, 255, 0.25); color: #fff; }
.section--navy .filter button[aria-pressed="true"] { background: var(--flame); border-color: var(--flame); color: var(--navy-900); }
.project[hidden] { display: none; }

/* ---------- Gallery ---------- */
.gallery { display: grid; grid-template-columns: repeat(4, 1fr); grid-auto-rows: 250px; gap: 16px; }
.gallery figure { margin: 0; position: relative; overflow: hidden; border-radius: var(--radius); }
.gallery figure:nth-child(1), .gallery figure:nth-child(6) { grid-column: span 2; }
.gallery img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.9s var(--ease); }
.gallery figure:hover img { transform: scale(1.06); }
.gallery figcaption { position: absolute; left: 0; right: 0; bottom: 0; padding: 30px 16px 12px; background: linear-gradient(transparent, rgba(8, 17, 30, 0.85)); color: #fff; font: 600 0.88rem var(--head); }

/* ---------- Roadmap ---------- */
.phases { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.phase { position: relative; }
.phase .card__img { aspect-ratio: 16 / 10; }
.phase__badge { position: absolute; right: 14px; top: 14px; padding: 6px 12px; border-radius: 999px; background: var(--flame); color: var(--navy-900); font: 700 0.72rem var(--head); letter-spacing: 0.06em; text-transform: uppercase; z-index: 2; }
.phase__when { font: 700 0.8rem var(--head); letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent-ink); margin-bottom: 6px; }
.phase__nums { display: flex; gap: 24px; margin: 6px 0 14px; padding: 14px 0; border-block: 1px solid var(--border); }
.phase__nums b { display: block; font: 800 1.8rem/1 var(--head); color: var(--heading); }
.phase__nums span { font-size: 0.8rem; color: var(--muted); }

/* ---------- Model diagram ---------- */
.flow { display: grid; grid-template-columns: repeat(5, 1fr); gap: 14px; position: relative; }
.flow__node { position: relative; padding: 24px 20px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); }
.flow__node:not(:last-child)::after { content: ""; position: absolute; right: -14px; top: 50%; width: 14px; height: 2px; background: var(--flame); }
.flow__node .n { display: inline-grid; place-items: center; width: 34px; height: 34px; margin-bottom: 14px; border-radius: 50%; background: var(--flame-soft); color: var(--accent-ink); font: 800 0.95rem var(--head); }
.flow__node p { margin: 0; font-size: 0.92rem; color: var(--muted); }
.flow__node--core { background: var(--navy-800); border-color: var(--navy-800); }
.flow__node--core h4 { color: #fff; } .flow__node--core p { color: #b8c4d4; }
.flow__node--core .n { background: var(--flame); color: var(--navy-900); }
.flow-legend { display: flex; flex-wrap: wrap; gap: 26px; justify-content: center; margin-top: 24px; font-size: 0.88rem; color: var(--muted); }
.flow-legend span::before { content: "→"; color: var(--flame); font-weight: 800; margin-right: 8px; }
.flow-legend span:last-child::before { content: "←"; color: var(--teal); }

/* ---------- Pathway ---------- */
.pathway { display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; counter-reset: stage; }
.stage { position: relative; padding: 26px 22px; border-radius: var(--radius-lg); background: rgba(255, 255, 255, 0.05); border: 1px solid rgba(255, 255, 255, 0.1); }
.stage::before { counter-increment: stage; content: "0" counter(stage); display: block; font: 800 2.2rem/1 var(--head); color: var(--flame); margin-bottom: 14px; }
.stage h3 { color: #fff; font-size: 1.1rem; }
.stage p { margin: 0; font-size: 0.92rem; color: #b8c4d4; }

/* ---------- Tabs (partner) ---------- */
.tabs__list { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 30px; }
.tabs__list button { padding: 11px 20px; border-radius: 999px; border: 1px solid var(--border); background: var(--surface); font: 700 0.9rem var(--head); color: var(--text); transition: background 0.2s, color 0.2s, border-color 0.2s; }
.tabs__list button:hover { border-color: var(--flame); }
.tabs__list button[aria-selected="true"] { background: var(--navy-800); border-color: var(--navy-800); color: #fff; }
.tab-panel { display: none; grid-template-columns: 0.95fr 1.05fr; gap: 0; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-sm); }
.tab-panel.active { display: grid; animation: fadein 0.5s var(--ease); }
@keyframes fadein { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.tab-panel > img { width: 100%; height: 100%; min-height: 320px; object-fit: cover; }
.tab-panel__body { padding: clamp(28px, 4vw, 48px); }
.tab-panel__body p { color: var(--muted); }
.tab-panel__cols { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin: 22px 0 26px; }
.tab-panel__cols h4 { font-size: 0.82rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent-ink); }
.tab-panel__cols ul { margin: 0; padding-left: 1.1em; font-size: 0.93rem; color: var(--muted); }
.tab-panel__cols li { margin-bottom: 6px; }
.tab-panel__actions { display: flex; flex-wrap: wrap; gap: 10px; }

/* ---------- Calculator ---------- */
.calc { display: grid; grid-template-columns: 1.1fr 0.9fr; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow); }
.calc__controls { padding: clamp(28px, 4vw, 44px); }
.calc__result { padding: clamp(28px, 4vw, 44px); background: var(--navy-800); color: #fff; display: flex; flex-direction: column; }
.field { margin-bottom: 26px; }
.field label, .field .label { display: flex; justify-content: space-between; font: 700 0.9rem var(--head); color: var(--heading); margin-bottom: 10px; }
.field output { color: var(--accent-ink); }
.seg { display: inline-flex; padding: 4px; border-radius: 999px; background: var(--surface-3); }
.seg button { padding: 9px 20px; border: 0; border-radius: 999px; background: transparent; font: 700 0.88rem var(--head); color: var(--muted); }
.seg button.active { background: var(--surface); color: var(--heading); box-shadow: var(--shadow-sm); }
input[type="range"] { width: 100%; height: 6px; appearance: none; -webkit-appearance: none; border-radius: 6px; background: linear-gradient(90deg, var(--flame) var(--fill, 50%), var(--border) var(--fill, 50%)); }
input[type="range"]::-webkit-slider-thumb { -webkit-appearance: none; width: 22px; height: 22px; border-radius: 50%; background: var(--surface); border: 4px solid var(--flame); box-shadow: var(--shadow-sm); }
input[type="range"]::-moz-range-thumb { width: 16px; height: 16px; border-radius: 50%; background: var(--surface); border: 4px solid var(--flame); }
.calc__label { font: 700 0.78rem var(--head); letter-spacing: 0.12em; text-transform: uppercase; color: var(--amber); }
.calc__big { margin: 10px 0 24px; font: 800 clamp(2.2rem, 4vw, 3rem)/1 var(--head); }
.calc__big small { font-size: 0.45em; color: #b8c4d4; margin-right: 6px; }
.calc__rows { list-style: none; margin: 0 0 28px; padding: 0; }
.calc__rows li { display: flex; justify-content: space-between; padding: 12px 0; border-bottom: 1px solid rgba(255, 255, 255, 0.12); font-size: 0.93rem; color: #c9d3e1; }
.calc__rows b { color: #fff; }
.calc__result .btn { margin-top: auto; align-self: flex-start; }

/* ---------- Proposal ---------- */
.proposal { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); box-shadow: var(--shadow); padding: clamp(28px, 5vw, 60px); }
.proposal__head { display: flex; justify-content: space-between; align-items: flex-start; gap: 20px; padding-bottom: 26px; margin-bottom: 10px; border-bottom: 2px solid var(--heading); }
.proposal__head img { width: 120px; margin: -16px -10px 0 0; }
.proposal dl { display: grid; grid-template-columns: 200px 1fr; margin: 0; }
.proposal dt, .proposal dd { padding: 18px 0; border-bottom: 1px solid var(--border); margin: 0; }
.proposal dt { font: 700 0.82rem var(--head); letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent-ink); padding-right: 20px; }
.proposal__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.timeline { list-style: none; margin: 0; padding: 0; position: relative; }
.timeline::before { content: ""; position: absolute; left: 19px; top: 8px; bottom: 8px; width: 2px; background: linear-gradient(var(--flame), var(--teal)); }
.timeline li { position: relative; padding: 0 0 30px 64px; }
.timeline li::before { content: ""; position: absolute; left: 10px; top: 4px; width: 20px; height: 20px; border-radius: 50%; background: var(--surface); border: 4px solid var(--flame); }
.timeline b { display: block; font: 700 0.8rem var(--head); letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent-ink); }
.timeline h3 { margin: 4px 0 6px; }
.timeline p { color: var(--muted); margin: 0; }

/* ---------- Accountability / metrics ---------- */
.rings { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.ring { text-align: center; padding: 28px 18px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); }
.ring svg { width: 120px; height: 120px; margin: 0 auto 14px; transform: rotate(-90deg); }
.ring circle { fill: none; stroke-width: 10; }
.ring .track { stroke: var(--surface-3); }
.ring .bar { stroke: var(--flame); stroke-linecap: round; stroke-dasharray: 327; stroke-dashoffset: 327; transition: stroke-dashoffset 1.6s var(--ease); }
.ring b { display: block; margin-top: -92px; margin-bottom: 52px; font: 800 1.7rem var(--head); color: var(--heading); }
.ring p { margin: 0; font-size: 0.9rem; color: var(--muted); }

/* ---------- Alignment ---------- */
.align { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.align div { padding: 22px; border-radius: var(--radius); background: rgba(255, 255, 255, 0.05); border: 1px solid rgba(255, 255, 255, 0.1); }
.align code { display: inline-block; margin-bottom: 10px; padding: 4px 10px; border-radius: 6px; background: var(--flame); color: var(--navy-900); font: 800 0.78rem var(--head); }
.align h4 { color: #fff; margin-bottom: 6px; }
.align p { margin: 0; font-size: 0.88rem; color: #b8c4d4; }

/* ---------- Family / founders ---------- */
.founders { display: grid; grid-template-columns: 0.8fr 1.2fr; gap: clamp(36px, 6vw, 80px); align-items: center; }
.founders__mark { display: grid; place-items: center; aspect-ratio: 1; border-radius: 50%; background: radial-gradient(circle at 50% 45%, var(--flame-soft), var(--surface-3) 70%); }
.founders__mark img { width: 62%; filter: drop-shadow(0 20px 30px rgba(242, 107, 29, 0.25)); }
.founders blockquote { margin: 0 0 22px; font: 600 clamp(1.15rem, 2vw, 1.45rem)/1.5 var(--head); color: var(--heading); }
.founders__sig b { display: block; font: 800 1.05rem var(--head); color: var(--heading); }
.founders__sig span { font-size: 0.9rem; color: var(--muted); }
.family { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.family__item { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 34px 28px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); text-decoration: none; color: inherit; transition: transform 0.35s var(--ease), box-shadow 0.35s; }
a.family__item:hover { transform: translateY(-6px); box-shadow: var(--shadow); }
.family__item img { width: 120px; height: 120px; object-fit: contain; margin-bottom: 16px; }
.family__item p { color: var(--muted); font-size: 0.95rem; flex: 1; }
.family__item .link { font-size: 0.85rem; }
.family__item--here { border: 2px solid var(--flame); background: var(--flame-soft); }

/* ---------- FAQ ---------- */
.faq { max-width: 860px; margin-inline: auto; }
.faq details { border-bottom: 1px solid var(--border); }
.faq summary { list-style: none; display: flex; justify-content: space-between; gap: 20px; padding: 22px 0; cursor: pointer; font: 700 1.08rem var(--head); color: var(--heading); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; flex: none; display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: var(--flame-soft); color: var(--accent-ink); font-size: 1.2rem; transition: transform 0.3s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { color: var(--muted); padding-bottom: 20px; margin: 0; }

/* ---------- Contact form ---------- */
.contact { display: grid; grid-template-columns: 0.85fr 1.15fr; gap: clamp(32px, 5vw, 64px); align-items: start; }
.contact__list { list-style: none; margin: 26px 0 0; padding: 0; display: grid; gap: 18px; }
.contact__list li { display: flex; gap: 16px; }
.contact__list .ico { flex: none; display: grid; place-items: center; width: 46px; height: 46px; border-radius: 12px; background: var(--flame-soft); color: var(--accent-ink); }
.contact__list .ico svg { width: 22px; height: 22px; }
.contact__list b { display: block; font: 700 0.8rem var(--head); letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.contact__list a { color: var(--heading); font-weight: 600; text-decoration: none; }
.contact__list a:hover { color: var(--accent-ink); }
.form { padding: clamp(26px, 4vw, 44px); background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); box-shadow: var(--shadow); }
.form .row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.form .f { margin-bottom: 18px; }
.form label { display: block; margin-bottom: 7px; font: 700 0.85rem var(--head); color: var(--heading); }
.form input, .form select, .form textarea { width: 100%; padding: 13px 15px; border: 1px solid var(--input-border); border-radius: 10px; background: var(--surface); font: inherit; font-size: 0.97rem; color: var(--text); transition: border-color 0.2s, box-shadow 0.2s; }
.form input:focus, .form select:focus, .form textarea:focus { outline: 0; border-color: var(--flame); box-shadow: 0 0 0 4px rgba(242, 107, 29, 0.15); }
.form textarea { min-height: 130px; resize: vertical; }
.form .consent { display: flex; gap: 12px; align-items: flex-start; margin: 6px 0 18px; font: 400 0.88rem/1.55 var(--body); color: var(--muted); cursor: pointer; }
.form .consent input { width: 18px; height: 18px; flex: none; margin-top: 2px; accent-color: var(--flame); }
.form .consent a { color: var(--accent-ink); }
.form .btn { width: 100%; }
.form .btn:disabled { opacity: 0.6; cursor: wait; }
.cf-turnstile { min-height: 65px; margin-bottom: 16px; }
.form__note { margin: 14px 0 0; text-align: center; font-size: 0.85rem; color: var(--muted); }
.form__note.is-ok { color: #1c7a3a; font-weight: 600; }
.form__note.is-error { color: #c0392b; font-weight: 600; }
.hp { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

/* ---------- Legal and credits ---------- */
.legal { display: grid; grid-template-columns: 240px 1fr; gap: clamp(36px, 6vw, 80px); align-items: start; }
.legal__toc { position: sticky; top: 110px; padding: 22px; border-radius: var(--radius); background: var(--surface-2); }
.legal__toc ol { margin: 0; padding-left: 1.2em; font-size: 0.92rem; line-height: 2; }
.legal__toc a { color: var(--muted); text-decoration: none; }
.legal__toc a:hover { color: var(--accent-ink); }
.legal__body { max-width: 760px; }
.legal__body h2 { font-size: 1.6rem; margin-top: 1.8em; scroll-margin-top: 110px; }
.legal__body h2:first-of-type { margin-top: 0.4em; }
.legal__body p, .legal__body li { color: var(--muted); }
.legal__body b { color: var(--text); }
.legal__body a { color: var(--accent-ink); }
.legal__updated { font: 700 0.8rem var(--head); letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent-ink) !important; }
.credit-thumb { width: 96px; height: 64px; object-fit: cover; border-radius: 8px; }
.linklike { padding: 0; border: 0; background: none; color: inherit; text-decoration: underline; text-underline-offset: 3px; }
.linklike:hover { color: var(--amber); }

/* ---------- Footer ---------- */
.footer { background: var(--navy-900); color: #a9b5c6; font-size: 0.93rem; }
.footer__top { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 40px; padding: 80px 0 56px; }
.footer__logo img { width: 170px; margin: -24px 0 4px -20px; }
.footer__about p { max-width: 320px; }
.footer__about a { color: #fff; }
.footer h5 { margin: 6px 0 18px; font: 700 0.8rem var(--head); letter-spacing: 0.12em; text-transform: uppercase; color: #fff; }
.footer ul { list-style: none; margin: 0; padding: 0; }
.footer li { margin-bottom: 10px; }
.footer a { color: #a9b5c6; text-decoration: none; transition: color 0.2s; }
.footer a:hover { color: var(--amber); }
.footer__bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 14px; padding: 22px 0 30px; border-top: 1px solid rgba(255, 255, 255, 0.08); font-size: 0.85rem; }
.footer__bottom .linklike { color: #a9b5c6; }

.to-top { position: fixed; right: 22px; bottom: 22px; z-index: 90; display: grid; place-items: center; width: 48px; height: 48px; border: 0; border-radius: 50%; background: var(--navy-800); color: #fff; box-shadow: var(--shadow);
  opacity: 0; transform: translateY(12px); pointer-events: none; transition: opacity 0.3s, transform 0.3s, background 0.2s; }
.to-top.show { opacity: 1; transform: none; pointer-events: auto; }
.to-top:hover { background: var(--flame); color: var(--navy-900); }
.to-top svg { width: 20px; height: 20px; }

/* ---------- Cookie banner ---------- */
.cookie { position: fixed; left: 50%; bottom: 20px; z-index: 250; display: flex; align-items: center; gap: 24px; width: min(900px, calc(100% - 32px)); padding: 20px 24px;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg);
  opacity: 0; visibility: hidden; transform: translate(-50%, 24px); transition: opacity 0.4s var(--ease), transform 0.4s var(--ease), visibility 0.4s; }
.cookie.show { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
.cookie__text b { font: 800 1rem var(--head); color: var(--heading); }
.cookie__text p { margin: 4px 0 0; font-size: 0.88rem; color: var(--muted); }
.cookie__text a { color: var(--accent-ink); }
.cookie__actions { display: flex; flex: none; gap: 10px; }

/* ---------- Dark theme ---------- */
:root[data-theme="dark"] {
  --bg: #0b1220; --surface: #121c2e; --surface-2: #0f1829; --surface-3: #1b2840;
  --text: #d6deea; --muted: #9aa8bb; --heading: #f3f6fb; --border: #23324b; --input-border: #2f405d;
  --header-bg: rgba(11, 18, 32, 0.92); --tag-bg: rgba(11, 18, 32, 0.85); --accent-ink: #ff9a5a;
  --flame-soft: rgba(242, 107, 29, 0.16); --teal-soft: rgba(14, 140, 127, 0.22);
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4); --shadow: 0 12px 30px -12px rgba(0, 0, 0, 0.7); --shadow-lg: 0 30px 60px -24px rgba(0, 0, 0, 0.8);
  color-scheme: dark;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0b1220; --surface: #121c2e; --surface-2: #0f1829; --surface-3: #1b2840;
    --text: #d6deea; --muted: #9aa8bb; --heading: #f3f6fb; --border: #23324b; --input-border: #2f405d;
    --header-bg: rgba(11, 18, 32, 0.92); --tag-bg: rgba(11, 18, 32, 0.85); --accent-ink: #ff9a5a;
    --flame-soft: rgba(242, 107, 29, 0.16); --teal-soft: rgba(14, 140, 127, 0.22);
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4); --shadow: 0 12px 30px -12px rgba(0, 0, 0, 0.7); --shadow-lg: 0 30px 60px -24px rgba(0, 0, 0, 0.8);
    color-scheme: dark;
  }
}
[data-theme="dark"] .section--navy, [data-theme="dark"] .calc__result, [data-theme="dark"] .lab-facts div { background: #101d33; }
[data-theme="dark"] .page-hero--plain, [data-theme="dark"] .cta--plain { background: linear-gradient(120deg, #101d33, #17304f); }
[data-theme="dark"] .footer, [data-theme="dark"] .topbar { background: #070d18; }
[data-theme="dark"] .lvl--beginner { background: rgba(28, 122, 58, 0.25); color: #7fd99b; }
[data-theme="dark"] .lvl--intermediate { color: #ffb37f; }
[data-theme="dark"] .lvl--advanced { background: rgba(91, 63, 196, 0.25); color: #b9a8ff; }
.only-dark { display: none; }
[data-theme="dark"] .only-dark { display: revert; }
[data-theme="dark"] .only-light { display: none; }

/* ---------- Header tools: language, theme, sign in ---------- */
.tools { display: flex; align-items: center; gap: 6px; }
.tools--top { margin-left: 18px; padding-left: 18px; border-left: 1px solid rgba(255, 255, 255, 0.15); }
.tools--head { display: none; }
.lang { position: relative; }
.lang summary { list-style: none; display: flex; align-items: center; gap: 6px; padding: 6px 10px; border-radius: 8px; cursor: pointer; font: 600 0.82rem var(--body); }
.lang summary::-webkit-details-marker { display: none; }
.lang summary svg { width: 16px; height: 16px; }
.lang summary:hover { background: rgba(255, 255, 255, 0.1); }
.lang ul { position: absolute; right: 0; top: calc(100% + 8px); z-index: 300; min-width: 190px; margin: 0; padding: 8px; list-style: none; background: var(--surface); border: 1px solid var(--border); border-radius: 12px; box-shadow: var(--shadow-lg); }
.lang li a { display: flex; justify-content: space-between; gap: 14px; padding: 9px 12px; border-radius: 8px; color: var(--text); font-size: 0.92rem; text-decoration: none; }
.lang li a small { color: var(--muted); font-size: 0.75rem; text-transform: uppercase; }
.lang li a:hover, .lang li a[aria-current="true"] { background: var(--flame-soft); color: var(--accent-ink); }
.theme-toggle { display: grid; place-items: center; width: 34px; height: 34px; padding: 0; border: 0; border-radius: 8px; background: transparent; color: inherit; }
.theme-toggle:hover { background: rgba(255, 255, 255, 0.1); }
.theme-toggle svg { width: 18px; height: 18px; }
.theme-toggle .i-sun { display: none; }
[data-theme="dark"] .theme-toggle .i-sun { display: block; }
[data-theme="dark"] .theme-toggle .i-moon { display: none; }
.signin { display: inline-flex; align-items: center; gap: 7px; margin-left: 6px; padding: 6px 12px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, 0.3); font: 600 0.82rem var(--body); text-decoration: none; }
.signin svg { width: 15px; height: 15px; }
.signin:hover { background: var(--flame); border-color: var(--flame); color: var(--navy-900) !important; }
.tools--head .lang summary:hover, .tools--head .theme-toggle:hover { background: var(--surface-3); }
.tools--head .lang summary { color: var(--heading); }
.tools--head .theme-toggle { color: var(--heading); }
.nav__signin { display: none; }

/* ---------- Right-to-left (Arabic) ---------- */
[dir="rtl"] .checks li { padding-left: 0; padding-right: 34px; }
[dir="rtl"] .checks li::before { left: auto; right: 0; }
[dir="rtl"] .feature-list > div { padding-left: 0; padding-right: 58px; }
[dir="rtl"] .feature-list .ico { left: auto; right: 0; }
[dir="rtl"] .timeline::before { left: auto; right: 19px; }
[dir="rtl"] .timeline li { padding: 0 64px 30px 0; }
[dir="rtl"] .timeline li::before { left: auto; right: 10px; }
[dir="rtl"] .btn svg, [dir="rtl"] .link svg { transform: scaleX(-1); }
[dir="rtl"] .btn:hover svg { transform: scaleX(-1) translateX(3px); }
[dir="rtl"] .link:hover svg { transform: scaleX(-1) translateX(4px); }
[dir="rtl"] .hero::before, [dir="rtl"] .page-hero::before { background: linear-gradient(265deg, rgba(8, 17, 30, 0.92) 0%, rgba(11, 22, 38, 0.78) 42%, rgba(11, 22, 38, 0.25) 100%); }
[dir="rtl"] .media__badge { left: auto; right: -22px; }
[dir="rtl"] .card__tag { left: auto; right: 14px; }
[dir="rtl"] .phase__badge { right: auto; left: 14px; }
[dir="rtl"] .flow__node:not(:last-child)::after { right: auto; left: -14px; }
[dir="rtl"] .card__body ul, [dir="rtl"] .tab-panel__cols ul, [dir="rtl"] .legal__body ul { padding-left: 0; padding-right: 1.1em; }
[dir="rtl"] .legal__toc ol { padding-left: 0; padding-right: 1.2em; }
[dir="rtl"] th, [dir="rtl"] td { text-align: right; }
[dir="rtl"] .to-top { right: auto; left: 22px; }
[dir="rtl"] .footer__logo img { margin: -24px -20px 4px 0; }
[dir="rtl"] .browser--float { transform: perspective(1600px) rotateY(6deg) rotateX(2deg); }
[dir="rtl"] .browser--float:hover { transform: none; }
[dir="rtl"] .tools--top { margin-left: 0; padding-left: 0; border-left: 0; margin-right: 18px; padding-right: 18px; border-right: 1px solid rgba(255, 255, 255, 0.15); }
[dir="rtl"] .lang ul { right: auto; left: 0; }
[dir="rtl"] .brand { margin-right: 0; margin-left: auto; }
[dir="rtl"] .browser__bar span { margin-left: 0; margin-right: 12px; }
[dir="rtl"] .map-panel { left: auto; right: 16px; }
[dir="rtl"] .map-layers { right: auto; left: 16px; }
[dir="rtl"] .quote blockquote::before { content: "”"; }

/* ---------- Scripts other than Latin ---------- */
html[lang="ar"] { --head: "IBM Plex Sans Arabic", "Segoe UI", Tahoma, sans-serif; --body: "IBM Plex Sans Arabic", "Segoe UI", Tahoma, sans-serif; }
html[lang="hi"] { --head: "Noto Sans Devanagari", "Nirmala UI", "Mangal", sans-serif; --body: "Noto Sans Devanagari", "Nirmala UI", "Mangal", sans-serif; }
html[lang="zh"] { --head: "Noto Sans SC", "Microsoft YaHei", "PingFang SC", sans-serif; --body: "Noto Sans SC", "Microsoft YaHei", "PingFang SC", sans-serif; }
html[lang="ja"] { --head: "Noto Sans JP", "Yu Gothic", "Hiragino Sans", Meiryo, sans-serif; --body: "Noto Sans JP", "Yu Gothic", "Hiragino Sans", Meiryo, sans-serif; }
html[lang="ko"] { --head: "Noto Sans KR", "Malgun Gothic", "Apple SD Gothic Neo", sans-serif; --body: "Noto Sans KR", "Malgun Gothic", "Apple SD Gothic Neo", sans-serif; }
html[lang="ar"] h1, html[lang="ar"] h2, html[lang="ar"] h3, html[lang="ar"] h4,
html[lang="hi"] h1, html[lang="hi"] h2, html[lang="hi"] h3, html[lang="hi"] h4,
html[lang="zh"] h1, html[lang="zh"] h2, html[lang="zh"] h3, html[lang="zh"] h4,
html[lang="ja"] h1, html[lang="ja"] h2, html[lang="ja"] h3, html[lang="ja"] h4,
html[lang="ko"] h1, html[lang="ko"] h2, html[lang="ko"] h3, html[lang="ko"] h4 { letter-spacing: 0; line-height: 1.3; }
html[lang="zh"] body, html[lang="ja"] body, html[lang="ko"] body, html[lang="hi"] body, html[lang="ar"] body { line-height: 1.8; }
/* Korean wraps between words, not inside them; Japanese headings wrap at phrase boundaries where the browser supports it */
html[lang="ko"] body { word-break: keep-all; overflow-wrap: anywhere; }
html[lang="ja"] h1, html[lang="ja"] h2, html[lang="ja"] h3, html[lang="ja"] h4, html[lang="zh"] h1, html[lang="zh"] h2 { word-break: auto-phrase; text-wrap: balance; }
html[lang="ar"] .eyebrow, html[lang="zh"] .eyebrow, html[lang="ja"] .eyebrow, html[lang="ko"] .eyebrow, html[lang="hi"] .eyebrow { letter-spacing: 0.04em; }
.notice.is-ok { background: rgba(28, 122, 58, 0.12); color: #1c7a3a; font-weight: 600; }
.notice.is-error { background: rgba(192, 57, 43, 0.12); color: #c0392b; font-weight: 600; }
[data-theme="dark"] .notice.is-ok { color: #7fd99b; } [data-theme="dark"] .notice.is-error { color: #ff8a7a; }
.notice-wrap .notice { margin: 40px 0 0; }
.notice { margin: 0 0 30px; padding: 14px 18px; border-radius: var(--radius); background: var(--flame-soft); color: var(--text); font-size: 0.93rem; }

/* ---------- Client portal ---------- */
.portal-wrap { max-width: 1100px; margin-inline: auto; }
.auth { max-width: 560px; margin-inline: auto; }
.auth__tabs { display: flex; gap: 4px; padding: 5px; margin-bottom: 22px; border-radius: 999px; background: var(--surface-3); }
.auth__tabs button { flex: 1; padding: 11px 14px; border: 0; border-radius: 999px; background: transparent; font: 700 0.9rem var(--head); color: var(--muted); }
.auth__tabs button[aria-selected="true"] { background: var(--surface); color: var(--heading); box-shadow: var(--shadow-sm); }
.auth-panel[hidden], .portal-view[hidden] { display: none; }
.form .hint { margin: 6px 0 0; font-size: 0.8rem; color: var(--muted); }
.form .linkbtn { padding: 0; border: 0; background: none; color: var(--accent-ink); font: 600 0.88rem var(--body); text-decoration: underline; text-underline-offset: 3px; }
.form .row-end { display: flex; justify-content: flex-end; margin: -8px 0 16px; }
.perks { display: grid; gap: 14px; margin: 26px 0 0; padding: 0; list-style: none; }
.perks li { display: flex; gap: 12px; align-items: flex-start; font-size: 0.95rem; color: var(--muted); }
.perks svg { flex: none; width: 22px; height: 22px; color: var(--accent-ink); margin-top: 2px; }
.dash { display: grid; grid-template-columns: 1.3fr 0.7fr; gap: 26px; align-items: start; }
.panel { padding: clamp(22px, 3vw, 32px); background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); box-shadow: var(--shadow-sm); }
.panel + .panel { margin-top: 22px; }
.panel h3 { margin-bottom: 14px; }
.dash-head { display: flex; align-items: center; gap: 16px; margin-bottom: 18px; }
.avatar { display: grid; place-items: center; flex: none; width: 58px; height: 58px; border-radius: 50%; background: var(--flame); color: var(--navy-900); font: 800 1.4rem var(--head); }
.dash-head h2 { margin: 0; font-size: 1.7rem; }
.dash-head p { margin: 2px 0 0; color: var(--muted); }
.quick { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.quick a { display: flex; gap: 12px; align-items: center; padding: 16px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface-2); color: var(--heading); font: 700 0.92rem var(--head); text-decoration: none; transition: border-color 0.2s, transform 0.2s; }
.quick a:hover { border-color: var(--flame); transform: translateY(-2px); }
.quick svg { flex: none; width: 22px; height: 22px; color: var(--accent-ink); }
.facts-list { margin: 0; display: grid; grid-template-columns: auto 1fr; gap: 10px 18px; font-size: 0.93rem; }
.facts-list dt { color: var(--muted); }
.facts-list dd { margin: 0; color: var(--heading); font-weight: 600; word-break: break-word; }
.admin-tools { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.admin-tools input { max-width: 280px; }
.admin .table-wrap { max-height: 520px; overflow: auto; }
.admin td, .admin th { font-size: 0.85rem; padding: 10px 14px; white-space: nowrap; }

/* ---------- Interactive satellite map ---------- */
.map-card { position: relative; overflow: hidden; border-radius: var(--radius-lg); border: 1px solid var(--border); box-shadow: var(--shadow-lg); background: #0b1626; }
.map { height: min(72vh, 640px); background: #0b1626; }
.map--short { height: 420px; }
.map__loading { position: absolute; inset: 0; display: grid; place-items: center; color: #b8c4d4; font-size: 0.95rem; }
.map-panel { position: absolute; z-index: 500; left: 16px; top: 16px; width: 310px; max-height: calc(100% - 32px); overflow: auto; padding: 18px; border-radius: var(--radius); background: var(--header-bg); backdrop-filter: blur(10px); box-shadow: var(--shadow); }
.map-panel h3 { font-size: 1.05rem; margin-bottom: 4px; }
.map-panel > p { margin: 0 0 12px; font-size: 0.85rem; color: var(--muted); }
.map-places { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.map-places button { display: flex; gap: 10px; align-items: flex-start; width: 100%; padding: 10px; border: 1px solid transparent; border-radius: 10px; background: transparent; text-align: start; color: var(--text); }
.map-places button:hover, .map-places button.on { background: var(--flame-soft); border-color: var(--flame); }
.map-places b { display: block; font: 700 0.9rem var(--head); color: var(--heading); }
.map-places span { font-size: 0.8rem; color: var(--muted); }
.dot { flex: none; width: 12px; height: 12px; margin-top: 4px; border-radius: 50%; box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.6); }
.dot--hq { background: var(--flame); } .dot--pilot { background: var(--amber); } .dot--reach { background: #3fd0bd; }
.map-layers { position: absolute; z-index: 500; right: 16px; top: 16px; display: flex; padding: 4px; border-radius: 999px; background: var(--header-bg); box-shadow: var(--shadow); }
.map-layers button { padding: 8px 14px; border: 0; border-radius: 999px; background: transparent; font: 700 0.8rem var(--head); color: var(--muted); }
.map-layers button[aria-pressed="true"] { background: var(--flame); color: var(--navy-900); }
.map-note { margin-top: 12px; font-size: 0.8rem; color: var(--muted); }
.section--navy .map-note { color: #9aa8bb; }
.section--navy .map-card { border-color: rgba(255, 255, 255, 0.12); }
.pin { display: block; position: relative; width: 18px; height: 18px; border-radius: 50%; border: 3px solid #fff; box-shadow: 0 2px 8px rgba(0, 0, 0, 0.5); }
.pin--hq { background: var(--flame); } .pin--pilot { background: var(--amber); } .pin--reach { background: #3fd0bd; }
.pin--hq::after { content: ""; position: absolute; inset: -9px; border-radius: 50%; border: 2px solid var(--flame); animation: pulse 2s ease-out infinite; }
@keyframes pulse { from { transform: scale(0.6); opacity: 1; } to { transform: scale(1.8); opacity: 0; } }
.leaflet-container { font: inherit; }
.leaflet-popup-content-wrapper { border-radius: 12px; }
.leaflet-popup-content b { font-family: var(--head); }

.form-input { padding: 10px 14px; border: 1px solid var(--input-border); border-radius: 10px; background: var(--surface); color: var(--text); font: inherit; font-size: 0.92rem; }
.mt-md { margin-top: 20px; }

/* ---------- Page-specific pieces ---------- */
.chips--center { justify-content: center; margin-top: 36px; }
.mb-xl { margin-bottom: 54px; }
.cta--plain { background: linear-gradient(120deg, var(--navy-800), var(--navy-700)); }
.cta--plain::before { background: radial-gradient(circle at 92% 10%, rgba(242, 107, 29, 0.35), transparent 45%), radial-gradient(circle at 0% 100%, rgba(14, 140, 127, 0.3), transparent 40%); }
.page-hero--lab { background: radial-gradient(circle at 85% 20%, rgba(14, 140, 127, 0.45), transparent 50%), linear-gradient(140deg, var(--navy-900), var(--navy-800) 60%, #0d3340); }
.page-hero--lab::before { display: none; }
.page-hero--lab .container { padding: 70px 0 84px; }
.page-hero--lab .kicker { margin-bottom: 16px; }
.page-hero--lab .hero__actions { margin-top: 28px; }
.page-hero--tall .container { padding: 120px 0 140px; }
.page-hero--tall .hero__actions { margin-top: 30px; }
.shot { margin: 0; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); overflow: hidden; transition: transform 0.35s var(--ease), box-shadow 0.35s; }
.shot:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.shot img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; object-position: 30% 50%; }
.shot figcaption { padding: 16px 20px 18px; font-size: 0.85rem; color: var(--muted); }
.shot figcaption b { display: block; font: 700 1rem var(--head); color: var(--heading); margin-bottom: 2px; }
.feature-list { gap: 22px 26px; margin-top: 26px; }
.feature-list > div { position: relative; padding-left: 58px; }
.feature-list .ico { position: absolute; left: 0; top: 0; display: grid; place-items: center; width: 42px; height: 42px; border-radius: 12px; background: var(--teal-soft); color: var(--teal); }
.feature-list .ico svg { width: 22px; height: 22px; }
.feature-list h4 { margin-bottom: 4px; }
.feature-list p { margin: 0; font-size: 0.92rem; color: var(--muted); }
.page-home .feature-list .ico, .feature-list--flame .ico { background: var(--flame-soft); color: var(--accent-ink); }
.lab-card h3 svg { width: 24px; height: 24px; color: var(--teal); flex: none; }
.media--tall img { height: 100%; }

/* ---------- Reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity 0.9s var(--ease), transform 0.9s var(--ease); }
.reveal.in { opacity: 1; transform: none; }
.reveal[data-delay="1"] { transition-delay: 0.08s; } .reveal[data-delay="2"] { transition-delay: 0.16s; }
.reveal[data-delay="3"] { transition-delay: 0.24s; } .reveal[data-delay="4"] { transition-delay: 0.32s; }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .nav a { padding: 10px 8px; font-size: 0.86rem; }
  .flow { grid-template-columns: repeat(2, 1fr); }
  .flow__node--core { grid-column: 1 / -1; }
  .flow__node::after { display: none; }
  .lab-facts { grid-template-columns: repeat(3, 1fr); }
  .projects, .grid-4, .align, .rings { grid-template-columns: repeat(2, 1fr); }
  .pathway { grid-template-columns: repeat(2, 1fr); }
  .footer__top { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 960px) {
  .topbar__links span { display: none; }
  .nav-toggle { display: grid; place-items: center; }
  .tools--head { display: flex; }
  .nav .nav__signin { display: block; }
  .dash { grid-template-columns: 1fr; }
  .header__cta { display: none; }
  body.menu-open { overflow: hidden; }
  .nav { position: fixed; top: var(--nav-top, 78px); right: 0; bottom: 0; left: 0; z-index: 99; flex-direction: column; align-items: stretch; gap: 0; padding: 18px 20px 40px; background: var(--surface); overflow-y: auto;
    opacity: 0; visibility: hidden; transform: translateY(-8px); transition: opacity 0.3s, transform 0.3s, visibility 0.3s; }
  .menu-open .nav { opacity: 1; visibility: visible; transform: none; }
  .nav a { padding: 16px 6px; font-size: 1.1rem; border-bottom: 1px solid var(--border); border-radius: 0; }
  .nav a[aria-current="page"]::after { display: none; }
  .nav .nav__cta { display: block; margin-top: 18px; text-align: center; border: 0; }
  .split, .split--wide, .contact, .calc, .quote, .founders, .legal, .tab-panel.active { grid-template-columns: 1fr; }
  .split--reverse > :first-child { order: 0; }
  .grid-3, .phases, .family { grid-template-columns: 1fr 1fr; }
  .stats__grid { grid-template-columns: 1fr 1fr; }
  .stat:nth-child(2) { border-right: 0; }
  .stat:nth-child(-n+2) { border-bottom: 1px solid var(--border); }
  .steps { grid-template-columns: 1fr 1fr; row-gap: 36px; }
  .steps::before { display: none; }
  .gallery { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 200px; }
  .media__badge { left: 14px; }
  .legal__toc { position: static; }
  .tab-panel > img { min-height: 240px; max-height: 300px; }
  .proposal dl { grid-template-columns: 1fr; }
  .proposal dt { border-bottom: 0; padding-bottom: 0; }
  .browser--float { transform: none; }
}
@media (min-width: 961px) { .nav .nav__cta { display: none; } }
@media (max-width: 640px) {
  body { font-size: 16px; }
  .topbar { display: none; }
  .hero { min-height: 0; }
  .hero__content { padding: 70px 0 130px; }
  .hero__actions .btn, .cta__actions .btn { width: 100%; }
  .grid-2, .grid-3, .grid-4, .phases, .family, .align, .rings, .pathway, .duo, .tab-panel__cols, .form .row { grid-template-columns: 1fr; }
  .projects { grid-template-columns: 1fr 1fr; gap: 12px; }
  .project figcaption { padding: 10px 12px 12px; }
  .project b { font-size: 0.88rem; }
  .media__badge { position: relative; left: auto; bottom: auto; max-width: none; margin: -36px 14px 0; }
  [dir="rtl"] .media__badge { right: auto; }
  .header .container { gap: 10px; }
  .map-panel { position: static; width: auto; max-height: none; border-radius: 0; backdrop-filter: none; box-shadow: none; }
  .map { height: 420px; }
  .quick { grid-template-columns: 1fr; }
  .duo figure:last-child { margin-top: 0; }
  .lab-facts { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: 1fr; }
  .gallery { grid-template-columns: 1fr 1fr; grid-auto-rows: 150px; }
  .footer__top { grid-template-columns: 1fr; }
  .cookie { flex-direction: column; align-items: stretch; gap: 14px; bottom: 10px; }
  .cookie__actions .btn { flex: 1; }
  th, td { padding: 12px 14px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; }
}
@media print {
  .topbar, .header, .footer, .cookie, .to-top, .cta, .tabs__list, .proposal__actions, .hero__actions, .page-hero__bg, .no-print { display: none !important; }
  .page-hero, .section--navy, .section--teal { background: var(--surface) !important; color: #111 !important; }
  .page-hero::before { display: none; }
  .page-hero h1, .page-hero p, .section--navy h2, .section--navy h3 { color: #111 !important; }
  .reveal { opacity: 1 !important; transform: none !important; }
  .section { padding: 24px 0; }
  .proposal { box-shadow: none; border: 0; padding: 0; }
  .timeline li::before { border-color: #333; }
}

/* ---------- Proposal viewer ---------- */
.viewer { background: #0a1424; border-radius: 18px; overflow: hidden; border: 1px solid rgba(255,255,255,0.08); box-shadow: 0 24px 60px rgba(0,0,0,0.35); }
.viewer__bar { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; padding: 12px 16px; background: #0f1f35; border-bottom: 1px solid rgba(255,255,255,0.08); }
.viewer__title b { display: block; font: 700 0.98rem var(--head); color: #fff; }
.viewer__title span { font-size: 0.8rem; color: rgba(255,255,255,0.6); }
.viewer__nav, .viewer__tools { display: flex; align-items: center; gap: 8px; }
.viewer__btn { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 10px; border: 1px solid rgba(255,255,255,0.16); background: rgba(255,255,255,0.06); color: #fff; cursor: pointer; transition: background 0.2s, border-color 0.2s; }
.viewer__btn:hover, .viewer__btn:focus-visible { background: rgba(242,107,29,0.18); border-color: var(--flame); }
.viewer__btn svg { width: 18px; height: 18px; }
[data-viewer-prev] svg { transform: rotate(180deg); }
[dir="rtl"] [data-viewer-prev] svg { transform: none; } [dir="rtl"] [data-viewer-next] svg { transform: rotate(180deg); }
.viewer__count { min-width: 84px; text-align: center; font: 700 0.92rem var(--head); color: #fff; font-variant-numeric: tabular-nums; }
.viewer__tools .btn { padding: 10px 18px; font-size: 0.88rem; }
.viewer__body { display: grid; grid-template-columns: 150px 1fr; height: min(84vh, 1000px); }
.viewer__thumbs { overflow-y: auto; padding: 14px 12px; display: flex; flex-direction: column; gap: 12px; background: #08111f; border-inline-end: 1px solid rgba(255,255,255,0.06); scrollbar-width: thin; }
.viewer__thumb { position: relative; padding: 0; border: 2px solid transparent; border-radius: 6px; background: none; cursor: pointer; opacity: 0.6; transition: opacity 0.2s, border-color 0.2s; }
.viewer__thumb img { display: block; width: 100%; height: auto; border-radius: 4px; }
.viewer__thumb span { position: absolute; bottom: 4px; inset-inline-end: 4px; min-width: 20px; padding: 1px 5px; border-radius: 6px; background: rgba(15,31,53,0.85); color: #fff; font: 700 0.7rem var(--head); }
.viewer__thumb:hover { opacity: 0.9; }
.viewer__thumb.is-active { opacity: 1; border-color: var(--flame); }
.viewer__pages { overflow-y: auto; padding: 24px; display: flex; flex-direction: column; align-items: center; gap: 24px; outline: none; scrollbar-width: thin; }
.viewer__pages:focus-visible { box-shadow: inset 0 0 0 2px var(--flame); }
.viewer__page { margin: 0; width: 100%; max-width: 880px; flex: 0 0 auto; aspect-ratio: 1240 / 1754; background: #fff; box-shadow: 0 12px 32px rgba(0,0,0,0.45); }
.viewer__page img { display: block; width: 100%; height: 100%; }
.viewer__note { display: none; margin: 0; padding: 10px 16px; font-size: 0.82rem; color: rgba(255,255,255,0.62); border-top: 1px solid rgba(255,255,255,0.08); }
html:not([lang="en"]) .viewer__note { display: block; }
.viewer:fullscreen { border-radius: 0; display: flex; flex-direction: column; }
.viewer:fullscreen .viewer__body { flex: 1; height: auto; min-height: 0; }
.viewer__head { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; flex-wrap: wrap; margin-bottom: 26px; }
.viewer__head h2 { margin: 0; }
@media (max-width: 760px) {
  .viewer { border-radius: 12px; }
  .viewer__body { grid-template-columns: 1fr; height: 78vh; }
  .viewer__thumbs, .viewer__title span, .viewer__tools .btn { display: none; }
  .viewer__pages { padding: 12px; gap: 12px; }
  .viewer__bar { padding: 10px 12px; }
  .viewer__title b { font-size: 0.9rem; }
}
