/* Brand colours + fonts live in brand.css (shared with the planning portal
   and stage view) — change them there, not here. */
@import url("brand.css");

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  min-height: 100%;
}

body {
  font-family: "Poppins", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  /* --footer-h is set from app.js to the sticky footer's real height, so the
     last queue item and the toast are never hidden behind it. */
  padding-bottom: calc(40px + var(--footer-h, 0px));
}

.wrap {
  max-width: 560px;
  margin: 0 auto;
  padding: 16px 16px 8px;
}

header.app-header {
  text-align: center;
  padding: 32px 16px 10px;
}

header.app-header .brand-logo {
  width: 56px;
  height: auto;
  margin-bottom: 10px;
}

header.app-header .brand-name {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 3px;
  color: var(--gold-deep);
  margin-bottom: 10px;
}

header.app-header h1 {
  margin: 0;
  font-family: "Playfair Display", Georgia, serif;
  font-style: italic;
  font-weight: 600;
  font-size: 1.7rem;
  line-height: 1.25;
  letter-spacing: 0.2px;
  color: var(--ink);
}

header.app-header .event-name {
  margin-top: 10px;
  color: var(--gold-deep);
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 2px;
}

header.app-header .event-name::before,
header.app-header .event-name::after {
  content: "—";
  margin: 0 8px;
  opacity: 0.6;
}

.tabs {
  display: flex;
  gap: 8px;
  margin: 20px 0;
}

.tab-btn {
  flex: 1;
  padding: 12px 8px;
  border-radius: 999px;
  border: 1px solid var(--card-border);
  background: var(--card);
  color: var(--charcoal);
  font-family: inherit;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
}

.tab-btn.active {
  background: var(--gold);
  border-color: var(--gold);
  color: #ffffff;
}

.panel {
  display: none;
}

.panel.active {
  display: block;
  animation: fadeInPanel 0.22s ease;
}

@keyframes fadeInPanel {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.dedication-card {
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  margin-bottom: 16px;
  overflow: hidden;
}

.dedication-summary {
  cursor: pointer;
  list-style: none;
  padding: 12px 14px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--gold-deep);
}

.dedication-summary::-webkit-details-marker {
  display: none;
}

.dedication-summary::marker {
  content: "";
}

.dedication-fields {
  padding: 2px 14px 14px;
}

.dedication-fields .field-row:last-child {
  margin-bottom: 0;
}

.queue-item .info .dedication {
  color: var(--gold-deep);
  font-size: 0.78rem;
  font-style: italic;
  margin-top: 2px;
}

.queue-item .info .message {
  color: var(--text);
  font-size: 0.78rem;
  font-style: italic;
  margin-top: 2px;
  word-break: break-word;
}

.hybrid-divider {
  text-align: center;
  color: var(--gold-deep);
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  margin: 18px 0;
}

.mode-headline {
  font-family: "Playfair Display", Georgia, serif;
  font-weight: 700;
  font-size: 1.6rem;
  color: var(--ink);
  text-align: center;
  margin: 4px 0 14px;
}

.search-input {
  width: 100%;
  margin-bottom: 18px;
  padding: 12px 14px;
  border-radius: 999px;
  border: 1px solid var(--card-border);
  background: var(--card);
  color: var(--ink);
  font-family: inherit;
  font-size: 0.95rem;
}

.artist-group {
  border-bottom: 1px solid var(--card-border);
}

.artist-group .artist-name {
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-family: "Playfair Display", Georgia, serif;
  font-style: italic;
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--gold-deep);
  padding: 14px 2px;
}

.artist-group .artist-name::-webkit-details-marker {
  display: none;
}

.artist-group .artist-name::marker {
  content: "";
}

.artist-group .artist-name::after {
  content: "";
  flex-shrink: 0;
  width: 7px;
  height: 7px;
  margin-bottom: 3px;
  border-right: 2px solid var(--gold-deep);
  border-bottom: 2px solid var(--gold-deep);
  transform: rotate(45deg);
  transition: transform 0.25s ease;
}

.artist-group[open] .artist-name::after {
  transform: rotate(225deg);
  margin-bottom: -3px;
}

.artist-group .artist-content {
  overflow: hidden;
}

.artist-group .song-grid {
  padding: 0 2px 16px;
}

.song-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

