/* assets/css/styles.css */
/* OSINT Course Styles */

:root {
    --primary-color: #667eea;
    --secondary-color: #764ba2;
    --sidebar-width: 320px;
}

body {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    min-height: 100vh;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 0;
}

/* Header */
.top-header {
    background: white;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.course-title {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary-color);
    margin: 0;
}

.progress-info {
    font-size: 14px;
    color: #6c757d;
}

/* Main Layout */
.main-layout {
    display: flex;
    margin-top: 20px;
    gap: 20px;
    padding: 0 15px 20px 15px;
}

/* Sidebar Navigation */
.sidebar {
    width: var(--sidebar-width);
    background: white;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    height: calc(100vh - 120px);
    overflow-y: auto;
    position: sticky;
    top: 90px;
}

.sidebar-header {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
    padding: 20px;
    font-weight: 600;
    border-radius: 15px 15px 0 0;
    position: sticky;
    top: 0;
    z-index: 10;
}

.search-box {
    padding: 15px;
    border-bottom: 1px solid #e9ecef;
    background: #f8f9fa;
}

.search-box input {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    font-size: 14px;
}

.sections-list {
    padding: 10px;
}

/* Section Accordion */
.section-item {
    margin-bottom: 8px;
}

.section-header {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 12px 15px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 600;
    color: #495057;
    text-decoration: none;
}

.section-header:hover {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
    transform: translateX(5px);
}

.section-header.active {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
}

.section-number {
    background: rgba(0,0,0,0.1);
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 12px;
    margin-right: 10px;
}

.section-toggle {
    transition: transform 0.3s ease;
}

.section-toggle.rotated {
    transform: rotate(180deg);
}

/* Lessons List */
.lessons-list {
    display: none;
    padding: 5px 10px 10px 15px;
    background: #f8f9fa;
    border-radius: 0 0 8px 8px;
    margin-top: -4px;
}

.lessons-list.show {
    display: block;
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        max-height: 0;
    }
    to {
        opacity: 1;
        max-height: 2000px;
    }
}

.lesson-item {
    padding: 10px 15px;
    margin: 5px 0;
    background: white;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    font-size: 14px;
    border-left: 3px solid transparent;
    text-decoration: none;
    color: #495057;
}

.lesson-item:hover {
    background: #e7f3ff;
    border-left-color: var(--primary-color);
    transform: translateX(3px);
    color: #495057;
}

.lesson-item.active {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
    border-left-color: var(--secondary-color);
}

.lesson-icon {
    margin-right: 10px;
    font-size: 12px;
    width: 20px;
}

.lesson-number {
    background: rgba(0,0,0,0.1);
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 11px;
    margin-left: auto;
}

/* Content Area */
.content-area {
    flex: 1;
    background: white;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    min-height: calc(100vh - 120px);
}

.content-header {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
    padding: 25px 40px;
    border-radius: 15px 15px 0 0;
}

.breadcrumb-nav {
    font-size: 13px;
    opacity: 0.9;
    margin-bottom: 10px;
}

.breadcrumb-nav a {
    color: white;
    text-decoration: none;
    opacity: 0.8;
}

.breadcrumb-nav a:hover {
    opacity: 1;
}

.content-title {
    font-size: 32px;
    font-weight: 700;
    margin: 0;
}

.lesson-meta {
    display: flex;
    gap: 20px;
    margin-top: 15px;
    font-size: 14px;
    opacity: 0.9;
}

.lesson-meta span {
    display: flex;
    align-items: center;
    gap: 8px;
}

.content-body {
    padding: 40px 50px;
}

.lesson-content {
    animation: fadeIn 0.5s ease;
}

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

.badge-lesson {
    display: inline-block;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
    padding: 8px 20px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 20px;
}

.lesson-text {
    font-size: 16px;
    line-height: 1.8;
    color: #333;
}

.lesson-text p {
    margin-bottom: 20px;
    text-align: justify;
}

/* Welcome Message */
.welcome-container {
    text-align: center;
    padding: 80px 40px;
    color: #6c757d;
}

.welcome-container i {
    font-size: 100px;
    margin-bottom: 30px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.welcome-container h2 {
    font-weight: 700;
    margin-bottom: 20px;
    color: #495057;
}

.welcome-stats {
    display: flex;
    justify-content: center;
    gap: 40px;
    margin-top: 40px;
}

.stat-card {
    background: #f8f9fa;
    padding: 25px 35px;
    border-radius: 12px;
    border: 2px solid #e9ecef;
}

.stat-number {
    font-size: 36px;
    font-weight: 700;
    color: var(--primary-color);
}

.stat-label {
    font-size: 14px;
    color: #6c757d;
    margin-top: 5px;
}

/* Navigation Buttons */
.lesson-navigation {
    display: flex;
    justify-content: space-between;
    padding: 30px 50px;
    border-top: 2px solid #e9ecef;
}

.nav-btn {
    padding: 12px 25px;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s ease;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
    border: none;
    cursor: pointer;
}

.nav-btn.prev {
    background: #6c757d;
    color: white;
}

.nav-btn.next {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
}

.nav-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    color: white;
}

.nav-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

/* Mobile Toggle Button */
.mobile-toggle {
    display: none;
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
    border: none;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    font-size: 24px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.3);
    cursor: pointer;
    z-index: 1001;
}

/* Scrollbar Styling */
.sidebar::-webkit-scrollbar {
    width: 8px;
}

.sidebar::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.sidebar::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    border-radius: 4px;
}

/* Alerts */
.alert {
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.alert-warning {
    background: #fff3cd;
    border: 1px solid #ffeeba;
    color: #856404;
}

/* Responsive Design */
@media (max-width: 992px) {
    .main-layout {
        flex-direction: column;
    }
    
    .sidebar {
        width: 100%;
        height: auto;
        position: relative;
        top: 0;
        display: none;
    }
    
    .sidebar.mobile-open {
        display: block;
    }
    
    .mobile-toggle {
        display: block;
    }
    
    .content-body {
        padding: 30px 25px;
    }
    
    .lesson-navigation {
        padding: 20px 25px;
    }
    
    .welcome-stats {
        flex-direction: column;
        gap: 20px;
    }
}