/* Ludoitte — wholesome evening palette. Fredoka for display, Nunito for body, both self-hosted. */

@font-face {
  font-family: "Fredoka";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("/assets/fonts/fredoka-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Fredoka";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("/assets/fonts/fredoka-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Nunito";
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url("/assets/fonts/nunito-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Nunito";
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url("/assets/fonts/nunito-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  --bg: #0f2438;
  --bg-deep: #0b1c2d;
  --surface: #17304a;
  --surface-2: #1b374f;
  --line: rgba(246, 222, 184, 0.12);
  --line-strong: rgba(246, 222, 184, 0.26);

  --text: #f3e6d3;
  --heading: #f6dcb4;
  --muted: #c9c0ae;
  --muted-2: #9a917f;

  --blue: #2f84d6;
  --green: #49a35a;
  --yellow: #f8b004;
  --red: #ea4a40;
  --coral: #e2693d;
  --glow: #f2a65a;

  --btn: #24507a;
  --btn-hover: #2c6193;

  --tri: #7fc4ff;
  --dd: #f0b24a;
  --em: #4fd1e0;

  --font-display: "Fredoka", "Segoe UI Rounded", "Arial Rounded MT Bold", system-ui, sans-serif;
  --font-body: "Nunito", "Segoe UI", system-ui, sans-serif;

  --wrap: 1180px;
  --gutter: clamp(20px, 4vw, 40px);
  --radius: 22px;
  --radius-sm: 14px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
  --shadow: 0 24px 48px -28px rgba(0, 0, 0, 0.7);
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  background: var(--bg);
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font-body);
  font-size: 16.5px;
  line-height: 1.65;
  color: var(--text);
  background:
    radial-gradient(1200px 600px at 85% -10%, rgba(242, 166, 90, 0.16), transparent 60%),
    radial-gradient(900px 500px at -10% 30%, rgba(47, 132, 214, 0.12), transparent 60%),
    linear-gradient(180deg, #0e2337 0%, var(--bg) 40%, #0e2133 100%);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, svg, picture { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
:focus-visible { outline: 3px solid var(--yellow); outline-offset: 3px; border-radius: 6px; }

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

.skip-link {
  position: absolute; left: 12px; top: -48px;
  padding: 8px 14px; background: var(--heading); color: var(--bg-deep);
  border-radius: 8px; font-weight: 700; z-index: 100;
  transition: top 0.2s var(--ease);
}
.skip-link:focus { top: 12px; }

/* ---------- Topbar ---------- */
.topbar {
  position: sticky; top: 0; z-index: 50;
  background: rgba(14, 35, 55, 0.6);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s var(--ease), background 0.3s var(--ease);
}
.topbar.is-scrolled { border-bottom-color: var(--line); background: rgba(14, 35, 55, 0.88); }
.topbar__inner { display: flex; align-items: center; justify-content: space-between; height: 76px; gap: 24px; }

.brand { display: inline-flex; align-items: center; }
.brand img { height: 46px; width: auto; }
/* The animated file carries headroom for the bounce, so it needs a taller box to show the same logo size. */
.brand img.brand__animated { height: 55px; }
@media (max-width: 480px) { .brand img, .brand img.brand__animated { height: 40px; } }

.topnav { display: flex; align-items: center; gap: clamp(14px, 2.2vw, 30px); font-size: 15px; font-weight: 700; color: var(--muted); }
.topnav a { padding: 6px 0; position: relative; transition: color 0.2s var(--ease); }
.topnav a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 3px; border-radius: 3px;
  background: var(--yellow); transform: scaleX(0); transform-origin: left;
  transition: transform 0.25s var(--ease);
}
.topnav a:hover, .topnav a:focus-visible { color: var(--text); }
.topnav a:hover::after, .topnav a:focus-visible::after { transform: scaleX(1); }
.topnav .pill {
  padding: 9px 16px; border-radius: 999px; color: var(--text);
  background: var(--coral); border: 0; font-weight: 800; font-size: 14px;
  transition: transform 0.2s var(--ease), background 0.2s var(--ease);
}
.topnav .pill::after { display: none; }
.topnav .pill:hover { background: #ec7748; transform: translateY(-1px); }

.menu-toggle {
  display: none; appearance: none; background: none; border: 2px solid var(--line-strong);
  color: var(--text); width: 44px; height: 44px; border-radius: 14px; cursor: pointer;
  align-items: center; justify-content: center;
}
.menu-toggle span { display: block; width: 18px; height: 2px; border-radius: 2px; background: currentColor; position: relative; transition: transform 0.25s var(--ease), background 0.25s var(--ease); }
.menu-toggle span::before, .menu-toggle span::after {
  content: ""; position: absolute; left: 0; width: 18px; height: 2px; border-radius: 2px; background: currentColor; transition: transform 0.25s var(--ease), top 0.25s var(--ease);
}
.menu-toggle span::before { top: -6px; }
.menu-toggle span::after { top: 6px; }
.menu-toggle[aria-expanded="true"] span { background: transparent; }
.menu-toggle[aria-expanded="true"] span::before { top: 0; transform: rotate(45deg); }
.menu-toggle[aria-expanded="true"] span::after { top: 0; transform: rotate(-45deg); }

@media (max-width: 860px) {
  .menu-toggle { display: inline-flex; }
  .topnav {
    position: absolute; left: 0; right: 0; top: 76px;
    flex-direction: column; align-items: stretch; gap: 0;
    background: #10263c; border-bottom: 1px solid var(--line);
    padding: 8px var(--gutter) 18px;
    display: none;
  }
  .topnav.is-open { display: flex; }
  .topnav a { font-size: 18px; padding: 14px 0; border-bottom: 1px solid var(--line); color: var(--text); }
  .topnav a::after { display: none; }
  .topnav .pill { margin-top: 14px; text-align: center; border-bottom: 0; }
}

/* ---------- Type ---------- */
.eyebrow {
  margin: 0 0 16px;
  font-size: 14px; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; color: var(--yellow);
}

h1, h2, h3 { font-family: var(--font-display); font-weight: 600; letter-spacing: -0.005em; margin: 0; color: var(--heading); }
.display {
  font-size: clamp(38px, 5.4vw, 66px); font-weight: 600; line-height: 1.06;
  max-width: 16ch; text-wrap: balance;
}
.section__title { font-size: clamp(30px, 3.4vw, 42px); font-weight: 600; line-height: 1.12; }
.section__lede { margin: 12px 0 0; max-width: 60ch; color: var(--muted); font-size: 17.5px; }
.lede { margin: 24px 0 0; max-width: 50ch; color: var(--muted); font-size: clamp(17px, 1.5vw, 20px); line-height: 1.6; }

.center { text-align: center; }
.center .section__lede { margin-inline: auto; }

/* ---------- Buttons ---------- */
.actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 34px; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 50px; padding: 0 24px; border-radius: 16px;
  font-family: var(--font-body); font-size: 16px; font-weight: 800; line-height: 1;
  border: 2px solid transparent; cursor: pointer; color: var(--text);
  transition: transform 0.2s var(--ease), background 0.2s var(--ease), border-color 0.2s var(--ease), color 0.2s var(--ease);
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }
.btn--primary { background: var(--btn); border-color: rgba(246, 222, 184, 0.18); }
.btn--primary:hover { background: var(--btn-hover); }
.btn--ghost { border-color: var(--line-strong); background: rgba(246, 222, 184, 0.03); color: var(--heading); }
.btn--ghost:hover { border-color: var(--heading); background: rgba(246, 222, 184, 0.07); }
.btn svg { width: 18px; height: 18px; }

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: clip;
  padding: clamp(24px, 5vh, 64px) 0 clamp(40px, 6vh, 72px);
}
.hero__inner {
  display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  gap: clamp(24px, 4vw, 56px); align-items: center;
}
.hero__copy { position: relative; z-index: 1; }
.hero__scene { position: relative; min-height: 320px; }
.hero__scene::before {
  content: ""; position: absolute; inset: -10% -14% -4% -14%; z-index: 0; pointer-events: none;
  background:
    radial-gradient(60% 55% at 50% 70%, rgba(242, 166, 90, 0.34), transparent 70%),
    radial-gradient(70% 60% at 50% 40%, rgba(47, 132, 214, 0.12), transparent 70%);
  filter: blur(6px);
}
.hero__stars {
  position: absolute; inset: 0; z-index: 0; pointer-events: none; opacity: 0.9;
  background-image:
    radial-gradient(1.6px 1.6px at 12% 18%, rgba(246, 220, 180, 0.9), transparent 60%),
    radial-gradient(1.2px 1.2px at 28% 8%, rgba(246, 220, 180, 0.8), transparent 60%),
    radial-gradient(1.8px 1.8px at 46% 14%, rgba(246, 220, 180, 0.9), transparent 60%),
    radial-gradient(1.2px 1.2px at 66% 6%, rgba(246, 220, 180, 0.75), transparent 60%),
    radial-gradient(1.6px 1.6px at 84% 16%, rgba(246, 220, 180, 0.9), transparent 60%),
    radial-gradient(1.2px 1.2px at 92% 32%, rgba(246, 220, 180, 0.7), transparent 60%),
    radial-gradient(1.4px 1.4px at 6% 40%, rgba(246, 220, 180, 0.7), transparent 60%),
    radial-gradient(1.2px 1.2px at 74% 28%, rgba(246, 220, 180, 0.6), transparent 60%);
}
.hero__art { position: relative; z-index: 1; width: 100%; height: auto; filter: drop-shadow(0 30px 40px rgba(0, 0, 0, 0.45)); }
@media (max-width: 860px) {
  .hero__inner { grid-template-columns: minmax(0, 1fr); }
  .hero__scene { order: 2; width: min(100%, 560px); margin-inline: auto; min-height: 0; min-width: 0; }
  .hero__copy { order: 1; }
  .display { max-width: 20ch; }
}

/* ---------- Sections ---------- */
.section { padding: clamp(56px, 7vw, 96px) 0; }
.section--tight { padding-top: clamp(20px, 3vw, 36px); }
.section__head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: clamp(24px, 3vw, 40px); flex-wrap: wrap; }
.section__head.center { flex-direction: column; align-items: center; }

/* ---------- Product cards ---------- */
.products { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(16px, 2vw, 26px); }
@media (max-width: 920px) { .products { grid-template-columns: 1fr; max-width: 560px; margin-inline: auto; } }

.card {
  --accent: var(--heading);
  position: relative; display: flex; flex-direction: column;
  background: linear-gradient(180deg, var(--surface-2) 0%, var(--surface) 100%);
  border: 1px solid var(--line);
  border-radius: var(--radius); overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform 0.3s var(--ease), border-color 0.3s var(--ease);
}
.card:hover, .card:focus-within { transform: translateY(-5px); border-color: var(--line-strong); }
.card--triviai { --accent: var(--tri); }
.card--dropdungeon { --accent: var(--dd); }
.card--evermail { --accent: var(--em); }

.card__art {
  display: flex; align-items: center; justify-content: center;
  height: 210px; padding: 30px 30px 10px;
  background: radial-gradient(70% 80% at 50% 100%, color-mix(in srgb, var(--accent) 16%, transparent), transparent 70%);
}
.card__art img { max-height: 100%; width: auto; object-fit: contain; filter: drop-shadow(0 16px 26px rgba(0, 0, 0, 0.5)); }
.card--evermail .card__art img { max-height: 112px; }
.card--triviai .card__art img { max-height: 160px; }

.card__body { padding: 8px 28px 28px; display: flex; flex-direction: column; flex: 1; }
.card__title { font-size: 28px; }
.card__tagline { margin: 4px 0 0; color: var(--text); font-weight: 800; font-size: 15.5px; }
.card__desc { margin: 12px 0 0; color: var(--muted); font-size: 15.5px; line-height: 1.6; flex: 1; }
.card__meta { margin: 16px 0 0; display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  font-size: 12.5px; font-weight: 700; color: var(--muted);
  padding: 4px 11px; border: 1px solid var(--line); border-radius: 999px;
}
.card__link {
  margin-top: 22px; display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 46px; padding: 0 20px; border-radius: 14px;
  font-size: 15.5px; font-weight: 800; color: var(--text);
  background: color-mix(in srgb, var(--accent) 22%, var(--surface));
  border: 1px solid color-mix(in srgb, var(--accent) 40%, transparent);
  transition: background 0.25s var(--ease);
}
.card:hover .card__link { background: color-mix(in srgb, var(--accent) 34%, var(--surface)); }
.card__link svg { width: 18px; height: 18px; transition: transform 0.25s var(--ease); }
.card:hover .card__link svg { transform: translateX(4px); }
.card__link::after { content: ""; position: absolute; inset: 0; }

/* ---------- Studio strip ---------- */
.strip {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: clamp(26px, 3.4vw, 40px) clamp(22px, 3.4vw, 44px);
  box-shadow: var(--shadow);
}
.strip__head { text-align: center; margin-bottom: clamp(20px, 3vw, 32px); }
.strip__head .section__lede { margin-inline: auto; }
.tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(16px, 2.4vw, 32px); }
@media (max-width: 980px) { .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .tiles { grid-template-columns: 1fr; } }
.tile { display: grid; grid-template-columns: 72px 1fr; gap: 16px; align-items: start; }
.tile__icon { width: 72px; height: 72px; display: grid; place-items: center; }
.tile__icon img { max-width: 72px; max-height: 72px; width: auto; height: auto; filter: drop-shadow(0 10px 14px rgba(0, 0, 0, 0.4)); }
.tile h3 { font-size: 19px; line-height: 1.25; }
.tile p { margin: 6px 0 0; color: var(--muted); font-size: 14.5px; line-height: 1.55; }
@media (max-width: 520px) { .tile { grid-template-columns: 60px 1fr; } .tile__icon, .tile__icon img { width: 60px; max-width: 60px; } }

/* ---------- Work with us panel ---------- */
.panel {
  position: relative; border-radius: var(--radius);
  padding: clamp(26px, 3.4vw, 40px) clamp(22px, 3.4vw, 44px);
  background: linear-gradient(135deg, #1b3a55 0%, var(--surface) 60%);
  border: 1px solid var(--line-strong);
  box-shadow: var(--shadow);
  display: grid; grid-template-columns: 200px 1fr auto; gap: clamp(18px, 3vw, 40px); align-items: center;
}
.panel__art img { width: 200px; height: auto; filter: drop-shadow(0 20px 30px rgba(0, 0, 0, 0.5)); }
.panel h2 { font-size: clamp(24px, 2.4vw, 32px); line-height: 1.2; }
.panel p { margin: 10px 0 0; color: var(--muted); max-width: 58ch; font-size: 16px; }
@media (max-width: 860px) {
  .panel { grid-template-columns: 1fr; text-align: center; }
  .panel__art { margin-inline: auto; }
  .panel p { margin-inline: auto; }
  .panel .btn { justify-self: center; }
}

/* ---------- About ---------- */
.about { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 72px); align-items: start; }
@media (max-width: 860px) { .about { grid-template-columns: 1fr; } }
.about__text p { margin: 0 0 16px; color: var(--muted); font-size: 17px; max-width: 60ch; }
.about__text .about__lead { margin-top: 18px; }
.about__text p strong { color: var(--text); font-weight: 800; }
.facts { list-style: none; margin: 0; padding: 6px 22px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.facts li { display: flex; justify-content: space-between; gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--line); font-size: 15.5px; }
.facts li:last-child { border-bottom: 0; }
.facts .k { color: var(--muted-2); }
.facts .v { text-align: right; font-weight: 700; }

/* ---------- FAQ ---------- */
.faq { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 24px; }
@media (max-width: 860px) { .faq { grid-template-columns: 1fr; } }
.faq details {
  border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface);
  transition: border-color 0.2s var(--ease);
}
.faq details[open] { border-color: var(--line-strong); }
.faq summary {
  list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 16px 20px; font-weight: 800; font-size: 16px; color: var(--text);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; flex: none; width: 10px; height: 10px;
  border-right: 2.5px solid var(--yellow); border-bottom: 2.5px solid var(--yellow);
  transform: rotate(45deg); margin-right: 4px; transition: transform 0.25s var(--ease);
}
.faq details[open] summary::after { transform: rotate(225deg); }
.faq .faq__a { padding: 0 20px 18px; margin: 0; color: var(--muted); font-size: 15.5px; line-height: 1.6; }
.faq .faq__a a, .about a, .contact a { color: var(--heading); text-decoration: underline; text-decoration-color: var(--line-strong); text-underline-offset: 3px; }
.faq .faq__a a:hover, .contact a:hover { text-decoration-color: var(--yellow); }