@media (min-width: 420px) {
  .song-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.song-btn {
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  padding: 14px 12px;
  color: var(--charcoal);
  font-family: inherit;
  text-align: left;
  cursor: pointer;
  min-height: 64px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 2px;
  transition: transform 0.08s ease, box-shadow 0.15s ease, border-color 0.15s ease, background 0.15s ease;
}

.song-btn:active {
  transform: scale(0.97);
}

.song-btn .title {
  font-weight: 700;
  font-size: 0.95rem;
  line-height: 1.2;
  color: var(--ink);
}

.song-btn .artist {
  color: var(--text-dim);
  font-size: 0.8rem;
}

.song-btn.picked {
  background: var(--gold-tint);
  border-color: var(--gold);
  box-shadow: 0 2px 10px rgba(184, 151, 126, 0.25);
}

.song-btn.picked .title::after {
  content: " ✓";
  color: var(--gold-deep);
}

/* "Your song just played" banner (top of the Live Queue) */
.played-banner {
  position: relative;
  background: var(--gold-tint);
  border: 1px solid var(--gold);
  border-radius: 12px;
  padding: 14px 38px 14px 16px;
  margin-bottom: 14px;
  box-shadow: 0 2px 12px rgba(184, 151, 126, 0.18);
}

.played-banner-text {
  font-family: "Playfair Display", Georgia, serif;
  font-style: italic;
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--ink);
  line-height: 1.3;
}

.played-banner-close {
  position: absolute;
  top: 8px;
  right: 10px;
  background: none;
  border: none;
  color: var(--gold-deep);
  font-size: 1rem;
  cursor: pointer;
}

/* Quiet, always-there footer ask — pinned to the bottom of the screen, but
   never covers anything: body padding grows by its height. */
.guest-footer {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 40;
  padding: 6px 16px calc(6px + env(safe-area-inset-bottom, 0px));
  text-align: center;
  background: rgba(233, 230, 225, 0.94);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  border-top: 1px solid var(--card-border);
}

.footer-link {
  background: none;
  border: none;
  color: var(--gold-deep);
  font-family: inherit;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.3px;
  cursor: pointer;
  padding: 8px;
}

.footer-book-btn {
  display: block;
  width: 100%;
  background: var(--gold);
  border: 1px solid var(--gold);
  border-radius: 999px;
  color: #ffffff;
  font-family: inherit;
  font-weight: 700;
  font-size: 0.95rem;
  padding: 12px 16px;
  max-width: 528px;
  margin: 4px auto;
  cursor: pointer;
}

/* Lead form — only ever opens when a guest taps for it */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(23, 20, 18, 0.5);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  z-index: 60;
  padding: 16px;
}

@media (min-width: 560px) {
  .modal-backdrop {
    align-items: center;
  }
}

.modal-card {
  position: relative;
  width: 100%;
  max-width: 420px;
  max-height: 88vh;
  overflow-y: auto;
  background: var(--card);
  border: 1px solid var(--gold);
  border-radius: 16px;
  padding: 22px 20px 18px;
  box-shadow: 0 8px 30px rgba(23, 20, 18, 0.25);
  animation: slideUpModal 0.2s ease;
}

@keyframes slideUpModal {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.modal-close {
  position: absolute;
  top: 10px;
  right: 12px;
  background: none;
  border: none;
  color: var(--text-dim);
  font-size: 1.1rem;
  cursor: pointer;
}

.lead-headline {
  font-family: "Playfair Display", Georgia, serif;
  font-style: italic;
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--ink);
  margin-bottom: 4px;
  padding-right: 20px;
}

.lead-sub {
  color: var(--text-dim);
  font-size: 0.88rem;
  margin: 0 0 14px;
}

.lead-fine-print {
  color: var(--text-dim);
  font-size: 0.72rem;
  line-height: 1.45;
  margin: 0;
}

.queue-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.queue-item {
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  padding: 12px 14px;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: 0 1px 4px rgba(23, 20, 18, 0.05);
}

.queue-item .rank {
  font-family: "Playfair Display", Georgia, serif;
  font-weight: 700;
  font-size: 1.2rem;
  color: var(--gold-deep);
  min-width: 24px;
  text-align: center;
}

.queue-item .info {
  flex: 1;
  min-width: 0;
}

.queue-item .info .title {
  font-weight: 700;
  font-size: 0.98rem;
  color: var(--ink);
}

.queue-item .info .artist {
  color: var(--text-dim);
  font-size: 0.82rem;
}

.queue-item.played {
  opacity: 0.55;
}

.queue-item.played .title {
  text-decoration: line-through;
}

.played-badge {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--text-dim);
  border: 1px solid var(--card-border);
  border-radius: 999px;
  padding: 8px 12px;
  white-space: nowrap;
}

