/* =========================================================
   CARTER SIMMONS — AI CONSULTING
   shared.css — canonical design tokens + cross-page utilities
   Visual system: Ink (#14110D) + Parchment (#F7F6F3) + monochrome accents
   Type: Inter (variable) + JetBrains Mono (console/mono accents)
          + Plus Jakarta Sans (display headlines)
   =========================================================
   USAGE: All pages link this file first, then add page-specific
   <style> blocks for their own layout/component CSS only.
   ========================================================= */

/* ── DISPLAY FONT — Plus Jakarta Sans ───────────────────── */
@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

/* ── DESIGN TOKENS ─────────────────────────────────────── */
:root {
  /* Palette */
  --parchment:   #F7F6F3;
  --parchment-2: #F1F0EC;
  --parchment-3: #E9E7E1;
  --ink:         #14110D;
  --ink-2:       #2A2724;
  --ink-3:       #3A3733;
  --ink-muted:   #6A655C;
  --gold:        #14110D;
  --gold-2:      #3A3733;
  --gold-fill:   #14110D;
  --gold-3:      #E9E7E1;
  --gold-glow:   rgba(20,17,13,0.20);
  --rule:        rgba(0,0,0,0.08);
  --rule-light:  rgba(255,255,255,0.08);

  /* Semantic aliases — use in new code */
  --surface-card:       var(--parchment);
  --surface-card-dark:  var(--ink);
  --surface-tint:       rgba(20,17,13,0.05);
  --surface-tint-strong:rgba(20,17,13,0.09);
  --text-strong:        var(--ink);
  --text-body:          var(--ink-2);
  --text-muted:         var(--ink-muted);
  --text-on-dark:       var(--parchment);
  --text-on-dark-muted: rgba(245,243,240,0.55);
  --text-on-dark-soft:  rgba(245,243,240,0.72);
  --accent:             var(--gold);
  --accent-soft:        var(--gold-2);
  --rule-soft:          var(--rule);
  --rule-on-dark:       rgba(245,243,240,0.10);

  /* Layout */
  --max: 1320px;
}

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

/* ── BASE ───────────────────────────────────────────────── */
html { scroll-behavior: smooth; }

body {
  background: var(--parchment);
  color: var(--ink);
  font-family: 'Helvetica Neue',Helvetica,Arial,sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a  { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }
img, svg { display: block; max-width: 100%; }

/* ── ANIMATIONS ─────────────────────────────────────────── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes pulseDot {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.4; }
}

@keyframes shimmer {
  0%   { background-position: 0% 0%; }
  100% { background-position: 200% 0%; }
}

/* ── SCROLL-REVEAL ──────────────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.85s cubic-bezier(0.16,1,0.3,1), transform 0.85s cubic-bezier(0.16,1,0.3,1);
}
.reveal.visible { opacity: 1; transform: translateY(0); }
.reveal-d1 { transition-delay: 0.08s; }
.reveal-d2 { transition-delay: 0.16s; }
.reveal-d3 { transition-delay: 0.24s; }
.reveal-d4 { transition-delay: 0.32s; }
.reveal-left { opacity: 0; transform: translateX(-36px); transition: opacity 0.85s cubic-bezier(0.16,1,0.3,1), transform 0.85s cubic-bezier(0.16,1,0.3,1); }
.reveal-left.visible { opacity: 1; transform: translateX(0); }
.reveal-right { opacity: 0; transform: translateX(36px); transition: opacity 0.85s cubic-bezier(0.16,1,0.3,1), transform 0.85s cubic-bezier(0.16,1,0.3,1); }
.reveal-right.visible { opacity: 1; transform: translateX(0); }
.reveal-scale { opacity: 0; transform: scale(0.94); transition: opacity 0.75s cubic-bezier(0.16,1,0.3,1), transform 0.75s cubic-bezier(0.16,1,0.3,1); }
.reveal-scale.visible { opacity: 1; transform: scale(1); }
.reveal-fade { opacity: 0; transition: opacity 1s ease; }
.reveal-fade.visible { opacity: 1; }

/* ── SECTION COMMONS ────────────────────────────────────── */
.section-label {
  display: inline-block;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 20px;
  padding-left: 28px;
  position: relative;
}
.section-label::before {
  content: '';
  position: absolute;
  left: 0; top: 50%;
  width: 18px; height: 1px;
  background: var(--gold);
}
.section-headline {
  font-size: clamp(38px, 4.2vw, 64px);
  font-family: 'Helvetica Neue',Helvetica,Arial,sans-serif;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.05;
  color: var(--ink);
}
.section-headline em {
  font-style: italic;
  font-weight: 600;
  color: var(--gold);
}
.section-sub {
  font-size: 16px;
  color: var(--ink-muted);
  line-height: 1.7;
  font-weight: 400;
}

/* ── BUTTONS ────────────────────────────────────────────── */
.btn-primary {
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  background: var(--gold-fill);
  color: #fff;
  padding: 17px 30px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border-radius: 2px;
  transition: transform 0.2s, box-shadow 0.2s;
  box-shadow: 0 8px 24px rgba(20,17,13,0.25);
}
.btn-primary::before {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(120deg, transparent 30%, rgba(255,255,255,0.45) 50%, transparent 70%);
  transform: translateX(-100%);
  transition: transform 0.7s ease;
}
.btn-primary:hover::before { transform: translateX(100%); }
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 36px rgba(20,17,13,0.4);
}
.btn-primary .arrow { transition: transform 0.25s ease; }
.btn-primary:hover .arrow { transform: translateX(4px); }