/* ---------- Contact ---------- */
.contact { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(16px, 2vw, 28px); }
@media (max-width: 860px) { .contact { grid-template-columns: 1fr; } }
.contact__block { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px 24px; }
.contact__block h3 { font-family: var(--font-body); font-size: 13px; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; color: var(--yellow); margin-bottom: 10px; }
.contact__block p { margin: 0; color: var(--muted); font-size: 15.5px; line-height: 1.75; }
.contact__block a { text-decoration: none; color: var(--text); }
.contact__block a:hover { text-decoration: underline; text-underline-offset: 3px; }

/* ---------- Footer ---------- */
.footer { padding: 0 0 40px; margin-top: clamp(24px, 4vw, 56px); font-size: 14px; color: var(--muted-2); }
.footer__card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: clamp(24px, 3vw, 36px) clamp(22px, 3vw, 40px);
  display: grid; grid-template-columns: minmax(0, 1.3fr) auto auto minmax(0, 1fr); gap: clamp(20px, 3vw, 40px); align-items: center;
  box-shadow: var(--shadow);
}
.footer__brand img { height: 56px; width: auto; }
.footer__blurb { margin: 14px 0 0; color: var(--muted); max-width: 30ch; font-size: 15px; line-height: 1.55; }
.footer__col h3 { font-family: var(--font-body); font-size: 13px; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; color: var(--yellow); margin-bottom: 10px; }
.footer__col a { display: block; padding: 4px 0; color: var(--muted); font-weight: 700; font-size: 15px; }
.footer__col a:hover { color: var(--text); }
.footer__sign { justify-self: end; }
.footer__sign img { width: min(100%, 220px); height: auto; filter: drop-shadow(0 18px 26px rgba(0, 0, 0, 0.5)); }
.footer__legal { margin-top: 18px; text-align: center; font-size: 13.5px; }
.footer__legal strong { color: var(--muted); font-weight: 800; }
@media (max-width: 920px) {
  .footer__card { grid-template-columns: 1fr 1fr; align-items: start; }
  .footer__brand { grid-column: 1 / -1; }
  .footer__sign { grid-column: 1 / -1; justify-self: center; }
}

