:root {
  /* Dark Mode Default */
  --bg-base: #030712;
  --bg-surface: rgba(15, 23, 42, 0.7);
  --bg-surface-hover: rgba(30, 41, 59, 0.85);
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-cyan: rgba(6, 182, 212, 0.35);
  --primary-cyan: #06b6d4;
  --primary-sky: #38bdf8;
  --accent-emerald: #10b981;
  --telegram-blue: #229ed9;
  --text-primary: #f8fafc;
  --text-muted: #94a3b8;
  --text-dim: #64748b;
  --font-khmer: 'Kantumruy Pro', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-tech: 'Orbitron', -apple-system, sans-serif;
  --card-shadow: 0 14px 35px rgba(0, 0, 0, 0.5);
}

/* Light Mode Overrides (Crisp, High-Contrast, Zero Blurry Text) */
[data-theme="light"] {
  --bg-base: #f8fafc;
  --bg-surface: #ffffff;
  --bg-surface-hover: #f1f5f9;
  --border-subtle: #cbd5e1;
  --border-cyan: #0284c7;
  --primary-cyan: #0284c7;
  --primary-sky: #0369a1;
  --accent-emerald: #059669;
  --telegram-blue: #0284c7;
  --text-primary: #090d16;
  --text-muted: #1e293b;
  --text-dim: #475569;
  --card-shadow: 0 10px 30px rgba(0, 0, 0, 0.06);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

html, body {
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
  scroll-behavior: smooth;
}

body {
  background-color: var(--bg-base);
  color: var(--text-primary);
  font-family: var(--font-khmer);
  line-height: 1.65;
  position: relative;
  -webkit-font-smoothing: antialiased;
  transition: background-color 0.25s ease, color 0.25s ease;
  padding-top: 88px;
}

/* Mobile Padding for Floating iOS 27 Dock */
@media (max-width: 768px) {
  body {
    padding-top: 76px;
    padding-bottom: calc(96px + env(safe-area-inset-bottom, 16px));
  }
}

/* Ambient Backdrops */
.ambient-grid {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-image: 
    linear-gradient(to right, rgba(255, 255, 255, 0.02) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
  background-size: 44px 44px;
  pointer-events: none;
  z-index: -2;
}

[data-theme="light"] .ambient-grid {
  background-image: 
    linear-gradient(to right, rgba(0, 0, 0, 0.03) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(0, 0, 0, 0.03) 1px, transparent 1px);
}

.ambient-glow {
  position: fixed;
  width: 500px;
  height: 500px;
  border-radius: 50%;
  filter: blur(140px);
  pointer-events: none;
  z-index: -1;
  opacity: 0.15;
}

[data-theme="light"] .ambient-glow {
  opacity: 0.08;
}

.glow-top {
  top: -150px;
  left: 20%;
  background: #0284c7;
}

.glow-bottom {
  bottom: 5%;
  right: 15%;
  background: #0d9488;
}

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

@media (max-width: 480px) {
  .container {
    padding: 0 16px;
  }
}

/* SVG Helpers */
.svg-icon {
  width: 18px;
  height: 18px;
  display: inline-block;
  vertical-align: middle;
  flex-shrink: 0;
}

.svg-icon-large {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}

/* iOS 27 Dynamic Island Floating Glass Navbar */
.navbar {
  position: fixed;
  top: 14px;
  left: 50%;
  transform: translateX(-50%);
  width: calc(100% - 28px);
  max-width: 1140px;
  z-index: 1000;
  background: rgba(10, 15, 29, 0.78);
  backdrop-filter: blur(32px) saturate(210%);
  -webkit-backdrop-filter: blur(32px) saturate(210%);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 9999px;
  padding: 10px 22px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.2);
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

[data-theme="light"] .navbar {
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid rgba(0, 0, 0, 0.08);
  box-shadow: 0 14px 35px rgba(0, 0, 0, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.95);
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.brand-group {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  flex-shrink: 0;
}

.brand-icon {
  width: 36px;
  height: 36px;
  border-radius: 9px;
  box-shadow: 0 0 15px rgba(6, 182, 212, 0.35);
}

.brand-text {
  display: flex;
  align-items: baseline;
  gap: 5px;
}

.brand-title {
  font-family: var(--font-tech);
  font-weight: 900;
  font-size: 18px;
  letter-spacing: 0.5px;
  color: var(--text-primary);
}

.brand-tag {
  font-family: var(--font-tech);
  font-size: 10px;
  font-weight: 700;
  color: var(--primary-sky);
  letter-spacing: 1px;
}

.nav-menu {
  display: flex;
  gap: 22px;
}

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

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

.nav-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

/* Theme Toggle */
.theme-toggle-btn {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--primary-sky);
  width: 36px;
  height: 36px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.theme-toggle-btn:hover {
  border-color: var(--border-cyan);
}

[data-theme="light"] .theme-moon {
  display: block;
}

[data-theme="light"] .theme-sun {
  display: none;
}

[data-theme="dark"] .theme-moon {
  display: none;
}

[data-theme="dark"] .theme-sun {
  display: block;
}

/* PWA Install Button */
.btn-pwa-install {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(16, 185, 129, 0.12);
  color: #059669;
  border: 1px solid rgba(16, 185, 129, 0.4);
  padding: 7px 12px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
}

[data-theme="dark"] .btn-pwa-install {
  color: #34d399;
}

.btn-pwa-install:hover {
  background: var(--accent-emerald);
  color: #fff;
}

/* Admin Nav Button */
.btn-admin-nav {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  padding: 7px 12px;
  border-radius: 8px;
  font-size: 12px;
  font-family: var(--font-tech);
  cursor: pointer;
  transition: all 0.2s;
}

.btn-admin-nav:hover {
  color: var(--primary-sky);
  border-color: var(--border-cyan);
}

/* Telegram Nav Button */
.btn-telegram-nav {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(34, 158, 217, 0.12);
  color: var(--telegram-blue);
  border: 1px solid rgba(34, 158, 217, 0.35);
  padding: 7px 14px;
  border-radius: 8px;
  text-decoration: none;
  font-size: 12.5px;
  font-weight: 700;
  transition: all 0.2s;
}

.btn-telegram-nav:hover {
  background: var(--telegram-blue);
  color: #fff;
}

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

.hero-container {
  max-width: 860px;
}

.tech-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(6, 182, 212, 0.08);
  border: 1px solid var(--border-cyan);
  padding: 6px 16px;
  border-radius: 30px;
  margin-bottom: 20px;
}

[data-theme="light"] .tech-badge {
  background: #f1f5f9;
  border-color: #cbd5e1;
}

.pulse-indicator {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent-emerald);
  box-shadow: 0 0 10px var(--accent-emerald);
  animation: pulseLight 1.8s infinite;
}

@keyframes pulseLight {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.3; transform: scale(0.85); }
}

