/* ===== AOG DESIGN SYSTEM — PRESTIGE & INNOVATION ===== */
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,600;0,700;1,600&family=Inter:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500&display=swap');

/* ---- TOKENS ---- */
:root {
  --navy:          #002D62;
  --navy-deep:     #001A3A;
  --navy-mid:      #013070;
  --gold:          #CBA063;
  --gold-dim:      rgba(203,160,99,0.12);
  --gold-border:   rgba(203,160,99,0.28);
  --ai:            #5DBCEC;
  --ai-dim:        rgba(93,188,236,0.1);
  --ai-border:     rgba(93,188,236,0.25);
  --ivory:         #F5F4F0;
  --ivory-dark:    #EAE9E3;
  --carbon:        #0D0D0D;

  /* Aliases for backward-compat (inner pages reference these) */
  --bg-primary:    var(--navy);
  --bg-secondary:  var(--navy-deep);
  --bg-card:       rgba(255,255,255,0.045);
  --accent:        var(--gold);
  --accent-dim:    var(--gold-dim);
  --accent-border: var(--gold-border);
  --gold-c:        var(--gold);
  --text:          #E8DFCC;
  --text-dim:      rgba(232,223,204,0.38);
  --text-mid:      rgba(232,223,204,0.62);

  --max-w:         1140px;
  --radius:        14px;
  --radius-lg:     24px;
  --transition:    0.32s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ---- RESET ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }
