:root {
  color-scheme: dark;
  --black: #050505;
  --charcoal: #121212;
  --panel: #181818;
  --line: #303030;
  --white: #f2f2f2;
  --muted: #b9b9b9;
  --cyan: #31e8ff;
  --red: #ff4662;
  --gold: #ffd12a;
  --shadow: 0 18px 46px rgba(0, 0, 0, 0.55);
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

body {
  margin: 0;
  min-width: 320px;
  background: var(--black);
  color: var(--white);
  font-family: "Trebuchet MS", Arial, Helvetica, sans-serif;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  min-height: 44px;
  border: 1px solid rgba(255, 70, 98, 0.82);
  border-radius: 8px;
  padding: 0 18px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 70, 98, 0.14);
  color: var(--white);
  font-weight: 700;
  text-decoration: none;
  text-transform: uppercase;
  white-space: nowrap;
  box-shadow: 0 0 18px rgba(255, 70, 98, 0.18);
}

button:hover,
button:focus-visible {
  background: rgba(255, 70, 98, 0.26);
}

a {
  color: var(--gold);
  font-weight: 700;
  text-decoration-color: rgba(255, 209, 42, 0.58);
  text-underline-offset: 3px;
}

a:hover {
  color: var(--white);
}

.events-shell {
  min-height: 100vh;
  background:
    linear-gradient(180deg, rgba(5, 5, 5, 0.42), var(--black) 42%),
    radial-gradient(circle at 22% 18%, rgba(49, 232, 255, 0.12), transparent 26%),
    radial-gradient(circle at 74% 8%, rgba(255, 70, 98, 0.1), transparent 24%),
    var(--black);
}

.events-hero,
.events-widget,
.admin-panel {
  padding-right: max(18px, calc((100vw - 1120px) / 2));
  padding-left: max(18px, calc((100vw - 1120px) / 2));
}

.events-hero {
  display: grid;
  grid-template-columns: minmax(180px, 320px) minmax(0, 1fr);
  gap: 24px;
  align-items: center;
  padding-top: 32px;
  padding-bottom: 30px;
  border-bottom: 1px solid var(--line);
  background:
    linear-gradient(90deg, rgba(5, 5, 5, 0.94), rgba(5, 5, 5, 0.78)),
    url("./assets/good-times-karaoke.jpg") right 7vw center / 250px auto no-repeat;
}

.admin-hero {
  grid-template-columns: 180px minmax(0, 1fr);
}

.events-logo-link {
  display: inline-flex;
  align-items: center;
}

.events-logo {
  display: block;
  width: 100%;
  max-height: 150px;
  object-fit: contain;
  filter:
    drop-shadow(0 0 12px rgba(49, 232, 255, 0.5))
    drop-shadow(0 0 18px rgba(255, 70, 98, 0.25));
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--cyan);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
  text-shadow: 0 0 12px rgba(49, 232, 255, 0.74);
}

h1,
h2,
h3 {
  margin: 0;
  line-height: 1.05;
  text-transform: uppercase;
}

h1 {
  max-width: 780px;
  font-size: 3.75rem;
  text-shadow: 0 0 14px rgba(255, 255, 255, 0.36);
}

h2 {
  font-size: 2.35rem;
}

h3 {
  font-size: 1.45rem;
}

.helper-copy {
  max-width: 760px;
  margin: 12px 0 0;
  color: var(--muted);
  line-height: 1.5;
}

.events-widget {
  display: grid;
  gap: 30px;
  padding-top: 30px;
  padding-bottom: 48px;
}

.events-section-heading {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
}

.compact-heading h2,
.compact-heading h3 {
  font-size: 1.8rem;
}

.event-group {
  display: grid;
  gap: 16px;
}

.event-card-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.event-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(18, 18, 18, 0.92);
  box-shadow: var(--shadow);
}

.event-card.is-featured {
  border-color: rgba(255, 209, 42, 0.72);
  box-shadow:
    0 0 0 1px rgba(255, 209, 42, 0.14),
    0 0 24px rgba(255, 209, 42, 0.14),
    var(--shadow);
}

.event-card-image {
  aspect-ratio: 16 / 9;
  border-bottom: 1px solid var(--line);
  background: #101010;
}

.event-card-image img,
.event-vibe-video video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.event-vibe-video {
  float: right;
  width: 128px;
  min-width: 128px;
  aspect-ratio: 1 / 1;
  margin: 0 0 12px 18px;
  overflow: hidden;
  border: 1px solid rgba(255, 209, 42, 0.32);
  border-radius: 8px;
  background: #101010;
}

