/* VCE Physics Practice - Core CSS Styles */

.physics-practice {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
}

/* Problem Display */
.problem-text {
    font-size: 16px;
    padding: 20px;
    background: #f8f9fa;
    border-left: 4px solid #007bff;
    margin-bottom: 20px;
    border-radius: 4px;
}

.loading-spinner {
    text-align: center;
    color: #6c757d;
    font-size: 18px;
    padding: 40px;
}

/* Physics Diagrams */
.physics-diagram-container {
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    padding: 20px;
    text-align: center;
    min-height: 300px;
    margin: 20px 0;
    position: relative;
}

.diagram-title {
    font-weight: 600;
    color: #495057;
    margin-bottom: 15px;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

#physics-diagram svg {
    max-width: 100%;
    height: auto;
}

/* Wave Animation Styles */
.wave-animation {
    stroke-width: 2;
    fill: none;
}

.wave-path {
    stroke: #007bff;
    stroke-width: 3;
}

.wave-peak {
    stroke: #dc3545;
    stroke-width: 2;
    stroke-dasharray: 5,5;
}

.wave-labels {
    font-family: 'KaTeX_Main', serif;
    font-size: 14px;
    fill: #495057;
}

/* Answer Interface */
.answer-input-group {
    margin-bottom: 20px;
}

.answer-input-group input {
    font-size: 16px;
    padding: 12px;
    margin-bottom: 15px;
}

.answer-buttons {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.answer-buttons .btn {
    padding: 8px 16px;
    font-weight: 500;
}

/* Feedback Styles */
.feedback-container {
    margin-top: 15px;
    padding: 15px;
    border-radius: 4px;
    display: none;
}

.feedback-correct {
    background: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
}

.feedback-incorrect {
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
}

.feedback-hint {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    color: #856404;
}

/* Formula Sheet */
.formula-container, .constants-container {
    font-size: 14px;
}

.formula-item, .constant-item {
    background: #f8f9fa;
    padding: 12px;
    margin: 8px 0;
    border-left: 3px solid #007bff;
    border-radius: 4px;
}

.formula-expression {
    font-family: 'KaTeX_Main', serif;
    font-size: 16px;
    color: #007bff;
    font-weight: 600;
    margin-bottom: 5px;
}

.formula-description {
    color: #6c757d;
    font-size: 13px;
    margin-bottom: 5px;
}

.formula-variables {
    font-size: 12px;
    color: #495057;
}

.formula-variables li {
    margin: 2px 0;
}

/* Solution Panel */
.solution-panel {
    margin-top: 20px;
}

.solution-content {
    font-size: 15px;
    line-height: 1.8;
}

.solution-step {
    background: #f8f9fa;
    padding: 15px;
    margin: 10px 0;
    border-left: 4px solid #28a745;
    border-radius: 4px;
}

.solution-step-number {
    font-weight: bold;
    color: #28a745;
    margin-right: 10px;
}

.solution-calculation {
    font-family: 'KaTeX_Main', serif;
    background: white;
    padding: 10px;
    border: 1px solid #e9ecef;
    border-radius: 4px;
    margin: 8px 0;
    font-size: 16px;
}

/* Remember Panel */
.remember-panel {
    margin-top: 30px;
    border-top: 3px solid #ffc107;
}

.physics-concepts {
    list-style: none;
    padding-left: 0;
}

.physics-concepts li {
    padding: 8px 0;
    border-bottom: 1px solid #e9ecef;
}

.physics-concepts li:last-child {
    border-bottom: none;
}

.physics-concepts strong {
    color: #007bff;
}

.remember-visual {
    background: #e7f3ff;
    padding: 15px;
    border-radius: 4px;
    margin-top: 15px;
    border-left: 4px solid #007bff;
}

/* Physics Graph Container */
.physics-graph-container {
    background: white;
    border: 1px solid #e9ecef;
    border-radius: 4px;
    padding: 20px;
    margin: 20px 0;
    text-align: center;
    min-height: 200px;
}

/* EM Spectrum Styles */
.spectrum-band {
    cursor: pointer;
    transition: opacity 0.3s;
}

.spectrum-band:hover {
    opacity: 0.8;
}

.spectrum-label {
    font-family: 'Segoe UI', sans-serif;
    font-size: 12px;
    fill: #495057;
}

/* Snell's Law Diagram Styles */
.refraction-ray {
    stroke-width: 2;
    marker-end: url(#arrowhead);
}

.incident-ray {
    stroke: #dc3545;
}

.refracted-ray {
    stroke: #007bff;
}

.normal-line {
    stroke: #6c757d;
    stroke-dasharray: 5,5;
    stroke-width: 1;
}

.medium-boundary {
    stroke: #343a40;
    stroke-width: 3;
}

.angle-arc {
    fill: none;
    stroke: #28a745;
    stroke-width: 1.5;
}

.angle-label {
    font-family: 'KaTeX_Main', serif;
    font-size: 14px;
    fill: #28a745;
}

/* Media Labels */
.medium-label {
    font-family: 'Segoe UI', sans-serif;
    font-size: 14px;
    font-weight: 600;
    fill: #495057;
}

/* Animation Controls */
.animation-controls {
    margin: 15px 0;
    text-align: center;
}

.animation-controls button {
    margin: 0 5px;
    padding: 5px 15px;
    background: #007bff;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

.animation-controls button:hover {
    background: #0056b3;
}

/* Responsive Design */
@media (max-width: 768px) {
    .answer-buttons {
        flex-direction: column;
    }

    .answer-buttons .btn {
        margin-bottom: 10px;
    }

    .physics-diagram-container {
        padding: 15px;
        min-height: 250px;
    }

    .formula-container, .constants-container {
        font-size: 13px;
    }
}

/* KaTeX Math Rendering */
.katex {
    font-size: 1.1em;
}

.katex-display {
    margin: 15px 0;
}

/* Loading States */
.loading-content {
    opacity: 0.6;
    pointer-events: none;
}

.fade-in {
    animation: fadeIn 0.5s ease-in;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Skill Navigation */
.skill-navigation {
    text-align: center;
    margin: 20px 0;
}

.skill-navigation .btn {
    margin: 0 5px;
}

/* Progress Indicator */
.skill-progress {
    background: #e9ecef;
    height: 4px;
    border-radius: 2px;
    margin: 20px 0;
}

.skill-progress-bar {
    background: linear-gradient(90deg, #28a745, #007bff);
    height: 100%;
    border-radius: 2px;
    transition: width 0.3s ease;
}

/* Score Display */
.score-display {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 15px;
    border-radius: 8px;
    text-align: center;
    margin: 20px 0;
}

.score-number {
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 5px;
}

.score-label {
    font-size: 14px;
    opacity: 0.9;
}