*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --bg-deep: #050810;
  --bg-mid: #0a1220;
  --accent-gold: #c9a84c;
  --accent-gold-light: #e8c96a;
  --accent-teal: #2dd4bf;
  --accent-purple: #7c3aed;
  --text-primary: #f0ede6;
  --text-muted: #8b95a8;
  --glass: rgba(255, 255, 255, 0.04);
  --glass-border: rgba(255, 255, 255, 0.08);
  --glow-gold: rgba(201, 168, 76, 0.35);
  --glow-teal: rgba(45, 212, 191, 0.2);
  --font: 'Vazirmatn', system-ui, sans-serif;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font);
  background: var(--bg-deep);
  color: var(--text-primary);
  min-height: 100vh;
  overflow-x: hidden;
  line-height: 1.7;
}

#particles {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

.aurora {
  position: fixed;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(ellipse 80% 60% at 20% 30%, rgba(124, 58, 237, 0.12) 0%, transparent 60%),
    radial-gradient(ellipse 70% 50% at 80% 70%, rgba(45, 212, 191, 0.08) 0%, transparent 55%),
    radial-gradient(ellipse 60% 40% at 50% 50%, rgba(201, 168, 76, 0.06) 0%, transparent 50%);
  animation: auroraShift 20s ease-in-out infinite alternate;
}

@keyframes auroraShift {
  0% { opacity: 0.7; transform: scale(1) rotate(0deg); }
  100% { opacity: 1; transform: scale(1.05) rotate(2deg); }
}

.noise {
  position: fixed;
  inset: 0;
  z-index: 1;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  pointer-events: none;
}

.container {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 900px;
  margin: 0 auto;
  padding:
    max(2rem, env(safe-area-inset-top))
    max(1.25rem, env(safe-area-inset-right))
    max(2rem, env(safe-area-inset-bottom))
    max(1.25rem, env(safe-area-inset-left));
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: clamp(2rem, 5vw, 3rem);
  text-align: center;
}

/* Logo */
.logo-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.25rem;
}

.logo-ring {
  width: 80px;
  height: 80px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--glass);
  border: 1px solid var(--glass-border);
  box-shadow: 0 0 40px var(--glow-gold), inset 0 0 20px rgba(201, 168, 76, 0.05);
  animation: logoPulse 4s ease-in-out infinite;
}

@keyframes logoPulse {
  0%, 100% { box-shadow: 0 0 30px var(--glow-gold), inset 0 0 20px rgba(201, 168, 76, 0.05); }
  50% { box-shadow: 0 0 60px var(--glow-gold), 0 0 20px var(--glow-teal), inset 0 0 30px rgba(201, 168, 76, 0.1); }
}

.logo-icon {
  width: 48px;
  height: 48px;
  color: var(--accent-gold);
  animation: logoSpin 30s linear infinite;
}

@keyframes logoSpin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.brand {
  font-weight: 900;
  font-size: clamp(1.8rem, 5vw, 2.8rem);
  letter-spacing: -0.02em;
  line-height: 1.3;
}

.brand-line {
  display: block;
}