body {
  background: var(--navy);
  color: var(--text);
  font-family: 'Inter', -apple-system, sans-serif;
  overflow-x: hidden;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ---- SCROLL PROGRESS ---- */
#scroll-progress {
  position: fixed; top: 0; left: 0; height: 2px; width: 0%;
  background: linear-gradient(90deg, var(--gold), #E8C88A, var(--gold));
  z-index: 9999; transition: width 0.08s linear;
}

/* ---- REVEAL ANIMATIONS ---- */
.rv { opacity: 0; transform: translateY(28px); transition: opacity 0.75s ease, transform 0.75s ease; }
.rv.shown { opacity: 1; transform: translateY(0); }
.rv.d1 { transition-delay: 0.1s; }
.rv.d2 { transition-delay: 0.2s; }
.rv.d3 { transition-delay: 0.3s; }
.rv.d4 { transition-delay: 0.4s; }
.rv.d5 { transition-delay: 0.5s; }
.rv.d6 { transition-delay: 0.65s; }

/* ---- LAYOUT ---- */
.wrap { max-width: var(--max-w); margin: 0 auto; width: 100%; padding: 0 5%; }
.section { padding: 128px 0; position: relative; overflow: hidden; }
.section-alt {
  background: var(--ivory);
  color: var(--carbon);
  --text: #1a1714;
  --text-mid: #7a7068;
  --text-dim: #b0a898;
  --bg-card: #ffffff;
  --accent: #CBA063;
  --accent-dim: rgba(203,160,99,0.1);
  --accent-border: rgba(203,160,99,0.25);
}
.section-deep { background: var(--navy-deep); }
.center { text-align: center; }
.center .subtitle { margin: 0 auto; }

/* ---- TYPOGRAPHY ---- */
.h1, .h2 {
  font-family: 'Playfair Display', Georgia, serif;
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.3px;
}
.h1 { font-size: clamp(38px, 5vw, 62px); line-height: 1.08; }
.h2 { font-size: clamp(28px, 3.5vw, 46px); margin: 14px 0 18px; }
.h3 {
  font-family: 'Playfair Display', Georgia, serif;
  font-weight: 600;
  font-size: clamp(19px, 2vw, 24px);
  line-height: 1.3;
}
.subtitle {
  font-size: clamp(15px, 1.2vw, 17px);
  color: var(--text-mid);
  line-height: 1.85;
  max-width: 560px;
  font-weight: 300;
}
.accent { color: var(--gold); }
.gold   { color: var(--gold); }
.ai-text { color: var(--ai); }

/* ---- GOLD HAIRLINE DIVIDER ---- */
.divider {
  width: 56px; height: 1px;
  background: linear-gradient(90deg, var(--gold), transparent);
  margin: 28px 0;
}
.center .divider { margin: 28px auto; }

/* ---- TAG / BADGE ---- */
.tag {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 16px;
  border: 1px solid var(--gold-border); border-radius: 100px;
  font-size: 10px; font-weight: 600; letter-spacing: 2px;
  text-transform: uppercase; color: var(--gold);
  background: var(--gold-dim);
  font-family: 'Inter', sans-serif;
}
.tag-ai {
  border-color: var(--ai-border); color: var(--ai);
  background: var(--ai-dim);
}

/* ---- BUTTONS ---- */
.btn {
  display: inline-flex; align-items: center; gap: 9px;
  font-family: 'Inter', sans-serif; font-weight: 600;
  font-size: 14px; padding: 15px 32px;
  border-radius: 10px; text-decoration: none;
  transition: all var(--transition); border: none; cursor: pointer;
  letter-spacing: 0.2px;
}
.btn-primary {
  background: var(--gold);
  color: var(--carbon);
  box-shadow: 0 4px 20px rgba(203,160,99,0.25);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 10px 36px rgba(203,160,99,0.38); }
.btn-outline {
  background: transparent; color: var(--text);
  border: 1px solid var(--gold-border);
}
.btn-outline:hover { background: var(--gold-dim); border-color: var(--gold); color: var(--gold); }
.btn-dark {
  background: var(--navy); color: var(--gold);
  border: 1px solid var(--gold-border);
}
.btn-dark:hover { background: var(--navy-deep); border-color: var(--gold); }
.btn-sm { padding: 10px 22px; font-size: 13px; }
.btn-lg { padding: 18px 40px; font-size: 15px; }

/* ---- CARDS (dark context default) ---- */
.card {
  background: var(--bg-card);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: var(--radius);
  padding: 36px 28px;
  transition: all var(--transition);
  backdrop-filter: blur(4px);
}
.card:hover {
  border-color: var(--gold-border);
  transform: translateY(-4px);
  box-shadow: 0 20px 60px rgba(0,0,0,0.25);
}

/* ---- NAV (shared by all pages) ---- */
.nav, #nav {
  position: fixed; top: 0; left: 0; right: 0; height: 74px;
  display: flex; align-items: center; z-index: 1000;
  transition: all var(--transition);
}
.nav.scrolled, #nav.scrolled {
  background: rgba(0,29,62,0.95);
  backdrop-filter: blur(20px) saturate(1.4);
  border-bottom: 1px solid var(--gold-border);
  box-shadow: 0 4px 32px rgba(0,0,0,0.3);
}
.nav-inner {
  max-width: var(--max-w); margin: 0 auto; width: 100%; padding: 0 5%;
  display: flex; align-items: center; justify-content: space-between;
}
.nav-logo {
  text-decoration: none;
  display: flex; align-items: center;
  flex-shrink: 0; line-height: 0;
}
.nav-logo img {
  height: 42px; width: auto; display: block;
  object-fit: contain;
}
.nav-links { display: flex; gap: 36px; list-style: none; }
.nav-links a {
  font-size: 13px; font-weight: 500; color: var(--text-mid);
  text-decoration: none; transition: color var(--transition);
  letter-spacing: 0.2px;
}
.nav-links a:hover, .nav-links a.active { color: var(--gold); }

