/* ============================================================
   MatrixFR — Shared Design System
   Bruno-polished retro-pop · coral + pink on near-black
   ============================================================ */

:root {
  /* Palette */
  --coral: #ff6250;
  --coral-bright: #ff8a7a;
  --pink: #ffdbd8;
  --pink-deep: #f5b4ad;
  --black: #0a0a0a;
  --ink: #1a1a1a;
  --surface: #161616;
  --cream: #fff5f0;
  --white: #ffffff;
  --muted: rgba(255, 245, 240, 0.62);
  --border: rgba(255, 245, 240, 0.12);

  /* Typography */
  --font-display: 'Anton', 'Archivo Black', 'Arial Black', sans-serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  /* Geometry */
  --radius-pill: 999px;
  --radius-card: 14px;
  --radius-tile: 8px;
  --shadow-card: 0 18px 40px rgba(0, 0, 0, 0.35);
  --shadow-coral: 0 10px 30px rgba(255, 98, 80, 0.35);
  --max-width: 1280px;

  /* Nav height (used to offset content below transparent nav) */
  --nav-h: 78px;
}

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--font-body);
  background: var(--black);
  color: var(--cream);
  line-height: 1.6;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, svg { max-width: 100%; display: block; }

a { color: inherit; text-decoration: none; transition: color 0.18s ease; }
a:hover { color: var(--coral); }

button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }

::selection { background: var(--coral); color: var(--black); }

/* ============= TYPOGRAPHY ============= */
.display {
  font-family: var(--font-display);
  font-weight: 400; /* Anton is intrinsically heavy */
  text-transform: uppercase;
  letter-spacing: 0.02em;
  line-height: 0.95;
}
h1, h2, h3 { font-family: var(--font-display); text-transform: uppercase; letter-spacing: 0.02em; line-height: 1; font-weight: 400; }
h1 { font-size: clamp(48px, 9vw, 132px); }
h2 { font-size: clamp(34px, 5.5vw, 72px); }
h3 { font-size: clamp(22px, 2.8vw, 34px); }

.eyebrow {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--coral);
  padding: 6px 12px;
  border: 1px solid var(--coral);
  border-radius: var(--radius-pill);
  background: rgba(255, 98, 80, 0.08);
}

.lede {
  font-size: clamp(17px, 1.8vw, 22px);
  line-height: 1.55;
  color: var(--cream);
  max-width: 56ch;
}

/* ============= LAYOUT ============= */
.container { width: 100%; max-width: var(--max-width); margin: 0 auto; padding: 0 24px; }
.container-narrow { width: 100%; max-width: 920px; margin: 0 auto; padding: 0 24px; }

.section { padding: clamp(72px, 10vw, 128px) 0; position: relative; }
.section-tight { padding: clamp(48px, 6vw, 80px) 0; }
.section-dark { background: var(--black); }
.section-ink { background: var(--ink); }
.section-cream { background: var(--cream); color: var(--black); }
.section-cream h1, .section-cream h2, .section-cream h3 { color: var(--black); }
.section-cream .eyebrow { color: var(--coral); border-color: var(--coral); background: rgba(255, 98, 80, 0.12); }
.section-coral { background: var(--coral); color: var(--black); }
.section-coral .eyebrow { color: var(--black); border-color: var(--black); background: transparent; }

.section-head { margin-bottom: clamp(36px, 5vw, 64px); display: flex; flex-direction: column; gap: 18px; align-items: flex-start; }

/* ============= NAV ============= */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 80;
  height: var(--nav-h);
  display: flex; align-items: center;
  transition: background 0.25s ease, backdrop-filter 0.25s ease, border-color 0.25s ease;
  border-bottom: 1px solid transparent;
}
body.nav-scrolled .nav,
body.nav-solid .nav {
  background: rgba(10, 10, 10, 0.78);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-bottom-color: var(--border);
}
.nav-inner {
  width: 100%; max-width: var(--max-width); margin: 0 auto; padding: 0 24px;
  display: grid; grid-template-columns: auto 1fr auto; gap: 24px; align-items: center;
}

.nav-brand {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-display); font-size: 26px; letter-spacing: 0.04em;
  color: var(--cream);
}
.nav-brand .matrix { color: var(--cream); }
.nav-brand .fr { color: var(--coral); }
.nav-brand:hover { color: var(--cream); }

