/* Girok — Self-hosted fonts (no Google CDN requests) */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/inter-400-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: 'Inter';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/inter-400-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-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: 'Rajdhani';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('../fonts/rajdhani-600-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: 'Rajdhani';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('../fonts/rajdhani-700-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;
}

/* ── Reset ──────────────────────────────────────────────────────────────── */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

/* ── Tokens ─────────────────────────────────────────────────────────────── */

:root {
  --bg:         #0B0B12;
  --surface:    #171A27;
  --border:     #30364A;
  --text:       #F4F5FA;
  --text-sec:   #A8AEC0;
  --accent:     #A78BFA;
  --accent-btn: #7450E8;
  --focus:      #7450E8;
  --font-head:  'Rajdhani', system-ui, sans-serif;
  --font-body:  'Inter', system-ui, sans-serif;
  --max-w:      70ch;
}

/* ── Body ───────────────────────────────────────────────────────────────── */

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ── Skip link ──────────────────────────────────────────────────────────── */

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  z-index: 100;
  padding: 0.5rem 1rem;
  background: var(--accent-btn);
  color: #fff;
  text-decoration: none;
  font-family: var(--font-head);
  font-weight: 600;
}
.skip-link:focus {
  left: 0;
}

/* ── Header ─────────────────────────────────────────────────────────────── */

.site-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.25rem 2rem;
  border-bottom: 1px solid var(--border);
}

.site-header .logo {
  height: 28px;
  width: auto;
}

.site-header nav {
  display: flex;
  gap: 1.5rem;
  margin-left: auto;
}

.site-header nav a {
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text-sec);
  text-decoration: none;
  padding: 0.25rem 0;
}

.site-header nav a:hover,
.site-header nav a[aria-current="page"] {
  color: var(--accent);
}

/* ── Main ───────────────────────────────────────────────────────────────── */

.page {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 2.5rem 1.5rem 4rem;
}

/* ── Headings ───────────────────────────────────────────────────────────── */

h1, h2, h3 {
  font-family: var(--font-head);
  color: var(--text);
  line-height: 1.2;
}

h1 {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.meta {
  font-size: 0.9rem;
  color: var(--text-sec);
  margin-bottom: 2rem;
}

h2 {
  font-size: 1.35rem;
  font-weight: 700;
  margin-top: 2.5rem;
  margin-bottom: 0.75rem;
  padding-top: 0.5rem;
}

h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin-top: 1.5rem;
  margin-bottom: 0.5rem;
}

/* ── Body text ──────────────────────────────────────────────────────────── */

p { margin-bottom: 1rem; }
p:last-child { margin-bottom: 0; }

strong { font-weight: 600; color: var(--text); }

/* ── Links ──────────────────────────────────────────────────────────────── */

a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 0.15em;
}

a:hover { color: #c4b5fd; }

a:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
  border-radius: 2px;
}

/* ── Lists ──────────────────────────────────────────────────────────────── */

ul, ol {
  margin: 0 0 1rem 1.5rem;
}

li { margin-bottom: 0.4rem; }
li:last-child { margin-bottom: 0; }

/* ── Table of contents ──────────────────────────────────────────────────── */

.toc {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1.25rem 1.5rem;
  margin-bottom: 2.5rem;
}

.toc summary {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.05rem;
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.toc summary::before {
  content: '▸';
  font-size: 0.85em;
  transition: transform 0.15s ease;
}

.toc[open] summary::before {
  transform: rotate(90deg);
}

@media (prefers-reduced-motion: reduce) {
  .toc summary::before { transition: none; }
}

.toc summary::-webkit-details-marker { display: none; }

.toc ol {
  margin: 0.75rem 0 0 1.25rem;
  padding: 0;
}

.toc li {
  margin-bottom: 0.3rem;
}

.toc a {
  text-decoration: none;
  font-size: 0.95rem;
  padding: 0.15rem 0;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
}

.toc a:hover { text-decoration: underline; }

/* Above 720px the TOC is always open */
@media (min-width: 720px) {
  .toc { padding: 1.5rem 2rem; }
  .toc[open] summary, .toc summary { cursor: default; }
}

/* ── Info box (used on delete-account page) ─────────────────────────────── */

.info-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1.5rem;
  margin: 1.5rem 0;
}

.info-box h3 {
  margin-top: 0;
}

/* ── Footer ─────────────────────────────────────────────────────────────── */

.site-footer {
  border-top: 1px solid var(--border);
  padding: 1.5rem 2rem;
  text-align: center;
  font-size: 0.85rem;
  color: var(--text-sec);
}

.site-footer nav {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 1rem 2rem;
  margin-bottom: 0.75rem;
}

.site-footer nav a {
  color: var(--text-sec);
  text-decoration: none;
  font-size: 0.85rem;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
}

.site-footer nav a:hover {
  color: var(--accent);
}

/* ── Responsive ─────────────────────────────────────────────────────────── */

@media (max-width: 720px) {
  .site-header {
    padding: 1rem 1rem;
    gap: 0.75rem;
  }
  .site-header nav { gap: 1rem; }
  .page { padding: 1.5rem 1rem 3rem; }
  h1 { font-size: 1.6rem; }
  h2 { font-size: 1.2rem; }
}