.badge-text {
  font-family: var(--font-tech);
  font-size: 10.5px;
  letter-spacing: 1px;
  color: var(--primary-sky);
  font-weight: 700;
}

.hero-heading {
  font-size: clamp(24px, 5.2vw, 42px);
  font-weight: 700;
  line-height: 1.35;
  margin-bottom: 18px;
  color: var(--text-primary);
}

.glow-gradient {
  background: linear-gradient(135deg, #38bdf8 0%, #06b6d4 50%, #34d399 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

[data-theme="light"] .glow-gradient {
  background: linear-gradient(135deg, #0369a1 0%, #0891b2 50%, #059669 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtext {
  font-size: clamp(13.5px, 2.5vw, 16px);
  color: var(--text-muted);
  line-height: 1.8;
  margin-bottom: 34px;
  max-width: 760px;
  margin-left: auto;
  margin-right: auto;
}

/* Hero CTA Group */
/* Hero VIP Quick Action Banner */
.hero-vip-badge-card {
  position: relative;
  display: block;
  max-width: 820px;
  margin: 0 auto 28px;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.25s ease;
}

.vip-badge-glow {
  position: absolute;
  inset: -2px;
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.4), rgba(6, 182, 212, 0.5), rgba(16, 185, 129, 0.4));
  border-radius: 18px;
  filter: blur(12px);
  opacity: 0.7;
  transition: opacity 0.3s;
}

.hero-vip-badge-card:hover .vip-badge-glow {
  opacity: 1;
}

.hero-vip-badge-card:hover {
  transform: translateY(-2px);
}

.vip-badge-content {
  position: relative;
  background: rgba(15, 23, 42, 0.88);
  border: 1px solid rgba(245, 158, 11, 0.4);
  border-radius: 16px;
  padding: 14px 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  backdrop-filter: blur(20px);
}

.vip-badge-left {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.vip-tag-pill {
  font-family: var(--font-tech);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 1px;
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: #fff;
  padding: 4px 10px;
  border-radius: 20px;
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.4);
}

.vip-main-text {
  font-size: 13.5px;
  font-weight: 700;
  color: #f8fafc;
}

.vip-arrow-btn {
  font-family: var(--font-tech);
  font-size: 11px;
  font-weight: 700;
  color: #38bdf8;
  background: rgba(56, 189, 248, 0.12);
  border: 1px solid rgba(56, 189, 248, 0.35);
  padding: 6px 14px;
  border-radius: 20px;
  transition: all 0.2s;
  white-space: nowrap;
}

.hero-vip-badge-card:hover .vip-arrow-btn {
  background: #38bdf8;
  color: #030712;
}

/* Quick Jump Hero Action Buttons */
.hero-cta-group {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  max-width: 680px;
  margin: 0 auto 36px;
}

.btn-main-cta {
  position: relative;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.25s ease;
  flex: 1 1 290px;
  max-width: 320px;
}

.btn-glow-layer {
  position: absolute;
  inset: -2px;
  background: linear-gradient(135deg, #0284c7, #06b6d4, #10b981);
  border-radius: 14px;
  filter: blur(10px);
  opacity: 0.65;
  transition: opacity 0.3s ease;
}

.btn-content-inner {
  position: relative;
  background: linear-gradient(135deg, #0284c7, #0891b2);
  color: #fff;
  padding: 13px 22px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  gap: 14px;
  height: 100%;
}

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

.btn-main-cta:hover .btn-glow-layer {
  opacity: 0.95;
}

.btn-secondary-cta {
  background: rgba(15, 23, 42, 0.8);
  border: 1px solid var(--border-cyan);
  color: #fff;
  padding: 13px 22px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  backdrop-filter: blur(10px);
  transition: all 0.25s ease;
  flex: 1 1 290px;
  max-width: 320px;
}

.btn-secondary-cta:hover {
  background: rgba(6, 182, 212, 0.15);
  border-color: var(--primary-cyan);
  box-shadow: 0 0 25px rgba(6, 182, 212, 0.35);
  transform: translateY(-2px);
}

.btn-telegram-cta {
  background: rgba(15, 23, 42, 0.8);
  border: 1px solid rgba(168, 85, 247, 0.4);
  color: #fff;
  padding: 13px 28px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  backdrop-filter: blur(10px);
  transition: all 0.25s ease;
  width: auto;
  min-width: 290px;
}

.btn-telegram-cta:hover {
  background: rgba(168, 85, 247, 0.15);
  border-color: #c084fc;
  box-shadow: 0 0 25px rgba(168, 85, 247, 0.35);
  transform: translateY(-2px);
}

/* Hide desktop-only controls on mobile */
@media (max-width: 768px) {
  .btn-desktop-only {
    display: none !important;
  }
}

.btn-texts {
  display: flex;
  flex-direction: column;
  text-align: left;
}

.label-top {
  font-size: 10px;
  font-family: var(--font-tech);
  letter-spacing: 0.5px;
  color: var(--text-dim);
}

.btn-content-inner .label-top {
  color: rgba(255, 255, 255, 0.85);
}

.label-main {
  font-size: 14px;
  font-weight: 700;
}

/* Metrics Grid */
.metrics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 14px;
  margin-top: 20px;
}

.metric-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 14px;
  padding: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: var(--card-shadow);
  transition: border-color 0.25s ease;
}

.metric-card:hover {
  border-color: var(--border-cyan);
}

.metric-icon-box {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: rgba(6, 182, 212, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary-sky);
  flex-shrink: 0;
}

.metric-svg {
  width: 20px;
  height: 20px;
}

.metric-body {
  display: flex;
  flex-direction: column;
  text-align: left;
}

.metric-value {
  font-family: var(--font-tech);
  font-size: 17px;
  font-weight: 800;
  color: var(--primary-sky);
}

.metric-label {
  font-size: 11.5px;
  color: var(--text-muted);
  font-weight: 600;
}

/* Content Sections */
.content-section, section[id] {
  padding: 70px 0;
  scroll-margin-top: 96px;
}

.section-title-wrap {
  text-align: center;
  max-width: 680px;
  margin: 0 auto 40px;
}

.section-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-family: var(--font-tech);
  font-size: 10.5px;
  letter-spacing: 1.5px;
  color: var(--primary-sky);
  margin-bottom: 8px;
  font-weight: 700;
}

.pill-svg {
  width: 14px;
  height: 14px;
}

.section-title {
  font-size: clamp(22px, 4vw, 32px);
  font-weight: 700;
  margin-bottom: 10px;
  color: var(--text-primary);
}

.section-subtitle {
  font-size: 13.5px;
  color: var(--text-muted);
  line-height: 1.7;
}

/* V2Box Generator Section */
.v2box-section-wrap {
  background: linear-gradient(180deg, transparent, rgba(6, 182, 212, 0.03), transparent);
}

