/* ============================================================
   KRMN shared design tokens, base styles, nav, footer, legal
   ============================================================ */

/* Playfair Display (SIL OFL 1.1), self-hosted variable font.
   One file covers weights 400 to 700, so no extra requests per weight. */
@font-face {
  font-family: "Playfair Display";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("/assets/fonts/playfair-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+2074, U+20AC,
                 U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Playfair Display";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("/assets/fonts/playfair-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: "Playfair Display";
  font-style: italic;
  font-weight: 400 700;
  font-display: swap;
  src: url("/assets/fonts/playfair-italic-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+2074, U+20AC,
                 U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Playfair Display";
  font-style: italic;
  font-weight: 400 700;
  font-display: swap;
  src: url("/assets/fonts/playfair-italic-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 {
  /* Surfaces */
  --bg:            #07080A;
  --bg-elev:       #0E1015;
  --surface:       #12151B;
  --surface-2:     #171B23;
  --line:          rgba(255, 255, 255, 0.08);
  --line-strong:   rgba(255, 255, 255, 0.16);

  /* Ink */
  --ink:           #F4F6F8;
  --ink-2:         #C3CAD4;
  --ink-3:         #8A93A2;
  --ink-4:         #5D6673;

  /* Brand */
  --volt:          #D4FF3D;
  --volt-deep:     #A8D400;
  --cyan:          #22E7FF;
  --violet:        #8B6BFF;

  /* Type. Didone display to match the wordmark, clean sans for reading */
  --font: ui-sans-serif, -apple-system, "Segoe UI Variable Text", "Segoe UI",
          Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-display: "Playfair Display", "Bodoni MT", Didot, "Didot LT STD",
                  "Hoefler Text", Garamond, "Times New Roman", serif;
  --font-deva: "Nirmala UI", "Noto Sans Devanagari", "Mangal", var(--font);
  --font-mono: ui-monospace, "Cascadia Mono", "SF Mono", Menlo, Consolas, monospace;

  /* Rhythm */
  --gutter: clamp(1.25rem, 5vw, 3rem);
  --maxw: 1180px;
  --radius: 18px;
  --radius-sm: 11px;

  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.65;
  letter-spacing: -0.011em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img, svg { max-width: 100%; display: block; }

a {
  color: var(--volt);
  text-decoration: none;
  text-underline-offset: 3px;
}
a:hover { text-decoration: underline; }

::selection { background: var(--volt); color: #0A0C05; }

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

/* Film grain overlay, sits above the page, ignores pointer events */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 100;
  pointer-events: none;
  opacity: 0.045;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.82' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

.wrap {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--volt);
  color: #0A0C05;
  padding: 0.75rem 1.25rem;
  font-weight: 700;
  z-index: 200;
}
.skip-link:focus { left: 0; }

/* ---------------------------------------------------------- Wordmark */

.wordmark {
  display: inline-block;
  line-height: 0;
  transition: opacity 0.25s var(--ease);
}
.wordmark:hover { text-decoration: none; opacity: 0.72; }

.wordmark img {
  height: 21px;
  width: auto;
}
.footer .wordmark img { height: 27px; }

@media (max-width: 520px) {
  .wordmark img { height: 18px; }
}

/* ---------------------------------------------------------- Site nav */

.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid transparent;
  background: rgba(7, 8, 10, 0);
  transition: background 0.35s var(--ease), border-color 0.35s var(--ease),
              backdrop-filter 0.35s var(--ease);
}
.nav.is-stuck {
  background: rgba(7, 8, 10, 0.82);
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-bottom-color: var(--line);
}

.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  min-height: 74px;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: clamp(1rem, 3vw, 2rem);
  font-size: 0.905rem;
  font-weight: 550;
}
.nav__links a {
  color: var(--ink-3);
  transition: color 0.2s var(--ease);
}
.nav__links a:hover,
.nav__links a[aria-current="page"] {
  color: var(--ink);
  text-decoration: none;
}

/* ---------------------------------------------------------- Buttons */

.btn {
  --btn-bg: var(--volt);
  --btn-fg: #0A0C05;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  padding: 0.92rem 1.6rem;
  border: 1px solid transparent;
  border-radius: 999px;
  background: var(--btn-bg);
  color: var(--btn-fg);
  font: inherit;
  font-size: 0.985rem;
  font-weight: 700;
  letter-spacing: -0.006em;
  cursor: pointer;
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease),
              background 0.25s var(--ease), border-color 0.25s var(--ease);
}
.btn:hover {
  text-decoration: none;
  transform: translateY(-2px);
  box-shadow: 0 14px 34px -12px rgba(212, 255, 61, 0.6);
}
.btn:active { transform: translateY(0); }

.btn--ghost {
  --btn-bg: transparent;
  --btn-fg: var(--ink);
  border-color: var(--line-strong);
}
.btn--ghost:hover {
  --btn-bg: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.3);
  box-shadow: none;
}

