/* ═══════════════════════════════════════════════════════════════════
   NightlifeSpecials — main stylesheet
   Aesthetic: warm, moody, neon-on-dark accents with clean mobile UX
   Fonts: Outfit (display) + Inter (body) via Google Fonts
═══════════════════════════════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700&family=Inter:wght@400;500&display=swap');

/* ── CSS Custom Properties ───────────────────────────────────────── */
:root {
  --bg:         #0e0e12;
  --bg2:        #16161d;
  --bg3:        #1e1e28;
  --surface:    #242430;
  --surface2:   #2c2c3a;
  --border:     rgba(255,255,255,0.08);
  --border2:    rgba(255,255,255,0.14);

  --amber:      #f0a500;
  --amber-dim:  rgba(240,165,0,0.15);
  --amber-glow: rgba(240,165,0,0.35);
  --coral:      #e85d3c;
  --coral-dim:  rgba(232,93,60,0.15);
  --teal:       #18c9a0;
  --teal-dim:   rgba(24,201,160,0.12);
  --purple:     #9b87f5;
  --purple-dim: rgba(155,135,245,0.15);

  --text:       #f0ede8;
  --text2:      #a09e9a;
  --text3:      #6a6865;

  --radius-sm:  6px;
  --radius-md:  10px;
  --radius-lg:  16px;
  --radius-xl:  22px;

  --font-display: 'Outfit', sans-serif;
  --font-body:    'Inter', sans-serif;

  --nav-h:      56px;  /* mobile bottom nav height */
  --header-h:   60px;
}

/* ── Reset ───────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  padding-bottom: calc(var(--nav-h) + 12px);
}
a { color: var(--amber); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }
button, input, select, textarea {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
}

/* ── Header ──────────────────────────────────────────────────────── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--header-h);
  background: rgba(14,14,18,0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  padding: 0 16px;
  gap: 12px;
}
.site-logo {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  color: var(--amber);
  letter-spacing: -0.02em;
  flex-shrink: 0;
}
.site-logo span { color: var(--text2); font-weight: 300; }
.header-tonight {
  font-size: 12px;
  color: var(--text2);
  background: var(--surface);
  border: 1px solid var(--border2);
  border-radius: 20px;
  padding: 3px 10px;
  flex-shrink: 0;
}
.header-spacer { flex: 1; }

/* ── Bottom nav (mobile primary navigation) ──────────────────────── */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: var(--nav-h);
  background: rgba(22,22,29,0.96);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-top: 1px solid var(--border);
  display: flex;
  z-index: 200;
}
.bnav-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  font-size: 10px;
  font-weight: 500;
  color: var(--text3);
  text-decoration: none;
  transition: color 0.15s;
  padding: 6px 2px;
  position: relative;
}
.bnav-item svg { width: 22px; height: 22px; stroke: currentColor; fill: none; stroke-width: 1.8; }
.bnav-item.active { color: var(--amber); }
.bnav-item.active::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 28px;
  height: 2px;
  background: var(--amber);
  border-radius: 0 0 2px 2px;
}
.bnav-item:hover { color: var(--text); }
.bnav-badge {
  position: absolute;
  top: 4px;
  right: calc(50% - 18px);
  background: var(--coral);
  color: #fff;
  font-size: 9px;
  font-weight: 600;
  min-width: 16px;
  height: 16px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
}

/* ── Desktop sidebar nav ─────────────────────────────────────────── */
@media (min-width: 768px) {
  body { padding-bottom: 0; display: flex; flex-direction: column; }
  .bottom-nav { display: none; }
  .desktop-layout { display: flex; flex: 1; }
  .sidebar {
    width: 220px;
    flex-shrink: 0;
    background: var(--bg2);
    border-right: 1px solid var(--border);
    padding: 20px 12px;
    position: sticky;
    top: var(--header-h);
    height: calc(100vh - var(--header-h));
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 4px;
  }
  .sidebar-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: var(--radius-md);
    font-size: 14px;
    color: var(--text2);
    text-decoration: none;
    transition: all 0.15s;
  }
  .sidebar-link svg { width: 18px; height: 18px; stroke: currentColor; fill: none; stroke-width: 1.8; flex-shrink: 0; }
  .sidebar-link:hover { background: var(--surface); color: var(--text); text-decoration: none; }
  .sidebar-link.active { background: var(--amber-dim); color: var(--amber); }
  .sidebar-section-label {
    font-size: 10px;
    font-weight: 600;
    color: var(--text3);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    padding: 12px 12px 4px;
  }
  .main-content { flex: 1; min-width: 0; }
}
@media (max-width: 767px) {
  .sidebar { display: none; }
  .desktop-layout { display: block; }
}