.v2box-card {
  position: relative;
  background: var(--bg-surface);
  border: 1px solid var(--border-cyan);
  border-radius: 20px;
  padding: 32px 24px;
  backdrop-filter: blur(14px);
  max-width: 820px;
  margin: 0 auto;
  box-shadow: var(--card-shadow);
}

.v2box-glow {
  position: absolute;
  top: 0;
  left: 20%;
  right: 20%;
  height: 2px;
  background: linear-gradient(90deg, transparent, #38bdf8, transparent);
}

.input-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
  margin-bottom: 20px;
}

.input-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  text-align: left;
}

.input-group label {
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 700;
}

.styled-select, .styled-input {
  background: rgba(15, 23, 42, 0.65);
  color: var(--text-primary);
  border: 1px solid var(--border-subtle);
  padding: 11px 14px;
  border-radius: 10px;
  font-family: var(--font-khmer);
  font-size: 13px;
  outline: none;
  transition: border-color 0.2s;
}

[data-theme="light"] .styled-select,
[data-theme="light"] .styled-input {
  background: #f8fafc;
  color: #090d16;
  border: 1px solid #cbd5e1;
}

.styled-select:focus, .styled-input:focus {
  border-color: var(--primary-cyan);
}

.btn-generate {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  background: linear-gradient(135deg, #0284c7, #0891b2);
  color: #fff;
  border: none;
  padding: 13px;
  border-radius: 12px;
  font-size: 14.5px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(6, 182, 212, 0.3);
  transition: all 0.25s ease;
}

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

.v2-result-box {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px dashed var(--border-subtle);
}

.license-banner {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(16, 185, 129, 0.12);
  color: #059669;
  border: 1px solid rgba(16, 185, 129, 0.35);
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 700;
  margin-bottom: 18px;
}

[data-theme="dark"] .license-banner {
  color: #34d399;
}

.qr-code-row {
  display: flex;
  gap: 20px;
  align-items: center;
  flex-wrap: wrap;
}

.qr-canvas {
  background: #fff;
  padding: 8px;
  border-radius: 12px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
  margin: 0 auto;
}

.v2-actions-col {
  flex: 1;
  min-width: 260px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  text-align: left;
}

.qr-instruction {
  font-size: 12.5px;
  color: var(--text-muted);
  line-height: 1.6;
}

.link-input-wrap {
  display: flex;
  gap: 8px;
}

.link-code {
  flex: 1;
  font-family: monospace;
  font-size: 11px;
}

.btn-copy {
  background: var(--bg-surface-hover);
  color: var(--primary-sky);
  border: 1px solid var(--border-cyan);
  padding: 0 14px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 700;
  transition: all 0.2s;
  white-space: nowrap;
}

.btn-copy:hover {
  background: var(--primary-cyan);
  color: #fff;
}

.btn-v2box-direct {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: rgba(6, 182, 212, 0.12);
  color: var(--primary-sky);
  border: 1px solid var(--border-cyan);
  padding: 11px;
  border-radius: 10px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 700;
  transition: all 0.2s;
}

.btn-v2box-direct:hover {
  background: var(--primary-sky);
  color: #fff;
}

/* Platforms Grid (Mobile & PC) */
.platforms-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(290px, 1fr));
  gap: 22px;
}

.platform-card {
  position: relative;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 18px;
  padding: 28px 22px;
  box-shadow: var(--card-shadow);
  display: flex;
  flex-direction: column;
  transition: all 0.3s ease;
}

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

.platform-card.featured-platform {
  border-color: rgba(6, 182, 212, 0.45);
}

.featured-glow {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, #38bdf8, transparent);
}

.platform-icon-circle {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.05);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary-sky);
  margin-bottom: 14px;
  border: 1px solid var(--border-subtle);
}

[data-theme="light"] .platform-icon-circle {
  background: #f1f5f9;
}

.platform-icon-circle.highlight-circle {
  background: rgba(6, 182, 212, 0.15);
  border-color: var(--border-cyan);
  color: #fff;
}

[data-theme="light"] .platform-icon-circle.highlight-circle {
  background: #0284c7;
  color: #fff;
}

.platform-svg {
  width: 24px;
  height: 24px;
}

.platform-tag {
  font-family: var(--font-tech);
  font-size: 10px;
  letter-spacing: 1.5px;
  color: var(--primary-sky);
  margin-bottom: 6px;
  font-weight: 700;
}

.platform-title {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 10px;
  color: var(--text-primary);
}

.platform-desc {
  font-size: 13.5px;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 18px;
}

.platform-features {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 24px;
  flex-grow: 1;
}

.platform-features li {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  font-size: 13px;
  color: var(--text-muted);
}

.platform-features li strong {
  color: var(--text-primary);
}

.check-svg {
  width: 16px;
  height: 16px;
  color: var(--accent-emerald);
  flex-shrink: 0;
  margin-top: 3px;
}

.platform-action {
  margin-top: auto;
}

.platform-actions-double {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.btn-platform-action {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: linear-gradient(135deg, #0284c7, #0891b2);
  color: #fff;
  padding: 11px 18px;
  border-radius: 10px;
  text-decoration: none;
  font-size: 13.5px;
  font-weight: 700;
  transition: all 0.25s ease;
}

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

.btn-platform-secondary {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--bg-surface-hover);
  border: 1px solid var(--border-cyan);
  color: var(--primary-sky);
  padding: 11px 18px;
  border-radius: 10px;
  text-decoration: none;
  font-size: 13.5px;
  font-weight: 700;
  transition: all 0.25s ease;
}

.btn-platform-secondary:hover {
  background: var(--primary-sky);
  color: #fff;
  transform: translateY(-2px);
}

/* Nodes Grid */
.nodes-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(290px, 1fr));
  gap: 18px;
}

.node-card {
  position: relative;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 16px;
  padding: 22px;
  box-shadow: var(--card-shadow);
  transition: all 0.25s ease;
}

.node-card:hover {
  transform: translateY(-3px);
  border-color: var(--border-cyan);
}

.node-card.featured-node {
  border-color: rgba(6, 182, 212, 0.45);
}

.node-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 12px;
}

.node-identity {
  display: flex;
  align-items: center;
  gap: 10px;
}

.node-symbol-box {
  width: 38px;
  height: 38px;
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.05);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary-sky);
  border: 1px solid var(--border-subtle);
  flex-shrink: 0;
}

[data-theme="light"] .node-symbol-box {
  background: #f1f5f9;
}

.node-svg {
  width: 18px;
  height: 18px;
}

.node-name {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
}

.node-routing {
  font-size: 11px;
  color: var(--text-dim);
}

.status-indicator {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 8px;
  border-radius: 20px;
  font-family: var(--font-tech);
  font-size: 9.5px;
  font-weight: 700;
}

.status-indicator.online {
  background: rgba(16, 185, 129, 0.12);
  color: #059669;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

[data-theme="dark"] .status-indicator.online {
  color: #34d399;
}

.status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-emerald);
}

