/* ============================================================
   VivaGuard — main.css
   Design tokens, reset, typography, global utilities
   ============================================================ */

/* Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@400;600;700&family=Inter:wght@400;500&display=swap');

/* ── Design Tokens ──────────────────────────────────────────── */
:root {
  /* Brand colors */
  --vg-navy:        #1B2A5A;
  --vg-blue:        #3D6CB9;
  --vg-blue-light:  #5B9BD5;
  --vg-blue-pale:   #D6E8F7;
  --vg-coral:       #E8593C;
  --vg-coral-light: #F5C4B3;
  --vg-white:       #FFFFFF;
  --vg-gray-light:  #F5F5F3;
  --vg-gray:        #888780;
  --vg-gray-dark:   #3D3D3A;

  /* Typography */
  --font-display: 'Outfit', sans-serif;
  --font-body:    'Inter', sans-serif;

  /* Spacing */
  --section-py-desktop: 96px;
  --section-py-tablet:  64px;
  --section-py-mobile:  48px;
  --max-width: 1280px;
  --px-desktop: 80px;
  --px-mobile:  24px;

  /* Radius */
  --radius-card: 16px;
  --radius-btn:  12px;
  --radius-badge: 8px;

  /* Shadows */
  --shadow-card:       0 4px 24px rgba(27, 42, 90, 0.08);
  --shadow-card-hover: 0 8px 40px rgba(27, 42, 90, 0.14);
  --shadow-nav:        0 2px 20px rgba(27, 42, 90, 0.10);

  /* Transitions */
  --transition-fast: 150ms ease;
  --transition-base: 250ms ease;
  --transition-slow: 400ms ease;
}

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

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

body {
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.7;
  color: var(--vg-gray-dark);
  background: var(--vg-white);
  overflow-x: hidden;
}

img, video, svg {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--vg-blue);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover { color: var(--vg-navy); }

ul, ol { list-style: none; }

/* ── Skip to Content ────────────────────────────────────────── */
.skip-link {
  position: absolute;
  top: -100%;
  left: 1rem;
  background: var(--vg-coral);
  color: var(--vg-white);
  padding: 0.75rem 1.25rem;
  border-radius: var(--radius-btn);
  font-weight: 600;
  z-index: 9999;
  transition: top var(--transition-fast);
}
.skip-link:focus {
  top: 1rem;
  outline: 3px solid var(--vg-navy);
  outline-offset: 2px;
}

/* ── Typography ─────────────────────────────────────────────── */
h1, h2, h3, h4, h5 {
  font-family: var(--font-display);
  color: var(--vg-navy);
  line-height: 1.15;
}

h1 {
  font-size: clamp(36px, 6vw, 72px);
  font-weight: 700;
  line-height: 1.1;
}

h2 {
  font-size: clamp(28px, 4vw, 48px);
  font-weight: 600;
  line-height: 1.2;
}

h3 {
  font-size: 28px;
  font-weight: 600;
  line-height: 1.3;
}

.body-large {
  font-size: 20px;
  line-height: 1.7;
}

.caption {
  font-size: 14px;
  line-height: 1.5;
}

/* ── Layout Utilities ───────────────────────────────────────── */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--px-desktop);
}

.section-py {
  padding: var(--section-py-desktop) 0;
}

.section-bg-pale  { background: var(--vg-blue-pale); }
.section-bg-gray  { background: var(--vg-gray-light); }
.section-bg-navy  { background: var(--vg-navy); }
.section-bg-white { background: var(--vg-white); }

.text-center { text-align: center; }
.text-navy   { color: var(--vg-navy); }
.text-blue   { color: var(--vg-blue); }
.text-coral  { color: var(--vg-coral); }
.text-white  { color: var(--vg-white); }
.text-gray   { color: var(--vg-gray); }

/* ── Buttons ────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.88rem 1.75rem;
  border-radius: var(--radius-btn);
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 600;
  line-height: 1;
  cursor: pointer;
  border: 2px solid transparent;
  transition: background var(--transition-base), color var(--transition-base),
              border-color var(--transition-base), box-shadow var(--transition-base),
              transform var(--transition-fast);
  text-decoration: none;
  min-height: 44px;
}

.btn:focus-visible {
  outline: 3px solid var(--vg-coral);
  outline-offset: 2px;
}

.btn:active { transform: scale(0.97); }

.btn-primary {
  background: var(--vg-blue);
  color: var(--vg-white);
  border-color: var(--vg-blue);
}
.btn-primary:hover {
  background: var(--vg-navy);
  border-color: var(--vg-navy);
  color: var(--vg-white);
  box-shadow: var(--shadow-card);
}

.btn-primary-coral {
  background: var(--vg-coral);
  color: var(--vg-white);
  border-color: var(--vg-coral);
}
.btn-primary-coral:hover {
  background: #c9432a;
  border-color: #c9432a;
  color: var(--vg-white);
  box-shadow: var(--shadow-card);
}

.btn-secondary {
  background: transparent;
  color: var(--vg-blue);
  border-color: var(--vg-blue);
}
.btn-secondary:hover {
  background: var(--vg-blue-pale);
  color: var(--vg-navy);
  border-color: var(--vg-navy);
}

.btn-outline-white {
  background: transparent;
  color: var(--vg-white);
  border-color: rgba(255,255,255,0.7);
}
.btn-outline-white:hover {
  background: rgba(255,255,255,0.12);
  border-color: var(--vg-white);
  color: var(--vg-white);
}

.btn-lg {
  padding: 1.1rem 2.25rem;
  font-size: 1.1rem;
}

/* ── Focus ring (global) ────────────────────────────────────── */
:focus-visible {
  outline: 3px solid var(--vg-coral);
  outline-offset: 2px;
}

/* ── Section header ─────────────────────────────────────────── */
.section-header {
  margin-bottom: 3rem;
}
.section-header h2 {
  margin-bottom: 1rem;
}
.section-header p {
  font-size: 20px;
  color: var(--vg-gray);
  max-width: 640px;
}
.section-header.center {
  text-align: center;
}
.section-header.center p {
  margin: 0 auto;
}

/* ── Pill badge ─────────────────────────────────────────────── */
.pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.35rem 1rem;
  border-radius: 100px;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.02em;
}
.pill-blue {
  background: var(--vg-blue-pale);
  color: var(--vg-blue);
}
.pill-coral {
  background: var(--vg-coral-light);
  color: var(--vg-coral);
}
.pill-navy {
  background: var(--vg-navy);
  color: var(--vg-white);
}
.pill-green {
  background: #d4edda;
  color: #155724;
}

/* ── Divider ─────────────────────────────────────────────────── */
.divider {
  width: 60px;
  height: 4px;
  background: var(--vg-coral);
  border-radius: 2px;
  margin: 1rem auto 0;
}
.divider-left { margin-left: 0; }

/* ── Animation helpers ──────────────────────────────────────── */
.fade-in {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity var(--transition-slow), transform var(--transition-slow);
}
.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}
.fade-in-delay-1 { transition-delay: 100ms; }
.fade-in-delay-2 { transition-delay: 200ms; }
.fade-in-delay-3 { transition-delay: 300ms; }
.fade-in-delay-4 { transition-delay: 400ms; }

/* ── Reduce motion ──────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  html { scroll-behavior: auto; }
  .fade-in { opacity: 1; transform: none; }
}
