:root {
  --bg: #050505;
  --bg-elev: #0c0c0c;
  --fg: #f2f2f2;
  --muted: #8a8a8a;
  --line: rgba(255, 255, 255, 0.08);
  --line-strong: rgba(255, 255, 255, 0.16);
  --accent: #ffffff;
  --danger: #ff6b6b;
  --ok: #7dffa3;
  --radius: 14px;
  --font: "Helvetica Neue", Helvetica, Arial, system-ui, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font);
  min-height: 100%;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body {
  position: relative;
}

.noise {
  pointer-events: none;
  position: fixed;
  inset: 0;
  z-index: 0;
  opacity: 0.04;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' 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");
}

.site-header,
main,
.site-footer {
  position: relative;
  z-index: 1;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.25rem clamp(1rem, 3vw, 2.5rem);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  backdrop-filter: blur(12px);
  background: rgba(5, 5, 5, 0.72);
  z-index: 10;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 2rem;
  height: 2rem;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  font-weight: 600;
}

.brand-name {
  font-size: 0.95rem;
  letter-spacing: 0.04em;
  font-weight: 500;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.unlock-status {
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.unlock-status[data-state="unlocked"] {
  color: var(--ok);
}

.hero {
  padding: clamp(1rem, 3vw, 2rem) clamp(1rem, 3vw, 2.5rem) 0;
}

.hero-frame {
  position: relative;
  overflow: hidden;
  border-radius: calc(var(--radius) + 4px);
  border: 1px solid var(--line);
  background: #000;
  aspect-ratio: 21 / 9;
  min-height: 220px;
  max-height: 520px;
}

.hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: saturate(0.85) contrast(1.05);
}

.hero-veil {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0.15) 0%,
    rgba(0, 0, 0, 0.55) 55%,
    rgba(0, 0, 0, 0.85) 100%
  );
}

.hero-copy {
  position: absolute;
  left: clamp(1rem, 3vw, 2.5rem);
  right: clamp(1rem, 3vw, 2.5rem);
  bottom: clamp(1rem, 3vw, 2rem);
  max-width: 36rem;
}

.eyebrow {
  margin: 0 0 0.4rem;
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
}

.hero-copy h1 {
  margin: 0 0 0.5rem;
  font-size: clamp(1.8rem, 4vw, 3rem);
  font-weight: 500;
  letter-spacing: -0.02em;
}

.lede {
  margin: 0;
  color: #cfcfcf;
  font-size: clamp(0.9rem, 1.6vw, 1.05rem);
  line-height: 1.5;
  max-width: 34ch;
}

.catalog-section {
  padding: clamp(2rem, 5vw, 3.5rem) clamp(1rem, 3vw, 2.5rem);
}

.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.25rem;
  border-bottom: 1px solid var(--line);
  padding-bottom: 0.75rem;
}

.section-head h2 {
  margin: 0;
  font-size: 0.85rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-weight: 500;
}

.meta {
  margin: 0;
  color: var(--muted);
  font-size: 0.8rem;
}

.song-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

@media (min-width: 640px) {
  .song-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 960px) {
  .song-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (min-width: 1280px) {
  .song-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.card {
  display: flex;
  flex-direction: column;
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  transition: border-color 160ms ease, transform 160ms ease,
    box-shadow 160ms ease;
}

.card:hover {
  border-color: var(--line-strong);
  transform: translateY(-2px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.45);
}

.card-media {
  position: relative;
  aspect-ratio: 1;
  background: #111;
  overflow: hidden;
}

.card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 280ms ease;
}

.card:hover .card-media img {
  transform: scale(1.03);
}

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

.card-title {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 500;
  letter-spacing: -0.01em;
  line-height: 1.35;
  min-height: 2.6em;
}

.card-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: auto;
}

.btn,
.ghost-btn,
a.btn {
  appearance: none;
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 0.55rem 0.95rem;
  font: inherit;
  font-size: 0.8rem;
  letter-spacing: 0.04em;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  transition: background 140ms ease, color 140ms ease, border-color 140ms ease,
    opacity 140ms ease;
}

.btn {
  background: var(--accent);
  color: #050505;
  font-weight: 600;
}

.btn:hover {
  opacity: 0.9;
}

.btn-secondary {
  background: transparent;
  color: var(--fg);
  border-color: var(--line-strong);
}

.btn-secondary:hover {
  border-color: #fff;
  background: rgba(255, 255, 255, 0.04);
}

.ghost-btn {
  background: transparent;
  color: var(--muted);
  border-color: transparent;
  padding-inline: 0.65rem;
}

.ghost-btn:hover {
  color: var(--fg);
}

.demo-section {
  padding: 0 clamp(1rem, 3vw, 2.5rem) clamp(2rem, 5vw, 3.5rem);
}

.demo-card {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.25rem 1.35rem;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.02);
}

.demo-title {
  margin: 0.15rem 0 0.35rem;
  font-family: var(--mono);
  font-size: 0.95rem;
}

.demo-note {
  margin: 0;
  color: var(--muted);
  font-size: 0.85rem;
  max-width: 48ch;
  line-height: 1.45;
}

.demo-note code {
  font-family: var(--mono);
  font-size: 0.8em;
  color: var(--fg);
}

.site-footer {
  padding: 1.5rem clamp(1rem, 3vw, 2.5rem) 2.5rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.75rem;
  letter-spacing: 0.06em;
}

.site-footer p {
  margin: 0;
}

/* Modal */
.modal {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: center;
  padding: 1rem;
}

.modal.hidden,
.hidden {
  display: none !important;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(4px);
}

.modal-panel {
  position: relative;
  width: min(100%, 380px);
  background: #0e0e0e;
  border: 1px solid var(--line-strong);
  border-radius: calc(var(--radius) + 2px);
  padding: 1.35rem 1.35rem 1.2rem;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.65);
}

.modal-panel h3 {
  margin: 0 0 0.35rem;
  font-size: 1.1rem;
  font-weight: 500;
}

.modal-copy {
  margin: 0 0 1rem;
  color: var(--muted);
  font-size: 0.85rem;
  line-height: 1.45;
}

#password {
  width: 100%;
  padding: 0.7rem 0.85rem;
  border-radius: 10px;
  border: 1px solid var(--line-strong);
  background: #050505;
  color: var(--fg);
  font: inherit;
  margin-bottom: 0.75rem;
}

#password:focus {
  outline: 1px solid #fff;
  outline-offset: 1px;
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.5rem;
}

.error {
  color: var(--danger);
  font-size: 0.8rem;
  margin: 0 0 0.75rem;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