.node-description {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.65;
  margin-bottom: 16px;
}

.node-stats-row {
  display: flex;
  justify-content: space-between;
  border-top: 1px solid var(--border-subtle);
  padding-top: 12px;
}

.stat-unit {
  display: flex;
  flex-direction: column;
}

.stat-title {
  font-size: 11px;
  color: var(--text-dim);
}

.stat-highlight {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--primary-sky);
  font-family: var(--font-tech);
}

.text-right {
  text-align: right;
}

/* Telegram Support Banner */
.telegram-banner-card {
  position: relative;
  background: linear-gradient(135deg, rgba(34, 158, 217, 0.1), rgba(15, 23, 42, 0.8));
  border: 1px solid rgba(34, 158, 217, 0.4);
  border-radius: 18px;
  padding: 30px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
  box-shadow: var(--card-shadow);
}

[data-theme="light"] .telegram-banner-card {
  background: linear-gradient(135deg, rgba(34, 158, 217, 0.08), rgba(241, 245, 249, 0.95));
  border-color: #cbd5e1;
}

.tg-glow {
  position: absolute;
  top: 0;
  left: 10%;
  width: 80%;
  height: 1px;
  background: linear-gradient(90deg, transparent, #229ed9, transparent);
}

.tg-content {
  max-width: 580px;
}

.tg-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--telegram-blue);
  font-family: var(--font-tech);
  font-size: 10px;
  letter-spacing: 1.2px;
  font-weight: 700;
  margin-bottom: 8px;
}

.tg-badge-svg {
  width: 15px;
  height: 15px;
}

.tg-title {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 6px;
  color: var(--text-primary);
}

.tg-desc {
  font-size: 13.5px;
  color: var(--text-muted);
  line-height: 1.7;
}

.btn-telegram-large {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--telegram-blue);
  color: #fff;
  border: none;
  padding: 12px 24px;
  border-radius: 11px;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  box-shadow: 0 6px 20px rgba(34, 158, 217, 0.4);
  transition: all 0.25s ease;
}

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

.tg-btn-svg {
  width: 20px;
  height: 20px;
}

/* Footer */
.footer-wrap {
  border-top: 1px solid var(--border-subtle);
  background: #020408;
  padding: 50px 0 20px;
  margin-top: 50px;
}

[data-theme="light"] .footer-wrap {
  background: #ffffff;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--border-subtle);
}

.footer-quote {
  margin-top: 8px;
  font-size: 12.5px;
  color: var(--text-dim);
}

.footer-contact-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--primary-sky);
  text-decoration: none;
  font-size: 13px;
  font-weight: 700;
  padding: 8px 14px;
  border-radius: 8px;
  border: 1px solid var(--border-subtle);
}

.footer-contact-link:hover {
  border-color: var(--border-cyan);
}

.footer-svg {
  width: 16px;
  height: 16px;
}

.footer-bottom-line {
  padding-top: 18px;
  text-align: center;
}

.copyright-text {
  font-family: var(--font-tech);
  font-size: 10.5px;
  color: var(--text-dim);
  letter-spacing: 0.5px;
}

/* Admin Modal */
.admin-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(14px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.admin-modal-overlay.hidden {
  display: none !important;
}

.admin-modal-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-cyan);
  border-radius: 18px;
  width: 100%;
  max-width: 740px;
  max-height: 88vh;
  overflow-y: auto;
  padding: 24px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
}

.admin-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border-subtle);
  margin-bottom: 18px;
}

.admin-title-row {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--primary-sky);
}

.admin-title-row h3 {
  font-family: var(--font-tech);
  font-size: 14px;
  letter-spacing: 0.5px;
}

.btn-close-modal {
  background: none;
  border: none;
  color: var(--text-dim);
  font-size: 24px;
  cursor: pointer;
}

.admin-auth-box {
  text-align: center;
  padding: 24px 10px;
}

.admin-auth-prompt {
  font-size: 13.5px;
  color: var(--text-muted);
}

.pin-row {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin: 16px auto;
  max-width: 340px;
}

.error-msg {
  color: #ef4444;
  font-size: 12px;
}

.admin-stats-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}

.stat-box {
  background: var(--bg-surface-hover);
  border: 1px solid var(--border-subtle);
  padding: 14px;
  border-radius: 11px;
  text-align: center;
}

.stat-number {
  font-family: var(--font-tech);
  font-size: 22px;
  font-weight: 800;
  color: var(--primary-sky);
  display: block;
}

.stat-caption {
  font-size: 11px;
  color: var(--text-dim);
}

.admin-section {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--border-subtle);
}

.admin-section h4 {
  font-size: 13.5px;
  margin-bottom: 10px;
  color: var(--primary-sky);
}

.admin-form-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.btn-primary-action {
  background: linear-gradient(135deg, #0284c7, #06b6d4);
  color: #fff;
  border: none;
  padding: 9px 16px;
  border-radius: 8px;
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
}

.table-wrap {
  overflow-x: auto;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}

.admin-table th, .admin-table td {
  padding: 9px 10px;
  text-align: left;
  border-bottom: 1px solid var(--border-subtle);
}

.admin-table th {
  color: var(--text-dim);
  font-family: var(--font-tech);
  font-size: 10px;
}

.badge-plan {
  background: rgba(6, 182, 212, 0.15);
  color: var(--primary-sky);
  padding: 2px 7px;
  border-radius: 4px;
  font-size: 10.5px;
  font-weight: 700;
}

.status-active {
  color: var(--accent-emerald);
  font-weight: 700;
}

.btn-revoke {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.3);
  padding: 3px 7px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 10px;
}

/* Floating AI Assistant Widget */
.ai-widget {
  position: fixed;
  bottom: 24px;
  right: 20px;
  z-index: 1500;
}

@media (max-width: 1024px) {
  .ai-widget > .ai-toggle-btn {
    display: none !important;
  }
}

.ai-toggle-btn {
  position: relative;
  background: linear-gradient(135deg, #0284c7, #0891b2);
  color: #fff;
  border: none;
  padding: 10px 16px;
  border-radius: 30px;
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  box-shadow: 0 6px 25px rgba(6, 182, 212, 0.4);
  font-family: var(--font-tech);
  font-size: 12px;
  font-weight: 700;
  transition: transform 0.2s ease;
}

.ai-toggle-btn:hover {
  transform: scale(1.05);
}

.ai-glow-ring {
  position: absolute;
  inset: -3px;
  border-radius: 34px;
  background: linear-gradient(135deg, #0284c7, #10b981);
  filter: blur(6px);
  opacity: 0.6;
  z-index: -1;
  animation: pulseLight 2s infinite;
}

.ai-icon {
  width: 18px;
  height: 18px;
}

.ai-drawer {
  position: fixed;
  bottom: 80px;
  right: 20px;
  width: 360px;
  max-width: calc(100vw - 32px);
  height: 490px;
  max-height: calc(100vh - 120px);
  background: var(--bg-surface);
  border: 1px solid var(--border-cyan);
  border-radius: 18px;
  backdrop-filter: blur(18px);
  display: flex;
  flex-direction: column;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
  transform: translateY(20px) scale(0.95);
  opacity: 0;
  pointer-events: none;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 1600;
}

.ai-drawer.open {
  transform: translateY(0) scale(1);
  opacity: 1;
  pointer-events: auto;
}

.ai-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border-subtle);
}

