/* ===========================================================
   AZEX AUDIT — Shared Design System
   =========================================================== */

@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;500;700&family=Inter:wght@400;500;600;700&family=Caveat:wght@600;700&display=swap');

:root {
  --bottle: #0B3D2C;
  --bottle-deep: #082A1F;
  --bottle-mid: #145C42;
  --bottle-light: #1F7A57;
  --sage: #E3F0EA;
  --sage-deep: #CFE6DA;
  --navy: #1B2A4A;
  --navy-tint: #E7E9F2;
  --gold: #C98A1F;
  --gold-light: #E0A94A;
  --cream: #F6FAF8;
  --ink: #12241D;
  --muted: #5B6B63;
  --muted-on-dark: #AFC9BC;
  --white: #FFFFFF;
  --shadow: 0 10px 30px rgba(11, 61, 44, 0.10);
  --shadow-lg: 0 20px 50px rgba(11, 61, 44, 0.16);
  --radius: 16px;
  --radius-sm: 10px;
  --max-width: 1180px;
  --font-display: 'Space Grotesk', sans-serif;
  --font-body: 'Inter', sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--cream);
  line-height: 1.6;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }

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

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

.eyebrow {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--bottle-mid);
}
.eyebrow.on-dark { color: var(--bottle-light); }

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 15px;
  padding: 13px 24px;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
  white-space: nowrap;
}
.btn img { width: 16px; height: 16px; }
.btn:hover { transform: translateY(-2px); }

.btn-primary { background: var(--gold); color: var(--bottle-deep); box-shadow: var(--shadow); }
.btn-primary:hover { background: var(--gold-light); box-shadow: var(--shadow-lg); }

.btn-secondary { background: var(--white); color: var(--bottle); border: 1.5px solid var(--sage-deep); }
.btn-secondary:hover { border-color: var(--bottle-mid); }

.btn-ghost-dark { background: rgba(255,255,255,0.08); color: var(--white); border: 1.5px solid rgba(255,255,255,0.25); }
.btn-ghost-dark:hover { background: rgba(255,255,255,0.16); }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(246, 250, 248, 0.88);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(11,61,44,0.08);
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 76px;
}
.brand { display: flex; align-items: center; gap: 12px; }
.brand-badge {
  width: 40px; height: 40px; border-radius: 50%;
  background: var(--white);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(11,61,44,0.15);
}
.brand-badge img { width: 26px; height: 26px; object-fit: contain; }
.brand-name { font-family: var(--font-display); font-weight: 700; font-size: 19px; color: var(--bottle); }

.main-nav { display: flex; align-items: center; gap: 36px; }
.main-nav ul { display: flex; gap: 32px; }
.main-nav a {
  font-weight: 600; font-size: 15px; color: var(--ink);
  position: relative; padding: 4px 0;
}
.main-nav a::after {
  content: ''; position: absolute; left: 0; bottom: -2px;
  width: 0; height: 2px; background: var(--gold);
  transition: width 0.2s ease;
}
.main-nav a:hover::after, .main-nav a.active::after { width: 100%; }
.main-nav a.active { color: var(--bottle); }

.nav-actions { display: flex; align-items: center; gap: 14px; }
.nav-login-link {
  font-weight: 600; font-size: 15px; color: var(--bottle);
  padding: 8px 4px;
}
.nav-login-link:hover { color: var(--bottle-mid); }
@media (max-width: 900px) { .nav-login-link { display: none; } }
.nav-toggle { display: none; background: none; border: none; cursor: pointer; padding: 6px; }
.nav-toggle img { width: 26px; height: 26px; }

@media (max-width: 900px) {
  .main-nav ul { display: none; }
  .nav-toggle { display: block; }
  .nav-actions .btn-secondary { display: none; }
  .float-icon { display: none; }
}

/* Mobile menu drawer */
.mobile-menu {
  position: fixed; inset: 0; z-index: 200;
  background: var(--bottle);
  display: flex; flex-direction: column;
  padding: 28px; transform: translateX(100%);
  transition: transform 0.3s ease;
}
.mobile-menu.open { transform: translateX(0); }
.mobile-menu-top { display: flex; justify-content: flex-end; }
.mobile-menu-top button { background: none; border: none; cursor: pointer; }
.mobile-menu-top img { width: 28px; height: 28px; }
.mobile-menu ul { display: flex; flex-direction: column; gap: 26px; margin-top: 50px; }
.mobile-menu a { font-family: var(--font-display); font-size: 28px; color: var(--white); font-weight: 700; }
.mobile-menu .btn { margin-top: 40px; align-self: flex-start; }

/* ---------- Sections ---------- */
section { padding: 96px 0; position: relative; }
.section-dark { background: var(--bottle); color: var(--white); overflow: hidden; }
.section-tight { padding: 64px 0; }
.section-head { max-width: 640px; margin-bottom: 56px; }
.section-head h2 { font-size: 38px; margin-top: 12px; color: var(--ink); }
.section-dark .section-head h2 { color: var(--white); }
.section-head p { font-size: 17px; color: var(--muted); margin-top: 14px; }
.section-dark .section-head p { color: var(--muted-on-dark); }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }

/* soft decorative motif — signature element carried from the deck */
.motif {
  position: absolute; border-radius: 50%; pointer-events: none;
}
.motif-tr { top: -180px; right: -160px; width: 480px; height: 480px; }
.motif-bl { bottom: -200px; left: -180px; width: 520px; height: 520px; }

/* ---------- Cards ---------- */
.card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 32px;
  box-shadow: var(--shadow);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }

