/* KeyHub Landing — Dark SaaS + Animations */

:root {
  --bg-primary: #000000;
  --bg-secondary: #0f0f0f;
  --panel: #1a1a1a;
  --menu-panel: #292929;
  --accent: #FFA31A;
  --accent-dim: rgba(255, 163, 26, 0.15);
  --accent-glow: rgba(255, 163, 26, 0.4);
  --text: #FFFFFF;
  --text-muted: #888;
  --border: #2a2a2a;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg-primary);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  -webkit-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
  touch-action: pan-x pan-y;
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ——— NAVBAR ——— */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 14px 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
  transition: background 0.3s, border-color 0.3s, box-shadow 0.3s;
}

.navbar.scrolled {
  background: rgba(0, 0, 0, 0.85);
  border-bottom-color: var(--border);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.3);
}

.navbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.navbar-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--text);
  transition: opacity 0.2s, transform 0.2s;
}

.navbar-brand:hover {
  opacity: 0.9;
  transform: scale(1.02);
}

.navbar-logo {
  display: block;
  height: 52px;
  width: auto;
  object-fit: contain;
}

.navbar-txtlogo {
  display: block;
  height: 38px;
  width: auto;
  object-fit: contain;
}

.navbar-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.navbar-user {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 10px 4px 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border);
  margin-right: 4px;
}

.navbar-user-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}

.navbar-user-name {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text);
  max-width: 140px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.btn-nav {
  padding: 10px 20px;
  font-size: 0.9375rem;
}

.hero {
  padding-top: 0;
}

.hero-inner {
  padding-top: calc(80px + 68px);
}

/* ——— FLOATING ORBS ——— */
.orb {
  position: fixed;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.5;
  pointer-events: none;
  z-index: 0;
  animation: orbFloat 15s ease-in-out infinite;
}

.orb-1 {
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, var(--accent-glow) 0%, transparent 70%);
  top: -100px;
  right: -100px;
}

.orb-2 {
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, rgba(255, 163, 26, 0.2) 0%, transparent 70%);
  bottom: 20%;
  left: -80px;
  animation-delay: -5s;
  animation-duration: 18s;
}

.orb-3 {
  width: 250px;
  height: 250px;
  background: radial-gradient(circle, rgba(255, 163, 26, 0.15) 0%, transparent 70%);
  top: 50%;
  right: 10%;
  animation-delay: -10s;
  animation-duration: 12s;
}

@keyframes orbFloat {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(30px, -20px) scale(1.05); }
  66% { transform: translate(-20px, 30px) scale(0.95); }
}

/* ——— BUTTONS ——— */
.btn {
  display: inline-block;
  padding: 14px 28px;
  font-family: var(--font-sans);
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  border-radius: 10px;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.3s, background 0.2s, color 0.2s, border-color 0.2s;
  border: 2px solid transparent;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-primary {
  background: var(--accent);
  color: #000;
}

.btn-primary:hover {
  background: #ffb84d;
  box-shadow: 0 8px 24px var(--accent-glow);
}

.btn-secondary {
  background: transparent;
  color: var(--text);
  border-color: var(--text-muted);
}

.btn-secondary:hover {
  border-color: var(--accent);
  color: var(--accent);
  box-shadow: 0 0 20px var(--accent-dim);
}

.btn-glow {
  animation: btnPulse 2.5s ease-in-out infinite;
}

@keyframes btnPulse {
  0%, 100% { box-shadow: 0 0 0 0 var(--accent-glow); }
  50% { box-shadow: 0 0 25px 4px var(--accent-glow); }
}

/* ——— HERO ——— */
.hero {
  position: relative;
  min-height: 95vh;
  display: flex;
  align-items: center;
  background: var(--bg-primary);
  overflow: hidden;
  z-index: 1;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 80% 60% at 70% 50%, rgba(27, 27, 27, 0.9) 0%, transparent 60%);
  pointer-events: none;
}

/* Subtle grid on hero background (~6% so it doesn't fight clean look) */
.hero-grid-bg {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 163, 26, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 163, 26, 0.06) 1px, transparent 1px);
  background-size: 60px 60px;
  pointer-events: none;
  opacity: 0.6;
}

.hero-inner {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: auto auto;
  gap: 48px 48px;
  align-items: center;
}

.hero-headline {
  grid-column: 1;
  grid-row: 1;
}

.hero-visual {
  grid-column: 2;
  grid-row: 1 / -1;
  align-self: center;
}

.hero-buttons {
  grid-column: 1;
  grid-row: 2;
  align-self: start;
}

