/* MusicPromoNetwork.com — design system. Dark default; light via [data-theme="light"]. */

:root {
  --bg: #0b0816;
  --bg-card: #150c2b;
  --bg-card-hover: #1c1136;
  --fg: #f5f3ff;
  --muted: #a39cc4;
  --border: rgba(255,255,255,0.10);
  --brand-1: #7c3aed;
  --brand-2: #c026d3;
  --brand-grad: linear-gradient(90deg, var(--brand-1) 0%, var(--brand-2) 100%);
  --ring: rgba(124, 58, 237, 0.45);
  --ok: #34d399;
  --warn: #fbbf24;
  --danger: #f87171;
  --radius: 14px;
  --radius-sm: 8px;
  --max-w: 1200px;
}

[data-theme="light"] {
  --bg: #faf7ff;
  --bg-card: #ffffff;
  --bg-card-hover: #f5f0ff;
  --fg: #0b0816;
  --muted: #5b5478;
  --border: rgba(11, 8, 22, 0.10);
  --ring: rgba(124, 58, 237, 0.25);
}

* { box-sizing: border-box; }

html, body {
  margin: 0; padding: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, sans-serif;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--fg); text-decoration: none; }
a:hover { color: var(--brand-1); }

.wrap { max-width: var(--max-w); margin: 0 auto; padding: 0 24px; }
.muted { color: var(--muted); }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); border: 0; }

.accent {
  background: var(--brand-grad);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.accent-inline { color: var(--brand-1); }
.accent-inline2 { color: var(--brand-2); }

/* Header */
header.site {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 24px;
  border-bottom: 1px solid var(--border);
  position: sticky; top: 0;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  z-index: 10;
}
header.site .brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 19px; }
header.site .brand img { width: 26px; height: 26px; }
.site-nav { display: flex; align-items: center; gap: 18px; }
.nav-link { color: var(--muted); font-size: 14px; }
.nav-link:hover { color: var(--fg); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 12px 22px; border-radius: 999px;
  font-weight: 600; font-size: 15px;
  border: 1px solid transparent; cursor: pointer; text-decoration: none;
  color: var(--fg); background: transparent; font-family: inherit;
}
.btn-primary { background: var(--brand-grad); color: #fff; }
.btn-ghost { border-color: var(--border); }
.btn-sm { padding: 7px 14px; font-size: 13px; }
.btn:focus-visible { outline: 2px solid var(--ring); outline-offset: 2px; }
.btn-icon {
  width: 38px; height: 38px; border-radius: 50%;
  border: 1px solid var(--border); background: transparent; color: var(--fg);
  cursor: pointer; font-size: 16px;
  display: inline-flex; align-items: center; justify-content: center;
}
.btn-icon:hover { background: var(--bg-card); }
.btn-icon.recording { background: var(--danger); color: #fff; border-color: var(--danger); }

/* Hero */
.hero { padding: 64px 0 32px; }
.hero .eyebrow { font-size: 12px; letter-spacing: 0.22em; color: var(--muted); text-transform: uppercase; margin: 0 0 12px; }
.hero h1 {
  font-size: clamp(36px, 5vw, 64px); line-height: 1.05;
  margin: 0 0 16px; font-weight: 800; letter-spacing: -0.02em;
}
.hero p.lede { font-size: 18px; color: var(--muted); max-width: 60ch; margin: 0 0 28px; }
.cta-row { display: flex; gap: 12px; flex-wrap: wrap; }

/* Search + filters */
.section-title {
  font-size: 13px; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--muted); margin: 48px 0 18px;
}
.search-bar {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 12px; background: var(--bg-card);
  border: 1px solid var(--border); border-radius: 999px; margin-bottom: 14px;
}
.search-bar input {
  flex: 1; background: transparent; border: 0; color: var(--fg);
  font-size: 16px; padding: 6px 0; font-family: inherit; outline: none;
}
.filter-row { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; }
.chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 14px; border-radius: 999px;
  background: var(--bg-card); color: var(--muted);
  border: 1px solid var(--border); font-size: 13px;
  font-family: inherit; cursor: pointer; white-space: nowrap;
}
.chip:hover { background: var(--bg-card-hover); color: var(--fg); }
.chip-active { background: var(--brand-grad); color: #fff; border-color: transparent; }
.filter-genres .chip { font-size: 12px; padding: 6px 12px; }

.result-meta { color: var(--muted); font-size: 13px; margin: 14px 0; }

/* Cards */
.result-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px; margin-bottom: 24px;
}
.card {
  background: var(--bg-card); border-radius: var(--radius);
  border: 1px solid var(--border); padding: 18px;
  display: flex; flex-direction: column; gap: 8px;
  transition: background 0.15s, transform 0.15s;
}
.card:hover { background: var(--bg-card-hover); transform: translateY(-1px); }
.card a.card-link { color: var(--fg); }
.card .card-title { font-weight: 700; font-size: 16px; line-height: 1.3; }
.card .card-meta {
  display: flex; flex-wrap: wrap; gap: 6px;
  font-size: 11px; color: var(--muted);
  text-transform: uppercase; letter-spacing: 0.08em;
}
.card .badge {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 3px 8px; border-radius: 999px;
  background: rgba(124, 58, 237, 0.18); color: var(--brand-1); font-weight: 600;
}
.card .badge.verified { background: rgba(52, 211, 153, 0.18); color: var(--ok); }
.card .badge.partial  { background: rgba(251, 191, 36, 0.18); color: var(--warn); }
.card .badge.stale    { background: rgba(248, 113, 113, 0.18); color: var(--danger); }
.card .card-tags { display: flex; flex-wrap: wrap; gap: 4px; }
.card .tag {
  font-size: 11px; color: var(--muted); background: var(--bg);
  border: 1px solid var(--border); padding: 2px 8px; border-radius: 999px;
}
.card .card-stats { font-size: 12px; color: var(--muted); }
.card .card-cta { margin-top: auto; font-size: 13px; color: var(--brand-1); font-weight: 600; }

