/* ==========================================================================
   Creatives Corner NG — Dark-Mode Design System
   Token-driven, mobile-first, SaaS-grade. Single theme (premium dark).
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Reset
   -------------------------------------------------------------------------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

* {
  margin: 0;
  padding: 0;
}

/* --------------------------------------------------------------------------
   2. Design tokens
   -------------------------------------------------------------------------- */
:root {
  /* Brand */
  --gold: #f4c542;
  --gold-soft: #ffd45e;
  --amber: #ff9f1c;
  --coral: #ff7a59;
  --brand-gradient: linear-gradient(135deg, var(--gold), var(--amber) 55%, var(--coral));
  --ink: #0a0f0d;               /* text on bright brand fills */

  /* Surfaces (near-black with a faint green-ink undertone) */
  --bg: #080b0a;
  --bg-1: #0c110f;              /* tinted / alternating sections */
  --bg-2: #101613;             /* raised bands */
  --surface: rgba(255, 255, 255, 0.038);
  --surface-2: rgba(255, 255, 255, 0.06);
  --surface-3: rgba(255, 255, 255, 0.09);
  --surface-solid: #111714;    /* opaque popovers/menus */
  --surface-inset: rgba(0, 0, 0, 0.28);

  /* Text */
  --text: #f4f8f6;
  --muted: #a7b3ad;
  --muted-2: #7a8781;

  /* Lines */
  --line: rgba(255, 255, 255, 0.10);
  --line-strong: rgba(255, 255, 255, 0.17);

  /* Semantic */
  --success: #37d399;
  --danger: #ff6b6b;
  --info: #5ac8fa;

  /* Accent aliases (semantic names used throughout) */
  --accent: var(--gold);
  --accent-2: var(--amber);
  --accent-3: var(--coral);

  /* Nav */
  --nav-shell: #0e0e0e;

  /* Focus ring */
  --ring: 0 0 0 3px rgba(244, 197, 66, 0.55);
  --ring-offset: 0 0 0 3px color-mix(in srgb, var(--bg) 78%, transparent);

  /* Radii */
  --r-xs: 8px;
  --r-sm: 10px;
  --r-md: 14px;
  --r-lg: 18px;
  --r-xl: 24px;
  --r-pill: 999px;

  /* Spacing (8pt) */
  --sp-1: 0.25rem;
  --sp-2: 0.5rem;
  --sp-3: 0.75rem;
  --sp-4: 1rem;
  --sp-5: 1.5rem;
  --sp-6: 2rem;
  --sp-7: 3rem;
  --sp-8: 4rem;
  --sp-9: 6rem;

  /* Fluid section rhythm */
  --section-pad: clamp(3.5rem, 8vw, 7rem);
  --section-pad-sm: clamp(2.5rem, 5vw, 4rem);

  /* Shadows (dark-tuned) */
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4), 0 4px 12px rgba(0, 0, 0, 0.25);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.38), 0 2px 6px rgba(0, 0, 0, 0.3);
  --shadow-lg: 0 24px 60px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 18px 46px rgba(244, 197, 66, 0.22);
  --shadow: var(--shadow-lg);

  /* Motion */
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
  --ease-out: cubic-bezier(0.19, 1, 0.22, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --dur-1: 140ms;
  --dur-2: 220ms;
  --dur-3: 340ms;

  /* Layout */
  --container: min(1200px, calc(100% - 2.5rem));

  color-scheme: dark;
}

/* --------------------------------------------------------------------------
   3. Base
   -------------------------------------------------------------------------- */
html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-feature-settings: "cv02", "cv03", "cv04", "cv11";
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

a {
  color: inherit;
  text-decoration: none;
}

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

ul {
  list-style: none;
}

:focus-visible {
  outline: none;
  box-shadow: var(--ring-offset), var(--ring);
  border-radius: var(--r-xs);
}

::selection {
  background: rgba(244, 197, 66, 0.28);
  color: #fff;
}

/* Custom scrollbar */
* {
  scrollbar-width: thin;
  scrollbar-color: var(--line-strong) transparent;
}

*::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

*::-webkit-scrollbar-thumb {
  background: var(--line-strong);
  border-radius: var(--r-pill);
  border: 2px solid transparent;
  background-clip: padding-box;
}

*::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.28);
  background-clip: padding-box;
}

/* --------------------------------------------------------------------------
   4. Typography
   -------------------------------------------------------------------------- */
h1,
h2,
h3,
h4 {
  line-height: 1.08;
  letter-spacing: -0.02em;
  font-weight: 800;
  text-wrap: balance;
}

h1 {
  max-width: 18ch;
  font-size: clamp(2.4rem, 6vw, 4.6rem);
  letter-spacing: -0.03em;
}

h2 {
  font-size: clamp(1.8rem, 4vw, 3.1rem);
}

h3 {
  font-size: 1.2rem;
  letter-spacing: -0.01em;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  width: fit-content;
  margin-bottom: 1rem;
  padding: 0.35rem 0.7rem;
  border-radius: var(--r-pill);
  border: 1px solid color-mix(in srgb, var(--gold) 32%, transparent);
  background: color-mix(in srgb, var(--gold) 10%, transparent);
  color: var(--gold-soft);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.eyebrow::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 10px var(--gold);
}

.hero-lede,
.page-hero p,
.section-copy {
  max-width: 62ch;
  margin-top: 1.25rem;
  color: var(--muted);
  font-size: clamp(1rem, 1.4vw, 1.18rem);
}

/* --------------------------------------------------------------------------
   5. Utilities
   -------------------------------------------------------------------------- */
.container {
  width: var(--container);
  margin-inline: auto;
}

.narrow {
  max-width: 820px;
}

.text-center {
  text-align: center;
}

.section-heading.center,
.text-center .eyebrow {
  margin-inline: auto;
}

.hidden {
  display: none !important;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Scroll-reveal */
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
  will-change: opacity, transform;
}

.reveal.in {
  opacity: 1;
  transform: none;
}

/* Skeleton shimmer */
.skeleton {
  position: relative;
  overflow: hidden;
  background: var(--surface-2);
  border-radius: var(--r-md);
}

.skeleton::after {
  content: "";
  position: absolute;
  inset: 0;
  transform: translateX(-100%);
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.07), transparent);
  animation: shimmer 1.4s infinite;
}

@keyframes shimmer {
  100% {
    transform: translateX(100%);
  }
}

/* Toasts */
.toast-stack {
  position: fixed;
  right: max(1rem, env(safe-area-inset-right));
  bottom: max(1rem, env(safe-area-inset-bottom));
  z-index: 80;
  display: grid;
  gap: 0.6rem;
  width: min(360px, calc(100vw - 2rem));
  pointer-events: none;
}

