/* ==========================================================================
   L&V Analytics — design tokens
   ========================================================================== */
:root {
  /* backgrounds */
  --bg-dark: #0a0c10;
  --bg-dark-alt: #12151c;
  --bg-light: #f6f7f9;
  --bg-light-alt: #ffffff;

  /* text */
  --ink: #14161c;
  --ink-soft: #454a55;
  --paper: #f5f6f8;
  --muted-on-dark: #9aa1ae;
  --muted-on-light: #5b6270;

  /* accent */
  --accent: #2fc08a;
  --accent-dark: #157a52;
  --accent-soft: rgba(47, 192, 138, 0.14);

  /* borders */
  --border-dark: rgba(255, 255, 255, 0.09);
  --border-light: rgba(18, 21, 28, 0.09);

  /* shape */
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 26px;
  --radius-full: 999px;

  --shadow-soft: 0 30px 70px -30px rgba(10, 12, 16, 0.45);
  --shadow-card: 0 18px 40px -22px rgba(10, 12, 16, 0.28);

  /* type */
  --font-display: 'Fraunces', Georgia, serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'JetBrains Mono', 'SFMono-Regular', monospace;

  --container-w: 1200px;
}

/* ==========================================================================
   Reset
   ========================================================================== */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-snap-type: y mandatory; }

/* Mandatory snap fights the page on phones: forms routinely run taller than
   one mobile viewport once the keyboard/address bar take their share, and
   "mandatory" actively resists scrolling past a section boundary to reach
   the rest of that content — it can feel like tapping Contact Us "does
   nothing" when really it snapped to the top of a section you then can't
   fully scroll through. Below 768px, sections snap loosely (or not at all)
   instead of fighting the user. */
@media (max-width: 768px) {
  html { scroll-snap-type: none; }
}
body, h1, h2, h3, h4, p, ul, figure { margin: 0; }
ul { padding: 0; list-style: none; }
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }
input, select, textarea { font: inherit; }

body {
  font-family: var(--font-body);
  background: var(--bg-light);
  color: var(--ink);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

section[id] { scroll-margin-top: 84px; }

.container {
  max-width: var(--container-w);
  margin: 0 auto;
  padding: 0 32px;
}

@media (max-width: 640px) {
  .container { padding: 0 20px; }
}

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 500;
  letter-spacing: -0.01em;
  line-height: 1.12;
}

h2 { font-size: clamp(2rem, 3.4vw, 2.75rem); font-weight: 450; }
h3 { font-size: 1.2rem; font-weight: 600; font-family: var(--font-body); }

