/* ==========================================================================
   Innovaria Tech — shared design system (light theme with dark anchors)
   White/soft-gray pages; dark navy header, heroes, stats band, CTA band,
   and footer. Restrained two tone gradient #06b6d4 > #7c3aed as the color
   thread, with deeper cyan/violet accents for text on white.
   ========================================================================== */

:root {
  /* Light surface tokens */
  --bg: #f5f7fc;
  --bg-2: #eef2f9;
  --panel: #ffffff;
  --panel-2: #ffffff;
  --line: #dfe6f2;
  --line-bright: rgba(8, 145, 178, 0.45);
  --heading: #0f1d3a;
  --ink: #2a3a5c;
  --muted: #5d6e90;
  --accent: #0891b2;

  /* Dark anchor tokens */
  --dark-bg: #060a13;
  --dark-bg-2: #0a1120;

  /* Brand gradient (restrained two tone: cyan to violet) */
  --g1: #06b6d4;
  --g2: #7c3aed;
  --g3: #7c3aed;
  --grad: linear-gradient(90deg, var(--g1), var(--g2));
  /* Deeper gradient for clipped text on white */
  --text-grad: linear-gradient(90deg, #0e7490, #6d28d9);

  /* Single accent family on light */
  --acc1: #0891b2;
  --acc2: #0891b2;
  --acc3: #0891b2;

  --cyan: #22d3ee;
  --violet: #a78bfa;
  --navy: #1d293d;
  --shadow: 0 14px 34px rgba(23, 42, 84, 0.10);
  --radius: 16px;
  --radius-sm: 10px;
  --font: "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  --mono: Consolas, "Cascadia Code", "Courier New", monospace;
}

/* Dark anchor zones re-map the semantic tokens */
.site-header, .hero, .page-hero, .stats-band, .cta-band, .site-footer, .photo-card, .terminal {
  --heading: #ffffff;
  --ink: #e8eefb;
  --muted: #9fb2d8;
  --line: rgba(148, 163, 184, 0.18);
  --line-bright: rgba(34, 211, 238, 0.5);
  --panel: rgba(255, 255, 255, 0.035);
  --panel-2: rgba(255, 255, 255, 0.065);
  --accent: #22d3ee;
  --text-grad: var(--grad);
  --acc1: #22d3ee;
  --acc2: #22d3ee;
  --acc3: #22d3ee;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.7;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  position: relative;
}

/* Fixed ambient background: faint grid + soft colored glows on white */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(800px 500px at 85% -5%, rgba(124, 58, 237, 0.05), transparent 60%),
    radial-gradient(700px 500px at -5% 40%, rgba(6, 182, 212, 0.06), transparent 60%),
    radial-gradient(600px 400px at 60% 110%, rgba(124, 58, 237, 0.04), transparent 60%),
    linear-gradient(rgba(15, 29, 58, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(15, 29, 58, 0.035) 1px, transparent 1px);
  background-size: auto, auto, auto, 44px 44px, 44px 44px;
  pointer-events: none;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--accent); }
a:hover { color: var(--g2); }

h1, h2, h3, h4 {
  line-height: 1.16;
  margin: 0 0 0.6em;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--heading);
}

h1 { font-size: clamp(2.2rem, 5.5vw, 3.6rem); }
h2 { font-size: clamp(1.6rem, 3.6vw, 2.4rem); }
h3 { font-size: clamp(1.15rem, 2.2vw, 1.35rem); }

p { margin: 0 0 1em; }

.grad-text {
  background: var(--text-grad);
  background-size: 200% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: grad-pan 5s ease-in-out infinite alternate;
}

@keyframes grad-pan {
  from { background-position: 0% 50%; }
  to { background-position: 100% 50%; }
}

@keyframes rise {
  from { opacity: 0; transform: translateY(22px); }
  to { opacity: 1; transform: none; }
}

.container {
  width: min(1140px, 100% - 2.5rem);
  margin-inline: auto;
}

.section { padding: clamp(3.4rem, 7vw, 6rem) 0; position: relative; }
.section-tight { padding: clamp(2.2rem, 5vw, 3.5rem) 0; }
.section-alt { background: linear-gradient(180deg, transparent, var(--bg-2) 15%, var(--bg-2) 85%, transparent); }

.kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1rem;
  font-family: var(--mono);
}
.kicker::before {
  content: "";
  width: 26px;
  height: 2px;
  background: var(--grad);
  border-radius: 2px;
}

.lede { font-size: clamp(1.05rem, 2vw, 1.22rem); color: var(--muted); max-width: 46em; }

.center { text-align: center; }
.center .lede { margin-inline: auto; }
.center .kicker { justify-content: center; }

