/*
 * This is a manifest file that'll be compiled into application.css.
 *
 * With Propshaft, assets are served efficiently without preprocessing steps. You can still include
 * application-wide styles in this file, but keep in mind that CSS precedence will follow the standard
 * cascading order, meaning styles declared later in the document or manifest will override earlier ones,
 * depending on specificity.
 *
 * Consider organizing styles into separate files for maintainability.
 */

/* === DARK MODE PREMIUM THEME === */
:root {
  --bg-dark: #0a0e27;
  --bg-darker: #060918;
  --bg-card: #141829;
  --text-primary: #e8eaed;
  --text-secondary: #9aa0a6;
  --accent-blue: #4d94ff;
  --accent-blue: #34d399;
  --accent-red: #ef4444;
  --border-color: #1f2937;
  --shadow: rgba(0, 0, 0, 0.5);
}

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

body {
  background: var(--bg-dark);
  color: var(--text-primary);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  line-height: 1.6;
  min-height: 100vh;
}

/* === CUE RUNNER LAYOUT === */
.cue-runner {
  max-width: 1000px;
  margin: 0 auto;
  padding: 2rem;
}

/* === HEADER & TIMER === */
.cue-header {
  background: var(--bg-card);
  border-radius: 12px;
  padding: 2rem;
  margin-bottom: 2rem;
  box-shadow: 0 4px 20px var(--shadow);
  border: 1px solid var(--border-color);
}

.timer-section {
  text-align: center;
}

.session-title {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
  color: var(--text-primary);
}

.attendees-section {
  margin: 1.5rem 0;
}

.attendees-section h3 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 0.75rem;
  text-align: center;
}

