/* The site's faces, self-hosted (served through the gate even while it is
   locked). DM Sans's latin file has no ₹; the 1.7 KB U+20B9 subset is the same
   family with that unicode-range, so it is fetched only where a ₹ appears
   (the liability cap in terms.html). JetBrains Mono has no ₹ either, so keep
   ₹ out of mono text. Same declarations as index.html. */
@font-face {
  font-family: "DM Sans";
  font-style: normal; font-weight: 400 700; font-display: swap;
  src: url('/fonts/dm-sans-latin.woff2') format('woff2');
}
@font-face {
  font-family: "DM Sans";
  font-style: normal; font-weight: 400 700; font-display: swap;
  src: url('/fonts/dm-sans-rupee.woff2') format('woff2');
  unicode-range: U+20B9;
}
@font-face {
  font-family: "DM Sans";
  font-style: italic; font-weight: 400 700; font-display: swap;
  src: url('/fonts/dm-sans-italic-latin.woff2') format('woff2');
}
@font-face {
  font-family: "JetBrains Mono";
  font-style: normal; font-weight: 400 700; font-display: swap;
  src: url('/fonts/jetbrains-mono-latin.woff2') format('woff2');
}

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

/* Dark by default, as the home page is; the visitor's light choice comes from
   /theme.css + /theme.js, shared with every page. These pages used to switch on
   prefers-color-scheme alone, which made /terms and /privacy look like a
   different site from the page that links to them. Same values as index.html. */
:root {
  color-scheme: dark;
  --ground:  #08080A;
  --raise:   #101014;
  --line:    #1D1D23;
  --line-hi: #2A2A33;
  --dim:     #7A7A85;
  --mid:     #8E8C88;
  --text:    #C6C3BC;
  --bright:  #F2EFE8;
  --grad-a:  #14141A;
  --grad-b:  #08080A;
  --warn:    #9A8F7E;
  --accent:  #E8A855;

  --sans: "DM Sans", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Helvetica, Arial, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, monospace;

  --pad: clamp(1.25rem, 5vw, 4.5rem);
  --measure: 36rem;
  --rule: 1px solid var(--line);
}

body {
  background: var(--ground);
  background-image: linear-gradient(180deg, var(--grad-a) 0%, var(--grad-b) 42%, var(--grad-b) 100%);
  background-repeat: no-repeat;
  color: var(--text);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.68;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* The home page's column, so the title lines up under the wordmark. The prose
   keeps its reading measure; boxes stop at 52rem. */
.wrap { max-width: 66rem; margin: 0 auto; padding: 0 var(--pad); }
.notice, .kv { max-width: 52rem; }

a { color: var(--bright); text-decoration: none; border-bottom: 1px solid var(--line-hi); }
a:hover { border-bottom-color: var(--mid); }
a:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

/* top bar + ≡ menu: /nav.css, shared with about and the case studies */

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 0.001s !important; }
}

header.doc {
  padding: clamp(3rem, 9vw, 5.5rem) 0 clamp(1.75rem, 4vw, 2.5rem);
  border-bottom: var(--rule);
  display: grid; gap: 1rem;
}
h1 {
  margin: 0;
  font-size: clamp(1.7rem, 4.4vw, 2.6rem);
  font-weight: 500; letter-spacing: -0.03em; line-height: 1.15;
  color: var(--bright); text-wrap: balance;
}
.meta {
  font-family: var(--mono); font-size: 11px; letter-spacing: 0.08em;
  color: var(--dim); margin: 0;
}

.notice {
  border: 1px solid var(--line-hi); background: var(--raise);
  padding: 1.15rem 1.25rem; margin: 2rem 0 0;
  font-size: 13.5px; color: var(--mid); line-height: 1.6;
}
.notice strong { color: var(--warn); font-weight: 500; }

section.clause { padding: clamp(2rem, 5vw, 2.75rem) 0; border-bottom: var(--rule); }
section.clause:last-of-type { border-bottom: 0; }

h2 {
  margin: 0 0 1rem;
  font-size: 1.05rem; font-weight: 500; letter-spacing: -0.012em;
  color: var(--bright);
  display: grid; grid-template-columns: 2.5rem 1fr; gap: 0.75rem; align-items: baseline;
}
h2 .n {
  font-family: var(--mono); font-size: 10.5px; font-weight: 400;
  letter-spacing: 0.08em; color: var(--dim);
}
h3 {
  margin: 1.5rem 0 0.6rem;
  font-size: 0.95rem; font-weight: 500; color: var(--text);
}

p { margin: 0 0 0.9rem; max-width: var(--measure); color: var(--mid); }
p:last-child { margin-bottom: 0; }
p strong, li strong { color: var(--text); font-weight: 500; }
em { color: var(--text); font-style: italic; }

ul, ol { margin: 0 0 0.9rem; padding-left: 1.15rem; max-width: var(--measure); color: var(--mid); }
li { margin-bottom: 0.5rem; }
li::marker { color: var(--dim); }

.kv { border: var(--rule); margin: 1.25rem 0; }
.kv-row { display: grid; gap: 0.25rem; padding: 0.85rem 1rem; border-bottom: 1px solid var(--line); }
.kv-row:last-child { border-bottom: 0; }
@media (min-width: 40rem) { .kv-row { grid-template-columns: 12rem 1fr; gap: 1.25rem; align-items: baseline; } }
.kv-k { font-family: var(--mono); font-size: 10px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--dim); }
.kv-v { font-size: 13.5px; color: var(--text); }
/* cookie names are case-sensitive: keep _ga from rendering as _GA */
.kv-k code { text-transform: none; letter-spacing: 0; font-size: 11.5px; }

code {
  font-family: var(--mono); font-size: 0.86em; color: var(--text);
  background: var(--raise); padding: 0.1em 0.36em; border: 1px solid var(--line);
}

.fill { color: var(--warn); font-family: var(--mono); font-size: 0.9em; }

/* footer + the lockup mark: /nav.css, shared with about and the case studies */

/* the sticky bar is 50px: keep linked headings (privacy#cookies) clear of it */
h3[id] { scroll-margin-top: 5rem; }