.toast {
  display: flex;
  align-items: flex-start;
  gap: 0.7rem;
  padding: 0.9rem 1rem;
  border-radius: var(--r-md);
  border: 1px solid var(--line-strong);
  background: var(--surface-solid);
  box-shadow: var(--shadow-lg);
  color: var(--text);
  font-size: 0.9rem;
  font-weight: 600;
  pointer-events: auto;
  transform: translateY(14px);
  opacity: 0;
  transition: transform var(--dur-3) var(--ease-out), opacity var(--dur-3) var(--ease);
}

.toast.show {
  transform: none;
  opacity: 1;
}

.toast::before {
  content: "";
  flex-shrink: 0;
  width: 6px;
  align-self: stretch;
  border-radius: var(--r-pill);
  background: var(--gold);
}

.toast.success::before {
  background: var(--success);
}

.toast.error::before {
  background: var(--danger);
}

.toast-body {
  display: grid;
  gap: 0.15rem;
}

.toast-title {
  font-weight: 800;
}

.toast-msg {
  color: var(--muted);
  font-weight: 500;
}

/* --------------------------------------------------------------------------
   6. Ambient background
   -------------------------------------------------------------------------- */
.site-bg {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(60rem 40rem at 12% -5%, rgba(255, 122, 89, 0.14), transparent 60%),
    radial-gradient(52rem 40rem at 92% 8%, rgba(244, 197, 66, 0.13), transparent 58%),
    radial-gradient(60rem 50rem at 50% 120%, rgba(255, 159, 28, 0.08), transparent 60%),
    var(--bg);
}

.site-bg::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
  background-size: 46px 46px;
  mask-image: radial-gradient(circle at 50% 0%, #000 0%, transparent 75%);
  -webkit-mask-image: radial-gradient(circle at 50% 0%, #000 0%, transparent 75%);
}

/* --------------------------------------------------------------------------
   7. Header / navigation
   -------------------------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid transparent;
  transition: background var(--dur-2) var(--ease), border-color var(--dur-2) var(--ease), backdrop-filter var(--dur-2);
}

.site-header.scrolled {
  border-bottom-color: var(--line);
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(16px) saturate(1.2);
  -webkit-backdrop-filter: blur(16px) saturate(1.2);
}

.header-shell {
  min-height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  min-width: 0;
  border-radius: var(--r-sm);
}

.brand-mark {
  width: 42px;
  height: 42px;
  border-radius: var(--r-sm);
  border: 1px solid var(--line);
  background: var(--gold);
  object-fit: cover;
}

.brand span {
  display: grid;
  line-height: 1.15;
}

.brand strong {
  font-size: 0.95rem;
  letter-spacing: -0.01em;
}

.brand small {
  color: var(--muted);
  font-size: 0.74rem;
}

.desktop-nav {
  display: inline-flex;
  padding: 3px;
  border-radius: var(--r-pill);
  background: var(--gold);
  box-shadow: 0 8px 26px rgba(244, 197, 66, 0.18);
}

.desktop-nav .nav-inner {
  display: flex;
  align-items: center;
  gap: 3px;
  padding: 5px;
  border-radius: var(--r-pill);
  background: var(--nav-shell);
  border: 1px solid rgba(255, 195, 0, 0.12);
}

.desktop-nav a {
  display: flex;
  align-items: center;
  padding: 9px 13px;
  border-radius: var(--r-pill);
  color: #f7f3f3;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  white-space: nowrap;
  overflow: hidden;
  transition: color var(--dur-2) var(--ease), background var(--dur-2) var(--ease);
}

.desktop-nav a i {
  font-size: 17px;
  flex-shrink: 0;
  transition: transform var(--dur-2) var(--ease);
}

.desktop-nav a:hover i {
  transform: scale(1.12);
}

.desktop-nav .lbl {
  display: inline-block;
  max-width: 0;
  overflow: hidden;
  opacity: 0;
  margin-left: 0;
  transition:
    max-width var(--dur-3) var(--ease),
    opacity var(--dur-2) var(--ease) 40ms,
    margin-left var(--dur-3) var(--ease);
}

.desktop-nav a.home .lbl {
  max-width: 60px;
  opacity: 1;
  margin-left: 7px;
}

.desktop-nav a:hover .lbl,
.desktop-nav a.active .lbl {
  max-width: 90px;
  opacity: 1;
  margin-left: 7px;
}

.desktop-nav a:hover {
  color: #0a0a0a;
  background: var(--gold);
}

.desktop-nav a.active {
  color: #fff;
  background: var(--amber);
}

.desktop-nav a.home:hover,
.desktop-nav a.home.active {
  background: var(--gold);
  color: #0a0a0a;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.7rem;
}

/* Menu toggle (mobile) */
.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
  padding: 0;
  font-size: 0;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
  transition: background var(--dur-2), border-color var(--dur-2);
}

.menu-toggle::before {
  content: "";
  width: 20px;
  height: 14px;
  background:
    linear-gradient(currentColor, currentColor) top / 100% 2px no-repeat,
    linear-gradient(currentColor, currentColor) center / 100% 2px no-repeat,
    linear-gradient(currentColor, currentColor) bottom / 100% 2px no-repeat;
  transition: background-size var(--dur-2) var(--ease), transform var(--dur-2) var(--ease);
}

.menu-toggle[aria-expanded="true"] {
  background: var(--surface-2);
  border-color: var(--line-strong);
}

.menu-toggle[aria-expanded="true"]::before {
  background:
    linear-gradient(currentColor, currentColor) center / 100% 2px no-repeat,
    linear-gradient(currentColor, currentColor) center / 100% 2px no-repeat,
    linear-gradient(currentColor, currentColor) center / 0 2px no-repeat;
  transform: rotate(45deg);
}

.menu-toggle[aria-expanded="true"]::after {
  content: "";
  position: absolute;
  width: 20px;
  height: 2px;
  background: currentColor;
  transform: rotate(-90deg);
}

/* Mobile slide-down menu */
.mobile-menu {
  display: grid;
  grid-template-rows: 0fr;
  width: var(--container);
  margin: 0 auto;
  overflow: hidden;
  transition: grid-template-rows var(--dur-3) var(--ease), margin var(--dur-3) var(--ease);
}

.mobile-menu > * {
  min-height: 0;
}

.mobile-menu .mobile-menu-inner {
  display: grid;
  gap: 0.3rem;
  padding: 0.6rem;
  margin-bottom: 0.75rem;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: var(--surface-solid);
  box-shadow: var(--shadow-lg);
  opacity: 0;
  transform: translateY(-6px);
  transition: opacity var(--dur-2) var(--ease), transform var(--dur-3) var(--ease);
}