.result-footer { display: flex; justify-content: center; margin: 12px 0 40px; }

.empty-state { grid-column: 1 / -1; text-align: center; padding: 40px 20px; color: var(--muted); }
.skeleton {
  background: linear-gradient(90deg, var(--bg-card) 0%, var(--bg-card-hover) 50%, var(--bg-card) 100%);
  background-size: 200% 100%; animation: shimmer 1.6s infinite linear;
  border-radius: var(--radius); height: 150px;
}
@keyframes shimmer { from { background-position: -200% 0; } to { background-position: 200% 0; } }

/* Pillars */
.pillars {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px; margin: 14px 0 48px;
}
.pillar {
  padding: 22px; background: var(--bg-card);
  border-radius: var(--radius); border: 1px solid var(--border);
}
.pillar h3 {
  margin: 0 0 8px; font-size: 13px; letter-spacing: 0.16em;
  color: var(--brand-2); text-transform: uppercase;
}
.pillar p { margin: 0; color: var(--muted); }

/* Footer */
footer.site {
  padding: 40px 24px; text-align: center; color: var(--muted);
  font-size: 13px; border-top: 1px solid var(--border);
}

/* Toasts */
.toast-host {
  position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%);
  display: flex; flex-direction: column; gap: 8px;
  z-index: 100; pointer-events: none;
}
.toast {
  background: var(--bg-card); border: 1px solid var(--border); color: var(--fg);
  padding: 10px 18px; border-radius: 999px; font-size: 14px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.3);
  animation: pop 0.2s ease-out; pointer-events: auto;
}
.toast.error { border-color: var(--danger); }
.toast.success { border-color: var(--ok); }
@keyframes pop { from { transform: translateY(10px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }

/* Outlet detail */
.detail-hero {
  padding: 48px 0 24px;
  display: grid; grid-template-columns: 1fr; gap: 18px;
}
@media (min-width: 800px) { .detail-hero { grid-template-columns: 1fr 320px; } }
.detail-hero h1 { font-size: clamp(28px, 4vw, 44px); margin: 0; }
.detail-hero .lede { color: var(--muted); font-size: 16px; max-width: 60ch; }
.contact-card {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 22px;
}
.contact-card h2 {
  margin: 0 0 12px; font-size: 13px; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--muted);
}
.contact-card .locked { text-align: center; padding: 20px 0; color: var(--muted); }
.contact-card .locked .icon { font-size: 28px; margin-bottom: 8px; display: block; }
.contact-card .contact-item {
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 0; border-bottom: 1px solid var(--border); gap: 10px;
}
.contact-card .contact-item:last-child { border-bottom: 0; }
.contact-card .contact-role {
  font-size: 11px; color: var(--muted);
  text-transform: uppercase; letter-spacing: 0.08em;
}
.contact-card .contact-email { font-family: ui-monospace, SFMono-Regular, monospace; font-size: 13px; }

/* Pitch composer modal */
.pitch-modal-overlay {
  position: fixed; inset: 0;
  background: rgba(11, 8, 22, 0.75);
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  display: flex; align-items: center; justify-content: center;
  z-index: 200; padding: 16px; animation: pop 0.15s ease-out;
}
.pitch-modal {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius);
  width: 100%; max-width: 980px; max-height: 92vh;
  display: flex; flex-direction: column; overflow: hidden;
}
.pitch-modal-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 18px; border-bottom: 1px solid var(--border);
}
.pitch-modal-header h2 { margin: 0; font-size: 18px; }
.pitch-modal-body {
  display: grid; grid-template-columns: 1fr; gap: 18px;
  padding: 18px; overflow-y: auto;
}
@media (min-width: 800px) { .pitch-modal-body { grid-template-columns: 360px 1fr; } }
.pitch-form, .pitch-preview { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.pitch-form label, .pitch-preview label {
  display: flex; flex-direction: column; gap: 4px;
  font-size: 12px; color: var(--muted);
  text-transform: uppercase; letter-spacing: 0.06em;
}
.pitch-form input, .pitch-form select,
.pitch-preview input, .pitch-preview textarea {
  background: var(--bg); border: 1px solid var(--border);
  border-radius: 8px; padding: 9px 12px;
  color: var(--fg); font-family: inherit; font-size: 14px;
  text-transform: none; letter-spacing: normal;
}
.pitch-preview textarea {
  font-family: ui-monospace, SFMono-Regular, monospace;
  font-size: 13px; line-height: 1.55;
  resize: vertical; min-height: 280px;
}
.pitch-form input:focus, .pitch-form select:focus,
.pitch-preview input:focus, .pitch-preview textarea:focus {
  outline: 2px solid var(--ring); outline-offset: 1px; border-color: var(--brand-1);
}
.pitch-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
@media (max-width: 599px) { .pitch-grid-2 { grid-template-columns: 1fr; } }
.pitch-modal-footer {
  display: flex; align-items: center; justify-content: space-between;
  gap: 10px; padding: 14px 18px; border-top: 1px solid var(--border);
  flex-wrap: wrap;
}
.pitch-actions { display: flex; gap: 8px; flex-wrap: wrap; }

/* Voice button (wraps any [data-voice] input) */
.voice-wrap { position: relative; display: block; }
.voice-btn {
  position: absolute; right: 6px; top: 50%; transform: translateY(-50%);
  width: 30px; height: 30px; border-radius: 50%;
  border: 1px solid var(--border); background: var(--bg-card);
  color: var(--fg); cursor: pointer; font-size: 13px;
  display: inline-flex; align-items: center; justify-content: center;
  font-family: inherit;
}
.voice-wrap > input, .voice-wrap > textarea { padding-right: 42px; width: 100%; }
.voice-btn:hover { background: var(--bg-card-hover); }
.voice-btn.recording { background: var(--danger); color: #fff; border-color: var(--danger); }
/* textarea voice button sits in the top-right instead of vertical-centered. */
.voice-wrap:has(> textarea) .voice-btn { top: 8px; transform: none; }

/* Skip-to-content link (a11y) */
.skip-link {
  position: absolute; left: -9999px; top: 0;
  background: var(--brand-grad); color: #fff;
  padding: 10px 18px; border-radius: 0 0 8px 0;
  text-decoration: none; font-weight: 600;
  z-index: 1000;
}
.skip-link:focus { left: 0; }

/* Crash overlay (global error boundary) */
.crash-overlay {
  position: fixed; inset: 0;
  background: rgba(11, 8, 22, 0.85);
  display: flex; align-items: center; justify-content: center;
  z-index: 9999; padding: 16px;
}
.crash-card {
  background: var(--bg-card); border: 1px solid var(--danger);
  border-radius: var(--radius); padding: 22px;
  max-width: 520px; width: 100%;
}
.crash-card h2 { margin: 0 0 8px; font-size: 18px; color: var(--danger); }
.crash-card pre {
  background: var(--bg); border: 1px solid var(--border); border-radius: 8px;
  padding: 10px; font-size: 12px; overflow: auto; max-height: 180px;
}
.crash-card details { margin-top: 10px; }
.crash-card details summary { cursor: pointer; color: var(--muted); font-size: 13px; }

/* Feedback form (faq.html) */
.feedback-form { display: grid; gap: 10px; margin-top: 20px; }
.feedback-form label {
  display: flex; flex-direction: column; gap: 4px;
  font-size: 12px; color: var(--muted);
  text-transform: uppercase; letter-spacing: 0.06em;
}
.feedback-form input, .feedback-form select, .feedback-form textarea {
  background: var(--bg); border: 1px solid var(--border);
  border-radius: 8px; padding: 9px 12px;
  color: var(--fg); font-family: inherit; font-size: 14px;
  text-transform: none; letter-spacing: normal;
}
.feedback-form textarea { resize: vertical; min-height: 120px; }

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}