/* ── Page container ──────────────────────────────────────────────── */
.page { padding: 16px; max-width: 800px; margin: 0 auto; }
.page-title {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 16px;
  letter-spacing: -0.02em;
}
.section-label {
  font-size: 11px;
  font-weight: 600;
  color: var(--text3);
  text-transform: uppercase;
  letter-spacing: 0.07em;
  margin: 20px 0 8px;
}

/* ── Cards ───────────────────────────────────────────────────────── */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 14px 16px;
  transition: border-color 0.15s;
}
.card:hover { border-color: var(--border2); }
.card-link { text-decoration: none; display: block; }
.card-link:hover { text-decoration: none; }

/* ── Venue card ──────────────────────────────────────────────────── */
.venue-card { cursor: pointer; position: relative; }
.venue-card.is-excluded { opacity: 0.35; }
.venue-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 8px;
  margin-bottom: 6px;
}
.venue-name {
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 600;
  color: var(--text);
  line-height: 1.2;
}
.venue-score {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 700;
  color: var(--amber);
  background: var(--amber-dim);
  border: 1px solid rgba(240,165,0,0.3);
  border-radius: 20px;
  padding: 2px 9px;
  flex-shrink: 0;
}
.venue-meta {
  font-size: 12px;
  color: var(--text2);
  margin-bottom: 8px;
}
.venue-meta .dist {
  color: var(--teal);
  font-weight: 500;
}
.specials-row {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-bottom: 8px;
}
.venue-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