.nav-links {
  display: flex; gap: 36px; justify-self: center;
  font-size: 12px; letter-spacing: 0.22em; text-transform: uppercase; font-weight: 600;
}
.nav-links a { color: var(--cream); opacity: 0.88; padding: 6px 0; position: relative; }
.nav-links a:hover { opacity: 1; color: var(--coral); }
.nav-links a.active::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: -6px; height: 2px; background: var(--coral); border-radius: 1px;
}

.nav-tools { display: flex; align-items: center; gap: 6px; }
.nav-btn {
  width: 40px; height: 40px; display: inline-flex; align-items: center; justify-content: center;
  border-radius: 50%; color: var(--cream); transition: background 0.18s ease, color 0.18s ease;
}
.nav-btn:hover { background: rgba(255, 245, 240, 0.08); color: var(--coral); }
.nav-btn svg { width: 18px; height: 18px; }
.nav-subscribe {
  margin-left: 8px; padding: 10px 18px; font-size: 11px; letter-spacing: 0.22em; text-transform: uppercase; font-weight: 700;
  background: var(--coral); color: var(--black); border-radius: var(--radius-pill);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}
.nav-subscribe:hover { transform: translateY(-1px); box-shadow: var(--shadow-coral); color: var(--black); }
.nav-cart-count {
  position: absolute; top: 4px; right: 4px;
  min-width: 16px; height: 16px; padding: 0 4px;
  font-family: var(--font-body); font-size: 10px; font-weight: 700; letter-spacing: 0;
  background: var(--coral); color: var(--black); border-radius: 999px;
  display: inline-flex; align-items: center; justify-content: center;
  pointer-events: none;
}

.nav-toggle { display: none; width: 40px; height: 40px; border-radius: 50%; color: var(--cream); }
.nav-toggle svg { width: 22px; height: 22px; }

/* ============= BUTTONS ============= */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 14px 28px;
  font-family: var(--font-body); font-size: 13px; font-weight: 700; letter-spacing: 0.18em; text-transform: uppercase;
  border-radius: var(--radius-pill);
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease, color 0.18s ease;
  cursor: pointer; white-space: nowrap;
}
.btn-coral { background: var(--coral); color: var(--black); }
.btn-coral:hover { background: var(--coral-bright); transform: translateY(-2px); box-shadow: var(--shadow-coral); color: var(--black); }
.btn-ghost { background: transparent; color: var(--cream); border: 1.5px solid var(--cream); }
.btn-ghost:hover { background: var(--cream); color: var(--black); transform: translateY(-2px); }
.btn-dark { background: var(--black); color: var(--cream); }
.btn-dark:hover { background: var(--ink); color: var(--coral); transform: translateY(-2px); }
.btn-large { padding: 18px 36px; font-size: 14px; }

/* ============= STREAMING BUTTONS ============= */
.streaming-row {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px;
}
.stream-btn {
  display: flex; flex-direction: column; align-items: center; gap: 10px;
  padding: 22px 18px;
  background: var(--ink); border: 1px solid var(--border); border-radius: var(--radius-card);
  color: var(--cream);
  transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}
.stream-btn:hover { transform: translateY(-3px); border-color: var(--coral); color: var(--coral); background: var(--surface); }
.stream-btn .stream-icon { width: 36px; height: 36px; display: inline-flex; align-items: center; justify-content: center; }
.stream-btn .stream-icon svg { width: 100%; height: 100%; }
.stream-btn .stream-label { font-size: 11px; letter-spacing: 0.22em; text-transform: uppercase; font-weight: 700; }

/* ============= CARDS ============= */
.card-grid { display: grid; gap: 22px; }
.card-grid.cols-2 { grid-template-columns: repeat(2, 1fr); }
.card-grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
.card-grid.cols-4 { grid-template-columns: repeat(4, 1fr); }

/* ============= PAGE LAYOUT HELPERS ============= */
/* Latest-release split: album art + copy. Stacks on mobile so the album
   art doesn't shrink to a thumbnail next to the body text. */
.release-grid {
  display: grid; grid-template-columns: 5fr 4fr; gap: 48px; align-items: center;
}
/* Gallery: 4-column photo strip on desktop, 2 columns on phone so the
   tiles stay viewable instead of collapsing to postage stamps. */