.attendee-seats {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

.attendee-input {
  flex: 1;
  min-width: 150px;
  max-width: 200px;
  padding: 0.75rem;
  background: var(--bg-darker);
  border: 2px solid var(--border-color);
  border-radius: 8px;
  color: var(--text-primary);
  font-size: 0.95rem;
  text-align: center;
  transition: all 0.3s ease;
}

.attendee-input:focus {
  outline: none;
  border-color: var(--accent-blue);
  box-shadow: 0 0 0 3px rgba(77, 148, 255, 0.2);
}

.attendee-input::placeholder {
  color: var(--text-secondary);
  opacity: 0.6;
}

.timer-display {
  font-size: 4.5rem;
  font-weight: 700;
  color: var(--accent-blue);
  font-variant-numeric: tabular-nums;
  margin-bottom: 1.5rem;
  letter-spacing: 0.05em;
  text-shadow: 0 0 30px rgba(77, 148, 255, 0.3);
}

.timer-display.overtime {
  color: var(--accent-red);
  text-shadow: 0 0 30px rgba(239, 68, 68, 0.3);
}

.timer-controls {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* === BUTTONS === */
.btn-primary, .btn-secondary, .btn-link {
  padding: 0.75rem 2rem;
  border: none;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  text-decoration: none;
  display: inline-block;
  text-align: center;
}

.btn-primary {
  background: var(--accent-blue);
  color: white;
}

.btn-primary:hover {
  background: #3a7be0;
  transform: translateY(-2px);
  box-shadow: 0 4px 20px rgba(77, 148, 255, 0.4);
}

.btn-secondary {
  background: var(--bg-darker);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
}

.btn-secondary:hover {
  background: var(--bg-card);
  border-color: var(--accent-blue);
}

.btn-link {
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid var(--border-color);
}

.btn-link:hover {
  color: var(--accent-blue);
  border-color: var(--accent-blue);
}

/* === INSTRUCTIONS === */
.instructions {
  background: var(--bg-card);
  border-radius: 8px;
  padding: 1.5rem;
  margin-bottom: 2rem;
  border-left: 4px solid var(--accent-blue);
  border: 1px solid var(--border-color);
  border-left: 4px solid var(--accent-blue);
}

.instructions p {
  margin: 0.5rem 0;
  color: var(--text-secondary);
}

.instructions kbd {
  background: var(--bg-darker);
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  border: 1px solid var(--border-color);
  font-family: 'Monaco', 'Courier New', monospace;
  font-size: 0.9em;
  color: var(--accent-blue);
}

.subtitle {
  font-size: 1.1rem;
  color: var(--text-primary);
}

/* === CUE STEPS === */
.cue-steps-container {
  background: var(--bg-card);
  border-radius: 12px;
  padding: 2rem;
  margin-bottom: 2rem;
  box-shadow: 0 4px 20px var(--shadow);
  border: 1px solid var(--border-color);
  max-height: 60vh;
  overflow-y: auto;
}

.cue-section-header {
  padding: 1.5rem;
  margin-bottom: 1rem;
  background: rgba(77, 148, 255, 0.15);
  border-left: 4px solid var(--accent-blue);
  border-radius: 8px;
}

.cue-section-header .step-text h3 {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--accent-blue);
  margin-bottom: 0.5rem;
  line-height: 1.4;
}

.cue-section-header .step-text span {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.6;
  display: block;
}

.cue-step {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1.5rem;
  border-radius: 8px;
  margin-bottom: 0.75rem;
  transition: all 0.3s ease;
  background: var(--bg-darker);
  border: 2px solid transparent;
}

.cue-step:hover {
  background: var(--bg-card);
}

.cue-step.active {
  background: rgba(77, 148, 255, 0.1);
  border-color: var(--accent-blue);
  box-shadow: 0 0 20px rgba(77, 148, 255, 0.2);
}

.step-checkbox {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  margin-top: 2px;
}

.checkbox {
  display: block;
  width: 28px;
  height: 28px;
  border: 2px solid var(--border-color);
  border-radius: 6px;
  background: var(--bg-darker);
  position: relative;
  transition: all 0.3s ease;
}

.checkbox.checked {
  background: var(--accent-blue);
  border-color: var(--accent-blue);
}

.checkbox.checked::after {
  content: '✓';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: white;
  font-size: 18px;
  font-weight: bold;
}

.checkbox.failed {
  background: var(--accent-red);
  border-color: var(--accent-red);
}

.checkbox.failed::after {
  content: '✗';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: white;
  font-size: 18px;
  font-weight: bold;
}

.checkbox.skipped {
  background: var(--accent-red);
  border-color: var(--accent-red);
}

.checkbox.skipped::after {
  content: '✗';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: white;
  font-size: 18px;
  font-weight: bold;
}

.step-content {
  flex: 1;
}

.step-text {
  font-size: 1.25rem;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
}

.step-text h3 {
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.3rem;
  line-height: 1.4;
}

.step-text span {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.5;
  display: block;
}

.cue-step.active .step-text h3 {
  color: var(--accent-blue);
}

.step-duration {
  font-size: 0.9rem;
  color: var(--text-secondary);
  font-style: italic;
}

/* === NAVIGATION === */
.nav-buttons {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* === SCROLLBAR === */
.cue-steps-container::-webkit-scrollbar {
  width: 8px;
}

.cue-steps-container::-webkit-scrollbar-track {
  background: var(--bg-darker);
  border-radius: 4px;
}

.cue-steps-container::-webkit-scrollbar-thumb {
  background: var(--border-color);
  border-radius: 4px;
}

.cue-steps-container::-webkit-scrollbar-thumb:hover {
  background: var(--accent-blue);
}

/* === RESPONSIVE === */
@media (max-width: 768px) {
  .cue-runner {
    padding: 1rem;
  }

  .timer-display {
    font-size: 3rem;
  }

  .session-title {
    font-size: 1.5rem;
  }

  .step-text {
    font-size: 1.1rem;
  }
}

/* === INDEX PAGE === */
.cue-sheets-index {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem;
}

.notice-message {
  background: rgba(52, 211, 153, 0.1);
  border: 1px solid rgba(52, 211, 153, 0.5);
  border-radius: 8px;
  padding: 1rem;
  margin-bottom: 2rem;
  color: #34d399;
  text-align: center;
}

.welcome-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 2px solid var(--border-color);
  flex-wrap: wrap;
  gap: 1rem;
}

.welcome-header h1 {
  color: var(--text-primary);
  margin: 0;
  font-size: 2rem;
}

.header-actions {
  display: flex;
  gap: 1rem;
  align-items: center;
}

.cue-sheets-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}

