/* ============================================================
   CreativeRadar — Legal pages stylesheet
   Shares brand tokens with the landing page (styles.css)
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
:root {
  --orange: #FF6805;
  --orange-600: #EA5C00;
  --orange-700: #C44E00;
  --tint: #FFF1E7;
  --ink: #15171C;
  --ink-800: #1B1E25;
  --slate: #4A5260;
  --muted: #767E8C;
  --line: #E7E3DC;
  --line-2: #ECE9E3;
  --bg: #FBFAF7;
  --bg-warm: #F4F1EA;
  --paper: #F7F4ED;
  --maxw: 880px;
  --mono: 'IBM Plex Mono', ui-monospace, monospace;
}
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: 'Archivo', system-ui, sans-serif;
  color: var(--ink); background: var(--bg);
  line-height: 1.7; -webkit-font-smoothing: antialiased;
  font-size: 17px; overflow-x: hidden;
}
a { color: var(--orange-700); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { font-family: 'Space Grotesk', sans-serif; letter-spacing: -0.02em; line-height: 1.15; }

/* ---- Header ---- */
header.nav {
  position: sticky; top: 0; z-index: 100;
  background: rgba(251,250,247,.85); -webkit-backdrop-filter: blur(14px) saturate(1.4); backdrop-filter: blur(14px) saturate(1.4);
  border-bottom: 1px solid var(--line);
}
.nav-in { max-width: 1240px; margin: 0 auto; padding: 0 40px; height: 74px; display: flex; align-items: center; justify-content: space-between; }
.brand { display: flex; align-items: center; gap: 13px; }
.brand img { height: 23px; width: auto; display: block; }
.brand .divider { width: 1px; height: 22px; background: var(--line); }
.brand { color: var(--ink); }
.brand:hover { text-decoration: none; }
.brand .product { font-family: 'Space Grotesk', sans-serif; font-weight: 600; font-size: 17px; letter-spacing: -0.01em; color: var(--ink); }
.brand .product b { color: var(--orange); font-weight: 600; }
.nav-back { display: inline-flex; align-items: center; gap: 8px; font-family: 'Archivo', sans-serif; font-weight: 600; font-size: 15px; color: var(--slate); }
.nav-back:hover { color: var(--ink); text-decoration: none; }

/* ---- Document ---- */
.legal-hero { background: var(--paper); border-bottom: 1px solid var(--line); padding: 56px 0 40px; }
.legal-wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 40px; }
.legal-hero .kicker { font-family: var(--mono); font-size: 12.5px; font-weight: 500; letter-spacing: .12em; text-transform: uppercase; color: var(--orange-700); display: inline-flex; align-items: center; gap: 10px; margin-bottom: 16px; }
.legal-hero .kicker .sq { width: 7px; height: 7px; background: var(--orange); transform: rotate(45deg); }
.legal-hero h1 { font-size: clamp(30px, 4vw, 44px); font-weight: 700; letter-spacing: -0.03em; }
.legal-hero .stand { margin-top: 14px; font-family: var(--mono); font-size: 13px; color: var(--muted); }

article.legal { padding: 48px 0 72px; }
article.legal .legal-wrap > * + * { margin-top: 18px; }
article.legal h2 {
  font-size: 23px; font-weight: 700; margin-top: 44px; padding-top: 22px;
  border-top: 1px solid var(--line); letter-spacing: -0.02em;
}
article.legal h2:first-of-type { margin-top: 28px; }
article.legal h3 { font-size: 18px; font-weight: 600; margin-top: 26px; }
article.legal p, article.legal li { color: var(--slate); font-size: 16.5px; }
article.legal strong { color: var(--ink); font-weight: 600; }
article.legal ul, article.legal ol { padding-left: 22px; }
article.legal li { margin-top: 7px; }
article.legal a { word-break: break-word; }

/* placeholder highlight */
.ph { background: var(--tint); color: var(--orange-700); font-family: var(--mono); font-size: .9em; padding: 1px 7px; border-radius: 5px; border: 1px dashed rgba(196,78,0,.35); white-space: nowrap; }

/* callout / note box */
.note {
  background: #fff; border: 1px solid var(--line); border-left: 3px solid var(--orange);
  border-radius: 12px; padding: 18px 22px; margin-top: 22px;
}
.note p { margin: 0; font-size: 15px; color: var(--slate); }
.note p + p { margin-top: 8px; }
.note .nt { display: block; font-family: var(--mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--orange-700); margin-bottom: 8px; }

/* definition table */
.legal-table { width: 100%; border-collapse: collapse; margin-top: 18px; font-size: 15.5px; }
.legal-table th, .legal-table td { text-align: left; padding: 12px 14px; border: 1px solid var(--line); vertical-align: top; color: var(--slate); }
.legal-table th { background: var(--bg-warm); font-family: 'Space Grotesk', sans-serif; font-weight: 600; color: var(--ink); }

/* table of contents */
.toc { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 22px 24px; margin-top: 28px; }
.toc h2 { all: unset; display: block; font-family: var(--mono); font-size: 11.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: 12px; }
.toc ol { columns: 2; column-gap: 32px; padding-left: 18px; }
.toc li { margin: 5px 0; color: var(--slate); }
@media (max-width: 620px) { .toc ol { columns: 1; } }

/* ---- Footer ---- */
footer.site { background: var(--ink); color: #fff; padding: 48px 0 32px; border-top: 1px solid rgba(255,255,255,.08); }
.foot-wrap { max-width: 1240px; margin: 0 auto; padding: 0 40px; }
.foot-top { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; padding-bottom: 26px; border-bottom: 1px solid rgba(255,255,255,.08); }
.foot-top img { height: 24px; }
.foot-links { display: flex; gap: 22px; flex-wrap: wrap; }
.foot-links a { color: #c2c7cf; font-size: 14.5px; transition: color .15s; }
.foot-links a:hover { color: var(--orange); text-decoration: none; }
.foot-bottom { padding-top: 22px; color: #767e8c; font-size: 13.5px; font-family: var(--mono); }

/* ---- Back-to-top button ---- */
.to-top {
  position: fixed; right: 24px; bottom: 24px; z-index: 80;
  width: 46px; height: 46px; border-radius: 50%;
  background: var(--orange); color: #fff; border: none; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 10px 26px -8px rgba(255,104,5,.6);
  opacity: 0; visibility: hidden; transform: translateY(10px);
  transition: opacity .25s ease, transform .25s ease, visibility .25s, background .15s;
}
.to-top.show { opacity: 1; visibility: visible; transform: none; }
.to-top:hover { background: var(--orange-600); }
.to-top:active { transform: translateY(1px); }

@media (max-width: 680px) {
  body { font-size: 16px; }
  .nav-in, .legal-wrap, .foot-wrap { padding-left: 22px; padding-right: 22px; }
  .to-top { right: 16px; bottom: 16px; }
  h1, h2, h3, article.legal p, article.legal li { overflow-wrap: break-word; word-break: break-word; hyphens: auto; }
  .legal-table { display: block; overflow-x: auto; }
}