/* ---- NAV DROPDOWN ---- */
.nav-dropdown { position: relative; }
.nav-dropdown > a {
  display: flex; align-items: center; gap: 5px;
  /* Extend click/hover zone downward so there's no gap to the submenu */
  padding-bottom: 28px; margin-bottom: -28px;
}
.nav-dropdown > a::after {
  content: '';
  width: 6px; height: 6px; flex-shrink: 0;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg) translateY(-2px);
  transition: transform 0.2s ease;
}
.nav-dropdown:hover > a::after,
.nav-dropdown:focus-within > a::after {
  transform: rotate(-135deg) translateY(2px);
}
.nav-submenu {
  position: absolute; top: 100%; left: 50%;
  transform: translateX(-50%) translateY(4px);
  background: rgba(0,26,58,0.98);
  backdrop-filter: blur(24px) saturate(1.5);
  border: 1px solid var(--gold-border);
  border-radius: 12px; padding: 8px 0;
  min-width: 230px; list-style: none;
  opacity: 0; visibility: hidden; pointer-events: none;
  transition: opacity 0.18s ease, transform 0.18s ease, visibility 0s linear 0.18s;
  box-shadow: 0 24px 64px rgba(0,0,0,0.45);
  z-index: 1100;
}
.nav-dropdown:hover .nav-submenu,
.nav-dropdown:focus-within .nav-submenu {
  opacity: 1; visibility: visible; pointer-events: auto;
  transform: translateX(-50%) translateY(0);
  transition: opacity 0.18s ease, transform 0.18s ease, visibility 0s linear 0s;
}
.nav-submenu li a {
  display: block; padding: 10px 20px;
  font-size: 13px; font-weight: 500; color: var(--text-mid);
  text-decoration: none; white-space: nowrap;
  transition: color 0.15s, background 0.15s;
}
.nav-submenu li a:hover { color: var(--gold); background: var(--gold-dim); }
.nav-submenu .submenu-divider {
  height: 1px; background: var(--gold-border);
  margin: 6px 16px; padding: 0; list-style: none;
}
.nav-right { display: flex; align-items: center; gap: 16px; }
.nav-cta {
  font-family: 'Inter', sans-serif; font-weight: 600;
  font-size: 12px; padding: 10px 22px;
  background: var(--gold); color: var(--carbon);
  border-radius: 8px; text-decoration: none;
  transition: all var(--transition); letter-spacing: 0.3px;
}
.nav-cta:hover { box-shadow: 0 4px 20px rgba(203,160,99,0.35); transform: translateY(-1px); }
#menu-btn {
  display: none; background: none;
  border: 1px solid var(--gold-border);
  border-radius: 8px; padding: 8px 10px; cursor: pointer;
  flex-direction: column; gap: 5px;
}
#menu-btn span { display: block; width: 20px; height: 1.5px; background: var(--text); border-radius: 2px; transition: all 0.25s; }
#menu-btn.open span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
#menu-btn.open span:nth-child(2) { opacity: 0; }
#menu-btn.open span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* ---- PAGE HEADER (inner pages) ---- */
.page-header {
  padding: 156px 0 80px; text-align: center; position: relative; overflow: hidden;
  background: linear-gradient(160deg, var(--navy-deep) 0%, var(--navy) 60%, var(--navy-mid) 100%);
}
.page-header::after {
  content: ''; position: absolute; bottom: 0; left: 10%; right: 10%;
  height: 1px; background: linear-gradient(90deg, transparent, var(--gold-border), transparent);
}
.page-header .h1 { margin: 16px 0 20px; }
.page-header .subtitle { margin: 0 auto; }

