@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;600;800&family=IBM+Plex+Mono:wght@400;500&display=swap');

:root {
  --bg-dark: #000000;
  --accent-cyan: #00f2ff;
  --accent-purple: #7000ff;
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --glass-bg: rgba(255, 255, 255, 0.03);
  --glass-border: rgba(255, 255, 255, 0.08);
  --grid-color: rgba(255, 255, 255, 0.02);
  --hero-gradient: linear-gradient(to bottom, #fff, #444);
  --nav-height: 80px;
}

body.light-theme {
  --bg-dark: #f1f5f9;
  --text-main: #0f172a;
  --text-muted: #64748b;
  --glass-bg: rgba(255, 255, 255, 0.7);
  --glass-border: rgba(15, 23, 42, 0.1);
  --grid-color: rgba(0, 0, 0, 0.05);
  --hero-gradient: linear-gradient(135deg, #0f172a 0%, #334155 100%);
  --accent-cyan: #1d4ed8;
  --accent-purple: #6d28d9;
}

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

body {
  font-family: 'Outfit', sans-serif;
  background-color: var(--bg-dark);
  color: var(--text-main);
  line-height: 1.5;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* Base Grid & Background */
.mesh-bg {
  position: fixed;
  inset: 0;
  z-index: -2;
  overflow: hidden;
}

.mesh-bg::before,
.mesh-bg::after {
  content: '';
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
}

.mesh-bg::before {
  width: 60vw;
  height: 60vw;
  background: rgba(112, 0, 255, 0.1);
  top: -10%;
  left: -10%;
  animation: blob-a 18s ease-in-out infinite;
}

.mesh-bg::after {
  width: 50vw;
  height: 50vw;
  background: rgba(0, 242, 255, 0.08);
  bottom: -10%;
  right: -5%;
  animation: blob-b 22s ease-in-out infinite;
}

@keyframes blob-a {
  0%   { transform: translate(0, 0); }
  33%  { transform: translate(8vw, 6vh); }
  66%  { transform: translate(-4vw, 10vh); }
  100% { transform: translate(0, 0); }
}

@keyframes blob-b {
  0%   { transform: translate(0, 0); }
  33%  { transform: translate(-6vw, -8vh); }
  66%  { transform: translate(5vw, -4vh); }
  100% { transform: translate(0, 0); }
}

body.light-theme .mesh-bg {
  display: none;
}

.grid-overlay {
  position: fixed;
  inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(var(--grid-color) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-color) 1px, transparent 1px);
  background-size: 50px 50px;
  mask-image: radial-gradient(circle at 50% 50%, black, transparent 80%);
}

.page-wrapper {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 2rem;
}

/* Typography Helpers */
.kicker {
  text-transform: uppercase;
  letter-spacing: 0.15em;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--accent-cyan);
  margin-bottom: 1rem;
  display: block;
}

h2 {
  font-size: clamp(2.5rem, 5vw, 4rem);
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin-bottom: 2rem;
}

.section-copy {
  font-size: 1.25rem;
  color: var(--text-muted);
  max-width: 800px;
  margin-bottom: 4rem;
}

/* Sidebar Nav */
.floating-nav {
  position: fixed;
  right: 2rem;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  z-index: 1000;
}

.nav-dot {
  width: 12px;
  height: 12px;
  border: 2px solid var(--glass-border);
  border-radius: 50%;
  transition: all 0.3s ease;
  position: relative;
}

.nav-dot:hover, .nav-dot.active {
  background: var(--accent-cyan);
  border-color: var(--accent-cyan);
  transform: scale(1.3);
}

.nav-dot::after {
  content: attr(data-label);
  position: absolute;
  right: 2rem;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(15, 23, 42, 0.92);
  color: #f8fafc;
  border: 1px solid rgba(255,255,255,0.12);
  backdrop-filter: blur(10px);
  padding: 0.4rem 0.8rem;
  border-radius: 6px;
  font-size: 0.75rem;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: all 0.3s ease;
}

body.light-theme .nav-dot::after {
  background: rgba(15, 23, 42, 0.88);
  border-color: rgba(0,0,0,0.15);
}

.nav-dot:hover::after {
  opacity: 1;
  right: 2.5rem;
}

/* Top Nav */
.top-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 900;
  transform: translateY(-100%);
  transition: transform 0.4s cubic-bezier(0.19, 1, 0.22, 1);
}

