/* =========================================
   Digirisers — Legal Pages Stylesheet
   Shared by privacy.html, terms.html, refund.html
   Blue · White · Black
   ========================================= */

:root {
  --blue-50:  #eff6ff;
  --blue-100: #dbeafe;
  --blue-200: #bfdbfe;
  --blue-300: #93c5fd;
  --blue-400: #60a5fa;
  --blue-500: #3b82f6;
  --blue-600: #2563eb;
  --blue-700: #1d4ed8;
  --blue-800: #1e40af;
  --blue-900: #1e3a8a;

  --ink:      #0b1020;
  --ink-2:    #111827;
  --muted:    #475569;
  --soft:     #64748b;
  --soft-2:   #94a3b8;
  --line:     #e5e7eb;
  --line-2:   #eef1f5;
  --bg:       #ffffff;
  --bg-soft:  #f8fafc;
  --bg-tint:  #fafbff;

  --r-sm: 10px;
  --r:    14px;
  --r-md: 20px;
  --r-lg: 28px;

  --shadow-xs: 0 1px 2px rgba(11, 16, 32, .04);
  --shadow-sm: 0 2px 6px rgba(11, 16, 32, .06), 0 1px 2px rgba(11, 16, 32, .04);
  --shadow:    0 14px 40px -18px rgba(30, 58, 138, .25);
  --shadow-lg: 0 40px 80px -30px rgba(30, 58, 138, .35);
  --ring-blue: 0 0 0 4px rgba(59, 130, 246, .18);

  --grad:      linear-gradient(135deg, #3b82f6 0%, #1e3a8a 100%);
  --grad-alt:  linear-gradient(135deg, #60a5fa 0%, #2563eb 50%, #1e3a8a 100%);
  --grad-soft: linear-gradient(180deg, #f5f8ff 0%, #ffffff 60%);

  --font: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-serif: 'Instrument Serif', ui-serif, Georgia, serif;
  --font-mono: 'JetBrains Mono', ui-monospace, monospace;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; scroll-padding-top: 100px; }
html, body { overflow-x: hidden; max-width: 100vw; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-feature-settings: "ss01", "cv11";
}
img { max-width: 100%; display: block; }
a { color: var(--blue-700); text-decoration: none; transition: color .2s ease; }
a:hover { color: var(--blue-900); }
::selection { background: var(--blue-600); color: #fff; }

h1, h2, h3, h4 {
  color: var(--ink);
  margin: 0 0 .4em;
  line-height: 1.15;
  letter-spacing: -0.025em;
  font-weight: 700;
}
h1 { font-size: clamp(2.4rem, 5vw, 3.8rem); letter-spacing: -0.04em; }
h2 { font-size: clamp(1.5rem, 2.6vw, 1.9rem); margin-top: 2.4em; letter-spacing: -0.025em; }
h3 { font-size: 1.15rem; font-weight: 600; margin-top: 1.6em; }

.serif-italic {
  font-family: var(--font-serif);
  font-weight: 400;
  font-style: italic;
  letter-spacing: -0.01em;
}
.gradient-text {
  background: var(--grad-alt);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  padding-right: 2px;
}
.container { width: 100%; max-width: 1240px; margin: 0 auto; padding: 0 24px; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: 8px; padding: 12px 22px; border-radius: 999px;
  font-weight: 600; font-size: .95rem; font-family: inherit;
  border: 1px solid transparent; cursor: pointer;
  transition: transform .2s ease, box-shadow .25s ease, background .25s ease, color .25s ease, border-color .25s ease;
  white-space: nowrap; position: relative;
}
.btn-primary {
  background: var(--grad); color: #fff;
  box-shadow: 0 10px 30px -10px rgba(37, 99, 235, .7), inset 0 1px 0 rgba(255,255,255,.2);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 18px 40px -10px rgba(37,99,235,.65); color: #fff; }
.btn-light { background: #fff; color: var(--ink); }
.btn-light:hover { transform: translateY(-2px); box-shadow: 0 12px 30px -10px rgba(0,0,0,.4); color: var(--ink); }

/* Nav (mirrors main site) */
.nav {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255, 255, 255, .82);
  backdrop-filter: saturate(180%) blur(18px);
  -webkit-backdrop-filter: saturate(180%) blur(18px);
  border-bottom: 1px solid var(--line);
}
.nav-inner {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 0; gap: 24px;
}
.logo {
  display: inline-flex; align-items: center; gap: 10px;
  font-weight: 700; font-size: 1.28rem; letter-spacing: -0.02em; color: var(--ink);
}
.logo:hover { color: var(--ink); }
.logo-mark { display: inline-grid; place-items: center; transition: transform .4s ease; }
.logo:hover .logo-mark { transform: rotate(-6deg) scale(1.05); }
.logo-dot { color: var(--blue-600); }
.nav-links { display: flex; gap: 32px; font-weight: 500; font-size: .95rem; }
.nav-links a { color: var(--muted); padding: 6px 0; position: relative; }
.nav-links a:hover { color: var(--ink); }
.nav-links a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -2px;
  height: 2px; background: var(--blue-600);
  transform: scaleX(0); transform-origin: left; transition: transform .3s ease;
}
.nav-links a:hover::after { transform: scaleX(1); }
.nav-right { display: flex; align-items: center; gap: 14px; }
.nav-toggle { display: none; background: transparent; border: 0; width: 44px; height: 44px; padding: 0; cursor: pointer; }
.nav-toggle span { display: block; width: 22px; height: 2px; background: var(--ink); margin: 6px auto; border-radius: 2px; transition: .3s; }

/* Page hero */
.legal-hero {
  position: relative; overflow: hidden;
  background: var(--grad-soft);
  padding: 100px 0 80px;
  border-bottom: 1px solid var(--line);
}
.legal-hero::before {
  content: ""; position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(148,163,184,.15) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148,163,184,.15) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(ellipse 60% 60% at 50% 30%, #000 30%, transparent 80%);
  -webkit-mask-image: radial-gradient(ellipse 60% 60% at 50% 30%, #000 30%, transparent 80%);
  pointer-events: none;
}
.legal-hero::after {
  content: ""; position: absolute; top: -160px; left: 50%; transform: translateX(-50%);
  width: 1100px; height: 600px;
  background: radial-gradient(ellipse at center, rgba(59,130,246,.22) 0%, transparent 55%);
  pointer-events: none;
}
.legal-hero-inner { position: relative; z-index: 1; max-width: 820px; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: .78rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: .14em;
  color: var(--blue-700);
  background: #fff;
  border: 1px solid var(--blue-100);
  padding: 7px 14px;
  border-radius: 999px;
  margin-bottom: 22px;
  box-shadow: var(--shadow-xs);
}
.eyebrow .dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--blue-600);
  box-shadow: 0 0 0 3px var(--blue-100);
}
.legal-hero h1 { margin-bottom: 18px; }
.legal-hero p {
  font-size: 1.15rem; color: var(--muted);
  max-width: 660px; margin: 0;
}
.legal-meta {
  margin-top: 28px; display: flex; flex-wrap: wrap; gap: 10px 14px;
  font-size: .85rem; color: var(--soft); font-family: var(--font-mono); letter-spacing: .02em;
}
.legal-meta span {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 12px; background: #fff;
  border: 1px solid var(--line); border-radius: 999px;
}
.legal-meta span::before {
  content: ""; width: 5px; height: 5px; border-radius: 50%; background: var(--blue-500);
}

/* Article body */
.legal-body {
  padding: 80px 0 120px;
  background: #fff;
}
.legal-body-inner {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 64px;
  align-items: start;
}
.toc {
  position: sticky; top: 100px;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  padding: 20px 22px;
  background: var(--bg-soft);
}
.toc h4 {
  font-size: .72rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .14em;
  color: var(--soft); margin: 0 0 14px;
}
.toc ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.toc a {
  display: block; padding: 7px 10px;
  font-size: .88rem; color: var(--muted);
  border-radius: 8px; line-height: 1.4;
  border-left: 2px solid transparent;
  transition: all .2s ease;
}
.toc a:hover {
  color: var(--ink);
  background: #fff;
  border-left-color: var(--blue-500);
}

article.legal-article {
  max-width: 760px;
  font-size: 1rem;
  color: var(--muted);
}
article.legal-article > h2:first-child { margin-top: 0; }
article.legal-article p { margin: 0 0 1.1em; }
article.legal-article ul, article.legal-article ol {
  margin: 0 0 1.4em; padding-left: 22px;
}
article.legal-article li { margin-bottom: .5em; }
article.legal-article li::marker { color: var(--blue-600); }
article.legal-article strong { color: var(--ink); font-weight: 600; }
article.legal-article a { font-weight: 500; }
article.legal-article hr {
  border: 0; height: 1px; background: var(--line); margin: 3em 0;
}

.callout {
  margin: 1.6em 0; padding: 20px 22px;
  background: var(--blue-50);
  border: 1px solid var(--blue-100);
  border-left: 3px solid var(--blue-600);
  border-radius: 12px;
  color: var(--ink-2);
  font-size: .95rem;
}
.callout strong { color: var(--blue-900); }

/* Definition card grid (used on Privacy "data we collect") */
.def-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px; margin: 0 0 1.8em;
}
.def {
  background: #fff; border: 1px solid var(--line);
  border-radius: var(--r); padding: 18px 18px;
  transition: border-color .25s ease, transform .25s ease;
}
.def:hover { border-color: var(--blue-300); transform: translateY(-2px); }
.def h4 { font-size: .82rem; margin: 0 0 6px; color: var(--blue-700); text-transform: uppercase; letter-spacing: .08em; }
.def p { margin: 0; font-size: .9rem; color: var(--muted); }

/* Contact card at end */
.legal-contact {
  margin-top: 3em;
  padding: 28px 28px;
  background: var(--bg-soft);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
}
.legal-contact h3 { margin: 0 0 8px; color: var(--ink); font-size: 1.15rem; }
.legal-contact p { margin: 0 0 14px; }
.legal-contact .lc-row {
  display: flex; flex-wrap: wrap; gap: 8px 24px;
  font-size: .95rem; color: var(--ink);
}
.legal-contact .lc-row a {
  font-weight: 600; color: var(--blue-700);
}

/* Footer (mirrors main site, simplified) */
.footer {
  background: var(--ink); color: rgba(255,255,255,.72);
  padding: 80px 0 28px; position: relative; overflow: hidden;
}
.footer::before {
  content: ""; position: absolute; top: 0; left: 50%; transform: translateX(-50%);
  width: 1200px; height: 600px;
  background: radial-gradient(ellipse at center top, rgba(59,130,246,.18), transparent 60%);
  pointer-events: none;
}
.footer .container { position: relative; }
.footer-inner {
  display: grid; grid-template-columns: 1.2fr 2fr; gap: 80px;
  padding-bottom: 56px;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.footer .logo-text { color: #fff; }
.footer .logo-dot { color: var(--blue-400); }
.footer .logo:hover { color: #fff; }
.footer-brand p { max-width: 320px; font-size: .95rem; color: rgba(255,255,255,.6); margin: 16px 0 20px; }
.footer-phone {
  display: inline-block; color: #fff; font-weight: 600; font-size: 1.05rem;
  padding: 10px 16px; border: 1px solid rgba(255,255,255,.15); border-radius: 10px;
  transition: all .2s ease;
}
.footer-phone:hover { background: rgba(255,255,255,.08); border-color: var(--blue-400); color: #fff; }
.footer-cols { display: grid; grid-template-columns: repeat(4, 1fr); gap: 32px; }
.footer-cols h5 {
  color: #fff; margin: 0 0 18px; font-size: .85rem;
  font-weight: 600; letter-spacing: .1em; text-transform: uppercase;
}
.footer-cols ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.footer-cols a { font-size: .92rem; color: rgba(255,255,255,.6); transition: color .2s ease; }
.footer-cols a:hover { color: #fff; }
.footer-bottom {
  display: flex; justify-content: space-between; align-items: center;
  padding-top: 28px; color: rgba(255,255,255,.5); font-size: .85rem;
  flex-wrap: wrap; gap: 10px;
}
.footer-links a { color: rgba(255,255,255,.65); }
.footer-links a:hover { color: #fff; }
.footer-links span { opacity: .4; margin: 0 8px; }

/* Responsive */
@media (max-width: 980px) {
  .legal-body-inner { grid-template-columns: 1fr; gap: 32px; }
  .toc { position: static; }
}
@media (max-width: 860px) {
  .nav-links, .nav-right { display: none; }
  .nav-toggle { display: block; }
  .nav.open .nav-inner { flex-wrap: wrap; }
  .nav.open .nav-links {
    display: flex; flex-direction: column; gap: 14px;
    width: 100%; padding: 18px 0 6px; margin-top: 14px;
    border-top: 1px solid var(--line); order: 3;
  }
  .nav.open .nav-right {
    display: flex; width: 100%;
    padding: 6px 0 14px; order: 4;
  }
  .nav.open .nav-cta { width: 100%; }
  .footer-inner { grid-template-columns: 1fr; gap: 40px; }
  .footer-cols { grid-template-columns: repeat(2, 1fr); gap: 24px; }
}
@media (max-width: 640px) {
  .container { padding: 0 18px; }
  .legal-hero { padding: 60px 0 50px; }
  .legal-hero p { font-size: 1rem; }
  .legal-body { padding: 56px 0 80px; }
  article.legal-article { font-size: .98rem; }
  h2 { margin-top: 1.8em; }
  .footer-cols { grid-template-columns: 1fr 1fr; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
}
@media (max-width: 420px) {
  .footer-cols { grid-template-columns: 1fr; }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    transition-duration: .01ms !important;
    scroll-behavior: auto !important;
  }
}