.mobile-menu.open {
  grid-template-rows: 1fr;
}

.mobile-menu.open .mobile-menu-inner {
  opacity: 1;
  transform: none;
}

.mobile-menu a {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.95rem 1rem;
  border-radius: var(--r-sm);
  color: var(--muted);
  font-weight: 700;
  transition: background var(--dur-1), color var(--dur-1);
}

.mobile-menu a i {
  font-size: 18px;
}

.mobile-menu a.active,
.mobile-menu a:hover {
  color: var(--text);
  background: var(--surface-2);
}

.mobile-menu a.mobile-cta {
  margin-top: 0.3rem;
  justify-content: center;
  color: var(--ink);
  background: var(--brand-gradient);
  font-weight: 800;
}

/* --------------------------------------------------------------------------
   8. Buttons
   -------------------------------------------------------------------------- */
.icon-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 0.9rem;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
  font-weight: 700;
  transition: background var(--dur-2), border-color var(--dur-2), transform var(--dur-1);
}

.icon-button:hover {
  background: var(--surface-2);
  border-color: var(--line-strong);
}

.icon-button:active {
  transform: scale(0.97);
}

.header-cta,
.primary-button,
.price-cta {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  min-height: 46px;
  padding: 0.8rem 1.15rem;
  border: 1px solid transparent;
  border-radius: var(--r-sm);
  cursor: pointer;
  font-weight: 800;
  letter-spacing: 0.005em;
  color: var(--ink);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.4), transparent 34%),
    var(--brand-gradient);
  box-shadow: var(--shadow-glow), inset 0 1px 0 rgba(255, 255, 255, 0.42);
  transition: transform var(--dur-2) var(--ease), box-shadow var(--dur-2) var(--ease), filter var(--dur-2) var(--ease);
}

.header-cta::before,
.primary-button::before,
.price-cta::before {
  content: "";
  position: absolute;
  inset: -45% -70%;
  z-index: -1;
  background: linear-gradient(105deg, transparent 42%, rgba(255, 255, 255, 0.7) 50%, transparent 58%);
  transform: translateX(-58%) rotate(8deg);
  animation: ctaSweep 5s ease-in-out infinite;
}

.header-cta:hover,
.primary-button:hover,
.price-cta:hover {
  transform: translateY(-2px);
  filter: saturate(1.06);
  box-shadow:
    0 22px 48px rgba(244, 197, 66, 0.3),
    0 0 0 5px rgba(244, 197, 66, 0.09),
    inset 0 1px 0 rgba(255, 255, 255, 0.5);
}

.header-cta:active,
.primary-button:active,
.price-cta:active {
  transform: translateY(0) scale(0.985);
  box-shadow: 0 10px 24px rgba(244, 197, 66, 0.22), inset 0 2px 7px rgba(7, 16, 13, 0.2);
}

/* Ghost / secondary button */
.ghost-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  min-height: 46px;
  padding: 0.8rem 1.15rem;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-sm);
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
  font-weight: 700;
  transition: background var(--dur-2), border-color var(--dur-2), transform var(--dur-1);
}

.ghost-button:hover {
  background: var(--surface-2);
  border-color: color-mix(in srgb, var(--gold) 50%, var(--line-strong));
}

.ghost-button:active {
  transform: scale(0.98);
}

/* --------------------------------------------------------------------------
   9. Forms & fields
   -------------------------------------------------------------------------- */
.email-form input,
.newsletter-form input,
.chat-form input,
.search-input,
.form-group select {
  width: 100%;
  min-height: 50px;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  background: var(--surface-inset);
  color: var(--text);
  padding: 0.85rem 1rem;
  outline: none;
  transition: border-color var(--dur-2), box-shadow var(--dur-2), background var(--dur-2);
}

.email-form input::placeholder,
.newsletter-form input::placeholder,
.chat-form input::placeholder,
.search-input::placeholder {
  color: var(--muted-2);
}

.email-form input:focus,
.newsletter-form input:focus,
.chat-form input:focus,
.search-input:focus,
.form-group select:focus {
  border-color: color-mix(in srgb, var(--gold) 60%, transparent);
  box-shadow: 0 0 0 4px rgba(244, 197, 66, 0.14);
  background: var(--surface-inset);
}

.form-group select {
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
  background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%),
    linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position: calc(100% - 1.15rem) center, calc(100% - 0.85rem) center;
  background-size: 0.36rem 0.36rem, 0.36rem 0.36rem;
  background-repeat: no-repeat;
  padding-right: 2.5rem;
}

.form-group select option {
  background: var(--surface-solid);
  color: var(--text);
}

/* Validation state */
.field-invalid {
  border-color: color-mix(in srgb, var(--danger) 70%, transparent) !important;
  box-shadow: 0 0 0 4px rgba(255, 107, 107, 0.14) !important;
}

.email-form,
.glass-panel {
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: var(--surface);
  box-shadow: var(--shadow-md);
}

.email-form {
  width: min(680px, 100%);
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.6rem;
  margin: 1.8rem 0 1.25rem;
  padding: 0.55rem;
  backdrop-filter: blur(8px);
}

/* Range slider */
input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 6px;
  border-radius: var(--r-pill);
  background: var(--surface-3);
  outline: none;
  cursor: pointer;
}

input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--brand-gradient);
  border: 2px solid var(--bg);
  box-shadow: 0 2px 8px rgba(244, 197, 66, 0.4);
  transition: transform var(--dur-1);
}

input[type="range"]::-webkit-slider-thumb:hover {
  transform: scale(1.15);
}

input[type="range"]::-moz-range-thumb {
  width: 18px;
  height: 18px;
  border: 2px solid var(--bg);
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 2px 8px rgba(244, 197, 66, 0.4);
}

/* Checkbox accent */
input[type="checkbox"] {
  accent-color: var(--gold);
  width: 18px;
  height: 18px;
  cursor: pointer;
}

/* --------------------------------------------------------------------------
   10. Sections & shared cards
   -------------------------------------------------------------------------- */
section {
  position: relative;
}

.section-band,
.process-section,
.proof-section,
.section-packages,
.section-projects,
.section-calculator,
.section-faq,
.blog-search,
.featured-article,
.articles-section,
.newsletter-section,
.values-section,
.timeline-section,
.cta-section {
  padding-block: var(--section-pad);
  border-top: 1px solid var(--line);
}

.tinted {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.012), transparent 30%),
    var(--bg-1);
}

.section-heading {
  max-width: 760px;
  margin-bottom: 2.25rem;
}

.section-heading.center {
  margin-inline: auto;
  text-align: center;
}