.top-nav.visible {
  transform: translateY(0);
}

.top-nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 2rem;
  height: 56px;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--glass-border);
}

body.light-theme .top-nav-inner {
  background: rgba(241, 245, 249, 0.85);
}

.top-nav-brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.top-nav-icon {
  width: 24px;
  height: 24px;
  border-radius: 6px;
}

.top-nav-logo {
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: -0.02em;
  color: var(--text-main);
}

.top-nav-section {
  flex: 1;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent-cyan);
  text-align: center;
  padding: 0 1rem;
  transition: opacity 0.2s ease;
}

.top-nav-right {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.lang-switcher {
  display: flex;
  gap: 0.2rem;
}

.lang-switcher-fixed {
  position: fixed;
  top: 1rem;
  left: 1.5rem;
  z-index: 950;
  display: flex;
  flex-wrap: wrap;
  gap: 0.2rem;
  max-width: 220px;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--glass-border);
  border-radius: 8px;
  padding: 0.3rem;
  transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s ease;
}

body.light-theme .lang-switcher-fixed {
  background: rgba(241, 245, 249, 0.85);
}

.lang-switcher-fixed.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(-0.5rem);
}

/* CJK font fallback */
body.lang-cjk {
  font-family: 'Outfit', 'Noto Sans CJK SC', 'Hiragino Sans', 'Yu Gothic', sans-serif;
}

/* Arabic RTL adjustments */
body.lang-ar {
  font-family: 'Outfit', 'Noto Sans Arabic', 'Segoe UI', sans-serif;
}

body.lang-ar .hero {
  direction: rtl;
}

body.lang-ar .hero-actions {
  flex-direction: row-reverse;
}

body.lang-ar .bullet-list li {
  padding-left: 0;
  padding-right: 1.5rem;
}

body.lang-ar .bullet-list li::before {
  left: auto;
  right: 0;
  content: '←';
}

body.lang-ar .comparison-row {
  direction: rtl;
}

body.lang-ar .try-steps {
  flex-direction: row-reverse;
}

body.lang-ar .build-flow {
  flex-direction: row-reverse;
}

body.lang-ar .flow-arrow-line::after {
  right: auto;
  left: -1px;
  border-left: none;
  border-right: 7px solid rgba(0, 242, 255, 0.6);
}

.lang-btn {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  padding: 0.28rem 0.5rem;
  border-radius: 5px;
  border: 1px solid transparent;
  cursor: pointer;
  background: transparent;
  color: var(--text-muted);
  transition: all 0.2s ease;
}

.lang-btn:hover {
  color: var(--text-main);
  border-color: var(--glass-border);
}

.lang-btn.active {
  color: var(--accent-cyan);
  border-color: rgba(0, 242, 255, 0.3);
  background: rgba(0, 242, 255, 0.06);
}

.top-nav-cta {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.2s ease;
}

.top-nav-cta:hover {
  color: var(--text-main);
}

.top-nav-progress {
  height: 2px;
  width: 0%;
  background: linear-gradient(90deg, var(--accent-purple), var(--accent-cyan));
  transition: width 0.1s linear;
}

/* Cursor glow */
.cursor-glow {
  position: fixed;
  width: 700px;
  height: 700px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(112, 0, 255, 0.13) 0%, transparent 65%);
  pointer-events: none;
  z-index: 0;
  transform: translate(-50%, -50%);
  left: 50%;
  top: 50%;
  mix-blend-mode: screen;
}