/* ── Pills / badges ──────────────────────────────────────────────── */
.pill {
  display: inline-flex;
  align-items: center;
  font-size: 11px;
  padding: 3px 9px;
  border-radius: 20px;
  border: 1px solid;
  line-height: 1.4;
  white-space: nowrap;
}
.pill-food    { background: rgba(24,201,160,0.1);  color: #18c9a0; border-color: rgba(24,201,160,0.3); }
.pill-drink   { background: rgba(240,165,0,0.1);   color: #f0a500; border-color: rgba(240,165,0,0.3); }
.pill-happy   { background: rgba(240,165,0,0.1);   color: #f0a500; border-color: rgba(240,165,0,0.3); }
.pill-music   { background: rgba(155,135,245,0.1); color: #9b87f5; border-color: rgba(155,135,245,0.3); }
.pill-trivia  { background: rgba(56,138,221,0.1);  color: #388add; border-color: rgba(56,138,221,0.3); }
.pill-event   { background: rgba(232,93,60,0.1);   color: #e85d3c; border-color: rgba(232,93,60,0.3); }
.pill-other   { background: var(--surface2); color: var(--text2); border-color: var(--border2); }

.tag-pill {
  display: inline-flex;
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 20px;
  border: 1px solid var(--border2);
  background: var(--surface2);
  color: var(--text2);
  cursor: pointer;
  user-select: none;
  transition: all 0.12s;
}
.tag-pill:hover { border-color: var(--amber); color: var(--amber); }
.tag-pill.is-want { background: rgba(24,201,160,0.12); color: var(--teal); border-color: rgba(24,201,160,0.4); }
.tag-pill.is-exclude { background: rgba(232,93,60,0.12); color: var(--coral); border-color: rgba(232,93,60,0.4); }

.badge {
  display: inline-block;
  font-size: 10px;
  padding: 2px 7px;
  border-radius: 20px;
  border: 1px solid;
}
.badge-amber  { background: var(--amber-dim);  color: var(--amber);  border-color: rgba(240,165,0,0.3); }
.badge-teal   { background: var(--teal-dim);   color: var(--teal);   border-color: rgba(24,201,160,0.3); }
.badge-coral  { background: var(--coral-dim);  color: var(--coral);  border-color: rgba(232,93,60,0.3); }
.badge-purple { background: var(--purple-dim); color: var(--purple); border-color: rgba(155,135,245,0.3); }
.badge-muted  { background: var(--surface2);   color: var(--text2);  border-color: var(--border2); }

/* ── Buttons ─────────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 9px 18px;
  border-radius: var(--radius-md);
  font-size: 14px;
  font-weight: 500;
  border: 1px solid var(--border2);
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
  transition: all 0.15s;
  text-decoration: none;
  line-height: 1;
  white-space: nowrap;
}
.btn:hover { background: var(--surface2); border-color: var(--border2); text-decoration: none; }
.btn:active { transform: scale(0.97); }
.btn-primary { background: var(--amber); color: #0e0e12; border-color: var(--amber); font-weight: 600; }
.btn-primary:hover { background: #ffb827; border-color: #ffb827; }
.btn-sm { padding: 6px 13px; font-size: 13px; }
.btn-danger { color: var(--coral); border-color: rgba(232,93,60,0.3); }
.btn-danger:hover { background: var(--coral-dim); }
.btn-icon { padding: 8px; border-radius: var(--radius-md); }
.btn-icon svg { width: 18px; height: 18px; }
.btn-row { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }

/* ── Forms ───────────────────────────────────────────────────────── */
.form-group { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.form-group label {
  font-size: 12px;
  font-weight: 500;
  color: var(--text2);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.form-control {
  background: var(--surface);
  border: 1px solid var(--border2);
  border-radius: var(--radius-md);
  color: var(--text);
  padding: 10px 12px;
  font-size: 14px;
  transition: border-color 0.15s;
  width: 100%;
}
.form-control:focus {
  outline: none;
  border-color: var(--amber);
  box-shadow: 0 0 0 3px var(--amber-dim);
}
.form-control::placeholder { color: var(--text3); }
textarea.form-control { resize: vertical; min-height: 80px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 500px) { .form-row { grid-template-columns: 1fr; } }
.form-hint { font-size: 11px; color: var(--text3); margin-top: 2px; }
.form-error { font-size: 12px; color: var(--coral); margin-top: 3px; }

/* ── Filter bar ──────────────────────────────────────────────────── */
.filter-bar {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 12px 14px;
  margin-bottom: 14px;
}
.filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 10px;
}
.filter-row:last-child { margin-bottom: 0; }
.filter-label { font-size: 11px; color: var(--text3); white-space: nowrap; }
.filter-select {
  background: var(--surface);
  border: 1px solid var(--border2);
  border-radius: var(--radius-sm);
  color: var(--text);
  padding: 5px 28px 5px 10px;
  font-size: 13px;
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M3 4.5L6 7.5L9 4.5' stroke='%23a09e9a' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 8px center;
  cursor: pointer;
}
.filter-select:focus { outline: none; border-color: var(--amber); }

/* hunger toggle */
.hunger-toggle {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--text2);
  cursor: pointer;
  user-select: none;
}
.toggle-track {
  width: 36px;
  height: 20px;
  border-radius: 10px;
  background: var(--surface2);
  border: 1px solid var(--border2);
  position: relative;
  transition: background 0.2s;
  flex-shrink: 0;
}
.toggle-thumb {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--text3);
  transition: all 0.2s;
}
.toggle-input { position: absolute; opacity: 0; width: 0; height: 0; }
.toggle-input:checked ~ .toggle-track { background: var(--amber); border-color: var(--amber); }
.toggle-input:checked ~ .toggle-track .toggle-thumb { left: 18px; background: #0e0e12; }

.tag-filter-group { display: flex; flex-wrap: wrap; gap: 5px; align-items: center; }

/* ── Week planner ────────────────────────────────────────────────── */
.week-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 6px;
  margin-bottom: 20px;
}
.week-col {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  min-height: 110px;
}
.week-col.is-today { border-color: rgba(240,165,0,0.5); }
.week-col-head {
  background: var(--bg2);
  padding: 6px 8px;
  border-bottom: 1px solid var(--border);
  text-align: center;
}
.wch-day  { font-size: 10px; font-weight: 600; color: var(--text3); text-transform: uppercase; }
.wch-date { font-size: 16px; font-weight: 700; font-family: var(--font-display); color: var(--text); }
.is-today .wch-date { color: var(--amber); }
.week-col-body { padding: 5px; display: flex; flex-direction: column; gap: 3px; }
.plan-chip {
  font-size: 10px;
  padding: 3px 6px;
  border-radius: 4px;
  line-height: 1.3;
  cursor: pointer;
}
.plan-chip.type-committed { background: var(--teal-dim); color: var(--teal); border: 1px solid rgba(24,201,160,0.3); }
.plan-chip.type-reminder  { background: var(--amber-dim); color: var(--amber); border: 1px solid rgba(240,165,0,0.3); }
.plan-chip.type-maybego   { background: var(--purple-dim); color: var(--purple); border: 1px solid rgba(155,135,245,0.3); }
.plan-chip.special-chip   { background: var(--surface2); color: var(--text2); border: 1px dashed var(--border2); cursor: default; }
.week-add-btn {
  font-size: 10px;
  color: var(--text3);
  border: 1px dashed var(--border);
  border-radius: 4px;
  text-align: center;
  padding: 3px;
  cursor: pointer;
  transition: all 0.12s;
}
.week-add-btn:hover { color: var(--amber); border-color: rgba(240,165,0,0.4); }

/* ── Calendar ────────────────────────────────────────────────────── */
.cal-grid { display: grid; grid-template-columns: repeat(7,1fr); gap: 4px; }
.cal-header { font-size: 11px; font-weight: 600; color: var(--text3); text-align: center; padding: 4px 0; text-transform: uppercase; }
.cal-day {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  min-height: 72px;
  padding: 4px;
  cursor: pointer;
  transition: border-color 0.12s;
}
.cal-day:hover { border-color: var(--border2); }
.cal-day.is-today { border-color: rgba(240,165,0,0.6); }
.cal-num { font-size: 12px; font-weight: 600; color: var(--text); margin-bottom: 3px; }
.is-today .cal-num { color: var(--amber); }
.cal-event {
  font-size: 9px;
  padding: 1px 4px;
  border-radius: 3px;
  margin-bottom: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.cal-event.special { background: var(--teal-dim); color: var(--teal); }
.cal-event.event   { background: var(--coral-dim); color: var(--coral); }

/* ── Reminder cards ──────────────────────────────────────────────── */
.reminder-card {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 14px;
}
.reminder-card.is-done { opacity: 0.4; }
.rem-check {
  width: 20px;
  height: 20px;
  border: 1.5px solid var(--border2);
  border-radius: 5px;
  flex-shrink: 0;
  margin-top: 1px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s;
}
.rem-check:hover { border-color: var(--amber); }
.rem-check.is-checked { background: var(--amber); border-color: var(--amber); }
.rem-check svg { width: 12px; height: 12px; stroke: #0e0e12; fill: none; stroke-width: 2.5; }
.rem-body { flex: 1; min-width: 0; }
.rem-text { font-size: 14px; font-weight: 500; color: var(--text); margin-bottom: 3px; }
.rem-meta { font-size: 12px; color: var(--text2); }
.rem-delete {
  background: none;
  border: none;
  color: var(--text3);
  cursor: pointer;
  padding: 4px;
  font-size: 18px;
  line-height: 1;
  transition: color 0.12s;
}
.rem-delete:hover { color: var(--coral); }

/* ── Visit / history ─────────────────────────────────────────────── */
.visit-card { margin-bottom: 8px; }
.visit-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; }
.visit-venue { font-family: var(--font-display); font-size: 15px; font-weight: 600; }
.visit-date { font-size: 12px; color: var(--text2); }
.star-row { color: var(--amber); font-size: 14px; margin-bottom: 4px; }
.visit-notes { font-size: 13px; color: var(--text2); line-height: 1.5; }
.visit-best  { font-size: 12px; color: var(--teal);  margin-top: 4px; }
.visit-avoid { font-size: 12px; color: var(--coral); margin-top: 2px; }

/* ── Photo grid ──────────────────────────────────────────────────── */
.photo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(100px, 1fr)); gap: 6px; margin-top: 8px; }
.photo-thumb {
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: var(--radius-sm);
  cursor: pointer;
  border: 1px solid var(--border);
}
.photo-upload-zone {
  border: 2px dashed var(--border2);
  border-radius: var(--radius-md);
  padding: 20px;
  text-align: center;
  color: var(--text3);
  font-size: 13px;
  cursor: pointer;
  transition: all 0.15s;
}
.photo-upload-zone:hover { border-color: var(--amber); color: var(--amber); }

/* ── GPS / I'm here panel ─────────────────────────────────────────── */
.gps-panel { margin-bottom: 20px; }
.gps-state { display: none; }
.gps-state.active { display: block; }
.loc-icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--amber-dim);
  border: 2px solid rgba(240,165,0,0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 14px;
  font-size: 26px;
}
.loc-icon.scanning { animation: pulse-ring 1.4s ease-in-out infinite; }
@keyframes pulse-ring {
  0%,100% { transform: scale(1); box-shadow: 0 0 0 0 var(--amber-glow); }
  50% { transform: scale(1.08); box-shadow: 0 0 0 10px transparent; }
}
.progress-bar { height: 3px; background: var(--surface2); border-radius: 2px; overflow: hidden; margin: 10px 0; }
.progress-fill { height: 100%; background: var(--amber); border-radius: 2px; transition: width 0.4s ease; }

.candidate-card { cursor: pointer; }
.candidate-card.is-selected { border-color: var(--amber) !important; background: var(--amber-dim); }
.cand-name { font-size: 14px; font-weight: 600; color: var(--text); margin-bottom: 2px; }
.cand-addr { font-size: 12px; color: var(--text2); }
.cand-dist { font-size: 11px; color: var(--teal); margin-top: 3px; }

/* ── Venue detail bottom sheet ───────────────────────────────────── */
.sheet-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  z-index: 300;
  display: none;
  align-items: flex-end;
  justify-content: center;
}
.sheet-overlay.open { display: flex; }
.sheet {
  background: var(--bg2);
  border-radius: 20px 20px 0 0;
  border-top: 1px solid var(--border2);
  width: 100%;
  max-width: 900px;
  max-height: 85vh;
  overflow-y: auto;
  padding: 16px 18px 24px;
  position: relative;
}
.sheet-handle {
  width: 36px;
  height: 4px;
  background: var(--surface2);
  border-radius: 2px;
  margin: 0 auto 16px;
}
.sheet-title { font-family: var(--font-display); font-size: 22px; font-weight: 700; color: var(--text); margin-bottom: 4px; }
.sheet-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--surface2);
  border: none;
  color: var(--text2);
  font-size: 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}
