/* ========================================
   halobot — Making Minds design system
   Shared theme with mnemos & cartograph
   ======================================== */

:root {
  color-scheme: dark;
  --bg: #11120e;
  --bg-deep: #0a0b08;
  --bg-elevated: rgba(24, 28, 23, 0.9);
  --surface: rgba(32, 37, 31, 0.86);
  --surface-strong: #232920;
  --surface-soft: rgba(220, 187, 119, 0.08);
  --text: #f5eedf;
  --text-muted: #cfbea0;
  --text-faint: #8f826b;
  --line: rgba(245, 238, 223, 0.12);
  --accent: #b86b30;
  --accent-strong: #de8e4f;
  --accent-soft: rgba(184, 107, 48, 0.18);
  --accent-cool: #6bb8ad;
  --shadow: 0 28px 90px rgba(0, 0, 0, 0.28);
  --radius-xl: 28px;
  --radius-lg: 22px;
  --radius-md: 16px;
  --nav-height: 86px;
  --container-wide: 1220px;
  --container: 1080px;
}

html[data-theme="light"] {
  color-scheme: light;
  --bg: #f1eadc;
  --bg-deep: #d8cebd;
  --bg-elevated: rgba(252, 248, 240, 0.92);
  --surface: rgba(255, 251, 243, 0.92);
  --surface-strong: #fff9ef;
  --surface-soft: rgba(122, 78, 35, 0.07);
  --text: #1e180f;
  --text-muted: #66523b;
  --text-faint: #8f7c64;
  --line: rgba(30, 24, 15, 0.12);
  --accent: #9a531b;
  --accent-strong: #bf6a24;
  --accent-soft: rgba(154, 83, 27, 0.12);
  --accent-cool: #0b7369;
  --shadow: 0 28px 90px rgba(74, 48, 20, 0.12);
}

/* ---- RESET ---- */
*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-height) + 2rem);
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Manrope", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 14% 18%, rgba(222, 142, 79, 0.18), transparent 26%),
    radial-gradient(circle at 82% 16%, rgba(107, 184, 173, 0.16), transparent 24%),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-deep) 100%);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.22;
  background-image:
    radial-gradient(circle at 20% 20%, transparent 0 84px, rgba(255,255,255,0.03) 84px 85px, transparent 85px 124px, rgba(255,255,255,0.025) 124px 125px, transparent 125px 164px, rgba(255,255,255,0.018) 164px 165px, transparent 165px),
    radial-gradient(circle at 78% 70%, transparent 0 74px, rgba(255,255,255,0.03) 74px 75px, transparent 75px 112px, rgba(255,255,255,0.02) 112px 113px, transparent 113px 150px, rgba(255,255,255,0.016) 150px 151px, transparent 151px);
}

a { color: inherit; text-decoration: none; }
img, svg { display: block; max-width: 100%; }
button, input, textarea, select { font: inherit; }
h1, h2, h3, h4, h5, h6 { margin: 0; }
p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }

/* ---- MONO FAMILY ---- */
code, pre, .eyebrow, .stat-label, .panel-title,
.step-note, .flow-proto, .flow-sub, .footer-tagline {
  font-family: "IBM Plex Mono", monospace;
}

code {
  padding: 0.14rem 0.38rem;
  border-radius: 0.45rem;
  background: var(--surface-soft);
  color: var(--accent-strong);
  font-size: 0.9em;
}

pre { margin: 0; white-space: pre-wrap; word-break: break-word; }

/* ---- HEADINGS (Fraunces) ---- */
h1, h2, .footer-name {
  font-family: "Fraunces", serif;
  font-weight: 700;
  letter-spacing: -0.03em;
}

/* ---- LAYOUT ---- */
.container {
  width: min(100% - 2rem, var(--container));
  margin: 0 auto;
}

/* ====== NAVIGATION ====== */
.nav {
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(18px);
  background: rgba(17, 18, 14, 0.72);
  border-bottom: 1px solid var(--line);
}

html[data-theme="light"] .nav {
  background: rgba(241, 234, 220, 0.82);
}

.nav-inner {
  min-height: var(--nav-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.4rem;
}

.nav-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  font-weight: 700;
}