.hero-title {
  margin: 0 0 20px;
  font-size: clamp(2.25rem, 5vw, 3.5rem);
  font-weight: 700;
  line-height: 1.15;
  color: var(--text);
  overflow: hidden;
}

.hero-title-line {
  display: block;
  opacity: 0;
  transform: translateY(1.2em);
  animation: titleReveal 0.8s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.hero-title-line:nth-child(1) { animation-delay: 0.2s; }
.hero-title-line:nth-child(2) { animation-delay: 0.45s; }

@keyframes titleReveal {
  to { opacity: 1; transform: translateY(0); }
}

.hero-subtext {
  margin: 0 0 32px;
  font-size: 1.125rem;
  color: var(--text-muted);
  max-width: 480px;
  opacity: 0;
  transform: translateY(20px);
  animation: fadeUp 0.6s ease-out 0.6s forwards;
}

@keyframes fadeUp {
  to { opacity: 1; transform: translateY(0); }
}

.hero-buttons {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  opacity: 0;
  transform: translateY(20px);
  animation: fadeUp 0.6s ease-out 0.9s forwards;
}

.hero-visual {
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  z-index: 2;
}


/* 3-step micro-flow: User → Key → Role — no outer box, just cards + arrows */
.hero-flow {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  flex-wrap: nowrap;
  padding: 0;
  background: none;
  border: none;
  border-radius: 0;
  box-shadow: none;
  opacity: 0;
  transform: translateY(20px);
  animation: fadeUp 0.7s ease-out 0.5s forwards;
}

.hero-flow-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.hero-flow-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 72px;
  height: 72px;
  border-radius: 18px;
  background: linear-gradient(180deg, #252525 0%, #1e1e1e 100%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow:
    0 8px 24px rgba(0, 0, 0, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.04);
  color: var(--accent);
  transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
}

.hero-flow-step:hover .hero-flow-icon {
  transform: scale(1.03);
  box-shadow:
    0 8px 24px rgba(0, 0, 0, 0.4),
    0 0 0 1px var(--accent-dim),
    inset 0 1px 0 rgba(255, 255, 255, 0.04);
  border-color: rgba(255, 163, 26, 0.2);
}

.hero-flow-icon svg {
  width: 32px;
  height: 32px;
}

.hero-flow-label {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text);
  letter-spacing: 0.02em;
}

.hero-flow-arrow {
  flex-shrink: 0;
  width: 24px;
  margin: 0 24px;
  font-size: 1.5rem;
  color: var(--accent);
  opacity: 0.9;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ——— SCROLL REVEAL ——— */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1), transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

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

/* ——— STATS ——— */
.stats {
  background: var(--bg-secondary);
  padding: 32px 0;
  position: relative;
  z-index: 1;
  margin-top: -24px;
}

.stats-inner {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.stat-card {
  background: linear-gradient(145deg, var(--panel) 0%, #222 100%);
  border-radius: 14px;
  padding: 20px 20px;
  text-align: center;
  border: 1px solid var(--border);
  transition: transform 0.3s, box-shadow 0.3s, border-color 0.3s;
  opacity: 0;
  transform: translateY(30px);
}

.stat-card.revealed {
  opacity: 1;
  transform: translateY(0);
}

.stat-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4), 0 0 0 1px var(--accent-dim);
  border-color: rgba(255, 163, 26, 0.3);
}

.stat-number {
  display: block;
  font-size: 1.875rem;
  font-weight: 800;
  color: var(--accent);
  margin-bottom: 4px;
  letter-spacing: -0.02em;
}

.stat-label {
  font-size: 0.875rem;
  color: var(--text-muted);
}

/* ——— HOW IT WORKS ——— */
.how-it-works {
  padding: 64px 0;
  background: var(--bg-primary);
  position: relative;
  z-index: 1;
}

.section-title {
  margin: 0 0 8px;
  font-size: clamp(1.75rem, 4vw, 2.25rem);
  font-weight: 700;
  text-align: center;
  color: var(--text);
}

.section-subtitle {
  margin: 0 0 40px;
  font-size: 1.0625rem;
  color: var(--text-muted);
  text-align: center;
}

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