.sheet-section { margin-bottom: 18px; }
.sheet-section h3 {
  font-size: 12px;
  font-weight: 600;
  color: var(--text3);
  text-transform: uppercase;
  letter-spacing: 0.07em;
  margin-bottom: 8px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 5px;
}
.sched-item { font-size: 13px; padding: 6px 0; border-bottom: 1px solid var(--border); color: var(--text); display: flex; }
.sched-item:last-child { border: none; }
.sched-day { font-weight: 600; min-width: 90px; color: var(--amber); }

/* ── Score display ───────────────────────────────────────────────── */
.score-bar { height: 4px; background: var(--surface2); border-radius: 2px; margin-top: 6px; overflow: hidden; }
.score-fill { height: 100%; background: linear-gradient(90deg, var(--teal), var(--amber)); border-radius: 2px; transition: width 0.4s; }

/* ── Admin page ──────────────────────────────────────────────────── */
.admin-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.admin-table th {
  font-size: 11px;
  font-weight: 600;
  color: var(--text3);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 8px 12px;
  text-align: left;
  border-bottom: 1px solid var(--border);
}
.admin-table td { padding: 8px 12px; border-bottom: 1px solid var(--border); color: var(--text); vertical-align: middle; }
.admin-table tr:last-child td { border: none; }
.admin-table tr:hover td { background: var(--surface2); }

