:root {
  --bg: #0a0a0b;
  --bg-card: #121214;
  --bg-elevated: #1a1a1d;
  --border: #2a2a2e;
  --text: #f5f0e8;
  --text-muted: #a89f91;
  --gold: #6caee8;
  --gold-soft: #a8d4f5;
  --gold-dim: #427aa8;
  --accent: #6caee8;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: 'Inter', system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
}

.bg-glow {
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 80% 50% at 50% -10%, rgba(65, 135, 200, 0.12), transparent),
    radial-gradient(ellipse 40% 30% at 90% 20%, rgba(55, 100, 155, 0.08), transparent);
  z-index: -1;
}

a { color: var(--gold-soft); text-decoration: none; }
a:hover { text-decoration: underline; }

.container { max-width: 1120px; margin: 0 auto; padding: 0 1.25rem; }

/* Header */
header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(10, 10, 11, 0.9);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
}

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

.logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: var(--text);
}

.logo-mark {
  width: 36px;
  height: 36px;
  border: 1.5px solid var(--gold);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Cormorant Garamond', serif;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--gold);
  letter-spacing: 0.05em;
}

.logo-text {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.logo-title {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 600;
  font-size: 1.05rem;
  letter-spacing: 0.02em;
}

.logo-sub {
  font-size: 0.68rem;
  color: var(--text-muted);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.nav-links {
  display: flex;
  gap: 1.75rem;
  font-size: 0.9rem;
  font-weight: 500;
}

.nav-links a {
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.2s;
}

.nav-links a:hover { color: var(--gold-soft); text-decoration: none; }

.mobile-menu-btn {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 38px;
  height: 38px;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 8px;
  cursor: pointer;
  padding: 9px;
}

.mobile-menu-btn span {
  display: block;
  width: 100%;
  height: 2px;
  background: var(--text);
  border-radius: 1px;
}

.mobile-nav { display: none !important; }

@media (max-width: 720px) {
  .nav-links { display: none; }
  .mobile-menu-btn { display: flex !important; }
  .mobile-nav.open {
    display: flex !important;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    background: rgba(10, 10, 11, 0.97);
    border-bottom: 1px solid var(--border);
    padding: 1rem 1.25rem 1.25rem;
    flex-direction: column;
    gap: 0.5rem;
    z-index: 60;
  }
  .mobile-nav a {
    color: var(--text);
    font-size: 1.05rem;
    font-weight: 500;
    padding: 0.65rem 0;
    text-decoration: none;
    border-bottom: 1px solid var(--border);
  }
  .mobile-nav a:last-child { border-bottom: none; }
}

/* Hero */
.hero {
  padding: 2rem 0 1.75rem;
}

.hero-header {
  text-align: center;
  max-width: 560px;
  margin: 0 auto 1.75rem;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  padding: 0.35rem 0.95rem;
  border-radius: 999px;
  font-size: 0.75rem;
  color: var(--gold);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 1.25rem;
}

.af1-title-img {
  display: block;
  width: 100%;
  max-width: 520px;
  height: auto;
  margin: 0 auto;
  border-radius: 8px;
}

/* Playlist Player */
.playlist-player {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
  max-width: 360px;
  margin: 0 auto;
  box-shadow: 0 20px 50px rgba(0,0,0,0.4), 0 0 30px rgba(65, 135, 200, 0.06);
}

.player-cover-wrap {
  position: relative;
  background: #08080a;
  aspect-ratio: 1 / 1;
  width: 100%;
  overflow: hidden;
}

.player-cover {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: opacity 0.35s ease;
}

.player-controls {
  padding: 1.25rem 1.35rem 1.5rem;
}

.now-playing {
  text-align: center;
  margin-bottom: 1rem;
}

.now-playing .track-num {
  font-size: 0.72rem;
  color: var(--gold);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 0.25rem;
}

.now-playing .track-name {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text);
  line-height: 1.3;
  padding: 0 0.5rem;
}

.progress-wrap { margin-bottom: 1rem; }

.progress-bar {
  height: 5px;
  background: var(--border);
  border-radius: 3px;
  cursor: pointer;
  overflow: hidden;
  margin-bottom: 0.35rem;
}

.progress-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--gold-dim), var(--gold));
  border-radius: 3px;
  transition: width 0.1s linear;
}