.nav-logo {
  width: 2.8rem;
  height: 2.8rem;
  padding: 0.3rem;
  border-radius: 0.85rem;
  color: var(--accent-strong);
  background:
    linear-gradient(145deg, rgba(222, 142, 79, 0.18), rgba(107, 184, 173, 0.12)),
    var(--surface);
  border: 1px solid rgba(222, 142, 79, 0.22);
  display: flex;
  align-items: center;
  justify-content: center;
}

.nav-logo svg { display: inline; }

.nav-brand-text {
  font-size: 1rem;
  letter-spacing: 0.02em;
}

.nav-links, .nav-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.nav-links a {
  color: var(--text-muted);
  font-size: 0.96rem;
  transition: color 180ms ease;
}

.nav-links a:hover,
.nav-links a:focus-visible {
  color: var(--text);
}

.nav-mobile-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text);
  cursor: pointer;
  padding: 0.5rem;
}

.nav-mobile-menu {
  display: none;
  flex-direction: column;
  gap: 0.5rem;
  padding: 1rem;
  border-top: 1px solid var(--line);
}

.nav-mobile-menu a {
  display: block;
  padding: 0.75rem 0;
  color: var(--text-muted);
  font-size: 1rem;
  border-bottom: 1px solid var(--line);
}

.nav-mobile-menu a:last-of-type { border-bottom: none; }

.nav-mobile-actions {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 0.75rem;
}

.nav-mobile-menu.open { display: flex; }

/* ---- BUTTONS ---- */
.btn-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  min-height: 2.9rem;
  padding: 0.72rem 1.2rem;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.94rem;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--text);
  cursor: pointer;
  text-decoration: none;
  transition:
    transform 180ms ease,
    background 180ms ease,
    border-color 180ms ease,
    color 180ms ease,
    box-shadow 180ms ease;
}

.btn-pill:hover,
.btn-pill:focus-visible {
  transform: translateY(-1px);
  border-color: rgba(222, 142, 79, 0.4);
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-strong));
  color: #fff7ef;
  border-color: transparent;
  box-shadow: 0 18px 36px rgba(184, 107, 48, 0.24);
}

.btn-primary:hover {
  box-shadow: 0 22px 44px rgba(184, 107, 48, 0.32);
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.02);
}

.btn-lg {
  min-height: 3.2rem;
  padding: 0.85rem 1.6rem;
  font-size: 1rem;
}

.btn-theme {
  text-transform: lowercase;
  font-weight: 500;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.82rem;
}

/* ====== HERO ====== */
.hero {
  padding: 5.5rem 0 4rem;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(320px, 0.92fr);
  gap: 2rem;
  align-items: center;
}

.eyebrow {
  font-size: 0.76rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent-cool);
}

.hero h1 {
  margin-top: 0.9rem;
  font-size: clamp(2.6rem, 5.5vw, 5rem);
  line-height: 0.98;
  max-width: 16ch;
}

.hero-lead {
  margin-top: 1.5rem;
  max-width: 44rem;
  font-size: clamp(1.05rem, 1.15vw, 1.24rem);
  color: var(--text);
}

.hero-sub {
  margin-top: 0.8rem;
  color: var(--accent-strong);
  font-size: 1rem;
  letter-spacing: 0.02em;
}

.hero-sub strong {
  font-weight: 800;
}

.hero-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  margin-top: 1.7rem;
}

.hero-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 1.8rem;
}

.stat-item {
  min-width: 8rem;
  padding: 0.85rem 1rem;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--line);
}

.stat-value {
  display: block;
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--accent-strong);
}

.stat-label {
  display: block;
  margin-top: 0.25rem;
  font-size: 0.76rem;
  color: var(--text-faint);
}

/* ---- HERO PANEL (Discord Chat) ---- */
.hero-panel {
  position: relative;
}

.hero-panel-glow {
  position: absolute;
  inset: -1.1rem;
  border-radius: calc(var(--radius-xl) + 8px);
  background:
    radial-gradient(circle at 15% 20%, rgba(222, 142, 79, 0.15), transparent 34%),
    radial-gradient(circle at 85% 24%, rgba(107, 184, 173, 0.13), transparent 28%);
  filter: blur(24px);
  pointer-events: none;
}

