:root {
  --black: #0e0e0e;
  --charcoal: #232323;
  --gold: #c6a357;
  --sun: #ffee86;
  --light: #f5f3ee;
  --line: rgba(245, 243, 238, 0.22);
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

.home-stage {
  position: relative;
  isolation: isolate;
  display: grid;
  min-height: 100vh;
  place-items: center;
  overflow: hidden;
}

.home-content {
  display: grid;
  justify-items: center;
  width: min(920px, 92vw);
  padding: 32px;
  text-align: center;
  transition: transform 180ms ease;
}

.cookie-visible .home-content {
  transform: translateY(-92px);
}

.home-logo {
  width: min(360px, 72vw);
  height: auto;
  margin-bottom: 30px;
}

.home-content h1 {
  margin-bottom: 10px;
  font-size: 9rem;
}

.home-actions {
  justify-content: center;
  margin-top: 28px;
}

.home-actions .button {
  min-width: 150px;
}

.home-about-section {
  padding: 64px clamp(20px, 5vw, 72px);
  border-top: 1px solid var(--line);
  background: #0d0d0d;
}

.home-about-tile {
  display: grid;
  width: min(760px, 100%);
  min-height: 260px;
  margin: 0 auto;
  align-content: end;
  gap: 12px;
  padding: 34px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #f2f0ea;
  color: #111;
  text-align: left;
}

.home-about-tile strong {
  font-family: Rockwell, Bahnschrift, "Segoe UI", sans-serif;
  font-size: 2.2rem;
}

.cookie-message {
  position: fixed;
  right: 18px;
  left: 18px;
  bottom: 18px;
  z-index: 20;
  display: flex;
  width: auto;
  max-width: 1100px;
  margin: 0 auto;
  align-items: center;
  gap: 20px;
  padding: 18px;
  border: 1px solid #666;
  border-radius: 6px;
  background: #f2f0ea;
  color: #111;
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.45);
}

.cookie-message p {
  flex: 1;
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.45;
}

.cookie-message .button {
  flex: 0 0 auto;
  border: 0;
  cursor: pointer;
}

.cookie-actions {
  display: flex;
  flex: 0 0 auto;
  gap: 8px;
}

.feedback-dialog form {
  display: grid;
  gap: 12px;
}

.feedback-dialog textarea {
  width: 100%;
  resize: vertical;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 12px;
  background: #171717;
  color: var(--light);
  font: inherit;
}

.feedback-copy {
  display: flex;
  align-items: center;
  gap: 9px;
}

.song-sort {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin: 0 0 22px;
}

.song-sort .button {
  border: 1px solid var(--line);
  cursor: pointer;
}

.songs-page {
  min-height: 100vh;
  background: #0d0d0d;
}

.songs-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 18px clamp(20px, 4vw, 60px);
  border-bottom: 1px solid var(--line);
  background: #111;
}

.songs-logo {
  display: block;
  width: 150px;
  height: auto;
}

.text-action {
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--sun);
  font: inherit;
  cursor: pointer;
}

.nav-account {
  max-width: 260px;
  overflow: hidden;
  color: var(--muted);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.songs-main {
  width: min(1280px, calc(100% - 40px));
  margin: 0 auto;
  padding: 56px 0 80px;
}

.songs-intro {
  margin-bottom: 34px;
}

.songs-intro h1 {
  margin-bottom: 22px;
  font-size: 7rem;
}

.songs-intro > p:last-child {
  color: var(--muted);
}

.song-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}

.song-tile {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #171717;
}

.video-open {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  padding: 0;
  overflow: hidden;
  border: 0;
  background: #000;
  cursor: pointer;
}

.video-open img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 180ms ease, opacity 180ms ease;
}

.video-open:hover img {
  transform: scale(1.025);
  opacity: 0.8;
}

.play-symbol {
  position: absolute;
  inset: 50% auto auto 50%;
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  border-radius: 50%;
  background: var(--sun);
  color: #111;
  font-size: 1.35rem;
  transform: translate(-50%, -50%);
}

.song-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  min-height: 76px;
  padding: 16px 18px;
}

.song-meta h2 {
  margin: 0;
  font-size: 1.15rem;
}

.story-open,
.lyrics-open {
  flex: 0 0 auto;
  padding: 9px 16px;
  border: 1px solid var(--sun);
  border-radius: 999px;
  background: transparent;
  color: var(--sun);
  font: inherit;
  cursor: pointer;
}

.song-actions {
  display: flex;
  flex: 0 0 auto;
  gap: 8px;
}

