/* ==============================================
   Academy Interactive Components
   Shared styles for sliders, toggles, timelines,
   score rings, and calculators.
   ============================================== */

/* ── Slider ── */
.academy-slider {
    -webkit-appearance: none;
    appearance: none;
    flex: 1;
    height: 6px;
    border-radius: 99px;
    background: rgba(255, 255, 255, 0.08);
    outline: none;
    cursor: pointer;
}

.academy-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #A0CBFF;
    border: none;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(160, 203, 255, 0.3);
}

.academy-slider::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #A0CBFF;
    border: none;
    cursor: pointer;
}

/* ── Toggle Bar ── */
.academy-toggle-wrap {
    display: flex;
    gap: 0;
    margin-bottom: 1.5rem;
    background: rgba(255, 255, 255, 0.04);
    border-radius: 12px;
    padding: 4px;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.academy-toggle-btn {
    flex: 1;
    padding: 0.75rem 1rem;
    border: none;
    background: none;
    color: rgba(255, 255, 255, 0.5);
    font-family: inherit;
    font-size: 0.875rem;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.25s;
}

.academy-toggle-btn.active {
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
}

/* ── Score Ring ── */
.academy-ring-wrap {
    position: relative;
    width: 80px;
    height: 80px;
    flex-shrink: 0;
}

.academy-ring-bg,
.academy-ring-fill {
    fill: none;
    stroke-width: 5;
}

.academy-ring-bg {
    stroke: rgba(255, 255, 255, 0.08);
}

.academy-ring-fill {
    stroke: #A0CBFF;
    stroke-linecap: round;
    transition: stroke-dashoffset 0.5s ease, stroke 0.5s;
}

.academy-score-num {
    font-size: 1.25rem;
    font-weight: 800;
    color: #fff;
    font-variant-numeric: tabular-nums;
    line-height: 1;
}

.academy-score-max {
    font-size: 0.65rem;
    color: rgba(255, 255, 255, 0.4);
    margin-top: 2px;
}

/* ── Timeline ── */
.academy-timeline {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.academy-time-block {
    display: flex;
    gap: 1rem;
    padding: 0.875rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.academy-time-block:last-child {
    border-bottom: none;
}

.academy-time-label {
    min-width: 52px;
    font-size: 0.8rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.35);
    font-variant-numeric: tabular-nums;
}

.academy-time-content {
    flex: 1;
}

.academy-time-task {
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.8);
    font-weight: 500;
}

.academy-time-note {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.35);
    margin-top: 2px;
}

.academy-time-mood {
    display: inline-block;
    font-size: 0.65rem;
    padding: 2px 8px;
    border-radius: 99px;
    font-weight: 600;
    margin-left: 8px;
}

.academy-mood-great {
    background: rgba(34, 197, 94, 0.1);
    color: rgba(34, 197, 94, 0.7);
}

.academy-mood-tough {
    background: rgba(239, 68, 68, 0.1);
    color: rgba(239, 68, 68, 0.7);
}

.academy-mood-ok {
    background: rgba(255, 255, 255, 0.06);
    color: rgba(255, 255, 255, 0.4);
}

/* ── Interactive Card ── */
.academy-interactive-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 1.25rem 1.5rem;
    margin-bottom: 0.75rem;
    transition: border-color 0.2s;
}

.academy-interactive-card:hover {
    border-color: rgba(255, 255, 255, 0.15);
}

/* ── Result Card (sticky score) ── */
.academy-result-card {
    position: sticky;
    top: 80px;
    z-index: 50;
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.97), rgba(15, 23, 42, 0.95));
    backdrop-filter: blur(16px);
    border: 1px solid rgba(160, 203, 255, 0.15);
    border-radius: 16px;
    padding: 1.25rem 1.5rem;
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.academy-result-card .score-wrap {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.academy-result-card .verdict {
    flex: 1;
    min-width: 200px;
}

.academy-result-card .verdict-text {
    font-size: 0.95rem;
    font-weight: 600;
    color: #fff;
    margin-bottom: 0.25rem;
}

.academy-result-card .verdict-sub {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.5);
    line-height: 1.4;
}

/* ── Trait Card ── */
.academy-trait-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.75rem;
}

.academy-trait-name {
    font-size: 0.95rem;
    font-weight: 600;
    color: #fff;
}

.academy-trait-val {
    font-size: 1.125rem;
    font-weight: 800;
    color: #A0CBFF;
    font-variant-numeric: tabular-nums;
    min-width: 20px;
    text-align: right;
}

.academy-slider-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.academy-slider-label {
    font-size: 0.7rem;
    color: rgba(255, 255, 255, 0.3);
    min-width: 12px;
    text-align: center;
}

.academy-trait-tip {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.4);
    margin-top: 0.625rem;
    line-height: 1.4;
    min-height: 1.4em;
    transition: opacity 0.2s;
}

/* ── Calculator Output ── */
.academy-calc-output {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-top: 1.25rem;
    padding-top: 1.25rem;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.academy-calc-stat {
    text-align: center;
}

.academy-calc-stat-val {
    font-size: 1.5rem;
    font-weight: 800;
    color: #fff;
    font-variant-numeric: tabular-nums;
}

.academy-calc-stat-label {
    font-size: 0.7rem;
    color: rgba(255, 255, 255, 0.4);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-top: 0.25rem;
}

.academy-calc-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
    gap: 1rem;
}

.academy-calc-label {
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.6);
    font-weight: 500;
}

.academy-calc-val {
    font-size: 1.25rem;
    font-weight: 800;
    color: #A0CBFF;
    font-variant-numeric: tabular-nums;
    min-width: 55px;
    text-align: right;
}

/* ── Neutral overrides for template cards ── */
.academy-math-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.academy-math-card .math-icon {
    background: rgba(255, 255, 255, 0.06);
}

.academy-math-card .math-title {
    color: #fff;
}