/* Shared surface card */
.glass-panel,
.package-card,
.calculator-card,
.featured-card,
.article-card,
.statement-card,
.values-grid article,
.process-grid article,
.service-matrix article,
.stats-grid div,
.faq-item,
.cta-panel,
.timeline article {
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.02), transparent 40%),
    var(--surface);
}

/* Two-column layouts */
.hero-grid,
.split-grid,
.proof-grid,
.calculator-wrapper {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(2rem, 5vw, 5rem);
  align-items: center;
}

.proof-grid {
  align-items: start;
}

/* Generic grids */
.service-matrix,
.process-grid,
.values-grid,
.stats-grid,
.packages-grid,
.articles-grid,
.faq-grid,
.timeline {
  display: grid;
  gap: 1.1rem;
}

.trust-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.trust-row span {
  padding: 0.55rem 0.85rem;
  border: 1px solid var(--line);
  border-radius: var(--r-pill);
  color: var(--muted);
  background: var(--surface);
  font-size: 0.84rem;
  font-weight: 700;
}

/* --------------------------------------------------------------------------
   11. Hero
   -------------------------------------------------------------------------- */
.hero-section {
  display: grid;
  align-items: center;
  min-height: min(88vh, 900px);
  padding: clamp(3rem, 7vw, 6rem) 0 clamp(2rem, 4vw, 3rem);
  overflow: hidden;
}

.hero-copy .eyebrow,
.hero-copy h1,
.hero-copy .hero-lede,
.hero-copy .email-form,
.hero-copy .trust-row {
  opacity: 0;
  transform: translateY(26px);
  animation: heroReveal 0.85s var(--ease-out) forwards;
}

.hero-copy h1 {
  animation-delay: 0.12s;
}

.hero-copy .hero-lede {
  animation-delay: 0.26s;
}

.hero-copy .email-form {
  animation-delay: 0.4s;
}

.hero-copy .trust-row {
  animation-delay: 0.54s;
}

.hero-copy h1 {
  background: linear-gradient(180deg, #ffffff, #cfd8d4);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-product {
  position: relative;
  display: grid;
  min-height: 520px;
  align-items: center;
}

.motion-showcase {
  isolation: isolate;
  padding: clamp(1rem, 3vw, 1.5rem);
  opacity: 0;
  transform: translateX(30px) rotate(-1.5deg);
  animation: sceneArrive 1s var(--ease-out) 0.22s forwards;
  perspective: 1100px;
}

.motion-showcase::before,
.motion-showcase::after {
  content: "";
  position: absolute;
  z-index: -1;
  border-radius: 999px;
  filter: blur(8px);
}

.motion-showcase::before {
  width: 56%;
  aspect-ratio: 1;
  right: 0;
  top: 7%;
  background: radial-gradient(circle, rgba(255, 122, 89, 0.4), transparent 68%);
  animation: glowDrift 7s ease-in-out infinite alternate;
}

.motion-showcase::after {
  width: 44%;
  aspect-ratio: 1;
  left: 2%;
  bottom: 4%;
  background: radial-gradient(circle, rgba(244, 197, 66, 0.36), transparent 70%);
  animation: glowDrift 8s ease-in-out 0.6s infinite alternate-reverse;
}

.motion-stage {
  position: relative;
  display: grid;
  place-items: center;
  width: min(100%, 560px);
  min-height: 520px;
  margin-inline: auto;
}

.motion-video {
  position: absolute;
  object-fit: contain;
  pointer-events: none;
  filter: drop-shadow(0 24px 34px rgba(0, 0, 0, 0.4));
}

.logo-motion {
  position: relative;
  z-index: 2;
  width: min(78%, 430px);
  transform: translateY(-3%);
  filter: drop-shadow(0 28px 48px rgba(0, 0, 0, 0.42)) drop-shadow(0 0 38px rgba(244, 197, 66, 0.24));
  animation: logoHover 5.6s ease-in-out infinite;
}

.code-motion,
.python-motion {
  z-index: 3;
  width: min(31%, 170px);
  animation: orbDrift 7s ease-in-out infinite;
}

.code-motion {
  right: 1%;
  top: 12%;
}

.python-motion {
  left: 3%;
  bottom: 9%;
  animation-delay: 0.9s;
  animation-direction: reverse;
}

.motion-note {
  position: absolute;
  z-index: 2;
  width: max-content;
  max-width: min(220px, 48%);
  padding: 0.7rem 0.9rem;
  border: 1px solid rgba(244, 197, 66, 0.4);
  border-radius: var(--r-pill);
  background: color-mix(in srgb, var(--bg) 72%, transparent);
  color: var(--text);
  box-shadow: var(--shadow-md);
  backdrop-filter: blur(14px);
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  white-space: nowrap;
  animation: noteFloat 4.8s ease-in-out infinite;
}

.motion-note-top {
  top: 15%;
  left: 0;
}

.motion-note-bottom {
  right: 0;
  bottom: 16%;
  animation-delay: 0.7s;
}

.motion-gesture {
  position: absolute;
  inset: 8% 1% auto auto;
  z-index: 3;
  width: min(42%, 220px);
  aspect-ratio: 1;
  border-top: 2px solid rgba(244, 197, 66, 0.82);
  border-right: 2px solid rgba(255, 122, 89, 0.78);
  border-radius: 50%;
  opacity: 0;
  transform: rotate(-22deg) scale(0.76);
  animation: gestureArc 4.8s var(--ease-out) 1.1s infinite;
}

.motion-gesture span {
  position: absolute;
  right: 7%;
  top: 10%;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 28px rgba(244, 197, 66, 0.9);
}

/* --------------------------------------------------------------------------
   12. Home — service matrix / process / proof / cta
   -------------------------------------------------------------------------- */
.service-matrix {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.service-matrix article {
  min-height: 200px;
  padding: 1.5rem;
  transition: transform var(--dur-2) var(--ease), border-color var(--dur-2), background var(--dur-2);
}

.service-matrix article:hover,
.values-grid article:hover,
.process-grid article:hover {
  transform: translateY(-4px);
  border-color: color-mix(in srgb, var(--gold) 45%, var(--line));
  background: var(--surface-2);
}

.service-matrix span,
.statement-card span {
  display: inline-block;
  color: var(--gold);
  font-weight: 900;
  font-size: 0.95rem;
}

.service-matrix h3,
.process-grid h3,
.values-grid h3 {
  margin: 0.85rem 0 0.55rem;
}

.service-matrix p,
.process-grid p,
.values-grid p,
.statement-card p,
.timeline p,
.package-card p,
.article-excerpt,
.faq-answer {
  color: var(--muted);
}

.process-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.process-grid article,
.values-grid article,
.statement-card {
  padding: 1.5rem;
  transition: transform var(--dur-2) var(--ease), border-color var(--dur-2), background var(--dur-2);
}

.process-grid strong {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.4rem;
  height: 2.4rem;
  border-radius: var(--r-sm);
  background: color-mix(in srgb, var(--gold) 14%, transparent);
  border: 1px solid color-mix(in srgb, var(--gold) 30%, transparent);
  color: var(--gold);
  font-size: 0.9rem;
  font-weight: 900;
}

.stats-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.stats-grid div {
  padding: 1.6rem 1.4rem;
}

.stats-grid strong {
  display: block;
  font-size: clamp(2.2rem, 4vw, 3.4rem);
  line-height: 1;
  background: var(--brand-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-weight: 900;
  letter-spacing: -0.02em;
}

.stats-grid span {
  color: var(--muted);
  font-weight: 700;
}

.cta-panel {
  padding: clamp(2.25rem, 5vw, 4rem);
  border-radius: var(--r-xl);
  text-align: center;
  background:
    radial-gradient(120% 120% at 0% 0%, rgba(244, 197, 66, 0.16), transparent 55%),
    radial-gradient(120% 120% at 100% 100%, rgba(255, 122, 89, 0.14), transparent 55%),
    var(--surface);
}

.cta-panel h2 {
  max-width: 20ch;
  margin-inline: auto;
}

.cta-panel p {
  max-width: 60ch;
  margin: 1rem auto 1.75rem;
  color: var(--muted);
}

/* --------------------------------------------------------------------------
   13. Pricing
   -------------------------------------------------------------------------- */
.page-hero {
  padding: clamp(3.5rem, 8vw, 6.5rem) 0;
}

.page-hero.compact h1 {
  font-size: clamp(2.4rem, 5vw, 4.4rem);
}

.billing-section {
  padding: 2.25rem 0;
  border-top: 1px solid var(--line);
}

.billing-toggle {
  display: inline-flex;
  gap: 0.35rem;
  padding: 0.35rem;
  border: 1px solid var(--line);
  border-radius: var(--r-pill);
  background: var(--surface);
}

.toggle-btn {
  min-width: 128px;
  min-height: 44px;
  padding: 0 1.2rem;
  border: 0;
  border-radius: var(--r-pill);
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font-weight: 800;
  transition: color var(--dur-2), background var(--dur-2), box-shadow var(--dur-2);
}

.toggle-btn.active {
  color: var(--ink);
  background: var(--brand-gradient);
  box-shadow: 0 6px 18px rgba(244, 197, 66, 0.28);
}

.toggle-savings {
  margin-top: 0.9rem;
  color: var(--muted);
  font-size: 0.92rem;
}

.packages-grid {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 290px), 1fr));
  align-items: stretch;
}

