/* SMM band site - dark, sharp, rock/metal. One accent color, no gradients,
   no rounded-corner SaaS look. Headings lean on a bold condensed system
   display face (Impact/Arial Narrow Bold) rather than a fetched webfont -
   keeps CSP script-src/style-src at 'self' with nothing to fetch from a
   third party. Drop a real self-hosted .woff2 into this directory and swap
   the font-family below if a licensed display face is wanted later. */

/* Great Vibes (SIL Open Font License) - self-hosted, Latin-1 subset only
   (covers ä/ö/ü/ß/é etc, nothing else needed here) so nothing is fetched
   from Google at runtime - visitors' browsers only ever talk to this site. */
@font-face {
  font-family: "Great Vibes";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/static/fonts/great-vibes.woff2") format("woff2");
}

:root {
  --bg: #0b0b0c;
  --bg-raised: #151517;
  --line: #2a2a2d;
  --ink: #ececec;
  --dim: #9a9a9e;
  --accent: #c81e3a;
  --accent-ink: #ffffff;
  --amber: #d18b1f;
  --purple: #7c3aed;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 15px/1.6 -apple-system, "Segoe UI", Roboto, sans-serif;
  /* .hero's full-bleed 100vw trick can overshoot by a scrollbar's width on
     desktop browsers that reserve gutter space - this is the standard
     companion rule that keeps that from ever showing as a scrollbar. */
  overflow-x: hidden;
}

.wrap { max-width: 980px; margin: 0 auto; padding: 0 20px; }

h1, h2, h3, .logo, .cta, .ghost-btn, .badge {
  font-family: Impact, "Arial Narrow Bold", "Helvetica Neue", sans-serif;
  text-transform: uppercase;
  letter-spacing: .03em;
}

