.hero {
  min-height: 0;
  padding: 58px 20px 44px;
  background: linear-gradient(160deg, #0a0a1a 0%, #0d1b3e 36%, #1a0a2e 68%, #0a1628 100%) !important;
  color: #fff;
}

.hero::before {
  z-index: 0;
  pointer-events: none;
}

.hero > * {
  position: relative;
  z-index: 1;
}

.hero .hero-badge {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.2);
  color: #ffd600;
  letter-spacing: 0.03em;
  text-transform: none;
}

.hero h1 {
  max-width: 900px;
  margin: 0 auto 12px;
  font-size: clamp(27px, 5vw, 46px);
  line-height: 1.12;
  letter-spacing: -0.03em;
}

.hero .hero-h1-sub {
  display: block;
  margin-top: 8px;
  color: rgba(255, 255, 255, 0.85);
  font-weight: 600;
}

.hero > p {
  max-width: 720px;
  margin: 0 auto 20px;
  color: rgba(255, 255, 255, 0.86);
  font-size: 15px;
  line-height: 1.65;
}

.language-calculator-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  margin: 0 auto 20px;
  padding: 13px 25px;
  border-radius: 100px;
  background: linear-gradient(135deg, #ff6f00, #ffd600);
  box-shadow: 0 4px 28px rgba(255, 140, 0, 0.38);
  color: #0a0a1a;
  font-size: 15px;
  font-weight: 800;
  text-decoration: none;
  transition: transform 0.2s, box-shadow 0.2s;
}

.language-calculator-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 34px rgba(255, 140, 0, 0.48);
}

.language-calculator-cta:focus-visible {
  outline: 3px solid #fff;
  outline-offset: 3px;
}

.main-wrap {
  max-width: 1240px !important;
  padding: 20px 24px 72px !important;
}

#calculatorGrid > .card:first-child {
  border: 2px solid var(--primary) !important;
  box-shadow: 0 8px 28px rgba(26, 86, 219, 0.12) !important;
}

#calculatorGrid > .card:first-child .card-header {
  background: linear-gradient(115deg, var(--primary-light), var(--surface)) !important;
}

.hero-stats.language-proof-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin: 28px 0;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: var(--surface2);
}

.language-proof-stats .hero-stat {
  min-width: 0;
  padding: 10px 8px;
  border-radius: 12px;
}

.language-proof-stats .hero-stat .num {
  color: var(--primary);
}

.language-proof-stats .hero-stat .lbl {
  color: var(--text2);
}

@media (max-width: 768px) {
  .hero {
    padding: 34px 16px 28px;
  }

  .hero h1 {
    max-width: 18ch;
    font-size: clamp(25px, 7.5vw, 34px);
  }

  .hero > p {
    margin-bottom: 16px;
    font-size: 14px;
  }

  .hero > p:not(.hero-h1-sub) {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    line-height: 1.45;
  }

  .language-calculator-cta {
    margin-bottom: 0;
    padding: 11px 20px;
    font-size: 14px;
  }

  .main-wrap {
    padding: 14px 16px 52px !important;
  }

  html body .faq-cta-btn {
    box-sizing: border-box !important;
    max-width: 100% !important;
    width: 100% !important;
    white-space: normal !important;
    overflow-wrap: anywhere;
    text-align: center;
  }

  html body .faq-cta-text {
    min-width: 0 !important;
    max-width: 100% !important;
    overflow-wrap: anywhere;
  }

  .hero-stats.language-proof-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin: 20px 0;
    padding: 8px;
  }
}

@media (max-width: 900px) {
  .features-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    min-width: 0;
  }
}

@media (max-width: 480px) {
  .features-grid {
    grid-template-columns: minmax(0, 1fr) !important;
  }
}

@media (max-width: 380px) {
  .hero-stats.language-proof-stats {
    gap: 4px;
  }

  .language-proof-stats .hero-stat .num {
    font-size: 16px;
  }
}