.package-card {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 1.6rem;
  transition: transform var(--dur-2) var(--ease), border-color var(--dur-2), box-shadow var(--dur-2);
}

.package-card:hover {
  transform: translateY(-6px);
  border-color: color-mix(in srgb, var(--gold) 55%, var(--line));
  box-shadow: var(--shadow-lg);
}

.package-card.popular {
  border-color: color-mix(in srgb, var(--gold) 60%, var(--line));
  background:
    linear-gradient(180deg, rgba(244, 197, 66, 0.08), transparent 42%),
    var(--surface-2);
  box-shadow: 0 0 0 1px rgba(244, 197, 66, 0.25), var(--shadow-md);
}

.popular-badge {
  position: absolute;
  top: 1.1rem;
  right: 1.1rem;
  padding: 0.3rem 0.65rem;
  border-radius: var(--r-pill);
  background: var(--brand-gradient);
  color: var(--ink);
  font-size: 0.68rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  box-shadow: 0 4px 12px rgba(244, 197, 66, 0.35);
}

.price-header {
  padding-right: 4.5rem;
  margin-bottom: 1.2rem;
}

.price-name {
  font-size: 1.15rem;
}

.price-for {
  margin: 0.55rem 0 1rem;
  min-height: 3.2rem;
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 500;
}