.lyrics-content {
  max-width: 720px;
  margin: 0 auto;
  white-space: pre-wrap;
  color: #171717;
  font-family: Georgia, serif;
  font-size: 1.05rem;
  line-height: 1.7;
}

.feature-tile {
  display: flex;
  min-height: 300px;
  align-items: flex-end;
  padding: 28px;
  background-position: center;
  background-size: cover;
}

.meloverse-tile {
  background-image: linear-gradient(0deg, rgba(5, 5, 5, 0.92), rgba(5, 5, 5, 0.3)), url("assets/hero.png");
}

.about-tile {
  background: #f2f0ea;
  color: #111;
}

.feature-copy h2 {
  margin-bottom: 12px;
  font-size: 2rem;
}

.feature-open {
  display: block;
  width: calc(100% + 56px);
  min-height: 300px;
  margin: -28px;
  padding: 28px;
  border: 0;
  background: transparent;
  color: inherit;
  text-align: left;
  cursor: pointer;
}

.feature-copy {
  display: grid;
  align-content: end;
  min-height: 244px;
}

.feature-copy strong {
  margin-bottom: 12px;
  font-family: Rockwell, Bahnschrift, "Segoe UI", sans-serif;
  font-size: 2rem;
}

.feature-copy p:last-child {
  margin-bottom: 0;
  line-height: 1.55;
}

.media-dialog,
.story-dialog,
.info-dialog,
.software-dialog {
  width: min(1100px, calc(100vw - 32px));
  max-height: calc(100vh - 32px);
  padding: 24px;
  border: 1px solid #555;
  border-radius: 6px;
  background: #111;
  color: var(--light);
}

.media-dialog::backdrop,
.story-dialog::backdrop,
.info-dialog::backdrop,
.software-dialog::backdrop {
  background: rgba(0, 0, 0, 0.86);
}

.dialog-close {
  display: grid;
  width: 42px;
  height: 42px;
  margin-left: auto;
  place-items: center;
  border: 1px solid #666;
  border-radius: 50%;
  background: transparent;
  color: var(--light);
  font-size: 1.7rem;
  cursor: pointer;
}

.video-frame {
  width: 100%;
  aspect-ratio: 16 / 9;
}

.video-frame iframe {
  width: 100%;
  height: 100%;
  border: 0;
}

.story-dialog {
  overflow: auto;
  background: #f5f3ee;
  color: #171717;
}

.story-toolbar {
  position: sticky;
  top: -24px;
  z-index: 1;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  margin: -24px -24px 36px;
  padding: 24px;
  border-bottom: 1px solid #d4d0c7;
  background: #f5f3ee;
}

.story-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.story-actions .button {
  border: 0;
  cursor: pointer;
}

.story-toolbar h2 {
  margin: 0;
  font-size: 2rem;
}

.story-toolbar .dialog-close {
  color: #171717;
}

.story-content {
  width: min(720px, 100%);
  margin: 0 auto;
  font-family: Georgia, serif;
  font-size: 1.08rem;
  line-height: 1.75;
}

.story-content > h2:first-child {
  font-size: 2.5rem;
  text-align: center;
}

.story-content h3 {
  margin: 70px 0 8px;
  font-family: Impact, Rockwell, sans-serif;
  font-size: 1rem;
  letter-spacing: 0.12em;
  text-align: center;
}

.story-content h4 {
  margin: 0 0 32px;
  font-family: Georgia, serif;
  font-size: 2rem;
  text-align: center;
}

.info-dialog {
  width: min(760px, calc(100vw - 32px));
  padding: 38px;
}

.info-dialog h2 {
  margin-bottom: 24px;
}

.info-dialog h3 {
  margin-top: 36px;
  color: var(--sun);
  font-size: 1.35rem;
}

.info-dialog p {
  color: rgba(245, 243, 238, 0.8);
  line-height: 1.7;
}

.software-account {
  margin-bottom: 34px;
  padding: 22px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.software-account .actions {
  margin-top: 16px;
}

.software-account button {
  border: 0;
  cursor: pointer;
}

.software-tile-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
}

.software-tile {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #171717;
}

.software-card-open {
  display: grid;
  width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--light);
  text-align: left;
  cursor: pointer;
}

.software-tile-visual {
  position: relative;
  display: grid;
  min-height: 280px;
  place-items: center;
  overflow: hidden;
  font-family: Impact, Rockwell, sans-serif;
  font-size: 3.2rem;
  text-align: center;
  text-transform: uppercase;
}

.toolbox-visual {
  background: var(--gold);
  color: #111;
}

.builder-visual {
  background: #101010;
  color: var(--light);
}