/* --------------------------------------------------------------------------
   Buttons
   -------------------------------------------------------------------------- */

.btn {
  display: inline-block;
  padding: 0.9rem 1.7rem;
  border-radius: 999px;
  font-weight: 700;
  font-size: 1rem;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease, border-color 0.18s ease;
}
.btn:active { transform: translateY(1px); }

.btn-primary {
  background: var(--grad);
  color: #fff;
  box-shadow: 0 8px 24px rgba(109, 40, 217, 0.28);
}
.btn-primary:hover {
  filter: brightness(1.08);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 12px 32px rgba(109, 40, 217, 0.32), 0 4px 16px rgba(8, 145, 178, 0.18);
}

.btn-ghost {
  background: transparent;
  color: var(--accent);
  border-color: var(--accent);
}
.btn-ghost:hover { filter: brightness(1.1); transform: translateY(-2px); }

.btn-sm { padding: 0.55rem 1.2rem; font-size: 0.92rem; }

/* --------------------------------------------------------------------------
   Header + nav (dark anchor)
   -------------------------------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(6, 10, 19, 0.9);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.75rem 0;
}

.brand { display: flex; align-items: center; text-decoration: none; }
.brand img {
  width: 188px;
  height: 64px;
  object-fit: contain;
  filter: brightness(0) invert(1);
}

.nav-toggle {
  display: none;
  background: none;
  border: 0;
  padding: 0.4rem;
  cursor: pointer;
}
.nav-toggle span {
  display: block;
  width: 24px;
  height: 2.5px;
  margin: 5px 0;
  background: #fff;
  border-radius: 2px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.site-nav { display: flex; align-items: center; gap: 1.5rem; }
.site-nav a {
  text-decoration: none;
  font-weight: 600;
  font-size: 0.97rem;
  color: var(--ink);
}
.site-nav a:hover, .site-nav a[aria-current="page"] { color: var(--cyan); }
.site-nav .btn { margin-left: 0.4rem; }
.site-nav a.btn-primary { color: #fff; }

/* --------------------------------------------------------------------------
   Nav dropdowns
   -------------------------------------------------------------------------- */

.nav-item { position: relative; display: flex; align-items: center; gap: 0.15rem; }

.nav-caret {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  padding: 0;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  transition: transform 0.2s ease, color 0.2s ease;
}
.nav-caret svg { width: 12px; height: 12px; }
.nav-caret:hover { color: var(--cyan); }
.nav-item.open > .nav-caret { transform: rotate(180deg); color: var(--cyan); }
.nav-item:hover > .nav-caret { color: var(--cyan); }

.nav-menu {
  position: absolute;
  top: calc(100% + 0.55rem);
  left: -0.75rem;
  z-index: 60;
  display: grid;
  grid-template-columns: repeat(2, minmax(190px, 1fr));
  gap: 0.1rem 0.4rem;
  padding: 0.6rem;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(10, 17, 32, 0.98);
  backdrop-filter: blur(14px);
  box-shadow: 0 22px 50px rgba(0, 0, 0, 0.45);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition: opacity 0.18s ease, transform 0.18s ease, visibility 0.18s;
}
.nav-item:hover > .nav-menu,
.nav-item:focus-within > .nav-menu,
.nav-item.open > .nav-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.nav-menu a {
  display: block;
  padding: 0.5rem 0.7rem;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.92rem;
  color: #e8eefb;
  white-space: nowrap;
  transition: background 0.15s ease, color 0.15s ease;
}
.nav-menu a:hover, .nav-menu a:focus-visible { background: rgba(34, 211, 238, 0.12); color: var(--cyan); }
.nav-menu a[aria-current="page"] { color: var(--cyan); background: rgba(34, 211, 238, 0.08); }

/* First entry links to the hub page and spans both columns */
.nav-menu .nav-menu-hub {
  grid-column: 1 / -1;
  margin-bottom: 0.25rem;
  padding-bottom: 0.55rem;
  border-bottom: 1px solid var(--line);
  border-radius: 8px 8px 0 0;
  color: #fff;
}
.nav-menu .nav-menu-hub span { color: var(--muted); font-weight: 500; font-size: 0.85rem; }

