:root {
  --bg-primary: #090d16;
  --bg-secondary: #0f172a;
  --bg-card: #131b2e;
  --bg-card-hover: #18233c;
  --border-card: rgba(255, 255, 255, 0.08);
  --border-card-hover: rgba(56, 189, 248, 0.35);
  --accent-sky: #38bdf8;
  --accent-indigo: #818cf8;
  --accent-pink: #ff2d75;
  --accent-emerald: #10b981;
  --text-primary: #f8fafc;
  --text-muted: #94a3b8;
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --radius-lg: 16px;
  --radius-xl: 24px;
}

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

body {
  font-family: var(--font-sans);
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* Background Atmosphere */
.ambient-glow {
  position: fixed;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 1000px;
  height: 500px;
  background: radial-gradient(circle, rgba(99, 102, 241, 0.15) 0%, rgba(56, 189, 248, 0.08) 40%, transparent 70%);
  filter: blur(80px);
  pointer-events: none;
  z-index: 0;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  position: relative;
  z-index: 1;
}

/* Header & Navigation */
header {
  position: sticky;
  top: 0;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  background: rgba(9, 13, 22, 0.8);
  border-bottom: 1px solid var(--border-card);
  z-index: 100;
  padding: 16px 0;
}

.nav-wrapper {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand-link {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: #fff;
}

.brand-logo {
  width: 36px;
  height: 36px;
}

.brand-title {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.5px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
}

.nav-link {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
  transition: color 0.2s;
}

.nav-link:hover {
  color: var(--text-primary);
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: 9999px;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  cursor: pointer;
  border: none;
}

.btn-primary {
  background: linear-gradient(135deg, #4f46e5 0%, #0284c7 100%);
  color: #fff;
  box-shadow: 0 4px 18px rgba(79, 70, 229, 0.35);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(79, 70, 229, 0.5);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-card);
  color: var(--text-primary);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}

/* Hero Section */
.hero-section {
  padding: 80px 0 60px;
  text-align: center;
}

.hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(99, 102, 241, 0.12);
  border: 1px solid rgba(129, 140, 248, 0.3);
  color: #a5b4fc;
  padding: 6px 16px;
  border-radius: 9999px;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 24px;
}

.hero-headline {
  font-size: 54px;
  font-weight: 900;
  line-height: 1.15;
  letter-spacing: -1.5px;
  max-width: 860px;
  margin: 0 auto 20px;
  background: linear-gradient(135deg, #ffffff 40%, #bae6fd 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtitle {
  font-size: 19px;
  color: var(--text-muted);
  max-width: 720px;
  margin: 0 auto 36px;
  line-height: 1.6;
}

.hero-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

/* Section Shared Headers */
.section {
  padding: 70px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.section-header {
  text-align: center;
  margin-bottom: 48px;
}

.section-tag {
  display: inline-block;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--accent-sky);
  margin-bottom: 10px;
}

.section-title {
  font-size: 36px;
  font-weight: 800;
  letter-spacing: -0.5px;
  margin-bottom: 12px;
}

.section-subtitle {
  font-size: 16px;
  color: var(--text-muted);
  max-width: 620px;
  margin: 0 auto;
}

/* Section 1: Translation Comparisons (Image Compare FIRST) */
.comparisons-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 50px;
}

@media (min-width: 992px) {
  .comparisons-grid {
    grid-template-columns: 1.2fr 1fr;
    align-items: start;
  }
}

.compare-box {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-xl);
  padding: 24px;
  box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.6);
  position: relative;
}

.compare-badge-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.compare-lang-tag {
  font-size: 13px;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 9999px;
  background: rgba(56, 189, 248, 0.15);
  color: var(--accent-sky);
  border: 1px solid rgba(56, 189, 248, 0.3);
}

.compare-caption {
  font-size: 12px;
  color: var(--text-muted);
}

.compare-caption a {
  color: var(--accent-sky);
  text-decoration: none;
}

/* Interactive Before & After Slider */
.slider-container {
  position: relative;
  width: 100%;
  max-width: 580px;
  margin: 0 auto;
  aspect-ratio: 848 / 1200;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.8);
  user-select: none;
}

.slider-img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
}

.slider-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  width: var(--slider-pos, 50%);
  border-right: 2px solid #fff;
  box-shadow: 2px 0 10px rgba(0, 0, 0, 0.5);
}

.slider-overlay .slider-img {
  width: 100%;
  max-width: none;
  /* Keep inner image fixed width to parent container */
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
}

.slider-handle-line {
  position: absolute;
  top: 0;
  bottom: 0;
  left: var(--slider-pos, 50%);
  width: 2px;
  background: #ffffff;
  pointer-events: none;
  z-index: 10;
}

.slider-handle-circle {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--accent-sky);
  border: 3px solid #ffffff;
  box-shadow: 0 0 20px rgba(56, 189, 248, 0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #090d16;
  font-size: 16px;
  font-weight: 900;
}

.slider-range-input {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: ew-resize;
  z-index: 20;
  margin: 0;
}