/* ── Score settings panel ────────────────────────────────────────── */
.score-setting-row { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--border); }
.score-setting-row:last-child { border: none; }
.score-setting-label { flex: 1; }
.score-setting-name { font-size: 14px; color: var(--text); font-weight: 500; }
.score-setting-desc { font-size: 12px; color: var(--text3); margin-top: 2px; }
.score-setting-input {
  width: 80px;
  background: var(--surface);
  border: 1px solid var(--border2);
  border-radius: var(--radius-sm);
  color: var(--text);
  padding: 6px 10px;
  font-size: 14px;
  text-align: right;
}
.score-setting-input:focus { outline: none; border-color: var(--amber); }

/* ── Modal (plan add) ────────────────────────────────────────────── */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.65);
  z-index: 400;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.modal-overlay.open { display: flex; }
.modal {
  background: var(--bg2);
  border: 1px solid var(--border2);
  border-radius: var(--radius-xl);
  padding: 22px;
  width: 100%;
  max-width: 400px;
}
.modal-title { font-family: var(--font-display); font-size: 18px; font-weight: 600; margin-bottom: 16px; }

/* ── Stars ───────────────────────────────────────────────────────── */
.star-input { display: flex; gap: 4px; }
.star-input label {
  font-size: 24px;
  cursor: pointer;
  color: var(--surface2);
  transition: color 0.1s;
  line-height: 1;
}
.star-input input { display: none; }
.star-input input:checked ~ label,
.star-input label:hover,
.star-input label:hover ~ label { color: var(--amber); }
.star-input { flex-direction: row-reverse; }
.star-input label:hover,
.star-input label:hover ~ label { color: var(--amber); }

