/* CourseCorrect - Custom Styles */

:root {
    --primary-color: #2563eb;
    --secondary-color: #1d4ed8;
    --accent-color: #f59e0b;
    --success-color: #10b981;
    --danger-color: #ef4444;
    --dark-color: #1f2937;
    --light-color: #f8fafc;
    --border-radius: 12px;
    --box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

* {
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: #374151;
    overflow-x: hidden;
}

/* Navigation */
.navbar {
    backdrop-filter: blur(10px);
    background: rgba(37, 99, 235, 0.95) !important;
    box-shadow: var(--box-shadow);
}

.navbar-brand {
    font-size: 1.5rem;
    font-weight: 700;
}

.nav-link {
    font-weight: 500;
    transition: var(--transition);
    position: relative;
}

.nav-link:hover {
    transform: translateY(-1px);
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    right: 0;
    height: 2px;
    background: white;
    border-radius: 2px;
}

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding-top: 80px;
}

.hero-image i {
    font-size: 8rem;
    opacity: 0.9;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
}

/* Buttons */
.btn {
    border-radius: var(--border-radius);
    font-weight: 600;
    padding: 0.75rem 1.5rem;
    transition: var(--transition);
    border: none;
    position: relative;
    overflow: hidden;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
}

.btn-success {
    background: linear-gradient(135deg, var(--success-color), #059669);
}

.btn-outline-light:hover {
    background: rgba(255, 255, 255, 0.2);
    color: white;
}

/* Cards */
.card {
    border: none;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    transition: var(--transition);
    overflow: hidden;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.15);
}

.feature-card {
    background: white;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    transition: var(--transition);
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.15);
}

.feature-icon {
    color: var(--primary-color);
}

/* Slide Cards */
.slide-card {
    background: white;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
    height: 100%;
}

.slide-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.15);
}

.slide-preview {
    height: 200px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 3rem;
    position: relative;
    overflow: hidden;
}

.slide-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.slide-preview .file-icon {
    z-index: 2;
    position: relative;
}

.slide-preview::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
    z-index: 1;
}

.slide-info {
    padding: 1.5rem;
}

.slide-title {
    font-weight: 600;
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
    color: var(--dark-color);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.slide-category {
    display: inline-block;
    background: var(--primary-color);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.slide-description {
    color: #6b7280;
    font-size: 0.9rem;
    margin-bottom: 1rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.slide-price {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

/* Forms */
.form-control,
.form-select {
    border-radius: var(--border-radius);
    border: 2px solid #e5e7eb;
    padding: 0.75rem 1rem;
    transition: var(--transition);
}

.form-control:focus,
.form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(37, 99, 235, 0.25);
    outline: none;
}

.input-group-text {
    background: var(--light-color);
    border: 2px solid #e5e7eb;
    border-right: none;
    border-radius: var(--border-radius) 0 0 var(--border-radius);
}

.input-group .form-control {
    border-left: none;
    border-radius: 0 var(--border-radius) var(--border-radius) 0;
}

/* Cart */
.cart-item {
    background: white;
    border-radius: var(--border-radius);
    padding: 1rem;
    margin-bottom: 1rem;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
}

.cart-item:hover {
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
}

.cart-item-info h6 {
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.cart-item-price {
    font-weight: 700;
    color: var(--primary-color);
    font-size: 1.1rem;
}

.cart-item-remove {
    background: none;
    border: none;
    color: var(--danger-color);
    font-size: 1.2rem;
    padding: 0.5rem;
    border-radius: 50%;
    transition: var(--transition);
}

.cart-item-remove:hover {
    background: rgba(239, 68, 68, 0.1);
    transform: scale(1.1);
}

/* Payment Methods */
.payment-method {
    background: white;
    border-radius: var(--border-radius);
    padding: 1.5rem;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
}

.payment-method:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.payment-method h6 {
    color: var(--dark-color);
    font-weight: 600;
    margin-bottom: 1rem;
}

/* Modals */
.modal-content {
    border: none;
    border-radius: var(--border-radius);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.25);
}

.modal-header {
    background: var(--primary-color);
    color: white;
    border-bottom: none;
    border-radius: var(--border-radius) var(--border-radius) 0 0;
}

.modal-title {
    font-weight: 600;
}

/* Loading States */
.spinner-border {
    width: 3rem;
    height: 3rem;
    border-width: 0.3em;
}

/* Alerts */
.alert {
    border: none;
    border-radius: var(--border-radius);
    font-weight: 500;
}

.alert-info {
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
    color: white;
}

.alert-warning {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: white;
}

.alert-success {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
}

/* Badges */
.badge {
    border-radius: 50px;
    font-weight: 600;
    padding: 0.5rem 0.75rem;
}

.badge.bg-danger {
    background: var(--danger-color) !important;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

/* Footer */
footer {
    background: linear-gradient(135deg, var(--dark-color), #111827) !important;
}

footer h5, footer h6 {
    color: white;
}

footer a {
    color: #d1d5db;
    text-decoration: none;
    transition: var(--transition);
}

footer a:hover {
    color: white;
    transform: translateX(5px);
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero-section {
        text-align: center;
        padding: 2rem 0;
    }
    
    .hero-image i {
        font-size: 4rem;
        margin-top: 2rem;
    }
    
    .display-4 {
        font-size: 2rem;
    }
    
    .btn {
        width: 100%;
        margin-bottom: 0.5rem;
    }
    
    .modal-dialog {
        margin: 0.5rem;
    }
    
    .payment-method {
        margin-bottom: 1rem;
    }
    
    .cart-item {
        text-align: center;
    }
    
    .cart-item-remove {
        margin-top: 1rem;
    }
}

@media (max-width: 576px) {
    .container {
        padding: 0 1rem;
    }
    
    .card-body {
        padding: 1.5rem;
    }
    
    .feature-card {
        padding: 2rem 1rem;
    }
    
    .slide-info {
        padding: 1rem;
    }
    
    .modal-body {
        padding: 1.5rem;
    }
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f5f9;
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--secondary-color);
}

/* Animation utilities */
.fade-in {
    animation: fadeIn 0.6s ease-out;
}

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

.slide-up {
    animation: slideUp 0.6s ease-out;
}

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

/* Utility classes */
.text-primary {
    color: var(--primary-color) !important;
}

.bg-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color)) !important;
}

.border-primary {
    border-color: var(--primary-color) !important;
}

.shadow-sm {
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05) !important;
}

.shadow {
    box-shadow: var(--box-shadow) !important;
}

.shadow-lg {
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15) !important;
}

.rounded {
    border-radius: var(--border-radius) !important;
}

.rounded-lg {
    border-radius: calc(var(--border-radius) * 1.5) !important;
}

.fw-bold {
    font-weight: 700 !important;
}

.fw-semibold {
    font-weight: 600 !important;
}

.lh-sm {
    line-height: 1.25 !important;
}

.lh-base {
    line-height: 1.5 !important;
}

.lh-lg {
    line-height: 1.75 !important;
}