@font-face {
  font-family: Manrope; font-style: normal; font-weight: 200 800; font-display: swap;
  src: url("/assets/manrope-cyrillic.woff2") format("woff2");
  unicode-range: U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116;
}
@font-face {
  font-family: Manrope; font-style: normal; font-weight: 200 800; font-display: swap;
  src: url("/assets/manrope-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF,U+2000-206F,U+20AC,U+2122,U+2212;
}

:root {
  color-scheme: dark;
  --background: #101118;
  --panel: #191b26;
  --raised: #222433;
  --line: #343748;
  --text: #f5f3ef;
  --muted: #b6b8c7;
  --gold: #ffd296;
  --gold-strong: #f2a45f;
  --blue: #cbd2ff;
  --radius: 18px;
  font-family: Manrope, system-ui, sans-serif;
  font-weight: 500;
  line-height: 1.55;
  scroll-padding-top: 96px;
}

*, *::before, *::after { box-sizing: border-box; }
body {
  background: var(--background);
  color: var(--text);
  margin: 0;
}
a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; }
button, summary, select { cursor: pointer; }
img { display: block; max-width: 100%; }
h1, h2, h3, p { margin: 0; }
h1, h2, h3 { line-height: 1.13; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 4px; }
.visually-hidden, .skip:not(:focus) {
  clip-path: inset(50%); width: 1px; height: 1px; overflow: hidden;
  white-space: nowrap; position: absolute;
}
.skip:focus {
  position: fixed; top: .55rem; left: 1rem; z-index: 30;
  padding: .65rem 1rem; background: var(--gold); color: #141014; border-radius: 8px;
}

