/* Markeplay Security Training Styles */

/* Remove unwanted scrollbars */
html, body {
    overflow-x: hidden;
    max-width: 100vw;
}

.container-fluid, .row, .col-md-3, .col-md-9 {
    overflow-x: hidden;
}

/* Ensure sidebar doesn't cause horizontal scroll */
.sidebar {
    min-width: 0;
    flex-shrink: 0;
}

.main-content {
    min-width: 0;
    flex: 1;
}

/* Hide sidebar completely for admin users */
.admin-view .sidebar {
    display: none !important;
}

/* Full width main content for admin users */
.admin-view .main-content {
    flex: 1 1 100% !important;
    max-width: 100% !important;
}

/* Module cards styling with proper spacing */
.hero-section .row {
    padding: 0 20px;
}

.hero-section .col-md-3:first-child {
    padding-left: 30px;
}

.hero-section .col-md-3:last-child {
    padding-right: 30px;
}

/* Blue background for home section */
#home.content-section {
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%) !important;
    min-height: calc(100vh - 56px);
}

/* Override any other background colors */
#home .hero-section {
    background: transparent !important;
}

#home .container {
    background: transparent !important;
}

/* White text on blue background - but not inside cards */
#home h1 {
    color: white !important;
}

#home > .hero-section > .container > p {
    color: rgba(255,255,255,0.9) !important;
}

/* Keep card text normal colors */
#home .card h5 {
    color: #333 !important;
}

#home .card p {
    color: #666 !important;
}

#home .alert {
    background-color: rgba(255,255,255,0.1) !important;
    border: 1px solid rgba(255,255,255,0.2) !important;
    color: white !important;
}





/* Authentication Styles */
.auth-container {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    background: rgba(0, 0, 0, 0.8) !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    z-index: 9999 !important;
}

.auth-overlay {
    width: 100% !important;
    height: 100% !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    padding: 20px !important;
}

.auth-modal {
    background: white;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    width: 100%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    animation: modalSlideIn 0.3s ease-out;
}

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

.auth-header {
    background: linear-gradient(135deg, #007bff, #0056b3);
    color: white;
    padding: 20px;
    border-radius: 10px 10px 0 0;
    text-align: center;
}

.auth-title {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 600;
}

.auth-form {
    display: none;
    padding: 30px;
}

.auth-form.active {
    display: block;
}

.auth-form h4 {
    color: #333;
    margin-bottom: 25px;
    text-align: center;
    font-weight: 600;
}

.auth-form .form-label {
    font-weight: 500;
    color: #555;
    margin-bottom: 8px;
}

.auth-form .form-control {
    border-radius: 8px;
    border: 2px solid #e9ecef;
    padding: 12px 15px;
    font-size: 14px;
    transition: all 0.3s ease;
}

.auth-form .form-control:focus {
    border-color: #007bff;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

.auth-form .btn {
    border-radius: 8px;
    padding: 12px 20px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
}

.auth-form .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 123, 255, 0.3);
}

.auth-form p {
    margin: 0;
    color: #666;
    font-size: 14px;
}

.auth-form a {
    color: #007bff;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.auth-form a:hover {
    color: #0056b3;
    text-decoration: underline;
}

#auth-alerts {
    margin-top: 20px;
}

#auth-alerts .alert {
    border-radius: 8px;
    border: none;
    font-size: 14px;
}
:root {
    --primary-color: #0066cc;
    --secondary-color: #f8f9fa;
    --success-color: #28a745;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
    --info-color: #17a2b8;
    --light-color: #f8f9fa;
    --dark-color: #343a40;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--secondary-color);
    color: var(--dark-color);
}

/* Navigation Styles */
.navbar-brand {
    font-weight: bold;
    font-size: 1.5rem;
}

/* Sidebar Styles */
.sidebar {
    min-height: calc(100vh - 56px);
    box-shadow: 2px 0 5px rgba(0,0,0,0.1);
}

.module-item {
    margin-bottom: 15px;
}

.module-item .module-title {
    font-size: 0.9rem;
    font-weight: 500;
}

.module-status {
    transition: all 0.3s ease;
}

.module-status.completed {
    color: var(--success-color);
}

.module-status.in-progress {
    color: var(--warning-color);
}

.module-status.locked {
    color: var(--dark-color);
}

.progress-sm {
    height: 5px;
}

/* Main Content Styles */
.main-content {
    padding: 0;
}

.content-section {
    display: none;
    min-height: calc(100vh - 56px);
}

.content-section.active {
    display: block;
}

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, var(--primary-color), #004499);
    color: white;
    margin: -15px -15px 30px -15px;
}