/* ---- FOOTER ---- */
footer {
  background: var(--navy-deep);
  border-top: 1px solid var(--gold-border);
  padding: 56px 0 32px;
}
.footer-inner {
  display: flex; justify-content: space-between; align-items: flex-start;
  gap: 48px; padding-bottom: 40px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.footer-brand .footer-logo {
  font-family: 'Playfair Display', serif; font-weight: 700;
  font-size: 22px; color: var(--text);
}
.footer-brand .footer-logo span { color: var(--gold); font-style: italic; }
.footer-brand p { font-size: 13px; color: var(--text-dim); margin-top: 8px; max-width: 240px; line-height: 1.7; }
.footer-cols { display: flex; gap: 64px; }
.footer-col h4 {
  font-family: 'Inter', sans-serif; font-size: 10px; font-weight: 700;
  letter-spacing: 2px; text-transform: uppercase; color: var(--gold);
  margin-bottom: 16px;
}
.footer-col a {
  display: block; font-size: 13px; color: var(--text-dim);
  text-decoration: none; margin-bottom: 10px;
  transition: color var(--transition);
}
.footer-col a:hover { color: var(--gold); }
.footer-copy {
  font-size: 11px; color: var(--text-dim);
  text-align: center; margin-top: 28px; opacity: 0.6;
}

/* ---- GLOW ORBS ---- */
.glow-orb {
  position: absolute; border-radius: 50%; pointer-events: none;
  filter: blur(80px); opacity: 0.07;
}

/* ---- GOLD ARCHITECTURAL LINES ---- */
.arch-line {
  width: 100%; height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold-border), transparent);
}

/* ---- TWO-COL SECTION GRID (service pages) ---- */
.two-col-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}
.two-col-grid.two-col-start { align-items: start; }

/* ---- BLOG FOOTER ---- */
footer.footer {
  background: var(--navy-deep);
  border-top: 1px solid var(--gold-border);
  padding: 56px 0 32px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 48px;
  padding-bottom: 40px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.footer-brand { line-height: 0; }
.footer-desc {
  font-size: 13px; color: var(--text-dim);
  margin-top: 12px; max-width: 260px; line-height: 1.7;
}
.footer-grid h5 {
  font-family: 'Inter', sans-serif; font-size: 10px; font-weight: 700;
  letter-spacing: 2px; text-transform: uppercase; color: var(--gold);
  margin: 0 0 16px;
}
.footer-grid ul { list-style: none; margin: 0; padding: 0; }
.footer-grid ul li { margin-bottom: 10px; }
.footer-grid a {
  font-size: 13px; color: var(--text-dim);
  text-decoration: none; transition: color var(--transition);
}
.footer-grid a:hover { color: var(--gold); }
.footer-bottom {
  font-size: 11px; color: var(--text-dim);
  text-align: center; margin-top: 28px; opacity: 0.6;
}
.footer-bottom p { margin: 0; }

/* ---- ARTICLE BODY: disable rv on wrapper (element too tall — observer threshold never met) ---- */
.article-body.rv {
  opacity: 1 !important;
  transform: none !important;
  transition: none !important;
}

/* ---- BLOG ARTICLE: TABLE RESPONSIVE WRAPPER ---- */
.table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 32px 0;
  border-radius: 8px;
}
.table-wrap .price-table { margin: 0; }

/* ---- RESPONSIVE — TABLET (≤900px) ---- */
@media (max-width: 900px) {
  /* Nav */
  .nav-links { display: none; }
  .nav-links.open {
    display: flex; flex-direction: column; position: absolute;
    top: 74px; left: 0; right: 0; padding: 24px 5%;
    background: rgba(0,26,58,0.98); backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--gold-border); gap: 18px; z-index: 999;
  }
  .nav-dropdown > a { padding-bottom: 0; margin-bottom: 0; }
  .nav-dropdown > a::after { display: none; }
  .nav-submenu {
    position: static !important; opacity: 1 !important; visibility: visible !important;
    pointer-events: auto !important; transform: none !important;
    background: transparent; border: none; box-shadow: none;
    padding: 4px 0 0 16px; min-width: unset; border-radius: 0;
    transition: none !important;
  }
  .nav-submenu li a { padding: 6px 0; font-size: 12px; }
  .nav-submenu .submenu-divider { display: none; }
  #menu-btn { display: flex; }

  /* Layout */
  .section { padding: 80px 0; }
  .page-header { padding: 110px 0 64px; }
  .two-col, .content-grid { grid-template-columns: 1fr; gap: 40px; }
  .cards-grid { grid-template-columns: 1fr 1fr; gap: 20px; }

  /* Two-col section grids */
  .two-col-grid, .two-col-grid.two-col-start { grid-template-columns: 1fr; gap: 40px; }

  /* Blog footer */
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }

  /* Footer */
  .footer-inner { flex-direction: column; }
  .footer-cols { gap: 40px; }
}