.event-card-copy {
  display: flow-root;
  padding: 16px;
}

.event-card-copy > * + * {
  margin-top: 10px;
}

.event-card-copy > .event-vibe-video + * {
  margin-top: 0;
}

.event-card-topline + .event-vibe-video + h3,
.event-card-topline + h3 {
  margin-top: 16px;
}

.event-card-topline,
.badge-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.event-date,
.event-time,
.event-description,
.event-detail,
.event-hook,
.event-action,
.tiktok-note,
.admin-event-main p,
.admin-count {
  margin: 0;
}

.event-date {
  color: var(--gold);
  font-weight: 700;
  text-shadow: 0 0 14px rgba(255, 209, 42, 0.35);
}

.event-detail {
  color: var(--muted);
}

.event-card h3 {
  font-size: 1.7rem;
  line-height: 1.08;
  text-shadow: 0 0 12px rgba(255, 255, 255, 0.24);
}

.event-time {
  color: var(--gold);
  font-size: 1.18rem;
  font-weight: 700;
  line-height: 1.25;
  text-shadow: 0 0 12px rgba(255, 209, 42, 0.24);
}

.event-description {
  line-height: 1.45;
}

.event-hook {
  color: var(--cyan);
  font-weight: 700;
}

.event-action {
  color: var(--gold);
  font-weight: 700;
}

.status-badge,
.vibe-tag {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  border: 1px solid rgba(49, 232, 255, 0.48);
  border-radius: 8px;
  padding: 0 9px;
  background: rgba(49, 232, 255, 0.08);
  color: var(--white);
  font-size: 0.78rem;
  font-weight: 700;
}

.status-badge.published {
  border-color: rgba(49, 232, 255, 0.58);
  color: var(--cyan);
}

.status-badge.draft {
  border-color: rgba(185, 185, 185, 0.42);
  color: var(--muted);
}

.status-badge.featured {
  border-color: rgba(255, 209, 42, 0.72);
  background: rgba(255, 209, 42, 0.12);
  color: var(--gold);
}

.status-badge.cancelled {
  border-color: rgba(255, 70, 98, 0.72);
  background: rgba(255, 70, 98, 0.12);
  color: var(--red);
}

.vibe-tag {
  border-color: rgba(255, 70, 98, 0.5);
  background: rgba(255, 70, 98, 0.08);
}

.empty-state {
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 22px;
  background: rgba(18, 18, 18, 0.92);
  color: var(--muted);
  font-weight: 700;
}

.tiktok-note {
  border-top: 1px solid rgba(255, 209, 42, 0.22);
  padding-top: 18px;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.45;
  text-align: center;
}

.admin-shell {
  padding-bottom: 46px;
}

.admin-panel {
  padding-top: 28px;
}

.event-admin-form {
  display: grid;
  gap: 18px;
}

fieldset {
  display: grid;
  gap: 14px;
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px;
  background: rgba(18, 18, 18, 0.92);
  box-shadow: var(--shadow);
}

legend {
  padding: 0 8px;
  color: var(--cyan);
  font-weight: 700;
  text-transform: uppercase;
  text-shadow: 0 0 12px rgba(49, 232, 255, 0.5);
}

.form-grid {
  display: grid;
  gap: 14px;
}