/* A nested level, if a menu entry ever needs its own children */
.nav-menu .nav-item { display: block; }
.nav-menu .nav-submenu {
  position: absolute;
  top: -0.6rem;
  left: 100%;
  min-width: 210px;
  display: grid;
  grid-template-columns: 1fr;
  padding: 0.6rem;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(10, 17, 32, 0.99);
  box-shadow: 0 22px 50px rgba(0, 0, 0, 0.45);
  opacity: 0;
  visibility: hidden;
  transform: translateX(-6px);
  transition: opacity 0.18s ease, transform 0.18s ease, visibility 0.18s;
}
.nav-menu .nav-item:hover > .nav-submenu,
.nav-menu .nav-item:focus-within > .nav-submenu,
.nav-menu .nav-item.open > .nav-submenu {
  opacity: 1;
  visibility: visible;
  transform: translateX(0);
}

/* Tight desktop widths: single column so the panel stays on screen */
@media (max-width: 1080px) {
  .site-nav { gap: 1.05rem; }
  .nav-menu { grid-template-columns: 1fr; max-height: 70vh; overflow-y: auto; }
}

@media (max-width: 880px) {
  .nav-toggle { display: block; }
  .site-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    background: var(--dark-bg-2);
    border-bottom: 1px solid var(--line);
    box-shadow: 0 24px 40px rgba(0, 0, 0, 0.5);
    display: none;
    padding: 0.5rem 1.25rem 1.25rem;
  }
  .site-nav.open { display: flex; }
  .site-nav a { padding: 0.7rem 0; width: 100%; }
  .site-nav .btn { margin: 0.6rem 0 0; text-align: center; width: 100%; }
  .nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }

  /* Dropdowns become inline accordions inside the stacked panel */
  .nav-item { width: 100%; justify-content: space-between; }
  .nav-item > a { width: auto; flex: 1; }
  .nav-caret { width: 40px; height: 40px; flex-shrink: 0; }
  .nav-caret svg { width: 14px; height: 14px; }
  .nav-menu, .nav-menu .nav-submenu {
    position: static;
    display: none;
    grid-template-columns: 1fr;
    width: 100%;
    margin: 0 0 0.5rem;
    padding: 0.35rem 0 0.35rem 0.9rem;
    border: 0;
    border-left: 2px solid var(--line-bright);
    border-radius: 0;
    background: transparent;
    backdrop-filter: none;
    box-shadow: none;
    opacity: 1;
    visibility: visible;
    transform: none;
    max-height: none;
    overflow: visible;
  }
  /* Hover must not open anything on touch: only the explicit toggle does */
  .nav-item:hover > .nav-menu, .nav-item:focus-within > .nav-menu,
  .nav-menu .nav-item:hover > .nav-submenu, .nav-menu .nav-item:focus-within > .nav-submenu { display: none; }
  .nav-item.open > .nav-menu, .nav-menu .nav-item.open > .nav-submenu { display: grid; }
  .nav-menu a { padding: 0.55rem 0; font-size: 0.95rem; white-space: normal; }
  .nav-menu .nav-menu-hub { border-bottom-color: var(--line); }
}

/* --------------------------------------------------------------------------
   Hero (dark anchor)
   -------------------------------------------------------------------------- */

.hero {
  padding: clamp(3.6rem, 8vw, 6.2rem) 0 clamp(3rem, 6vw, 5rem);
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(900px 480px at 85% -10%, rgba(124, 58, 237, 0.14), transparent 60%),
    radial-gradient(700px 480px at -10% 110%, rgba(6, 182, 212, 0.10), transparent 62%),
    var(--dark-bg-2);
  color: var(--muted);
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(159, 176, 205, 0.14) 1px, transparent 1px);
  background-size: 26px 26px;
  mask-image: linear-gradient(120deg, transparent 40%, #000);
  pointer-events: none;
}
.hero .container { position: relative; z-index: 1; }

.hero-orb {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  animation: orb-float 14s ease-in-out infinite alternate;
  will-change: transform;
}
.hero-orb.o1 {
  width: 560px;
  height: 560px;
  background: radial-gradient(circle, rgba(124, 58, 237, 0.18), transparent 65%);
  top: -200px;
  right: -140px;
}
.hero-orb.o2 {
  width: 480px;
  height: 480px;
  background: radial-gradient(circle, rgba(6, 182, 212, 0.16), transparent 65%);
  bottom: -180px;
  left: -160px;
  animation-delay: -7s;
}

@keyframes orb-float {
  from { transform: translate3d(0, 0, 0) scale(1); }
  to { transform: translate3d(30px, 40px, 0) scale(1.12); }
}

.hero-grid {
  display: grid;
  gap: 3rem;
  align-items: center;
  grid-template-columns: 1fr;
  position: relative;
  z-index: 1;
}
@media (min-width: 960px) { .hero-grid { grid-template-columns: 1.15fr 0.85fr; } }

.hero h1 { max-width: 16em; }
.hero .lede { max-width: 36em; }