.step-card {
  background: linear-gradient(145deg, var(--panel) 0%, #1f1f1f 100%);
  border-radius: 14px;
  padding: 24px 22px;
  border: 1px solid var(--border);
  text-align: center;
  transition: transform 0.35s, box-shadow 0.35s, border-color 0.35s;
  opacity: 0;
  transform: translateY(50px);
  transition: opacity 0.6s cubic-bezier(0.22, 1, 0.36, 1), transform 0.6s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.35s, border-color 0.35s;
}

.steps-grid .step-card:nth-child(1) { transition-delay: 0.1s; }
.steps-grid .step-card:nth-child(2) { transition-delay: 0.2s; }
.steps-grid .step-card:nth-child(3) { transition-delay: 0.3s; }

.step-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.35), 0 0 40px var(--accent-dim);
  border-color: rgba(255, 163, 26, 0.25);
}

.step-number {
  width: 52px;
  height: 52px;
  margin: 0 auto 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-secondary);
  color: var(--accent);
  font-size: 1.35rem;
  font-weight: 800;
  border-radius: 50%;
  border: 2px solid var(--accent);
  transition: transform 0.3s, box-shadow 0.3s;
}

.step-card:hover .step-number {
  transform: scale(1.08);
  box-shadow: 0 0 20px var(--accent-glow);
}

.step-title {
  margin: 0 0 8px;
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--text);
}

.step-desc {
  margin: 0;
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.5;
}

/* ——— FEATURES ——— */
.features {
  padding: 64px 0;
  background: var(--bg-secondary);
  position: relative;
  z-index: 1;
}

.features .section-subtitle {
  margin-bottom: 32px;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 0;
}

.feature-card {
  background: linear-gradient(145deg, var(--panel) 0%, #1f1f1f 100%);
  border-radius: 12px;
  padding: 32px 24px;
  border: 1px solid var(--border);
  transition: transform 0.35s, box-shadow 0.35s, border-color 0.35s;
  opacity: 0;
  transform: translateY(50px);
  transition: opacity 0.6s cubic-bezier(0.22, 1, 0.36, 1), transform 0.6s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.35s, border-color 0.35s;
  position: relative;
  overflow: hidden;
}

.features-grid .feature-card:nth-child(1) { transition-delay: 0.1s; }
.features-grid .feature-card:nth-child(2) { transition-delay: 0.2s; }
.features-grid .feature-card:nth-child(3) { transition-delay: 0.3s; }

.feature-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  opacity: 0;
  transition: opacity 0.35s;
}

.feature-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.35), 0 0 50px var(--accent-dim);
  border-color: rgba(255, 163, 26, 0.3);
}

.feature-card:hover::before {
  opacity: 1;
}

.feature-icon {
  margin-bottom: 16px;
  line-height: 1;
  transition: transform 0.3s;
}

.feature-card:hover .feature-icon {
  transform: scale(1.1);
}

.feature-icon svg {
  display: block;
  filter: drop-shadow(0 0 8px var(--accent-dim));
}

.feature-title {
  margin: 0 0 12px;
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--text);
}