/* ---------- Documents (privacy, terms, 404) ---------- */
.doc-page .topbar { background: rgba(14, 35, 55, 0.88); border-bottom-color: var(--line); }
.doc { max-width: 760px; padding: clamp(48px, 7vw, 88px) 0 40px; }
.doc__title { font-size: clamp(36px, 4.6vw, 54px); line-height: 1.05; }
.doc__meta { margin: 14px 0 34px; color: var(--muted-2); font-size: 15px; }
.doc h2 { font-size: 24px; margin: 40px 0 12px; }
.doc h3 { font-size: 18px; margin: 24px 0 8px; color: var(--text); }
.doc p, .doc li { color: var(--muted); font-size: 16.5px; line-height: 1.7; }
.doc p { margin: 0 0 14px; }
.doc a { color: var(--heading); text-decoration: underline; text-decoration-color: var(--line-strong); text-underline-offset: 3px; }
.doc a:hover { text-decoration-color: var(--yellow); }
.doc ul, .doc ol { padding-left: 22px; margin: 0 0 16px; }
.doc code { font-family: Consolas, "SF Mono", Menlo, monospace; font-size: 0.92em; color: var(--heading); background: var(--surface); border: 1px solid var(--line); border-radius: 6px; padding: 1px 7px; }
.doc li { margin: 6px 0; }
.doc strong { color: var(--text); }
.doc__sections { counter-reset: sec; list-style: none; padding-left: 0; }
.doc__sections > li { counter-increment: sec; margin: 0; }
.doc__sections > li h2::before { content: counter(sec) ". "; color: var(--yellow); }
.doc__related { margin-top: 40px; padding-top: 20px; border-top: 1px solid var(--line); font-size: 15px; }
.doc-page .footer__simple { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px 28px; padding-top: 24px; border-top: 1px solid var(--line); }
.doc-page .footer__links { display: flex; gap: 22px; }
.doc-page .footer__links a { color: var(--muted); font-weight: 700; }
.doc-page .footer__links a:hover { color: var(--text); }
.doc-page .footer__copy { width: 100%; }

