/* Core resets and variables */
:root {
  --font-family-primary: 'Outfit', sans-serif;
  --font-family-secondary: 'Inter', sans-serif;
  
  /* HSL Color System - Premium Broadway Theatrical Theme */
  --bg-deep: hsl(348, 12%, 4%); /* Deep velvet obsidian charcoal with a tiny hint of red */
  --bg-dark: hsl(0, 0%, 2%); /* Deep black stage background */
  --bg-card: hsla(348, 10%, 10%, 0.55);
  
  --panel-glass: hsla(348, 12%, 6%, 0.85);
  --border-glass: hsla(0, 0%, 100%, 0.05);
  --border-active: hsla(38, 98%, 52%, 0.35); /* Glowing marquee gold border */
  
  --text-primary: hsl(0, 0%, 100%);
  --text-secondary: hsl(38, 10%, 80%);
  --text-muted: hsl(348, 8%, 50%);
  
  --accent-red: hsl(348, 80%, 42%); /* Deep rich velvet red */
  --accent-gold: hsl(38, 98%, 52%); /* Marquee gold */
  --accent-green: hsl(142, 70%, 45%);
  --accent-blue: hsl(210, 100%, 55%);
  --accent-yellow: hsl(38, 98%, 52%); /* Use marquee gold for stars */
  
  --gradient-broadway: linear-gradient(135deg, var(--accent-red) 0%, hsl(348, 90%, 20%) 100%);
  --gradient-success: linear-gradient(135deg, hsl(142, 70%, 45%) 0%, hsl(160, 80%, 40%) 100%);
  --gradient-card: linear-gradient(180deg, hsla(348, 10%, 10%, 0.6) 0%, hsla(348, 10%, 6%, 0.85) 100%);
  --gradient-gold: linear-gradient(135deg, var(--accent-gold) 0%, hsl(38, 90%, 35%) 100%);
  
  --shadow-sm: 0 4px 12px rgba(0, 0, 0, 0.2);
  --shadow-md: 0 10px 30px rgba(0, 0, 0, 0.4);
  --shadow-glow: 0 0 20px hsla(38, 98%, 52%, 0.15); /* Warm golden marquee glow */
  --shadow-glow-red: 0 0 20px hsla(348, 80%, 42%, 0.25);
  
  --radius-lg: 16px;
  --radius-md: 10px;
  --radius-sm: 6px;
  
  --transition-smooth: all 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
  --transition-fast: all 0.15s ease;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: var(--font-family-primary);
  background-color: var(--bg-deep);
  color: var(--text-primary);
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
  -webkit-font-smoothing: antialiased;
}

/* Background animated glowing orbs */
.glass-bg-container {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: -1;
  overflow: hidden;
  background: radial-gradient(circle at 50% 50%, var(--bg-dark) 0%, var(--bg-deep) 100%);
}

.glow-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(140px);
  opacity: 0.1;
  animation: pulse 15s infinite alternate;
}

.orb-1 {
  width: 600px;
  height: 600px;
  top: -150px;
  right: -50px;
  background: var(--accent-red);
}

.orb-2 {
  width: 700px;
  height: 700px;
  bottom: -200px;
  left: -150px;
  background: var(--accent-gold);
  animation-duration: 20s;
}

@keyframes pulse {
  0% { transform: translate(0, 0) scale(1); }
  100% { transform: translate(40px, 40px) scale(1.1); }
}

/* App Layout */
.app-container {
  max-width: 1350px;
  margin: 0 auto;
  padding: 24px 16px;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  gap: 20px;
}

/* Header */
.app-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 24px;
  background: var(--panel-glass);
  backdrop-filter: blur(25px);
  -webkit-backdrop-filter: blur(25px);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}

