/* Terms and Privacy pages: the Reliquary's obsidian, bone and gilt, set for long reading.
   System faces only, so reading the Privacy Policy contacts no third party. */
:root {
  color-scheme: dark;
  --bg: #050407;
  --ink-1: #f4ebda;
  --ink-2: #d2c6b0;
  --ink-3: #a3988a;
  --gold-1: #f6dc9e;
  --gold-2: #dcb66c;
  --gold-3: #a8833f;
  --line: rgba(232, 205, 150, 0.15);
  --line-hi: rgba(242, 211, 142, 0.34);
  --serif: 'Cormorant Garamond', Georgia, 'Noto Serif KR', 'AppleMyungjo', 'Noto Serif JP', 'Hiragino Mincho ProN', serif;
}
* { box-sizing: border-box; }
html { background: var(--bg); -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100vh; color: var(--ink-2);
  font: 16px/1.72 system-ui, -apple-system, 'Segoe UI', 'Apple SD Gothic Neo', 'Noto Sans KR', 'Hiragino Sans', 'Noto Sans JP', sans-serif;
  background: radial-gradient(ellipse 120% 52% at 50% -12%, rgba(143, 15, 38, 0.24), rgba(143, 15, 38, 0) 62%) no-repeat, var(--bg);
  word-break: keep-all; overflow-wrap: anywhere;
}
:lang(ja) body, body:lang(ja) { word-break: normal; line-break: strict; }

.lg-top {
  position: sticky; top: 0; z-index: 2; display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: max(12px, env(safe-area-inset-top)) max(16px, env(safe-area-inset-right)) 12px max(16px, env(safe-area-inset-left));
  background: rgba(5, 4, 7, 0.84); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line);
}
.lg-brand { display: block; line-height: 0; border-radius: 2px; }
.lg-brand img { width: 128px; height: auto; }
.lg-langs { display: flex; gap: 2px; }
.lg-langs a { padding: 6px 10px; border-radius: 3px; color: var(--ink-3); font-size: 13px; text-decoration: none; }
.lg-langs a:hover { color: var(--ink-1); }
.lg-langs a[aria-current] { color: var(--gold-1); background: rgba(242, 211, 142, 0.09); }

main { max-width: 760px; margin: 0 auto; padding: 40px 16px 72px; }
.lg-foot { max-width: 760px; margin: 0 auto; padding: 20px 16px calc(28px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); text-align: center; font-size: 12px; letter-spacing: 0.04em; color: var(--ink-3); }
article[hidden] { display: none; }
/* Without the script every language shows, one after another. */
article:not([hidden]) ~ article:not([hidden]) { margin-top: 96px; padding-top: 56px; border-top: 1px solid var(--line); }

.lg-kicker { margin: 0 0 10px; font-size: 12px; font-weight: 600; letter-spacing: 0.26em; color: var(--gold-3); }
h1 { margin: 0; font-family: var(--serif); font-weight: 600; font-size: clamp(34px, 6vw, 46px); line-height: 1.12; color: var(--ink-1); }
.lg-meta { margin: 12px 0 0; font-size: 13px; line-height: 1.6; color: var(--ink-3); }
article > header { margin-bottom: 28px; }

h2 { display: flex; align-items: baseline; gap: 12px; margin: 48px 0 14px; font-size: 18px; font-weight: 650; line-height: 1.4; color: var(--ink-1); }
h2::before { content: ''; flex: none; width: 6px; height: 6px; transform: translateY(-3px) rotate(45deg); background: var(--gold-2); box-shadow: 0 0 8px rgba(242, 190, 100, 0.5); }
p { margin: 12px 0; }
b { color: var(--ink-1); font-weight: 650; }
a { color: var(--gold-1); text-decoration-color: rgba(246, 220, 158, 0.42); text-underline-offset: 3px; }
a:hover { text-decoration-color: currentColor; }
ol, ul { margin: 12px 0; padding-left: 1.4em; }
li + li { margin-top: 8px; }
li::marker { color: var(--gold-3); }
code { padding: 1px 6px; border-radius: 3px; background: rgba(242, 211, 142, 0.08); color: var(--gold-1); font: 0.86em ui-monospace, 'SF Mono', Menlo, Consolas, monospace; }

.lg-summary { margin: 28px 0 0; padding: 18px 22px; border: 1px solid var(--line-hi); border-radius: 4px; background: linear-gradient(180deg, rgba(242, 211, 142, 0.06), rgba(242, 211, 142, 0.02)); }
.lg-summary p { margin: 0 0 8px; color: var(--gold-1); }
.lg-summary ul { margin: 0; }

.lg-table { margin: 14px 0; border: 1px solid var(--line); border-radius: 4px; overflow: hidden; }
table { width: 100%; border-collapse: collapse; font-size: 14px; line-height: 1.62; }
th, td { padding: 12px 16px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
tbody tr:last-child td { border-bottom: 0; }
th { background: rgba(242, 211, 142, 0.05); font-size: 12px; font-weight: 600; letter-spacing: 0.08em; color: var(--gold-2); }
td:first-child { color: var(--ink-1); width: 30%; }

.lg-facts { display: grid; grid-template-columns: max-content 1fr; gap: 10px 24px; margin: 14px 0; padding: 18px 20px; border: 1px solid var(--line); border-radius: 4px; font-size: 14px; line-height: 1.62; }
.lg-facts dt { color: var(--gold-2); }
.lg-facts dd { margin: 0; }

:focus-visible { outline: 1px solid var(--gold-1); outline-offset: 3px; }

@media (max-width: 600px) {
  main { padding-top: 28px; }
  /* Rows become cards: the first cell names the row, the rest follow beneath it. */
  table, thead, tbody, tr, td { display: block; }
  thead { display: none; }
  tr { padding: 14px 16px; border-bottom: 1px solid var(--line); }
  tbody tr:last-child { border-bottom: 0; }
  td { width: auto !important; padding: 0; border: 0; }
  td + td { margin-top: 6px; }
  td:first-child { font-weight: 650; }
  td:nth-child(3) { color: var(--ink-3); }
  .lg-facts { grid-template-columns: 1fr; gap: 2px; }
  .lg-facts dd + dt { margin-top: 10px; }
}
@media print {
  :root { color-scheme: light; --ink-1: #000; --ink-2: #222; --ink-3: #555; --gold-1: #000; --gold-2: #444; --gold-3: #666; --line: #ccc; --line-hi: #999; }
  body { background: #fff; }
  .lg-top { position: static; background: none; }
  article[hidden] { display: none; }
}