.price-amount {
  background: var(--brand-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-size: clamp(1.9rem, 3vw, 2.5rem);
  font-weight: 900;
  letter-spacing: -0.02em;
}

.price-period {
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 600;
}

.price-save {
  margin-top: 0.4rem;
  color: var(--success);
  font-size: 0.84rem;
  font-weight: 700;
}

.features-list {
  display: grid;
  gap: 0.7rem;
  margin: 1.1rem 0 1.6rem;
}

.feature-row {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  color: var(--muted);
  font-size: 0.92rem;
}

.feature-check {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 1.2rem;
  height: 1.2rem;
  margin-top: 0.1rem;
  border-radius: 50%;
  background: color-mix(in srgb, var(--success) 18%, transparent);
  color: var(--success);
  font-size: 0.72rem;
  font-weight: 900;
}

.price-cta {
  width: 100%;
  margin-top: auto;
}

/* Projects table */
.projects-table-wrapper {
  position: relative;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  -webkit-overflow-scrolling: touch;
}

.projects-table {
  width: 100%;
  min-width: 720px;
  border-collapse: collapse;
  background: var(--surface);
}

.projects-table th,
.projects-table td {
  padding: 1rem 1.15rem;
  text-align: left;
  border-bottom: 1px solid var(--line);
}

.projects-table thead th {
  position: sticky;
  top: 0;
  color: var(--text);
  background: var(--surface-3);
  font-size: 0.82rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.projects-table tbody tr {
  transition: background var(--dur-1);
}

.projects-table tbody tr:hover {
  background: var(--surface-2);
}

.projects-table tbody tr:last-child td {
  border-bottom: 0;
}

.projects-table td {
  color: var(--muted);
}

.projects-table td:first-child {
  color: var(--text);
  font-weight: 700;
}

.projects-table td:not(:first-child) {
  color: var(--gold-soft);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

/* Calculator */
.calculator-card {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(260px, 0.85fr);
  gap: 1.25rem;
  padding: 1.25rem;
}

.calculator-form {
  display: grid;
  gap: 1.25rem;
  align-content: start;
}

.form-group {
  display: grid;
  gap: 0.6rem;
  color: var(--text);
  font-weight: 700;
}

.slider-group {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.slider-group b {
  min-width: 2.4rem;
  height: 2.4rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--r-sm);
  background: color-mix(in srgb, var(--gold) 14%, transparent);
  color: var(--gold);
  font-variant-numeric: tabular-nums;
}

.addons-grid {
  display: grid;
  gap: 0.55rem;
}

.addon-option {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.8rem 0.9rem;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  color: var(--muted);
  background: var(--surface-inset);
  cursor: pointer;
  font-weight: 500;
  transition: border-color var(--dur-1), background var(--dur-1), color var(--dur-1);
}

.addon-option:hover {
  border-color: var(--line-strong);
  color: var(--text);
}

.addon-option:has(input:checked) {
  border-color: color-mix(in srgb, var(--gold) 55%, transparent);
  background: color-mix(in srgb, var(--gold) 9%, var(--surface-inset));
  color: var(--text);
}

.addon-option .addon-price {
  margin-left: auto;
  color: var(--gold-soft);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.result-display {
  display: grid;
  align-content: center;
  gap: 0.6rem;
  padding: 1.5rem;
  border: 1px solid color-mix(in srgb, var(--gold) 30%, var(--line));
  border-radius: var(--r-md);
  background:
    radial-gradient(120% 120% at 100% 0%, rgba(255, 122, 89, 0.16), transparent 55%),
    linear-gradient(145deg, rgba(244, 197, 66, 0.12), rgba(255, 122, 89, 0.06));
}

.result-display span,
.result-display small {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
}

.result-display strong {
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}

.result-display .primary-button {
  margin-top: 0.6rem;
}

/* FAQ */
.faq-grid {
  max-width: 860px;
}

.faq-item {
  overflow: hidden;
}

.faq-question {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 64px;
  padding: 1.15rem 1.3rem;
  border: 0;
  background: transparent;
  color: var(--text);
  cursor: pointer;
  text-align: left;
  font-weight: 700;
  font-size: 1rem;
}

.faq-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 1.9rem;
  height: 1.9rem;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  color: var(--gold);
  font-size: 1.2rem;
  line-height: 1;
  transition: transform var(--dur-2) var(--ease), background var(--dur-2), border-color var(--dur-2);
}

.faq-item.open .faq-toggle {
  transform: rotate(45deg);
  background: var(--gold);
  color: var(--ink);
  border-color: transparent;
}

.faq-answer {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows var(--dur-3) var(--ease);
}

.faq-answer > div {
  min-height: 0;
  overflow: hidden;
}

.faq-answer-inner {
  padding: 0 1.3rem 1.3rem;
  color: var(--muted);
}

.faq-item.open .faq-answer {
  grid-template-rows: 1fr;
}

/* --------------------------------------------------------------------------
   14. About
   -------------------------------------------------------------------------- */
.statement-card {
  min-height: 280px;
  display: grid;
  align-content: start;
  gap: 0.5rem;
}

.values-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.timeline {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.timeline article {
  padding: 1.5rem;
  border-top: 3px solid transparent;
  border-image: var(--brand-gradient) 1;
  border-radius: 0 0 var(--r-lg) var(--r-lg);
  position: relative;
}

.timeline time {
  display: inline-block;
  margin-bottom: 0.3rem;
  color: var(--gold);
  font-weight: 900;
  font-size: 1.05rem;
}

.timeline h3 {
  margin: 0.4rem 0 0.5rem;
}

/* --------------------------------------------------------------------------
   15. Blog
   -------------------------------------------------------------------------- */
.blog-search {
  padding-bottom: 2rem;
}

.search-input {
  margin-bottom: 1.1rem;
}

.category-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.filter-btn {
  min-height: 40px;
  padding: 0 1rem;
  border: 1px solid var(--line);
  border-radius: var(--r-pill);
  background: var(--surface);
  color: var(--muted);
  cursor: pointer;
  font-weight: 700;
  font-size: 0.88rem;
  transition: color var(--dur-2), background var(--dur-2), border-color var(--dur-2);
}

.filter-btn:hover {
  color: var(--text);
  border-color: var(--line-strong);
}

.filter-btn.active {
  color: var(--ink);
  background: var(--brand-gradient);
  border-color: transparent;
}

.featured-card {
  padding: 1.5rem;
}

.featured-layout {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 1.75rem;
  align-items: center;
}

.featured-emoji,
.article-image {
  display: grid;
  place-items: center;
  border-radius: var(--r-md);
  background:
    linear-gradient(135deg, rgba(255, 122, 89, 0.2), rgba(244, 197, 66, 0.16)),
    var(--surface-2);
  font-size: 3rem;
}

.featured-emoji {
  min-height: 180px;
}

.article-image {
  min-height: 150px;
  font-size: 2.6rem;
}

.featured-meta,
.article-meta,
.article-footer,
.featured-footer {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  flex-wrap: wrap;
}

.featured-category,
.article-category {
  padding: 0.28rem 0.6rem;
  border-radius: var(--r-pill);
  background: color-mix(in srgb, var(--gold) 16%, transparent);
  border: 1px solid color-mix(in srgb, var(--gold) 30%, transparent);
  color: var(--gold-soft);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.03em;
}

.featured-date,
.article-date,
.article-author,
.featured-author {
  color: var(--muted-2);
  font-size: 0.84rem;
}

.featured-title,
.article-title {
  margin: 0.9rem 0 0.6rem;
}

.featured-excerpt {
  color: var(--muted);
}

.featured-footer {
  justify-content: space-between;
  margin-top: 1.1rem;
}

.articles-grid {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
}

.article-card {
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform var(--dur-2) var(--ease), border-color var(--dur-2), box-shadow var(--dur-2);
}

.article-card:hover {
  transform: translateY(-5px);
  border-color: color-mix(in srgb, var(--gold) 40%, var(--line));
  box-shadow: var(--shadow-lg);
}

.article-card .article-image {
  border-radius: 0;
}

.article-body {
  display: grid;
  gap: 0.4rem;
  padding: 1.15rem;
}

.article-title {
  margin: 0.5rem 0 0.35rem;
}

.article-excerpt {
  font-size: 0.9rem;
}

.article-footer {
  justify-content: space-between;
  padding-top: 1rem;
  margin-top: 0.7rem;
  border-top: 1px solid var(--line);
}

.article-read-btn {
  min-height: 38px;
  padding: 0 0.9rem;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-sm);
  background: var(--surface-2);
  color: var(--text);
  cursor: pointer;
  font-weight: 700;
  transition: background var(--dur-2), border-color var(--dur-2);
}

.article-read-btn:hover {
  background: var(--surface-3);
  border-color: color-mix(in srgb, var(--gold) 50%, var(--line-strong));
}

.newsletter-form {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.6rem;
  max-width: 620px;
  margin-inline: auto;
}

.no-results {
  grid-column: 1 / -1;
  display: grid;
  place-items: center;
  gap: 0.5rem;
  padding: 3rem 2rem;
  text-align: center;
  color: var(--muted);
  border: 1px dashed var(--line-strong);
  border-radius: var(--r-lg);
  background: var(--surface);
}

.no-results::before {
  content: "🔍";
  font-size: 2rem;
}

/* --------------------------------------------------------------------------
   16. Chat
   -------------------------------------------------------------------------- */
.chat-button {
  position: fixed;
  right: max(1.25rem, env(safe-area-inset-right));
  bottom: max(1.25rem, env(safe-area-inset-bottom));
  z-index: 45;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 54px;
  padding: 0 1.35rem;
  border: 0;
  border-radius: var(--r-pill);
  background: var(--brand-gradient);
  color: var(--ink);
  cursor: pointer;
  font-weight: 800;
  box-shadow: var(--shadow-glow), var(--shadow-md);
  transition: transform var(--dur-2) var(--ease), box-shadow var(--dur-2);
}

.chat-button::before {
  content: "💬";
  font-size: 1.1rem;
}

.chat-button:hover {
  transform: translateY(-3px);
  box-shadow: 0 20px 44px rgba(244, 197, 66, 0.34);
}

.chat-modal {
  position: fixed;
  right: max(1.25rem, env(safe-area-inset-right));
  bottom: 5.5rem;
  z-index: 44;
  width: min(390px, calc(100vw - 2.5rem));
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-lg);
  background: var(--surface-solid);
  box-shadow: var(--shadow-lg);
  opacity: 0;
  pointer-events: none;
  transform: translateY(16px) scale(0.98);
  transform-origin: bottom right;
  transition: opacity var(--dur-2) var(--ease), transform var(--dur-2) var(--ease-out);
}

.chat-modal.open {
  opacity: 1;
  pointer-events: auto;
  transform: none;
}

@media (max-width: 768px) {
  body.is-pricing-page .chat-button,
  body.is-pricing-page .chat-modal,
  body.is-career-page .chat-button,
  body.is-career-page .chat-modal {
    display: none !important;
  }
}

.chat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.15rem;
  border-bottom: 1px solid var(--line);
  font-weight: 800;
  background: var(--surface);
}

.chat-header::before {
  content: "";
  width: 9px;
  height: 9px;
  margin-right: auto;
  order: -1;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 10px var(--success);
}

.chat-header span {
  margin-right: auto;
  margin-left: 0.5rem;
}

.chat-close {
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font-size: 1.5rem;
  line-height: 1;
  transition: color var(--dur-1);
}

.chat-close:hover {
  color: var(--text);
}

.chat-content {
  max-height: 340px;
  overflow-y: auto;
  padding: 1.15rem;
  display: grid;
  gap: 0.6rem;
  align-content: start;
}

.chat-message {
  width: fit-content;
  max-width: 88%;
  padding: 0.75rem 0.95rem;
  border-radius: var(--r-md);
  border-bottom-left-radius: 4px;
  background: var(--surface-2);
  color: var(--text);
  font-size: 0.92rem;
  line-height: 1.5;
}

.chat-message.user {
  margin-left: auto;
  border-radius: var(--r-md);
  border-bottom-right-radius: 4px;
  background: var(--brand-gradient);
  color: var(--ink);
  font-weight: 600;
}

.chat-form {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.6rem;
  padding: 0.85rem;
  border-top: 1px solid var(--line);
  background: var(--surface);
}

.chat-form input {
  min-height: 46px;
}

.chat-form button {
  min-height: 46px;
  border: 0;
  border-radius: var(--r-sm);
  background: var(--brand-gradient);
  color: var(--ink);
  cursor: pointer;
  padding: 0 1.15rem;
  font-weight: 800;
  transition: filter var(--dur-1), transform var(--dur-1);
}

.chat-form button:hover {
  filter: saturate(1.08) brightness(1.03);
}

.chat-form button:active {
  transform: scale(0.97);
}

/* --------------------------------------------------------------------------
   17. Footer
   -------------------------------------------------------------------------- */
.site-footer {
  position: relative;
  border-top: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(244, 197, 66, 0.05), rgba(255, 255, 255, 0.02)), var(--bg-1);
  padding: clamp(2.5rem, 5vw, 3.6rem) 0 1.5rem;
}