.btn-ghost {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-muted);
  padding: 17px 8px;
  border-bottom: 1px solid rgba(10,9,8,0.18);
  transition: color 0.2s, border-color 0.2s;
}
.btn-ghost:hover { color: var(--ink); border-color: var(--gold); }

/* Dark-surface ghost variant */
.btn-ghost--dark {
  color: rgba(245,243,240,0.55);
  border-bottom-color: rgba(245,243,240,0.18);
}
.btn-ghost--dark:hover { color: var(--parchment); border-color: var(--gold); }

/* ── LIVE DOT ───────────────────────────────────────────── */
.live-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: #38c172;
  box-shadow: 0 0 8px #38c172;
  animation: pulseDot 2s infinite;
}

/* ── SHARED NAV (inner pages — light surface) ───────────── */
/* index.html has its own dark nav defined inline.           */
/* About, FAQ, legal, privacy use this shared light nav.     */
.nav-light {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 56px;
  background: rgba(245,243,240,0.92);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--rule);
  transition: padding 0.25s ease;
}
.nav-light.compact { padding: 12px 56px; }

.logo-mark { display: flex; align-items: center; gap: 12px; }
.mark-img { width: 80px; height: 80px; object-fit: contain; display: block; }
.logo-text-block { display: flex; flex-direction: column; }
.logo-name {
  font-size: 16px; font-weight: 700;
  color: var(--ink);
  letter-spacing: 0.06em; line-height: 1;
  text-transform: uppercase;
}
.logo-title {
  font-size: 9px; font-weight: 500;
  color: var(--ink-muted);
  letter-spacing: 0.18em; text-transform: uppercase;
  margin-top: 5px;
}

.nav-links { display: flex; gap: 32px; align-items: center; list-style: none; }
.nav-links a {
  font-size: 12px; font-weight: 500;
  letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--ink-muted);
  transition: color 0.2s;
  position: relative;
}
.nav-links a:not(.nav-cta):hover { color: var(--ink); }
.nav-links a:not(.nav-cta)::after {
  content: ''; position: absolute; left: 0; bottom: -6px;
  width: 0; height: 1px; background: var(--gold);
  transition: width 0.3s ease;
}
.nav-links a:not(.nav-cta):hover::after { width: 100%; }

.nav-cta {
  color: #fff !important;
  background: var(--gold-fill);
  padding: 11px 22px !important;
  font-weight: 600 !important;
  border-radius: 2px;
  transition: all 0.25s ease;
}
.nav-cta:hover {
  background: var(--gold-2) !important;
  transform: translateY(-1px);
  box-shadow: 0 8px 24px var(--gold-glow);
}
.nav-cta::after { display: none !important; }