body.light-theme .cursor-glow {
  display: none;
}

/* Hero Evolution */
.hero {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 4rem;
  padding: 7rem 0 5rem;
}

.hero-content {
  display: flex;
  flex-direction: column;
}

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

/* App mockup window */
.app-mockup {
  width: 100%;
  max-width: 400px;
  background: rgba(8, 12, 24, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 20px;
  overflow: hidden;
  box-shadow:
    0 40px 80px rgba(0, 0, 0, 0.6),
    0 0 0 1px rgba(255, 255, 255, 0.04),
    inset 0 1px 0 rgba(255, 255, 255, 0.07);
}

.mockup-bar {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.85rem 1.1rem;
  background: rgba(255, 255, 255, 0.03);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.mockup-dot-red, .mockup-dot-yellow, .mockup-dot-green {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}
.mockup-dot-red    { background: #ff5f57; }
.mockup-dot-yellow { background: #febc2e; }
.mockup-dot-green  { background: #28c840; }

.mockup-title-bar {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.7rem;
  color: rgba(255, 255, 255, 0.3);
  margin: 0 auto;
}

.mockup-chat {
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
}

.chat-msg {
  padding: 0.7rem 1rem;
  border-radius: 14px;
  font-size: 0.88rem;
  max-width: 82%;
  line-height: 1.45;
}

.user-msg {
  background: rgba(112, 0, 255, 0.28);
  border: 1px solid rgba(112, 0, 255, 0.35);
  color: #e2e8f0;
  align-self: flex-end;
  border-bottom-right-radius: 4px;
}

.ai-msg {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.09);
  color: #cbd5e1;
  align-self: flex-start;
  border-bottom-left-radius: 4px;
}

.chat-widget {
  background: rgba(0, 242, 255, 0.06);
  border: 1px solid rgba(0, 242, 255, 0.22);
  border-radius: 16px;
  padding: 1rem 1.1rem;
  align-self: flex-start;
  width: 88%;
}

.widget-pack-tag {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.68rem;
  color: var(--accent-cyan);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 0.65rem;
  display: block;
}

.widget-body {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.widget-temp {
  font-size: 2.2rem;
  font-weight: 800;
  color: #f1f5f9;
  line-height: 1;
}

.widget-details {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.widget-city {
  font-size: 0.85rem;
  font-weight: 600;
  color: #e2e8f0;
}

.widget-cond {
  font-size: 0.75rem;
  color: #94a3b8;
}

.mockup-input-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 0.65rem 0.9rem;
  margin-top: 0.25rem;
}

.mockup-placeholder {
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.22);
}

.mockup-send-btn {
  width: 26px;
  height: 26px;
  background: var(--accent-purple);
  border-radius: 7px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.82rem;
  color: #fff;
  font-weight: 700;
}

/* Floating pack chips */
.floating-chip {
  position: absolute;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.7rem;
  padding: 0.38rem 0.85rem;
  border-radius: 999px;
  backdrop-filter: blur(12px);
  white-space: nowrap;
  user-select: none;
  pointer-events: none;
}

.chip-1 {
  top: -0.75rem;
  right: -1.5rem;
  background: rgba(112, 0, 255, 0.18);
  border: 1px solid rgba(112, 0, 255, 0.35);
  color: #c4b5fd;
}

.chip-2 {
  bottom: 3rem;
  left: -2rem;
  background: rgba(0, 242, 255, 0.1);
  border: 1px solid rgba(0, 242, 255, 0.28);
  color: #67e8f9;
}

.chip-3 {
  bottom: -0.5rem;
  right: 1rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: rgba(255, 255, 255, 0.55);
}

@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; }
  .hero-visual { display: none; }
}

.hero h1 {
  font-size: clamp(3rem, 8vw, 7rem);
  font-weight: 800;
  letter-spacing: -0.06em;
  line-height: 0.9;
  margin-bottom: 2rem;
  background: var(--hero-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero .summary {
  font-size: 1.5rem;
  color: var(--text-muted);
  max-width: 700px;
  margin-bottom: 3rem;
  font-weight: 300;
}

.hero-actions {
  display: flex;
  gap: 1.5rem;
}

.btn {
  padding: 1.25rem 2.5rem;
  border-radius: 10px;
  font-weight: 600;
  text-decoration: none;
  font-size: 1.1rem;
  transition: all 0.4s cubic-bezier(0.19, 1, 0.22, 1);
}

.btn-primary {
  background: var(--text-main);
  color: var(--bg-dark);
}

body.light-theme .btn-primary {
  background: var(--accent-purple);
  color: #fff;
}

.btn-secondary {
  border: 1px solid var(--glass-border);
  color: var(--text-main);
  backdrop-filter: blur(10px);
}

.btn:hover {
  transform: translateY(-5px);
  filter: brightness(1.2);
}

/* Section Grid */
.section {
  padding: 10rem 0;
  border-top: 1px solid var(--glass-border);
}

.comparison-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  perspective: 1000px;
}

.detail-card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  padding: 3rem;
  border-radius: 24px;
}

.panel-label {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.8rem;
  text-transform: uppercase;
  color: var(--accent-purple);
  margin-bottom: 1.5rem;
  display: block;
}

.bullet-list {
  list-style: none;
}

.bullet-list li {
  margin-bottom: 1rem;
  padding-left: 1.5rem;
  position: relative;
  color: var(--text-main);
  opacity: 0.75;
}

.bullet-list li::before {
  content: "→";
  position: absolute;
  left: 0;
}

/* Bad card — muted red tint */
.card-bad {
  background: rgba(239, 68, 68, 0.04);
  border-color: rgba(239, 68, 68, 0.2);
}

.panel-label-bad {
  color: #f87171;
}

.bullet-list-bad li::before {
  color: #f87171;
}

/* Good card — cyan/green tint */
.card-good {
  background: rgba(0, 242, 255, 0.04);
  border-color: rgba(0, 242, 255, 0.3);
}

.panel-label-good {
  color: var(--accent-cyan);
}

.bullet-list-good li {
  opacity: 1;
}

.bullet-list-good li::before {
  color: var(--accent-cyan);
}

body.light-theme .card-bad {
  background: rgba(239, 68, 68, 0.05);
  border-color: rgba(239, 68, 68, 0.25);
}

body.light-theme .card-good {
  background: rgba(29, 78, 216, 0.05);
  border-color: rgba(29, 78, 216, 0.25);
}

body.light-theme .panel-label-good {
  color: #1d4ed8;
}

body.light-theme .bullet-list-good li::before {
  color: #1d4ed8;
}

/* Comparison Table */
.comparison-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--glass-bg);
  border-radius: 24px;
  overflow: hidden;
  border: 1px solid var(--glass-border);
}