.site-footer::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(244, 197, 66, 0.25), transparent);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.7fr repeat(3, minmax(0, 1fr));
  gap: 1.5rem 2rem;
  align-items: start;
}

.footer-column {
  display: grid;
  align-content: start;
  gap: 0.65rem;
}

.footer-grid h4 {
  margin-bottom: 0.25rem;
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold-soft);
}

.footer-brand {
  width: fit-content;
  padding: 0.8rem 0.95rem;
  border-radius: var(--r-md);
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.03);
}

.footer-brand .brand-mark {
  width: 44px;
  height: 44px;
}

.footer-link,
.footer-bottom {
  color: var(--muted);
  font-size: 0.93rem;
}

.footer-link {
  width: fit-content;
  padding: 0.12rem 0;
  transition: color var(--dur-1), transform var(--dur-1);
}

.footer-link:hover {
  color: var(--gold);
  transform: translateX(2px);
}

.footer-grid .brand small {
  color: var(--muted-2);
}

.footer-bottom {
  margin-top: 2.2rem;
  padding-top: 1.2rem;
  border-top: 1px solid var(--line);
  color: var(--muted-2);
  font-size: 0.85rem;
}

/* --------------------------------------------------------------------------
   18. Hero animated icon ticker
   -------------------------------------------------------------------------- */
.symbol {
  font-family: "Material Symbols Outlined";
  font-weight: normal;
  font-style: normal;
  line-height: 1;
  letter-spacing: normal;
  text-transform: none;
  display: inline-block;
  white-space: nowrap;
  direction: ltr;
  -webkit-font-smoothing: antialiased;
  font-feature-settings: "liga";
}