.logo-area {
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo-emoji {
  font-size: 28px;
}

.logo-text h1 {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.5px;
  background: linear-gradient(90deg, #fff 50%, var(--text-secondary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.logo-text p {
  font-size: 11px;
  color: var(--accent-gold);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
}

/* Scheduler status badge */
.scheduler-status-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: 50px;
  background: hsla(224, 71%, 1%, 0.4);
  border: 1px solid var(--border-glass);
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
  transition: var(--transition-smooth);
}

.scheduler-status-badge .status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--text-muted);
}

.scheduler-status-badge.active {
  border-color: hsla(142, 70%, 45%, 0.25);
  background: hsla(142, 70%, 45%, 0.05);
  color: #fff;
}

.scheduler-status-badge.active .status-dot {
  background: var(--accent-green);
  box-shadow: 0 0 8px var(--accent-green);
}

/* Grid Layout */
.main-grid {
  display: grid;
  grid-template-columns: 340px 1fr;
  gap: 20px;
  flex: 1;
  transition: grid-template-columns 0.4s cubic-bezier(0.2, 0.8, 0.2, 1), gap 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.preferences-collapsed .main-grid {
  grid-template-columns: 0px 1fr;
  gap: 0px;
}

@media (max-width: 1024px) {
  .main-grid {
    grid-template-columns: 1fr;
  }
  .preferences-collapsed .main-grid {
    grid-template-columns: 1fr;
  }
}

/* Panels */
.glass-panel {
  background: var(--panel-glass);
  backdrop-filter: blur(25px);
  -webkit-backdrop-filter: blur(25px);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: var(--shadow-sm);
  transition: padding 0.4s cubic-bezier(0.2, 0.8, 0.2, 1), opacity 0.4s cubic-bezier(0.2, 0.8, 0.2, 1), border-width 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.settings-panel {
  display: flex;
  flex-direction: column;
  gap: 16px;
  height: fit-content;
  transition: all 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
  overflow: hidden;
  position: sticky;
  top: 24px;
}

.preferences-collapsed .settings-panel {
  width: 0;
  padding: 0;
  border-width: 0;
  opacity: 0;
  margin: 0;
  pointer-events: none;
}

@media (max-width: 1024px) {
  .preferences-collapsed .settings-panel {
    display: none;
  }
}

.panel-header {
  display: flex;
  align-items: center;
  gap: 8px;
  border-bottom: 1px solid var(--border-glass);
  padding-bottom: 12px;
}

.panel-header h2 {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.2px;
}

.panel-header .icon {
  width: 18px;
  height: 18px;
  color: var(--accent-red);
}

/* Forms */
.settings-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.settings-section {
  display: flex;
  flex-direction: column;
  gap: 10px;
  border-bottom: 1px solid hsla(0, 0%, 100%, 0.03);
  padding-bottom: 14px;
}

.settings-section:last-of-type {
  border-bottom: none;
  padding-bottom: 0;
}

.settings-section h3 {
  font-size: 12px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.8px;
}

.section-helper {
  font-size: 11px;
  color: var(--text-muted);
  font-family: var(--font-family-secondary);
  line-height: 1.4;
}

/* Toggle switch stylings */
.toggle-group {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 4px 0;
}

.toggle-switch {
  position: relative;
  display: inline-block;
  width: 38px;
  height: 20px;
  flex-shrink: 0;
}

.toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: hsla(224, 71%, 1%, 0.6);
  border: 1px solid var(--border-glass);
  transition: .25s ease;
  border-radius: 20px;
}

.slider:before {
  position: absolute;
  content: "";
  height: 12px;
  width: 12px;
  left: 3px;
  bottom: 3px;
  background-color: var(--text-secondary);
  transition: .25s cubic-bezier(0.2, 0.8, 0.2, 1);
  border-radius: 50%;
}

.toggle-switch input:checked + .slider {
  background-color: var(--accent-red);
  border-color: hsla(348, 80%, 42%, 0.3);
}

.toggle-switch input:checked + .slider:before {
  transform: translateX(18px);
  background-color: #fff;
}

.toggle-text {
  display: flex;
  flex-direction: column;
}

.toggle-title {
  font-size: 13px;
  font-weight: 600;
}

.toggle-desc {
  font-size: 10px;
  color: var(--text-muted);
  font-family: var(--font-family-secondary);
}

/* Input Fields */
.input-field-container {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.input-field-container label {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-secondary);
}

.input-field-container input {
  padding: 8px 12px;
  background: hsla(348, 12%, 2%, 0.5);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-sm);
  color: #fff;
  font-family: var(--font-family-secondary);
  font-size: 12px;
  transition: var(--transition-fast);
}