.comparison-row {
  display: grid;
  grid-template-columns: 1fr 1fr 1.5fr 1fr;
  padding: 2rem;
  border-bottom: 1px solid var(--glass-border);
}

.comparison-head {
  font-weight: 700;
  font-size: 1.1rem;
  background: rgba(255,255,255,0.05);
}

body.light-theme .comparison-head {
  background: rgba(0,0,0,0.06);
}

.comparison-highlight {
  background: linear-gradient(90deg, rgba(112, 0, 255, 0.1), transparent);
  color: var(--accent-cyan);
}

body.light-theme .comparison-highlight {
  background: #1d4ed8;
  color: #ffffff;
}

body.light-theme .comparison-table {
  background: #ffffff;
  box-shadow: 0 4px 24px rgba(0,0,0,0.08);
}

body.light-theme .comparison-head {
  background: #f8fafc;
  color: #0f172a;
}

body.light-theme .comparison-row {
  border-bottom-color: rgba(0,0,0,0.08);
}

body.light-theme .detail-card {
  background: #ffffff;
  box-shadow: 0 2px 16px rgba(0,0,0,0.07);
}

body.light-theme .try-step {
  background: #ffffff;
  box-shadow: 0 2px 12px rgba(0,0,0,0.07);
}

.technical-card {
  background: rgba(0,0,0,0.5);
}