/* ==========================================================================
   Header / nav
   ========================================================================== */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 26px 0;
  transition: padding 0.35s ease, background 0.35s ease, box-shadow 0.35s ease;
  /* Only the logo needs to be clickable — the rest of this bar is empty
     space now that nav links live in .side-nav. Below 900px that pill
     shares the same vertical band as this header, and without this the
     header's empty area (stacked above it, z-index 100 vs. 90) would
     silently swallow every tap on Home/Contact Us. */
  pointer-events: none;
}
.site-header .logo { pointer-events: auto; }
.nav-inner {
  max-width: var(--container-w);
  margin: 0 auto;
  padding: 0 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.site-header.is-scrolled {
  padding: 14px 0;
  background: rgba(10, 12, 16, 0.82);
  backdrop-filter: blur(14px);
  box-shadow: 0 1px 0 var(--border-dark);
}

.logo { display: flex; align-items: center; }
.logo-stack {
  display: flex;
  flex-direction: column;
  line-height: 1;
}
.logo-lv {
  color: var(--paper);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 2.13rem;
  letter-spacing: -0.01em;
}
.logo-amp {
  font-family: Georgia, 'Times New Roman', serif;
  font-weight: 400;
  font-style: normal;
  margin: 0 0.03em;
}
.logo-analytics {
  color: var(--paper);
  font-family: var(--font-body);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  margin-top: 5px;
}

@media (max-width: 640px) {
  .logo-lv { font-size: 1.73rem; }
  .logo-analytics { font-size: 0.64rem; letter-spacing: 0.22em; }
}

.side-nav {
  position: fixed;
  left: 28px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 90;
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.nav-link {
  position: relative;
  color: var(--paper);
  font-size: 0.95rem;
  font-weight: 600;
  padding-bottom: 3px;
  white-space: nowrap;
  text-shadow: 0 1px 6px rgba(10, 12, 16, 0.5);
}
.nav-link::after {
  content: '';
  position: absolute; left: 0; right: 100%; bottom: 0;
  height: 1px; background: currentColor;
  transition: right 0.3s ease;
}
.nav-link:hover::after { right: 0; }

/* Below 900px there's no longer room for a floating stack in the left
   margin (the page is edge-to-edge), and a fixed bottom bar would sit on
   top of whatever content happens to scroll underneath it — including the
   footer text and the Send Message button. Instead it moves up into the
   header's own reserved strip, next to the logo, where nothing else ever
   renders underneath it. */
@media (max-width: 900px) {
  .side-nav {
    left: auto;
    right: 20px;
    top: 30px;
    bottom: auto;
    transform: none;
    flex-direction: row;
    gap: 20px;
  }
}

@media (max-width: 480px) {
  .side-nav { top: 24px; right: 16px; gap: 14px; }
}

/* ==========================================================================
   Hero
   ========================================================================== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: var(--bg-dark);
  color: var(--paper);
  overflow: hidden;
  scroll-snap-align: start;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: var(--container-w);
  width: 100%;
  margin: 0 auto;
  padding: 140px 32px 64px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.hero-visual {
  width: 100%;
  max-width: 900px;
}
.hero-visual img {
  width: 100%;
  border-radius: var(--radius-lg);
  box-shadow: 0 40px 100px -30px rgba(0, 0, 0, 0.6);
}

.hero-title {
  margin-top: 44px;
  text-align: center;
  font-size: clamp(1.98rem, 4.14vw, 3.15rem);
  max-width: 16em;
}

/* Plain text "Register" links — white, no fill, just a currentColor
   underline that sweeps in on hover (see .nav-link for the same pattern,
   no green hover highlight). Used for the hero CTA and the form's submit
   button; the hero one gets a rectangular outline box on top, below. */
.register-cta {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: none;
  border: none;
  box-shadow: none;
  padding: 4px 0;
  color: var(--paper);
  font-family: inherit;
  font-weight: 600;
  font-size: 1.1rem;
}
.register-cta::after {
  content: '';
  position: absolute; left: 0; right: 100%; bottom: 0;
  height: 1px; background: currentColor;
  transition: right 0.3s ease;
}
.register-cta:hover::after { right: 0; }

.form-card .register-cta { width: 100%; margin-top: 4px; }

/* Hero CTA — same white text, but boxed in a rectangular (not pill) outline
   instead of the underline treatment above. */
.hero .register-cta {
  margin-top: 40px;
  padding: 14px 40px;
  border: 1px solid var(--paper);
  border-radius: var(--radius-sm);
}
.hero .register-cta::after { content: none; }
.hero .register-cta:hover { background: rgba(245, 246, 248, 0.08); }

.scroll-cue {
  position: absolute;
  bottom: 36px; left: 32px;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--muted-on-dark);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.scroll-cue-line {
  width: 1px; height: 34px;
  background: linear-gradient(to bottom, var(--accent), transparent);
}

/* ==========================================================================
   Register + Contact (forms)
   ========================================================================== */
.register {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: var(--bg-dark);
  color: var(--paper);
  padding: 110px 0;
  overflow: hidden;
  scroll-snap-align: start;
}
.register-grid {
  position: relative; z-index: 1;
  display: flex;
  justify-content: center;
}
.register .form-card { width: 100%; max-width: 480px; }

.contact {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: var(--bg-dark);
  color: var(--paper);
  padding: 110px 0;
  scroll-snap-align: start;
}
/* Just the email above the form — same narrow centered-column shape as the
   Register section. */
.contact-grid { display: flex; flex-direction: column; align-items: center; gap: 28px; }
.contact .form-card { width: 100%; max-width: 480px; }

/* Plain text email link — same currentColor underline-on-hover pattern as
   .nav-link and .register-cta (see those for the shared rationale). */
.contact-email {
  position: relative;
  color: var(--paper);
  font-weight: 600;
  font-size: 1.05rem;
}
.contact-email::after {
  content: '';
  position: absolute; left: 0; right: 100%; bottom: -3px;
  height: 1px; background: currentColor;
  transition: right 0.3s ease;
}
.contact-email:hover::after { right: 0; }

.form-card {
  background: var(--bg-light-alt);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 36px;
  box-shadow: var(--shadow-card);
}
.register .form-card,
.contact .form-card { background: var(--bg-dark-alt); border-color: var(--border-dark); }

/* "Send Message" — same rectangular-outline, no-fill treatment as the
   Register buttons (see .register-cta). White, since the Contact section
   now shares the same dark background as the rest of the site. */
.send-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 14px 40px;
  border: 1px solid var(--paper);
  border-radius: var(--radius-sm);
  background: none;
  color: var(--paper);
  font-family: inherit;
  font-weight: 600;
  font-size: 1.1rem;
}
.send-cta:hover { background: rgba(245, 246, 248, 0.08); }

.form-row { margin-bottom: 20px; }
.form-row label {
  display: block; font-size: 0.8rem; font-weight: 600; margin-bottom: 8px;
  color: var(--ink-soft);
}
.register .form-row label,
.contact .form-row label { color: var(--muted-on-dark); }

.form-row input, .form-row select, .form-row textarea {
  width: 100%;
  padding: 13px 16px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-light);
  background: var(--bg-light);
  color: var(--ink);
  transition: border-color 0.25s ease;
}
.register .form-row input, .register .form-row select, .register .form-row textarea,
.contact .form-row input, .contact .form-row select, .contact .form-row textarea {
  background: var(--bg-dark);
  border-color: var(--border-dark);
  color: var(--paper);
}
.form-row input:focus, .form-row select:focus, .form-row textarea:focus {
  outline: none; border-color: var(--accent);
}