.feature-desc {
  margin: 0;
  font-size: 0.9375rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ——— FAQ ——— */
.faq {
  padding: 64px 0;
  background: var(--bg-primary);
  position: relative;
  z-index: 1;
}

.faq-list {
  max-width: 720px;
  margin: 40px auto 0;
}

.faq-item {
  border-bottom: 1px solid var(--border);
  transition: background 0.2s;
  margin-top: 8px;
}

.faq-item:first-child {
  border-top: 1px solid var(--border);
  margin-top: 0;
}

.faq-question {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 0;
  font-family: var(--font-sans);
  font-size: 1.0625rem;
  font-weight: 600;
  color: var(--text);
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
  transition: color 0.25s;
}

.faq-question:hover {
  color: var(--accent);
}

.faq-icon {
  flex-shrink: 0;
  width: 26px;
  height: 26px;
  margin-left: 20px;
  position: relative;
  transition: transform 0.3s ease;
}

.faq-icon::before,
.faq-icon::after {
  content: '';
  position: absolute;
  left: 50%;
  top: 50%;
  width: 14px;
  height: 2px;
  background: var(--text-muted);
  transform: translate(-50%, -50%);
  transition: background 0.25s;
}

.faq-icon::after {
  width: 2px;
  height: 14px;
  transform: translate(-50%, -50%);
}

.faq-question:hover .faq-icon::before,
.faq-question:hover .faq-icon::after {
  background: var(--accent);
}

.faq-item[aria-expanded="true"] .faq-icon {
  transform: rotate(180deg);
}

.faq-item[aria-expanded="true"] .faq-icon::before,
.faq-item[aria-expanded="true"] .faq-icon::after {
  background: var(--accent);
}

.faq-item[aria-expanded="true"] .faq-icon::after {
  display: none;
}

.faq-answer {
  overflow: hidden;
  max-height: 0;
  transition: max-height 0.25s ease-out;
}

.faq-answer p {
  margin: 0 0 20px;
  padding: 0 0 20px;
  font-size: 0.9375rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ——— CTA ——— */
.cta {
  padding: 72px 0;
  background: var(--bg-secondary);
  position: relative;
  z-index: 1;
}

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

.cta-title {
  margin: 0 0 24px;
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 700;
  color: var(--text);
}

.btn-cta {
  padding: 16px 36px;
  font-size: 1.0625rem;
}

/* ——— FOOTER ——— */
.footer {
  padding: 40px 0;
  background: var(--bg-primary);
  border-top: 1px solid var(--border);
  position: relative;
  z-index: 1;
}

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

.footer-brand-wrap {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.footer-brand-img {
  display: block;
  height: 28px;
  width: auto;
  object-fit: contain;
}

.footer-tagline {
  margin: 0;
  font-size: 0.8125rem;
  color: var(--text-muted);
  max-width: 260px;
  line-height: 1.4;
}

.footer-links {
  display: flex;
  gap: 24px;
}

.footer-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.9375rem;
  transition: color 0.2s, transform 0.2s;
}

.footer-links a:hover {
  color: var(--accent);
  transform: translateY(-1px);
}

.footer-copy {
  margin: 0;
  font-size: 0.875rem;
  color: var(--text-muted);
  width: 100%;
  text-align: center;
}

/* ——— Button ripple ——— */
.btn-ripple {
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  transform: translate(-50%, -50%) scale(0);
  pointer-events: none;
  animation: ripple 0.6s ease-out forwards;
}

@keyframes ripple {
  to {
    transform: translate(-50%, -50%) scale(8);
    opacity: 0;
  }
}

/* ——— MOBILE: Hamburger + menu ——— */
.navbar-hamburger {
  display: none;
  align-items: center;
  justify-content: center;
  width: 44px;
  min-width: 44px;
  height: 44px;
  min-height: 44px;
  padding: 0;
  margin: 0;
  margin-left: 8px;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text);
  transition: color 0.2s;
  flex-direction: column;
  gap: 6px;
}

.navbar-hamburger:hover,
.navbar-hamburger:focus {
  color: var(--accent);
  outline: none;
}

.navbar-hamburger.open {
  color: var(--accent);
}

.hamburger-line {
  display: block;
  width: 22px;
  height: 2px;
  background: currentColor;
  border-radius: 1px;
  transition: transform 0.25s ease, opacity 0.2s ease;
}

/* Hamburger morphs into X when open */
.navbar-hamburger.open .hamburger-line:nth-child(1) {
  transform: translateY(8px) rotate(45deg);
}

.navbar-hamburger.open .hamburger-line:nth-child(2) {
  opacity: 0;
}

.navbar-hamburger.open .hamburger-line:nth-child(3) {
  transform: translateY(-8px) rotate(-45deg);
}

/* Overlay: simple dark, no blur */
.nav-menu-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 150;
  opacity: 0;
  transition: opacity 0.22s ease;
}

.nav-menu-overlay.visible {
  opacity: 1;
}

/* Panel: dark like page, slight depth (not flat gray wall) */
.nav-menu {
  position: fixed;
  top: 0;
  right: 0;
  width: 300px;
  max-width: 88vw;
  height: 100%;
  background: var(--bg-primary);
  z-index: 151;
  transform: translateX(100%);
  transition: transform 0.22s cubic-bezier(0.22, 1, 0.36, 1);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: -4px 0 24px rgba(0, 0, 0, 0.4);
  border-left: 1px solid var(--border);
}

.nav-menu.open {
  transform: translateX(0);
}

.nav-menu-inner {
  display: flex;
  flex-direction: column;
  min-height: 100%;
  padding: 0;
}

/* Header: logo + KeyHub + close (explicit close control) */
.nav-menu-header {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  gap: 12px;
}

.nav-menu-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text);
}

.nav-menu-logo {
  display: block;
  width: 32px;
  height: 32px;
  object-fit: contain;
}

.nav-menu-brand-text {
  font-size: 1.125rem;
  font-weight: 700;
}

.nav-menu-user {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border);
  margin-right: auto;
}

.nav-menu-user-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}

.nav-menu-user-name {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--text);
}

.nav-menu-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  min-width: 44px;
  min-height: 44px;
  padding: 0;
  margin: 0;
  background: none;
  border: none;
  color: var(--text);
  cursor: pointer;
  transition: color 0.2s;
  border-radius: 8px;
}