.gallery-strip { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }

/* ============= MOBILE CARD CAROUSEL ============= */
/* Modifier for .card-grid that swaps the grid into a horizontal snap-scroll
   row on small viewports. Each child becomes ~85% of the viewport so the
   next card "peeks" at the right edge, signalling there's more to swipe.
   Used on the announcements section so it doesn't stack into a tall column. */
.card-grid.scroll-mobile { /* desktop fallback: behaves like normal grid */ }
@media (max-width: 720px) {
  .card-grid.scroll-mobile {
    display: flex;
    grid-template-columns: none;
    gap: 16px;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    touch-action: pan-x;
    scrollbar-width: none;
    padding-bottom: 8px;
    /* Stay inside .container's 24px gutter — no negative-margin bleed.
       body has overflow-x:hidden which was clipping the bleed and breaking
       touch scroll on iOS. */
  }
  .card-grid.scroll-mobile::-webkit-scrollbar { display: none; }
  .card-grid.scroll-mobile > * {
    flex: 0 0 calc(100% - 40px);
    scroll-snap-align: start;
    box-sizing: border-box;
  }
}

.card {
  background: var(--ink); border-radius: var(--radius-card); overflow: hidden;
  border: 1px solid var(--border);
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
  display: flex; flex-direction: column;
}
.card:hover { transform: translateY(-4px); border-color: var(--coral); box-shadow: var(--shadow-card); }
.card-media {
  aspect-ratio: 4 / 5; background: linear-gradient(135deg, var(--coral) 0%, var(--pink) 100%);
  position: relative; overflow: hidden;
}
.card-media.aspect-1 { aspect-ratio: 1 / 1; }
.card-media.aspect-16-9 { aspect-ratio: 16 / 9; }
.card-media img { width: 100%; height: 100%; object-fit: cover; }
.card-media-placeholder {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  font-family: var(--font-display); font-size: 56px; color: rgba(10, 10, 10, 0.25);
  text-transform: uppercase; letter-spacing: 0.1em;
}
.card-body { padding: 22px; display: flex; flex-direction: column; gap: 8px; }
.card-title { font-family: var(--font-display); font-size: 22px; text-transform: uppercase; letter-spacing: 0.04em; color: var(--cream); }
.card-meta { font-size: 12px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--muted); }
.card-price { font-family: var(--font-display); font-size: 24px; color: var(--coral); }

/* ============= TOUR LIST ============= */
.tour-list { display: flex; flex-direction: column; }
.tour-row {
  display: grid; grid-template-columns: 110px 1fr auto; gap: 24px; align-items: center;
  padding: 22px 4px; border-bottom: 1px solid var(--border);
  transition: padding-left 0.2s ease, background 0.2s ease;
}
.tour-row:hover { padding-left: 14px; background: rgba(255, 98, 80, 0.04); }
.tour-row:last-child { border-bottom: none; }
.tour-date { font-family: var(--font-display); font-size: 30px; color: var(--coral); line-height: 1; }
.tour-date .day { display: block; font-size: 14px; color: var(--muted); letter-spacing: 0.18em; margin-top: 6px; text-transform: uppercase; }
.tour-info .venue { font-family: var(--font-display); font-size: 24px; text-transform: uppercase; letter-spacing: 0.03em; color: var(--cream); }
.tour-info .city { font-size: 13px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--muted); margin-top: 4px; }
.tour-row.sold-out .tour-info .venue { color: var(--muted); }
.tour-status {
  font-size: 11px; letter-spacing: 0.22em; text-transform: uppercase; font-weight: 700;
  padding: 8px 14px; border-radius: var(--radius-pill);
  background: var(--coral); color: var(--black);
}
.tour-row.sold-out .tour-status { background: var(--surface); color: var(--muted); border: 1px solid var(--border); }
.tour-row.tba .tour-status { background: transparent; color: var(--muted); border: 1px solid var(--border); }

