/* ROJIN publisher site — Swiss/International, monochrome (guide/11: black #000 / white #FFF only). */
:root {
  --ink: #000;
  --paper: #fff;
  --muted: #525252;
  --rule: #000;
  --hair: #d4d4d4;
  --tint: #f4f4f4;
  --mark-h: 28px;          /* wordmark height; clear space = 50% of it (guide/11 §2) */
  --gutter: clamp(1rem, 0.6rem + 2vw, 2.5rem);
  --measure: 46rem;
  --text: clamp(1rem, 0.95rem + 0.2vw, 1.0625rem);
  --h1: clamp(2rem, 1.2rem + 3.6vw, 3.75rem);
  --h2: clamp(1.15rem, 1rem + 0.6vw, 1.4rem);
  --space: clamp(2.5rem, 2rem + 3vw, 5rem);
  --sans: system-ui, -apple-system, "Apple SD Gothic Neo", "Pretendard", "Noto Sans KR", "Malgun Gothic", sans-serif;
  --fast: 150ms;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root { --ink: #fff; --paper: #000; --muted: #a3a3a3; --rule: #fff; --hair: #3a3a3a; --tint: #141414; }
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font: 400 var(--text)/1.7 var(--sans); word-break: keep-all; overflow-wrap: break-word;
}
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 0.2em; }
a:hover { text-decoration-thickness: 3px; }
a:focus-visible, [tabindex]:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; }
.skip { position: absolute; left: -999px; top: 0; background: var(--ink); color: var(--paper); padding: 0.5rem 1rem; z-index: 2; }
.skip:focus { left: var(--gutter); }

/* Header: wordmark keeps its clear space (padding = 50% of mark height) */
.site-header {
  display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 1.5rem;
  padding: 0 var(--gutter); border-bottom: 2px solid var(--rule);
}
.brand { display: inline-block; padding: calc(var(--mark-h) / 2); margin-left: calc(var(--mark-h) / -2); line-height: 0; }
.brand svg { height: var(--mark-h); width: auto; display: block; }
.crumb { font-weight: 700; letter-spacing: 0.02em; }
.crumb a { text-decoration: none; }
.lang { margin-left: auto; display: flex; gap: 0.25rem; }
.lang a {
  display: inline-block; min-width: 44px; min-height: 44px; padding: 0.6rem 0.75rem; text-align: center;
  border: 1px solid var(--rule); text-decoration: none; font-size: 0.875rem; line-height: 1.6;
  transition: background var(--fast), color var(--fast);
}
.lang a:hover, .lang a:focus-visible { background: var(--ink); color: var(--paper); }

main { display: block; padding: var(--space) var(--gutter); max-width: calc(var(--measure) + 2 * var(--gutter)); margin: 0 auto; }
main:focus { outline: none; }
body.wide main { max-width: 72rem; }
.doc > p, .doc > ul, .doc > dl, .doc > .notice { max-width: var(--measure); }