body.light-theme .technical-card {
  background: #ffffff;
  border-color: rgba(0,0,0,0.1);
}

body.light-theme .try-section::before {
  background: none;
}

body.light-theme .pwa-card {
  background: #ffffff;
  box-shadow: 0 2px 16px rgba(0,0,0,0.07);
}

/* Hero icon */
.hero-icon {
  width: 72px;
  height: 72px;
  border-radius: 20px;
  margin-bottom: 1.5rem;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
  display: block;
  transition: box-shadow 0.3s ease;
}

body.light-theme .hero-icon {
  box-shadow: 0 8px 32px rgba(15, 23, 42, 0.15);
}

/* PWA Showcase */
.pwa-showcase {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
  justify-content: center;
  margin: 1rem 0;
}

.pwa-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 20px;
  padding: 1.5rem 1.75rem;
  backdrop-filter: blur(10px);
  transition: transform 0.3s ease, border-color 0.3s ease;
}

.pwa-card:hover {
  transform: translateY(-4px);
  border-color: rgba(0, 242, 255, 0.3);
}

.pwa-icon-img {
  border-radius: 16px;
  object-fit: cover;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.35);
  transition: box-shadow 0.3s ease;
}

body.light-theme .pwa-icon-img {
  box-shadow: 0 4px 16px rgba(15, 23, 42, 0.12);
}

.pwa-icon-img.large  { width: 80px; height: 80px; }
.pwa-icon-img.medium { width: 64px; height: 64px; }

.pwa-maskable-wrap {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.35);
}

.pwa-maskable-wrap .pwa-icon-img {
  border-radius: 0;
  box-shadow: none;
  width: 100%;
  height: 100%;
}

.pwa-icon-label {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.75rem;
  color: var(--accent-cyan);
  margin-top: 0.25rem;
}

.pwa-icon-type {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.try-motion-accent {
  position: relative;
  width: min(100%, 30rem);
  margin: 1.5rem auto 0;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background:
    radial-gradient(circle at 18% 20%, rgba(112, 0, 255, 0.22), transparent 28%),
    radial-gradient(circle at 78% 24%, rgba(0, 242, 255, 0.18), transparent 25%),
    rgba(4, 8, 20, 0.84);
  box-shadow:
    0 26px 54px rgba(0, 0, 0, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

body.light-theme .try-motion-accent {
  background:
    radial-gradient(circle at 18% 20%, rgba(29, 78, 216, 0.14), transparent 28%),
    radial-gradient(circle at 78% 24%, rgba(14, 165, 233, 0.12), transparent 25%),
    rgba(255, 255, 255, 0.92);
  border-color: rgba(15, 23, 42, 0.08);
}

.try-motion-video {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.try-motion-overlay {
  position: absolute;
  inset: auto 0 0 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.1rem;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0), rgba(2, 6, 23, 0.84));
}

.try-motion-kicker,
.try-motion-label {
  font-family: 'IBM Plex Mono', monospace;
  letter-spacing: 0.08em;
}

.try-motion-kicker {
  font-size: 0.68rem;
  text-transform: uppercase;
  color: rgba(248, 250, 252, 0.9);
}

.try-motion-label {
  font-size: 0.62rem;
  color: var(--accent-cyan);
}

body.light-theme .try-motion-overlay {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0), rgba(255, 255, 255, 0.94));
}

body.light-theme .try-motion-kicker {
  color: #0f172a;
}

/* Build Flow Diagram */
.build-flow {
  display: flex;
  align-items: center;
  gap: 0;
  flex-wrap: wrap;
  justify-content: center;
}