/* ---------------------------------------------------------- Footer */

.footer {
  position: relative;
  z-index: 2;
  margin-top: clamp(4rem, 10vw, 8rem);
  border-top: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.014), transparent 60%);
  padding-block: clamp(3rem, 7vw, 4.5rem) 2.5rem;
  font-size: 0.925rem;
}

.footer__grid {
  display: grid;
  gap: clamp(2rem, 5vw, 3.5rem);
  grid-template-columns: minmax(0, 1.5fr) repeat(2, minmax(0, 1fr));
}
@media (max-width: 720px) {
  .footer__grid { grid-template-columns: 1fr 1fr; }
  .footer__brand { grid-column: 1 / -1; }
}

.footer__tag {
  margin: 1.1rem 0 0;
  max-width: 34ch;
  color: var(--ink-3);
  line-height: 1.6;
}

.footer h2 {
  margin: 0 0 1rem;
  font-size: 0.735rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--ink-4);
}

.footer ul { margin: 0; padding: 0; list-style: none; }
.footer li + li { margin-top: 0.65rem; }
.footer li a, .footer address a {
  color: var(--ink-2);
  font-style: normal;
  transition: color 0.2s var(--ease);
}
.footer li a:hover, .footer address a:hover { color: var(--volt); }
.footer address { font-style: normal; color: var(--ink-3); line-height: 1.75; }

.footer__base {
  margin-top: clamp(2.5rem, 6vw, 4rem);
  padding-top: 1.75rem;
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.5rem;
  justify-content: space-between;
  align-items: center;
  color: var(--ink-4);
  font-size: 0.855rem;
}

/* ============================================================
   Legal / document pages
   ============================================================ */

.doc-hero {
  position: relative;
  padding-block: clamp(3rem, 8vw, 5.5rem) clamp(2rem, 5vw, 3rem);
  border-bottom: 1px solid var(--line);
  overflow: hidden;
}
.doc-hero::before {
  content: "";
  position: absolute;
  left: 50%;
  top: -60%;
  width: min(900px, 130vw);
  aspect-ratio: 1;
  translate: -50% 0;
  background: radial-gradient(circle, rgba(212, 255, 61, 0.11), transparent 62%);
  pointer-events: none;
}
.doc-hero > * { position: relative; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-size: 0.735rem;
  font-weight: 700;
  letter-spacing: 0.17em;
  text-transform: uppercase;
  color: var(--volt);
}

.doc-hero h1 {
  margin: 1rem 0 0;
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 6.6vw, 4rem);
  font-weight: 500;
  line-height: 1.06;
  letter-spacing: -0.018em;
}

.doc-hero .lede {
  margin: 1.1rem 0 0;
  max-width: 62ch;
  color: var(--ink-2);
  font-size: clamp(1.02rem, 2vw, 1.12rem);
  line-height: 1.65;
}

.doc-meta {
  margin-top: 1.9rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}
.doc-meta span {
  padding: 0.42rem 0.9rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.028);
  color: var(--ink-3);
  font-size: 0.815rem;
  font-weight: 550;
}
.doc-meta b { color: var(--ink); font-weight: 650; }

.doc-layout {
  display: grid;
  gap: clamp(2rem, 5vw, 4rem);
  grid-template-columns: minmax(0, 1fr);
  padding-block: clamp(2.5rem, 6vw, 4rem);
}
@media (min-width: 1000px) {
  .doc-layout { grid-template-columns: 232px minmax(0, 1fr); }
}

.toc {
  display: none;
  align-self: start;
  position: sticky;
  top: 100px;
  font-size: 0.88rem;
}
@media (min-width: 1000px) { .toc { display: block; } }

.toc h2 {
  margin: 0 0 1rem;
  font-size: 0.715rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--ink-4);
}
.toc ol { margin: 0; padding: 0; list-style: none; counter-reset: toc; }
.toc li { counter-increment: toc; }
.toc a {
  display: block;
  padding: 0.42rem 0 0.42rem 1.9rem;
  position: relative;
  color: var(--ink-3);
  border-left: 2px solid var(--line);
  transition: color 0.2s var(--ease), border-color 0.2s var(--ease);
}
.toc a::before {
  content: counter(toc);
  position: absolute;
  left: 0.75rem;
  color: var(--ink-4);
  font-variant-numeric: tabular-nums;
  font-size: 0.79rem;
}
.toc a:hover { color: var(--ink); text-decoration: none; }
.toc a.is-active {
  color: var(--volt);
  border-left-color: var(--volt);
}
.toc a.is-active::before { color: var(--volt); }

/* Prose */

.prose { max-width: 74ch; }
.prose > *:first-child { margin-top: 0; }