.brand-line.accent {
  background: linear-gradient(135deg, var(--accent-gold-light), var(--accent-teal));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Mystery section */
.mystery {
  width: 100%;
  max-width: 640px;
  padding-inline: 0.25rem;
}

.headline {
  font-size: clamp(1.15rem, 3.5vw, 1.75rem);
  font-weight: 300;
  color: var(--text-primary);
  min-height: 3.2em;
  margin-bottom: 1rem;
  line-height: 1.6;
  padding-inline: 0.5rem;
}

.cursor-blink {
  color: var(--accent-gold);
  animation: blink 1s step-end infinite;
  font-weight: 100;
}

@keyframes blink {
  50% { opacity: 0; }
}

.subtext {
  font-size: clamp(0.85rem, 2.5vw, 0.95rem);
  color: var(--text-muted);
  font-weight: 300;
  padding-inline: 0.5rem;
}

.subtext em {
  color: var(--accent-gold-light);
  font-style: normal;
  opacity: 0.8;
}

/* Countdown */
.countdown-section {
  width: 100%;
  padding-inline: 0.25rem;
}

.countdown-label {
  font-size: clamp(0.65rem, 2vw, 0.75rem);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: clamp(1rem, 3vw, 1.5rem);
  padding-inline: 0.5rem;
}

.countdown {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(0.35rem, 2vw, 0.75rem);
  flex-wrap: wrap;
  direction: ltr;
  width: 100%;
  max-width: 100%;
}

.time-block {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
}

.time-flip {
  position: relative;
  width: clamp(64px, 14vw, 96px);
  height: clamp(72px, 16vw, 108px);
  perspective: 400px;
}

.time-value {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  font-size: clamp(1.6rem, 5.5vw, 3rem);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--text-primary);
  background: var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: clamp(10px, 2vw, 12px);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow:
    0 4px 24px rgba(0, 0, 0, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.4s ease;
}

.time-value.flip-animate {
  animation: flipIn 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes flipIn {
  0% { transform: rotateX(-90deg); opacity: 0; }
  60% { transform: rotateX(10deg); }
  100% { transform: rotateX(0deg); opacity: 1; }
}

.time-value.glow {
  box-shadow:
    0 4px 24px rgba(0, 0, 0, 0.3),
    0 0 30px var(--glow-gold),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.time-unit {
  font-size: clamp(0.6rem, 1.8vw, 0.7rem);
  color: var(--text-muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.time-separator {
  font-size: clamp(1.5rem, 4vw, 2.5rem);
  font-weight: 100;
  color: var(--accent-gold);
  opacity: 0.5;
  align-self: flex-start;
  margin-top: clamp(16px, 4vw, 24px);
  animation: separatorPulse 2s ease-in-out infinite;
}

@keyframes separatorPulse {
  0%, 100% { opacity: 0.3; }
  50% { opacity: 0.7; }
}

.launch-date {
  margin-top: clamp(0.75rem, 2vw, 1.25rem);
  font-size: clamp(0.75rem, 2vw, 0.85rem);
  color: var(--accent-gold);
  letter-spacing: 0.1em;
  opacity: 0.7;
}

/* Teaser cards */
.teaser {
  width: 100%;
}

.teaser-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
  gap: clamp(0.75rem, 2vw, 1rem);
  width: 100%;
  max-width: 700px;
  margin-inline: auto;
}

.teaser-card {
  padding: clamp(1rem, 3vw, 1.25rem) clamp(0.85rem, 2.5vw, 1rem);
  background: var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: 14px;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1), border-color 0.3s ease, box-shadow 0.3s ease;
}

@media (hover: hover) {
  .teaser-card:hover {
    transform: translateY(-4px);
    border-color: rgba(201, 168, 76, 0.25);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3), 0 0 20px var(--glow-gold);
  }
}

.card-icon {
  display: block;
  font-size: 1.2rem;
  color: var(--accent-gold);
  margin-bottom: 0.5rem;
}

.teaser-card p {
  font-size: clamp(0.8rem, 2.2vw, 0.85rem);
  color: var(--text-muted);
  font-weight: 300;
  line-height: 1.6;
}

/* Scroll animations */
[data-animate] {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

[data-animate].visible {
  opacity: 1;
  transform: translateY(0);
}

/* Responsive */
@media (max-width: 768px) {
  .logo-ring {
    width: 68px;
    height: 68px;
  }

  .logo-icon {
    width: 40px;
    height: 40px;
  }

  .time-separator {
    font-size: 1.5rem;
    margin-top: 18px;
  }
}

@media (max-width: 540px) {
  .countdown {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.85rem 1rem;
    max-width: 300px;
    margin-inline: auto;
  }

  .time-separator {
    display: none;
  }

  .time-block {
    width: 100%;
  }

  .time-flip {
    width: 100%;
    max-width: 132px;
    height: 76px;
    margin-inline: auto;
  }

  .time-value {
    font-size: 1.85rem;
  }

  .teaser-cards {
    grid-template-columns: 1fr;
    max-width: 360px;
  }
}

@media (max-width: 380px) {
  .brand {
    font-size: 1.55rem;
  }

  .headline {
    min-height: 3.6em;
    font-size: 1.05rem;
  }

  .countdown {
    max-width: 260px;
    gap: 0.65rem 0.75rem;
  }

  .time-flip {
    max-width: 118px;
    height: 68px;
  }

  .time-value {
    font-size: 1.6rem;
  }
}

@media (max-height: 700px) and (orientation: landscape) {
  .container {
    justify-content: flex-start;
    padding-block: 1.25rem;
    gap: 1.5rem;
  }

  .logo-ring {
    width: 56px;
    height: 56px;
  }

  .logo-icon {
    width: 34px;
    height: 34px;
  }

  .headline {
    min-height: 2.4em;
  }

  .countdown {
    max-width: 420px;
  }

  .time-flip {
    width: 72px;
    height: 64px;
  }

  .time-value {
    font-size: 1.5rem;
  }

  .teaser-cards {
    grid-template-columns: repeat(3, 1fr);
    max-width: 100%;
  }

  .teaser-card {
    padding: 0.75rem 0.5rem;
  }

  .teaser-card p {
    font-size: 0.72rem;
  }
}
