/* ============================================================
   Flash Keyboard — Site Styles
   Colors, fonts, and layout. Edit text in index.html.
   ============================================================ */

/* ---------- Reset & Base ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg:         #0a0a0b;
  --bg-card:    #18181b;
  --border:     rgba(255,255,255,0.06);
  --border-hover: rgba(255,255,255,0.12);
  --text:       #ffffff;
  --muted:      #a1a1aa;
  --green:      #34C759;
  --blue:       #007AFF;
  --yellow:     #FFD60A;
  --purple:     #5856D6;
  --orange:     #FF9500;
  --gradient:   linear-gradient(135deg, #FFD700 0%, #FF8C00 50%, #FF4B3A 100%);
  --radius:     16px;
  --radius-sm:  10px;
  --container:  1100px;
  --section-gap: 96px;
}

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
p { color: var(--muted); }

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

.gradient-text {
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ---------- Nav ---------- */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  background: rgba(10,10,11,0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
}

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

.nav-logo img { height: 28px; }

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
}

.nav-links a {
  font-size: 14px;
  color: var(--muted);
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--text); }

.nav-cta {
  background: var(--text);
  color: var(--bg) !important;
  font-size: 14px;
  font-weight: 600;
  padding: 8px 18px;
  border-radius: 8px;
  transition: opacity 0.2s;
  white-space: nowrap;
}
.nav-cta:hover { opacity: 0.85; color: var(--bg) !important; }

.nav-hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 4px;
}
.nav-hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform 0.2s, opacity 0.2s;
}

/* ---------- Sections ---------- */
section { padding: var(--section-gap) 0; }

.section-header {
  text-align: center;
  margin-bottom: 56px;
}
.section-header h2 {
  font-size: clamp(32px, 5vw, 48px);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
  margin-bottom: 16px;
}
.section-header p {
  font-size: 18px;
  max-width: 560px;
  margin: 0 auto;
}

/* ---------- Hero ---------- */
#hero {
  padding-top: calc(64px + 56px); /* nav height + breathing room */
  padding-bottom: 64px;
  min-height: 90vh;
  display: flex;
  align-items: center;
}

.hero-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
  width: 100%;
}

.hero-text { display: flex; flex-direction: column; gap: 24px; }

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255,214,10,0.12);
  border: 1px solid rgba(255,214,10,0.2);
  color: var(--yellow);
  font-size: 13px;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 100px;
  width: fit-content;
}

.hero-text h1 {
  font-size: clamp(36px, 5vw, 56px);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
}

.hero-text p {
  font-size: 18px;
  line-height: 1.65;
}

.hero-subline {
  font-size: 13px !important;
  color: var(--muted);
  margin-top: -8px;
}

.hero-actions { display: flex; flex-direction: column; gap: 12px; }

.hero-appstore img { height: 44px; }

.hero-image {
  display: flex;
  justify-content: center;
}
.hero-image img {
  max-height: 580px;
  width: auto;
  border-radius: 24px;
}

/* ---------- Feature Cards ---------- */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 0;
  transition: border-color 0.3s ease;
}
.card:hover { border-color: var(--border-hover); }

.card-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  flex-shrink: 0;
}
.card-icon svg { width: 24px; height: 24px; }

.card h3 {
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin-bottom: 8px;
}
.card p { font-size: 15px; line-height: 1.6; }

/* ---------- How It Works ---------- */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.step {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  text-align: center;
}

.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: rgba(255,255,255,0.06);
  border: 1px solid var(--border-hover);
  border-radius: 50%;
  font-size: 13px;
  font-weight: 700;
  color: var(--muted);
  margin: 0 auto 16px;
}

.step-emoji {
  font-size: 36px;
  margin-bottom: 16px;
}

.step h3 {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 10px;
}

.step p { font-size: 15px; }

/* ---------- Languages ---------- */
.lang-tiers {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 0;
}

.lang-tier {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
}

.lang-tier-label {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 8px;
}

.lang-tier h3 {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 6px;
}

.lang-tier > p {
  font-size: 14px;
  margin-bottom: 24px;
}

.lang-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.lang-pill {
  background: rgba(255,255,255,0.06);
  border: 1px solid var(--border);
  border-radius: 100px;
  padding: 4px 12px;
  font-size: 13px;
  color: var(--muted);
  white-space: nowrap;
}

.lang-more {
  background: rgba(0,122,255,0.1);
  border-color: rgba(0,122,255,0.2);
  color: var(--blue);
}

/* ---------- Pricing ---------- */
#pricing { background: #0d0d0f; }

.pricing-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  max-width: 760px;
  margin: 0 auto;
}

.pricing-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.pricing-card.featured {
  border-color: rgba(255,214,10,0.3);
  background: linear-gradient(180deg, rgba(255,214,10,0.05) 0%, var(--bg-card) 40%);
}

.pricing-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--muted);
  margin-bottom: 8px;
}

.pricing-card.featured .pricing-name {
  color: var(--yellow);
}

.pricing-price {
  font-size: 36px;
  font-weight: 700;
  letter-spacing: -0.03em;
  margin-bottom: 4px;
}

.pricing-price span {
  font-size: 16px;
  font-weight: 400;
  color: var(--muted);
}