/* ── Utility ─────────────────────────────────────────────────────── */
.text-center { text-align: center; }
.text-muted { color: var(--text2); }
.text-sm { font-size: 13px; }
.mt-1 { margin-top: 4px; }
.mt-2 { margin-top: 8px; }
.mt-3 { margin-top: 12px; }
.mb-2 { margin-bottom: 8px; }
.mb-3 { margin-bottom: 12px; }
.gap-2 { gap: 8px; }
.flex { display: flex; }
.flex-wrap { flex-wrap: wrap; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.w-full { width: 100%; }
.hidden { display: none !important; }

/* ── Alert ───────────────────────────────────────────────────────── */
.alert { padding: 10px 14px; border-radius: var(--radius-md); font-size: 13px; margin-bottom: 14px; border: 1px solid; }
.alert-success { background: var(--teal-dim); color: var(--teal); border-color: rgba(24,201,160,0.3); }
.alert-warning { background: var(--amber-dim); color: var(--amber); border-color: rgba(240,165,0,0.3); }
.alert-danger  { background: var(--coral-dim); color: var(--coral); border-color: rgba(232,93,60,0.3); }

/* ── Empty state ─────────────────────────────────────────────────── */
.empty-state { text-align: center; padding: 3rem 1rem; color: var(--text3); font-size: 14px; }
.empty-state .empty-icon { font-size: 40px; margin-bottom: 12px; }
.empty-state p { margin-top: 6px; }

/* ── Responsive tweaks ───────────────────────────────────────────── */
@media (max-width: 480px) {
  .week-grid { grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 3px; }
  .wch-day { display: none; }
  .page { padding: 12px; }
  .form-row { grid-template-columns: 1fr; }
}
@media (min-width: 480px) and (max-width: 767px) {
  .week-grid { gap: 5px; }
}

/* ── Scrollbar ───────────────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--surface2); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--border2); }

/* ── Map placeholder ─────────────────────────────────────────────── */
#venue-map { width: 100%; height: 320px; border-radius: var(--radius-lg); border: 1px solid var(--border); background: var(--surface); overflow: hidden; }

/* ── Validation ──────────────────────────────────────────────────── */
.field-validation-error { font-size: 12px; color: var(--coral); }
.input-validation-error { border-color: var(--coral) !important; }

/* ═══════════════════════════════════════════════════════════════════
   NEW ADDITIONS — compact filter bar, tag panel, priority strips,
   score breakdown, admin header button
═══════════════════════════════════════════════════════════════════ */

/* ── Admin header button ─────────────────────────────────────────── */
.admin-header-btn {
  padding: 6px 10px;
  opacity: 0.7;
}
.admin-header-btn:hover { opacity: 1; }
/* On narrow screens: icon only */
@media (max-width: 480px) {
  .admin-btn-text { display: none; }
  .admin-header-btn { padding: 6px 8px; }
}

/* ── Compact filter bar ──────────────────────────────────────────── */
.filter-bar-compact {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 10px 12px;
}
.fbc-row {
  display: flex;
  gap: 6px;
  align-items: center;
  flex-wrap: wrap;
}
.fbc-row2 {
  margin-top: 8px;
  flex-wrap: nowrap;
}
.fbc-select {
  flex: 1;
  min-width: 80px;
  max-width: 160px;
}

/* Active filter badge on the Tags button */
.filter-active-badge {
  display: inline-block;
  background: var(--amber);
  color: #0e0e12;
  font-size: 10px;
  font-weight: 700;
  border-radius: 20px;
  padding: 1px 6px;
  margin-left: 4px;
  line-height: 1.4;
}

/* ── Tag filter panel (bottom sheet on mobile, modal on desktop) ─── */
.tag-panel-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,0);
  z-index: 500;
  pointer-events: none;
  transition: background 0.25s;
}
.tag-panel-overlay.open {
  background: rgba(0,0,0,0.55);
  pointer-events: all;
}

