/* Repsalot site — shared tokens + primitives (landing, legal pages, 404).
   Dark brand look that echoes the app's "glass" style (src/theme/glass.js):
   translucent cards with a top sheen, and three soft aura orbs behind. */

:root {
  --bg: #07090d;
  --bg-raised: #0e1118;
  --teal: #2BC0A0;
  --indigo: #7B8CFF;
  --mint: #34D399;
  --flame: #FF8A4C;
  --gold: #F2C94C;
  --brand-gradient: linear-gradient(120deg, var(--teal) 0%, #52A8D8 50%, var(--indigo) 100%);

  --text: #ffffff;
  --muted: rgba(255, 255, 255, 0.66);
  --faint: rgba(255, 255, 255, 0.42);

  --glass: rgba(255, 255, 255, 0.05);
  --glass-strong: rgba(255, 255, 255, 0.08);
  --glass-border: rgba(255, 255, 255, 0.10);
  --glass-sheen: linear-gradient(180deg, rgba(255, 255, 255, 0.09) 0%, rgba(255, 255, 255, 0) 45%, rgba(255, 255, 255, 0.025) 100%);

  --radius-lg: 28px;
  --radius-md: 18px;
  --radius-sm: 12px;
  --gutter: clamp(16px, 4vw, 40px);
  --max: 1160px;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
}

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

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

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: inherit; }
img, svg { display: block; }
button, input { font: inherit; color: inherit; }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

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

/* ---------- Aura backdrop (3 orbs: identity TL, accent CR, shared teal BL) ---------- */
.aura {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}
.aura::after { /* faint grid, masked to the top of the page */
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 56px 56px;
  -webkit-mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, #000 20%, transparent 75%);
          mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, #000 20%, transparent 75%);
}
.orb {
  position: absolute;
  border-radius: 50%;
  opacity: 0.55;
  will-change: transform;
  animation: orb-drift 18s ease-in-out infinite alternate;
}
.orb--tl { width: 70vmax; height: 70vmax; left: -28vmax; top: -30vmax; background: radial-gradient(circle, rgba(43, 192, 160, 0.42), transparent 62%); }
.orb--cr { width: 60vmax; height: 60vmax; right: -26vmax; top: 18vh; background: radial-gradient(circle, rgba(123, 140, 255, 0.36), transparent 62%); animation-delay: -6s; }
.orb--bl { width: 55vmax; height: 55vmax; left: -22vmax; bottom: -30vmax; background: radial-gradient(circle, rgba(52, 211, 153, 0.22), transparent 62%); animation-delay: -12s; }

@keyframes orb-drift {
  0%   { transform: translate3d(0, 0, 0) scale(1); }
  100% { transform: translate3d(4vmax, 3vmax, 0) scale(1.08); }
}

/* ---------- Glass ---------- */
.glass {
  position: relative;
  background: var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
  isolation: isolate;
}
.glass::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: var(--glass-sheen);
  pointer-events: none;
  z-index: -1;
}

/* ---------- Wordmark ---------- */
.wordmark {
  font-weight: 900;
  letter-spacing: -0.035em;
  background: var(--brand-gradient);
  -webkit-background-clip: text;
          background-clip: text;
  -webkit-text-fill-color: transparent;
  text-decoration: none;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  padding: 14px 0;
  transition: background 0.3s ease, border-color 0.3s ease;
  border-bottom: 1px solid transparent;
}
.site-header.is-scrolled {
  background: rgba(7, 9, 13, 0.78);
  border-bottom-color: var(--glass-border);
  -webkit-backdrop-filter: saturate(140%) blur(12px);
          backdrop-filter: saturate(140%) blur(12px);
}
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.site-header .wordmark { font-size: 22px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 22px;
  border: 0;
  border-radius: 14px;
  font-weight: 800;
  font-size: 15px;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
  transition: transform 0.2s var(--ease-out), box-shadow 0.2s ease, opacity 0.2s ease;
}
.btn:active { transform: scale(0.97); }
.btn--primary {
  color: #061015;
  background: var(--brand-gradient);
  box-shadow: 0 8px 30px rgba(43, 192, 160, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.35);
}
.btn--primary:hover { box-shadow: 0 10px 38px rgba(82, 168, 216, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.35); }
.btn--ghost {
  min-height: 40px;
  padding: 0 16px;
  font-size: 14px;
  color: var(--text);
  background: var(--glass-strong);
  border: 1px solid var(--glass-border);
}
.btn--ghost:hover { background: rgba(255, 255, 255, 0.12); }
.btn[disabled] { opacity: 0.6; cursor: progress; }

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

/* ---------- Footer ---------- */
.site-footer {
  padding: 48px 0 40px;
  color: var(--faint);
  font-size: 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}
.site-footer .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.site-footer a { color: var(--muted); text-decoration: none; }
.site-footer a:hover { color: var(--text); }
.socials { display: flex; gap: 10px; }
.socials a {
  display: grid;
  place-items: center;
  width: 40px; height: 40px;
  border-radius: 12px;
  background: var(--glass);
  border: 1px solid var(--glass-border);
  color: var(--muted);
}
.socials a:hover { color: var(--text); background: var(--glass-strong); }
.socials svg { width: 18px; height: 18px; }

/* ---------- Document pages (privacy / terms / 404) ---------- */
.doc {
  max-width: 760px;
  margin: 32px auto 80px;
  padding: clamp(24px, 5vw, 56px);
}
.doc h1 { font-size: clamp(30px, 6vw, 44px); line-height: 1.1; letter-spacing: -0.03em; margin-bottom: 20px; }
.doc h2 { font-size: 21px; margin: 40px 0 12px; letter-spacing: -0.01em; }
.doc h3 { font-size: 17px; margin: 28px 0 10px; }
.doc p, .doc li { color: var(--muted); font-size: 16px; }
.doc p { margin-bottom: 14px; }
.doc ul, .doc ol { margin: 0 0 16px 22px; }
.doc li { margin-bottom: 6px; }
.doc strong { color: var(--text); }
.doc a { color: var(--teal); }
.doc hr { border: 0; border-top: 1px solid var(--glass-border); margin: 32px 0; }

@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;
  }
}
