/* front.css - Central CSS for kayprep Platform */

:root {
    --primary-color: #4361ee;
    --secondary-color: #3a0ca3;
    --accent-color: #4cc9f0;
    --success-color: #4ade80;
    --warning-color: #f59e0b;
    --danger-color: #ef4444;
    --text-dark: #2b2d42;
    --text-light: #8d99ae;
    --background-light: #f8f9fa;
    --border-color: #e2e8f0;
    --shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--background-light);
}

/* Common Layout Styles */
.container-custom {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Common Button Styles */
.btn-primary-custom {
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    border: none;
    padding: 12px 30px;
    border-radius: 50px;
    font-weight: 600;
    color: white;
    text-decoration: none;
    display: inline-block;
    transition: all 0.3s ease;
    cursor: pointer;
}

.btn-primary-custom:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow);
    color: white;
    text-decoration: none;
}

.btn-outline-custom {
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
    background: transparent;
    padding: 12px 30px;
    border-radius: 50px;
    font-weight: 600;
    text-decoration: none;
    display: inline-block;
    transition: all 0.3s ease;
    cursor: pointer;
}

.btn-outline-custom:hover {
    background: var(--primary-color);
    color: white;
    text-decoration: none;
}

.btn-success-custom {
    background: linear-gradient(45deg, var(--success-color), #16a34a);
    border: none;
    padding: 12px 30px;
    border-radius: 50px;
    font-weight: 600;
    color: white;
    transition: all 0.3s ease;
}

.btn-success-custom:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

/* Card Styles */
.card-custom {
    background: white;
    border-radius: 15px;
    padding: 30px;
    box-shadow: var(--shadow);
    border: none;
    transition: transform 0.3s ease;
}

.card-custom:hover {
    transform: translateY(-5px);
}

.card-header-custom {
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    color: white;
    border-radius: 15px 15px 0 0 !important;
    padding: 20px 30px;
    border: none;
}

/* Form Styles */
.form-control-custom {
    border: 2px solid var(--border-color);
    border-radius: 10px;
    padding: 12px 15px;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-control-custom:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(67, 97, 238, 0.1);
}

.form-label-custom {
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 8px;
}

/* Navigation */
.navbar-custom {
    background: rgba(0,0,0,0.9) !important;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.navbar-custom .navbar-brand {
    font-size: 1.8rem;
    font-weight: bold;
    color: white;
}

.navbar-custom .navbar-brand span {
    color: var(--accent-color);
}

.navbar-custom .nav-link {
    color: white !important;
    font-weight: 500;
    margin: 0 10px;
    transition: color 0.3s ease;
}

.navbar-custom .nav-link:hover {
    color: var(--accent-color) !important;
}

/* Auth Pages Specific */
.auth-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 40px 20px;
}

.auth-card {
    background: white;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.1);
    overflow: hidden;
    max-width: 450px;
    width: 100%;
}

.auth-header {
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    color: white;
    padding: 40px 30px;
    text-align: center;
}

.auth-header h2 {
    margin-bottom: 10px;
    font-weight: 700;
}

.auth-header p {
    opacity: 0.9;
    margin-bottom: 0;
}

.auth-body {
    padding: 40px 30px;
}

/* Alert Styles */
.alert-custom {
    border-radius: 10px;
    border: none;
    padding: 15px 20px;
    margin-bottom: 20px;
}