/* Browser autofill (e.g. a remembered email address) paints its own
   background over ours, ignoring `background` entirely — this is the only
   way to override it, and without it a remembered field reverts to a
   light/white box even inside the dark Register or Contact cards. */
.register .form-row input:-webkit-autofill,
.contact .form-row input:-webkit-autofill {
  -webkit-text-fill-color: var(--paper);
  -webkit-box-shadow: 0 0 0px 1000px var(--bg-dark) inset;
  box-shadow: 0 0 0px 1000px var(--bg-dark) inset;
  caret-color: var(--paper);
  border-color: var(--border-dark);
}

.form-note {
  margin-top: 16px; font-size: 0.76rem; text-align: center;
  color: var(--muted-on-light);
}
.register .form-note,
.contact .form-note { color: var(--muted-on-dark); }
.form-success {
  margin-top: 16px; font-size: 0.85rem; text-align: center;
  color: var(--accent-dark); font-weight: 600;
}
.register .form-success,
.contact .form-success { color: var(--accent); }

.form-error {
  margin-top: 16px; font-size: 0.85rem; text-align: center;
  color: #c0392b; font-weight: 600;
}
.register .form-error,
.contact .form-error { color: #ff7a6e; }

/* Honeypot spam-trap field — invisible to people, visible to simple bots
   that fill in every field they find. */
.hidden-field {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer {
  background: var(--bg-dark);
  color: var(--muted-on-dark);
  padding: 76px 0 0;
  scroll-snap-align: end;
}
.footer-top {
  display: flex; justify-content: space-between; gap: 60px;
  padding-bottom: 56px; border-bottom: 1px solid var(--border-dark);
  flex-wrap: wrap;
}
.footer-brand { max-width: 320px; }
.footer-links { display: flex; gap: 64px; }
.footer-col h4 {
  font-family: var(--font-mono); font-size: 0.72rem; text-transform: uppercase;
  letter-spacing: 0.08em; color: var(--paper); margin-bottom: 16px; font-weight: 500;
}
.footer-col a { display: block; font-size: 0.88rem; margin-bottom: 12px; }
.footer-col a:hover { color: var(--accent); }

.footer-bottom {
  display: flex; justify-content: space-between; gap: 20px;
  padding: 26px 0; font-size: 0.8rem; flex-wrap: wrap;
}

/* ==========================================================================
   Reveal animation base state (GSAP flips these in)
   ========================================================================== */
.reveal-up { opacity: 0; transform: translateY(28px); }
.no-js .reveal-up { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  .reveal-up { opacity: 1; transform: none; }
  html { scroll-behavior: auto; }
}