.builder-visual img {
  position: absolute;
  width: 210px;
  height: 210px;
  opacity: 0.5;
}

.builder-visual span {
  position: relative;
  z-index: 1;
  max-width: 420px;
}

.software-tile-copy {
  display: grid;
  min-height: 132px;
  gap: 9px;
  padding: 20px;
}

.software-tile-copy strong {
  font-size: 1.35rem;
}

.software-tile-copy > span:not(.tile-action) {
  color: var(--muted);
}

.tile-action {
  color: var(--sun);
}

.software-dialog {
  width: min(980px, calc(100vw - 32px));
  overflow: auto;
}

.software-dialog-toolbar {
  position: sticky;
  top: -24px;
  z-index: 2;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  margin: -24px -24px 28px;
  padding: 24px;
  border-bottom: 1px solid var(--line);
  background: #111;
}

.software-dialog-toolbar h2 {
  margin: 0;
  font-size: 2.6rem;
}

.software-dialog-copy {
  width: min(760px, 100%);
  margin: 0 auto;
}

.software-dialog-copy p {
  color: rgba(245, 243, 238, 0.8);
  line-height: 1.7;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--black);
  color: var(--light);
  font-family: Bahnschrift, "Segoe UI", Arial, sans-serif;
}

a {
  color: inherit;
}

.site-shell {
  min-height: 100vh;
  overflow-x: hidden;
}

.hero {
  position: relative;
  min-height: 92vh;
  display: grid;
  grid-template-rows: auto 1fr auto;
  isolation: isolate;
}

.install-hero {
  position: relative;
  min-height: 74vh;
  display: grid;
  grid-template-rows: auto 1fr;
  isolation: isolate;
}

.hero-image,
.hero-shade {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.hero-image {
  object-fit: cover;
  opacity: 0.62;
  z-index: -3;
}

.hero-shade {
  background:
    radial-gradient(circle at 22% 42%, rgba(198, 163, 87, 0.18), transparent 24rem),
    linear-gradient(90deg, rgba(14, 14, 14, 0.92), rgba(14, 14, 14, 0.45) 48%, rgba(14, 14, 14, 0.88));
  z-index: -2;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 28px clamp(20px, 5vw, 72px);
}

.brand,
.nav {
  display: flex;
  align-items: center;
  gap: 16px;
}

.brand {
  text-decoration: none;
  font-weight: 700;
  letter-spacing: 0;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 999px;
  background: var(--light);
  color: var(--black);
  font-weight: 900;
}

.nav a {
  text-decoration: none;
  color: rgba(245, 243, 238, 0.78);
  font-size: 0.95rem;
}

.nav a:hover {
  color: var(--sun);
}

.hero-content {
  align-self: center;
  width: min(960px, 92vw);
  padding: clamp(24px, 6vw, 84px);
}

.install-content {
  align-self: center;
  width: min(980px, 92vw);
  padding: clamp(24px, 6vw, 84px);
}

.eyebrow {
  margin: 0 0 14px;
  color: var(--gold);
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.82rem;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 20px;
  font-family: Impact, Rockwell, Bahnschrift, sans-serif;
  font-size: clamp(5rem, 18vw, 17rem);
  line-height: 0.78;
  letter-spacing: 0;
  text-transform: uppercase;
}

.install-title {
  font-size: clamp(3.6rem, 11vw, 10rem);
}

.lead,
.brand-line {
  max-width: 650px;
  color: rgba(245, 243, 238, 0.82);
  font-size: clamp(1.15rem, 2vw, 1.55rem);
  line-height: 1.45;
}

.brand-line {
  max-width: 820px;
  margin-bottom: 0;
  color: var(--light);
  font-family: Rockwell, Bahnschrift, "Segoe UI", sans-serif;
  font-size: clamp(1.35rem, 2.6vw, 2.35rem);
  font-weight: 700;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 34px;
}

.installer-status {
  margin-top: 14px;
  color: rgba(245, 243, 238, 0.68);
  font-size: 0.95rem;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 24px;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 800;
}

.button.primary {
  background: var(--gold);
  color: var(--black);
}

.button.secondary {
  background: var(--light);
  color: var(--black);
}

.button.small {
  min-height: 40px;
  margin-top: 18px;
}

.scroll-hint {
  padding: 0 clamp(20px, 5vw, 72px) 34px;
  color: rgba(245, 243, 238, 0.52);
}

.section {
  padding: clamp(56px, 8vw, 110px) clamp(20px, 5vw, 72px);
  background: var(--black);
  border-top: 1px solid var(--line);
}

.section.alt {
  background: #151515;
}

.section-grid {
  display: grid;
  grid-template-columns: minmax(220px, 0.8fr) minmax(280px, 1.2fr);
  gap: clamp(28px, 5vw, 80px);
  align-items: start;
}

h2 {
  font-family: Rockwell, Bahnschrift, "Segoe UI", sans-serif;
  font-size: clamp(2rem, 5vw, 4rem);
  line-height: 1;
}

.panel,
.mini-card {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(245, 243, 238, 0.06);
  padding: 28px;
}

.steps-panel {
  display: grid;
  gap: 14px;
}

.software-options {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 18px;
}

.account-panel {
  margin-bottom: 18px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 18px;
}

.account-panel .button {
  border: 0;
  cursor: pointer;
}

.software-option {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(245, 243, 238, 0.06);
  padding: 24px;
}

.software-option p {
  color: rgba(245, 243, 238, 0.78);
  line-height: 1.65;
}

.software-option h4 {
  margin: 4px 0 18px;
  color: var(--sun);
  font-size: 1.25rem;
}

.software-option .software-close {
  color: var(--light);
  font-weight: 800;
}

.requirement-note {
  color: rgba(245, 243, 238, 0.66);
  font-size: 0.9rem;
}

.release-list {
  display: grid;
  gap: 8px;
  margin-top: 20px;
}

.release-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  border-top: 1px solid var(--line);
  padding-top: 10px;
}