.site-header {
  background: rgba(16, 17, 24, .96);
  border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 10;
  backdrop-filter: blur(18px);
}
.header-inner {
  max-width: 1560px; min-height: 70px; margin: 0 auto;
  display: flex; justify-content: space-between; align-items: center;
  gap: 1rem; padding: 10px clamp(18px, 3.25vw, 54px);
}
.wordmark { display: inline-flex; align-items: center; gap: 11px; white-space: nowrap; flex-shrink: 0; }
.wordmark img { width: auto; height: 34px; }
.wordmark span { color: var(--muted); font-size: .82rem; font-weight: 750; border-left: 1px solid var(--line); padding-left: 10px; }
.header-actions, .hero-actions, .article-actions, .footer-links { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; }
.header-actions { justify-content: flex-end; }
.button, .language, .search-button {
  display: inline-flex; justify-content: center; align-items: center; gap: .6rem;
  min-height: 44px; padding: .58rem 1rem; border-radius: 9px;
  border: 1px solid transparent; font-size: .88rem; font-weight: 800; white-space: nowrap;
}
.primary { background: linear-gradient(105deg, #ffd79d, #f6a765); color: #211418; }
.primary:hover { background: #ffe2bc; }
.quiet { background: #222431; color: var(--text); border-color: var(--line); }
.quiet:hover, .language:hover, .search-button:hover { border-color: #747995; background: #2c2f42; }
.language, .search-button { background: transparent; color: var(--muted); border-color: var(--line); }
.language { padding-inline: .65rem; }
.search-icon { width: 14px; height: 14px; border: 1.5px solid currentColor; border-radius: 50%; position: relative; margin-right: .2rem; }
.search-icon::after { position: absolute; right: -4px; bottom: -2px; width: 6px; height: 1.5px; background: currentColor; transform: rotate(48deg); content: ""; }

.page-shell {
  max-width: 1560px; margin: 0 auto; padding: 25px clamp(18px, 3.25vw, 54px) 38px;
  display: grid; grid-template-columns: clamp(182px, 17vw, 230px) minmax(0, 1fr); gap: clamp(20px, 2.55vw, 42px);
  align-items: start;
}
.page-content { min-width: 0; }
.sidebar {
  position: sticky; top: 94px; max-height: calc(100dvh - 111px);
  overflow-y: auto; scrollbar-width: thin; scrollbar-color: var(--line) transparent;
}
.guide-menu { padding: 13px 13px 11px; background: #151721; border: 1px solid #292c3e; border-radius: var(--radius); }
.guide-menu > summary { padding: .35rem .55rem .65rem; font-weight: 800; }
.nav-group + .nav-group { border-top: 1px solid #2c2f3d; margin-top: 8px; padding-top: 8px; }
.nav-group h2 { color: var(--muted); font-size: .7rem; font-weight: 800; padding: .4rem .58rem; letter-spacing: .075em; text-transform: uppercase; }
.nav-group ul, .article-toc ul, .sources, .game-gallery { list-style: none; margin: 0; padding: 0; }
.nav-group a { display: block; padding: .38rem .58rem; border-radius: 7px; color: #e0e0ec; font-size: .79rem; line-height: 1.35; }
.nav-group a:hover, .nav-group a[aria-current] { background: #302739; color: var(--gold); }

.hero {
  position: relative; display: grid; grid-template-columns: minmax(285px, .9fr) minmax(0, 1.15fr);
  min-height: 420px; align-items: center; isolation: isolate; overflow: hidden;
  border: 1px solid #504053; border-radius: 25px;
  background: radial-gradient(ellipse at 85% 34%, #633927 0%, #352637 39%, transparent 66%), linear-gradient(128deg, #1c1e35, #171922);
}
.hero-copy { position: relative; z-index: 1; padding: 35px 0 37px clamp(28px, 3.25vw, 52px); }
.eyebrow { display: flex; align-items: center; gap: .58rem; font-size: .76rem; font-weight: 800; letter-spacing: .07em; color: var(--gold); }
.eyebrow span { height: 7px; width: 7px; border-radius: 50%; background: var(--gold-strong); }
.eyebrow b, .age { border: 1px solid #615161; border-radius: 99px; padding: 2px 7px; font-size: .68rem; color: var(--muted); }
.hero h1 { margin-top: .75rem; font-size: clamp(2.6rem, 4.7vw, 5.1rem); letter-spacing: -.065em; font-weight: 800; line-height: 1.04; }
.hero h1 em { font-style: normal; color: var(--gold); display: block; }
.hero-operator { display: flex; flex-wrap: wrap; column-gap: .6rem; align-items: baseline; margin-top: 1rem; color: #e0d6df; font-size: .88rem; }
.hero-operator strong { color: var(--gold); font-size: 1rem; }
.hero-description { margin: .58rem 0 1.16rem; color: #e0d6df; font-size: clamp(.9rem, 1.33vw, 1.08rem); max-width: 36ch; line-height: 1.62; }
.hero-actions .button { min-height: 49px; padding-inline: 1.28rem; }
.guide-links { display: flex; flex-wrap: wrap; gap: .42rem 1rem; list-style: none; margin: .85rem 0 0; padding: 0; font-size: .87rem; }
.guide-links a, .text-link { color: var(--blue); text-decoration: underline; text-underline-offset: .2em; }
.guide-links a:hover, .text-link:hover { color: var(--gold); }
.hero-media { align-self: stretch; position: relative; display: grid; align-items: center; overflow: hidden; padding: 20px 18px 20px 0; }
.hero-media::before {
  content: ""; position: absolute; top: 12%; bottom: 12%; right: 13%; left: 5%;
  border: 1px solid #d591655c; border-radius: 51% 49% 45% 55%; transform: rotate(-12deg);
}
.hero-art { position: relative; width: 100%; height: auto; aspect-ratio: 1400 / 821; object-fit: contain; filter: drop-shadow(0 23px 28px #0908107a); }

.issue-finder {
  display: grid; grid-template-columns: minmax(190px, .65fr) minmax(0, 1.35fr); align-items: start;
  gap: 1rem; margin-top: 21px; padding: clamp(18px, 2.2vw, 28px);
  border: 1px solid #4a4f69; border-radius: var(--radius);
  background: linear-gradient(112deg, #262a3e, #1d2130);
}
.issue-finder h2, .directory > h2, .related h2, .home-reference > h2 { font-size: clamp(1.45rem, 2.1vw, 1.85rem); letter-spacing: -.04em; font-weight: 800; }
.issue-finder p { margin-top: .35rem; color: #ccd0e2; font-size: .84rem; }
.issue-controls { display: grid; grid-template-columns: minmax(0, 1fr) max-content; gap: 8px; align-items: start; }
select, input[type="search"], input[type="number"] {
  width: 100%; border: 1px solid #595e76; color: var(--text); background: #171925;
  border-radius: 9px; padding: .63rem .65rem; min-height: 44px; min-width: 0;
}
.issue-summary { grid-column: 1 / -1; margin-top: 0 !important; }
.featured, .card-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .78rem; }
.featured { margin-top: 13px; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.guide-card {
  position: relative; display: flex; flex-direction: column; gap: .42rem; min-width: 0;
  min-height: 136px; padding: 1rem 1rem 1.15rem; border: 1px solid var(--line); border-radius: 13px;
  background: var(--panel); transition: background-color .16s, border-color .16s;
}
.guide-card:hover { background: #242538; border-color: #b28263; }
.guide-card strong { font-size: .95rem; line-height: 1.35; padding-right: 1rem; color: var(--gold); }
.guide-card span:not(.card-arrow) { color: var(--muted); font-size: .8rem; line-height: 1.55; }
.card-arrow { position: absolute; top: .95rem; right: .9rem; color: var(--gold); font-size: .88rem; }
.directory { margin-top: 44px; }
.directory > section { margin-top: 22px; }
.directory h3 { font-size: 1.12rem; margin-bottom: 11px; color: #e1e2ef; }
.home-reference { margin-top: 40px; }
.reference-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .85rem 1.25rem; margin-top: 1rem; }
.reference-grid .article-detail { margin-top: 0; padding: 1.1rem; border: 1px solid var(--line); border-radius: 12px; background: var(--panel); }

.article { max-width: 1120px; }
.article-header {
  border: 1px solid #484054; border-radius: 22px; overflow: hidden;
  background: radial-gradient(ellipse at 100% 0%, #403047, transparent 65%), linear-gradient(130deg, #222237, #191c27);
  padding: clamp(22px, 3.4vw, 49px);
}
.breadcrumb { display: flex; flex-wrap: wrap; gap: .4rem .6rem; color: var(--muted); font-size: .76rem; margin-bottom: 1.2rem; }
.breadcrumb a { text-decoration: underline; text-underline-offset: 3px; }
.article h1 { max-width: 23ch; font-size: clamp(2rem, 3.5vw, 3.6rem); font-weight: 800; letter-spacing: -.05em; line-height: 1.1; }
.article-intro { margin-top: 1rem; font-size: clamp(.93rem, 1.6vw, 1.12rem); color: #d2d2df; max-width: 64ch; }
.article-answer { margin-top: 1.3rem; padding-left: .84rem; border-left: 2px solid var(--gold-strong); max-width: 68ch; font-weight: 720; color: var(--text); }
.contact-box {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .6rem 1.35rem; max-width: 680px;
  margin: 1.2rem 0 0; padding: .8rem .95rem; background: #161925; border: 1px solid var(--line); border-radius: 11px;
}
.contact-box dt { font-size: .74rem; color: var(--muted); font-weight: 750; }
.contact-box dd { margin: .15rem 0 0; color: var(--blue); font-size: .86rem; overflow-wrap: anywhere; }
.article-actions { margin-top: 1rem; gap: .45rem .75rem; }
.article-actions p { font-size: .76rem; color: var(--muted); }
.article-actions .text-link { font-size: .9rem; }
.article-actions:has(.text-link) p { flex-basis: 100%; }
.reading-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(147px, 180px); gap: clamp(16px, 3vw, 42px); align-items: start; }
.reading-body { min-width: 0; grid-column: 1; grid-row: 1; }
.article-section { margin-top: 30px; }
.article-section h2, .calculator h2 { font-size: clamp(1.23rem, 2.1vw, 1.65rem); font-weight: 800; letter-spacing: -.028em; }
.article-section p, .calculator p { margin-top: .8rem; max-width: 72ch; color: #e3e3ed; }
.article-detail { margin-top: 1.55rem; }
.article-section .article-detail + .article-detail { border-top: 1px solid var(--line); padding-top: 1.45rem; }
.article-detail h3 { font-size: clamp(1.1rem, 1.7vw, 1.32rem); line-height: 1.25; font-weight: 800; }
.article-detail p, .detail-list { margin: .65rem 0 0; max-width: 70ch; color: #e3e3ed; }
.detail-list { padding-inline-start: 1.25rem; }
.detail-list li + li { margin-top: .32rem; }
.article-toc {
  grid-column: 2; grid-row: 1; position: sticky; top: 94px; margin-top: 24px; padding: .7rem .75rem;
  max-height: calc(100dvh - 106px); overflow: auto; scrollbar-width: thin; scrollbar-color: var(--line) transparent;
  background: #151721; border: 1px solid #2f3244; border-radius: 11px;
}
.article-toc summary { font-size: .85rem; font-weight: 800; }
.article-toc nav { margin-top: .5rem; }
.article-toc a { display: block; color: var(--muted); font-size: .8rem; padding: .31rem 0; line-height: 1.34; }
.article-toc a:hover, .article-toc a:focus-visible { color: var(--gold); }
.article-toc .toc-topics { margin-inline-start: .2rem; padding-inline-start: .55rem; border-inline-start: 1px solid var(--line); }
.steps { list-style: none; counter-reset: step; margin: .8rem 0 0; padding: 0; }
.steps li {
  position: relative; counter-increment: step; padding: .65rem .75rem .65rem 2.65rem; margin-top: .43rem;
  background: var(--panel); border: 1px solid var(--line); border-radius: 10px;
  color: #e3e3ed; font-size: .92rem;
}
.steps li::before {
  position: absolute; left: .65rem; top: .65rem; content: counter(step); display: grid; place-items: center;
  width: 1.42rem; height: 1.42rem; border: 1px solid #8a624d; border-radius: 50%; color: var(--gold); font-weight: 800; font-size: .72rem;
}
.decision-table { margin-top: .85rem; width: 100%; border: 1px solid var(--line); border-radius: 10px; border-spacing: 0; overflow: hidden; font-size: .82rem; }
.decision-table th, .decision-table td { padding: .65rem .67rem; text-align: left; vertical-align: top; color: #e3e3ed; overflow-wrap: anywhere; }
.decision-table thead th { color: var(--gold); background: #252332; font-weight: 800; }
.decision-table tbody th { width: 26%; font-weight: 770; }
.decision-table tbody th, .decision-table tbody td { border-top: 1px solid var(--line); background: #171924; }
.decision-table tbody tr:nth-child(even) > * { background: #1c1e2a; }
.registration-image { margin: 25px 0 0; width: min(100%, 430px); }
.registration-image img { background: #171923; border: 1px solid var(--line); border-radius: 12px; width: 100%; height: auto; }
.registration-fields { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); align-items: start; gap: 1rem; margin-top: 1rem; }
.registration-fields .registration-image { margin: 0; }
.registration-fields .decision-table { margin-top: 0; }
.registration-fields .decision-table tbody th { width: 38%; }
.case-example { margin: .75rem 0 0; border: 1px solid var(--line); border-radius: 10px; padding: .3rem .85rem; background: var(--panel); }
.case-example div { display: grid; grid-template-columns: minmax(125px, .7fr) minmax(0, 1fr); gap: .5rem; padding: .44rem 0; }
.case-example div + div { border-top: 1px solid var(--line); }
.case-example dt { color: var(--muted); }
.case-example dd { margin: 0; overflow-wrap: anywhere; }
figcaption, .article-section .source-note { color: var(--muted); font-size: .78rem; margin-top: .48rem; }
.support-template, .calculator {
  margin-top: .8rem; padding: 1rem; border: 1px solid #555a73; border-radius: 12px;
  background: #202536;
}
.support-template p { margin: 0 0 .7rem; }
[data-copy-status] { margin-inline-start: .5rem; font-size: .76rem; color: var(--gold); }
.faq { display: grid; gap: .45rem; margin-top: .75rem; }
.faq details { padding: .65rem .8rem; background: var(--panel); border: 1px solid var(--line); border-radius: 9px; }
.faq summary { font-weight: 750; }
.sources { margin-top: .75rem; font-size: .86rem; }
.sources li { display: flex; flex-wrap: wrap; gap: .15rem .65rem; padding: .42rem 0; border-bottom: 1px solid var(--line); }
.sources a, .source-address { color: var(--blue); overflow-wrap: anywhere; }
.sources a { text-decoration: underline; text-underline-offset: 3px; }
.related { margin-top: 40px; }
.related h2 { margin-bottom: .8rem; }
.calculator { margin-top: 25px; }
.calculator > p { font-size: .85rem; }
.calc-fields { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .5rem; margin-top: .8rem; }
.calc-fields label { display: grid; align-content: space-between; gap: .28rem; color: var(--muted); font-size: .77rem; font-weight: 700; }
.calculator .calc-result { display: flex; gap: .2rem .7rem; flex-wrap: wrap; align-items: baseline; }
.calc-result output { color: var(--gold); font-size: 1.22rem; font-weight: 800; }
.game-gallery { margin-top: 25px; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .5rem; }
.game-gallery li { border: 1px solid var(--line); border-radius: 11px; overflow: hidden; background: var(--panel); }
.game-gallery img { width: 100%; height: auto; aspect-ratio: 170 / 140; object-fit: cover; }
.game-gallery span { display: block; padding: .5rem; font-size: .72rem; }

.site-footer { margin-top: 48px; padding: 23px 0 0; border-top: 1px solid var(--line); color: var(--muted); font-size: .79rem; }
.footer-brand { display: flex; align-items: center; gap: .55rem; color: var(--text); font-size: .93rem; }
.site-footer p { margin-top: .4rem; }
.footer-links { margin-top: .7rem; gap: .45rem 1rem; }
.footer-links a { color: var(--blue); text-decoration: underline; text-underline-offset: 3px; }

.search-dialog {
  width: min(calc(100% - 32px), 600px); max-height: min(80dvh, 680px); padding: 1.1rem;
  color: var(--text); background: #1b1e2c; border: 1px solid #626984; border-radius: var(--radius);
}
.search-dialog::backdrop { background: rgba(3, 4, 7, .75); }
.dialog-top { display: flex; align-items: center; gap: .4rem; justify-content: space-between; margin-bottom: .9rem; }
.dialog-top h2 { font-size: 1.4rem; }
.search-results { display: grid; gap: .42rem; margin-top: .65rem; color: var(--muted); font-size: .85rem; }
.result {
  display: grid; gap: .28rem; padding: .6rem .7rem; color: var(--muted);
  border: 1px solid var(--line); border-radius: 8px; background: #191b26;
}
.result:hover { background: var(--raised); border-color: #9d7d6d; }
.result strong { color: var(--gold); }
.chooser main { max-width: 1040px; margin: 0 auto; padding: clamp(24px, 8vh, 96px) 20px 28px; }
.chooser .hero h1 { font-size: clamp(2.5rem, 6vw, 5rem); }
.chooser .hero .wordmark { margin-bottom: .5rem; }
.missing { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; }
.missing h1 { margin: 0 0 1rem; }
.missing h1 span { display: block; color: var(--muted); font-size: .7em; }
.missing .button { margin-right: .4rem; }

@media (max-width: 1120px) {
  .hero { min-height: 380px; }
  .hero h1 { font-size: clamp(2.3rem, 4.8vw, 4.6rem); }
  .featured { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .reading-grid { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .reading-body { grid-row: auto; }
  .article-toc { grid-column: 1; position: static; max-height: none; margin-top: 14px; }
  .article-toc summary { padding-block: .2rem; }
  .article-toc a { font-size: .875rem; padding-block: .46rem; }
}
@media (max-width: 940px) {
  .page-shell { grid-template-columns: 1fr; gap: 14px; padding-top: 14px; }
  .sidebar { position: static; max-height: none; }
  .guide-menu { padding: 7px 11px; border-radius: 10px; }
  .guide-menu > summary { padding: .45rem .4rem; }
  .guide-menu nav { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .25rem; }
  .nav-group + .nav-group { margin: 0; padding: 0; border-top: 0; }
  .hero h1 { font-size: clamp(2.5rem, 6.9vw, 4.9rem); }
}
@media (max-width: 650px) {
  .reference-grid { grid-template-columns: 1fr; }
  :root { scroll-padding-top: 117px; }
  .header-inner { gap: .35rem .45rem; flex-wrap: wrap; padding-block: 8px; }
  .wordmark img { height: 27px; }
  .wordmark { gap: 7px; }
  .wordmark span { font-size: .71rem; padding-left: 7px; }
  .header-actions, .hero-actions { gap: .32rem; }
  .header-actions .button, .header-actions .language, .header-actions .search-button { min-height: 39px; padding: .35rem .54rem; font-size: .74rem; }
  .search-button > span:last-child { position: absolute; clip-path: inset(50%); width: 1px; height: 1px; overflow: hidden; }
  .guide-menu nav { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hero { grid-template-columns: 1fr; min-height: unset; border-radius: 18px; }
  .hero-copy { padding: 25px 21px 4px; }
  .hero h1 { font-size: clamp(2.65rem, 10.1vw, 4.3rem); }
  .hero-operator { margin-top: .75rem; }
  .hero-description { margin: .52rem 0 .9rem; }
  .hero .guide-links { row-gap: .28rem; }
  .hero-media { padding: 0 13px 10px; }
  .hero-art { max-height: 252px; }
  .issue-finder { grid-template-columns: 1fr; gap: .6rem; }
  .issue-controls { grid-template-columns: minmax(0, 1fr); }
  .issue-link { justify-self: start; }
  .card-grid, .calc-fields { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .contact-box { grid-template-columns: 1fr; }
  .guide-card { padding: .75rem; min-height: 120px; }
  .guide-card strong { font-size: .87rem; }
  .guide-card span:not(.card-arrow) { font-size: .76rem; }
  .card-arrow { right: .6rem; top: .67rem; }
  .decision-table { display: block; border: 0; overflow: visible; }
  .decision-table thead { position: absolute; height: 1px; width: 1px; overflow: hidden; clip-path: inset(50%); }
  .decision-table tbody { display: grid; gap: .45rem; }
  .decision-table tbody tr { display: grid; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
  .decision-table tbody th, .decision-table tbody td { display: block; width: auto; padding: .49rem .65rem; }
  .decision-table tbody th { border: 0; color: var(--gold); }
  .decision-table td::before { content: attr(data-label); display: block; color: var(--muted); font-size: .68rem; font-weight: 800; }
  .registration-fields { grid-template-columns: 1fr; }
  .registration-fields .decision-table tbody th { width: auto; }
}
@media (max-width: 418px) {
  .header-inner { padding-inline: 14px; }
  .wordmark span { display: none; }
  .header-actions .button, .header-actions .language, .header-actions .search-button { padding-inline: .44rem; }
  .page-shell { padding-inline: 13px; }
  .game-gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .case-example div { grid-template-columns: 1fr; gap: 0; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: .01ms !important; }
}