.hero-panel-inner {
  position: relative;
  border-radius: var(--radius-xl);
  background:
    linear-gradient(180deg, rgba(255,255,255,0.03), transparent),
    var(--bg-elevated);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.panel-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 1rem 1.4rem;
  border-bottom: 1px solid var(--line);
}

.panel-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.panel-dot.red { background: #ff5f57; }
.panel-dot.yellow { background: #febc2e; }
.panel-dot.green { background: #28c840; }

.panel-title {
  margin-left: 0.5rem;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-faint);
}

.panel-chat {
  padding: 1.2rem 1.4rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.chat-msg {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.chat-author {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-weight: 500;
}

.chat-agent .chat-author { color: var(--accent-cool); }
.chat-human .chat-author { color: var(--accent-strong); }

.chat-text {
  padding: 0.8rem 1rem;
  border-radius: var(--radius-md);
  font-size: 0.92rem;
  line-height: 1.55;
  color: var(--text);
}

.chat-agent .chat-text {
  background: rgba(7, 9, 8, 0.54);
  border: 1px solid rgba(255,255,255,0.06);
}

html[data-theme="light"] .chat-agent .chat-text {
  background: rgba(255,255,255,0.65);
  border-color: var(--line);
  color: var(--text);
}

.chat-human .chat-text {
  background: var(--accent-soft);
  border: 1px solid rgba(184, 107, 48, 0.2);
  color: var(--accent-strong);
  font-weight: 700;
  font-size: 1.1rem;
  align-self: flex-start;
}

.chat-typing {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 0;
}

.chat-typing .chat-author {
  color: var(--text-faint);
  text-transform: none;
  letter-spacing: 0;
  font-size: 0.8rem;
}

.typing-indicator {
  display: flex;
  gap: 3px;
  align-items: center;
}

.typing-indicator span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-cool);
  opacity: 0.4;
  animation: typing-pulse 1.4s ease-in-out infinite;
}

.typing-indicator span:nth-child(2) { animation-delay: 0.2s; }
.typing-indicator span:nth-child(3) { animation-delay: 0.4s; }

@keyframes typing-pulse {
  0%, 80%, 100% { opacity: 0.25; transform: scale(0.85); }
  40% { opacity: 1; transform: scale(1); }
}

/* ====== SECTIONS ====== */
.section {
  padding: 5rem 0;
}

.section h2 {
  margin-top: 0.9rem;
  font-size: clamp(2.2rem, 4.6vw, 4rem);
  line-height: 1.02;
}

.section-lead {
  margin-top: 1rem;
  font-size: 1.05rem;
  color: var(--text-muted);
  max-width: 56ch;
}

.section-surface {
  background: linear-gradient(180deg, rgba(255,255,255,0.02), rgba(255,255,255,0.01));
  border-block: 1px solid var(--line);
}

/* ---- COMPARE CARDS ---- */
.compare-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 2.5rem;
}

.compare-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  padding: 1.6rem;
}

.compare-card h3 {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 1rem;
}

.compare-problem h3 { color: var(--text-muted); }

.compare-solution {
  background:
    linear-gradient(155deg, rgba(222, 142, 79, 0.15), rgba(107, 184, 173, 0.04)),
    var(--surface);
}

.compare-solution h3 { color: var(--accent-strong); }