.two-column {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.four-column {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.form-field,
.checkbox-group {
  display: grid;
  gap: 9px;
}

.form-field span,
.form-label {
  margin: 0;
  color: var(--muted);
  font-weight: 700;
  text-transform: uppercase;
}

.admin-only span,
.admin-only .form-label {
  color: var(--gold);
}

input[type="text"],
input[type="url"],
input[type="date"],
input[type="time"],
select,
textarea {
  width: 100%;
  min-height: 52px;
  border: 1px solid rgba(49, 232, 255, 0.72);
  border-radius: 8px;
  padding: 0 14px;
  background: rgba(12, 12, 12, 0.9);
  color: var(--white);
  box-shadow:
    0 0 0 1px rgba(49, 232, 255, 0.14),
    0 0 24px rgba(49, 232, 255, 0.14);
}

textarea {
  min-height: 118px;
  padding: 14px;
  line-height: 1.45;
  resize: vertical;
}

input::placeholder,
textarea::placeholder {
  color: #8f8f8f;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--cyan);
  outline: 3px solid rgba(49, 232, 255, 0.22);
}

.checkbox-row,
.toggle-grid,
.form-actions,
.json-actions,
.filter-bar,
.admin-event-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.check-pill,
.switch-row {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  min-height: 38px;
  color: var(--white);
  font-weight: 700;
}

.check-pill {
  border: 1px solid rgba(49, 232, 255, 0.48);
  border-radius: 8px;
  padding: 0 10px;
  background: rgba(49, 232, 255, 0.08);
}

.switch-row {
  width: fit-content;
}

.quiet-button,
.filter-button,
.load-more-button {
  border-color: rgba(49, 232, 255, 0.48);
  background: rgba(49, 232, 255, 0.08);
  box-shadow: none;
}

.quiet-button:hover,
.filter-button:hover,
.filter-button.is-active,
.load-more-button:hover {
  background: rgba(49, 232, 255, 0.18);
}

.load-more-button {
  width: fit-content;
  margin-top: 14px;
}

.danger-button {
  border-color: rgba(255, 70, 98, 0.72);
  background: rgba(255, 70, 98, 0.1);
  box-shadow: none;
}

.form-status {
  border: 1px solid rgba(255, 209, 42, 0.52);
  border-radius: 8px;
  padding: 12px 14px;
  background: rgba(255, 209, 42, 0.1);
  color: var(--gold);
  font-weight: 700;
}

.json-tools-panel {
  display: grid;
  gap: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px;
  background: rgba(18, 18, 18, 0.92);
  box-shadow: var(--shadow);
}

.json-import-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(240px, 0.42fr);
  gap: 14px;
  align-items: end;
}

.json-import-actions {
  display: grid;
  gap: 12px;
}

.preview-frame-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.preview-frame {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(5, 5, 5, 0.78);
  box-shadow: var(--shadow);
}

.preview-label {
  margin: 0;
  border-bottom: 1px solid var(--line);
  padding: 10px 14px;
  color: var(--gold);
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
}

.preview-frame .events-widget {
  padding: 18px;
}

.preview-frame-mobile .event-card-grid {
  grid-template-columns: minmax(0, 1fr);
}

.preview-frame-mobile {
  width: min(390px, 100%);
}

.preview-frame-mobile .event-vibe-video {
  width: 92px;
  min-width: 92px;
}

.preview-frame-mobile .events-section-heading {
  align-items: stretch;
  flex-direction: column;
}

.preview-frame-mobile h3,
.preview-frame-mobile .compact-heading h3 {
  font-size: 1.35rem;
}

.admin-count {
  color: var(--gold);
  font-weight: 700;
}

.admin-event-list {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.admin-event-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
  background: rgba(18, 18, 18, 0.92);
  box-shadow: var(--shadow);
}

.admin-event-main {
  display: grid;
  gap: 8px;
}

.admin-event-main p {
  color: var(--muted);
}

@media (max-width: 820px) {
  .events-hero,
  .admin-hero {
    grid-template-columns: minmax(0, 1fr);
    padding-top: 24px;
    background:
      linear-gradient(180deg, rgba(5, 5, 5, 0.9), rgba(5, 5, 5, 0.96)),
      url("./assets/good-times-karaoke.jpg") right 18px top 18px / 112px auto no-repeat;
  }

  .events-logo {
    width: min(260px, 72vw);
    max-height: 118px;
  }

  h1 {
    font-size: 2.45rem;
  }

  h2 {
    font-size: 2rem;
  }

  h3,
  .compact-heading h2,
  .compact-heading h3 {
    font-size: 1.45rem;
  }

  .event-card h3 {
    font-size: 1.5rem;
  }

  .event-time {
    font-size: 1.08rem;
  }

  .event-vibe-video {
    width: 96px;
    min-width: 96px;
    margin-left: 12px;
  }

  .events-section-heading,
  .admin-event-item {
    align-items: stretch;
    grid-template-columns: minmax(0, 1fr);
  }

  .events-section-heading {
    flex-direction: column;
  }

  .event-card-grid,
  .two-column,
  .four-column,
  .json-import-grid,
  .preview-frame-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .admin-event-actions,
  .form-actions,
  .json-actions,
  .form-actions button,
  .json-actions button,
  .admin-event-actions button,
  .load-more-button {
    width: 100%;
  }

  .filter-bar {
    align-items: stretch;
  }

  .filter-button {
    flex: 1 1 120px;
  }
}