.slider-label {
  position: absolute;
  bottom: 14px;
  padding: 4px 12px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  z-index: 15;
  pointer-events: none;
}

.label-left {
  left: 14px;
  background: rgba(15, 23, 42, 0.85);
  color: #bae6fd;
  border: 1px solid rgba(56, 189, 248, 0.4);
}

.label-right {
  right: 14px;
  background: rgba(15, 23, 42, 0.85);
  color: #cbd5e1;
  border: 1px solid #475569;
}

/* Comparison Pair 2: Side-by-Side */
.side-compare-pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.side-compare-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
}

.side-compare-tag {
  position: absolute;
  top: 10px;
  padding: 3px 10px;
  border-radius: 9999px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.5px;
  z-index: 5;
}

.side-compare-col img {
  width: 100%;
  height: auto;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-card);
}

/* Section 2: UI Showcase (Hover Button on TOP) */
.hover-spotlight {
  background: linear-gradient(135deg, rgba(255, 45, 117, 0.08) 0%, rgba(19, 27, 46, 0.9) 100%);
  border: 1px solid rgba(255, 45, 117, 0.25);
  border-radius: var(--radius-xl);
  padding: 40px;
  margin-bottom: 48px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 36px;
  align-items: center;
  box-shadow: 0 20px 45px -15px rgba(255, 45, 117, 0.15);
}

@media (min-width: 860px) {
  .hover-spotlight {
    grid-template-columns: 1.1fr 1fr;
  }
}

.hover-lead-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 45, 117, 0.15);
  border: 1px solid var(--accent-pink);
  color: #ff759f;
  padding: 4px 14px;
  border-radius: 9999px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  margin-bottom: 12px;
}

.hover-spotlight-title {
  font-size: 32px;
  font-weight: 800;
  letter-spacing: -0.5px;
  margin-bottom: 12px;
  line-height: 1.25;
}

.hover-spotlight-desc {
  font-size: 15px;
  color: var(--text-muted);
  margin-bottom: 24px;
  line-height: 1.6;
}

.modes-pills {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.mode-pill {
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid var(--border-card);
  border-radius: 12px;
  padding: 12px 14px;
}

.mode-pill-title {
  font-size: 13px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 4px;
}

.mode-pill-sub {
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.4;
}

.hover-visual-wrap {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.7);
  border: 1px solid rgba(255, 45, 117, 0.3);
}

.hover-visual-wrap img {
  width: 100%;
  height: auto;
  display: block;
}

/* Extension Popup & Settings Side-by-Side */
.extension-panels-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
  margin-bottom: 48px;
}

@media (min-width: 800px) {
  .extension-panels-row {
    grid-template-columns: 1fr 1fr;
  }
}

.panel-card {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-xl);
  padding: 28px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  transition: transform 0.25s, border-color 0.25s;
}

.panel-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-card-hover);
}

.panel-card-img-wrap {
  background: #0b0f19;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  padding: 8px;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.6);
  margin-bottom: 20px;
}

.panel-card-img-wrap img {
  max-height: 440px;
  width: auto;
  max-width: 100%;
  border-radius: 10px;
  display: block;
}

.panel-title {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 6px;
}

.panel-desc {
  font-size: 13px;
  color: var(--text-muted);
}

/* Kites Studio Showcase */
.studio-showcase {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-xl);
  padding: 32px;
  box-shadow: 0 25px 50px -15px rgba(0, 0, 0, 0.8);
}

.studio-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  flex-wrap: wrap;
  gap: 16px;
}

.studio-window-frame {
  background: #0b0f19;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.7);
}

.studio-title-bar {
  background: #1e293b;
  padding: 10px 16px;
  display: flex;
  align-items: center;
  gap: 8px;
  border-bottom: 1px solid #334155;
}

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

.dot-1 { background: #ef4444; }
.dot-2 { background: #f59e0b; }
.dot-3 { background: #10b981; }

.window-text {
  margin-left: 8px;
  font-size: 12px;
  color: #94a3b8;
  font-weight: 600;
}

.studio-window-frame img {
  width: 100%;
  height: auto;
  display: block;
}

/* Architecture Features Grid */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-lg);
  padding: 24px;
  transition: transform 0.25s, border-color 0.25s;
}

.feature-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-card-hover);
}

.feature-icon {
  font-size: 28px;
  margin-bottom: 16px;
  display: inline-block;
}

.feature-title {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 8px;
}

.feature-desc {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.5;
}

/* Footer & Legal */
footer {
  border-top: 1px solid var(--border-card);
  padding: 50px 0 30px;
  background: rgba(9, 13, 22, 0.95);
  margin-top: 60px;
}

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

.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 20px;
}

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

.footer-link {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
  transition: color 0.2s;
}

.footer-link:hover {
  color: var(--accent-sky);
}

.footer-privacy-highlight {
  color: var(--accent-sky) !important;
  font-weight: 700 !important;
}

.footer-bottom {
  text-align: center;
  font-size: 13px;
  color: #64748b;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding-top: 24px;
}
