/* ============================================================
   CSS VARIABLES — Design System
   ============================================================ */
:root {
  /* Backgrounds */
  --bg-deep: #070B1A;
  --bg-dark: #111627;
  --bg-glass: rgba(26, 32, 64, 0.6);
  --bg-glass-solid: rgba(26, 32, 64, 0.4);

  /* Accents */
  --gold: #D4A853;
  --gold-light: #F6E27A;
  --gold-dark: #A67C3D;
  --violet: #7B5EA7;
  --blue: #4A7CF7;

  /* Text */
  --text-primary: #F0F4FF;
  --text-secondary: #9BA3C0;

  /* Glows & borders */
  --gold-glow: rgba(212, 168, 83, 0.3);
  --gold-glow-intense: rgba(212, 168, 83, 0.4);
  --violet-glow: rgba(123, 94, 167, 0.25);
  --glass-border: rgba(212, 168, 83, 0.15);
  --glass-border-subtle: rgba(212, 168, 83, 0.12);

  /* Typography */
  --font-display: 'Playfair Display', serif;
  --font-body: 'Inter', sans-serif;

  /* Sizing */
  --container-max: 1200px;
  --container-padding-desktop: 120px;
  --container-padding-tablet: 60px;
  --container-padding-mobile: 24px;
  --section-gap-desktop: 100px;
  --section-gap-mobile: 60px;
  --base-unit: 8px;

  /* Transitions */
  --transition-fast: 0.2s ease;
  --transition-normal: 0.3s ease;
  --transition-slow: 0.5s ease;
}

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

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 16px;
  line-height: 1.6;
  color: var(--text-primary);
  background: linear-gradient(135deg, var(--bg-deep), #0E1230);
  min-height: 100vh;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

ul {
  list-style: none;
}

/* ============================================================
   VISUALLY HIDDEN (accessibility)
   ============================================================ */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ============================================================
   CONTAINER
   ============================================================ */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--container-padding-desktop);
}

/* ============================================================
   SECTION SHARED
   ============================================================ */
.section {
  padding: var(--section-gap-desktop) 0;
}

.section__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 40px;
  line-height: 1.2;
  text-align: center;
  margin-bottom: 16px;
  color: var(--text-primary);
  text-shadow: 0 0 40px var(--gold-glow);
}

.section__subtitle {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 18px;
  line-height: 1.5;
  text-align: center;
  color: var(--text-secondary);
  max-width: 640px;
  margin: 0 auto 56px;
}

/* ============================================================
   GLASS CARD
   ============================================================ */
.glass-card {
  background: var(--bg-glass-solid);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--glass-border-subtle);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
  border-radius: 16px;
  transition: transform var(--transition-normal), box-shadow var(--transition-normal), border-color var(--transition-normal);
}

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

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 16px;
  line-height: 1;
  padding: 14px 32px;
  border-radius: 12px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all var(--transition-normal);
  white-space: nowrap;
}

.btn--primary {
  background: linear-gradient(135deg, var(--gold), var(--gold-dark));
  color: var(--bg-deep);
  border-color: var(--gold);
  box-shadow: 0 0 20px var(--gold-glow);
}

.btn--primary:hover {
  box-shadow: 0 0 36px var(--gold-glow-intense);
  transform: translateY(-2px);
}

.btn--ghost {
  background: transparent;
  color: var(--text-primary);
  border-color: rgba(240, 244, 255, 0.2);
}

.btn--ghost:hover {
  border-color: var(--gold);
  color: var(--gold);
  box-shadow: 0 0 20px var(--gold-glow);
  transform: translateY(-2px);
}

/* ============================================================
   REVEAL (scroll animation placeholder)
   ============================================================ */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal.revealed {
  opacity: 1;
  transform: translateY(0);
}

/* ============================================================
   HEADER / NAVIGATION
   ============================================================ */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(7, 11, 26, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--glass-border-subtle);
}

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

.header__logo {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-display);
  font-size: 22px;
  color: var(--gold);
}

.header__logo-icon {
  font-size: 24px;
}

.header__nav-list {
  display: flex;
  align-items: center;
  gap: 32px;
}

.header__nav-link {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-secondary);
  transition: color var(--transition-fast);
  position: relative;
}

