/* ── Variables ── */
:root {
  --bg: #0a0a0a;
  --surface: #141414;
  --card: #1a1a1a;
  --border: #2a2a2a;
  --border-hover: #3a3a3a;
  --text-primary: #ffffff;
  --text-secondary: #888888;
  --text-muted: #555555;
  --accent: #00e676;
  --accent-dim: #00c864;
  --shadow: 0 8px 32px rgba(0,0,0,0.5);
  --shadow-sm: 0 2px 12px rgba(0,0,0,0.3);
  --radius: 16px;
  --radius-sm: 10px;
  --radius-xs: 8px;
  --transition: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="light"] {
  --bg: #f0f0f0;
  --surface: #ffffff;
  --card: #f7f7f7;
  --border: #e0e0e0;
  --border-hover: #c0c0c0;
  --text-primary: #111111;
  --text-secondary: #555555;
  --text-muted: #aaaaaa;
  --accent: #00d46a;
  --accent-dim: #00b857;
  --shadow: 0 8px 32px rgba(0,0,0,0.12);
  --shadow-sm: 0 2px 12px rgba(0,0,0,0.08);
}

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

body {
  background: var(--bg);
  color: var(--text-primary);
  font-family: 'Inter', 'Noto Sans KR', system-ui, sans-serif;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  transition: background var(--transition), color var(--transition);
}

/* ── Navigation ── */
.nav {
  width: 100%;
  padding: 18px 0 14px;
  display: flex;
  justify-content: center;
  position: sticky;
  top: 0;
  z-index: 200;
  background: var(--bg);
}

.nav-inner {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-link {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  padding: 8px 18px;
  border-radius: var(--radius-xs);
  transition: color var(--transition);
  cursor: pointer;
}

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

.nav-dropdown {
  position: relative;
}

.dropdown-menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%) translateY(6px);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 8px 0;
  min-width: 200px;
  box-shadow: var(--shadow);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
  z-index: 300;
}

.nav-dropdown:hover .dropdown-menu,
.nav-dropdown.open .dropdown-menu {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
  pointer-events: auto;
}

.dropdown-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 20px;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: background var(--transition), color var(--transition);
}

.dropdown-item:hover {
  background: var(--card);
  color: var(--text-primary);
}

.dropdown-item svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  opacity: 0.6;
}

.dropdown-item:hover svg {
  opacity: 1;
}

/* ── Hero ── */
.hero {
  text-align: center;
  padding: 80px 24px 60px;
  max-width: 700px;
}

.hero-icon {
  width: 56px;
  height: 56px;
  background: rgba(0, 230, 118, 0.08);
  border: 1px solid rgba(0, 230, 118, 0.2);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 28px;
  color: var(--accent);
}

.hero-title {
  font-size: clamp(36px, 6vw, 52px);
  font-weight: 900;
  letter-spacing: -1.5px;
  line-height: 1.1;
  margin-bottom: 16px;
}

.hero-subtitle {
  font-size: 16px;
  line-height: 1.7;
  color: var(--text-secondary);
  max-width: 540px;
  margin: 0 auto;
}

/* ── Feature Cards ── */
.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  padding: 0 24px 120px;
  max-width: 1100px;
  width: 100%;
}

.feature-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0 28px 28px;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: border-color var(--transition), transform var(--transition);
}

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

/* Glow effect at the top */
.card-glow {
  position: absolute;
  top: -40px;
  right: -20px;
  width: 180px;
  height: 120px;
  border-radius: 50%;
  filter: blur(50px);
  opacity: 0.15;
  pointer-events: none;
  transition: opacity 0.4s ease;
}

.feature-card:hover .card-glow {
  opacity: 0.25;
}

[data-accent="green"] .card-glow  { background: #00e676; }
[data-accent="orange"] .card-glow { background: #ff9800; }
[data-accent="cyan"] .card-glow   { background: #00bcd4; }

/* Card icon */
.card-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 28px 0 20px;
}

.card-icon svg {
  width: 22px;
  height: 22px;
}

.card-icon.green  { background: rgba(0,230,118,0.1); color: #00e676; border: 1px solid rgba(0,230,118,0.2); }
.card-icon.orange { background: rgba(255,152,0,0.1); color: #ff9800; border: 1px solid rgba(255,152,0,0.2); }
.card-icon.cyan   { background: rgba(0,188,212,0.1); color: #00bcd4; border: 1px solid rgba(0,188,212,0.2); }

[data-theme="light"] .card-icon.green  { background: rgba(0,212,106,0.1); color: #00b857; border-color: rgba(0,212,106,0.25); }
[data-theme="light"] .card-icon.orange { background: rgba(255,152,0,0.1); color: #e68a00; border-color: rgba(255,152,0,0.25); }
[data-theme="light"] .card-icon.cyan   { background: rgba(0,188,212,0.1); color: #00838f; border-color: rgba(0,188,212,0.25); }

.card-title {
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.3px;
  margin-bottom: 8px;
}

.card-desc {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-secondary);
  flex: 1;
  margin-bottom: 24px;
}

.card-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 14px 0;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  color: #000;
  transition: filter var(--transition), transform var(--transition);
}

.card-btn:hover {
  filter: brightness(1.1);
  transform: translateY(-1px);
}

.card-btn.green  { background: #00e676; color: #000; }
.card-btn.orange { background: #ff9800; color: #000; }
.card-btn.cyan   { background: #00bcd4; color: #000; }

[data-theme="light"] .card-btn.green  { background: #00d46a; color: #fff; }
[data-theme="light"] .card-btn.orange { background: #f57c00; color: #fff; }
[data-theme="light"] .card-btn.cyan   { background: #0097a7; color: #fff; }

/* ── Floating Buttons ── */
.float-btn {
  position: fixed;
  bottom: 24px;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-secondary);
  font-size: 20px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-sm);
  transition: border-color var(--transition), transform var(--transition), box-shadow var(--transition);
  z-index: 100;
}

.float-btn:hover {
  border-color: var(--accent);
  transform: scale(1.08);
  box-shadow: 0 4px 20px rgba(0,0,0,0.3);
}

#theme-btn { right: 20px; }
#lang-btn  { left: 20px; }

/* ── Language Panel ── */
.lang-panel {
  position: fixed;
  bottom: 78px;
  left: 20px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  box-shadow: var(--shadow);
  min-width: 160px;
  opacity: 0;
  transform: translateY(10px) scale(0.95);
  pointer-events: none;
  transition: opacity 0.22s ease, transform 0.22s ease;
  transform-origin: bottom left;
  z-index: 101;
}

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

.lang-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 16px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  cursor: pointer;
  transition: background var(--transition), color var(--transition);
  border: none;
  background: none;
  width: 100%;
  text-align: left;
  white-space: nowrap;
}

.lang-option:hover { background: rgba(255,255,255,0.03); color: var(--text-primary); }
[data-theme="light"] .lang-option:hover { background: rgba(0,0,0,0.03); }
.lang-option.active { color: var(--accent); font-weight: 700; }

.lang-flag { font-size: 16px; flex-shrink: 0; }

/* ── Responsive ── */
@media (max-width: 840px) {
  .cards {
    grid-template-columns: 1fr;
    max-width: 480px;
  }

  .hero { padding: 60px 20px 40px; }
}

@media (max-width: 540px) {
  .nav-inner { gap: 2px; }
  .nav-link { font-size: 13px; padding: 8px 12px; }
  .hero-title { font-size: 32px; }
}