/* ============= FOOTER ============= */
.site-footer {
  background: var(--black); color: var(--muted); padding: 80px 0 28px;
  border-top: 1px solid var(--border);
}
.footer-grid {
  display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 56px;
  margin-bottom: 48px;
}
.footer-brand .nav-brand { font-size: 36px; }
.footer-brand p { margin-top: 16px; font-size: 13px; max-width: 320px; line-height: 1.7; }
.footer-col h4 {
  font-family: var(--font-body); font-size: 11px; letter-spacing: 0.28em; text-transform: uppercase; font-weight: 700;
  color: var(--cream); margin-bottom: 16px;
}
.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.footer-col a { font-size: 13px; color: var(--muted); }
.footer-col a:hover { color: var(--coral); }
.footer-social { display: flex; gap: 12px; margin-top: 24px; }
.footer-social a {
  width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--border);
  display: inline-flex; align-items: center; justify-content: center; color: var(--cream);
}
.footer-social a:hover { background: var(--coral); color: var(--black); border-color: var(--coral); }
.footer-social svg { width: 16px; height: 16px; }
.footer-bottom {
  padding-top: 24px; border-top: 1px solid var(--border);
  display: flex; justify-content: space-between; gap: 24px; flex-wrap: wrap;
  font-size: 12px; color: var(--muted);
}
.footer-legal { display: flex; gap: 22px; flex-wrap: wrap; }

/* ============= MAILING LIST MODAL ============= */
.modal-backdrop {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(0, 0, 0, 0.74);
  display: none; align-items: center; justify-content: center;
  padding: 24px;
}
.modal-backdrop.open { display: flex; animation: fadeIn 0.2s ease; }
.modal {
  width: 100%; max-width: 480px; background: var(--ink); color: var(--cream);
  border-radius: var(--radius-card); border: 1px solid var(--border);
  padding: 40px 32px 32px; position: relative;
  text-align: center;
  animation: popIn 0.25s ease;
}
.modal h3 { font-size: 32px; margin-bottom: 10px; }
.modal-eyebrow { color: var(--coral); font-size: 11px; letter-spacing: 0.3em; text-transform: uppercase; font-weight: 700; margin-bottom: 16px; display: block; }
.modal p { font-size: 14px; color: var(--muted); margin-bottom: 24px; line-height: 1.6; }
.modal-form { display: flex; gap: 8px; flex-direction: column; }
.modal-form input {
  width: 100%; padding: 14px 18px; border-radius: var(--radius-pill);
  background: var(--surface); border: 1px solid var(--border); color: var(--cream);
  font-family: inherit; font-size: 14px;
}
.modal-form input:focus { outline: none; border-color: var(--coral); }
.modal-form .btn { width: 100%; }
.modal-close {
  position: absolute; top: 14px; right: 14px;
  width: 32px; height: 32px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  color: var(--muted);
}
.modal-close:hover { color: var(--coral); background: rgba(255, 245, 240, 0.06); }
.modal-fine { font-size: 11px; color: var(--muted); margin-top: 14px; }

/* ============= COOKIE BANNER ============= */
.cookie-banner {
  position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 90;
  display: none; gap: 18px; align-items: center; flex-wrap: wrap;
  background: var(--ink); color: var(--cream);
  border: 1px solid var(--border); border-radius: var(--radius-card);
  padding: 18px 22px;
  box-shadow: var(--shadow-card);
}
.cookie-banner.show { display: flex; }
.cookie-banner p { font-size: 13px; flex: 1; min-width: 260px; line-height: 1.5; color: var(--cream); }
.cookie-banner p a { color: var(--coral); text-decoration: underline; text-underline-offset: 3px; }
.cookie-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.cookie-actions .btn { padding: 10px 18px; font-size: 11px; }
.cookie-prefs {
  display: none; position: absolute; bottom: calc(100% + 8px); right: 16px;
  background: var(--ink); border: 1px solid var(--border); border-radius: var(--radius-card);
  padding: 22px; width: min(360px, 92vw);
  box-shadow: var(--shadow-card);
}
.cookie-prefs.open { display: block; }
.cookie-prefs h4 { font-family: var(--font-body); font-size: 13px; letter-spacing: 0.18em; text-transform: uppercase; margin-bottom: 14px; color: var(--cream); }
.cookie-prefs-row {
  display: flex; align-items: center; justify-content: space-between; padding: 10px 0;
  border-top: 1px solid var(--border); font-size: 13px;
}
.cookie-prefs-row:first-of-type { border-top: none; }
.cookie-prefs-row label { display: flex; align-items: center; gap: 10px; color: var(--cream); }
.cookie-prefs-row input[type="checkbox"] { width: 16px; height: 16px; accent-color: var(--coral); }
.cookie-prefs-row .required { font-size: 11px; color: var(--muted); }