.header__nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--gold);
  transition: width var(--transition-normal);
}

.header__nav-link:hover {
  color: var(--gold);
}

.header__nav-link:hover::after {
  width: 100%;
}

.header__nav-link--cta {
  padding: 8px 20px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--gold), var(--gold-dark));
  color: var(--bg-deep);
  font-weight: 700;
}

.header__nav-link--cta::after {
  display: none;
}

.header__nav-link--cta:hover {
  color: var(--bg-deep);
  box-shadow: 0 0 24px var(--gold-glow);
}

.header__burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.header__burger-line {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: all var(--transition-normal);
}

/* ============================================================
   HERO
   ============================================================ */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.hero__particles {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse at 20% 50%, rgba(123, 94, 167, 0.15) 0%, transparent 60%),
    radial-gradient(ellipse at 80% 20%, rgba(212, 168, 83, 0.08) 0%, transparent 50%),
    radial-gradient(ellipse at 50% 80%, rgba(74, 124, 247, 0.06) 0%, transparent 50%);
}

.hero__inner {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 60px;
  width: 100%;
}

.hero__content {
  flex: 1;
  max-width: 560px;
}

.hero__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 56px;
  line-height: 1.15;
  color: var(--text-primary);
  margin-bottom: 24px;
  text-shadow: 0 0 40px var(--gold-glow);
}

.hero__subtitle {
  font-size: 18px;
  line-height: 1.6;
  color: var(--text-secondary);
  margin-bottom: 40px;
}

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

/* Brand image (symbol MAG) */
.hero__brand-image {
  flex-shrink: 0;
  width: 550px;
  max-width: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero__brand-img {
  width: 100%;
  height: auto;
  filter: drop-shadow(0 0 30px var(--gold-glow-intense));
  animation: float 5s ease-in-out infinite;
}

/* Scroll indicator */
.hero__scroll {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  z-index: 1;
}

.hero__scroll-text {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--text-secondary);
}

.hero__scroll-line {
  display: block;
  width: 1px;
  height: 32px;
  background: linear-gradient(to bottom, var(--gold), transparent);
  animation: scrollPulse 2s ease-in-out infinite;
}

/* ============================================================
   PROBLEM
   ============================================================ */
.problem {
  background: var(--bg-dark);
}

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

.problem__card {
  padding: 40px 32px;
  text-align: center;
}

.problem__card-icon {
  font-size: 36px;
  color: var(--gold);
  margin-bottom: 20px;
}

.problem__card-title {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 20px;
  margin-bottom: 12px;
  color: var(--text-primary);
}

.problem__card-text {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* ============================================================
   HOW IT WORKS
   ============================================================ */
.how-it-works__steps {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
}

.how-it-works__step {
  flex: 1;
  max-width: 320px;
  text-align: center;
  padding: 40px 24px;
}

.how-it-works__step-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--gold), var(--gold-dark));
  color: var(--bg-deep);
  font-weight: 700;
  font-size: 20px;
  margin-bottom: 20px;
}

.how-it-works__step-icon {
  font-size: 32px;
  color: var(--gold);
  margin-bottom: 16px;
}

.how-it-works__step-title {
  font-weight: 600;
  font-size: 20px;
  margin-bottom: 12px;
  color: var(--text-primary);
}

.how-it-works__step-text {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.5;
}

.how-it-works__connector {
  width: 80px;
  height: 1px;
  background: linear-gradient(to right, transparent, var(--gold-glow), transparent);
  flex-shrink: 0;
}

/* ============================================================
   FEATURES
   ============================================================ */
.features {
  background: var(--bg-dark);
}

.features__grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 20px;
}

.features__card {
  padding: 32px 20px;
  text-align: center;
}

.features__card-icon {
  font-size: 32px;
  color: var(--gold);
  margin-bottom: 16px;
}

.features__card-title {
  font-weight: 600;
  font-size: 16px;
  margin-bottom: 10px;
  color: var(--text-primary);
}

.features__card-text {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.5;
}

.features__card:hover {
  box-shadow: 0 0 24px var(--gold-glow);
}

/* ============================================================
   FOR WHOM
   ============================================================ */