.hero-ctas { display: flex; flex-wrap: wrap; gap: 0.9rem; margin: 1.9rem 0 1.3rem; }

.hero-note { font-size: 0.92rem; color: var(--muted); }
.hero-note strong { color: var(--cyan); }

.rotator {
  display: inline-block;
  white-space: nowrap;
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  /* width is measured per word in main.js so the gap hugs the text */
  transition: opacity 0.25s ease, transform 0.25s ease, width 0.32s cubic-bezier(0.4, 0, 0.2, 1);
}
.rotator.swap { opacity: 0; transform: translateY(8px); }

/* Terminal / live automation feed (always dark) */
.terminal {
  background: rgba(8, 13, 26, 0.94);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(34, 211, 238, 0.06);
  overflow: hidden;
  font-family: var(--mono);
  font-size: 0.86rem;
}
.terminal-bar {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.7rem 1rem;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.03);
}
.terminal-bar span { width: 11px; height: 11px; border-radius: 50%; display: inline-block; }
.terminal-bar .d1 { background: #ff5f57; }
.terminal-bar .d2 { background: #febc2e; }
.terminal-bar .d3 { background: #28c840; }
.terminal-bar em {
  font-style: normal;
  color: var(--muted);
  font-size: 0.78rem;
  margin-left: 0.6rem;
}
.terminal-body { padding: 1.1rem 1.2rem 1.3rem; min-height: 250px; }
.terminal-body .tline { display: flex; gap: 0.7rem; margin-bottom: 0.55rem; opacity: 0; animation: tline-in 0.35s ease forwards; }
.terminal-body .t-time { color: #5b6f92; flex-shrink: 0; }
.terminal-body .t-ok { color: #34d399; }
.terminal-body .t-info { color: var(--cyan); }
.terminal-body .t-warn { color: #fbbf24; }
.terminal-body .t-text { color: #c7d4ea; }
.terminal-caret {
  display: inline-block;
  width: 8px;
  height: 15px;
  background: var(--cyan);
  animation: caret-blink 1s steps(1) infinite;
  vertical-align: -2px;
}

@keyframes tline-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@keyframes caret-blink { 50% { opacity: 0; } }

/* Tools marquee (light band) */
.marquee {
  overflow: hidden;
  border-block: 1px solid var(--line);
  padding: 0.9rem 0;
  background: #fff;
  position: relative;
}
.marquee-track {
  display: flex;
  gap: 3.5rem;
  width: max-content;
  animation: marquee 30s linear infinite;
}
.marquee:hover .marquee-track { animation-play-state: paused; }
.marquee span {
  font-family: var(--mono);
  font-size: 0.92rem;
  color: var(--muted);
  white-space: nowrap;
  letter-spacing: 0.06em;
}
.marquee span b { color: var(--accent); font-weight: 400; }

@keyframes marquee { to { transform: translateX(-50%); } }

/* --------------------------------------------------------------------------
   Cards + grids
   -------------------------------------------------------------------------- */

.grid { display: grid; gap: 1.4rem; }
.grid-2 { grid-template-columns: 1fr; }
.grid-3 { grid-template-columns: 1fr; }
.grid-4 { grid-template-columns: 1fr; }
@media (min-width: 700px) {
  .grid-2 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1000px) {
  .grid-3 { grid-template-columns: repeat(3, 1fr); }
  .grid-4 { grid-template-columns: repeat(4, 1fr); }
}

.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.8rem 1.6rem;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
  box-shadow: 0 3px 12px rgba(23, 42, 84, 0.05);
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}
.card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--card-accent, var(--grad));
  opacity: 0;
  transition: opacity 0.25s ease;
}
.card:hover {
  transform: translateY(-5px);
  border-color: rgba(8, 145, 178, 0.4);
  box-shadow: 0 20px 44px rgba(23, 42, 84, 0.14), 0 0 26px rgba(34, 211, 238, 0.10);
}
.card:hover::before { opacity: 1; }
.card p { color: var(--muted); font-size: 0.98rem; flex: 1; }
.card .card-link { font-weight: 700; text-decoration: none; font-size: 0.95rem; }

.card-icon {
  width: 48px;
  height: 48px;
  border-radius: 13px;
  background: linear-gradient(135deg, rgba(6, 182, 212, 0.10), rgba(232, 121, 249, 0.16));
  border: 1px solid var(--line);
  color: var(--acc1);
  display: grid;
  place-items: center;
  margin-bottom: 1.15rem;
}
.card-icon svg { width: 24px; height: 24px; }

/* Single accent family: quiet cyan icon tiles, gradient reserved for hover edge */
.card-icon { color: var(--acc1); background: linear-gradient(135deg, rgba(6, 182, 212, 0.14), rgba(6, 182, 212, 0.04)); }

/* 3D tilt cards — leaf silhouette, tilt toward the cursor, floating icon */
.card-3d {
  overflow: visible;
  transform-style: preserve-3d;
  transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg));
  transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.3, 1), box-shadow 0.35s ease, border-color 0.25s ease;
  border-radius: 2.9rem 0.8rem 2.9rem 0.8rem;
  padding: 2.2rem 1.9rem 2rem;
}
.card-3d:nth-child(even) { border-radius: 0.8rem 2.9rem 0.8rem 2.9rem; }
.card-3d::before { display: none; }
.card-3d:hover {
  transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)) translateY(-8px) scale(1.015);
  box-shadow: 0 30px 60px rgba(23, 42, 84, 0.20), 0 10px 24px rgba(139, 92, 246, 0.14);
  border-color: var(--card-accent, var(--g2));
}
.card-3d .card-icon { border-radius: 24px 8px 24px 8px; }
.card-3d:nth-child(even) .card-icon { border-radius: 8px 24px 8px 24px; }
.card-3d::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(460px circle at var(--mx, 50%) var(--my, 30%), rgba(124, 58, 237, 0.07), rgba(6, 182, 212, 0.04) 40%, transparent 65%);
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}
.card-3d:hover::after { opacity: 1; }
.card-3d .card-icon {
  box-shadow: 0 12px 24px rgba(23, 42, 84, 0.14);
  animation: icon-bob 5s ease-in-out infinite;
}
.card-3d:nth-child(2) .card-icon { animation-delay: -1.6s; }
.card-3d:nth-child(3) .card-icon { animation-delay: -3.2s; }
.card-3d h3 { transform: translateZ(22px); }
.card-3d p { transform: translateZ(12px); }