.ai-title-group {
  display: flex;
  align-items: center;
  gap: 8px;
}

.ai-avatar-circle {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(6, 182, 212, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary-sky);
}

.ai-title-group h4 {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text-primary);
}

.ai-status-online {
  font-size: 9.5px;
  color: var(--accent-emerald);
}

.btn-ai-close {
  background: none;
  border: none;
  color: var(--text-dim);
  font-size: 22px;
  cursor: pointer;
}

.ai-chips-scroll {
  display: flex;
  gap: 6px;
  padding: 8px 14px;
  overflow-x: auto;
  border-bottom: 1px solid var(--border-subtle);
  scrollbar-width: none;
}

.ai-chips-scroll::-webkit-scrollbar {
  display: none;
}

.ai-chip {
  background: var(--bg-surface-hover);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  padding: 5px 11px;
  border-radius: 14px;
  font-size: 11px;
  white-space: nowrap;
  cursor: pointer;
  transition: all 0.2s;
  font-family: var(--font-khmer);
}

.ai-chip:hover {
  color: var(--primary-sky);
  border-color: var(--border-cyan);
}

.ai-chat-body {
  flex: 1;
  padding: 14px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.ai-msg {
  display: flex;
}

.msg-user {
  justify-content: flex-end;
}

.msg-user .msg-bubble {
  background: linear-gradient(135deg, #0284c7, #06b6d4);
  color: #fff;
  border-radius: 14px 14px 2px 14px;
}

.msg-bot {
  justify-content: flex-start;
}

.msg-bot .msg-bubble {
  background: var(--bg-surface-hover);
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  border-radius: 14px 14px 14px 2px;
}

.msg-bubble {
  max-width: 86%;
  padding: 9px 12px;
  font-size: 12px;
  line-height: 1.6;
  white-space: pre-line;
}

.ai-input-bar {
  display: flex;
  gap: 6px;
  padding: 10px 14px;
  border-top: 1px solid var(--border-subtle);
}

.ai-input-bar input {
  flex: 1;
  font-size: 12px;
  padding: 7px 10px;
}

.btn-ai-send {
  background: var(--primary-cyan);
  color: #fff;
  border: none;
  width: 34px;
  height: 34px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

/* iOS 27 Native Floating Glass Dock (Screens < 768px) */
.mobile-bottom-bar {
  display: none;
  position: fixed;
  bottom: calc(12px + env(safe-area-inset-bottom, 6px));
  left: 14px;
  right: 14px;
  margin: 0 auto;
  max-width: 480px;
  height: 64px;
  background: rgba(10, 15, 29, 0.82);
  backdrop-filter: blur(36px) saturate(220%);
  -webkit-backdrop-filter: blur(36px) saturate(220%);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 36px;
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.22);
  z-index: 1400;
  justify-content: space-around;
  align-items: center;
  padding: 0 8px;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

[data-theme="light"] .mobile-bottom-bar {
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(0, 0, 0, 0.1);
  box-shadow: 0 14px 35px rgba(0, 0, 0, 0.1), inset 0 1px 0 rgba(255, 255, 255, 0.95);
}

.mobile-nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  background: none;
  border: none;
  color: var(--text-dim);
  text-decoration: none;
  font-size: 10.5px;
  font-weight: 700;
  cursor: pointer;
  padding: 6px 12px;
  border-radius: 20px;
  transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
  position: relative;
}

.mobile-nav-item:active {
  transform: scale(0.88);
}

.mobile-nav-item.active {
  color: #38bdf8;
  background: rgba(56, 189, 248, 0.14);
}

[data-theme="light"] .mobile-nav-item.active {
  color: #0284c7;
  background: rgba(2, 132, 199, 0.12);
}

.mobile-nav-item:hover {
  color: var(--primary-sky);
}

.mobile-nav-svg {
  width: 20px;
  height: 20px;
}

.mobile-ai-nav {
  color: var(--primary-cyan);
}

/* Responsive Breakpoints */
@media (max-width: 768px) {
  .nav-menu {
    display: none;
  }
  .btn-text-hide-mobile {
    display: none;
  }
  .mobile-bottom-bar {
    display: flex;
  }
  .ai-toggle-btn {
    display: none !important;
  }
  .hero-cta-group {
    flex-direction: column;
  }
  .btn-main-cta, .btn-secondary-cta, .btn-telegram-cta {
    width: 100%;
    justify-content: center;
  }
  .telegram-banner-card {
    flex-direction: column;
    text-align: center;
  }
  .btn-telegram-large {
    width: 100%;
    justify-content: center;
  }
  .ai-drawer {
    right: 12px;
    bottom: 84px;
    width: calc(100vw - 24px);
    height: 460px;
    border-radius: 24px;
  }
}

@media (min-width: 769px) and (max-width: 1024px) {
  /* iPad / Tablet */
  .container {
    padding: 0 24px;
  }
  .platforms-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Google Auth Navbar Pill */
.user-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  padding: 4px 10px;
  border-radius: 30px;
}

.user-avatar-img {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 1px solid var(--border-cyan);
}

.user-info-text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
  text-align: left;
}

.user-name {
  font-size: 11.5px;
  font-weight: 700;
  color: var(--text-primary);
  max-width: 100px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.user-plan-badge {
  font-size: 9px;
  color: var(--accent-emerald);
  font-weight: 700;
}

.btn-logout {
  background: none;
  border: none;
  color: var(--text-dim);
  cursor: pointer;
  display: flex;
  align-items: center;
  padding: 2px;
  transition: color 0.2s;
}

.btn-logout:hover {
  color: #ef4444;
}

.btn-google-sign {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: #fff;
  color: #0f172a;
  border: 1px solid #cbd5e1;
  padding: 6px 12px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  transition: all 0.2s;
}

.btn-google-sign:hover {
  background: #f8fafc;
  transform: translateY(-1px);
}

/* Google Auth Modal Gate */
.auth-gate-card {
  position: relative;
  background: var(--bg-surface);
  border: 1px solid var(--border-cyan);
  border-radius: 20px;
  max-width: 440px;
  width: 100%;
  padding: 34px 28px;
  text-align: center;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(20px);
}

.auth-gate-icon {
  margin-bottom: 14px;
}

.auth-gate-title {
  font-family: var(--font-tech);
  font-size: 18px;
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: 0.5px;
  margin-bottom: 8px;
}

.auth-gate-desc {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.65;
  margin-bottom: 22px;
}

.auth-gate-inputs {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.btn-google-login-action {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: #ffffff;
  color: #0f172a;
  border: 1px solid #cbd5e1;
  padding: 12px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.12);
  transition: all 0.2s;
}

.btn-google-login-action:hover {
  background: #f1f5f9;
  transform: translateY(-2px);
}

.auth-gate-footer {
  margin-top: 18px;
  font-size: 11px;
  color: var(--text-dim);
  line-height: 1.5;
}

/* Pricing Grid & Cards */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
}

.pricing-card {
  position: relative;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 18px;
  padding: 28px 20px;
  box-shadow: var(--card-shadow);
  display: flex;
  flex-direction: column;
  text-align: left;
  transition: all 0.3s ease;
}

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

.pricing-card.popular-plan {
  border-color: var(--primary-cyan);
  background: linear-gradient(180deg, rgba(6, 182, 212, 0.08), var(--bg-surface));
}

.pricing-card.vip-year-plan {
  border-color: #f59e0b;
  background: linear-gradient(180deg, rgba(245, 158, 11, 0.08), var(--bg-surface));
}

.popular-ribbon, .vip-ribbon {
  position: absolute;
  top: 14px;
  right: 14px;
  font-family: var(--font-tech);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.8px;
  padding: 4px 10px;
  border-radius: 20px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.35);
  z-index: 2;
}

