/* Shared styling for the legal pages (terms, privacy, refunds).
   Kept in one real stylesheet rather than inlined per page — unlike the
   marketing pages these are plain prose, so there's nothing to gain from
   self-contained files and a lot to gain from editing the design once. */

:root{
  --bg:#140803;
  --bg-2:#1c0d05;
  --glass:rgba(255,244,230,.05);
  --glass-line:rgba(255,214,160,.16);
  --txt:#fdf1e5;
  --txt-dim:#c2b5a3;
  --txt-faint:#857767;
  --amber:#ff8a3d;
  --terracotta:#d4562a;
  --accent-txt:#ff8a3d;
  --nav-bg:rgba(20,8,3,.55);
  --shadow:rgba(0,0,0,.55);
  --note-bg:rgba(255,138,61,.10);
  --r-lg:28px;--r-md:20px;
}
html[data-theme="light"]{
  --bg:#f6ecdd;
  --bg-2:#fdf6ec;
  --glass:rgba(255,255,255,.55);
  --glass-line:rgba(166,62,28,.22);
  --txt:#2c1608;
  --txt-dim:#6b5c49;
  --txt-faint:#9a8a75;
  --amber:#d4562a;
  --terracotta:#a63e1c;
  --accent-txt:#a63e1c;
  --nav-bg:rgba(253,246,236,.6);
  --shadow:rgba(120,70,20,.18);
  --note-bg:rgba(212,86,42,.08);
}

*{margin:0;padding:0;box-sizing:border-box}
html{scroll-behavior:smooth}
body{
  font-family:'Inter',system-ui,-apple-system,sans-serif;
  background-color:var(--bg);color:var(--txt);
  line-height:1.7;overflow-x:hidden;
  /* Deliberately NOT transitioned. These colours come from custom properties
     that change wholesale when the theme flips; transitioning them left the
     body latched on the previous colour, so the toggle updated data-theme and
     every other element but the page background never repainted. Verified by
     forcing transition:none, which made it switch correctly. A theme swap that
     snaps instantly is a fine trade for one that reliably happens at all. */
}
a{color:var(--accent-txt);text-decoration:none}
a:hover{text-decoration:underline}

/* ---- ambient background ---- */
.orbs{position:fixed;inset:0;pointer-events:none;z-index:0;overflow:hidden}
.orb{position:absolute;border-radius:50%;filter:blur(90px);opacity:.35}
.orb-a{width:520px;height:520px;top:-180px;right:-140px;background:radial-gradient(circle at 40% 40%,var(--amber),transparent 65%)}
.orb-b{width:620px;height:620px;bottom:-260px;left:-280px;background:radial-gradient(circle at 60% 40%,var(--terracotta),transparent 65%);opacity:.22}

/* ---- logo badge + nav (matches the marketing pages) ---- */
.brand{
  position:fixed;top:18px;left:22px;z-index:61;
  display:flex;align-items:center;gap:9px;text-decoration:none;
  padding:9px 18px;border-radius:100px;
  background:var(--nav-bg);
  backdrop-filter:blur(20px) saturate(1.5);-webkit-backdrop-filter:blur(20px) saturate(1.5);
  border:1px solid var(--glass-line);box-shadow:0 10px 40px var(--shadow);
  transition:transform .2s;
}
.brand:hover{transform:translateY(-2px);text-decoration:none}
.brand-mark{
  font-family:'Sora',system-ui,sans-serif;font-weight:800;font-size:18px;letter-spacing:-.02em;
  background:linear-gradient(110deg,var(--amber),var(--terracotta));
  -webkit-background-clip:text;background-clip:text;color:transparent;
}
.nav-shell{position:fixed;top:18px;left:0;right:0;z-index:60;display:flex;justify-content:flex-end;padding:0 20px;}
.nav{
  display:flex;align-items:center;gap:18px;
  padding:10px 20px;border-radius:100px;
  background:var(--nav-bg);
  backdrop-filter:blur(20px) saturate(1.5);-webkit-backdrop-filter:blur(20px) saturate(1.5);
  border:1px solid var(--glass-line);box-shadow:0 10px 40px var(--shadow);
}
.nav a{color:var(--txt-dim);font-size:14px;font-weight:600;white-space:nowrap}
.nav a:hover,.nav a.on{color:var(--accent-txt);text-decoration:none}
.theme-toggle{
  width:36px;height:36px;border-radius:50%;cursor:pointer;flex:none;
  background:transparent;border:1px solid var(--glass-line);
  display:flex;align-items:center;justify-content:center;color:var(--accent-txt);
  font-size:15px;line-height:1;
}
@media(max-width:760px){
  .nav a.hide-m{display:none}
  .brand{top:12px;left:12px;padding:7px 14px}
  .nav-shell{top:12px;padding:0 12px}
}