.pricing-alt {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 24px;
}

.pricing-badge {
  display: inline-flex;
  background: var(--green);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 4px;
  margin-bottom: 24px;
  width: fit-content;
}

.pricing-divider {
  border: none;
  border-top: 1px solid var(--border);
  margin: 0 0 24px;
}

.pricing-features {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex: 1;
  margin-bottom: 28px;
}

.pricing-features li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 14px;
  color: var(--muted);
}

.pricing-features li::before {
  content: "✓";
  color: var(--green);
  font-weight: 700;
  flex-shrink: 0;
  margin-top: 1px;
}

.pricing-features li.dim { color: rgba(161,161,170,0.4); }
.pricing-features li.dim::before { color: rgba(52,199,89,0.3); }

.pricing-cta {
  display: block;
  text-align: center;
  padding: 13px;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 600;
  transition: opacity 0.2s;
  cursor: pointer;
}
.pricing-cta:hover { opacity: 0.85; }

.pricing-cta.outline {
  border: 1px solid var(--border-hover);
  color: var(--text);
}

.pricing-cta.solid {
  background: var(--yellow);
  color: #000;
}

.pricing-legal {
  text-align: center;
  font-size: 12px;
  color: rgba(161,161,170,0.5);
  margin-top: 20px;
}

/* ---------- Full Features ---------- */
.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.feature-item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 24px;
  transition: border-color 0.3s;
}
.feature-item:hover { border-color: var(--border-hover); }

.feature-item h4 {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 6px;
}
.feature-item p { font-size: 14px; }

/* ---------- Privacy ---------- */
#privacy { background: #0d0d0f; }

.privacy-inner {
  max-width: 680px;
  margin: 0 auto;
  text-align: center;
}

.privacy-shield {
  width: 56px;
  height: 56px;
  background: rgba(52,199,89,0.12);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 24px;
}
.privacy-shield svg { width: 28px; height: 28px; color: var(--green); }

.privacy-inner h2 {
  font-size: clamp(28px, 4vw, 40px);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 20px;
}

.privacy-inner > p {
  font-size: 16px;
  line-height: 1.7;
  margin-bottom: 12px;
}

.privacy-inner > p + p {
  margin-bottom: 32px;
}

.privacy-pills {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-bottom: 32px;
}

.privacy-pill {
  display: flex;
  align-items: center;
  gap: 7px;
  border: 1px solid var(--border);
  border-radius: 100px;
  padding: 8px 16px;
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
}
.privacy-pill svg { width: 14px; height: 14px; flex-shrink: 0; }
.privacy-pill.green { border-color: rgba(52,199,89,0.25); color: var(--green); }
.privacy-pill.blue  { border-color: rgba(0,122,255,0.25);  color: var(--blue); }
.privacy-pill.purple{ border-color: rgba(88,86,214,0.25);  color: var(--purple); }

.privacy-powered {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 28px;
}

.privacy-powered-item {
  display: flex;
  align-items: center;
  gap: 6px;
}
.privacy-powered-item svg { width: 16px; height: 16px; }

.privacy-policy-link {
  font-size: 13px;
  color: var(--muted);
  border-bottom: 1px solid var(--border-hover);
  padding-bottom: 1px;
  transition: color 0.2s;
}
.privacy-policy-link:hover { color: var(--text); }

/* ---------- Bottom CTA ---------- */
.bottom-cta {
  text-align: center;
  padding: var(--section-gap) 0;
}

.bottom-cta img.app-icon {
  width: 80px;
  height: 80px;
  border-radius: 18px;
  margin: 0 auto 24px;
}

.bottom-cta h2 {
  font-size: clamp(28px, 4vw, 44px);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
  margin-bottom: 16px;
}

.bottom-cta p {
  font-size: 16px;
  max-width: 440px;
  margin: 0 auto 28px;
}

.bottom-cta .appstore-btn img { height: 48px; margin: 0 auto; }

.bottom-cta .req {
  margin-top: 14px;
  font-size: 12px;
}

/* ---------- Footer ---------- */
footer {
  border-top: 1px solid var(--border);
  padding: 24px 0;
  text-align: center;
  font-size: 13px;
  color: rgba(161,161,170,0.5);
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .hero-inner { grid-template-columns: 1fr; text-align: center; }
  .hero-badge { margin: 0 auto; }
  .hero-actions { align-items: center; }
  .hero-image { order: -1; }
  .hero-image img { max-height: 360px; }

  .cards-grid { grid-template-columns: 1fr; }
  .steps-grid { grid-template-columns: 1fr; }
  .lang-tiers { grid-template-columns: 1fr; }
  .pricing-grid { grid-template-columns: 1fr; max-width: 400px; }
  .features-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 600px) {
  :root { --section-gap: 64px; }
  .nav-links { display: none; }
  .nav-links.open {
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 64px; left: 0; right: 0;
    background: rgba(10,10,11,0.97);
    padding: 24px;
    gap: 20px;
    border-bottom: 1px solid var(--border);
  }
  .nav-hamburger { display: flex; }
  .features-grid { grid-template-columns: 1fr; }
  .pricing-grid { max-width: 100%; }
}
