:root {
  --orange: #F57C00;
  --turquoise: #4DD0E1;
  --black: #000000;
  --white: #FFFFFF;
  --gray: #333333;
  --muted: #6b7280;
  --surface: #f5f7fa;
  --border: #e5e7eb;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  font-family: "Montserrat", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--gray);
  background: var(--white);
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

body.music-body {
  background: #0b0f14;
  color: #e5e7eb;
}

.container {
  width: min(1140px, calc(100% - 32px));
  margin: 0 auto;
}

.site-header {
  background: var(--white);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 20;
}

body.music-body .site-header {
  background: #0f172a;
  color: var(--white);
  border-bottom-color: #1e293b;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 64px;
  gap: 16px;
}

.brand {
  font-weight: 800;
  letter-spacing: 0.08em;
  color: var(--orange);
  text-decoration: none;
  font-size: 1.15rem;
}

.primary-nav {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.primary-nav a {
  color: var(--gray);
  text-decoration: none;
  padding: 8px 10px;
  border-radius: 6px;
  font-size: 0.95rem;
}

body.music-body .primary-nav a {
  color: #e5e7eb;
}

.primary-nav a:hover,
.primary-nav a:focus-visible,
.primary-nav a[aria-current="page"] {
  background: var(--orange);
  color: var(--black);
}

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 8px 10px;
  font-weight: 700;
  color: #ffffff;
  cursor: pointer;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 10px 16px;
  border-radius: 8px;
  border: 1px solid transparent;
  text-decoration: none;
  font-weight: 700;
  cursor: pointer;
}

.button-primary {
  background: var(--orange);
  color: var(--black);
}

.button-ghost {
  background: transparent;
  color: inherit;
  border-color: currentColor;
}

.site-main {
  flex: 1;
}

.hero {
  background: radial-gradient(circle at 15% 20%, rgba(77, 208, 225, 0.18), transparent 28%), #000;
  color: var(--white);
  padding: 70px 0 56px;
}

.hero.small {
  padding: 42px 0;
}

.hero h1 {
  max-width: 880px;
  margin: 0 0 18px;
  font-size: clamp(2.2rem, 6vw, 4.6rem);
  line-height: 1.05;
  font-weight: 800;
  color: var(--white);
}

.hero p {
  max-width: 720px;
  font-size: 1.2rem;
  color: #d1d5db;
  margin: 0 0 24px;
}

.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.preview-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 18px;
  margin-top: 38px;
  align-items: start;
}

.preview-note {
  color: #cbd5e1;
  font-size: 0.9rem;
}

.preview-card {
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 12px;
  padding: 20px;
}

.preview-card h3 {
  margin-top: 0;
  color: var(--turquoise);
}

.preview-numbers {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 16px;
}

.preview-number {
  background: rgba(0,0,0,0.35);
  padding: 14px;
  border-radius: 8px;
}

.preview-number span {
  display: block;
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--white);
}

.section {
  padding: 48px 0;
}

.section-light {
  background: var(--surface);
}

.section-title {
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  color: var(--black);
  margin: 0 0 22px;
}

body.music-body .section-title {
  color: var(--white);
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}

.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 20px;
  text-decoration: none;
  color: var(--gray);
}

body.music-body .card,
.song-card {
  background: #111827;
  border-color: #1f2937;
  color: #e5e7eb;
}

.card h3 {
  margin: 0 0 8px;
  color: #9a4200;
}

.dark-card h3 {
  color: var(--orange);
}

.song-card h3 {
  margin: 0 0 8px;
  color: var(--orange);
}

.dark-card {
  background: #111827;
  color: #e5e7eb;
  border-color: #1f2937;
}

.song-card img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 10px;
  display: block;
  background: #1f2937;
}

.song-card-body {
  padding: 12px 2px 4px;
}

.song-card-body p {
  color: #9ca3af;
  margin: 4px 0;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.song-card-actions {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-top: 10px;
}

.song-card-actions a,
.song-card-actions button {
  text-decoration: none;
  border: 1px solid var(--orange);
  color: var(--orange);
  background: transparent;
  border-radius: 8px;
  padding: 8px 10px;
  font-weight: 700;
  cursor: pointer;
}

#catalog-root {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  align-items: start;
  margin-bottom: 20px;
}

#catalog-root > .song-card {
  min-width: 0;
}

#catalog-root > .empty-state {
  grid-column: 1 / -1;
}

.toolbar button {
  min-height: 42px;
  padding: 10px 12px;
  border: 1px solid var(--orange);
  background: transparent;
  color: var(--orange);
  border-radius: 8px;
  font-weight: 700;
  cursor: pointer;
}

.toolbar button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

@media (max-width: 960px) {
  #catalog-root {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  #catalog-root {
    grid-template-columns: 1fr;
  }
}

.empty-state {
  text-align: center;
  padding: 48px 16px;
  border: 1px dashed var(--border);
  border-radius: 12px;
  background: var(--surface);
}

body.music-body .empty-state {
  background: #111827;
  border-color: #1f2937;
  color: #e5e7eb;
}

.toolbar {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 20px;
  align-items: center;
}

.toolbar label {
  font-weight: 700;
}

.toolbar input,
.toolbar select,
.inquiry-form input,
.inquiry-form textarea,
.inquiry-form select {
  padding: 10px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: #1f2937;
  color: #e5e7eb;
}

.toolbar input,
.toolbar select {
  background: #111827;
  color: #e5e7eb;
}