.tag-panel {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  background: var(--bg2);
  border-top: 1px solid var(--border2);
  border-radius: var(--radius-xl) var(--radius-xl) 0 0;
  z-index: 600;
  max-height: 80dvh;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  transform: translateY(100%);
  transition: transform 0.3s cubic-bezier(0.34, 1.2, 0.64, 1);
  padding-bottom: calc(var(--nav-h) + 8px);
}
.tag-panel.open { transform: translateY(0); }

/* On desktop — show as a sidebar-attached card instead */
@media (min-width: 768px) {
  .tag-panel {
    position: fixed;
    top: calc(var(--header-h) + 8px);
    left: calc(240px + 8px); /* sidebar width */
    right: auto;
    bottom: auto;
    width: 340px;
    max-height: calc(100dvh - var(--header-h) - 16px);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border2);
    box-shadow: 0 8px 40px rgba(0,0,0,0.5);
    transform: scale(0.96) translateY(-8px);
    opacity: 0;
    transition: transform 0.2s ease, opacity 0.2s ease;
    pointer-events: none;
  }
  .tag-panel.open {
    transform: scale(1) translateY(0);
    opacity: 1;
    pointer-events: all;
  }
}

.tag-panel-handle {
  width: 36px; height: 4px;
  background: var(--border2);
  border-radius: 2px;
  margin: 10px auto 0;
}
@media (min-width: 768px) { .tag-panel-handle { display: none; } }

.tag-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px 10px;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  background: var(--bg2);
  z-index: 1;
}
.tag-panel-title {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 600;
}

.tag-panel-body {
  padding: 12px 16px;
}

.tag-panel-section {
  margin-bottom: 20px;
}
.tag-panel-section-hd {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
  font-size: 13px;
}

/* ── Priority number badge inside want pills ─────────────────────── */
.pill-priority-num {
  font-size: 10px;
  font-weight: 700;
  color: var(--amber);
  background: rgba(240,165,0,0.2);
  border-radius: 10px;
  padding: 0 4px;
  margin-right: 2px;
}

/* ── Priority order strip ────────────────────────────────────────── */
.priority-order-strip {
  margin-top: 10px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  min-height: 28px;
}