@keyframes icon-bob {
  0%, 100% { transform: translateZ(36px) translateY(0); }
  50% { transform: translateZ(36px) translateY(-5px); }
}

/* Photo cards (industries) — dark overlay on imagery */
.photo-card {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
  min-height: 300px;
  display: flex;
  align-items: flex-end;
  text-decoration: none;
  box-shadow: var(--shadow);
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}
.photo-card:hover { transform: translateY(-5px); border-color: var(--line-bright); box-shadow: 0 20px 44px rgba(23, 42, 84, 0.22); }
.photo-card img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.photo-card:hover img { transform: scale(1.06); }
.photo-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(6, 10, 19, 0.05) 30%, rgba(6, 10, 19, 0.92) 85%);
}
.photo-card-body { position: relative; z-index: 1; padding: 1.4rem 1.4rem 1.5rem; }
.photo-card h3 { margin-bottom: 0.3em; color: #fff; }
.photo-card p { color: #c7d4ea; font-size: 0.93rem; margin: 0 0 0.6rem; }
.photo-card .card-link { color: var(--cyan); font-weight: 700; font-size: 0.92rem; }

/* Image + text split */
.split {
  display: grid;
  gap: 2.5rem;
  align-items: center;
  grid-template-columns: 1fr;
}
@media (min-width: 900px) { .split { grid-template-columns: 1fr 1fr; } }

.frame {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: 0 24px 50px rgba(23, 42, 84, 0.18);
  position: relative;
  background: #fff;
}
.frame img { width: 100%; height: 100%; object-fit: cover; }
.frame::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(160deg, rgba(6, 182, 212, 0.06), transparent 45%, rgba(124, 58, 237, 0.06));
  pointer-events: none;
}

/* --------------------------------------------------------------------------
   Steps
   -------------------------------------------------------------------------- */

.steps { counter-reset: step; }
.step {
  position: relative;
  padding: 1.6rem 1.5rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: 0 3px 12px rgba(23, 42, 84, 0.05);
}
.step::before {
  counter-increment: step;
  content: counter(step, decimal-leading-zero);
  display: block;
  font-family: var(--mono);
  font-size: 1.9rem;
  font-weight: 700;
  background: var(--text-grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  margin-bottom: 0.5rem;
}
.step h3 { margin-bottom: 0.35em; }
.step p { color: var(--muted); font-size: 0.96rem; margin: 0; }

/* --------------------------------------------------------------------------
   Stats band (dark anchor)
   -------------------------------------------------------------------------- */

.stats-band {
  border-block: 1px solid rgba(148, 163, 184, 0.18);
  background:
    radial-gradient(600px 200px at 50% 0%, rgba(124, 58, 237, 0.12), transparent 70%),
    var(--dark-bg-2);
  color: var(--muted);
}
.stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2.2rem 1.5rem;
  text-align: center;
}
@media (min-width: 760px) { .stats { grid-template-columns: repeat(4, 1fr); } }

.stat-num {
  font-size: clamp(2rem, 4.5vw, 3rem);
  font-weight: 800;
  font-family: var(--mono);
  background: var(--text-grad);
  background-size: 200% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  letter-spacing: -0.02em;
  animation: grad-pan 5s ease-in-out infinite alternate;
}
.stat-label { font-size: 0.94rem; color: var(--muted); }

/* --------------------------------------------------------------------------
   Case study teaser + quotes
   -------------------------------------------------------------------------- */

.case-teaser {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.case-body { padding: clamp(1.6rem, 4vw, 2.4rem); }
.case-metrics { display: flex; flex-wrap: wrap; gap: 1.6rem 2.5rem; margin: 1.4rem 0 1.6rem; }
.case-metrics div strong {
  display: block;
  font-size: 1.8rem;
  font-family: var(--mono);
  background: var(--text-grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.case-metrics div span { font-size: 0.9rem; color: var(--muted); }

.quote {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.6rem;
  margin: 0;
  box-shadow: 0 3px 12px rgba(23, 42, 84, 0.05);
  transition: transform 0.25s ease, border-color 0.25s ease;
}
.quote:hover { transform: translateY(-4px); border-color: var(--line-bright); }
.quote p { font-size: 1rem; color: var(--ink); }
.quote footer { display: flex; align-items: center; gap: 0.8rem; font-size: 0.9rem; color: var(--muted); }
.quote footer strong { color: var(--heading); display: block; }
.avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--grad);
  color: #fff;
  font-weight: 700;
  display: grid;
  place-items: center;
  font-size: 0.9rem;
  flex-shrink: 0;
}

/* --------------------------------------------------------------------------
   FAQ
   -------------------------------------------------------------------------- */

.faq { max-width: 780px; margin-inline: auto; }
.faq details {
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--panel);
  margin-bottom: 0.8rem;
  padding: 0 1.2rem;
  box-shadow: 0 2px 8px rgba(23, 42, 84, 0.04);
  transition: border-color 0.2s ease;
}
.faq details[open] { border-color: var(--line-bright); }
.faq summary {
  cursor: pointer;
  font-weight: 700;
  color: var(--heading);
  padding: 1rem 2rem 1rem 0;
  list-style: none;
  position: relative;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  position: absolute;
  right: 0.2rem;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.4rem;
  color: var(--accent);
  transition: transform 0.2s ease;
}
.faq details[open] summary::after { content: "\2013"; }
.faq details p { color: var(--muted); padding-bottom: 1.1rem; margin: 0; }

/* --------------------------------------------------------------------------
   CTA band (dark anchor)
   -------------------------------------------------------------------------- */

.cta-band {
  text-align: center;
  padding: clamp(3.4rem, 8vw, 6rem) 0;
  position: relative;
  overflow: hidden;
  color: var(--muted);
  background:
    radial-gradient(700px 320px at 50% 115%, rgba(124, 58, 237, 0.10), transparent 65%),
    radial-gradient(500px 250px at 15% -10%, rgba(6, 182, 212, 0.10), transparent 60%),
    var(--dark-bg);
}
.cta-band h2 { max-width: 21em; margin-inline: auto; }
.cta-band .btn { margin-top: 1.4rem; }
.cta-band .cta-sub { font-size: 0.95rem; margin-top: 1.2rem; color: var(--muted); }

/* --------------------------------------------------------------------------
   Forms
   -------------------------------------------------------------------------- */

.form-grid { display: grid; gap: 1.1rem; }
.form-field label { display: block; font-weight: 700; font-size: 0.92rem; margin-bottom: 0.35rem; color: var(--heading); }
.form-field input,
.form-field select,
.form-field textarea {
  width: 100%;
  padding: 0.8rem 0.95rem;
  border: 1.5px solid var(--line);
  border-radius: var(--radius-sm);
  font: inherit;
  color: var(--ink);
  background: #fff;
}
.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(8, 145, 178, 0.15);
}
.form-field .field-error {
  display: none;
  color: #dc2626;
  font-size: 0.85rem;
  margin-top: 0.3rem;
}
.form-field.invalid input,
.form-field.invalid select,
.form-field.invalid textarea { border-color: #dc2626; }
.form-field.invalid .field-error { display: block; }
.form-status { font-weight: 700; margin-top: 1rem; }
.form-status.ok { color: #047857; }
.form-status.err { color: #dc2626; }

/* --------------------------------------------------------------------------
   Footer (dark anchor)
   -------------------------------------------------------------------------- */

.site-footer {
  background: #070b14;
  border-top: 1px solid rgba(148, 163, 184, 0.18);
  color: var(--muted);
  padding: 3.4rem 0 2rem;
  font-size: 0.95rem;
}
.footer-grid {
  display: grid;
  gap: 2.2rem;
  grid-template-columns: 1fr;
  margin-bottom: 2.5rem;
}
@media (min-width: 760px) { .footer-grid { grid-template-columns: 2fr 1fr 1fr 1.4fr; } }

.site-footer h3 {
  color: #fff;
  font-size: 0.92rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 0.9rem;
  font-family: var(--mono);
}
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 0.55rem; }
.site-footer a { color: var(--muted); text-decoration: none; }
.site-footer a:hover { color: var(--cyan); }
.site-footer a.btn-primary { color: #fff; }
.site-footer a.btn-primary:hover { color: #fff; }
.footer-brand img { width: 200px; filter: brightness(0) invert(1) opacity(0.92); margin-bottom: 1rem; }
.footer-cta { margin-top: 1rem; }
.footer-bottom {
  border-top: 1px solid rgba(148, 163, 184, 0.18);
  padding-top: 1.4rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem 1.5rem;
  justify-content: space-between;
  font-size: 0.85rem;
}

/* --------------------------------------------------------------------------
   Page hero (inner pages, dark anchor), breadcrumbs, prose
   -------------------------------------------------------------------------- */

.page-hero {
  padding: clamp(2.8rem, 6vw, 4.2rem) 0;
  border-bottom: 1px solid rgba(148, 163, 184, 0.18);
  background:
    radial-gradient(700px 300px at 80% -20%, rgba(124, 58, 237, 0.10), transparent 60%),
    var(--dark-bg-2);
  color: var(--muted);
  position: relative;
  overflow: hidden;
}
.page-hero::before {
  content: "";
  position: absolute;
  width: 540px;
  height: 540px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(124, 58, 237, 0.14), transparent 65%);
  top: -230px;
  right: -130px;
  animation: orb-float 12s ease-in-out infinite alternate;
  pointer-events: none;
}
.page-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(420px 420px circle at -5% 120%, rgba(6, 182, 212, 0.10), transparent 65%),
    radial-gradient(rgba(159, 176, 205, 0.13) 1px, transparent 1px);
  background-size: auto, 26px 26px;
  mask-image: linear-gradient(115deg, rgba(0,0,0,0.35) 30%, #000);
  pointer-events: none;
}
.page-hero .container { position: relative; z-index: 1; }
.page-hero .breadcrumbs { animation: rise 0.5s ease both; }
.page-hero .kicker { animation: rise 0.55s ease 0.08s both; }
.page-hero h1 { max-width: 18em; animation: rise 0.6s ease 0.16s both; }
.page-hero .lede, .page-hero .post-meta { animation: rise 0.6s ease 0.28s both; }

.breadcrumbs { font-size: 0.85rem; margin-bottom: 1.2rem; font-family: var(--mono); }
.breadcrumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 0.4rem; margin: 0; padding: 0; }
.breadcrumbs li + li::before { content: "/"; margin-right: 0.4rem; color: var(--muted); }
.breadcrumbs a { color: var(--muted); text-decoration: none; }
.breadcrumbs a:hover { color: var(--accent); }
.breadcrumbs [aria-current="page"] { color: var(--heading); }

.prose { max-width: 730px; }
.prose h2 { margin-top: 2.2em; }
.prose h3 { margin-top: 1.8em; }
.prose p, .prose li { color: var(--ink); }
.prose ul, .prose ol { padding-left: 1.3rem; }
.prose li { margin-bottom: 0.45rem; }
.prose blockquote {
  border-left: 3px solid var(--g2);
  margin: 1.5rem 0;
  padding: 0.4rem 0 0.4rem 1.2rem;
  color: var(--muted);
}
.prose table { border-collapse: collapse; width: 100%; font-size: 0.95rem; display: block; overflow-x: auto; }
@media (min-width: 700px) { .prose table { display: table; overflow-x: visible; } }
.prose th, .prose td { border: 1px solid var(--line); padding: 0.6rem 0.8rem; text-align: left; }
.prose th { background: var(--bg-2); color: var(--heading); }

.post-meta { font-size: 0.88rem; color: var(--muted); margin-bottom: 2rem; font-family: var(--mono); }

/* --------------------------------------------------------------------------
   Pricing plans (product pages)
   -------------------------------------------------------------------------- */

.plan { text-align: center; }
.plan .tier {
  font-family: var(--mono);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
}
.plan .price { font-size: 2.6rem; font-weight: 800; color: var(--heading); margin: 0.3rem 0 0; letter-spacing: -0.02em; }
.plan .price span { font-size: 1rem; color: var(--muted); font-weight: 500; }
.plan ul { list-style: none; padding: 0; margin: 1.4rem 0 1.6rem; text-align: left; }
.plan li {
  padding: 0.5rem 0 0.5rem 1.7rem;
  position: relative;
  color: var(--muted);
  font-size: 0.95rem;
  border-bottom: 1px solid var(--line);
}
.plan li:last-child { border-bottom: 0; }
.plan li::before { content: "\2713"; position: absolute; left: 0; color: var(--accent); font-weight: 700; }
.plan .btn { width: 100%; }
.plan.popular {
  border-color: rgba(124, 58, 237, 0.32);
  box-shadow: 0 18px 44px rgba(124, 58, 237, 0.10);
}
.plan .badge {
  position: absolute;
  top: -13px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--grad);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  padding: 0.3rem 0.95rem;
  border-radius: 999px;
  white-space: nowrap;
}

/* Product brandmark (product hero) */
.brandmark { display: inline-flex; align-items: center; gap: 0.7rem; margin-bottom: 1.3rem; }
.brandmark .mark {
  width: 46px;
  height: 46px;
  border-radius: 12px;
  background: var(--grad);
  color: #fff;
  font-weight: 800;
  font-size: 1.4rem;
  display: grid;
  place-items: center;
}
.brandmark .name { font-weight: 800; font-size: 1.25rem; color: var(--heading); letter-spacing: -0.01em; }

/* Reading progress bar (blog posts) */
.progress-bar {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  width: 0;
  background: var(--grad);
  z-index: 100;
  box-shadow: 0 0 10px rgba(124, 58, 237, 0.5);
}

/* --------------------------------------------------------------------------
   Scroll reveal
   -------------------------------------------------------------------------- */

.reveal { opacity: 0; transform: translateY(26px); }
.reveal.in {
  opacity: 1;
  transform: none;
  transition: opacity 0.65s ease, transform 0.65s ease;
}
.reveal.d1.in { transition-delay: 0.08s; }
.reveal.d2.in { transition-delay: 0.16s; }
.reveal.d3.in { transition-delay: 0.24s; }

/* Revealed 3D cards keep their perspective transform (beats .reveal.in) */
.card-3d.reveal.in {
  transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg));
  transition: opacity 0.65s ease, transform 0.3s cubic-bezier(0.2, 0.8, 0.3, 1), box-shadow 0.35s ease, border-color 0.25s ease;
}
.card-3d.reveal.in:hover {
  transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)) translateY(-8px) scale(1.015);
}

