:root {
  --bg-primary: #000;
  --bg-secondary: #0a0a0a;
  --text-primary: #fff;
  --text-secondary: #a1a1aa;
  --text-muted: #71717a;
  --accent-red: #dc2626;
  --accent-gold: #f59e0b;
  --border-subtle: rgba(255, 255, 255, 0.1);
  --font-sans: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-full: 9999px;
  --nav-height: 64px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
[hidden] { display: none !important; }
html, body { background: #000; color: var(--text-primary); font-family: var(--font-sans); min-height: 100vh; }
a { color: inherit; }
button, input { font: inherit; }

#static-promo-banner {
  display: block;
  margin-top: var(--nav-height);
  background: linear-gradient(90deg, #991b1b, #dc2626, #b91c1c);
  color: #fff;
  text-align: center;
  padding: 8px 16px;
  font-size: 0.875rem;
  font-weight: 700;
  text-decoration: none;
  letter-spacing: 0.5px;
}
#static-promo-banner strong {
  background: #fff;
  color: #991b1b;
  padding: 2px 6px;
  border-radius: 4px;
  margin: 0 4px;
}

#grimaldi-unified-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #000;
  border-bottom: 1px solid var(--border-subtle);
  padding: 0 20px;
  z-index: 100000;
}
.menu-toggle-btn {
  background: none; border: none; color: #fff; cursor: pointer; padding: 8px; display: flex;
}
#grimaldi-nav-logo {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
}
#grimaldi-nav-logo img {
  height: 44px; width: auto; max-width: min(280px, 58vw); object-fit: contain; display: block;
}
#grimaldiMenuBackdrop {
  position: fixed; inset: 0; background: rgba(0,0,0,0.85); z-index: 1100;
  opacity: 0; pointer-events: none; transition: opacity 0.3s ease;
}
#grimaldiMenuBackdrop.open { opacity: 1; pointer-events: auto; }
#grimaldiMenuDrawer {
  position: fixed; top: 0; left: 0; bottom: 0; width: 320px; max-width: 85vw;
  background: #080808; border-right: 1px solid var(--border-subtle);
  z-index: 1200; transform: translateX(-100%); transition: transform 0.3s ease;
  display: flex; flex-direction: column; overflow-y: auto;
}
#grimaldiMenuDrawer.open { transform: translateX(0); }
.drawer-header {
  padding: 18px 20px; display: flex; align-items: center; justify-content: space-between;
  border-bottom: 1px solid var(--border-subtle);
}
.drawer-title { font-weight: 900; letter-spacing: 1px; }
.drawer-close-btn { background: none; border: none; color: var(--text-secondary); font-size: 1.2rem; cursor: pointer; }
.drawer-section-title {
  padding: 12px 20px 6px; font-size: 0.7rem; font-weight: 900;
  text-transform: uppercase; letter-spacing: 1.2px; color: var(--text-muted);
}
.grit-nav-link {
  padding: 10px 20px; color: #fff; text-decoration: none;
  font-family: Impact, "Oswald", sans-serif; font-size: 16px; font-weight: 700;
  letter-spacing: 0.08em; text-transform: uppercase; display: block;
  border-left: 3px solid transparent;
}
.grit-nav-link:hover { background: rgba(255,255,255,0.08); }
.grit-nav-link.active-channel { border-left-color: #fff; }

.vault-page { max-width: 1180px; margin: 0 auto; padding: 28px 20px 80px; overflow-x: hidden; }
.admin-page { padding-top: 92px; }
.vault-hero { margin-bottom: 28px; }
.kicker {
  color: var(--accent-gold); font-size: 0.78rem; font-weight: 800;
  letter-spacing: 0.14em; margin-bottom: 10px;
}
.vault-hero h1 {
  font-size: clamp(2.1rem, 9vw, 5.2rem); line-height: 0.95;
  letter-spacing: 0.02em; margin-bottom: 12px;
  overflow-wrap: anywhere;
}
.lede { color: var(--text-secondary); max-width: 42rem; font-size: 1.05rem; }
.vault-status { color: var(--text-muted); margin-bottom: 18px; }
.vault-feed { display: grid; gap: 28px; }
.episode-block h2 {
  font-size: 0.85rem; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--text-secondary); margin-bottom: 12px;
}
.clip-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
}
.clip-card {
  background: #0d0d0d; border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg); overflow: hidden; cursor: pointer; text-align: left;
  color: inherit; width: 100%;
}
.clip-card:hover { border-color: rgba(245, 158, 11, 0.6); }
.clip-thumb {
  position: relative; aspect-ratio: 16 / 9; background: #111;
}
.clip-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.clip-dur {
  position: absolute; right: 10px; bottom: 10px;
  background: rgba(0,0,0,0.8); color: #fff; font-size: 0.75rem;
  padding: 3px 7px; border-radius: 4px; font-weight: 700;
}
.clip-body { padding: 14px 14px 16px; }
.clip-body h3 { font-size: 1.05rem; line-height: 1.3; margin-bottom: 6px; }
.clip-body p { color: var(--text-muted); font-size: 0.88rem; }

.player-modal {
  position: fixed; inset: 0; background: rgba(0,0,0,0.92);
  z-index: 200000; display: flex; flex-direction: column;
  align-items: center; justify-content: center; padding: 24px;
}
.player-modal[hidden] { display: none; }
.player-frame {
  width: min(1100px, 100%);
  aspect-ratio: 16 / 9;
  background: #000;
  position: relative;
}
.player-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.player-copy { width: min(1100px, 100%); margin-top: 14px; }
.player-copy h2 { font-size: 1.3rem; margin-bottom: 4px; }
.player-copy p { color: var(--text-secondary); }
.player-close {
  position: absolute; top: 16px; right: 18px;
  background: none; border: none; color: #fff; font-size: 1.6rem; cursor: pointer;
}

.admin-card {
  background: #0d0d0d; border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg); padding: 22px;
  display: grid; gap: 10px; max-width: 560px;
}
.admin-card label { font-size: 0.8rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-secondary); }
.admin-card input {
  background: #000; border: 1px solid var(--border-subtle); color: #fff;
  padding: 10px 12px; border-radius: 8px;
}
.btn-primary {
  background: var(--accent-red); color: #fff; border: 0; border-radius: 8px;
  padding: 12px 16px; font-weight: 800; letter-spacing: 0.04em; cursor: pointer;
  text-transform: uppercase;
}
.btn-primary:disabled { opacity: 0.6; cursor: wait; }
.form-msg { min-height: 1.2em; color: var(--accent-gold); font-size: 0.9rem; }

@media (max-width: 700px) {
  .vault-hero h1 { font-size: 2.15rem; letter-spacing: 0; }
  .vault-page { padding: 22px 16px 72px; }
}