/* ---------- Brand page ---------- */
.doc--wide { max-width: 860px; }
.logo-stage { margin: 8px 0 40px; padding: clamp(24px, 4vw, 48px); background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); display: grid; place-items: center; gap: 14px; cursor: pointer; }
.logo-stage__svg { width: min(100%, 460px); height: auto; }
.logo-stage__hint { margin: 0; color: var(--muted-2); font-size: 14px; }
.downloads { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin: 0 0 12px; }
@media (max-width: 720px) { .downloads { grid-template-columns: 1fr; } }
.download { display: flex; flex-direction: column; gap: 8px; padding: 20px 22px; background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--radius); transition: transform 0.2s var(--ease), border-color 0.2s var(--ease); }
.doc .download, .doc .download:hover { text-decoration: none; }
.download:hover { transform: translateY(-2px); border-color: var(--heading); }
.download strong { font-family: var(--font-display); font-size: 20px; color: var(--heading); }
.download span { color: var(--muted); font-size: 15px; line-height: 1.5; }
.download strong::after { content: " ↓"; color: var(--yellow); }
.sprite-demo { display: grid; grid-template-columns: auto 1fr; gap: 20px; align-items: center; margin: 0 0 12px; padding: 20px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
@media (max-width: 720px) { .sprite-demo { grid-template-columns: 1fr; justify-items: center; } }
.sprite { width: 256px; height: 192px; background-repeat: no-repeat; background-size: 800% auto; background-position: 0 0; border-radius: 12px; background-color: var(--bg-deep); }
.sprite-demo__controls { display: flex; flex-wrap: wrap; gap: 10px; }
.sprite-demo__controls .btn { min-height: 42px; padding: 0 16px; font-size: 14.5px; }
.swatches { list-style: none; padding: 0; margin: 0 0 16px; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
@media (max-width: 720px) { .swatches { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.swatches li { display: grid; gap: 4px; padding: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm); font-size: 14px; color: var(--muted); margin: 0; }
.swatches strong { color: var(--text); }
.swatches em { color: var(--muted-2); font-style: normal; font-size: 13px; }
.swatch { display: block; height: 44px; border-radius: 10px; border: 1px solid rgba(0, 0, 0, 0.25); }
.swatch--blue { background: #0c64b8; } .swatch--green { background: #3c8c4c; } .swatch--yellow { background: #f8b004; } .swatch--red { background: #e4342c; }
.swatch--ink { background: #041c3c; } .swatch--cream { background: #f7efe1; } .swatch--paper { background: #fdfaf5; } .swatch--navy { background: #0f2438; }

.notfound { text-align: center; padding: clamp(80px, 16vh, 180px) 0; }
.notfound .display { margin-inline: auto; }
.notfound .lede { margin-inline: auto; }
.notfound .actions { justify-content: center; }

/* ---------- Reveal ---------- */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.6s var(--ease), transform 0.6s var(--ease); }
.reveal.is-visible { 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; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .btn, .card, .topnav a::after { transition: none; }
}
.no-js .reveal { opacity: 1; transform: none; }

@media print {
  .topbar, .hero__scene, .footer__links { display: none; }
  body { background: #fff; color: #000; }
}