.priority-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: var(--surface);
  border: 1px solid var(--border2);
  border-radius: var(--radius-md);
  padding: 4px 8px;
  font-size: 12px;
}
.pchip-num {
  font-weight: 700;
  color: var(--amber);
  font-size: 11px;
  min-width: 14px;
  text-align: center;
}
.pchip-name { color: var(--text); }
.pchip-mult {
  font-size: 10px;
  color: var(--teal);
  font-weight: 600;
}
.pchip-arrow {
  background: none; border: none;
  color: var(--text2); cursor: pointer;
  font-size: 13px; padding: 0 2px;
  line-height: 1;
  transition: color 0.1s;
}
.pchip-arrow:hover { color: var(--amber); }
.pchip-remove {
  background: none; border: none;
  color: var(--text3); cursor: pointer;
  font-size: 15px; padding: 0 1px;
  line-height: 1;
  transition: color 0.1s;
  margin-left: 2px;
}
.pchip-remove:hover { color: var(--coral); }

/* ── Score badge (interactive) ───────────────────────────────────── */
.score-badge {
  cursor: pointer;
  user-select: none;
  transition: all 0.15s;
  position: relative;
}
.score-badge:hover {
  background: var(--amber);
  color: #0e0e12;
}
.score-badge:active { transform: scale(0.9); }
.score-badge-open {
  background: var(--amber);
  color: #0e0e12;
}

/* Desktop tooltip via CSS on hover */
@media (min-width: 768px) {
  .score-badge[data-tooltip]:not([data-tooltip=""]):hover::after {
    content: attr(data-tooltip);
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    background: var(--surface2);
    border: 1px solid var(--border2);
    border-radius: var(--radius-md);
    padding: 8px 12px;
    font-size: 12px;
    white-space: normal;
    min-width: 220px;
    max-width: 300px;
    color: var(--text);
    z-index: 50;
    box-shadow: 0 4px 16px rgba(0,0,0,0.4);
    line-height: 1.7;
    pointer-events: none;
  }
}

/* ── Score breakdown inline panel ────────────────────────────────── */
.score-breakdown-panel {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-bottom: 8px;
  padding: 6px 0 2px;
  border-top: 1px solid var(--border);
  animation: slideIn 0.15s ease;
}
.bd-item {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 20px;
  border: 1px solid var(--border2);
  background: var(--surface);
  color: var(--text2);
  white-space: nowrap;
}
.bd-detail {
  color: var(--text3);
  font-size: 10px;
}
.bd-tags  { border-color: rgba(240,165,0,0.3); color: var(--amber); }
.bd-dist  { border-color: rgba(24,201,160,0.3); color: var(--teal); }
.bd-fresh { border-color: rgba(155,135,245,0.3); color: var(--purple); }

/* ── Location switcher (header pill bar) ─────────────────────────── */
.loc-switcher {
  display: flex;
  align-items: center;
  gap: 4px;
  overflow-x: auto;
  scrollbar-width: none;       /* Firefox */
  -ms-overflow-style: none;    /* IE/Edge */
  flex-shrink: 1;
  min-width: 0;
  padding: 0 2px;
}
.loc-switcher::-webkit-scrollbar { display: none; }

.loc-pill {
  display: inline-flex;
  align-items: center;
  padding: 4px 11px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  font-family: var(--font-display);
  white-space: nowrap;
  border: 1px solid var(--border2);
  background: var(--surface);
  color: var(--text2);
  text-decoration: none;
  transition: all 0.15s;
  flex-shrink: 0;
  letter-spacing: 0.01em;
}
.loc-pill:hover {
  border-color: var(--amber);
  color: var(--amber);
  text-decoration: none;
}
.loc-pill.active {
  background: var(--amber-dim);
  border-color: var(--amber);
  color: var(--amber);
}

/* On very small screens collapse the header into 2 rows */
@media (max-width: 420px) {
  .site-header {
    flex-wrap: wrap;
    height: auto;
    padding: 8px 12px;
    gap: 6px;
  }
  .loc-switcher {
    order: 3;
    width: 100%;
    padding: 0;
  }
  .header-spacer { display: none; }
}

/* ── Admin compact stat strip ────────────────────────────────────── */
.admin-stat-strip {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 4px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 10px 16px;
  font-size: 13px;
  color: var(--text2);
}
.astat { white-space: nowrap; }
.astat-num {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 16px;
  margin-right: 3px;
}
.astat-sep { color: var(--border2); }