.time {
  display: flex;
  justify-content: space-between;
  font-size: 0.72rem;
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
}

.transport {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.1rem;
  margin-bottom: 1.25rem;
}

.ctrl-btn {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  color: var(--text);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
}

.ctrl-btn:hover {
  border-color: var(--gold-dim);
  color: var(--gold);
}

.ctrl-btn.play-main {
  width: 56px;
  height: 56px;
  background: var(--gold);
  color: #0a0a0b;
  border: none;
}

.ctrl-btn.play-main:hover {
  background: var(--gold-soft);
  transform: scale(1.05);
}

.ctrl-btn svg { width: 20px; height: 20px; }
.ctrl-btn.play-main svg { width: 24px; height: 24px; }

.playlist-list {
  border-top: 1px solid var(--border);
  max-height: 280px;
  overflow-y: auto;
}

.playlist-item {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.7rem 1.1rem;
  cursor: pointer;
  transition: background 0.15s;
  border-bottom: 1px solid rgba(42,42,46,0.6);
}

.playlist-item:last-child { border-bottom: none; }
.playlist-item:hover { background: rgba(65, 135, 200, 0.06); }
.playlist-item.active {
  background: rgba(65, 135, 200, 0.12);
}

.playlist-item .num {
  font-size: 0.78rem;
  color: var(--text-muted);
  width: 22px;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.playlist-item.active .num { color: var(--gold); }

.playlist-item .meta {
  flex: 1;
  min-width: 0;
}

.playlist-item .title {
  font-size: 0.85rem;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.playlist-item.active .title { color: var(--gold-soft); }

.playlist-item .duration {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
}

/* Explore section */
.section { padding: 3.5rem 0; }

.section-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 2.1rem;
  font-weight: 600;
  text-align: center;
  margin-bottom: 0.5rem;
}

.section-sub {
  text-align: center;
  color: var(--text-muted);
  margin-bottom: 2.5rem;
  max-width: 520px;
  margin-left: auto;
  margin-right: auto;
  font-size: 0.95rem;
}

.grid {
  display: grid;
  gap: 1.5rem;
}

.songs-grid {
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
}

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
  transition: transform 0.2s, box-shadow 0.2s;
  display: flex;
  flex-direction: column;
}

.card:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 40px rgba(0,0,0,0.45), 0 0 24px rgba(65, 135, 200, 0.08);
}

.card-img-wrap {
  position: relative;
  background: #08080a;
}

.card-img-wrap a { display: block; cursor: zoom-in; }

.card-img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  display: block;
}

.card-num {
  position: absolute;
  top: 10px;
  left: 10px;
  background: rgba(0,0,0,0.7);
  color: var(--gold);
  font-weight: 600;
  font-size: 0.78rem;
  padding: 0.2rem 0.55rem;
  border-radius: 5px;
  letter-spacing: 0.03em;
}

.card-body {
  padding: 1rem 1.1rem 1.15rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.card-body h3 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.05rem;
  font-weight: 600;
  margin-bottom: 0.2rem;
  line-height: 1.3;
}

.card-body .remedy {
  font-size: 0.78rem;
  color: var(--gold);
  margin-bottom: 0.65rem;
  letter-spacing: 0.03em;
}

.card-body .song-link {
  display: inline-block;
  font-size: 0.82rem;
  color: var(--gold-soft);
  margin-bottom: 0.85rem;
  font-weight: 500;
}

.card-body .song-link:hover { text-decoration: underline; }

.share-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  margin-top: auto;
}

.share-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.2rem;
  padding: 0.35rem 0.55rem;
  border-radius: 7px;
  font-size: 0.7rem;
  font-weight: 600;
  border: 1px solid var(--border);
  background: var(--bg-elevated);
  color: var(--text-muted);
  cursor: pointer;
  text-decoration: none;
  transition: all 0.15s;
}

.share-btn:hover {
  border-color: var(--gold-dim);
  color: var(--gold-soft);
  text-decoration: none;
}

.share-btn.primary {
  background: rgba(65, 135, 200, 0.15);
  border-color: var(--gold-dim);
  color: var(--gold);
}