/* ============= SEARCH OVERLAY ============= */
.search-overlay {
  position: fixed; inset: 0; z-index: 150;
  background: rgba(10, 10, 10, 0.96);
  display: none; flex-direction: column;
  padding: 80px 24px 24px;
}
.search-overlay.open { display: flex; animation: fadeIn 0.2s ease; }
.search-overlay-inner { width: 100%; max-width: 720px; margin: 0 auto; }
.search-overlay input {
  width: 100%; padding: 22px 0;
  background: transparent; border: none; border-bottom: 2px solid var(--cream);
  color: var(--cream); font-family: var(--font-display); font-size: clamp(28px, 5vw, 48px);
  text-transform: uppercase; letter-spacing: 0.02em;
}
.search-overlay input:focus { outline: none; border-bottom-color: var(--coral); }
.search-overlay-hint { font-size: 12px; letter-spacing: 0.22em; text-transform: uppercase; color: var(--muted); margin-top: 18px; }
.search-results { margin-top: 36px; display: flex; flex-direction: column; gap: 16px; max-height: 60vh; overflow-y: auto; }
.search-result {
  padding: 16px 0; border-top: 1px solid var(--border);
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
}
.search-result:first-child { border-top: none; }
.search-result .name { font-family: var(--font-display); font-size: 22px; color: var(--cream); }
.search-result .kind { font-size: 11px; letter-spacing: 0.22em; text-transform: uppercase; color: var(--coral); }
.search-close {
  position: absolute; top: 22px; right: 22px;
  width: 44px; height: 44px; border-radius: 50%; color: var(--cream);
  display: inline-flex; align-items: center; justify-content: center;
  background: rgba(255, 245, 240, 0.06);
}
.search-close:hover { background: var(--coral); color: var(--black); }

/* ============= REVEAL ANIMATIONS ============= */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal.in { opacity: 1; transform: translateY(0); }

@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes popIn { from { opacity: 0; transform: translateY(8px) scale(0.98); } to { opacity: 1; transform: translateY(0) scale(1); } }

/* ============= RESPONSIVE ============= */
@media (max-width: 960px) {
  .nav-links { display: none; }
  .nav-toggle { display: inline-flex; }
  /* Switch to flex on mobile so the tools cluster sits flush-right regardless
     of which children inside it (subscribe, account) are hidden at narrower
     widths. The CSS Grid auto-flow was placing the cluster into the 1fr
     middle cell once .nav-links hid, pulling icons toward the center. */
  .nav-inner { display: flex; justify-content: space-between; align-items: center; }
  .nav-tools .nav-subscribe { display: none; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 36px; }
  .card-grid.cols-3, .card-grid.cols-4 { grid-template-columns: repeat(2, 1fr); }
  .streaming-row { grid-template-columns: repeat(2, 1fr); }
  .tour-row { grid-template-columns: 80px 1fr; gap: 16px; }
  .tour-status { grid-column: 1 / -1; justify-self: start; margin-top: 8px; }
  .release-grid { grid-template-columns: 1fr; gap: 32px; }
}

@media (max-width: 560px) {
  .footer-grid { grid-template-columns: 1fr; }
  .card-grid.cols-2, .card-grid.cols-3, .card-grid.cols-4 { grid-template-columns: 1fr; }
  .footer-bottom { justify-content: flex-start; flex-direction: column; }
  .nav-tools .nav-btn[data-tool="account"] { display: none; }
  .gallery-strip { grid-template-columns: repeat(2, 1fr); }
}

/* Mobile menu overlay */
.mobile-menu {
  position: fixed; inset: 0; z-index: 70;
  background: var(--black);
  display: none; flex-direction: column;
  padding: calc(var(--nav-h) + 24px) 32px 32px;
}
.mobile-menu.open { display: flex; animation: fadeIn 0.2s ease; }
.mobile-menu a {
  font-family: var(--font-display); font-size: 36px; text-transform: uppercase; letter-spacing: 0.04em;
  color: var(--cream); padding: 14px 0; border-bottom: 1px solid var(--border);
}
.mobile-menu a:hover { color: var(--coral); }
.mobile-menu .nav-subscribe { margin-top: 24px; align-self: flex-start; font-size: 13px; padding: 14px 26px; }