h1 {
  font-size: 42px;
  margin: 24px 0 12px;
  text-shadow: 2px 2px 0 var(--accent);
}
h2 {
  font-size: 20px;
  margin: 32px 0 12px;
  border-bottom: 2px solid var(--line);
  padding-bottom: 8px;
  color: var(--dim);
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

/* --- header --- */
.site-header { background: var(--bg-raised); border-bottom: 3px solid var(--accent); }
.header-inner { display: flex; align-items: center; gap: 24px; padding: 14px 20px; flex-wrap: wrap; }
.logo { font-size: 26px; color: var(--ink); text-shadow: 2px 2px 0 var(--accent); }
.nav { display: flex; gap: 18px; flex: 1; flex-wrap: wrap; }
.nav-link {
  color: var(--dim); font-size: 13px; text-transform: uppercase; letter-spacing: .08em;
  padding: 4px 0; border-bottom: 2px solid transparent;
}
.nav-link.active, .nav-link:hover { color: var(--ink); border-bottom-color: var(--accent); text-decoration: none; }
/* Deliberately dimmer than the standard nav links - reference chrome for a
   promoter/venue, not a primary nav item. */
.nav-link-rider { color: #6f6f74; }
.nav-link-rider:hover { color: var(--dim); border-bottom-color: transparent; }
.nav-auth { display: flex; align-items: center; gap: 12px; font-size: 13px; color: var(--dim); }

/* --- hero --- */
/* Full-bleed: .hero lives inside <main class="wrap">, which is capped at
   980px and centered. The classic "break out of a centered container"
   trick re-centers a 100vw box regardless of the parent's max-width, so the
   video runs edge-to-edge instead of sitting in the narrow content column.
   overflow-x on body/html stays clean because the box is symmetric (equal
   negative margins both sides), not because anything is clipped. */
.hero {
  position: relative; overflow: hidden;
  width: 100vw; margin-left: calc(50% - 50vw); margin-right: calc(50% - 50vw);
  box-sizing: border-box;
  min-height: 620px;
  text-align: center; border-bottom: 1px solid var(--line);
}
.hero-video-wrap { position: absolute; inset: 0; z-index: 0; overflow: hidden; }
.hero-video-wrap iframe {
  position: absolute; top: 50%; left: 50%;
  width: 100%; height: 100%; min-width: 177.78vh; min-height: 56.25vw;
  transform: translate(-50%, -50%);
  pointer-events: none; border: 0;
}
.hero-overlay { position: absolute; inset: 0; z-index: 1; background: rgba(11, 11, 12, .55); }
/* Pinned to the bottom edge of .hero (= the line above "Binnenkort") with an
   explicit offset - flex align-items:flex-end technically bottom-aligned
   this too, but with how much empty space .hero's min-height leaves above a
   fairly short content block, it read as "still roughly centered". Absolute
   positioning against .hero's own box removes that ambiguity outright. */
.hero-content { position: absolute; left: 0; right: 0; bottom: 28px; z-index: 2; padding: 0 20px; }
.tagline {
  color: var(--ink); font-size: 30px; margin-bottom: 4px; text-transform: uppercase;
  letter-spacing: .06em; font-family: Impact, "Arial Narrow Bold", "Helvetica Neue", sans-serif;
  text-shadow: 2px 2px 0 var(--accent);
}
.tagline-script {
  font-family: "Great Vibes", "Brush Script MT", "Segoe Script", cursive;
  font-size: 32px; color: var(--accent); margin: 4px 0 28px; font-weight: 400;
}
.hero-buttons { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-top: 18px; }
/* Half the normal .cta/.ghost-btn padding, text kept at the same font-size -
   scoped to the hero only, so admin/builder buttons elsewhere are unaffected. */
.hero-buttons .cta, .hero-buttons .ghost-btn { padding: 5px 11px; }

/* --- buttons --- */
.cta, .ghost-btn {
  display: inline-block; padding: 10px 22px; font-size: 13px; cursor: pointer;
  border: 2px solid var(--accent); border-radius: 2px;
}
.cta { background: var(--accent); color: var(--accent-ink); }
.cta:hover { background: #a8172f; text-decoration: none; }
.ghost-btn { background: transparent; color: var(--ink); }
.ghost-btn:hover { background: var(--bg-raised); text-decoration: none; }
.link-btn { background: none; border: none; color: var(--accent); cursor: pointer; font: inherit; padding: 0; }
.link-btn.danger { color: #e05252; }
.inline-form { display: inline; }

/* --- badges --- */
.badge { display: inline-block; font-size: 11px; padding: 3px 9px; border-radius: 2px; color: #111; font-weight: 700; }
.badge-repetitie { background: var(--amber); }
.badge-optreden { background: var(--accent); color: #fff; }
.badge-speciaal { background: var(--purple); color: #fff; }

/* --- events --- */
.event-list { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); margin: 16px 0; }
.event-card {
  display: block; background: var(--bg-raised); border: 1px solid var(--line); border-left: 4px solid var(--accent);
  padding: 14px 16px; color: var(--ink);
}
.event-card:hover { border-color: var(--accent); text-decoration: none; background: #1b1b1e; }
.event-card-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; gap: 8px; }
.event-date { font-size: 12px; color: var(--dim); text-align: right; }
.event-card h3 { margin: 0 0 4px; text-transform: none; font-family: inherit; letter-spacing: 0; font-size: 17px; }
.event-venue { color: var(--dim); font-size: 13px; margin: 0; }
.event-playlist { font-size: 12px; display: inline-block; margin-top: 6px; }
.event-date-full { color: var(--dim); }
.event-notes { white-space: pre-line; }

.ics-links { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; margin: 14px 0 24px; font-size: 13px; color: var(--dim); }
.ics-links a { border: 1px solid var(--line); padding: 4px 10px; border-radius: 2px; }

/* --- forms --- */
form label, .auth-form label {
  display: block; margin-bottom: 14px; font-size: 12px; text-transform: uppercase;
  letter-spacing: .05em; color: var(--dim);
}
input, select, textarea {
  display: block; width: 100%; margin-top: 6px; padding: 9px 10px; background: var(--bg-raised);
  border: 1px solid var(--line); color: var(--ink); font: inherit; border-radius: 2px;
}
input:focus, select:focus, textarea:focus { outline: 1px solid var(--accent); border-color: var(--accent); }
.event-form, .auth-form { max-width: 460px; }

/* --- EU date/time entry (static/datepicker.js) --- */
.dt-row { position: relative; display: flex; gap: 8px; }
.dt-row .date-field { flex: 1.4; }
.dt-row .time-field { flex: 1; }
.dp-popup {
  position: absolute; top: 100%; left: 0; z-index: 50; margin-top: 4px;
  background: var(--bg-raised); border: 1px solid var(--line); border-radius: 2px;
  padding: 10px; width: 240px; box-shadow: 0 8px 24px rgba(0,0,0,.5);
}
.dp-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; font-size: 13px; text-transform: uppercase; letter-spacing: .04em; }
.dp-nav { background: none; border: 1px solid var(--line); color: var(--ink); cursor: pointer; width: 26px; border-radius: 2px; }
.dp-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; }
.dp-dow { font-size: 10px; text-align: center; color: var(--dim); padding: 2px 0; }
.dp-day { background: none; border: none; color: var(--ink); font-size: 13px; padding: 6px 0; cursor: pointer; border-radius: 2px; }
.dp-day:hover { background: var(--bg); }
.dp-selected { background: var(--accent); color: #fff; }

/* --- opstellen fieldset --- */
.opstellen-field { border: 1px solid var(--line); border-radius: 2px; padding: 12px 14px; margin: 4px 0 20px; }
.checkbox-label { display: flex; align-items: center; gap: 8px; text-transform: none; letter-spacing: 0; font-size: 14px; color: var(--ink); margin-bottom: 10px; }
.checkbox-label input { width: auto; margin: 0; }
.opstellen-field input[type="number"] { max-width: 100px; }
.song-form { display: flex; gap: 10px; align-items: end; flex-wrap: wrap; margin: 16px 0; }
.song-form input { width: auto; flex: 1; min-width: 160px; margin-top: 0; }
.form-error { color: #e05252; border-left: 3px solid #e05252; padding: 8px 12px; background: var(--bg-raised); }

.note { border-left: 3px solid var(--accent); padding: 10px 14px; background: var(--bg-raised); border-radius: 0 4px 4px 0; margin: 14px 0; }
.note.warn { border-left-color: var(--amber); }

/* --- tables --- */
.admin-table { width: 100%; border-collapse: collapse; margin: 16px 0; font-size: 14px; }
.admin-table th {
  text-align: left; color: var(--dim); font-size: 11px; text-transform: uppercase; letter-spacing: .05em;
  border-bottom: 1px solid var(--line); padding: 8px 10px;
}
.admin-table td { padding: 8px 10px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.row-actions { display: flex; gap: 12px; font-size: 13px; }
.dim { color: var(--dim); }

/* --- playlist builder --- */
.builder-head { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 10px; }
.builder-actions { display: flex; gap: 10px; align-items: center; }
#save-status { font-size: 12px; }
.save-ok { color: #4caf6b; }
.save-error { color: #e05252; }
.builder { display: flex; gap: 24px; margin: 20px 0 60px; align-items: flex-start; flex-wrap: wrap; }
.builder-left { flex: 2; min-width: 320px; }
.builder-right { flex: 1; min-width: 240px; background: var(--bg-raised); border: 1px solid var(--line); padding: 14px; }
.section { background: var(--bg-raised); border: 1px solid var(--line); margin-bottom: 16px; padding: 12px; }
.section-head { display: flex; gap: 8px; margin-bottom: 8px; }
.section-title { flex: 1; margin: 0; font-weight: 700; }
.section-remove, .item-remove {
  background: none; border: 1px solid var(--line); color: var(--dim); cursor: pointer; width: 30px; border-radius: 2px;
}
.item-list { list-style: none; margin: 0; padding: 0; min-height: 40px; }
.item-list.drop-target { outline: 2px dashed var(--accent); outline-offset: 4px; }
.item {
  display: flex; align-items: flex-start; gap: 8px; background: var(--bg); border: 1px solid var(--line);
  padding: 8px; margin-bottom: 6px; cursor: grab;
}
.item.dragging { opacity: .35; }
.item-title { flex: 0 0 140px; font-size: 14px; padding-top: 6px; }
.item-comment { flex: 1; margin: 0; min-height: 32px; resize: vertical; font-size: 13px; }
#repertoire-filter { margin-bottom: 10px; }
#repertoire-list { list-style: none; margin: 0; padding: 0; max-height: 70vh; overflow-y: auto; }
.repertoire-song {
  padding: 8px; border: 1px solid var(--line); margin-bottom: 6px; cursor: grab; font-size: 14px; background: var(--bg);
}
.song-hint { display: block; font-size: 11px; color: var(--dim); margin-top: 2px; }

.back-link { display: inline-block; margin: 16px 0; font-size: 13px; }
.site-footer { border-top: 1px solid var(--line); color: var(--dim); font-size: 12px; padding: 20px 0 40px; margin-top: 40px; }

/* subtle grain overlay - a generated data-URI, never an external image fetch */
.grain {
  position: fixed; inset: 0; pointer-events: none; z-index: 999; opacity: .04; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='120' height='120'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
}

@media (max-width: 640px) {
  /* No forced column stack here on purpose. .header-inner/.nav are already
     flex-wrap:wrap (see their base rules above) - a short row (logo + Home +
     Agenda, logged out) naturally stays on one line, and a longer one
     (logged in: + Beheer/Repertoire/Playlists/Rider + Technische
     rider/Inloggen) wraps onto the next line by itself. Forcing
     flex-direction:column here used to stack every single item one-per-line
     regardless of how short the public nav is, which also pushed .hero (and
     its video) far enough below the fold that mobile browsers never started
     autoplay at all - fixing the header height fixed the video too. */
  .item-title { flex-basis: 100px; }
}