.cue-sheet-card {
  background: var(--bg-card);
  border-radius: 12px;
  padding: 2rem;
  border: 1px solid var(--border-color);
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.cue-sheet-card:hover {
  border-color: var(--accent-blue);
  box-shadow: 0 4px 20px rgba(77, 148, 255, 0.2);
  transform: translateY(-2px);
}

.btn-start {
  width: 100%;
  margin-top: auto;
}

@media (max-width: 768px) {
  .welcome-header {
    flex-direction: column;
    align-items: flex-start;
  }
  
  .header-actions {
    width: 100%;
    justify-content: flex-start;
  }
  
  .cue-sheets-grid {
    grid-template-columns: 1fr;
  }
}

.btn-logout {
  margin-top: 0;
  padding: 0.75rem 2rem;
  border: none;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  background: var(--accent-red);
  color: white;
}

.btn-logout:hover {
  background: #dc2626;
  transform: translateY(-2px);
  box-shadow: 0 4px 20px rgba(239, 68, 68, 0.4);
}


/* === SELF AUDIT CONTAINER === */
.self-audit-container {
  background: var(--bg-card);
  border-radius: 12px;
  padding: 2rem;
  margin: 2rem 0;
  box-shadow: 0 4px 20px var(--shadow);
  border: 1px solid var(--border-color);
}

.self-audit-container .cue-section-header {
  margin-bottom: 1rem;
}

.self-audit-container .cue-step {
  margin-bottom: 0.75rem;
}

@media (max-width: 768px) {
  .self-audit-container {
    padding: 1.5rem;
  }
}

.self-audit-container .audit-title {
  text-align: center;
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 2px solid var(--border-color);
}

.self-audit-container .audit-title h2 {
  font-size: 1.8rem;
  color: var(--accent-blue);
  margin-bottom: 0.5rem;
}

.self-audit-container .audit-title p {
  color: var(--text-secondary);
  font-size: 0.95rem;
}

/* === PRE-CLASS SETUP === */
.pre-class-setup {
  background: rgba(255, 193, 7, 0.1);
  border: 2px solid rgba(255, 193, 7, 0.5);
  border-radius: 12px;
  padding: 1.5rem;
  margin-bottom: 2rem;
}

.setup-header h3 {
  color: #ffc107;
  font-size: 1.2rem;
  margin-bottom: 1rem;
}

.setup-content h4 {
  color: var(--text-primary);
  font-size: 1rem;
  margin-bottom: 0.5rem;
  margin-top: 0;
}

.setup-content p {
  color: var(--text-secondary);
  margin: 0.5rem 0;
  line-height: 1.6;
}

.setup-content .point {
  color: #ffc107;
  font-weight: 600;
  margin-top: 1rem;
}

.self-audit-container .exception-section {
  margin-top: 1rem;
  padding-left: 1rem;
  border-left: 3px solid var(--accent-red);
}

.self-audit-container .exception-section h4 {
  color: var(--accent-red);
  font-size: 1rem;
  margin-bottom: 0.75rem;
  font-weight: 600;
}

.self-audit-container .exception-section .cue-step {
  margin-bottom: 0.5rem;
}

.self-audit-container .final-score {
  background: rgba(77, 148, 255, 0.15);
  border: 2px solid var(--accent-blue);
  border-radius: 8px;
  padding: 1.5rem;
  margin-top: 1.5rem;
  text-align: center;
}

.self-audit-container .final-score h3 {
  color: var(--accent-blue);
  font-size: 1.3rem;
  margin: 0;
}

.self-audit-container .final-score .score-input {
  display: inline-block;
  margin-left: 0.5rem;
}

.self-audit-container .final-score .score-number {
  width: 60px;
  padding: 0.3rem;
  font-size: 1.3rem;
  text-align: center;
  background: var(--bg-card);
  border: 2px solid var(--accent-blue);
  border-radius: 4px;
  color: var(--accent-blue);
  font-weight: bold;
  cursor: default;
}

.self-audit-container .final-score .score-number:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(77, 148, 255, 0.3);
}

.cue-steps-container .container-title {
  text-align: center;
  padding-bottom: 1.5rem;
  margin-bottom: 1.5rem;
  border-bottom: 2px solid var(--border-color);
}

.cue-steps-container .container-title h2 {
  font-size: 1.8rem;
  color: var(--accent-blue);
  margin: 0;
}

/* === HEIGHT RATIO: Cue Steps 6 : Self Audit 4 === */
.cue-steps-container {
  max-height: 60vh;
}

.self-audit-container {
  max-height: 40vh;
  overflow-y: auto;
}

.self-audit-container::-webkit-scrollbar {
  width: 8px;
}

.self-audit-container::-webkit-scrollbar-track {
  background: var(--bg-darker);
  border-radius: 4px;
}

.self-audit-container::-webkit-scrollbar-thumb {
  background: var(--border-color);
  border-radius: 4px;
}

.self-audit-container::-webkit-scrollbar-thumb:hover {
  background: var(--accent-blue);
}