.hero-section .display-4 {
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

/* Card Styles */
.card {
    border: none;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
}

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

/* Module Card Styles */
.module-card {
    cursor: pointer;
    transition: all 0.3s ease;
    border-left: 4px solid transparent;
}

.module-card:hover {
    border-left-color: var(--primary-color);
    background-color: rgba(0, 102, 204, 0.05);
}

.module-card.completed {
    border-left-color: var(--success-color);
    background-color: rgba(40, 167, 69, 0.05);
}

.module-card.in-progress {
    border-left-color: var(--warning-color);
    background-color: rgba(255, 193, 7, 0.05);
}

.module-card.locked {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Progress Bars */
.progress {
    background-color: #e9ecef;
    border-radius: 10px;
}

.progress-bar {
    border-radius: 10px;
    transition: width 0.6s ease;
}

/* Quiz Styles */
.quiz-question {
    background-color: white;
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.quiz-option {
    padding: 10px 15px;
    margin: 5px 0;
    border: 2px solid #e9ecef;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.quiz-option:hover {
    border-color: var(--primary-color);
    background-color: rgba(0, 102, 204, 0.05);
}

.quiz-option.selected {
    border-color: var(--primary-color);
    background-color: rgba(0, 102, 204, 0.1);
}

.quiz-option.correct {
    border-color: var(--success-color);
    background-color: rgba(40, 167, 69, 0.1);
}

.quiz-option.incorrect {
    border-color: var(--danger-color);
    background-color: rgba(220, 53, 69, 0.1);
}

/* Certificate Styles */
.certificate {
    background: white;
    border: 10px solid var(--primary-color);
    border-radius: 15px;
    padding: 40px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    margin: 20px auto;
    max-width: 600px;
}

.certificate-header {
    color: var(--primary-color);
    font-size: 2.5rem;
    font-weight: bold;
    margin-bottom: 20px;
}

.certificate-title {
    font-size: 1.8rem;
    color: var(--dark-color);
    margin-bottom: 30px;
}

.certificate-name {
    font-size: 2rem;
    color: var(--primary-color);
    font-weight: bold;
    border-bottom: 2px solid var(--primary-color);
    display: inline-block;
    padding-bottom: 10px;
    margin-bottom: 20px;
}

.certificate-details {
    color: var(--dark-color);
    margin-bottom: 30px;
}

.certificate-date {
    color: var(--primary-color);
    font-weight: 500;
}

/* Module Content Styles */
.module-content {
    background: white;
    border-radius: 10px;
    padding: 30px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin-bottom: 30px;
}

.module-header {
    border-bottom: 3px solid var(--primary-color);
    padding-bottom: 15px;
    margin-bottom: 30px;
}

.module-section {
    margin-bottom: 30px;
}

.module-section h3 {
    color: var(--primary-color);
    border-left: 4px solid var(--primary-color);
    padding-left: 15px;
    margin-bottom: 20px;
}

/* Alert Styles */
.alert-security {
    background-color: #fff3cd;
    border-color: #ffeaa7;
    color: #856404;
    border-left: 4px solid var(--warning-color);
}

.alert-best-practice {
    background-color: #d1ecf1;
    border-color: #bee5eb;
    color: #0c5460;
    border-left: 4px solid var(--info-color);
}

.alert-danger-example {
    background-color: #f8d7da;
    border-color: #f5c6cb;
    color: #721c24;
    border-left: 4px solid var(--danger-color);
}

/* Interactive Elements */
.interactive-scenario {
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    border-radius: 10px;
    padding: 20px;
    margin: 20px 0;
    border-left: 4px solid var(--info-color);
}

.scenario-question {
    font-weight: bold;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.scenario-options {
    margin-left: 20px;
}

.scenario-explanation {
    background: white;
    padding: 15px;
    border-radius: 5px;
    margin-top: 15px;
    border-left: 4px solid var(--success-color);
}

/* Responsive Design */
@media (max-width: 768px) {
    .sidebar {
        display: none !important;
    }
    
    .main-content {
        margin-left: 0;
    }
    
    .hero-section .display-4 {
        font-size: 2rem;
    }
    
    .certificate {
        padding: 20px;
        margin: 10px;
    }
    
    .certificate-header {
        font-size: 1.8rem;
    }
    
    .certificate-title {
        font-size: 1.3rem;
    }
    
    .certificate-name {
        font-size: 1.5rem;
    }
}

/* Animation Classes */
.fade-in {
    animation: fadeIn 0.5s ease-in;
}

.slide-in {
    animation: slideIn 0.5s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

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

/* Print Styles for Certificate */
@media print {
    body * {
        visibility: hidden;
    }
    
    .certificate, .certificate * {
        visibility: visible;
    }
    
    .certificate {
        position: absolute;
        left: 0;
        top: 0;
        width: 100%;
    }
    
    .navbar, .sidebar, .btn {
        display: none !important;
    }
}

/* Loading Spinner */
.loading-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(0, 102, 204, 0.3);
    border-radius: 50%;
    border-top-color: var(--primary-color);
    animation: spin 1s ease-in-out infinite;
}

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

/* Success/Error Messages */
.message-success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
    border-radius: 5px;
    padding: 10px 15px;
    margin: 10px 0;
}

.message-error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
    border-radius: 5px;
    padding: 10px 15px;
    margin: 10px 0;
}

/* Navigation Progress Indicator */
.nav-progress {
    height: 3px;
    background: linear-gradient(90deg, var(--success-color) 0%, var(--warning-color) 50%, var(--danger-color) 100%);
    position: absolute;
    bottom: 0;
    left: 0;
    transition: width 0.3s ease;
}

/* Force navbar overflow for dropdown */
.navbar {
    overflow: visible !important;
}

.navbar .dropdown {
    position: static !important;
}

/* Login section as full-screen overlay - hidden by default */
#login.content-section {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    background: rgba(0, 0, 0, 0.8) !important;
    display: none !important;
    justify-content: center !important;
    align-items: center !important;
    z-index: 9999 !important;
}

/* Show login section when active */
#login.content-section.active {
    display: flex !important;
}

#login.content-section .container {
    position: relative !important;
    z-index: 10000 !important;
}