.popular-ribbon {
  background: linear-gradient(135deg, #0284c7, #06b6d4);
  color: #fff;
}

.vip-ribbon {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: #000;
}

.pricing-duration {
  font-family: var(--font-tech);
  font-size: 12px;
  font-weight: 800;
  color: var(--primary-sky);
  letter-spacing: 1px;
  margin-bottom: 8px;
  display: block;
}

.pricing-price-wrap {
  display: flex;
  align-items: baseline;
  gap: 2px;
  margin-bottom: 8px;
}

.currency {
  font-family: var(--font-tech);
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
}

.price-val {
  font-family: var(--font-tech);
  font-size: 34px;
  font-weight: 900;
  color: var(--text-primary);
  line-height: 1;
}

.price-period {
  font-size: 12px;
  color: var(--text-dim);
}

.pricing-desc {
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 18px;
  min-height: 38px;
}

.pricing-perks {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 24px;
  flex-grow: 1;
}

.pricing-perks li {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 12.5px;
  color: var(--text-muted);
  line-height: 1.5;
}

.btn-buy-plan {
  width: 100%;
  background: var(--bg-surface-hover);
  border: 1px solid var(--border-cyan);
  color: var(--primary-sky);
  padding: 11px;
  border-radius: 10px;
  font-size: 13.5px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  text-align: center;
}

.btn-buy-plan:hover {
  background: var(--primary-cyan);
  color: #fff;
  transform: translateY(-2px);
}

.btn-buy-plan.btn-glow-btn {
  background: linear-gradient(135deg, #0284c7, #06b6d4);
  color: #fff;
  border: none;
}

.btn-buy-plan.btn-vip-gold {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: #000;
  border: none;
}

/* Bakong KHQR Modal */
.khqr-modal-card {
  position: relative;
  background: var(--bg-surface);
  border: 1px solid var(--border-cyan);
  border-radius: 20px;
  max-width: 420px;
  width: 100%;
  padding: 26px 20px;
  text-align: center;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(20px);
}

.payment-loading-box {
  padding: 40px 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  font-size: 13.5px;
  color: var(--text-muted);
}

.spinner-pulse {
  width: 44px;
  height: 44px;
  border: 3px solid rgba(6, 182, 212, 0.2);
  border-top-color: var(--primary-cyan);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.bakong-brand-row {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-bottom: 6px;
}

.bakong-tag {
  background: #e11d48;
  color: #fff;
  font-family: var(--font-tech);
  font-size: 10px;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 4px;
  letter-spacing: 0.5px;
}

.merchant-badge {
  background: rgba(255, 255, 255, 0.08);
  font-size: 10.5px;
  padding: 2px 8px;
  border-radius: 4px;
  color: var(--text-dim);
}

.khqr-plan-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.khqr-amount-display {
  font-family: var(--font-tech);
  font-size: 26px;
  font-weight: 900;
  color: var(--primary-sky);
  margin-bottom: 4px;
}

.bill-label {
  font-size: 11px;
  color: var(--text-dim);
}

.khqr-frame-wrap {
  margin: 16px auto;
  padding: 8px;
  background: #fff;
  border-radius: 12px;
  display: inline-block;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

.khqr-real-img {
  width: 200px;
  height: 200px;
  display: block;
}

.payment-status-pill {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: rgba(6, 182, 212, 0.08);
  border: 1px solid var(--border-cyan);
  padding: 8px 12px;
  border-radius: 20px;
  font-size: 11px;
  color: var(--primary-sky);
  font-weight: 600;
  margin-bottom: 14px;
}

.btn-open-bakong {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: linear-gradient(135deg, #e11d48, #be123c);
  color: #fff;
  padding: 12px;
  border-radius: 10px;
  text-decoration: none;
  font-size: 13.5px;
  font-weight: 700;
  box-shadow: 0 4px 15px rgba(225, 29, 72, 0.35);
  transition: all 0.2s;
}

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

/* Payment Success State */
.payment-success-box {
  padding: 20px 10px;
  text-align: center;
}

.success-icon-circle {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: rgba(16, 185, 129, 0.15);
  border: 2px solid #10b981;
  color: #34d399;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
  box-shadow: 0 0 30px rgba(16, 185, 129, 0.4);
}

.success-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.success-subtitle {
  font-size: 12.5px;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 20px;
}

.license-unlocked-card {
  background: var(--bg-surface-hover);
  border: 1px solid var(--border-cyan);
  border-radius: 12px;
  padding: 14px;
  margin-bottom: 20px;
  text-align: center;
}

.license-label {
  font-family: var(--font-tech);
  font-size: 10px;
  letter-spacing: 1px;
  color: var(--primary-sky);
  display: block;
  margin-bottom: 4px;
}

.license-key-val {
  font-family: monospace;
  font-size: 15px;
  font-weight: 800;
  color: #34d399;
  display: block;
  margin-bottom: 4px;
}

.license-expiry-val {
  font-size: 11.5px;
  color: var(--text-muted);
}

.admin-hidden-trigger {
  color: var(--text-dim);
  text-decoration: none;
  font-size: 10px;
  margin-left: 6px;
  opacity: 0.4;
  transition: opacity 0.2s;
  display: inline-flex;
  align-items: center;
}

.admin-hidden-trigger:hover {
  opacity: 1;
}

/* Google Identity Services SDK Render Target & Separator */
.gsi-slot-container {
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 14px 0 16px;
  min-height: 44px;
}

.gsi-render-target {
  display: flex;
  justify-content: center;
}

.auth-separator-row {
  display: flex;
  align-items: center;
  text-align: center;
  color: var(--text-dim);
  font-size: 11px;
  margin: 14px 0 18px;
}

.auth-separator-row::before,
.auth-separator-row::after {
  content: "";
  flex: 1;
  border-bottom: 1px solid var(--border-subtle);
}

.auth-separator-row span {
  padding: 0 10px;
  font-weight: 600;
}

.auth-client-id-info {
  font-family: var(--font-tech);
  font-size: 9px;
  color: var(--primary-sky);
  margin-bottom: 4px;
  letter-spacing: 0.5px;
  word-break: break-all;
}

/* V2Box Plan Status Banner & Latency Badge */
.v2-plan-status-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px 18px;
  border-radius: 14px;
  margin-bottom: 22px;
  flex-wrap: wrap;
  transition: all 0.3s ease;
}

.v2-plan-status-box.free-trial {
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 158, 11, 0.4);
  color: #fbbf24;
}

.v2-plan-status-box.vip-active {
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.4);
  color: #34d399;
}

.status-icon-wrap {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.08);
  flex-shrink: 0;
}

.status-info-text {
  display: flex;
  flex-direction: column;
  flex: 1;
  text-align: left;
  line-height: 1.4;
}

.status-info-text strong {
  font-size: 13.5px;
  letter-spacing: 0.3px;
}

.status-info-text span {
  font-size: 11.5px;
  opacity: 0.85;
}

.btn-upgrade-plan-pill {
  display: inline-flex;
  align-items: center;
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: #fff;
  text-decoration: none;
  font-size: 11.5px;
  font-weight: 700;
  padding: 6px 14px;
  border-radius: 20px;
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
  transition: transform 0.2s;
  white-space: nowrap;
}

.btn-upgrade-plan-pill:hover {
  transform: translateY(-1px);
}

.v2-latency-pill {
  font-family: var(--font-tech);
  font-size: 10px;
  color: #10b981;
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.3);
  padding: 4px 10px;
  border-radius: 12px;
  font-weight: 700;
  letter-spacing: 0.5px;
}