.flow-node {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.5rem;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 20px;
  padding: 1.75rem 2rem;
  min-width: 160px;
  backdrop-filter: blur(10px);
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.flow-node:hover {
  border-color: rgba(0, 242, 255, 0.35);
  box-shadow: 0 0 24px rgba(0, 242, 255, 0.08);
}

.flow-node-final {
  border-color: rgba(0, 242, 255, 0.3);
  background: rgba(0, 242, 255, 0.04);
}

.flow-icon {
  font-size: 1.75rem;
  line-height: 1;
}

.flow-name {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-main);
}

.flow-desc {
  font-size: 0.72rem;
  color: var(--text-muted);
  max-width: 140px;
  line-height: 1.4;
}

.flow-arrow {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  padding: 0 0.5rem;
  min-width: 80px;
  flex-shrink: 0;
}

.flow-arrow-line {
  height: 2px;
  width: 100%;
  background: linear-gradient(90deg, rgba(112, 0, 255, 0.5), rgba(0, 242, 255, 0.5));
  border-radius: 2px;
  position: relative;
}

.flow-arrow-line::after {
  content: '';
  position: absolute;
  right: -1px;
  top: 50%;
  transform: translateY(-50%);
  border-left: 7px solid rgba(0, 242, 255, 0.6);
  border-top: 5px solid transparent;
  border-bottom: 5px solid transparent;
}

.flow-arrow-label {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.62rem;
  color: var(--accent-purple);
  white-space: nowrap;
}

.flow-outputs {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  padding: 1.25rem 1.5rem;
  min-width: 240px;
}

.flow-output {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.72rem;
  color: var(--text-muted);
  opacity: 0;
}

.fo-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-cyan);
  flex-shrink: 0;
}

body.light-theme .flow-outputs {
  background: #f8fafc;
  border-color: rgba(0,0,0,0.1);
}

body.light-theme .flow-output {
  color: #475569;
}

@media (max-width: 900px) {
  .build-flow { flex-direction: column; }
  .flow-arrow { transform: rotate(90deg); min-width: 48px; }
  .flow-arrow-label { display: none; }
}

/* Try Today Section */
.try-section {
  text-align: center;
  position: relative;
  overflow: hidden;
}

.try-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 50%, rgba(112, 0, 255, 0.12) 0%, transparent 70%);
  pointer-events: none;
}

.try-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
}

.try-badge {
  display: inline-block;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--accent-cyan);
  border: 1px solid rgba(0, 242, 255, 0.3);
  padding: 0.4rem 1rem;
  border-radius: 999px;
  background: rgba(0, 242, 255, 0.05);
}

