/* ============================================================
   AI Advisor Lab — v2 landing page styles
   Design tokens + base element styles + responsive breakpoints
   ============================================================ */

/* ---------- DESIGN TOKENS ---------- */
:root {
  --pure-white: #FFFFFF;
  --deep-black: #000000;
  --neutral-gray: #6B7280;
  --medium-gray: #9CA3AF;
  --dark-gray: #1F2937;
  --light-gray: #F3F4F6;
  --surface-alt: #FAFBFC;
  --border-gray: #E5E7EB;

  --professional-blue: #0078D4;
  --professional-blue-hover: #006ABC;
  --professional-blue-deep: #0056b3;
  --blue-dark: #003D7A;
  --cyan-accent: #00BCF2;
  --light-blue: #E3F2FD;

  --success-green: #10B981;
  --success-green-deep: #059669;
  --mint-surface: #D1FAE5;
  --mint-border: #6EE7B7;
  --mint-soft: #F0FDF4;

  --alert-red: #DC2626;
  --warn-amber: #F59E0B;

  --violet-500: #6366F1;
  --violet-surface: #E0E7FF;
  --purple-600: #9333EA;

  --fg-1: var(--deep-black);
  --fg-2: var(--dark-gray);
  --fg-3: var(--neutral-gray);
  --fg-muted: var(--medium-gray);
  --fg-link: var(--professional-blue);

  --bg-canvas: var(--pure-white);
  --bg-surface-alt: var(--surface-alt);
  --bg-chip: var(--light-gray);

  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI',
               system-ui, 'Helvetica Neue', Arial, sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas,
               'Liberation Mono', 'Courier New', monospace;

  --container-max: 1200px;
  --container-narrow: 980px;
  --container-prose: 800px;

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-pill: 999px;

  --shadow-sm: 0 2px 8px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 6px rgba(0,0,0,0.07);
  --shadow-lg: 0 8px 16px rgba(0,0,0,0.10);
}

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

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

body {
  font-family: var(--font-sans);
  color: var(--fg-2);
  line-height: 1.6;
  background: var(--bg-canvas);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

section { scroll-margin-top: 80px; }
a { text-decoration: none; }
img { max-width: 100%; height: auto; display: block; }

.hero-highlight { color: var(--professional-blue); }

/* ---------- SKIP LINK (accessibility) ---------- */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--blue-dark);
  color: #fff;
  padding: 10px 16px;
  z-index: 10000;
  font-weight: 600;
  border-radius: 0 0 8px 0;
}
.skip-link:focus {
  left: 0;
  top: 0;
  outline: 3px solid var(--cyan-accent);
}

/* ============================================================
   RESPONSIVE — breakpoints at 1200 / 1024 / 768 / 480
   !important is required to override the inline grid styles
   that React components set via the style={{}} prop.
   ============================================================ */

/* ≤1200px — first shrink on smaller desktops / large tablets */
@media (max-width: 1200px) {
  /* Containers shrink padding */
  .v2-container { padding-left: 32px !important; padding-right: 32px !important; }
}

/* ≤1024px — tablet landscape / portrait collapse */
@media (max-width: 1024px) {
  .v2-asi-grid,
  .v2-cases-grid { grid-template-columns: 1fr !important; }

  .v2-persona-grid,
  .v2-services-grid,
  .v2-partnership-grid,
  .v2-pricing-grid,
  .v2-proserv-grid { grid-template-columns: repeat(2, 1fr) !important; }

  .v3-stat-bar { grid-template-columns: repeat(2, 1fr) !important; }

  /* Hero type ramps down */
  .v2-hero h1 { font-size: 44px !important; }
  .v2-hero p.v2-hero-sub { font-size: 17px !important; }

  /* Section padding shrink */
  .v2-section { padding-top: 64px !important; padding-bottom: 64px !important; }
}

/* ≤768px — tablet portrait / large phone */
@media (max-width: 768px) {
  .v2-persona-grid,
  .v2-services-grid,
  .v2-partnership-grid,
  .v2-pricing-grid,
  .v2-proserv-grid { grid-template-columns: 1fr !important; }

  .v3-stat-bar { grid-template-columns: repeat(2, 1fr) !important; }

  /* Container padding */
  .v2-container,
  [data-v2-container] { padding-left: 20px !important; padding-right: 20px !important; }

  /* Typography scale */
  .v2-hero h1 { font-size: 34px !important; line-height: 1.1 !important; }
  .v2-hero p.v2-hero-sub { font-size: 16px !important; }
  h2 { font-size: 28px !important; line-height: 1.2 !important; }
  h3 { font-size: 20px !important; }

  /* Section padding */
  .v2-section { padding-top: 48px !important; padding-bottom: 48px !important; }

  /* Nav — hide primary links, show hamburger */
  .v2-nav-links { display: none !important; }
  .v2-nav-toggle { display: inline-flex !important; }

  /* Let any inline-grid with ≥3 cols fall back to 1 col when marked
     with the generic responsive hook */
  .v2-grid-3 { grid-template-columns: 1fr !important; }
  .v2-grid-4 { grid-template-columns: 1fr !important; }
  .v2-grid-5 { grid-template-columns: 1fr !important; }
  .v2-grid-6 { grid-template-columns: 1fr !important; }

  /* Category-map & diagnostic tables: allow horizontal scroll rather
     than crushing content */
  .v2-scroll-on-mobile { overflow-x: auto !important; }
  .v2-scroll-on-mobile > * { min-width: 640px !important; }

  /* Pricing compare table — let it scroll horizontally */
  .v2-pricing-compare { overflow-x: auto !important; }
  .v2-pricing-compare > * { min-width: 720px !important; }

  /* Hero dual-CTA buttons go full-width stack */
  .v2-hero a[role="button"],
  .v2-hero .v2-cta-row a,
  .v2-hero .v2-cta-row button { display: block !important; width: 100% !important; text-align: center !important; }

  /* Hero dual-button/caption row: stack to 1 col on phones */
  .v2-hero-cta-row { grid-template-columns: 1fr !important; gap: 24px !important; }

  /* Features grid (Platform Capabilities): 2-col -> 1-col on phone */
  .v2-features-grid { grid-template-columns: 1fr !important; }

  /* Testimonials: identity block + quote stack vertically on phone */
  .v2-testi-row { flex-direction: column !important; gap: 16px !important; padding: 28px 22px !important; }
  .v2-testi-row > div:first-child { width: auto !important; }
}