.for-whom__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.for-whom__card {
  padding: 36px 24px;
  text-align: center;
}

.for-whom__card-icon {
  font-size: 32px;
  color: var(--violet);
  margin-bottom: 16px;
}

.for-whom__card-title {
  font-weight: 600;
  font-size: 18px;
  margin-bottom: 12px;
  color: var(--text-primary);
}

.for-whom__card-text {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.5;
}

.for-whom__card:hover {
  box-shadow: 0 0 24px var(--violet-glow);
  border-color: rgba(123, 94, 167, 0.25);
}

/* ============================================================
   CREDIBILITY
   ============================================================ */
.credibility {
  background: var(--bg-dark);
}

.credibility__content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.credibility__tech,
.credibility__security {
  padding: 32px 28px;
}

.credibility__tech-icon,
.credibility__security-icon {
  font-size: 28px;
  color: var(--gold);
  margin-bottom: 16px;
}

.credibility__tech-title,
.credibility__security-title {
  font-weight: 600;
  font-size: 18px;
  margin-bottom: 12px;
  color: var(--text-primary);
}

.credibility__tech-text,
.credibility__security-text {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.6;
}

.credibility__tech-text strong,
.credibility__security-text strong {
  color: var(--gold);
}

.credibility__expert {
  grid-column: 1 / -1;
  display: flex;
  gap: 28px;
  align-items: flex-start;
  padding: 32px 28px;
}

.credibility__expert-avatar {
  flex-shrink: 0;
  width: 80px;
  height: 80px;
  border-radius: 50%;
  overflow: hidden;
  border: 2px solid var(--gold);
  box-shadow: 0 0 20px var(--gold-glow);
}

.credibility__expert-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.credibility__expert-name {
  font-weight: 600;
  font-size: 20px;
  margin-bottom: 4px;
  color: var(--text-primary);
}

.credibility__expert-role {
  font-size: 14px;
  color: var(--gold);
  margin-bottom: 10px;
}

.credibility__expert-bio {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ============================================================
   CTA
   ============================================================ */
.cta__inner {
  max-width: 600px;
  margin: 0 auto;
  padding: 48px 40px;
  text-align: center;
}

.cta__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 36px;
  margin-bottom: 16px;
  color: var(--text-primary);
}

.cta__subtitle {
  font-size: 16px;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 32px;
}

.cta__form {
  display: flex;
  gap: 12px;
  max-width: 440px;
  margin: 0 auto 24px;
}

.cta__form-field {
  flex: 1;
  position: relative;
}

.cta__form-input {
  width: 100%;
  padding: 14px 18px;
  border-radius: 12px;
  border: 1px solid var(--glass-border-subtle);
  background: rgba(240, 244, 255, 0.06);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 16px;
  outline: none;
  transition: border-color var(--transition-normal), box-shadow var(--transition-normal);
}

.cta__form-input::placeholder {
  color: var(--text-secondary);
  opacity: 0.6;
}

.cta__form-input:focus {
  border-color: var(--gold);
  box-shadow: 0 0 16px var(--gold-glow);
}

.cta__form-input--error {
  border-color: #E74C3C;
}

.cta__form-error {
  position: absolute;
  bottom: -20px;
  left: 0;
  font-size: 12px;
  color: #E74C3C;
  display: none;
}

.cta__form-error.visible {
  display: block;
}

.cta__form-submit {
  flex-shrink: 0;
}

.cta__counter {
  font-size: 14px;
  color: var(--text-secondary);
}

.cta__counter span {
  color: var(--gold);
  font-weight: 700;
}

.cta__success {
  display: none;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.cta__success i {
  font-size: 48px;
  color: var(--gold);
}

.cta__success p {
  font-size: 18px;
  color: var(--text-primary);
}

.cta__success.visible {
  display: flex;
}

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

.footer__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  text-align: center;
}

.footer__logo {
  font-family: var(--font-display);
  font-size: 20px;
  color: var(--gold);
}

.footer__copy {
  font-size: 14px;
  color: var(--text-secondary);
  margin-top: 4px;
}

.footer__links {
  display: flex;
  gap: 24px;
}

