/* Aptitude Assessment & Career Prediction Styles */

:root {
    --primary-color: #3B82F6;
    --success-color: #10B981;
    --warning-color: #F59E0B;
    --error-color: #EF4444;
    --light-bg: #F3F4F6;
    --card-bg: #FFFFFF;
    --text-primary: #1F2937;
    --text-secondary: #6B7280;
    --border-color: #E5E7EB;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.1);
}

/* Aptitude Assessment Container */
.assessment-header {
    text-align: center;
    margin-bottom: 2rem;
    padding: 2rem;
    background: linear-gradient(135deg, var(--primary-color), #60A5FA);
    color: white;
    border-radius: 12px;
}

.assessment-header h1 {
    font-size: 2.5rem;
    margin: 0 0 0.5rem 0;
    font-weight: 700;
}

.assessment-header p {
    font-size: 1.1rem;
    margin: 0;
    opacity: 0.95;
}

.assessment-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 2rem;
}

/* Progress Section */
.progress-section {
    margin-bottom: 2rem;
}

.question-counter {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.75rem;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background-color: var(--light-bg);
    border-radius: 4px;
    overflow: hidden;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.05);
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), #60A5FA);
    transition: width 0.3s ease;
    border-radius: 4px;
}

/* Question Card */
.question-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: var(--shadow);
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.question-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.category-label {
    background: linear-gradient(135deg, var(--primary-color), #60A5FA);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
}

.timer {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

#time-remaining {
    font-weight: 600;
    color: var(--error-color);
}

.question-content {
    margin-bottom: 2rem;
}

#question-text {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 1.5rem 0;
    line-height: 1.6;
}

/* MCQ Options */
.options-container {
    display: grid;
    gap: 1rem;
}

.option {
    position: relative;
    margin-bottom: 0.5rem;
}

.option input[type="radio"] {
    position: absolute;
    opacity: 0;
    cursor: pointer;
}

.option label {
    display: flex;
    align-items: center;
    padding: 1.25rem;
    background-color: var(--light-bg);
    border: 2px solid var(--border-color);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1rem;
}

.option label:hover {
    background-color: #E0E7FF;
    border-color: var(--primary-color);
}

.option input[type="radio"]:checked + label {
    background-color: #DBEAFE;
    border-color: var(--primary-color);
    font-weight: 600;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.option-letter {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background-color: white;
    border: 2px solid var(--text-secondary);
    border-radius: 50%;
    margin-right: 1rem;
    font-weight: 700;
    color: var(--text-secondary);
    transition: all 0.3s ease;
}

.option input[type="radio"]:checked + label .option-letter {
    background-color: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

/* Navigation Controls */
.navigation-controls {
    display: flex;
    gap: 1rem;
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
}

.nav-button {
    flex: 1;
    padding: 0.75rem 1.5rem;
    background-color: var(--light-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.nav-button:hover:not(:disabled) {
    background-color: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.nav-button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.submit-button {
    flex: 1;
    padding: 0.75rem 1.5rem;
    background: linear-gradient(135deg, var(--success-color), #059669);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.submit-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 16px rgba(16, 185, 129, 0.3);
}

.submit-button:active {
    transform: translateY(0);
}

/* Error Message Display */
.error-message {
    padding: 1rem;
    margin-bottom: 1rem;
    border-radius: 8px;
    font-weight: 500;
    animation: slideDown 0.3s ease-out;
    display: none;
}

.error-message.error {
    background-color: #FEE2E2;
    color: #991B1B;
    border: 1px solid #FECACA;
}

.error-message.warning {
    background-color: #FEF3C7;
    color: #92400E;
    border: 1px solid #FCD34D;
}

.error-message.success {
    background-color: #DCFCE7;
    color: #166534;
    border: 1px solid #BBFBDC;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Loading Indicator */
.loading-indicator {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    border-radius: 0;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.loading-indicator p {
    color: white;
    margin-top: 1rem;
    font-size: 1.1rem;
}

/* Career Results Styles */
.results-header {
    text-align: center;
    margin-bottom: 2rem;
    padding: 2rem;
    background: linear-gradient(135deg, var(--success-color), #059669);
    color: white;
    border-radius: 12px;
}

.results-header h1 {
    font-size: 2.5rem;
    margin: 0 0 0.5rem 0;
    font-weight: 700;
}

.results-header p {
    font-size: 1.1rem;
    margin: 0;
    opacity: 0.95;
}

.results-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-bottom: 2rem;
}

.career-card {
    background: var(--card-bg);
    border: 2px solid var(--border-color);
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
}

.career-card:hover {
    border-color: var(--primary-color);
    box-shadow: var(--shadow-lg);
    transform: translateY(-4px);
}

.career-rank {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.career-name {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1rem;
}

.confidence-meter {
    margin-top: auto;
}

.confidence-label {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.meter-bar {
    width: 100%;
    height: 10px;
    background-color: var(--light-bg);
    border-radius: 5px;
    overflow: hidden;
    margin-bottom: 0.5rem;
}

.meter-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--success-color));
    border-radius: 5px;
    transition: width 0.5s ease;
}

.confidence-value {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--primary-color);
}

/* Weight Distribution Card */
.weight-distribution-card,
.career-predictions-card,
.career-summary-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: var(--shadow);
}

.weight-distribution-card h3,
.career-predictions-card h3,
.career-summary-card h3 {
    margin-top: 0;
    font-size: 1.3rem;
    color: var(--text-primary);
    margin-bottom: 1rem;
}

.weight-item {
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.weight-label {
    min-width: 120px;
    font-weight: 600;
    color: var(--text-primary);
}

.weight-bar {
    flex: 1;
    height: 8px;
    background-color: var(--light-bg);
    border-radius: 4px;
    overflow: hidden;
}

.weight-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), #60A5FA);
    border-radius: 4px;
}

/* Career Summary */
.summary-items {
    display: grid;
    gap: 1rem;
}

.summary-item {
    display: flex;
    justify-content: space-between;
    padding: 0.75rem;
    background-color: var(--light-bg);
    border-radius: 8px;
}

.summary-label {
    font-weight: 600;
    color: var(--text-secondary);
}

.summary-value {
    font-weight: 700;
    color: var(--primary-color);
}

/* Integrity Badge */
.integrity-badge {
    text-align: center;
    padding: 1rem;
    background: linear-gradient(135deg, #ECFDF5, #DBEAFE);
    border: 1px solid var(--success-color);
    border-radius: 8px;
    color: var(--success-color);
    font-weight: 600;
    margin: 2rem 0;
}

/* Action Buttons */
.action-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 2rem;
}

.btn-primary,
.btn-secondary {
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), #60A5FA);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 16px rgba(59, 130, 246, 0.3);
}

.btn-secondary {
    background-color: var(--light-bg);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background-color: var(--border-color);
}

/* Responsive Design */
@media (max-width: 768px) {
    .assessment-header h1 {
        font-size: 1.8rem;
    }

    .question-card {
        padding: 1.5rem;
    }

    #question-text {
        font-size: 1.1rem;
    }

    .navigation-controls {
        flex-direction: column;
    }

    .results-container {
        grid-template-columns: 1fr;
    }

    .question-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .option label {
        padding: 1rem;
    }
}