.alert-success-custom {
    background: linear-gradient(45deg, #dcfce7, #bbf7d0);
    color: #166534;
    border-left: 4px solid var(--success-color);
}

.alert-danger-custom {
    background: linear-gradient(45deg, #fee2e2, #fecaca);
    color: #991b1b;
    border-left: 4px solid var(--danger-color);
}

.alert-warning-custom {
    background: linear-gradient(45deg, #fef3c7, #fde68a);
    color: #92400e;
    border-left: 4px solid var(--warning-color);
}

/* Utility Classes */
.text-primary-custom {
    color: var(--primary-color) !important;
}

.text-accent {
    color: var(--accent-color) !important;
}

.bg-gradient-primary {
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color)) !important;
}

.border-radius-15 {
    border-radius: 15px !important;
}

.shadow-custom {
    box-shadow: var(--shadow) !important;
}

/* Loading Spinner */
.spinner-custom {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 20px auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Responsive Design */
@media (max-width: 768px) {
    .container-custom {
        padding: 0 15px;
    }
    
    .auth-card {
        margin: 20px;
    }
    
    .auth-body {
        padding: 30px 20px;
    }
    
    .btn-primary-custom,
    .btn-outline-custom {
        padding: 10px 20px;
        font-size: 0.9rem;
    }
}

/* Dashboard Specific */
.sidebar-custom {
    background: white;
    border-radius: 15px;
    box-shadow: var(--shadow);
    padding: 20px;
    height: fit-content;
}

.sidebar-custom .nav-link {
    color: var(--text-dark);
    padding: 12px 15px;
    border-radius: 10px;
    margin-bottom: 5px;
    transition: all 0.3s ease;
}

.sidebar-custom .nav-link:hover,
.sidebar-custom .nav-link.active {
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    color: white;
}

.dashboard-card {
    background: white;
    border-radius: 15px;
    padding: 25px;
    box-shadow: var(--shadow);
    border-left: 4px solid var(--primary-color);
}

/* Exam Timer */
.timer-display {
    font-size: 2rem;
    font-weight: bold;
    color: var(--primary-color);
    background: white;
    padding: 15px 25px;
    border-radius: 50px;
    box-shadow: var(--shadow);
    display: inline-block;
}

.timer-warning {
    color: var(--warning-color);
    animation: pulse 1s infinite;
}

.timer-danger {
    color: var(--danger-color);
    animation: pulse 0.5s infinite;
}

@keyframes pulse {
    0% { opacity: 1; }
    50% { opacity: 0.5; }
    100% { opacity: 1; }
}

/* Question Styles */
.question-card {
    background: white;
    border-radius: 15px;
    padding: 25px;
    box-shadow: var(--shadow);
    margin-bottom: 20px;
    border-left: 4px solid transparent;
}

.question-card.active {
    border-left-color: var(--primary-color);
}

.option-label {
    display: block;
    padding: 15px;
    margin-bottom: 10px;
    border: 2px solid var(--border-color);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.option-label:hover {
    border-color: var(--primary-color);
    background: rgba(67, 97, 238, 0.05);
}

.option-label.selected {
    border-color: var(--primary-color);
    background: rgba(67, 97, 238, 0.1);
}

.option-input {
    margin-right: 10px;
}

/* Subscription Status */
.subscription-active {
    background: linear-gradient(45deg, #dcfce7, #bbf7d0);
    color: #166534;
    padding: 20px;
    border-radius: 15px;
    border-left: 4px solid var(--success-color);
}

.subscription-expired {
    background: linear-gradient(45deg, #fee2e2, #fecaca);
    color: #991b1b;
    padding: 20px;
    border-radius: 15px;
    border-left: 4px solid var(--danger-color);
}

/* Add to existing front.css */

/* Exam Results Specific */
.border-success {
    border-left: 4px solid var(--success-color) !important;
}

.border-danger {
    border-left: 4px solid var(--danger-color) !important;
}

/* Option states */
.option-label.bg-success {
    background: linear-gradient(45deg, #dcfce7, #bbf7d0) !important;
    border-color: var(--success-color) !important;
}

.option-label.bg-danger {
    background: linear-gradient(45deg, #fee2e2, #fecaca) !important;
    border-color: var(--danger-color) !important;
}

/* Filter buttons active state */
.filter-btn.active {
    background: var(--primary-color) !important;
    color: white !important;
    border-color: var(--primary-color) !important;
}

/* Exam card hover effects */
.exam-card .card-custom {
    transition: all 0.3s ease;
}

.exam-card .card-custom:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0,0,0,0.1);
}

/* Progress bars */
.progress-custom {
    height: 8px;
    border-radius: 10px;
    background: var(--border-color);
    overflow: hidden;
}

.progress-bar-custom {
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    border-radius: 10px;
    transition: width 0.5s ease;
}

/* Badge enhancements */
.badge {
    font-size: 0.75rem;
    font-weight: 500;
    padding: 5px 10px;
    border-radius: 20px;
}