.input-field-container input:focus {
  outline: none;
  border-color: var(--accent-gold);
  box-shadow: 0 0 8px hsla(38, 98%, 52%, 0.15);
}

/* Schedule Time Input */
.schedule-time-row {
  display: flex;
  align-items: flex-end;
  gap: 8px;
}

.time-input-container {
  flex: 1;
}

.time-input-container input {
  height: 36px;
  text-align: center;
}

/* Buttons */
.btn {
  padding: 8px 14px;
  border-radius: var(--radius-md);
  font-family: var(--font-family-primary);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition-smooth);
  border: 1px solid transparent;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.btn-primary {
  background: var(--accent-red);
  color: #fff;
}

.btn-primary:hover {
  background: hsl(348, 85%, 48%);
  transform: translateY(-1px);
}

.btn-success {
  background: var(--gradient-success);
  color: #fff;
  border-color: hsla(142, 70%, 45%, 0.15);
}

.btn-success:hover {
  transform: translateY(-1px);
}

.btn-secondary {
  background: hsla(0, 0%, 100%, 0.04);
  color: #fff;
  border: 1px solid var(--border-glass);
}

.btn-secondary:hover {
  background: hsla(0, 0%, 100%, 0.07);
}

.btn-full {
  width: 100%;
}

.btn-glow.btn-success:hover {
  box-shadow: 0 0 15px hsla(142, 70%, 45%, 0.25);
}

.btn-glow.btn-primary:hover {
  box-shadow: var(--shadow-glow-red);
}

.controls-section {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-bottom: 0;
}

/* System Console Log Box */
.console-wrapper {
  border-radius: var(--radius-md);
  border: 1px solid var(--border-glass);
  background: hsl(224, 71%, 1%);
  font-family: 'Courier New', Courier, monospace;
  overflow: hidden;
}

.console-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 6px 10px;
  background: hsla(224, 71%, 2%, 0.8);
  border-bottom: 1px solid var(--border-glass);
  font-size: 10px;
  font-weight: bold;
  color: var(--text-muted);
}

.console-dot-green {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent-green);
  box-shadow: 0 0 4px var(--accent-green);
}

.console-body {
  padding: 10px;
  height: 100px;
  overflow-y: auto;
  font-size: 10px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  scroll-behavior: smooth;
}

.log-line {
  line-height: 1.3;
}

.log-system { color: var(--accent-blue); }
.log-success { color: var(--accent-green); }
.log-error { color: var(--accent-red); }
.log-info { color: var(--text-secondary); }

/* Directory Panel */
.directory-panel {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Search bar row */
.search-bar-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
}

@media (max-width: 768px) {
  .search-bar-row {
    flex-direction: column;
    align-items: stretch;
  }
}

.search-input-wrapper {
  position: relative;
  flex: 1;
}

.search-icon {
  position: absolute;
  left: 12px;
  top: 9px;
  width: 14px;
  height: 14px;
  color: var(--text-muted);
}

.search-input-wrapper input {
  width: 100%;
  padding: 8px 12px 8px 34px;
  background: hsla(348, 12%, 2%, 0.4);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  color: #fff;
  font-family: var(--font-family-secondary);
  font-size: 13px;
  transition: var(--transition-smooth);
}

.search-input-wrapper input:focus {
  outline: none;
  border-color: var(--accent-gold);
  box-shadow: 0 0 10px hsla(38, 98%, 52%, 0.12);
}