/* Hamburger */
.hamburger {
  display: none; flex-direction: column; gap: 5px;
  width: 36px; height: 36px; padding: 4px;
  align-items: center; justify-content: center;
}
.hamburger span {
  display: block; width: 22px; height: 1.5px;
  background: var(--ink);
  transition: transform 0.3s, opacity 0.3s;
}
.hamburger.open span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* Mobile menu (light) */
.mobile-menu {
  display: none; position: fixed; inset: 0;
  background: rgba(245,243,240,0.98);
  backdrop-filter: blur(24px); z-index: 99;
  flex-direction: column; align-items: center; justify-content: center; gap: 36px;
}
.mobile-menu.open { display: flex; }
.mobile-menu a {
  font-size: 28px; font-weight: 600;
  color: var(--ink); letter-spacing: -0.02em;
}
.mobile-menu .nav-cta { font-size: 13px !important; padding: 16px 32px !important; }

/* ── SHARED FOOTER ──────────────────────────────────────── */
footer {
  background: var(--parchment-2);
  border-top: 1px solid var(--rule);
  padding: 0 !important;
}
.footer-top {
  display: flex; justify-content: space-between; align-items: flex-start;
  gap: 60px; padding: 64px 56px 48px;
  border-bottom: 1px solid var(--rule);
  flex-wrap: wrap;
}
.footer-brand { display: flex; flex-direction: column; gap: 8px; }
.footer-name {
  font-weight: 700; font-size: 18px;
  letter-spacing: 0.06em; color: var(--ink);
  text-transform: uppercase;
}
.footer-tagline {
  font-size: 11px; font-weight: 400;
  color: var(--ink-muted); letter-spacing: 0.14em;
  text-transform: uppercase;
}
.footer-links { display: flex; gap: 60px; flex-wrap: wrap; }
.footer-col { display: flex; flex-direction: column; gap: 10px; }
.footer-col-label {
  font-size: 10px; font-weight: 700;
  letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--ink-muted); margin-bottom: 4px;
}
.footer-col a {
  font-size: 13px; color: var(--ink-2);
  font-weight: 300; transition: color 0.2s;
}
.footer-col a:hover { color: var(--ink); }
.footer-bottom {
  display: flex; justify-content: space-between; align-items: center;
  padding: 20px 56px; flex-wrap: wrap; gap: 12px;
}
.footer-bottom p { font-size: 12px; color: var(--ink-muted); font-weight: 300; }
.footer-legal-links { display: flex; gap: 24px; }
.footer-legal-links a {
  font-size: 12px; color: var(--ink-muted);
  font-weight: 300; transition: color 0.2s;
}
.footer-legal-links a:hover { color: var(--ink); }

/* ── DIAGONAL WEDGE (injected by shared.js) ────────────── */
.diagonal-wedge {
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 72px;
  pointer-events: none;
  z-index: 3;
}

/* ── GRAIN TEXTURE OVERLAY ──────────────────────────────── */
/* Injected via shared.js into dark sections (.hero, .live-ops, etc.) */
.grain-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 9;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='256' height='256'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.82' numOctaves='4' stitchTiles='stitch'/%3E%3C%2Ffilter%3E%3Crect width='256' height='256' filter='url(%23n)'/%3E%3C%2Fsvg%3E");
  background-size: 256px 256px;
  background-repeat: repeat;
  opacity: 0.038;
  mix-blend-mode: overlay;
  will-change: transform; /* GPU layer — no repaints */
}

/* ── SPLIT-TEXT WORD ANIMATION ──────────────────────────── */
.section-headline .word {
  display: inline-block;
  opacity: 0;
  transform: translateY(18px);
  transition:
    opacity  0.55s ease calc(var(--wi, 0) * 0.075s),
    transform 0.55s ease calc(var(--wi, 0) * 0.075s);
}
.section-headline.words-visible .word {
  opacity: 1;
  transform: translateY(0);
}

/* ── PAGE TRANSITIONS ───────────────────────────────────── */
body {
  opacity: 0;
  transition: opacity 0.25s ease;
}
body.page-ready {
  opacity: 1;
}

/* ── RESPONSIVE ─────────────────────────────────────────── */
@media (max-width: 900px) {
  .nav-light { padding: 14px 24px; }
  .nav-light.compact { padding: 10px 24px; }
  .nav-links { display: none; }
  .hamburger { display: flex; }
  .footer-top { padding: 48px 24px 36px; flex-direction: column; gap: 40px; }
  .footer-links { gap: 36px; }
  .footer-bottom { padding: 16px 24px; flex-direction: column; text-align: center; }
}