.tip-tiers {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.tip-tier-btn {
  border: 1px solid var(--gold);
  border-radius: 999px;
  padding: 5px 10px;
  background: var(--bg);
  color: var(--gold-deep);
  font-family: inherit;
  font-weight: 700;
  font-size: 0.78rem;
  cursor: pointer;
}

.tip-tier-btn:active {
  background: var(--gold);
  color: #ffffff;
}

.tip-tier-btn:disabled {
  opacity: 0.5;
  cursor: default;
}

.vote-btn {
  border: 1px solid var(--card-border);
  border-radius: 999px;
  padding: 8px 12px;
  background: var(--bg);
  color: var(--charcoal);
  font-family: inherit;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
}

.vote-btn.voted {
  background: var(--gold);
  border-color: var(--gold);
  color: #ffffff;
}

.empty-msg {
  text-align: center;
  color: var(--text-dim);
  padding: 30px 10px;
}

.connection-status {
  background: var(--danger);
  color: #ffffff;
  font-size: 0.85rem;
  font-weight: 600;
  text-align: center;
  padding: 10px 14px;
  border-radius: 10px;
  margin-bottom: 14px;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: calc(24px + var(--footer-h, 0px));
  transform: translateX(-50%);
  background: var(--ink);
  border: none;
  color: #ffffff;
  padding: 10px 18px;
  border-radius: 999px;
  font-size: 0.9rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
  z-index: 50;
  max-width: calc(100% - 32px);
  text-align: center;
}

.toast.show {
  opacity: 1;
}

/* Admin page */
.admin-card {
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 18px;
  box-shadow: 0 1px 4px rgba(23, 20, 18, 0.05);
}

.admin-card h2 {
  margin-top: 0;
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--gold);
  display: inline-block;
  font-family: "Playfair Display", Georgia, serif;
  font-weight: 700;
  font-size: 1.2rem;
  color: var(--ink);
}

.admin-card > summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--gold);
}

.admin-card > summary::-webkit-details-marker {
  display: none;
}

.admin-card > summary::marker {
  content: "";
}

.admin-card > summary .admin-card-title {
  flex: 1;
  font-family: "Playfair Display", Georgia, serif;
  font-weight: 700;
  font-size: 1.2rem;
  color: var(--ink);
}

.admin-card > summary .chevron {
  flex-shrink: 0;
  color: var(--gold-deep);
  font-size: 1rem;
  transition: transform 0.2s ease;
}

.admin-card[open] > summary .chevron {
  transform: rotate(180deg);
}

.field-row {
  display: flex;
  gap: 8px;
  margin-bottom: 10px;
}

input[type="text"], input[type="password"], input[type="email"], input[type="tel"], select {
  flex: 1;
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid var(--card-border);
  background: var(--bg);
  color: var(--ink);
  font-family: inherit;
  font-size: 0.95rem;
}

button.primary {
  background: var(--gold);
  border: 1px solid var(--gold);
  color: #ffffff;
  font-family: inherit;
  font-weight: 700;
  padding: 10px 16px;
  border-radius: 8px;
  cursor: pointer;
}

button.secondary {
  background: var(--bg);
  border: 1px solid var(--card-border);
  color: var(--charcoal);
  font-family: inherit;
  font-weight: 600;
  padding: 10px 16px;
  border-radius: 8px;
  cursor: pointer;
}

button.danger {
  background: var(--danger);
  border: none;
  color: white;
  font-family: inherit;
  font-weight: 700;
  padding: 12px 16px;
  border-radius: 8px;
  cursor: pointer;
  width: 100%;
}

.song-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 0;
  border-bottom: 1px solid var(--card-border);
}

.song-row:last-child {
  border-bottom: none;
}

.song-row .remove-btn {
  background: none;
  border: none;
  color: var(--danger);
  font-size: 1.2rem;
  cursor: pointer;
}

.pin-gate {
  max-width: 320px;
  margin: 80px auto;
  text-align: center;
  padding: 0 16px;
}

.pin-gate h1 {
  font-family: "Playfair Display", Georgia, serif;
  font-style: italic;
  color: var(--ink);
}

.qr-box {
  text-align: center;
  margin-top: 10px;
}

.qr-box img {
  border-radius: 8px;
  margin-top: 10px;
  border: 1px solid var(--card-border);
}

.link-display {
  word-break: break-all;
  background: var(--bg);
  border: 1px solid var(--card-border);
  padding: 10px;
  border-radius: 8px;
  font-size: 0.85rem;
  color: var(--charcoal);
  margin-top: 8px;
}