.compare-card ul {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.compare-card li {
  font-size: 0.96rem;
  color: var(--text-muted);
  line-height: 1.45;
  padding-left: 1.4rem;
  position: relative;
}

.compare-problem li::before {
  content: "—";
  position: absolute;
  left: 0;
  color: var(--text-faint);
}

.compare-solution li {
  padding-left: 0;
}

.compare-solution .check {
  color: var(--accent-strong);
  margin-right: 0.55rem;
}

/* ---- FLOW DIAGRAM ---- */
.flow-diagram {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  margin-top: 3rem;
  padding: 2rem 0;
}

.flow-node {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  padding: 1.4rem 1.8rem;
  border-radius: var(--radius-lg);
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  min-width: 140px;
}

.flow-halo {
  background:
    linear-gradient(155deg, rgba(222, 142, 79, 0.15), rgba(107, 184, 173, 0.06)),
    var(--surface);
  border-color: rgba(222, 142, 79, 0.2);
}

.flow-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.flow-icon svg { display: inline; }

.flow-icon-halo {
  animation: halo-pulse 3s ease-in-out infinite;
}

@keyframes halo-pulse {
  0%, 100% { filter: drop-shadow(0 0 6px rgba(184, 107, 48, 0.2)); }
  50% { filter: drop-shadow(0 0 14px rgba(184, 107, 48, 0.4)); }
}

.flow-label {
  font-weight: 700;
  font-size: 1rem;
}

.flow-sub {
  font-size: 0.72rem;
  color: var(--text-faint);
  letter-spacing: 0.04em;
}

.flow-connector {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  padding: 0 0.6rem;
}

.flow-line {
  width: 48px;
  height: 2px;
  background: linear-gradient(90deg, var(--accent), var(--accent-cool));
  border-radius: 1px;
  position: relative;
}

.flow-line::after {
  content: "";
  position: absolute;
  right: -4px;
  top: -3px;
  width: 0;
  height: 0;
  border-left: 6px solid var(--accent-cool);
  border-top: 4px solid transparent;
  border-bottom: 4px solid transparent;
}

.flow-proto {
  font-size: 0.66rem;
  color: var(--text-faint);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  white-space: nowrap;
}

/* ---- WHY DISCORD ---- */
.why-discord {
  margin-top: 4rem;
}

.why-discord h3 {
  font-family: "Fraunces", serif;
  font-size: 1.8rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.why-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 1.5rem;
}

.why-card {
  padding: 1.2rem;
  border-radius: var(--radius-md);
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--line);
}

.why-icon {
  font-size: 1.5rem;
  display: block;
  margin-bottom: 0.7rem;
}

.why-card h4 {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 0.4rem;
}

.why-card p {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.5;
}

/* ---- TOOLS SECTION ---- */
.tools-block {
  margin-top: 2.5rem;
  display: grid;
  gap: 1.5rem;
}

.tools-group {
  border-radius: var(--radius-lg);
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  padding: 1.6rem;
  overflow: hidden;
}

.tools-group h3 {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: var(--accent-strong);
}

.tools-table {
  display: flex;
  flex-direction: column;
}

.tool-row {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 1rem;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--line);
  align-items: baseline;
}

.tool-row:last-child { border-bottom: none; }

.tool-row code {
  font-size: 0.88rem;
  font-weight: 500;
  white-space: nowrap;
}

.tool-row span {
  font-size: 0.92rem;
  color: var(--text-muted);
}

/* ---- QUICKSTART STEPS ---- */
.steps-grid {
  display: grid;
  gap: 1rem;
  margin-top: 2rem;
}

.step-card {
  display: grid;
  grid-template-columns: 80px minmax(0, 1fr);
  gap: 1.25rem;
  padding: 1.35rem;
  align-items: start;
  border-radius: var(--radius-lg);
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.step-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 4.2rem;
  height: 4.2rem;
  border-radius: 1.2rem;
  background:
    linear-gradient(145deg, rgba(222, 142, 79, 0.22), rgba(107, 184, 173, 0.08)),
    rgba(255,255,255,0.03);
  border: 1px solid rgba(222, 142, 79, 0.22);
}

.step-badge span {
  font-family: "IBM Plex Mono", monospace;
  font-size: 1rem;
  color: var(--accent-strong);
  font-weight: 700;
}

.step-content h4 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 0.6rem;
}

.code-block {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.85rem 1rem;
  border-radius: var(--radius-md);
  background: rgba(7, 9, 8, 0.54);
  border: 1px solid rgba(255,255,255,0.08);
}

html[data-theme="light"] .code-block {
  background: rgba(255,255,255,0.65);
}

.code-block code {
  background: none;
  padding: 0;
  color: #f3e7d1;
  font-size: 0.92rem;
  white-space: nowrap;
  overflow-x: auto;
}

html[data-theme="light"] .code-block code {
  color: #23180f;
}

.copy-btn {
  flex-shrink: 0;
  background: none;
  border: none;
  color: var(--text-faint);
  cursor: pointer;
  padding: 0.3rem;
  border-radius: 0.3rem;
  transition: color 180ms ease, background 180ms ease;
}