.nav-menu-close:hover,
.nav-menu-close:focus {
  color: var(--accent);
  outline: none;
}

.nav-menu-close-icon {
  font-size: 1.75rem;
  line-height: 1;
  font-weight: 300;
}

/* Links: scrollable, with zone hierarchy (spacing between zones) */
.nav-menu-links {
  flex: 1;
  overflow-y: auto;
  padding: 20px 20px 24px;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.nav-menu-zone {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.nav-menu-zone + .nav-menu-zone {
  margin-top: 24px;
}

.nav-menu-link {
  display: block;
  padding: 12px 0;
  font-size: 1rem;
  font-weight: 500;
  color: var(--text);
  text-decoration: none;
  transition: color 0.2s;
}

.nav-menu-link:hover {
  color: var(--accent);
}

/* CTA anchored to bottom, visually separated */
.nav-menu-cta-wrap {
  flex-shrink: 0;
  padding: 20px 20px 24px;
  padding-bottom: max(24px, env(safe-area-inset-bottom));
  border-top: 1px solid var(--border);
  background: var(--bg-primary);
}

.nav-menu-cta {
  display: block;
  width: 100%;
  text-align: center;
  padding: 16px 20px;
  font-size: 1rem;
  font-weight: 600;
  box-sizing: border-box;
}

/* ——— RESPONSIVE ——— */
@media (max-width: 900px) {
  .navbar-inner {
    padding: 0 16px;
  }

  .navbar-txtlogo {
    height: 30px;
  }

  .navbar-logo {
    height: 44px;
  }

  .btn-nav {
    padding: 8px 16px;
    font-size: 0.875rem;
  }

  .hero-inner {
    grid-template-columns: 1fr;
    grid-template-rows: auto auto auto;
    text-align: center;
    padding-top: calc(60px + 60px);
  }

  /* Explicit order: 1 text, 2 icons, 3 button */
  .hero-headline {
    grid-column: 1;
    grid-row: 1;
  }

  .hero-visual {
    grid-column: 1;
    grid-row: 2;
  }

  .hero-buttons {
    grid-column: 1;
    grid-row: 3;
    justify-content: center;
  }

  .hero-subtext {
    margin-left: auto;
    margin-right: auto;
  }

  /* Mobile: headline → horizontal flow → CTA (flow never stacked) */
  .hero-flow {
    flex-direction: row;
    justify-content: center;
  }

  .stats {
    margin-top: -16px;
    padding: 28px 0;
  }

  .stats-inner {
    grid-template-columns: repeat(2, 1fr);
  }

  .steps-grid,
  .features-grid {
    grid-template-columns: 1fr;
  }

  .footer-inner {
    flex-direction: column;
    text-align: center;
  }

  .footer-brand-wrap {
    align-items: center;
  }

  .footer-tagline {
    text-align: center;
    max-width: 320px;
  }

  .footer-links {
    justify-content: center;
  }
}

/* Mobile navbar: logo + text + hamburger only; no Add Bot / Login in header */
@media (max-width: 768px) {
  .navbar-actions .btn-nav {
    display: none;
  }

  .navbar-hamburger {
    display: flex;
  }
}

@media (max-width: 768px) {
  .nav-menu-overlay {
    display: block;
    pointer-events: none;
  }

  .nav-menu-overlay.visible {
    pointer-events: auto;
  }
}

@media (max-width: 600px) {
  .navbar {
    padding: 10px 0;
  }

  .navbar-brand {
    gap: 8px;
  }

  .navbar-logo {
    height: 36px;
  }

  .navbar-actions {
    gap: 8px;
  }

  .btn-nav {
    padding: 8px 14px;
    font-size: 0.8125rem;
  }

  .hero-inner {
    padding-top: calc(50px + 52px);
  }

  /* Flow stays horizontal on mobile: User → Key → Role in one row */
  .hero-flow {
    gap: 0;
    padding: 0;
  }

  .hero-flow-arrow {
    margin: 0 16px;
  }

  .hero-flow-icon {
    width: 56px;
    height: 56px;
  }

  .hero-flow-icon svg {
    width: 26px;
    height: 26px;
  }

  /* Single CTA on mobile: only Add to Discord */
  .hero-buttons .btn-secondary {
    display: none;
  }

  .hero-buttons {
    flex-direction: column;
  }

  .btn {
    width: 100%;
    text-align: center;
  }

  .stats-inner {
    grid-template-columns: 1fr;
  }

  .stat-number {
    font-size: 1.65rem;
  }

  .orb {
    filter: blur(60px);
    opacity: 0.35;
  }
}