/* ============================================================
   3.0 — bookings, portal offers, songs to learn (setup page)
   Brand tokens only (brand.css).
   ============================================================ */
input[type="date"], input[type="time"], input[type="number"] {
  flex: 1;
  min-width: 0;
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid var(--card-border);
  background: var(--bg);
  color: var(--ink);
  font-family: inherit;
  font-size: 0.95rem;
}

.stage-link {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--gold-deep);
  text-decoration: none;
  border: 1px solid var(--gold);
  border-radius: 999px;
  padding: 6px 14px;
  background: var(--card);
}

.booking-event-note {
  background: var(--gold-tint);
  border: 1px solid var(--gold);
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 0.85rem;
  color: var(--ink);
  margin-bottom: 10px;
}

.booking-event-note.warn {
  border-color: var(--danger);
}

.booking-form {
  border: 1px solid var(--gold);
  border-radius: 12px;
  padding: 14px;
  margin: 12px 0;
  background: var(--gold-tint);
}

.booking-form input, .booking-form select {
  background: var(--card);
}

.form-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--ink);
  margin-bottom: 10px;
}

.grid-2 {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
}

@media (min-width: 480px) {
  .grid-2 {
    grid-template-columns: 1fr 1fr;
  }
}

.inline-check {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.88rem;
  color: var(--charcoal);
}

.inline-check input {
  accent-color: var(--gold);
}

.booking-item {
  border: 1px solid var(--card-border);
  border-radius: 12px;
  margin-top: 10px;
  overflow: hidden;
}

.booking-item > summary {
  list-style: none;
  cursor: pointer;
  padding: 12px 14px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}

.booking-item > summary::-webkit-details-marker {
  display: none;
}

.booking-item[open] > summary {
  border-bottom: 1px solid var(--card-border);
  background: var(--bg);
}

.booking-name {
  font-weight: 700;
  color: var(--ink);
}

.booking-sub {
  color: var(--text-dim);
  font-size: 0.8rem;
}

.status-chip {
  flex-shrink: 0;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  border-radius: 999px;
  padding: 3px 9px;
  border: 1px solid var(--card-border);
  color: var(--text-dim);
  background: var(--card);
}

.status-chip.started {
  border-color: var(--gold);
  color: var(--gold-deep);
}

.status-chip.submitted {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--on-gold);
}

.booking-body {
  padding: 12px 14px 14px;
  font-size: 0.88rem;
}

.booking-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 12px;
}

.booking-actions button, .booking-actions a {
  padding: 6px 11px;
  font-size: 0.8rem;
  text-decoration: none;
}

.plan-section {
  margin-top: 10px;
}

.plan-section-title {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--gold-deep);
  margin-bottom: 3px;
}

.plan-section ul {
  margin: 0;
  padding-left: 18px;
  color: var(--charcoal);
}

.warn-line {
  color: var(--danger);
  font-weight: 600;
  margin-top: 8px;
}

.extend-box {
  margin: 8px 0 12px;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px dashed var(--gold);
  background: var(--gold-tint);
}

.price-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--card-border);
  font-size: 0.9rem;
  color: var(--charcoal);
}

.hint {
  color: var(--text-dim);
  font-size: 0.78rem;
}

.price-input {
  display: flex;
  align-items: center;
  gap: 4px;
  width: 110px;
  flex-shrink: 0;
  color: var(--text-dim);
}

.addon-edit {
  border-bottom: 1px solid var(--card-border);
  padding: 12px 0;
  display: grid;
  gap: 6px;
}

.addon-edit .top {
  display: flex;
  gap: 8px;
  align-items: center;
}

.request-badge {
  display: inline-block;
  margin-top: 3px;
  margin-right: 4px;
  font-size: 0.72rem;
  font-weight: 700;
  border-radius: 999px;
  padding: 2px 8px;
  background: var(--gold-tint);
  color: var(--gold-deep);
}

.request-badge.blocked {
  background: var(--card);
  border: 1px solid var(--danger);
  color: var(--danger);
}

.booking-actions a.primary, .booking-actions a.secondary {
  display: inline-flex;
  align-items: center;
  font-weight: 600;
  border-radius: 8px;
}

.booking-actions a.primary {
  background: var(--gold);
  border: 1px solid var(--gold);
  color: var(--on-gold);
}

.booking-actions a.secondary {
  background: var(--bg);
  border: 1px solid var(--card-border);
  color: var(--charcoal);
}

.form-sub {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--ink);
  margin: 12px 0 6px;
}

.service-checks {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  margin-bottom: 4px;
}
