/* Tablet */
@media (max-width: 1024px) {
    .exam-body {
        grid-template-columns: 1fr;
    }

    .exam-sidebar {
        display: none;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .checkbox-group {
        grid-template-columns: 1fr;
    }

    .score-stats {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Mobile */
@media (max-width: 768px) {
    .container {
        padding: 20px;
    }

    .header h1 {
        font-size: 24px;
    }

    .exam-header {
        flex-direction: column;
        gap: 10px;
    }

    .exam-info {
        flex-wrap: wrap;
        gap: 15px;
        justify-content: space-between;
        width: 100%;
    }

    .exam-content {
        padding: 15px;
    }

    .question-text {
        font-size: 14px;
    }

    .option-item {
        padding: 12px;
    }

    .option-item input[type="radio"] {
        margin-right: 10px;
    }

    .exam-navigation {
        flex-direction: column;
    }

    .btn-nav {
        width: 100%;
    }

    .card h3 {
        font-size: 16px;
    }

    .form-group input,
    .form-group select {
        font-size: 16px; /* Prevent zoom on iOS */
    }

    .results-header h1 {
        font-size: 24px;
    }

    .score-display {
        font-size: 36px;
    }

    .results-actions {
        flex-direction: column;
    }

    .results-actions .btn {
        max-width: 100%;
    }
}

/* Small phones */
@media (max-width: 480px) {
    .container {
        padding: 15px;
    }

    .header h1 {
        font-size: 20px;
    }

    .header p {
        font-size: 14px;
    }

    .card {
        padding: 15px;
    }

    .form-row.full {
        grid-template-columns: 1fr;
    }

    .questions-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .exam-time {
        font-size: 14px;
    }

    .question-number {
        font-size: 12px;
    }

    .question-text {
        font-size: 13px;
    }

    .option-item {
        padding: 10px;
        font-size: 13px;
    }

    .option-item input[type="radio"] {
        width: 16px;
        height: 16px;
        margin: 2px 10px 0 0;
    }

    .modal-content {
        width: 95%;
    }

    .score-stats {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .stat-card {
        padding: 15px;
    }

    .stat-card .number {
        font-size: 24px;
    }

    .questions-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 3px;
    }

    .question-btn {
        font-size: 10px;
    }
}