/* ---- layout ---- */
.wrap{max-width:820px;margin:0 auto;padding:0 24px;position:relative;z-index:2}
.doc-head{padding:150px 0 40px;text-align:center}
.doc-head h1{
  font-family:'Sora',system-ui,sans-serif;font-weight:800;letter-spacing:-.02em;
  font-size:clamp(30px,5vw,44px);line-height:1.15;margin-bottom:14px;
}
.doc-head .meta{color:var(--txt-faint);font-size:14px}
.doc-body{padding-bottom:80px}

/* ---- prose ---- */
.doc-body h2{
  font-family:'Sora',system-ui,sans-serif;font-weight:700;font-size:21px;letter-spacing:-.01em;
  margin:44px 0 12px;padding-top:22px;border-top:1px solid var(--glass-line);
}
.doc-body h2:first-of-type{border-top:none;padding-top:0;margin-top:26px}
.doc-body h3{font-family:'Sora',system-ui,sans-serif;font-weight:600;font-size:16px;margin:26px 0 8px}
.doc-body p{color:var(--txt-dim);margin-bottom:14px}
.doc-body ul,.doc-body ol{color:var(--txt-dim);margin:0 0 16px 22px}
.doc-body li{margin-bottom:8px}
.doc-body strong{color:var(--txt);font-weight:600}

/* ---- callouts ---- */
.note{
  background:var(--note-bg);border:1px solid var(--glass-line);
  border-left:3px solid var(--amber);
  border-radius:12px;padding:16px 20px;margin:22px 0;
}
.note p{margin-bottom:0}
.note p + p{margin-top:10px}
.note h3{margin-top:0}

/* Anything the business must fill in before publishing. Deliberately loud —
   these are legally material and must not slip through unnoticed. */
.fill{
  background:var(--amber);color:#1a0d02;font-weight:700;
  padding:1px 7px;border-radius:5px;font-size:.93em;white-space:nowrap;
}

.toc{background:var(--glass);border:1px solid var(--glass-line);border-radius:var(--r-md);padding:20px 24px;margin-bottom:34px}
.toc h4{font-family:'Sora',system-ui,sans-serif;font-size:13px;text-transform:uppercase;letter-spacing:.12em;color:var(--txt-faint);margin-bottom:12px}
.toc ol{margin:0 0 0 20px}
.toc li{margin-bottom:5px}
.toc a{color:var(--txt-dim);font-size:14.5px}
.toc a:hover{color:var(--accent-txt)}

table.legal{width:100%;border-collapse:collapse;margin:0 0 18px;font-size:14.5px}
table.legal th,table.legal td{text-align:left;padding:10px 12px;border-bottom:1px solid var(--glass-line);vertical-align:top}
table.legal th{color:var(--txt);font-weight:600;font-size:13px;text-transform:uppercase;letter-spacing:.06em}
table.legal td{color:var(--txt-dim)}

/* ---- footer ---- */
footer{border-top:1px solid var(--glass-line);padding:40px 0;position:relative;z-index:2}
.fbottom{
  max-width:820px;margin:0 auto;padding:0 24px;
  display:flex;justify-content:space-between;gap:14px;flex-wrap:wrap;
  color:var(--txt-faint);font-size:13.5px;
}
.fbottom a{color:var(--txt-faint)}
.fbottom a:hover{color:var(--accent-txt)}

/* ---- Mobile fixes (must sit last: media queries add no specificity, so an
   earlier override would lose to the base rules above) ---- */
@media(max-width:760px){
  /* .fill is nowrap by design so a placeholder reads as one token, but the long
     ones ("If you add analytics or advertising tools…") are far wider than a
     phone screen and dragged the whole document into horizontal scroll
     (measured 646px inside a 375px viewport). Let them wrap when space is tight. */
  .fill{white-space:normal}
  /* Legal tables are wider than a phone column; scroll them rather than let
     them push the page sideways. */
  table.legal{display:block;overflow-x:auto;-webkit-overflow-scrolling:touch;max-width:100%}
  table.legal th,table.legal td{padding:8px 10px;font-size:13.5px}
}