.share-btn.primary:hover {
  background: rgba(65, 135, 200, 0.25);
}

.stream-mini {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-bottom: 0.75rem;
}

.stream-mini a {
  font-size: 0.68rem;
  padding: 0.25rem 0.5rem;
  border-radius: 6px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  color: var(--text-muted);
  text-decoration: none;
  font-weight: 600;
}

.stream-mini a:hover {
  border-color: var(--gold-dim);
  color: var(--gold);
  text-decoration: none;
}

/* CTA */
.cta {
  padding: 3.5rem 0;
  text-align: center;
  border-top: 1px solid var(--border);
}

.cta h2 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.8rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.cta p {
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}

/* Footer */
footer {
  padding: 2.5rem 0 3rem;
  border-top: 1px solid var(--border);
  text-align: center;
}

.footer-brand {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.15rem;
  color: var(--gold);
  margin-bottom: 0.4rem;
}

footer p {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 0.3rem;
}

.fineprint {
  font-size: 0.75rem !important;
  opacity: 0.7;
  margin-top: 0.75rem !important;
}

/* Toast */
.toast {
  position: fixed;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%) translateY(100px);
  background: var(--bg-elevated);
  border: 1px solid var(--gold-dim);
  color: var(--text);
  padding: 0.7rem 1.3rem;
  border-radius: 10px;
  font-size: 0.85rem;
  font-weight: 500;
  opacity: 0;
  transition: transform 0.3s, opacity 0.3s;
  z-index: 100;
  pointer-events: none;
}

.toast.show {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(0, 0, 0, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.lightbox.open {
  opacity: 1;
  visibility: visible;
}

.lightbox-inner {
  position: relative;
  max-width: 100%;
  max-height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.lightbox img {
  max-width: 100%;
  max-height: calc(100vh - 120px);
  object-fit: contain;
  border-radius: 8px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.6);
}

.lightbox-close {
  position: absolute;
  top: -52px;
  right: 0;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  color: var(--text);
  font-size: 1.6rem;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s, border-color 0.15s;
  z-index: 10;
}

.lightbox-close:hover {
  background: var(--gold);
  color: #0a0a0b;
  border-color: var(--gold);
}

.lightbox-actions {
  margin-top: 1rem;
  display: flex;
  gap: 0.6rem;
  flex-wrap: wrap;
  justify-content: center;
}

@media (max-width: 600px) {
  .lightbox {
    padding: 0.75rem;
  }
  .lightbox-close {
    top: 12px;
    right: 12px;
    width: 52px;
    height: 52px;
    font-size: 1.8rem;
    background: rgba(0,0,0,0.7);
  }
  .lightbox img {
    max-height: calc(100vh - 140px);
  }
}

/* Audiosensory Formula switcher */
.formula-switcher{position:relative}
.formula-trigger{background:transparent;border:0;font:inherit;cursor:pointer;padding:0;text-align:left}
.formula-chevron{margin-left:.15rem;color:var(--gold);font-size:1rem;transition:transform .2s}
.formula-trigger[aria-expanded="true"] .formula-chevron{transform:rotate(180deg)}
.formula-menu{position:absolute;top:calc(100% + 12px);left:0;width:min(330px,calc(100vw - 2.5rem));padding:.55rem;background:rgba(18,18,20,.98);border:1px solid var(--border);border-radius:12px;box-shadow:0 18px 50px rgba(0,0,0,.55);z-index:100}
.formula-menu[hidden]{display:none}
.formula-item{display:grid;grid-template-columns:78px 1fr auto;gap:.65rem;align-items:center;padding:.7rem .75rem;border-radius:8px;color:var(--text);text-decoration:none!important;font-size:.78rem}
.formula-item:hover{background:var(--bg-elevated)}
.formula-item>span{color:var(--gold);text-transform:uppercase;letter-spacing:.05em;font-size:.66rem}
.formula-item>strong{font-weight:500}
.formula-item>em{font-style:normal;color:var(--text-muted);font-size:.65rem;white-space:nowrap}
.formula-item.current{background:color-mix(in srgb,var(--gold) 12%,transparent);outline:1px solid var(--gold-dim)}
@media(max-width:480px){.logo-sub{display:none}.formula-menu{top:calc(100% + 10px)}}