.sort-selector-wrapper {
  display: flex;
  align-items: center;
  gap: 8px;
}

.sort-select {
  padding: 8px 12px;
  background: hsla(348, 12%, 2%, 0.4);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  color: var(--text-secondary);
  font-family: var(--font-family-primary);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  outline: none;
  transition: var(--transition-smooth);
  height: 38px;
}

.sort-select:focus, .sort-select:hover {
  border-color: var(--accent-gold);
  color: #fff;
  box-shadow: 0 0 10px hsla(38, 98%, 52%, 0.08);
}

.sort-select option {
  background: hsl(348, 12%, 4%);
  color: #fff;
}

.directory-filter-tabs {
  display: flex;
  gap: 4px;
  background: hsla(348, 12%, 2%, 0.3);
  padding: 3px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-glass);
}

.filter-tab {
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--text-secondary);
  border: none;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  font-family: var(--font-family-primary);
  transition: var(--transition-fast);
}

.filter-tab:hover {
  color: #fff;
}

.filter-tab.active {
  background: var(--bg-card);
  color: #fff;
  border: 1px solid var(--border-glass);
}

/* Cards Grid */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 16px;
  min-height: 400px;
}

/* Individual Show Cards - Clean Ticket Design */
.show-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 12px;
  background: var(--gradient-card);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  padding: 16px;
  transition: var(--transition-smooth);
  overflow: hidden;
}

.show-card:hover {
  transform: translateY(-2px);
  border-color: hsla(38, 98%, 52%, 0.2);
  box-shadow: var(--shadow-md);
}

/* Watchlist active glow with animated gold marquee borders */
.show-card.watched {
  border-color: var(--accent-gold);
  box-shadow: 0 0 22px hsla(38, 98%, 52%, 0.12);
  animation: marqueeGlow 3s infinite alternate cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes marqueeGlow {
  0% {
    border-color: hsla(38, 98%, 52%, 0.35);
    box-shadow: 0 4px 20px -5px hsla(38, 98%, 52%, 0.05), 0 0 10px hsla(38, 98%, 52%, 0.05);
  }
  100% {
    border-color: hsla(38, 98%, 52%, 0.75);
    box-shadow: 0 4px 25px -3px hsla(38, 98%, 52%, 0.08), 0 0 18px hsla(38, 98%, 52%, 0.2);
  }
}

.show-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 8px;
}

.show-title-wrapper {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
}

.show-title {
  font-size: 15px;
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.2px;
}

.show-theatre {
  font-size: 11px;
  color: var(--text-muted);
  font-family: var(--font-family-secondary);
  display: flex;
  align-items: center;
  gap: 4px;
}

.icon-map {
  width: 10px;
  height: 10px;
  color: var(--text-muted);
  flex-shrink: 0;
}

/* Watchlist star icon button */
.btn-watchlist-toggle {
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 2px;
  color: var(--text-muted);
  transition: var(--transition-fast);
  flex-shrink: 0;
}

.btn-watchlist-toggle:hover {
  color: var(--accent-yellow);
  transform: scale(1.1);
}

.btn-watchlist-toggle.active {
  color: var(--accent-yellow);
}

.btn-watchlist-toggle svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

/* Policy Badges Row */
.policy-badges-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.badge {
  padding: 3px 8px;
  border-radius: 50px;
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border: 1px solid transparent;
}

.badge-lottery {
  background: hsla(348, 80%, 42%, 0.08);
  color: hsl(348, 85%, 70%);
  border-color: hsla(348, 80%, 42%, 0.25);
}

.badge-rush {
  background: hsla(38, 98%, 52%, 0.06);
  color: hsl(38, 98%, 70%);
  border-color: hsla(38, 98%, 52%, 0.2);
}

.badge-other {
  background: hsla(210, 100%, 50%, 0.05);
  color: hsl(210, 100%, 70%);
  border-color: hsla(210, 100%, 50%, 0.12);
}