.footer__link {
  font-size: 14px;
  color: var(--text-secondary);
  transition: color var(--transition-fast);
}

.footer__link:hover {
  color: var(--gold);
}

.footer__disclaimer {
  font-size: 12px;
  color: var(--text-secondary);
  opacity: 0.5;
  max-width: 480px;
  line-height: 1.5;
}

/* ============================================================
   ANIMATIONS
   ============================================================ */
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-16px); }
}

@keyframes scrollPulse {
  0%, 100% { opacity: 1; transform: scaleY(1); }
  50%      { opacity: 0.3; transform: scaleY(0.5); }
}

/* ============================================================
   MEDIA QUERIES
   ============================================================ */

/* Tablet (≤ 1024px) */
@media (max-width: 1024px) {
  .container {
    padding: 0 var(--container-padding-tablet);
  }

  .hero__inner {
    flex-direction: column;
    text-align: center;
    gap: 40px;
  }

  .hero__content {
    max-width: 100%;
  }

  .hero__actions {
    justify-content: center;
  }

  .hero__brand-image {
    width: 380px;
    max-width: 60%;
    order: -1;
  }

  .hero__title {
    font-size: 44px;
  }

  .section__title {
    font-size: 34px;
  }

  .features__grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .for-whom__grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .credibility__content {
    grid-template-columns: 1fr;
  }

  .how-it-works__steps {
    flex-direction: column;
    gap: 0;
  }

  .how-it-works__connector {
    width: 1px;
    height: 40px;
    background: linear-gradient(to bottom, transparent, var(--gold-glow), transparent);
  }
}

/* Mobile L (≤ 768px) */
@media (max-width: 768px) {
  :root {
    --container-padding-desktop: 24px;
  }

  .container {
    padding: 0 var(--container-padding-mobile);
  }

  .section {
    padding: var(--section-gap-mobile) 0;
  }

  .header__nav {
    position: fixed;
    top: 72px;
    left: 0;
    right: 0;
    background: rgba(7, 11, 26, 0.98);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--glass-border-subtle);
    transform: translateY(-100%);
    opacity: 0;
    pointer-events: none;
    transition: all var(--transition-normal);
  }

  .header__nav.active {
    transform: translateY(0);
    opacity: 1;
    pointer-events: all;
  }

  .header__nav-list {
    flex-direction: column;
    gap: 0;
    padding: 16px 24px;
  }

  .header__nav-list li {
    width: 100%;
  }

  .header__nav-link {
    display: block;
    padding: 14px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  }

  .header__nav-link--cta {
    text-align: center;
    margin-top: 8px;
  }

  .header__burger {
    display: flex;
  }

  .hero__brand-image {
    width: 310px;
    max-width: 70%;
  }

  .hero__title {
    font-size: 36px;
  }

  .hero__subtitle {
    font-size: 16px;
  }

  .hero__actions {
    flex-direction: column;
    align-items: center;
  }

  .hero__scroll {
    display: none;
  }

  .section__title {
    font-size: 28px;
  }

  .section__subtitle {
    font-size: 16px;
    margin-bottom: 40px;
  }

  .problem__grid {
    grid-template-columns: 1fr;
  }

  .features__grid {
    grid-template-columns: 1fr;
  }

  .for-whom__grid {
    grid-template-columns: 1fr;
  }

  .credibility__expert {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .cta__inner {
    padding: 36px 24px;
  }

  .cta__title {
    font-size: 28px;
  }

  .cta__form {
    flex-direction: column;
  }
}

/* Mobile M (≤ 480px) */
@media (max-width: 480px) {
  .hero__brand-image {
    width: 280px;
    max-width: 80%;
  }

  .hero__title {
    font-size: 30px;
  }

  .section__title {
    font-size: 24px;
  }

  .btn {
    width: 100%;
    justify-content: center;
  }

  .footer__inner {
    gap: 12px;
  }

  .footer__links {
    flex-direction: column;
    gap: 8px;
  }
}

/* Mobile S (≤ 375px) */
@media (max-width: 375px) {
  .hero__brand-image {
    width: 250px;
  }

  .hero__title {
    font-size: 26px;
  }

  .hero__subtitle {
    font-size: 14px;
  }
}