.prose h2 {
  margin: 3.4rem 0 1.1rem;
  padding-top: 0.4rem;
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 3.4vw, 1.95rem);
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: -0.012em;
  scroll-margin-top: 100px;
}
.prose h2 .num {
  display: block;
  margin-bottom: 0.4rem;
  color: var(--volt);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.17em;
  font-family: var(--font-mono);
}

.prose h3 {
  margin: 2.1rem 0 0.75rem;
  font-size: 1.045rem;
  font-weight: 700;
  letter-spacing: -0.015em;
  color: var(--ink);
}

.prose p, .prose li { color: var(--ink-2); }
.prose p { margin: 0 0 1.1rem; }
.prose strong { color: var(--ink); font-weight: 650; }

.prose ul, .prose ol { margin: 0 0 1.25rem; padding-left: 0; list-style: none; }
.prose li {
  position: relative;
  margin-bottom: 0.62rem;
  padding-left: 1.6rem;
}
.prose ul > li::before {
  content: "";
  position: absolute;
  left: 0.28rem;
  top: 0.72em;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--volt);
}
.prose ol { counter-reset: li; }
.prose ol > li { counter-increment: li; }
.prose ol > li::before {
  content: counter(li) ".";
  position: absolute;
  left: 0;
  color: var(--volt);
  font-weight: 650;
  font-variant-numeric: tabular-nums;
}

.prose a { text-decoration: underline; text-decoration-color: rgba(212, 255, 61, 0.4); }
.prose a:hover { text-decoration-color: var(--volt); }

.prose hr {
  margin: 3rem 0;
  border: 0;
  height: 1px;
  background: var(--line);
}

/* Callout card */
.callout {
  margin: 1.75rem 0;
  padding: 1.4rem 1.5rem;
  border: 1px solid var(--line);
  border-left: 3px solid var(--volt);
  border-radius: var(--radius-sm);
  background: linear-gradient(120deg, rgba(212, 255, 61, 0.05), rgba(255, 255, 255, 0.015));
}
.callout p:last-child { margin-bottom: 0; }
.callout__title {
  margin: 0 0 0.5rem;
  color: var(--ink);
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

/* Definition table */
.dtable {
  width: 100%;
  margin: 1.5rem 0 1.75rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  border-collapse: separate;
  border-spacing: 0;
  overflow: hidden;
  font-size: 0.925rem;
}
.dtable th, .dtable td {
  padding: 0.85rem 1.05rem;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid var(--line);
}
.dtable thead th {
  background: rgba(255, 255, 255, 0.03);
  color: var(--ink);
  font-size: 0.735rem;
  font-weight: 700;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}
.dtable tbody th { color: var(--ink); font-weight: 650; white-space: nowrap; }
.dtable td { color: var(--ink-2); }
.dtable tr:last-child th, .dtable tr:last-child td { border-bottom: 0; }

.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }

/* Numbered step cards (account deletion / support flows) */
.steps {
  margin: 1.75rem 0 2rem;
  padding: 0;
  list-style: none;
  counter-reset: step;
  display: grid;
  gap: 0.85rem;
}
.steps > li {
  counter-increment: step;
  position: relative;
  margin: 0;
  padding: 1.35rem 1.5rem 1.35rem 4.1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.026);
}
.steps > li::before {
  content: counter(step);
  position: absolute;
  left: 1.35rem;
  top: 1.3rem;
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(212, 255, 61, 0.13);
  color: var(--volt);
  font-size: 0.85rem;
  font-weight: 750;
  font-variant-numeric: tabular-nums;
}
.steps b {
  display: block;
  margin-bottom: 0.3rem;
  color: var(--ink);
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: -0.015em;
}
.steps p { margin: 0; font-size: 0.945rem; }
.steps p + p { margin-top: 0.5rem; }

.contact-card {
  margin: 2rem 0 0;
  padding: 1.6rem 1.7rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}
.contact-card p { margin: 0 0 0.45rem; }
.contact-card p:last-child { margin-bottom: 0; }

/* ---------------------------------------------------------- Print */

@media print {
  :root { --ink: #000; --ink-2: #1c1c1c; --ink-3: #444; --volt: #000; }
  body { background: #fff; color: #000; font-size: 11pt; }
  body::after, .nav, .toc, .footer__grid, .doc-hero::before, .skip-link { display: none !important; }
  .doc-layout { display: block; padding-top: 0; }
  .prose { max-width: none; }
  .prose h2 { page-break-after: avoid; margin-top: 1.6rem; }
  .prose h2 .num { color: #666; }
  .prose li::before { background: #000 !important; color: #000 !important; }
  .callout, .contact-card, .dtable { border: 1px solid #bbb; background: none; }
  .prose a { color: #000; text-decoration: underline; }
  .footer { border-top: 1px solid #bbb; margin-top: 2rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}
