/**
 * The Spin The Wheel — Page Module: classroom.css
 * Dedicated styling for /classroom-name-picker
 */

/* Privacy Banner */
.privacy-shield-banner {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    background: rgba(16, 185, 129, 0.08);
    border: 1px solid rgba(16, 185, 129, 0.25);
    border-radius: var(--radius-md);
    padding: 0.65rem 1rem;
    margin-bottom: 1.25rem;
    font-size: 0.825rem;
    color: #34d399;
}
.privacy-shield-banner svg { flex-shrink: 0; color: #10b981; }
.privacy-shield-text { line-height: 1.4; flex: 1; }
.privacy-shield-text strong { color: #6ee7b7; }
.ad-safe-badge {
    background: rgba(16, 185, 129, 0.2);
    color: #34d399;
    border: 1px solid rgba(16, 185, 129, 0.4);
    font-size: 0.725rem;
    font-weight: 700;
    padding: 0.25rem 0.6rem;
    border-radius: 9999px;
    white-space: nowrap;
    margin-left: auto;
    flex-shrink: 0;
}

/* Multi-Class Period Tabs */
.class-period-tabs {
    display: flex;
    gap: 0.35rem;
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 0.3rem;
    margin-bottom: 1rem;
    overflow-x: auto;
    scrollbar-width: thin;
}
.period-tab-btn {
    flex: 1;
    min-width: 80px;
    background: transparent;
    border: none;
    color: var(--text-secondary);
    font-size: 0.8rem;
    font-weight: 600;
    padding: 0.5rem 0.75rem;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.15s ease;
    text-align: center;
    white-space: nowrap;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.period-tab-btn:hover { color: var(--text-primary); background: rgba(255, 255, 255, 0.05); }
.period-tab-btn.active {
    background: var(--accent-indigo);
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(99, 102, 241, 0.35);
}
.period-tab-add {
    background: transparent;
    border: 1px dashed var(--border-subtle);
    color: var(--text-muted);
    font-size: 0.85rem;
    font-weight: 700;
    padding: 0.5rem 0.75rem;
    border-radius: var(--radius-sm);
    cursor: pointer;
    min-height: 44px;
    min-width: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s ease;
}
.period-tab-add:hover {
    color: var(--text-primary);
    border-color: var(--accent-indigo);
    background: rgba(99, 102, 241, 0.1);
}

/* Control Groups, Labels & Preset Chips */
.slices-control-group { display: flex; flex-direction: column; gap: 0.5rem; }
.control-label-row { display: flex; align-items: center; justify-content: space-between; }
.control-label {
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
}
.control-hint { font-size: 0.75rem; color: var(--text-secondary); }
.slice-chips-row { display: flex; flex-wrap: wrap; gap: 0.45rem; }
.slice-chip {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    color: var(--text-secondary);
    padding: 0.4rem 0.75rem;
    border-radius: var(--radius-sm);
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    min-height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s ease;
}
.slice-chip:hover {
    color: var(--text-primary);
    border-color: var(--accent-indigo);
    background: rgba(99, 102, 241, 0.08);
}
.slice-chip.active {
    background: var(--accent-indigo);
    color: #ffffff;
    border-color: var(--accent-indigo);
}

/* Instructional Pacing Tempo Selector */
.pacing-pills-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.45rem;
}
.pacing-pill {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-sm);
    padding: 0.5rem 0.35rem;
    text-align: center;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    transition: all 0.15s ease;
    color: var(--text-secondary);
}
.pacing-pill:hover { border-color: var(--accent-indigo); color: var(--text-primary); }
.pacing-pill.active {
    background: rgba(99, 102, 241, 0.15);
    border-color: var(--accent-indigo);
    color: var(--text-primary);
    font-weight: 700;
    box-shadow: 0 0 10px rgba(99, 102, 241, 0.2);
}
.pacing-pill-title { font-size: 0.825rem; font-weight: 700; line-height: 1.2; }
.pacing-pill-sub { font-size: 0.675rem; color: var(--text-muted); margin-top: 0.15rem; }
.pacing-pill.active .pacing-pill-sub { color: #a5b4fc; }

/* Zero-Loss Attendance Matrix */
.attendance-toggle-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.5rem;
}
.roster-view-tabs {
    display: inline-flex;
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-sm);
    padding: 0.2rem;
    gap: 0.25rem;
}
.roster-view-tab {
    background: transparent;
    border: none;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-muted);
    padding: 0.35rem 0.65rem;
    border-radius: var(--radius-sm);
    cursor: pointer;
    min-height: 34px;
    transition: all 0.15s ease;
}
.roster-view-tab:hover { color: var(--text-primary); }
.roster-view-tab.active { background: var(--accent-indigo); color: #ffffff; }

.entries-textarea {
    width: 100%;
    background: var(--bg-input);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    padding: 0.75rem;
    font-size: 0.875rem;
    font-family: inherit;
    line-height: 1.5;
    resize: vertical;
}

.attendance-matrix-box {
    display: none;
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-sm);
    padding: 0.75rem;
    max-height: 220px;
    overflow-y: auto;
    scrollbar-width: thin;
}
.attendance-matrix-box.show { display: block; }
.attendance-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.75rem;
    margin-bottom: 0.65rem;
    padding-bottom: 0.4rem;
    border-bottom: 1px solid var(--border-subtle);
}
.attendance-stats { color: var(--text-secondary); font-weight: 600; }
.attendance-quick-action {
    background: transparent;
    border: none;
    color: var(--accent-indigo);
    cursor: pointer;
    font-size: 0.75rem;
    font-weight: 600;
    text-decoration: underline;
    padding: 0;
}
.attendance-items-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    gap: 0.4rem;
}
.attendance-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.4rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-sm);
    padding: 0.4rem 0.55rem;
    font-size: 0.775rem;
    color: var(--text-primary);
    transition: all 0.15s ease;
}
.attendance-item.absent {
    opacity: 0.5;
    background: rgba(239, 68, 68, 0.06);
    border-color: rgba(239, 68, 68, 0.25);
}
.attendance-item.absent .attendance-item-name {
    text-decoration: line-through;
    color: var(--text-muted);
}
.attendance-item-name {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.attendance-item-toggle {
    background: rgba(16, 185, 129, 0.15);
    color: #34d399;
    border: 1px solid rgba(16, 185, 129, 0.3);
    border-radius: 3px;
    padding: 0.2rem 0.45rem;
    font-size: 0.65rem;
    font-weight: 700;
    cursor: pointer;
    flex-shrink: 0;
    transition: all 0.15s ease;
}
.attendance-item.absent .attendance-item-toggle {
    background: rgba(239, 68, 68, 0.15);
    color: #f87171;
    border-color: rgba(239, 68, 68, 0.3);
}

/* Selection Mode Pills (Fair Turn vs Standard Spin) */
.mode-pills-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
}
.mode-pill {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    color: var(--text-secondary);
    padding: 0.55rem 0.5rem;
    border-radius: var(--radius-sm);
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    text-align: center;
    transition: all 0.15s ease;
    min-height: 48px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.15rem;
}
.mode-pill:hover { border-color: var(--accent-indigo); color: var(--text-primary); }
.mode-pill.active {
    background: rgba(99, 102, 241, 0.15);
    border-color: var(--accent-indigo);
    color: var(--text-primary);
    box-shadow: 0 0 10px rgba(99, 102, 241, 0.2);
}
.mode-pill-sub { font-size: 0.675rem; color: var(--text-muted); font-weight: 400; }
.mode-pill.active .mode-pill-sub { color: #a5b4fc; }

/* Class Turn Tracker Ledger */
.drawn-tray-container {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 0.85rem 1rem;
    margin-top: 1rem;
}
.drawn-tray-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.65rem;
    flex-wrap: wrap;
    gap: 0.5rem;
}
.drawn-tray-title {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.825rem;
    font-weight: 700;
    color: var(--text-primary);
}
.drawn-tray-actions { display: flex; align-items: center; gap: 0.35rem; }
.drawn-tray-btn {
    background: transparent;
    border: 1px solid var(--border-subtle);
    color: var(--text-secondary);
    padding: 0.3rem 0.6rem;
    border-radius: var(--radius-sm);
    font-size: 0.725rem;
    font-weight: 600;
    cursor: pointer;
    min-height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s ease;
}
.drawn-tray-btn:hover {
    color: var(--text-primary);
    border-color: var(--accent-indigo);
    background: rgba(99, 102, 241, 0.1);
}
.drawn-chips-wrap {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    max-height: 140px;
    overflow-y: auto;
}
.drawn-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-subtle);
    padding: 0.25rem 0.5rem;
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    color: var(--text-primary);
}
.drawn-chip-order { font-weight: 700; color: var(--accent-indigo); font-size: 0.7rem; }
.drawn-chip-undo {
    background: transparent;
    border: none;
    color: #cbd5e1;
    cursor: pointer;
    padding: 0 0.15rem;
    font-size: 0.85rem;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    margin-left: 0.2rem;
    transition: all 0.15s ease;
}
.drawn-chip-undo:hover { color: #ef4444; transform: scale(1.2); }
.drawn-chip.passed { opacity: 0.75; border-color: #f59e0b; }
.drawn-chip.buddy { border-color: #38bdf8; }

.classroom-hotkeys-bar {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    font-size: 0.725rem;
    color: var(--text-muted);
    margin-top: 1rem;
    padding: 0.5rem 0.75rem;
    background: rgba(255, 255, 255, 0.02);
    border-radius: var(--radius-sm);
    flex-wrap: wrap;
}
.classroom-hotkeys-bar kbd {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: 3px;
    padding: 0.1rem 0.35rem;
    font-family: monospace;
    font-size: 0.7rem;
    color: var(--text-primary);
}

/* Pedagogical Wait-Time Timer & Trauma-Informed Lifelines (Modal) */
.think-time-box {
    background: rgba(99, 102, 241, 0.08);
    border: 1px solid rgba(99, 102, 241, 0.25);
    border-radius: var(--radius-md);
    padding: 0.85rem 1rem;
    margin: 1rem 0;
    text-align: center;
}
.think-time-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    font-size: 0.825rem;
    font-weight: 700;
    color: #a5b4fc;
    margin-bottom: 0.6rem;
}
.think-time-btns {
    display: flex;
    gap: 0.4rem;
    justify-content: center;
    margin-bottom: 0.5rem;
    flex-wrap: wrap;
}
.think-time-chip {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    color: var(--text-secondary);
    padding: 0.35rem 0.75rem;
    border-radius: var(--radius-sm);
    font-size: 0.775rem;
    font-weight: 600;
    cursor: pointer;
    min-height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s ease;
}
.think-time-chip:hover { color: var(--text-primary); border-color: var(--accent-indigo); }
.think-time-chip.active {
    background: var(--accent-indigo);
    color: #ffffff;
    border-color: var(--accent-indigo);
}
.think-time-bar-wrap {
    height: 6px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
    overflow: hidden;
    margin: 0.6rem 0 0.4rem;
    display: none;
}
.think-time-bar-fill {
    height: 100%;
    width: 100%;
    background: linear-gradient(90deg, #38bdf8, #818cf8);
    transition: width 1s linear;
}
.think-time-countdown-text {
    font-size: 0.85rem;
    font-weight: 700;
    color: #38bdf8;
    display: none;
}

.lifeline-actions-row {
    display: flex;
    gap: 0.45rem;
    justify-content: center;
    margin-top: 0.85rem;
    flex-wrap: wrap;
}
.btn-lifeline {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-subtle);
    color: var(--text-primary);
    font-size: 0.8rem;
    font-weight: 600;
    padding: 0.5rem 0.85rem;
    border-radius: var(--radius-sm);
    cursor: pointer;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    transition: all 0.15s ease;
}
.btn-lifeline:hover { background: rgba(255, 255, 255, 0.1); border-color: var(--accent-indigo); }
.buddy-announcement {
    background: rgba(56, 189, 248, 0.12);
    border: 1px solid rgba(56, 189, 248, 0.35);
    color: #38bdf8;
    padding: 0.6rem 0.85rem;
    border-radius: var(--radius-sm);
    font-size: 0.875rem;
    font-weight: 700;
    margin: 0.65rem 0;
    display: none;
}
.modal-btn-group {
    display: flex;
    gap: 0.5rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 1rem;
}

/* Fast Roster Cleaner Tools */
.roster-cleaner-tools {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-bottom: 0.65rem;
}
.cleaner-tool-btn {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    color: var(--text-secondary);
    padding: 0.35rem 0.65rem;
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    min-height: 34px;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    transition: all 0.15s ease;
}
.cleaner-tool-btn:hover {
    color: var(--text-primary);
    border-color: var(--accent-indigo);
    background: rgba(99, 102, 241, 0.1);
}

/* ==========================================================================
   Zen Smartboard Theater View (Promethean / SMART Board Projector Mode)
   ========================================================================== */
body.zen-smartboard-active {
    overflow: hidden;
}

body.zen-smartboard-active .wheel-stage-card {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 9999;
    border-radius: 0;
    border: none;
    background: radial-gradient(circle at center, #111827 0%, #060911 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 1rem 1rem 5.5rem;
}

body.zen-smartboard-active .wheel-canvas-container {
    max-width: min(74vh, 85vw, 680px);
    aspect-ratio: 1 / 1;
}

body.zen-smartboard-active .center-spin-btn {
    width: 105px;
    height: 105px;
    font-size: 1.35rem;
    box-shadow: 0 0 35px rgba(99, 102, 241, 0.6), 0 4px 25px rgba(0, 0, 0, 0.8);
}

.zen-theater-bar {
    display: none;
    position: fixed;
    bottom: 1.5rem;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(15, 23, 42, 0.92);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(99, 102, 241, 0.4);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.7), 0 0 25px rgba(99, 102, 241, 0.3);
    border-radius: 9999px;
    padding: 0.45rem 1rem;
    z-index: 10000;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    justify-content: center;
}

body.zen-smartboard-active .zen-theater-bar {
    display: flex;
}

body.zen-smartboard-active .wheel-quick-toolbar,
body.zen-smartboard-active .classroom-hotkeys-bar {
    display: none !important;
}

.zen-bar-pill {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid var(--border-subtle);
    color: var(--text-primary);
    font-size: 0.8rem;
    font-weight: 600;
    padding: 0.4rem 0.85rem;
    border-radius: 9999px;
    min-height: 40px;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    cursor: pointer;
    transition: all 0.15s ease;
}

.zen-bar-pill:hover {
    background: rgba(99, 102, 241, 0.25);
    border-color: var(--accent-indigo);
}

.zen-bar-pill.exit-btn {
    background: rgba(239, 68, 68, 0.18);
    color: #fca5a5;
    border-color: rgba(239, 68, 68, 0.4);
}

.zen-bar-pill.exit-btn:hover {
    background: rgba(239, 68, 68, 0.35);
    color: #ffffff;
}

/* Mobile-First Responsive Adjustments */
@media (max-width: 768px) {
    .pacing-pills-grid { grid-template-columns: 1fr; }
    .pacing-pill {
        flex-direction: row;
        justify-content: space-between;
        padding: 0.5rem 0.85rem;
    }
    .pacing-pill-sub { margin-top: 0; }
    .drawn-tray-header { flex-direction: column; align-items: flex-start; }
    .drawn-tray-actions { width: 100%; justify-content: flex-end; }
    .classroom-hotkeys-bar { display: none; }
}