.release-name {
  font-weight: 800;
}

.release-meta {
  margin-top: 3px;
  color: rgba(245, 243, 238, 0.62);
  font-size: 0.82rem;
}

.release-badge {
  color: var(--sun);
  text-transform: uppercase;
}

.release-row .button {
  min-height: 36px;
  padding: 0 15px;
}

.step-card {
  display: grid;
  grid-template-columns: 48px 1fr;
  gap: 18px;
  align-items: start;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(245, 243, 238, 0.06);
  padding: 22px;
}

.step-card span {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 999px;
  background: var(--gold);
  color: var(--black);
  font-weight: 900;
}

.step-card h3 {
  margin-bottom: 6px;
  color: var(--sun);
}

.step-card p {
  margin-bottom: 0;
  color: rgba(245, 243, 238, 0.76);
  line-height: 1.55;
}

.panel p,
.mini-card p {
  color: rgba(245, 243, 238, 0.76);
  line-height: 1.6;
}

.identity-copy {
  max-width: 780px;
  font-size: clamp(1.05rem, 1.5vw, 1.3rem);
  line-height: 1.7;
}

.identity-copy p {
  color: rgba(245, 243, 238, 0.82);
}

.identity-copy .identity-close {
  margin-bottom: 0;
  color: var(--light);
  font-weight: 700;
}

.cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.mini-card h3 {
  margin-bottom: 8px;
  color: var(--sun);
}

@media (max-width: 760px) {
  .topbar {
    align-items: flex-start;
  }

  .nav {
    gap: 10px;
    flex-wrap: wrap;
    justify-content: flex-end;
  }

  .nav-account {
    order: 3;
    width: 100%;
    max-width: 190px;
    font-size: 0.82rem;
  }

  .hero {
    min-height: 88vh;
  }

  .section-grid,
  .cards,
  .software-options {
    grid-template-columns: 1fr;
  }

  .home-logo {
    width: min(280px, 76vw);
  }

  .home-content h1 {
    font-size: 4.2rem;
  }

  .songs-intro h1 {
    font-size: 4rem;
  }

  .songs-header {
    align-items: flex-start;
  }

  .songs-logo {
    width: 110px;
  }

  .song-grid {
    grid-template-columns: 1fr;
  }

  .software-tile-grid {
    grid-template-columns: 1fr;
  }

  .feature-tile {
    min-height: 240px;
  }

  .media-dialog,
  .story-dialog,
  .info-dialog,
  .software-dialog {
    padding: 16px;
  }

  .story-toolbar {
    top: -16px;
    margin: -16px -16px 28px;
    padding: 16px;
  }

  .story-toolbar {
    align-items: center;
  }

  .story-actions {
    align-items: flex-end;
    flex-direction: column-reverse;
  }

  .story-actions .button {
    min-height: 38px;
    padding: 0 14px;
  }

  .cookie-message {
    align-items: stretch;
    flex-direction: column;
  }

  .cookie-visible .home-content {
    transform: translateY(-136px);
  }

  .cookie-message,
  .cookie-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .song-sort {
    justify-content: stretch;
  }

  .song-sort .button {
    flex: 1;
  }

  .software-dialog-toolbar {
    top: -16px;
    margin: -16px -16px 24px;
    padding: 16px;
  }
}