/* ≤480px — small phones */
@media (max-width: 480px) {
  .v3-stat-bar { grid-template-columns: 1fr !important; }

  .v2-container,
  [data-v2-container] { padding-left: 16px !important; padding-right: 16px !important; }

  .v2-hero h1 { font-size: 28px !important; }
  h2 { font-size: 24px !important; }
  h3 { font-size: 18px !important; }

  .v2-section { padding-top: 36px !important; padding-bottom: 36px !important; }

  /* Any 2-col fallback grid flattens */
  .v2-grid-2 { grid-template-columns: 1fr !important; }
}

/* ---------- NAV HAMBURGER (shown at ≤768px) ---------- */
.v2-nav-toggle {
  display: none;
  background: transparent;
  border: 1px solid var(--border-gray);
  border-radius: 6px;
  padding: 8px 10px;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  margin-left: auto;
}
.v2-nav-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--fg-2);
  margin: 3px 0;
  transition: transform 200ms, opacity 200ms;
}

/* Mobile panel — appears when .v2-nav-links carries .v2-open */
@media (max-width: 768px) {
  .v2-nav-links.v2-open {
    display: flex !important;
    flex-direction: column !important;
    position: absolute !important;
    top: 100% !important;
    left: 0 !important;
    right: 0 !important;
    background: #fff !important;
    border-bottom: 1px solid var(--border-gray) !important;
    padding: 16px 20px !important;
    gap: 14px !important;
    margin-left: 0 !important;
    z-index: 49 !important;
    box-shadow: 0 8px 24px rgba(0,0,0,0.08) !important;
  }
  .v2-nav-links.v2-open > * { width: 100%; }
}

/* Reduced-motion preference */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* ============================================================
   DISCLAIMER BAR  (sits between the ClosingCta and the Footer)
   Light surface, muted ink, tight professional typography.
   ============================================================ */
.disclaimer-bar {
  background: #F8FAFC;
  border-top: 1px solid #E5E7EB;
  border-bottom: 1px solid #E5E7EB;
  padding: 28px 0;
}
.disclaimer-inner {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 40px;
  font-size: 12.5px;
  line-height: 1.7;
  color: #475569;
}
.disclaimer-inner strong {
  color: #1F2937;
  font-weight: 700;
  letter-spacing: 0.01em;
}
.disclaimer-inner a {
  color: var(--professional-blue);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.disclaimer-inner a:hover { color: var(--professional-blue-hover); }

@media (max-width: 768px) {
  .disclaimer-bar  { padding: 22px 0; }
  .disclaimer-inner { padding: 0 20px; font-size: 13px; }
}

/* ============================================================
   SITE FOOTER  —  dark, 4-column grid with brand + link columns
   + bottom legal rail.
   ============================================================ */
.site-footer {
  background: #0F172A;
  color: #CBD5E1;
  padding: 56px 0 28px;
  margin-top: 0;
}

.footer-inner {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 40px;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px;
}

.footer-brand { min-width: 0; }
.footer-brand-lockup {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  margin-bottom: 14px;
  letter-spacing: -0.02em;
}
.footer-brand-logo {
  height: 44px;
  width: auto;
  display: block;
  flex-shrink: 0;
}
.footer-brand-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
}
.footer-brand-name {
  font-size: 20px;
  font-weight: 600;
  color: #FFFFFF;
  line-height: 1.2;
}
.footer-brand-tagline {
  font-size: 13px;
  font-weight: 400;
  color: #94A3B8;
  line-height: 1.2;
  margin-top: 2px;
}
.footer-tagline {
  font-size: 13px;
  line-height: 1.6;
  color: #94A3B8;
  margin-bottom: 16px;
  max-width: 360px;
}
.footer-brand p { margin: 0 0 6px; }
.footer-brand p[style] { color: #64748B !important; }

.footer-col h4 {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #F1F5F9;
  margin-bottom: 14px;
}
.footer-col ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 9px;
}
.footer-col ul li a {
  font-size: 14px;
  color: #94A3B8;
  text-decoration: none;
  transition: color 150ms;
}
.footer-col ul li a:hover { color: var(--cyan-accent); }

.footer-bottom {
  max-width: var(--container-max);
  margin: 36px auto 0;
  padding: 20px 40px 0;
  border-top: 1px solid rgba(255,255,255,0.08);
}
.footer-bottom p {
  font-size: 13px;
  line-height: 1.6;
  color: #64748B;
  margin: 0 0 8px;
}
.footer-bottom p:last-child { margin-bottom: 0; }
.footer-bottom a {
  color: #94A3B8;
  text-decoration: none;
  font-size: 13px;
  transition: color 150ms;
}
.footer-bottom a:hover { color: var(--cyan-accent); }

@media (max-width: 1024px) {
  .footer-inner { grid-template-columns: 1fr 1fr; gap: 36px; }
  .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 768px) {
  .site-footer   { padding: 40px 0 20px; }
  .footer-inner  { grid-template-columns: 1fr; gap: 28px; padding: 0 20px; }
  .footer-bottom { padding: 18px 20px 0; }
}
