/* Transposing Instruments Quiz - Custom Styles */

/* ============================================
   FLASHCARD CUSTOM STYLES
   ============================================ */

.transposing-app .flashcard {
    height: 260px;
}

.transposing-app .flashcard-front {
    gap: 12px;
}

.transposing-app .question-text {
    font-size: 18px;
    font-weight: 500;
    color: var(--text);
    line-height: 1.5;
    margin-bottom: 8px;
}

.transposing-app .highlight {
    font-weight: 800;
}

.transposing-app .instrument-name {
    color: var(--primary);
    font-size: 22px;
}

/* Concert Pitch Display */
.concert-pitch-display {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.concert-label {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-light);
    font-weight: 700;
}

.concert-note {
    font-size: 56px;
    font-weight: 900;
    color: var(--text);
    line-height: 1;
}

/* Answer Reveal on Back */
.answer-reveal {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.answer-label {
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #065f46;
    font-weight: 700;
}

.answer-note {
    font-size: 64px;
    font-weight: 900;
    color: #10b981;
}

/* ============================================
   ANSWER GRID - Matches music-notation-app.css
   ============================================ */

.transposing-app .answer-container {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    align-items: center;
}

.transposing-app .answer-row {
    display: flex;
    align-items: center;
    gap: 6px;
}

.transposing-app .row-label {
    font-size: 16px;
    font-weight: 700;
    min-width: 24px;
}

.transposing-app .pill {
    padding: 12px 18px;
    font-size: 16px;
    font-weight: 700;
    border-radius: 28px;
    border: 2px solid;
    cursor: pointer;
    transition: all 0.15s;
    min-width: 62px;
    text-align: center;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
    background: var(--card);
}

.transposing-app .pill:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.transposing-app .pill:active:not(:disabled) {
    transform: scale(0.96);
}

.transposing-app .pill:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Row colors - matches music-notation-app.css */
/* C row - Blue */
.transposing-app .answer-row:nth-child(1) .pill {
    border-color: #60a5fa;
    color: #2563eb;
}
.transposing-app .answer-row:nth-child(1) .pill:hover:not(:disabled) {
    background: #dbeafe;
}
.transposing-app .answer-row:nth-child(1) .row-label { color: #3b82f6; }

/* D row - Gray */
.transposing-app .answer-row:nth-child(2) .pill {
    border-color: #9ca3af;
    color: #4b5563;
}
.transposing-app .answer-row:nth-child(2) .pill:hover:not(:disabled) {
    background: #f3f4f6;
}
.transposing-app .answer-row:nth-child(2) .row-label { color: #6b7280; }

/* E row - Green */
.transposing-app .answer-row:nth-child(3) .pill {
    border-color: #34d399;
    color: #059669;
}
.transposing-app .answer-row:nth-child(3) .pill:hover:not(:disabled) {
    background: #d1fae5;
}
.transposing-app .answer-row:nth-child(3) .row-label { color: #10b981; }

/* F row - Red */
.transposing-app .answer-row:nth-child(4) .pill {
    border-color: #f87171;
    color: #dc2626;
}
.transposing-app .answer-row:nth-child(4) .pill:hover:not(:disabled) {
    background: #fee2e2;
}
.transposing-app .answer-row:nth-child(4) .row-label { color: #ef4444; }

/* G row - Yellow/Orange */
.transposing-app .answer-row:nth-child(5) .pill {
    border-color: #fbbf24;
    color: #d97706;
}
.transposing-app .answer-row:nth-child(5) .pill:hover:not(:disabled) {
    background: #fef3c7;
}
.transposing-app .answer-row:nth-child(5) .row-label { color: #f59e0b; }

/* A row - Dark Gray */
.transposing-app .answer-row:nth-child(6) .pill {
    border-color: #6b7280;
    color: #374151;
}
.transposing-app .answer-row:nth-child(6) .pill:hover:not(:disabled) {
    background: #f3f4f6;
}
.transposing-app .answer-row:nth-child(6) .row-label { color: #4b5563; }

/* B row - Teal */
.transposing-app .answer-row:nth-child(7) .pill {
    border-color: #2dd4bf;
    color: #0d9488;
}
.transposing-app .answer-row:nth-child(7) .pill:hover:not(:disabled) {
    background: #ccfbf1;
}
.transposing-app .answer-row:nth-child(7) .row-label { color: #14b8a6; }

/* Dark mode adjustments for pills */
body.dark-mode .transposing-app .pill {
    background: var(--bg);
}

body.dark-mode .transposing-app .pill:hover:not(:disabled) {
    background: var(--card);
}

/* ============================================
   TRANSPOSITION CHART
   ============================================ */

.chart-section {
    background: var(--card);
    border-radius: 16px;
    padding: 24px;
    margin-top: 24px;
    box-shadow: var(--shadow);
    border: 1px solid var(--border);
}

.chart-title {
    font-size: 24px;
    font-weight: 800;
    color: var(--text);
    text-align: center;
    margin-bottom: 4px;
}

.chart-subtitle {
    font-size: 14px;
    color: var(--text-light);
    text-align: center;
    margin-bottom: 20px;
}

.chart-container {
    overflow-x: auto;
    margin-bottom: 20px;
}

.transposition-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}

.transposition-table th {
    background: var(--bg);
    padding: 12px 16px;
    text-align: left;
    font-weight: 700;
    color: var(--text);
    border-bottom: 2px solid var(--border);
    white-space: nowrap;
}

.transposition-table td {
    padding: 12px 16px;
    border-bottom: 1px solid var(--border);
    color: var(--text);
}

.transposition-table tbody tr:hover {
    background: rgba(20, 184, 166, 0.05);
}

.instrument-name-cell {
    font-weight: 600;
}

.sounds-as {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 700;
    color: var(--primary);
}

/* Key Badges */
.key-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 700;
}

.key-badge.bb {
    background: rgba(59, 130, 246, 0.15);
    color: #3b82f6;
}

.key-badge.eb {
    background: rgba(139, 92, 246, 0.15);
    color: #8b5cf6;
}

.key-badge.f {
    background: rgba(234, 179, 8, 0.15);
    color: #ca8a04;
}

.key-badge.g {
    background: rgba(16, 185, 129, 0.15);
    color: #10b981;
}

.key-badge.a {
    background: rgba(239, 68, 68, 0.15);
    color: #ef4444;
}

/* Chart Tip */
.chart-tip {
    display: flex;
    gap: 12px;
    padding: 16px;
    background: linear-gradient(135deg, rgba(20, 184, 166, 0.08), rgba(8, 145, 178, 0.08));
    border-radius: 10px;
    border-left: 4px solid var(--primary);
}

.tip-icon {
    font-size: 20px;
    flex-shrink: 0;
}

.tip-content {
    font-size: 14px;
    color: var(--text);
    line-height: 1.6;
}

.tip-content strong {
    color: var(--primary);
}

/* ============================================
   DARK MODE OVERRIDES
   ============================================ */

body.dark-mode .key-badge.bb {
    background: rgba(59, 130, 246, 0.25);
}

body.dark-mode .key-badge.eb {
    background: rgba(139, 92, 246, 0.25);
}

body.dark-mode .key-badge.f {
    background: rgba(234, 179, 8, 0.25);
}

body.dark-mode .key-badge.g {
    background: rgba(16, 185, 129, 0.25);
}

body.dark-mode .key-badge.a {
    background: rgba(239, 68, 68, 0.25);
}

body.dark-mode .transposition-table th {
    background: var(--card);
}

body.dark-mode .transposition-table tbody tr:hover {
    background: rgba(94, 234, 212, 0.08);
}

body.dark-mode .answer-label {
    color: #6ee7b7;
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 600px) {
    .transposing-app .flashcard {
        height: 240px;
    }

    .transposing-app .question-text {
        font-size: 15px;
    }

    .transposing-app .instrument-name {
        font-size: 18px;
    }

    .concert-note {
        font-size: 44px;
    }

    .answer-note {
        font-size: 52px;
    }

    .transposing-app .pill {
        padding: 10px 14px;
        font-size: 14px;
        min-width: 52px;
    }

    .transposing-app .row-label {
        min-width: 20px;
        font-size: 14px;
    }

    .chart-section {
        padding: 16px;
    }

    .chart-title {
        font-size: 20px;
    }

    .transposition-table {
        font-size: 12px;
    }

    .transposition-table th,
    .transposition-table td {
        padding: 8px 10px;
    }

    .chart-tip {
        padding: 12px;
    }

    .tip-content {
        font-size: 13px;
    }
}

@media (max-width: 400px) {
    .transposing-app .answer-row {
        gap: 4px;
    }

    .transposing-app .pill {
        padding: 8px 10px;
        min-width: 44px;
        font-size: 13px;
    }

    .transposing-app .row-label {
        min-width: 18px;
        font-size: 12px;
    }
}