/* KO/EN on one page: both shown by default; #ko / #en in the URL shows only that language. */
.doc + .doc { margin-top: var(--space); padding-top: var(--space); border-top: 2px solid var(--rule); }
main:has(> #en:target) > .doc[lang="ko"], main:has(> #ko:target) > .doc[lang="en"] { display: none; }
main:has(> .doc:target) > .doc + .doc { margin-top: 0; padding-top: 0; border-top: 0; }

/* Type scale: strong contrast between title and body */
h1 { font-size: var(--h1); line-height: 1.08; letter-spacing: -0.03em; margin: 0 0 1rem; font-weight: 800; }
h2 {
  font-size: var(--h2); line-height: 1.3; margin: 3rem 0 0.75rem; padding-top: 0.75rem;
  border-top: 1px solid var(--rule); font-weight: 750; letter-spacing: -0.01em;
}
h3 { font-size: 1rem; margin: 1.75rem 0 0.25rem; }
.eyebrow { font-size: 0.8125rem; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; margin: 0 0 0.75rem; }
.lead { font-size: 1.125rem; line-height: 1.6; max-width: 40rem; }
.meta, .note, caption { color: var(--muted); font-size: 0.875rem; }
p, ul, ol { margin: 0 0 1rem; }
ul, ol { padding-left: 1.25rem; }
li + li { margin-top: 0.35rem; }
.num, td .num { font-variant-numeric: tabular-nums; white-space: nowrap; }
code, .sku { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-size: 0.875em; white-space: nowrap; }

/* Tables: dense, rule-based, scroll horizontally on narrow screens */
.table-wrap { overflow-x: auto; margin: 1rem 0 1.5rem; border-top: 2px solid var(--rule); }
table { border-collapse: collapse; width: 100%; font-size: 0.9375rem; line-height: 1.55; }
caption { text-align: left; padding: 0.5rem 0; caption-side: bottom; }
th, td { text-align: left; vertical-align: top; padding: 0.6rem 0.75rem 0.6rem 0; border-bottom: 1px solid var(--hair); }
th { font-size: 0.8125rem; font-weight: 700; letter-spacing: 0.04em; border-bottom: 1px solid var(--rule); white-space: nowrap; }
table.odds td:nth-child(2), table.odds td:nth-child(4) { text-align: right; }
table.kv th { width: 34%; white-space: normal; font-size: 0.875rem; border-bottom: 1px solid var(--hair); }
@media (max-width: 47.99rem) { .table-wrap table.wide { min-width: 44rem; } }

/* Placeholder for missing data: hatched and dashed, visible in both themes */
mark.todo {
  color: inherit; padding: 0 0.3em; outline: 1px dashed var(--ink);
  background: repeating-linear-gradient(135deg, transparent 0 5px, var(--tint) 5px 10px);
}

/* Notice box (03 §8.2 verbatim text) */
.notice { border: 2px solid var(--rule); padding: 1rem 1.25rem; margin: 1rem 0 1.5rem; white-space: pre-line; font-size: 0.9375rem; }

/* Home: oversized wordmark + numbered game index */
.hero { padding-bottom: calc(var(--space) / 2); }
.hero .mark { --hero-h: clamp(56px, 10vw, 120px); color: var(--ink); line-height: 0; padding: calc(var(--hero-h) / 2) 0; }
.hero .mark svg { height: var(--hero-h); width: auto; display: block; }
.hero p { max-width: 34rem; }
.games { list-style: none; padding: 0; margin: 0; counter-reset: game; }
.games li { counter-increment: game; border-bottom: 1px solid var(--rule); margin: 0; }
.games a {
  display: grid; grid-template-columns: 3rem 1fr auto; gap: 0 1rem; align-items: baseline;
  padding: 1.5rem 0; text-decoration: none;
}
.games a::before { content: counter(game, decimal-leading-zero); font-variant-numeric: tabular-nums; font-size: 0.875rem; color: var(--muted); }
.games a:hover .g-name, .games a:focus-visible .g-name { text-decoration: underline; text-decoration-thickness: 3px; }
.g-name { font-size: clamp(1.4rem, 1rem + 1.6vw, 2.25rem); font-weight: 800; letter-spacing: -0.02em; line-height: 1.15; }
.g-tag { grid-column: 2 / 4; color: var(--muted); margin-top: 0.35rem; }
.g-status { font-size: 0.8125rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; }

/* Link lists (game page, privacy index) */
.links { list-style: none; padding: 0; margin: 1.5rem 0; border-top: 2px solid var(--rule); }
.links li { margin: 0; border-bottom: 1px solid var(--hair); }
.links a { display: flex; justify-content: space-between; gap: 1rem; padding: 1rem 0; text-decoration: none; font-weight: 600; }
.links a::after { content: "\2192"; }
.links a:hover { text-decoration: underline; }

/* FAQ */
.faq dt { font-weight: 700; margin-top: 1.5rem; }
.faq dd { margin: 0.35rem 0 0; }

.site-footer { border-top: 2px solid var(--rule); padding: 2rem var(--gutter) 3rem; font-size: 0.875rem; }
.site-footer ul { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: 0.5rem 1.5rem; }
.site-footer li + li { margin-top: 0; }
.copy { color: var(--muted); }

@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
@media print {
  .skip, .lang, .site-footer nav { display: none; }
  main:has(> .doc:target) > .doc { display: block; }
  a { text-decoration: none; }
}
