/* ===== RESET & BASE ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --color-bg: #04061A;
  --color-surface: #0D1030;
  --color-primary: #7C3AED;
  --color-accent: #EC4899;
  --color-text: #F1F5F9;
  --color-text-muted: #94A3B8;
  --color-border: rgba(255,255,255,0.08);
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --radius: 16px;
  --container: 1120px;
}

body {
  background: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font);
  line-height: 1.6;
}

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

/* ===== HEADER ===== */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(4,6,26,0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--color-border);
}

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

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--color-text);
  font-weight: 700;
  font-size: 1.1rem;
}

.logo-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: block;
  flex-shrink: 0;
}

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

.nav-links a {
  color: var(--color-text-muted);
  text-decoration: none;
  font-size: 0.95rem;
  transition: color .2s;
}

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

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 22px;
  border-radius: 100px;
  font-weight: 600;
  font-size: 0.9rem;
  text-decoration: none;
  transition: all .2s;
}

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

.btn-primary:hover {
  background: #6D28D9;
  transform: translateY(-1px);
}

/* ===== HERO ===== */
.hero {
  padding: 80px 0 60px;
  overflow: hidden;
}

.hero-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.hero-text h1 {
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 900;
  line-height: 1.1;
  margin-bottom: 20px;
}

.gradient-text {
  background: linear-gradient(135deg, var(--color-primary), var(--color-accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-sub {
  font-size: 1.15rem;
  color: var(--color-text-muted);
  margin-bottom: 36px;
  max-width: 480px;
}

.hero-free {
  margin-top: 14px;
  font-size: 0.85rem;
  color: var(--color-text-muted);
}

.hero-cta {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.store-btn {
  display: inline-block;
  transition: opacity .2s, transform .2s;
}

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

.store-btn img {
  display: block;
}

/* ===== FEATURES ===== */
.features {
  padding: 100px 0;
  background: var(--color-surface);
}

.features h2 {
  text-align: center;
  font-size: 2.2rem;
  font-weight: 800;
  margin-bottom: 12px;
}

.section-sub {
  text-align: center;
  color: var(--color-text-muted);
  margin-bottom: 56px;
}

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

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

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

.feature-icon {
  font-size: 2rem;
  margin-bottom: 16px;
}

.feature-card h3 {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 10px;
}

.feature-card p {
  color: var(--color-text-muted);
  font-size: 0.95rem;
}

/* ===== DOWNLOAD CTA ===== */
.download {
  padding: 100px 0;
  text-align: center;
  background: linear-gradient(135deg, rgba(124,58,237,0.15) 0%, rgba(236,72,153,0.1) 100%);
}

.download-inner h2 {
  font-size: 2.2rem;
  font-weight: 800;
  margin-bottom: 12px;
}

.download-inner p {
  color: var(--color-text-muted);
  margin-bottom: 36px;
}

.store-badges {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ===== FOOTER ===== */
.footer {
  padding: 32px 0;
  border-top: 1px solid var(--color-border);
}

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

.footer p {
  color: var(--color-text-muted);
  font-size: 0.9rem;
}

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

.footer-links a {
  color: var(--color-text-muted);
  font-size: 0.9rem;
  text-decoration: none;
  transition: color .2s;
}

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

/* ===== LANG SWITCHER ===== */
.lang-switcher {
  position: relative;
}

.lang-current {
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(255,255,255,0.06);
  border: 1px solid var(--color-border);
  border-radius: 8px;
  padding: 7px 12px;
  color: var(--color-text);
  font-size: 0.85rem;
  font-weight: 500;
  font-family: var(--font);
  cursor: pointer;
  transition: background .15s, border-color .15s;
  white-space: nowrap;
  line-height: 1;
}

.lang-current:hover {
  background: rgba(255,255,255,0.10);
  border-color: rgba(255,255,255,0.18);
}

.lang-current svg {
  flex-shrink: 0;
  opacity: 0.7;
}

.lang-chevron {
  transition: transform .2s;
}

.lang-current[aria-expanded="true"] .lang-chevron {
  transform: rotate(180deg);
}

.lang-dropdown {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 160px;
  background: #14122a;
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 12px;
  padding: 6px;
  list-style: none;
  z-index: 200;
  box-shadow: 0 16px 40px rgba(0,0,0,0.5), 0 4px 12px rgba(124,58,237,0.15);
  overflow: hidden;
}

.lang-dropdown.open {
  display: block;
  animation: dropIn .15s ease;
}

@keyframes dropIn {
  from { opacity: 0; transform: translateY(-6px); }
  to   { opacity: 1; transform: translateY(0); }
}

.lang-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border-radius: 7px;
  cursor: pointer;
  color: var(--color-text-muted);
  font-size: 0.88rem;
  transition: background .12s, color .12s;
}

.lang-option:hover,
.lang-option:focus {
  background: rgba(124,58,237,0.15);
  color: var(--color-text);
  outline: none;
}

.lang-option.active {
  color: #c084fc;
  font-weight: 600;
}

.lang-flag {
  font-size: 1.1rem;
  line-height: 1;
  flex-shrink: 0;
}

/* ===== HERO VISUAL (app icon + glow) ===== */
.hero-mockup {
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
}

.hero-visual {
  position: relative;
  width: clamp(220px, 40vw, 340px);
  height: clamp(220px, 40vw, 340px);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.hero-glow-ring {
  position: absolute;
  inset: -20px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(124,58,237,0.35) 0%, rgba(236,72,153,0.2) 50%, transparent 70%);
  animation: pulseGlow 3s ease-in-out infinite;
}

@keyframes pulseGlow {
  0%, 100% { opacity: 0.7; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.06); }
}

.hero-app-icon {
  position: relative;
  z-index: 2;
  width: clamp(120px, 26vw, 180px);
  height: clamp(120px, 26vw, 180px);
  border-radius: clamp(28px, 5vw, 40px);
  box-shadow:
    0 0 0 1px rgba(255,255,255,0.08),
    0 20px 60px rgba(124,58,237,0.5),
    0 8px 24px rgba(236,72,153,0.3);
  display: block;
}

/* ===== K-COMMUNITY HIGHLIGHT CARD ===== */
.feature-card--highlight {
  background: linear-gradient(135deg, rgba(124,58,237,0.18) 0%, rgba(236,72,153,0.12) 100%);
  border-color: rgba(124,58,237,0.5);
  grid-column: span 2;
  position: relative;
  overflow: hidden;
}

.feature-card--highlight::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: var(--radius);
  padding: 1px;
  background: linear-gradient(135deg, #7C3AED, #EC4899);
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}

.community-langs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.community-langs span {
  background: rgba(255,255,255,0.07);
  border: 1px solid var(--color-border);
  border-radius: 20px;
  padding: 4px 12px;
  font-size: 0.8rem;
  color: var(--color-text);
  white-space: nowrap;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .hero-inner {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .hero-sub {
    max-width: 100%;
  }
  .hero-cta {
    justify-content: center;
  }
  .hero-mockup {
    display: none;
  }
  .features-grid {
    grid-template-columns: 1fr 1fr;
  }
  .feature-card--highlight {
    grid-column: span 2;
  }
  .footer-inner {
    flex-direction: column;
    text-align: center;
  }
}

@media (max-width: 480px) {
  .features-grid {
    grid-template-columns: 1fr;
  }
  .feature-card--highlight {
    grid-column: span 1;
  }
  .nav-links a:not(.btn):not(.lang-switcher) {
    display: none;
  }
  .lang-dropdown {
    right: auto;
    left: 0;
  }
}