.icon-badge {
  width: 52px; height: 52px; border-radius: 14px;
  background: var(--bottle);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 18px;
}
.icon-badge img { width: 26px; height: 26px; }
.icon-badge.round { border-radius: 50%; }
.icon-badge.navy { background: var(--navy); }
.icon-badge.gold { background: var(--gold); }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--bottle-deep);
  color: var(--muted-on-dark);
  padding: 64px 0 28px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 40px;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}
.footer-col h4 { font-family: var(--font-body); color: var(--white); font-size: 14px; margin-bottom: 16px; }
.footer-col ul { display: flex; flex-direction: column; gap: 10px; }
.footer-col a { font-size: 14px; color: var(--muted-on-dark); transition: color 0.15s; }
.footer-col a:hover { color: var(--white); }
.footer-bottom {
  display: flex; justify-content: space-between; align-items: center;
  padding-top: 24px; font-size: 13px; flex-wrap: wrap; gap: 12px;
}
.footer-social { display: flex; gap: 14px; }
.footer-social img { width: 18px; height: 18px; opacity: 0.7; }
.footer-social a:hover img { opacity: 1; }

@media (max-width: 800px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

/* ---------- Utility ---------- */
.pill {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 16px; border-radius: 999px;
  background: var(--bottle-mid); color: var(--white);
  font-size: 13px; font-weight: 600;
}
.pill.light { background: var(--sage); color: var(--bottle); }

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }

@media (max-width: 900px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  section { padding: 64px 0; }
  .section-head h2 { font-size: 30px; }
}

/* ---------- Animations ---------- */
@keyframes float {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-18px) rotate(4deg); }
}
@keyframes floatSlow {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(14px) rotate(-3deg); }
}
@keyframes popIn {
  0% { opacity: 0; transform: scale(0.6) translateY(20px); }
  100% { opacity: 1; transform: scale(1) translateY(0); }
}
.fade-up {
  opacity: 0; transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.fade-up.in-view { opacity: 1; transform: translateY(0); }

.float-icon {
  position: absolute;
  animation: float 6s ease-in-out infinite;
  opacity: 0;
}
.float-icon.appear { animation: popIn 0.6s cubic-bezier(0.34,1.56,0.64,1) forwards, float 6s ease-in-out 0.6s infinite; }
.float-icon.slow { animation-duration: 8s; }
.float-icon.reverse { animation-name: floatSlow; }

.float-icon .chip {
  width: 64px; height: 64px; border-radius: 18px;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 12px 28px rgba(0,0,0,0.18);
  backdrop-filter: blur(6px);
}
.float-icon .chip img { width: 30px; height: 30px; }

/* ---------- Imagine Without AZEX toggle ---------- */
.imagine-wrap {
  position: relative;
  max-width: 920px;
  margin: 0 auto;
  padding: 100px 150px 60px;
}
.imagine-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  position: relative;
  z-index: 3;
}
.imagine-tile {
  background: var(--white);
  border-radius: 14px;
  box-shadow: var(--shadow);
  padding: 20px 12px;
  text-align: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease, opacity 0.3s ease;
}
.imagine-tile .icon-badge { margin: 0 auto 10px; width: 44px; height: 44px; }
.imagine-tile .icon-badge img { width: 22px; height: 22px; }
.imagine-tile span { font-size: 12.5px; font-weight: 600; color: var(--ink); display: block; line-height: 1.25; }

.imagine-wrap.chaos .imagine-tile {
  transform: rotate(var(--wob, -1deg));
  box-shadow: var(--shadow-lg);
}

.imagine-toggle-row {
  display: flex; align-items: center; justify-content: center; gap: 14px;
  margin-top: 44px; position: relative; z-index: 3;
}
.toggle-switch {
  position: relative; width: 56px; height: 30px; flex-shrink: 0;
}
.toggle-switch input { opacity: 0; width: 0; height: 0; }
.toggle-slider {
  position: absolute; inset: 0; cursor: pointer;
  background: var(--sage-deep); border-radius: 999px;
  transition: background 0.25s ease;
}
.toggle-slider::before {
  content: ''; position: absolute; width: 24px; height: 24px;
  left: 3px; top: 3px; background: var(--white); border-radius: 50%;
  transition: transform 0.25s ease; box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}
.toggle-switch input:checked + .toggle-slider { background: var(--gold); }
.toggle-switch input:checked + .toggle-slider::before { transform: translateX(26px); }
.imagine-toggle-label { font-weight: 700; font-size: 16px; font-family: var(--font-display); }

.imagine-caption {
  text-align: center; margin-top: 18px; font-size: 15px; color: var(--muted);
  min-height: 24px; position: relative; z-index: 3;
}

/* hand-drawn annotations */
.scribble {
  position: absolute;
  font-family: 'Caveat', cursive;
  font-weight: 700;
  color: var(--gold);
  font-size: 22px;
  line-height: 1.1;
  opacity: 0;
  transform: scale(0.8);
  transition: opacity 0.4s ease, transform 0.4s ease;
  pointer-events: none;
  z-index: 4;
  white-space: nowrap;
}
.imagine-wrap.chaos .scribble { opacity: 1; transform: scale(1); }
.scribble svg { position: absolute; overflow: visible; }
.scribble path {
  fill: none; stroke: var(--gold); stroke-width: 2.5;
  stroke-linecap: round;
  stroke-dasharray: 140; stroke-dashoffset: 140;
  transition: stroke-dashoffset 0.6s ease 0.15s;
}
.imagine-wrap.chaos .scribble path { stroke-dashoffset: 0; }

@media (max-width: 900px) {
  .imagine-wrap { padding: 40px 16px; }
  .imagine-grid { grid-template-columns: repeat(2, 1fr); }
  .scribble { display: none; }
}