/* ---- RESPONSIVE — MOBILE (≤600px) ---- */
@media (max-width: 600px) {
  /* Wrap */
  .wrap { padding: 0 18px; }

  /* Sections */
  .section { padding: 56px 0; }
  .page-header { padding: 100px 0 52px; }

  /* Typography */
  .h1 { font-size: clamp(26px, 8vw, 38px); line-height: 1.12; }
  .h2 { font-size: clamp(22px, 7vw, 32px); }
  .h3 { font-size: clamp(17px, 5vw, 22px); }
  .subtitle { font-size: 14px; line-height: 1.75; }

  /* Buttons — full width only in button groups, not standalone */
  .btn-group .btn, .cta-buttons .btn { width: 100%; justify-content: center; }
  .btn { max-width: 100%; }

  /* Cards */
  .cards-grid { grid-template-columns: 1fr; gap: 14px; }
  .card { padding: 24px 18px; }

  /* Two-col gaps */
  .two-col-grid, .two-col-grid.two-col-start { gap: 32px; }

  /* Blog footer */
  .footer-grid { grid-template-columns: 1fr; gap: 24px; text-align: center; }
  .footer-desc { max-width: 100%; margin: 8px auto 0; text-align: center; }
  .footer-grid h5 { margin-top: 8px; }

  /* Main footer */
  .footer-inner { align-items: center; text-align: center; }
  .footer-cols { flex-direction: column; gap: 28px; align-items: center; }
  .footer-col { text-align: center; }
  .footer-brand p { margin: 8px auto 0; }

  /* Nav CTA */
  .nav-cta { font-size: 12px; padding: 8px 14px; }

  /* Images */
  img { max-width: 100%; height: auto; }

  /* Service page: inline stats inside performance card */
  .perf-mini-grid { grid-template-columns: 1fr 1fr !important; gap: 10px !important; }

  /* Blog article hero */
  .article-hero { padding: 110px 0 56px; }
  .article-body { padding: 0 2px; }
  .article-body p, .article-body li { font-size: 15px; }
  .article-body h2 { margin: 40px 0 16px; }
  .article-body h3 { margin: 28px 0 12px; }
  .article-meta { gap: 10px; font-size: 12px; flex-wrap: wrap; }
  .breadcrumb { font-size: 12px; flex-wrap: wrap; gap: 6px; }

  /* Blog components */
  .fact-box { padding: 18px 18px; }
  .inline-cta { padding: 24px 18px; }
  .pull-quote { padding: 20px 0; }
  .author-box { flex-direction: column; padding: 24px 18px; gap: 16px; }

  /* Stats grid — 2 cols on mobile */
  .stat-grid { grid-template-columns: repeat(2, 1fr) !important; gap: 12px; }

  /* Related articles — 1 col */
  .related-grid { grid-template-columns: 1fr !important; gap: 14px; }

  /* Price table — scrollable */
  .price-table { font-size: 13px; }
  .price-table th, .price-table td { padding: 10px 10px; }

  /* Stats bar (service page header) */
  .stats-bar { gap: 20px; justify-content: center !important; }
  .stat-val { font-size: clamp(20px, 5vw, 28px) !important; }

  /* Button groups centered */
  [style*="display:flex"][style*="justify-content:center"] { flex-direction: column; align-items: center; }
}

/* ---- RESPONSIVE — SMALL (≤380px) ---- */
@media (max-width: 380px) {
  .wrap { padding: 0 14px; }
  .section { padding: 44px 0; }
  .page-header { padding: 90px 0 40px; }
  .nav-cta { display: none; }
  .stat-grid { grid-template-columns: 1fr !important; }
  .h1 { font-size: clamp(24px, 8vw, 32px); }
}