/* --------------------------------------------------------------------------
   Load more (blog listing)
   The extra posts stay in the HTML so crawlers and no-JS visitors get every
   post. Only the script hides them, and only the script shows the button.
   -------------------------------------------------------------------------- */

.is-hidden { display: none; }

.load-more-wrap { margin-top: 2.5rem; text-align: center; }
.load-more-count {
  display: block;
  margin-top: 0.8rem;
  color: var(--muted);
  font-size: 0.92rem;
}

/* --------------------------------------------------------------------------
   Utilities
   -------------------------------------------------------------------------- */

.mt-0 { margin-top: 0; }
.mt-2 { margin-top: 2rem; }
.mb-2 { margin-bottom: 2rem; }

:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }

/* Skip link: hidden until keyboard focus brings it on screen */
.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  z-index: 200;
  background: var(--dark-bg-2);
  color: #fff;
  font-weight: 700;
  padding: 0.7rem 1.2rem;
  border-radius: 0 0 10px 0;
  text-decoration: none;
}
.skip-link:focus { left: 0; }

/* Small phone refinements */
@media (max-width: 560px) {
  body { font-size: 1rem; overflow-wrap: break-word; }
  .brand img { width: 150px; height: 51px; }
  .hero { padding-top: 2.6rem; }
  .hero-ctas .btn { width: 100%; text-align: center; }
  .terminal-body { min-height: 200px; padding: 0.9rem 0.9rem 1.1rem; }
  .terminal { font-size: 0.78rem; }
  .card, .step { padding: 1.4rem 1.2rem; }
  .case-metrics { gap: 1.1rem 1.6rem; }
  .photo-card { min-height: 240px; }
  .stats { gap: 1.6rem 1rem; }
  .cta-band .btn { width: 100%; text-align: center; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition: none !important;
  }
  .reveal { opacity: 1; transform: none; }
}