.try-heading {
  font-size: clamp(3.5rem, 10vw, 8rem);
  font-weight: 800;
  letter-spacing: -0.05em;
  line-height: 0.95;
  background: linear-gradient(135deg, #fff 30%, var(--accent-cyan) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 0;
}

body.light-theme .try-heading {
  background: linear-gradient(135deg, #0f172a 30%, var(--accent-cyan) 100%);
  -webkit-background-clip: text;
  background-clip: text;
}

.try-sub {
  font-size: clamp(1.1rem, 2.5vw, 1.5rem);
  color: var(--text-muted);
  max-width: 600px;
  font-weight: 300;
  line-height: 1.6;
}

.try-terminal {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  background: rgba(0, 0, 0, 0.6);
  border: 1px solid var(--glass-border);
  border-radius: 12px;
  padding: 1.1rem 2rem;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 1rem;
  backdrop-filter: blur(10px);
  min-width: 360px;
}

.terminal-prompt {
  color: var(--accent-cyan);
  font-weight: 700;
  user-select: none;
}

.terminal-text {
  color: #e2e8f0;
}

body.light-theme .try-terminal {
  background: #1e293b;
  border-color: rgba(0,0,0,0.2);
}

body.light-theme .btn-secondary {
  background: rgba(255,255,255,0.7);
  border-color: rgba(0,0,0,0.2);
}

.terminal-cursor {
  color: var(--accent-cyan);
  animation: blink 1s step-end infinite;
}

@keyframes blink {
  50% { opacity: 0; }
}

.try-actions {
  display: flex;
  gap: 1.25rem;
  flex-wrap: wrap;
  justify-content: center;
}

.try-btn {
  display: flex;
  align-items: center;
}

.try-steps {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-top: 1rem;
  flex-wrap: wrap;
  justify-content: center;
}

.try-step {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  padding: 0.85rem 1.5rem;
  border-radius: 12px;
  backdrop-filter: blur(10px);
}

.step-num {
  width: 26px;
  height: 26px;
  background: var(--accent-purple);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}

.step-label {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.try-step-arrow {
  color: var(--accent-cyan);
  font-size: 1.25rem;
  font-weight: 700;
}

.docs-section {
  position: relative;
}

.docs-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  padding: 2rem;
  border-radius: 24px;
  background:
    radial-gradient(circle at top right, rgba(0, 242, 255, 0.12), transparent 32%),
    radial-gradient(circle at bottom left, rgba(112, 0, 255, 0.16), transparent 28%),
    rgba(255, 255, 255, 0.03);
  border: 1px solid var(--glass-border);
  box-shadow:
    0 24px 50px rgba(0, 0, 0, 0.22),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(14px);
}

body.light-theme .docs-card {
  background:
    radial-gradient(circle at top right, rgba(29, 78, 216, 0.08), transparent 32%),
    radial-gradient(circle at bottom left, rgba(14, 165, 233, 0.08), transparent 28%),
    #ffffff;
  box-shadow: 0 8px 28px rgba(15, 23, 42, 0.08);
}

.docs-card-copy {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  max-width: 42rem;
}

.docs-url {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  color: var(--accent-cyan);
}

.docs-note {
  font-size: 1rem;
  color: var(--text-muted);
  line-height: 1.6;
}

.docs-btn {
  flex-shrink: 0;
}

/* Utils */
.reveal {
  opacity: 0;
  transform: translateY(40px);
}

/* Hidden Game */
.game-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(0, 0, 0, 0.96);
  backdrop-filter: blur(24px);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease;
}

.game-overlay.active {
  opacity: 1;
  pointer-events: all;
}

.game-modal {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  position: relative;
}

.game-header {
  width: 600px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: 'IBM Plex Mono', monospace;
}

.game-title {
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  color: var(--accent-cyan);
}

.game-stats {
  display: flex;
  gap: 1.5rem;
  font-size: 0.72rem;
  color: #64748b;
}

.game-stats span span {
  color: #f8fafc;
  font-weight: 700;
}

#game-canvas {
  border: 1px solid rgba(0, 242, 255, 0.15);
  border-radius: 10px;
  display: block;
  background: #000;
}

.game-footer {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.62rem;
  color: rgba(255, 255, 255, 0.2);
  letter-spacing: 0.08em;
}

.game-message {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-family: 'IBM Plex Mono', monospace;
  font-size: 2rem;
  font-weight: 700;
  text-align: center;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.3s ease;
  text-shadow: 0 0 30px currentColor;
}

@media (max-width: 900px) {
  .comparison-grid { grid-template-columns: 1fr; }
  .comparison-row { grid-template-columns: 1fr; gap: 1rem; }
  .floating-nav { display: none; }
  .hero { grid-template-columns: 1fr; padding: 6rem 0 4rem; }
  .hero-visual { display: none; }
  .hero h1 { font-size: clamp(2.8rem, 10vw, 5rem); }
  .hero-actions {
    flex-direction: column;
    align-items: flex-start;
  }
  .try-motion-overlay {
    flex-direction: column;
    align-items: flex-start;
  }
  .docs-card {
    flex-direction: column;
    align-items: flex-start;
  }
}