.qr-frame-sleek {
  padding: 8px;
  background: #ffffff;
  border-radius: 14px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
  border: 2px solid var(--border-cyan);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* Mobile & Tablet App Responsive Polish */
@media (max-width: 768px) {
  body {
    padding-bottom: calc(78px + env(safe-area-inset-bottom, 12px));
  }
  .hero-cta-group {
    flex-direction: column;
    width: 100%;
    gap: 12px;
    margin-bottom: 24px;
  }
  .btn-main-cta, .btn-secondary-cta, .btn-telegram-cta {
    width: 100%;
    max-width: 100%;
    min-height: 54px;
  }
  .link-input-wrap {
    flex-direction: column;
    gap: 10px;
  }
  .btn-copy {
    width: 100%;
    height: 44px;
  }
  .btn-v2box-direct {
    width: 100%;
    height: 48px;
  }
  .pricing-grid {
    grid-template-columns: 1fr;
    gap: 18px;
  }
  .pricing-card {
    width: 100%;
  }
  .btn-pricing-action {
    width: 100%;
    min-height: 46px;
  }
  /* Hide the floating helper button on mobile screens so it never covers buttons; user taps bottom bar "AI ជំនួយ" */
  .ai-widget > .ai-toggle-btn {
    display: none !important;
  }
  .ai-drawer {
    right: 12px;
    left: 12px;
    width: calc(100vw - 24px);
    bottom: calc(66px + env(safe-area-inset-bottom, 12px));
    height: 460px;
  }
}

@media (max-width: 480px) {
  body {
    padding-bottom: calc(84px + env(safe-area-inset-bottom, 14px));
  }
  .container {
    padding: 0 14px;
  }
  .hero-heading {
    font-size: 20px;
    line-height: 1.35;
  }
  .hero-subtext {
    font-size: 12.5px;
  }
  .nav-container {
    padding: 0 12px;
    height: 56px;
  }
  .brand-group {
    gap: 7px;
  }
  .brand-icon {
    width: 30px;
    height: 30px;
  }
  .brand-title {
    font-size: 15px;
  }
  .brand-tag {
    font-size: 8.5px;
  }
  .nav-actions {
    gap: 6px;
  }
  .theme-toggle-btn {
    width: 32px;
    height: 32px;
  }
  .btn-telegram-nav {
    padding: 6px 10px;
    font-size: 11px;
  }
  .user-pill {
    padding: 2px;
    gap: 0;
    border: none;
    background: transparent;
    cursor: pointer;
  }
  .user-name, .user-plan-badge, .btn-logout {
    display: none !important;
  }
  .user-avatar-img {
    width: 32px;
    height: 32px;
    border: 2px solid var(--primary-cyan);
    box-shadow: 0 0 12px rgba(6, 182, 212, 0.4);
  }
  .btn-pwa-install {
    display: none !important;
  }
  .auth-gate-card {
    padding: 24px 16px;
    width: calc(100vw - 28px);
    margin: 14px;
  }
  .khqr-modal-card {
    padding: 22px 16px;
    width: calc(100vw - 28px);
    margin: 14px;
  }
}

/* Light Mode High-Contrast Super-Sharp Readability */
[data-theme="light"] body {
  color: #090d16;
  background: #f8fafc;
}

[data-theme="light"] .brand-title {
  color: #090d16;
}

[data-theme="light"] .hero-title,
[data-theme="light"] .section-title,
[data-theme="light"] .platform-title,
[data-theme="light"] .pricing-title,
[data-theme="light"] .auth-gate-title,
[data-theme="light"] .khqr-plan-title {
  color: #090d16 !important;
  font-weight: 800;
}

[data-theme="light"] .hero-subtext,
[data-theme="light"] .section-desc,
[data-theme="light"] .auth-gate-desc,
[data-theme="light"] .platform-feature-desc,
[data-theme="light"] .pricing-desc {
  color: #1e293b !important;
  font-weight: 500;
}

[data-theme="light"] .metric-card {
  background: #ffffff;
  border-color: #cbd5e1;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.04);
}

[data-theme="light"] .metric-value {
  color: #0284c7 !important;
}

[data-theme="light"] .metric-label {
  color: #334155 !important;
}

[data-theme="light"] .tech-badge .badge-text {
  color: #0284c7 !important;
  font-weight: 700;
}

[data-theme="light"] .code-box,
[data-theme="light"] .v2box-code-block {
  background: #f1f5f9 !important;
  border-color: #cbd5e1 !important;
  color: #0f172a !important;
}

[data-theme="light"] .btn-secondary-cta {
  background: #ffffff;
  border-color: #0284c7;
  color: #0f172a;
}

[data-theme="light"] .btn-telegram-cta {
  background: #ffffff;
  border-color: #cbd5e1;
  color: #0f172a;
}

[data-theme="light"] .btn-telegram-cta:hover {
  border-color: #0284c7;
  color: #0284c7;
}

[data-theme="light"] .pricing-card {
  background: #ffffff;
  border-color: #cbd5e1;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}

[data-theme="light"] .pricing-card.popular-plan {
  background: linear-gradient(180deg, #f0fdfa 0%, #ffffff 100%);
  border-color: #0284c7;
}

[data-theme="light"] .pricing-card.vip-year-plan {
  background: linear-gradient(180deg, #fffbeb 0%, #ffffff 100%);
  border-color: #f59e0b;
}

[data-theme="light"] .pricing-price {
  color: #090d16 !important;
}

[data-theme="light"] .pricing-features li {
  color: #1e293b !important;
}

[data-theme="light"] .v2box-notice {
  background: #f1f5f9;
  border-color: #cbd5e1;
  color: #1e293b;
}

[data-theme="light"] .v2box-card {
  background: #ffffff;
  border-color: #cbd5e1;
}

[data-theme="light"] .node-card {
  background: #ffffff;
  border-color: #cbd5e1;
}

[data-theme="light"] .node-title {
  color: #090d16;
}

[data-theme="light"] .node-desc {
  color: #1e293b;
}

[data-theme="light"] .auth-gate-card {
  background: #ffffff;
  border-color: #cbd5e1;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
}

/* ============================================================
   iOS 27 Version 27 Liquid Glass & Spatial UI/UX Design System
   ============================================================ */

/* 1. Dynamic Island Live Status Capsule */
.ios-dynamic-island {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  background: rgba(0, 0, 0, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 9999px;
  padding: 6px 16px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(28px) saturate(200%);
  -webkit-backdrop-filter: blur(28px) saturate(200%);
  margin-bottom: 24px;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  cursor: default;
}

.ios-dynamic-island:hover {
  transform: scale(1.02);
  border-color: rgba(56, 189, 248, 0.45);
  box-shadow: 0 14px 38px rgba(6, 182, 212, 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

[data-theme="light"] .ios-dynamic-island {
  background: rgba(255, 255, 255, 0.9);
  border-color: rgba(0, 0, 0, 0.12);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06), inset 0 1px 0 rgba(255, 255, 255, 1);
}

.island-left {
  display: flex;
  align-items: center;
  gap: 8px;
}

.island-pulse-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 12px #10b981;
  animation: iosPulse 2s infinite ease-in-out;
}

@keyframes iosPulse {
  0%, 100% {
    transform: scale(1);
    opacity: 1;
    box-shadow: 0 0 12px #10b981;
  }
  50% {
    transform: scale(1.3);
    opacity: 0.7;
    box-shadow: 0 0 18px #10b981;
  }
}

.island-brand {
  font-family: var(--font-tech);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 1px;
  color: #f8fafc;
}

[data-theme="light"] .island-brand {
  color: #090d16;
}

.island-pill-divider {
  width: 1px;
  height: 14px;
  background: rgba(255, 255, 255, 0.16);
}

[data-theme="light"] .island-pill-divider {
  background: rgba(0, 0, 0, 0.12);
}

.island-center {
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-tech);
  font-size: 11.5px;
  font-weight: 700;
  color: #38bdf8;
}

[data-theme="light"] .island-center {
  color: #0284c7;
}

.island-svg {
  width: 14px;
  height: 14px;
}

.island-status-tag {
  font-family: var(--font-tech);
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: 0.8px;
  padding: 3px 9px;
  border-radius: 9999px;
  background: rgba(16, 185, 129, 0.18);
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.35);
}

/* 2. iOS 27 Glass Segmented Controls */
.hidden-select {
  display: none !important;
}

.ios-segmented-control {
  display: flex;
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
  padding: 4px;
  gap: 4px;
  margin-bottom: 12px;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

[data-theme="light"] .ios-segmented-control {
  background: #e2e8f0;
  border-color: #cbd5e1;
}

.ios-segment-btn {
  flex: 1;
  padding: 9px 14px;
  border-radius: 10px;
  background: transparent;
  border: 1px solid transparent;
  color: var(--text-muted);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.ios-segment-btn:hover {
  color: #f8fafc;
  background: rgba(255, 255, 255, 0.05);
}

[data-theme="light"] .ios-segment-btn:hover {
  color: #090d16;
  background: rgba(255, 255, 255, 0.6);
}

.ios-segment-btn.active {
  background: linear-gradient(135deg, rgba(6, 182, 212, 0.4) 0%, rgba(56, 189, 248, 0.25) 100%), rgba(255, 255, 255, 0.12);
  border-color: rgba(56, 189, 248, 0.5);
  color: #ffffff !important;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.35);
  transform: translateY(-1px);
}

[data-theme="light"] .ios-segment-btn.active {
  background: #ffffff;
  border-color: #0284c7;
  color: #0284c7 !important;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.08);
}

.ios-segment-btn:active {
  transform: scale(0.96);
}

/* 3. iOS 27 Sheet Grabber Handle & Modals */
.ios-sheet-grabber {
  width: 42px;
  height: 5px;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.28);
  margin: 6px auto 16px;
  display: block;
}

[data-theme="light"] .ios-sheet-grabber {
  background: rgba(0, 0, 0, 0.2);
}

.modal-overlay {
  backdrop-filter: blur(28px) saturate(180%);
  -webkit-backdrop-filter: blur(28px) saturate(180%);
}

.modal-card {
  border-radius: 28px;
  animation: iosSheetSpring 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes iosSheetSpring {
  0% {
    opacity: 0;
    transform: scale(0.92) translateY(24px);
  }
  100% {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

/* 4. iOS 27 Haptic Press Physics */
button:active,
.btn-main-cta:active,
.btn-secondary-cta:active,
.pricing-btn:active,
.v2-generate-btn:active,
.btn-telegram-nav:active,
.theme-toggle-btn:active,
.mobile-nav-item:active {
  transform: scale(0.96);
  transition: transform 0.1s ease;
}

/* 5. Mobile Dynamic Island & Segmented Control Adjustments */
@media (max-width: 640px) {
  .ios-dynamic-island {
    gap: 8px;
    padding: 5px 12px;
    margin-bottom: 18px;
  }
  .island-brand {
    font-size: 10px;
  }
  .island-center {
    font-size: 10.5px;
  }
  .island-status-tag {
    font-size: 8.5px;
    padding: 2px 7px;
  }
  .ios-segment-btn {
    padding: 8px 10px;
    font-size: 12px;
  }
}

/* Light Theme overrides for SSH Details Card */
[data-theme="light"] .ssh-details-card {
  background: #f1f5f9 !important;
  border-color: #cbd5e1 !important;
}

[data-theme="light"] .ssh-details-card div {
  color: #1e293b !important;
}

[data-theme="light"] .ssh-details-card strong {
  color: #090d16 !important;
}



