/* styles/audio-consent.css
   First-screen audio consent (C). Shown ONCE before the intro primer
   to unlock the AudioContext via explicit click — closes the
   "no sound" gap caused by browser autoplay policy.

   Visual register matches intro-primer + share-card (resting beat,
   slow fade, sparse). Sits above orientation-portrait-lock so the
   consent modal is the FIRST thing a mobile player sees in landscape. */

.audio-consent-overlay {
  position: fixed;
  inset: 0;
  z-index: 850;   /* above HUD (30) + intro primer (modal 60), below
                     orientation-portrait-lock (9999) */
  background: rgba(4, 6, 12, 0.94);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  opacity: 0;
  transition: opacity 800ms ease;
  backdrop-filter: blur(10px) saturate(0.85);
  -webkit-backdrop-filter: blur(10px) saturate(0.85);
}
.audio-consent-overlay.revealed { opacity: 1; }

.audio-consent-card {
  position: relative;
  width: min(440px, 92vw);
  max-height: 92vh;
  background: linear-gradient(180deg,
    #0c1220 0%,
    #10162a 55%,
    #080a14 100%);
  border: 1px solid rgba(184, 224, 255, 0.35);
  border-radius: 4px;
  padding: 36px 32px 28px 32px;
  font-family: var(--serif);
  color: rgba(248, 240, 224, 0.94);
  box-shadow:
    0 0 50px rgba(184, 224, 255, 0.08),
    0 28px 56px rgba(0, 0, 0, 0.75);
  text-align: center;
  transform: translateY(8px);
  transition: transform 800ms ease;
}
.audio-consent-overlay.revealed .audio-consent-card {
  transform: translateY(0);
}

.ac-icon {
  font-size: 2.6rem;
  margin-bottom: 18px;
  color: rgba(184, 224, 255, 0.92);
  text-shadow: 0 0 24px rgba(184, 224, 255, 0.45);
  animation: ac-icon-pulse 2.2s ease-in-out infinite;
  line-height: 1;
}
@keyframes ac-icon-pulse {
  0%, 100% { transform: scale(1); opacity: 0.92; }
  50%      { transform: scale(1.08); opacity: 1; }
}

.ac-title {
  margin: 0 0 16px 0;
  font-family: var(--serif);
  font-style: italic;
  font-weight: normal;
  font-size: 1.55rem;
  line-height: 1.2;
  color: rgba(232, 240, 252, 0.96);
  letter-spacing: 0.01em;
}

.ac-body {
  margin: 0 0 28px 0;
  font-family: var(--serif);
  font-size: 0.95rem;
  line-height: 1.55;
  color: rgba(232, 240, 252, 0.86);
  padding: 0 4px;
}
.ac-body em {
  font-style: italic;
  color: rgba(255, 232, 168, 0.95);
}

/* Compact variant — returning-player short prompt. Tighter padding,
   smaller text. Same buttons. */
.audio-consent-card-compact {
  width: min(360px, 90vw);
  padding: 24px 22px 18px 22px;
}
.audio-consent-card-compact .ac-icon {
  font-size: 2rem;
  margin-bottom: 12px;
}
.audio-consent-card-compact .ac-title {
  font-size: 1.15rem;
  margin-bottom: 10px;
}
.ac-body-compact {
  margin: 0 0 18px 0;
  font-family: var(--serif);
  font-style: italic;
  font-size: 0.82rem;
  line-height: 1.45;
  color: rgba(232, 240, 252, 0.72);
  padding: 0 4px;
}

.ac-actions {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 10px;
}
.ac-cta {
  display: block;
  width: 100%;
  padding: 14px 22px;
  background: transparent;
  border: 1px solid rgba(184, 224, 255, 0.45);
  border-radius: 3px;
  color: rgba(232, 240, 252, 0.94);
  font-family: var(--mono);
  cursor: pointer;
  transition: all 220ms ease;
  text-align: center;
}
.ac-cta:hover {
  border-color: rgba(184, 224, 255, 0.95);
  background: rgba(184, 224, 255, 0.06);
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.45);
}
.ac-cta:active {
  transform: translateY(0) scale(0.99);
}
.ac-cta-label {
  font-size: 0.85rem;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  font-weight: bold;
}

.ac-cta-primary {
  border-color: rgba(184, 224, 255, 0.85);
  background: rgba(184, 224, 255, 0.10);
}
.ac-cta-primary:hover {
  border-color: rgba(184, 224, 255, 1);
  background: rgba(184, 224, 255, 0.18);
  box-shadow:
    0 8px 22px rgba(0, 0, 0, 0.55),
    0 0 28px rgba(184, 224, 255, 0.18);
}
.ac-cta-primary .ac-cta-label {
  color: rgba(232, 244, 255, 1);
}

.ac-cta-skip {
  border: none;
  padding: 10px 22px;
  background: transparent;
  color: rgba(232, 240, 252, 0.55);
}
.ac-cta-skip:hover {
  color: rgba(248, 240, 224, 0.92);
  background: transparent;
  border-color: transparent;
  transform: none;
  box-shadow: none;
}
.ac-cta-skip .ac-cta-label {
  font-size: 0.72rem;
  letter-spacing: 0.32em;
  text-transform: lowercase;
  font-family: var(--serif);
  font-style: italic;
  font-weight: normal;
}

/* ---------- REDUCED MOTION ---------- */
@media (prefers-reduced-motion: reduce) {
  .audio-consent-overlay { transition-duration: 200ms; }
  .audio-consent-card { transition-duration: 100ms; transform: none !important; }
  .ac-icon { animation: none; }
  .ac-cta { transition-duration: 100ms; }
}

/* ---------- MOBILE ---------- */
@media (max-width: 480px) {
  .audio-consent-card {
    width: 94vw;
    padding: 28px 22px 22px 22px;
  }
  .ac-icon { font-size: 2.2rem; }
  .ac-title { font-size: 1.3rem; }
  .ac-body { font-size: 0.88rem; }
}