.inquiry-form {
  background: var(--white);
  color: var(--gray);
  border-radius: 14px;
  padding: 24px;
  border: 1px solid var(--border);
  max-width: 620px;
}

.inquiry-form label {
  display: block;
  margin: 16px 0 6px;
  font-weight: 700;
}

.inquiry-form input,
.inquiry-form textarea,
.inquiry-form select {
  width: 100%;
  background: var(--white);
  color: var(--gray);
}

.inquiry-form textarea {
  min-height: 130px;
  resize: vertical;
}

.form-status {
  min-height: 24px;
  margin-top: 12px;
  font-weight: 700;
}

.global-player {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 50;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  background: #0f172a;
  color: #e5e7eb;
  border-top: 1px solid #1f2937;
  padding: 10px 14px;
}

.global-audio {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.global-player button {
  background: var(--orange);
  color: var(--black);
  border: none;
  border-radius: 8px;
  padding: 8px 10px;
  font-weight: 700;
  cursor: pointer;
}

.global-player .player-now-playing {
  flex: 1 1 180px;
  font-weight: 700;
}

.global-player input[type="range"] {
  width: min(180px, 30vw);
}

.site-footer {
  background: #0b0f14;
  color: #cbd5e1;
  padding: 36px 0 16px;
  margin-bottom: 80px;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.site-footer h2 {
  color: var(--turquoise);
  font-size: 1rem;
  margin: 0 0 10px;
}

.site-footer a {
  color: #e5e7eb;
  text-decoration: none;
  display: block;
  padding: 4px 0;
}

.footer-note {
  grid-column: 1 / -1;
  border-top: 1px solid #1f2937;
  padding-top: 14px;
  color: #9ca3af;
  font-size: 0.85rem;
}

@media (max-width: 960px) {
  .card-grid,
  .preview-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .container {
    width: min(390px, calc(100% - 24px));
  }

  .nav-toggle {
    display: inline-block;
  }

  .primary-nav {
    display: none;
    width: 100%;
    flex-direction: column;
    align-items: stretch;
  }

  .primary-nav.open {
    display: flex;
  }

  .header-inner {
    flex-wrap: wrap;
  }

  .card-grid,
  .preview-grid,
  .footer-grid,
  .preview-numbers {
    grid-template-columns: 1fr;
  }

  .hero h1 {
    font-size: 2.2rem;
  }

  .global-player {
    flex-direction: column;
    align-items: flex-start;
  }

  .site-footer {
    margin-bottom: 150px;
  }
}

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

:focus-visible {
  outline: 3px solid var(--turquoise);
  outline-offset: 2px;
}

/* === Rev 2 overrides and new components === */
.site-header {
  background: #0b0f14;
  color: #ffffff;
  border-bottom: 1px solid #1f2937;
}

.primary-nav a,
body:not(.music-body) .primary-nav a {
  color: #e5e7eb;
}

.primary-nav a:hover,
.primary-nav a:focus-visible,
.primary-nav a[aria-current='page'] {
  background: var(--orange);
  color: var(--black);
}

[hidden] {
  display: none !important;
}

.brand {
  display: inline-flex;
  align-items: center;
  min-height: 48px;
  gap: 8px;
}

.brand-text {
  font-weight: 800;
  letter-spacing: 0.08em;
  color: var(--orange);
}

.brand-logo {
  height: 40px;
  width: auto;
  display: block;
}

.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 48px;
}

.footer-brand .brand-text {
  font-weight: 800;
  letter-spacing: 0.08em;
  color: var(--orange);
}

.footer-logo {
  height: 48px;
  width: auto;
  display: block;
  margin-bottom: 10px;
}

.site-footer {
  margin-bottom: 0;
}

body.music-body .site-footer {
  margin-bottom: 150px;
}

.hero {
  padding: 56px 0 48px;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(300px, 0.95fr);
  gap: 26px;
  align-items: center;
}

.hero-copy {
  min-width: 0;
}

.hero-copy h1 {
  font-size: clamp(2.1rem, 5vw, 4.2rem);
}

.inventory-preview {
  min-width: 0;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  padding: 16px;
}

.preview-note {
  display: block;
  margin-bottom: 10px;
  color: #cbd5e1;
  font-size: 0.85rem;
}

.mock-window {
  background: #0f172a;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid #1f2937;
}

.mock-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 12px;
  background: #111827;
  color: #cbd5e1;
  font-size: 0.8rem;
  border-bottom: 1px solid #1f2937;
}

.mock-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.78rem;
}

.mock-table th,
.mock-table td {
  padding: 8px 10px;
  text-align: left;
  border-bottom: 1px solid #1f2937;
  color: #e5e7eb;
  white-space: nowrap;
}

.mock-table th {
  color: #4dd0e1;
  font-weight: 700;
}

.mini-chart {
  display: flex;
  align-items: flex-end;
  gap: 10px;
  height: 96px;
  padding: 12px;
}

.bar {
  flex: 1;
  min-width: 12px;
  background: linear-gradient(180deg, #4dd0e1, #f57c00);
  border-radius: 6px 6px 2px 2px;
  height: var(--bar, 20%);
}

@media (max-width: 960px) {
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
}

@media (max-width: 640px) {
  .hero-grid {
    grid-template-columns: 1fr;
  }

  .inventory-preview {
    overflow-x: auto;
  }

  .mock-table {
    min-width: 340px;
  }

  .mini-chart {
    height: 80px;
  }

  .brand-logo {
    height: 32px;
  }

  .footer-logo {
    height: 40px;
  }
}