.hero-ticker-wrapper {
  position: relative;
  display: flex;
  overflow: hidden;
  width: 100%;
  padding: 2.5rem 0;
  margin-top: 3rem;
  mask: linear-gradient(90deg, transparent, #fff 12%, #fff 88%, transparent);
  -webkit-mask: linear-gradient(90deg, transparent, #fff 12%, #fff 88%, transparent);
}

.hero-ticker-wrapper:hover .icon-list {
  animation-play-state: paused;
}

.icon-list {
  display: flex;
  align-items: center;
  gap: 3rem;
  flex-shrink: 0;
  min-width: 100%;
  justify-content: space-around;
  animation: scrollTicker 46s linear infinite;
}

.grid-col {
  display: flex;
  align-items: center;
  justify-content: center;
  animation: waveMotion 4s ease-in-out infinite;
  will-change: transform;
}

.bouncer {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 58px;
  height: 58px;
  border-radius: var(--r-md);
  background: var(--surface);
  border: 1px solid var(--line);
  color: var(--gold);
  font-size: 26px;
  cursor: pointer;
  user-select: none;
  transition:
    transform 0.3s var(--ease-spring),
    background-color 0.3s ease,
    border-color 0.3s ease,
    color 0.3s ease,
    box-shadow 0.3s ease;
}

.bouncer:hover {
  transform: scale(1.2) rotate(4deg);
  background: var(--surface-3);
  border-color: var(--gold);
  color: var(--text);
  box-shadow: 0 12px 30px rgba(244, 197, 66, 0.25), 0 0 0 5px rgba(244, 197, 66, 0.08);
}

/* Staggered wave delays */
.grid-col:nth-child(1) { animation-delay: 0s; }
.grid-col:nth-child(2) { animation-delay: -0.1s; }
.grid-col:nth-child(3) { animation-delay: -0.2s; }
.grid-col:nth-child(4) { animation-delay: -0.3s; }
.grid-col:nth-child(5) { animation-delay: -0.4s; }
.grid-col:nth-child(6) { animation-delay: -0.5s; }
.grid-col:nth-child(7) { animation-delay: -0.6s; }
.grid-col:nth-child(8) { animation-delay: -0.7s; }
.grid-col:nth-child(9) { animation-delay: -0.8s; }
.grid-col:nth-child(10) { animation-delay: -0.9s; }
.grid-col:nth-child(11) { animation-delay: -1s; }
.grid-col:nth-child(12) { animation-delay: -1.1s; }
.grid-col:nth-child(13) { animation-delay: -1.2s; }
.grid-col:nth-child(14) { animation-delay: -1.3s; }
.grid-col:nth-child(15) { animation-delay: -1.4s; }
.grid-col:nth-child(16) { animation-delay: -1.5s; }
.grid-col:nth-child(17) { animation-delay: -1.6s; }
.grid-col:nth-child(18) { animation-delay: -1.7s; }
.grid-col:nth-child(19) { animation-delay: -1.8s; }
.grid-col:nth-child(20) { animation-delay: -1.9s; }
.grid-col:nth-child(n + 21) { animation-delay: -2s; }

/* --------------------------------------------------------------------------
   19. Keyframes
   -------------------------------------------------------------------------- */
@keyframes heroReveal {
  to { opacity: 1; transform: translateY(0); }
}

@keyframes ctaSweep {
  0%, 46% { transform: translateX(-58%) rotate(8deg); opacity: 0; }
  56% { opacity: 0.82; }
  72%, 100% { transform: translateX(58%) rotate(8deg); opacity: 0; }
}

@keyframes sceneArrive {
  to { opacity: 1; transform: translateX(0) rotate(0deg); }
}

@keyframes logoHover {
  0%, 100% { transform: translateY(-3%) scale(1); }
  50% { transform: translateY(-8%) scale(1.045); }
}

@keyframes orbDrift {
  0%, 100% { transform: translate3d(0, 0, 0) scale(1); }
  50% { transform: translate3d(-18px, 16px, 0) scale(1.08); }
}

@keyframes glowDrift {
  to { transform: translate3d(-18px, 18px, 0) scale(1.1); }
}

@keyframes noteFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

@keyframes gestureArc {
  0% { opacity: 0; transform: rotate(-36deg) scale(0.72); }
  18% { opacity: 1; }
  48% { opacity: 0.9; transform: rotate(18deg) scale(1); }
  76%, 100% { opacity: 0; transform: rotate(38deg) scale(1.08); }
}

@keyframes scrollTicker {
  0% { transform: translate3d(0, 0, 0); }
  100% { transform: translate3d(-100%, 0, 0); }
}

@keyframes waveMotion {
  0%, 100% { transform: translate3d(0, 14px, 0); }
  50% { transform: translate3d(0, -14px, 0); }
}

/* --------------------------------------------------------------------------
   20. Responsive
   -------------------------------------------------------------------------- */

/* Laptop / small desktop */
@media (max-width: 1080px) {
  .process-grid,
  .values-grid,
  .timeline {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Tablet */
@media (max-width: 900px) {
  .desktop-nav,
  .header-cta {
    display: none;
  }

  .menu-toggle {
    display: inline-flex;
    position: relative;
  }

  .split-grid,
  .proof-grid,
  .calculator-wrapper,
  .calculator-card,
  .featured-layout,
  .hero-grid {
    grid-template-columns: 1fr;
  }

  .hero-grid {
    gap: clamp(1.5rem, 4vw, 2.5rem);
  }

  .hero-copy {
    text-align: center;
    display: grid;
    justify-items: center;
  }

  .hero-section {
    min-height: auto;
    padding-top: 2.5rem;
  }

  .hero-product {
    min-height: 380px;
    order: -1;
  }

  .footer-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .footer-grid > div:first-child {
    grid-column: 1 / -1;
  }
}

/* Large phone */
@media (max-width: 680px) {
  :root {
    --container: calc(100% - 1.75rem);
  }

  .header-shell {
    min-height: 62px;
  }

  .brand small {
    display: none;
  }

  .brand-mark {
    width: 38px;
    height: 38px;
  }

  h1 {
    font-size: clamp(2rem, 8.5vw, 2.9rem);
  }

  .service-matrix,
  .stats-grid {
    grid-template-columns: 1fr;
  }

  .hero-product {
    min-height: 300px;
  }

  /* Drop the two small orbiting videos on phones to save decode cost */
  .code-motion,
  .python-motion {
    display: none;
  }

  .logo-motion {
    width: min(82%, 320px);
  }

  .motion-note {
    display: none;
  }

  .email-form {
    grid-template-columns: 1fr;
  }

  .newsletter-form {
    grid-template-columns: 1fr;
  }

  .price-header {
    padding-right: 0;
  }

  .popular-badge {
    position: static;
    width: fit-content;
    margin-bottom: 0.9rem;
  }

  .featured-footer {
    flex-direction: column;
    align-items: flex-start;
  }

  .bouncer {
    width: 48px;
    height: 48px;
    font-size: 21px;
  }

  .icon-list {
    gap: 2.2rem;
  }
}

/* Small phone */
@media (max-width: 400px) {
  .process-grid,
  .values-grid,
  .timeline {
    grid-template-columns: 1fr;
  }

  h1 {
    font-size: clamp(1.75rem, 8vw, 2.3rem);
  }
}

/* --------------------------------------------------------------------------
   21. Reduced motion
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }

  .reveal {
    opacity: 1 !important;
    transform: none !important;
  }

  .hero-copy .eyebrow,
  .hero-copy h1,
  .hero-copy .hero-lede,
  .hero-copy .email-form,
  .hero-copy .trust-row,
  .motion-showcase {
    opacity: 1 !important;
    transform: none !important;
  }

  .motion-gesture {
    display: none;
  }
}
