:root {
    --primary-color: #4F46E5;
    --primary-dark: #4338CA;
    --success-color: #10B981;
    --warning-color: #F59E0B;
    --danger-color: #EF4444;
    --text-primary: #1F2937;
    --text-secondary: #6B7280;
    --bg-light: #F9FAFB;
    --border-color: #E5E7EB;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
    --radius: 12px;
    --transition: 0.2s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--bg-light);
    color: var(--text-primary);
    line-height: 1.6;
}

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    padding: 3rem 1rem;
    text-align: center;
    color: white;
}

.hero-title {
    font-size: clamp(1.75rem, 5vw, 2.5rem);
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.hero-title i {
    margin-right: 0.5rem;
}

.hero-subtitle {
    font-size: clamp(1rem, 3vw, 1.125rem);
    opacity: 0.95;
}

/* Main Content */
.main-content {
    padding: 2rem 1rem;
    max-width: 1200px;
    margin: 0 auto;
}

/* Learning Guide */
.learning-guide {
    display: flex;
    gap: 1.5rem;
    align-items: flex-start;
    background: white;
    padding: 1.5rem;
    border-radius: var(--radius);
    border-left: 4px solid var(--primary-color);
    margin-bottom: 2rem;
}

.guide-icon {
    font-size: 2.5rem;
    color: var(--primary-color);
    flex-shrink: 0;
}

.guide-content h2 {
    font-size: clamp(1.25rem, 3vw, 1.5rem);
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.guide-content p {
    color: var(--text-secondary);
    font-size: 0.9375rem;
}

/* Tabs Navigation */
.tabs-nav {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 2rem;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.tabs-nav::-webkit-scrollbar {
    display: none;
}

.tab-btn {
    flex: 1;
    min-width: 140px;
    background: white;
    border: 2px solid var(--border-color);
    border-radius: var(--radius);
    padding: 1rem;
    cursor: pointer;
    transition: all var(--transition);
    text-align: center;
}

.tab-btn i {
    display: block;
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: var(--text-secondary);
    transition: color var(--transition);
}

.tab-btn span {
    display: block;
    font-weight: 600;
    font-size: 0.9375rem;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.tab-btn small {
    display: block;
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.tab-btn:hover {
    border-color: var(--primary-color);
    background: #F5F3FF;
}

.tab-btn.active {
    border-color: var(--primary-color);
    background: var(--primary-color);
}

.tab-btn.active i,
.tab-btn.active span,
.tab-btn.active small {
    color: white;
}

/* Tab Content */
.tabs-content {
    min-height: 400px;
}

.tab-pane {
    display: none;
}

.tab-pane.active {
    display: block;
}

/* Level Header */
.level-header {
    background: white;
    padding: 1.5rem;
    border-radius: var(--radius);
    margin-bottom: 1.5rem;
}

.level-header h2 {
    font-size: clamp(1.5rem, 4vw, 2rem);
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.level-header p {
    color: var(--text-secondary);
    font-size: 0.9375rem;
}

.badge {
    display: inline-block;
    padding: 0.375rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8125rem;
    font-weight: 600;
    margin-left: 0.5rem;
}

.badge-free {
    background: #D1FAE5;
    color: #065F46;
}

.badge-premium {
    background: #DBEAFE;
    color: #1E40AF;
}

.badge-excellence {
    background: #FEE2E2;
    color: #991B1B;
}

/* Video Grid */
.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

/* Video Card */
.video-card {
    background: white;
    border-radius: var(--radius);
    overflow: hidden;
    cursor: pointer;
    transition: transform var(--transition);
}

.video-card:hover {
    transform: translateY(-4px);
}

.video-thumbnail {
    position: relative;
    width: 100%;
    padding-top: 56.25%;
    background: #000;
    overflow: hidden;
}

.video-thumbnail img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.play-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 3rem;
    color: rgba(255, 255, 255, 0.9);
    pointer-events: none;
    transition: transform var(--transition);
}

.video-card:hover .play-overlay {
    transform: translate(-50%, -50%) scale(1.15);
}

.duration-badge {
    position: absolute;
    bottom: 0.5rem;
    right: 0.5rem;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.8125rem;
    font-weight: 500;
}

.lock-badge {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    font-size: 1.5rem;
    color: var(--danger-color);
}

.video-content {
    padding: 1rem;
}

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

.video-content h3 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    line-height: 1.4;
}

.video-badges {
    display: flex;
    gap: 0.5rem;
}

.badge-difficulty {
    padding: 0.25rem 0.625rem;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 500;
    background: var(--bg-light);
    color: var(--text-secondary);
}

/* Locked Video */
.video-card.locked {
    opacity: 0.7;
}

/* Video Modal */
.video-modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 9999;
    padding: 1rem;
}

.video-modal-overlay.active {
    display: flex;
    justify-content: center;
    align-items: center;
}

.video-modal {
    background: #1F2937;
    border-radius: var(--radius);
    max-width: 900px;
    width: 100%;
    position: relative;
}

.video-modal-close {
    position: absolute;
    top: -1rem;
    right: -1rem;
    background: white;
    border: none;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 50%;
    font-size: 1.25rem;
    cursor: pointer;
    z-index: 10000;
    transition: background var(--transition);
}

.video-modal-close:hover {
    background: var(--danger-color);
    color: white;
}

.video-wrapper {
    position: relative;
    padding-top: 56.25%;
    border-radius: var(--radius) var(--radius) 0 0;
    overflow: hidden;
    background: #000;
}

.video-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

.video-info {
    padding: 1.5rem;
}

.video-info h3 {
    color: white;
    font-size: 1.25rem;
    margin-bottom: 0.75rem;
    font-weight: 600;
}

.video-meta {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.video-meta span {
    padding: 0.375rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8125rem;
    font-weight: 500;
}

.video-meta .video-number {
    background: var(--primary-color);
    color: white;
}

.video-meta .video-duration,
.video-meta .video-difficulty {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

/* Lock Modal */
.lock-modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    z-index: 9998;
    padding: 1rem;
}

.lock-modal-overlay.active {
    display: flex;
    justify-content: center;
    align-items: center;
}

.lock-modal {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    border-radius: var(--radius);
    padding: 2.5rem 2rem;
    max-width: 450px;
    width: 100%;
    text-align: center;
}

.lock-icon {
    font-size: 3.5rem;
    color: white;
    margin-bottom: 1.5rem;
}

.lock-modal h2 {
    color: white;
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.lock-modal p {
    color: rgba(255, 255, 255, 0.95);
    font-size: 1rem;
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.lock-modal-button {
    background: white;
    color: var(--primary-color);
    border: none;
    padding: 0.875rem 2rem;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: transform var(--transition);
}

.lock-modal-button:hover {
    transform: translateY(-2px);
}

/* FAQ Section */
.faq-section {
    background: white;
    padding: 2rem 1.5rem;
    border-radius: var(--radius);
    margin: 3rem 0 2rem;
}

.faq-section h2 {
    font-size: clamp(1.5rem, 4vw, 2rem);
    font-weight: 700;
    margin-bottom: 2rem;
    text-align: center;
}

.faq-section h2 i {
    color: var(--primary-color);
    margin-right: 0.5rem;
}

.faq-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
}

.faq-item {
    background: var(--bg-light);
    padding: 1.5rem;
    border-radius: var(--radius);
    border-left: 3px solid var(--primary-color);
}

.faq-item h3 {
    font-size: 1.0625rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
}

.faq-item p {
    color: var(--text-secondary);
    font-size: 0.9375rem;
    line-height: 1.6;
}

/* CTA Section */
.cta-section {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    padding: 3rem 2rem;
    border-radius: var(--radius);
    text-align: center;
    color: white;
    margin-bottom: 2rem;
}

.cta-section i {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.cta-section h2 {
    font-size: clamp(1.5rem, 4vw, 2rem);
    font-weight: 700;
    margin-bottom: 0.75rem;
}

.cta-section p {
    font-size: 1.0625rem;
    margin-bottom: 1.5rem;
    opacity: 0.95;
}

.cta-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.875rem 1.75rem;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1rem;
    text-decoration: none;
    transition: transform var(--transition);
}

.cta-btn i {
    font-size: 1rem;
}

.cta-btn.primary {
    background: white;
    color: var(--primary-color);
}

.cta-btn.secondary {
    background: transparent;
    color: white;
    border: 2px solid white;
}

.cta-btn:hover {
    transform: translateY(-2px);
}

/* Mobile Optimizations */
@media (max-width: 768px) {
    .main-content {
        padding: 1.5rem 1rem;
    }

    .learning-guide {
        flex-direction: column;
        text-align: center;
        padding: 1.25rem;
    }

    .guide-icon {
        font-size: 2rem;
    }

    .tabs-nav {
        gap: 0.375rem;
    }

    .tab-btn {
        min-width: 120px;
        padding: 0.875rem 0.5rem;
    }

    .tab-btn i {
        font-size: 1.25rem;
        margin-bottom: 0.375rem;
    }

    .tab-btn span {
        font-size: 0.875rem;
    }

    .tab-btn small {
        font-size: 0.6875rem;
    }

    .video-grid {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }

    .video-modal {
        margin: 0.5rem;
    }

    .video-modal-close {
        top: -0.75rem;
        right: -0.75rem;
        width: 2.25rem;
        height: 2.25rem;
        font-size: 1.125rem;
    }

    .lock-modal {
        padding: 2rem 1.5rem;
    }

    .faq-grid {
        grid-template-columns: 1fr;
    }

    .cta-section {
        padding: 2rem 1.5rem;
    }

    .cta-buttons {
        flex-direction: column;
    }

    .cta-btn {
        width: 100%;
        justify-content: center;
    }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    * {
        animation: none !important;
        transition: none !important;
    }
}