/* Card details divider */
.card-divider {
  height: 1px;
  background: var(--border-glass);
  margin: 2px 0;
}

/* Collapsible Rules Block */
.show-card-policies {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* Rules Section Header Trigger */
.rules-accordion-trigger {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 6px 0;
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-family: var(--font-family-primary);
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition-fast);
  width: 100%;
}

.rules-accordion-trigger:hover {
  color: #fff;
}

.accordion-arrow {
  width: 12px;
  height: 12px;
  transition: transform 0.25s cubic-bezier(0.2, 0.8, 0.2, 1);
  color: var(--text-muted);
}

.rules-accordion-trigger.active .accordion-arrow {
  transform: rotate(180deg);
  color: #fff;
}

/* Sliding accordion container */
.rules-accordion-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.rules-accordion-content.expanded {
  max-height: 500px; /* Large enough to fit any show rules */
}

/* Detailed rules cards */
.policy-detail-block {
  display: flex;
  flex-direction: column;
  gap: 4px;
  background: hsla(348, 12%, 2%, 0.3);
  border: 1px solid var(--border-glass);
  padding: 8px 10px;
  border-radius: var(--radius-md);
  font-size: 11px;
}

.policy-block-title {
  font-size: 11px;
  font-weight: 700;
  color: #fff;
  display: flex;
  justify-content: space-between;
  border-bottom: 1px solid hsla(0, 0%, 100%, 0.03);
  padding-bottom: 4px;
  margin-bottom: 2px;
}

.policy-block-price {
  color: var(--accent-gold);
}

.policy-detail-row {
  display: flex;
  flex-direction: column;
  gap: 1px;
  font-family: var(--font-family-secondary);
}

.policy-detail-label {
  font-size: 9px;
  text-transform: uppercase;
  color: var(--text-muted);
  font-weight: 700;
}

.policy-detail-value {
  color: var(--text-secondary);
  line-height: 1.35;
}

/* Prominent Bottom Apply Buttons */
.card-actions-wrapper {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding-top: 4px;
}

.btn-apply-lottery {
  text-decoration: none;
  font-size: 11px;
  padding: 7px 10px;
  background: var(--gradient-broadway);
  color: #fff;
  border-radius: var(--radius-md);
  text-align: center;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  transition: var(--transition-smooth);
}

.btn-apply-lottery:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-glow-red);
}

/* Placeholder & Empty states */
.directory-placeholder {
  grid-column: 1 / -1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  color: var(--text-secondary);
  gap: 12px;
}

.placeholder-spinner {
  width: 32px;
  height: 32px;
  border: 3px solid var(--border-glass);
  border-top-color: var(--accent-red);
  border-radius: 50%;
  animation: spin 1s infinite linear;
}

.directory-placeholder p {
  font-size: 13px;
}

.empty-state {
  grid-column: 1 / -1;
  text-align: center;
  padding: 40px 16px;
}

.empty-emoji { font-size: 32px; margin-bottom: 8px; }
.empty-title { font-size: 16px; font-weight: bold; margin-bottom: 2px; }
.empty-desc { font-size: 12px; color: var(--text-muted); }

/* Footer */
.app-footer {
  text-align: center;
  padding: 16px 0 8px 0;
  border-top: 1px solid var(--border-glass);
  font-size: 10px;
  color: var(--text-muted);
  font-family: var(--font-family-secondary);
}

/* Show-Score circular rating badge design */
.show-score-badge-container {
  display: flex;
  align-items: center;
  gap: 8px;
}

.show-score-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  font-family: var(--font-family-primary);
  font-size: 13px;
  font-weight: 800;
  color: #fff;
  flex-shrink: 0;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.4);
  position: relative;
  transition: var(--transition-smooth);
}

.show-score-badge:hover {
  transform: scale(1.1) rotate(5deg);
}