.copy-btn:hover {
  color: var(--text);
  background: rgba(255,255,255,0.06);
}

.copy-btn.copied {
  color: var(--accent-cool);
}

.step-note {
  margin-top: 0.5rem;
  font-size: 0.84rem;
  color: var(--text-faint);
  line-height: 1.5;
}

/* ---- USE CASES ---- */
.usecases-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 2.5rem;
}

.usecase-card {
  padding: 1.4rem;
  border-radius: var(--radius-lg);
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.usecase-icon {
  font-size: 1.5rem;
  margin-bottom: 0.8rem;
}

.usecase-card h4 {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 0.4rem;
}

.usecase-card p {
  font-size: 0.92rem;
  color: var(--text-muted);
  line-height: 1.5;
}

/* ---- FEATURES ---- */
.features-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 2rem;
}

.feature-item {
  padding: 1.4rem;
  border-radius: var(--radius-md);
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--line);
}

.feature-item h4 {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 0.4rem;
}

.feature-item p {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.feature-item code {
  font-size: 0.84rem;
}

/* ---- CTA SECTION ---- */
.section-cta {
  padding: 5rem 0;
  text-align: center;
}

.cta-content h2 {
  font-size: clamp(2rem, 4vw, 3.5rem);
  line-height: 1.05;
}

.cta-content p {
  margin-top: 1rem;
  font-size: 1.1rem;
  color: var(--text-muted);
}

.cta-buttons {
  display: flex;
  justify-content: center;
  gap: 0.85rem;
  margin-top: 2rem;
}

/* ====== FOOTER ====== */
.footer {
  padding: 2rem 0 2.8rem;
  border-top: 1px solid var(--line);
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.2rem;
}

.footer-name {
  font-size: 1.35rem;
}

.footer-tagline {
  display: block;
  margin-top: 0.3rem;
  font-size: 0.8rem;
  color: var(--text-faint);
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  color: var(--text-muted);
  font-size: 0.94rem;
}

.footer-links a:hover,
.footer-links a:focus-visible {
  color: var(--text);
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--line);
  font-size: 0.82rem;
  color: var(--text-faint);
}

.footer-bottom a {
  color: var(--text-muted);
  transition: color 180ms ease;
}

.footer-bottom a:hover { color: var(--text); }

/* ====== SCROLL REVEAL ====== */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ====== RESPONSIVE ====== */
@media (max-width: 1024px) {
  .hero-grid {
    grid-template-columns: 1fr;
  }

  .hero-panel {
    max-width: 520px;
  }

  .hero h1 {
    max-width: 16ch;
  }

  .nav-links { display: none; }

  .nav-mobile-toggle { display: block; }

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

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

  .tool-row {
    grid-template-columns: 1fr;
    gap: 0.3rem;
  }
}

@media (max-width: 760px) {
  .hero {
    padding-top: 4rem;
  }

  .section {
    padding: 3.5rem 0;
  }

  .compare-grid,
  .usecases-grid,
  .features-grid,
  .why-grid {
    grid-template-columns: 1fr;
  }

  .hero-ctas,
  .hero-stats,
  .cta-buttons,
  .footer-inner {
    flex-direction: column;
    align-items: stretch;
  }

  .cta-buttons .btn-pill {
    width: 100%;
  }

  .hero-stats { gap: 0.75rem; }

  .step-card {
    grid-template-columns: 1fr;
  }

  .step-badge {
    width: 3.6rem;
    height: 3.6rem;
  }

  .flow-diagram {
    flex-direction: column;
    gap: 0;
  }

  .flow-connector {
    padding: 0.4rem 0;
  }

  .flow-line {
    width: 2px;
    height: 36px;
    background: linear-gradient(180deg, var(--accent), var(--accent-cool));
  }

  .flow-line::after {
    right: auto;
    top: auto;
    bottom: -4px;
    left: -3px;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    border-top: 6px solid var(--accent-cool);
    border-bottom: none;
  }

  .nav-actions .btn-theme { display: none; }
}

@media (max-width: 480px) {
  .hero h1 {
    font-size: clamp(2.2rem, 9vw, 3.2rem);
  }

  .nav-actions {
    display: none;
  }
}

/* ---- REDUCED MOTION ---- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