/* Color-coded Show-Score circular dials */
.score-green {
  background: linear-gradient(135deg, var(--accent-green) 0%, hsl(142, 80%, 30%) 100%);
  border: 2px solid var(--accent-green);
  box-shadow: 0 0 12px hsla(142, 70%, 45%, 0.35);
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

.score-yellow {
  background: var(--gradient-gold);
  border: 2px solid var(--accent-gold);
  box-shadow: 0 0 12px hsla(38, 98%, 52%, 0.35);
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

.score-red {
  background: linear-gradient(135deg, var(--accent-red) 0%, hsl(348, 90%, 25%) 100%);
  border: 2px solid var(--accent-red);
  box-shadow: 0 0 12px hsla(348, 80%, 42%, 0.35);
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

.score-grey {
  background: linear-gradient(135deg, hsl(0, 0%, 35%) 0%, hsl(0, 0%, 20%) 100%);
  border: 2px solid hsl(0, 0%, 45%);
  box-shadow: 0 0 8px rgba(0, 0, 0, 0.2);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

/* Category details */
.show-score-info {
  display: flex;
  flex-direction: column;
}

.show-score-label {
  font-size: 8px;
  text-transform: uppercase;
  color: var(--text-muted);
  font-weight: 700;
  letter-spacing: 0.5px;
  line-height: 1;
}

.show-score-desc {
  font-size: 11px;
  font-weight: 700;
  color: var(--text-secondary);
  line-height: 1.2;
}

.show-score-desc.desc-green {
  color: var(--accent-green);
  text-shadow: 0 0 8px hsla(142, 70%, 45%, 0.1);
}

.show-score-desc.desc-yellow {
  color: var(--accent-gold);
  text-shadow: 0 0 8px hsla(38, 98%, 52%, 0.1);
}

.show-score-desc.desc-red {
  color: hsl(348, 85%, 65%);
  text-shadow: 0 0 8px hsla(348, 80%, 42%, 0.1);
}

/* Unrated show badge */
.show-score-unrated {
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 3px 8px;
  border-radius: 4px;
  background: hsla(0, 0%, 100%, 0.05);
  border: 1px solid hsla(0, 0%, 100%, 0.08);
  color: var(--text-muted);
}

/* Core inline SVGs */
.logo-svg {
  width: 24px;
  height: 24px;
  color: var(--accent-gold);
}

.header-svg {
  width: 16px;
  height: 16px;
  transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.prefs-icon {
  transform: rotate(-90deg);
}

.guide-svg {
  width: 14px;
  height: 14px;
  color: var(--accent-gold);
}

/* ==========================================
   Theme Toggle Layout & Button
   ========================================== */
.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.btn-theme-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  background: hsla(348, 12%, 2%, 0.4);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  color: var(--accent-gold);
  cursor: pointer;
  outline: none;
  font-size: 16px;
  transition: var(--transition-smooth);
}

.btn-theme-toggle:hover {
  background: hsla(348, 12%, 2%, 0.6);
  border-color: var(--accent-gold);
  transform: translateY(-1px);
  box-shadow: 0 0 10px hsla(38, 98%, 52%, 0.12);
}

/* ==========================================
   Light Mode Overrides
   ========================================== */
body.light-mode {
  --bg-deep: hsl(38, 30%, 96%); /* Very warm Broadway cream background */
  --bg-dark: hsl(38, 20%, 91%); /* Rich theatrical beige */
  --bg-card: hsla(0, 0%, 100%, 0.85); /* Premium glass card background */
  
  --panel-glass: hsla(0, 0%, 100%, 0.9); /* Premium high-opacity glass */
  --border-glass: hsla(348, 12%, 10%, 0.08); /* Darker border for cards */
  --border-active: hsla(38, 98%, 52%, 0.6); /* Glowing marquee gold border */
  
  --text-primary: hsl(348, 12%, 10%); /* Very dark velvet obsidian text */
  --text-secondary: hsl(348, 10%, 25%); /* Elegant secondary dark slate */
  --text-muted: hsl(348, 8%, 45%); /* Slate-gray text */
  
  --gradient-card: linear-gradient(180deg, hsla(0, 0%, 100%, 0.9) 0%, hsla(38, 20%, 94%, 0.92) 100%);
  
  --shadow-sm: 0 4px 12px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 10px 30px rgba(0, 0, 0, 0.07);
  --shadow-glow: 0 0 15px hsla(38, 98%, 52%, 0.15);
}

body.light-mode .glow-orb {
  opacity: 0.07; /* Dim the orbs slightly in light mode for soft highlights */
}

/* Light mode text colors & gradient logo */
body.light-mode .logo-text h1 {
  background: linear-gradient(90deg, var(--text-primary) 50%, var(--accent-red) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

body.light-mode .logo-text p {
  color: var(--text-secondary);
}

/* Light mode inputs & selectors */
body.light-mode .input-field-container input,
body.light-mode .search-input-wrapper input,
body.light-mode .sort-select {
  background: hsla(38, 20%, 90%, 0.6);
  border-color: hsla(348, 12%, 10%, 0.15);
  color: var(--text-primary);
}

body.light-mode .input-field-container input::placeholder,
body.light-mode .search-input-wrapper input::placeholder {
  color: var(--text-muted);
}

body.light-mode .sort-select option {
  background: hsl(38, 20%, 96%);
  color: var(--text-primary);
}

/* Light mode preferences, toggles & scheduler badge */
body.light-mode .scheduler-status-badge {
  background: hsla(348, 80%, 42%, 0.1);
  color: var(--accent-red);
}

body.light-mode .scheduler-status-badge.active {
  background: hsla(142, 70%, 45%, 0.12);
  color: var(--accent-green);
}

body.light-mode .toggle-switch .slider {
  background-color: hsla(38, 20%, 82%, 0.8);
}

/* Light mode accordion trigger & panels */
body.light-mode .rules-accordion-trigger {
  background: hsla(38, 20%, 90%, 0.4);
  color: var(--text-primary);
  border-color: var(--border-glass);
}

body.light-mode .rules-accordion-trigger:hover {
  background: hsla(38, 20%, 90%, 0.7);
  border-color: var(--accent-gold);
}

body.light-mode .rules-accordion-content {
  background: hsla(38, 20%, 90%, 0.25);
  border-color: var(--border-glass);
}

body.light-mode .policy-detail-block {
  border-color: hsla(348, 12%, 10%, 0.05);
}

body.light-mode .policy-block-title {
  color: var(--text-primary);
}

/* Light mode theme toggle button */
body.light-mode .btn-theme-toggle {
  background: hsla(38, 20%, 90%, 0.5);
  color: var(--accent-red);
}

body.light-mode .btn-theme-toggle:hover {
  background: hsla(38, 20%, 90%, 0.8);
  border-color: var(--accent-red);
  box-shadow: 0 0 10px hsla(348, 80%, 42%, 0.1);
}

/* Light mode secondary button */
body.light-mode .btn-secondary {
  background: hsla(38, 20%, 88%, 0.6);
  color: var(--text-primary);
  border-color: hsla(348, 12%, 10%, 0.15);
}

body.light-mode .btn-secondary:hover {
  background: hsla(38, 20%, 84%, 0.8);
  border-color: var(--accent-red);
  box-shadow: 0 0 10px hsla(348, 80%, 42%, 0.1);
}

/* Light mode terminal / logs console output */
body.light-mode .console-body {
  background: hsla(38, 20%, 92%, 0.5);
  border-color: hsla(348, 12%, 10%, 0.08);
}

body.light-mode .log-system,
body.light-mode .log-line {
  color: hsl(348, 12%, 15%);
}

body.light-mode .log-system {
  color: var(--text-secondary);
}

body.light-mode .log-success {
  color: hsl(142, 60%, 25%);
}

body.light-mode .log-error {
  color: hsl(348, 70%, 35%);
}

/* ==========================================
   Show Card Poster Covers
   ========================================== */
.show-card-poster {
  width: 70px;
  height: 105px;
  border-radius: var(--radius-sm);
  object-fit: cover;
  border: 1px solid var(--border-glass);
  box-shadow: var(--shadow-sm);
  flex-shrink: 0;
  transition: var(--transition-smooth);
}

.show-card:hover .show-card-poster {
  transform: scale(1.04);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.18);
  border-color: hsla(38, 98%, 52%, 0.3);
}

/* ==========================================
   Tablet & Mobile Overlay Adjustments
   ========================================== */
@media (max-width: 1024px) {
  .settings-panel {
    position: relative;
    top: 0;
    width: 100%;
    margin-bottom: 12px;
  }
}

/* ==========================================
   Phone Sized Screens Responsive Styles (<576px)
   ========================================== */
@media (max-width: 576px) {
  .app-container {
    padding: 12px 8px;
    gap: 12px;
  }
  
  .app-header {
    flex-direction: column;
    align-items: stretch;
    gap: 14px;
    padding: 14px;
  }
  
  .header-actions {
    display: flex;
    justify-content: space-between;
    width: 100%;
    gap: 8px;
  }
  
  .scheduler-status-badge {
    flex: 1;
    justify-content: center;
    padding: 8px 12px;
    font-size: 11px;
  }
  
  .btn-theme-toggle {
    width: 36px;
    height: 36px;
  }
  
  .search-bar-row {
    padding: 12px;
    gap: 10px;
  }
  
  .directory-filter-tabs {
    width: 100%;
    display: flex;
  }
  
  .filter-tab {
    flex: 1;
    text-align: center;
    padding: 8px 6px;
    font-size: 11px;
  }
  
  .cards-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }
  
  /* Show card layouts on phone */
  .show-card {
    padding: 14px;
    gap: 10px;
  }
  
  .show-card-header {
    flex-direction: column !important;
    gap: 12px !important;
    align-items: center !important;
    text-align: center;
    position: relative;
    padding-top: 12px;
  }
  
  .show-card-poster {
    width: 90px;
    height: 135px;
    margin: 0 auto;
    border-radius: var(--radius-md);
  }
  
  .show-title-wrapper {
    width: 100%;
    align-items: center;
  }
  
  .show-title {
    font-size: 16px;
    text-align: center;
    margin: 0 auto;
  }
  
  .show-theatre {
    justify-content: center;
    font-size: 11px;
    text-align: center;
    margin-top: 2px;
  }
  
  .show-score-badge-container {
    justify-content: center;
    margin-top: 4px;
  }
  
  .btn-watchlist-toggle {
    position: absolute !important;
    top: -6px !important;
    right: -4px !important;
    padding: 6px;
    background: hsla(0, 0%, 100%, 0.05);
    border-radius: 50%;
    border: 1px solid var(--border-glass);
    color: var(--text-muted);
  }
  
  body.light-mode .btn-watchlist-toggle {
    background: hsla(0, 0%, 0%, 0.03);
  }
  
  .policy-badges-row {
    justify-content: center;
    gap: 4px;
  }
  
  .badge {
    padding: 3px 6px;
    font-size: 8px;
  }
  
  .rules-accordion-trigger {
    padding: 8px;
    background: hsla(0, 0%, 100%, 0.02);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-sm);
    justify-content: space-between;
  }
  
  body.light-mode .rules-accordion-trigger {
    background: hsla(0, 0%, 0%, 0.01);
  }
  
  .rules-accordion-content {
    gap: 6px;
  }
  
  .policy-detail-block {
    padding: 8px;
  }
  
  .btn-apply-lottery {
    padding: 9px 12px;
    font-size: 11px;
    border-radius: var(--radius-sm);
  }
}

