/* Statistical Learning Styles */

/* Light background with dark text - WCAG AA compliant */
body {
    background-color: #ffffff;
    color: #333333;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
}

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, #6a11cb 0%, #2575fc 100%);
    color: white;
    padding: 80px 0;
    text-align: center;
    border-radius: 0 0 20px 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

.hero-section h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.hero-section p {
    font-size: 1.2rem;
    max-width: 800px;
    margin: 0 auto 30px;
    opacity: 0.9;
}

.btn-explore {
    background: white;
    color: #6a11cb;
    border: none;
    font-weight: 600;
    padding: 15px 40px;
    font-size: 1.1rem;
    border-radius: 50px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.btn-explore:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.3);
    color: #6a11cb;
}

/* Section Titles */
.section-title {
    text-align: center;
    margin: 60px 0 40px;
}

.section-title h2 {
    font-size: 2.5rem;
    color: #2c3e50;
    margin-bottom: 15px;
    position: relative;
    display: inline-block;
}

.section-title h2:after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: linear-gradient(45deg, #6a11cb, #2575fc);
    border-radius: 2px;
}

.section-title p {
    font-size: 1.1rem;
    color: #7f8c8d;
    max-width: 700px;
    margin: 20px auto 0;
}

/* Cards */
.definition-card, .concept-card, .simulation-card, .calculator-card, 
.comparison-card, .export-card, .import-card, .simulation-card {
    background: white;
    border-radius: 15px;
    padding: 30px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    border: none;
    margin-bottom: 30px;
}

.definition-card:hover, .concept-card:hover, .simulation-card:hover, 
.calculator-card:hover, .comparison-card:hover, .export-card:hover, 
.import-card:hover, .simulation-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
}

.definition-card h2, .concept-card h3, .simulation-card h3, 
.calculator-card h3, .comparison-card h3, .export-card h3, .import-card h3,
.simulation-card h3 {
    color: #2c3e50;
    margin-bottom: 20px;
    font-weight: 600;
}

.definition-card p, .concept-card p, .simulation-card p, 
.calculator-card p, .comparison-card p, .export-card p, .import-card p,
.simulation-card p {
    color: #555;
    line-height: 1.8;
}

/* Keyword Badges */
.keyword-badges-container {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 25px 0;
}

.keyword-badge {
    background: linear-gradient(45deg, #6a11cb, #2575fc);
    color: white;
    padding: 8px 15px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.keyword-badge:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

/* Simulation Containers */
.simulation-container {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 15px;
    min-height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #e9ecef;
}

.simulation-container canvas, .simulation-container div {
    width: 100%;
    height: 100%;
}

/* Calculator Styles */
.calculator-card .form-group {
    margin-bottom: 20px;
}

.calculator-card label {
    font-weight: 600;
    color: #2c3e50;
}

.calculator-card .form-control {
    border-radius: 8px;
    border: 1px solid #ddd;
    padding: 12px 15px;
    transition: border-color 0.3s ease;
}

.calculator-card .form-control:focus {
    border-color: #6a11cb;
    box-shadow: 0 0 0 0.2rem rgba(106, 17, 203, 0.25);
}

.result-display {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 20px;
    min-height: 200px;
}

.result-display h4 {
    color: #2c3e50;
    margin-bottom: 15px;
}

.visualization-container {
    background: white;
    border-radius: 8px;
    padding: 10px;
    border: 1px solid #e9ecef;
}

/* Step Indicator */
.step-indicator {
    position: relative;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    counter-reset: step-counter;
    margin: 40px 0;
}

.step-indicator:before {
    content: '';
    position: absolute;
    top: 30px;
    left: 5%;
    width: 90%;
    height: 2px;
    background: #e9ecef;
    z-index: 1;
}

.step {
    position: relative;
    text-align: center;
    flex: 1;
    z-index: 2;
    padding: 0 10px;
}

.step-number {
    width: 60px;
    height: 60px;
    background: #e9ecef;
    color: #7f8c8d;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: bold;
    margin: 0 auto 15px;
    position: relative;
    z-index: 2;
    transition: all 0.3s ease;
}

.step.active .step-number {
    background: linear-gradient(45deg, #6a11cb, #2575fc);
    color: white;
    box-shadow: 0 5px 15px rgba(106, 17, 203, 0.4);
}

.step-content h4 {
    color: #2c3e50;
    margin-bottom: 10px;
}

.step-content p {
    color: #7f8c8d;
    font-size: 0.95rem;
}

/* Comparison Section */
.comparison-list {
    list-style: none;
    padding: 0;
}

.comparison-list li {
    padding: 8px 0;
    border-bottom: 1px solid #eee;
}

.comparison-list li:last-child {
    border-bottom: none;
}

/* Export/Import Cards */
.export-card, .import-card {
    text-align: center;
}

.custom-file {
    margin-top: 15px;
}

.custom-file-input {
    cursor: pointer;
}

.custom-file-label {
    border-radius: 8px;
    padding: 10px 15px;
}

/* Simulation Controls */
.simulation-controls {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 20px;
    margin: 20px 0;
}

.simulation-controls .form-group {
    margin-bottom: 15px;
}

.simulation-controls label {
    font-weight: 600;
    color: #2c3e50;
}

.results-panel {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 20px;
    height: 100%;
}

.results-panel h4 {
    color: #2c3e50;
    margin-bottom: 15px;
    border-bottom: 2px solid #e9ecef;
    padding-bottom: 10px;
}

/* Breadcrumb */
.breadcrumb {
    background: transparent;
    padding: 15px 0;
}

.breadcrumb-item a {
    color: #6a11cb;
}

.breadcrumb-item.active {
    color: #7f8c8d;
}

/* Buttons */
.btn {
    border-radius: 8px;
    padding: 10px 20px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.btn-primary {
    background: linear-gradient(45deg, #6a11cb, #2575fc);
    border: none;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(106, 17, 203, 0.4);
}

.btn-success {
    background: linear-gradient(45deg, #28a745, #20c997);
    border: none;
}

.btn-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(40, 167, 69, 0.4);
}

.btn-warning {
    background: linear-gradient(45deg, #ffc107, #fd7e14);
    border: none;
}

.btn-warning:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 193, 7, 0.4);
}

.btn-info {
    background: linear-gradient(45deg, #17a2b8, #6a11cb);
    border: none;
}

.btn-info:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(23, 162, 184, 0.4);
}

.btn-outline-primary {
    border-color: #6a11cb;
    color: #6a11cb;
}

.btn-outline-primary:hover {
    background: #6a11cb;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(106, 17, 203, 0.4);
}

.btn-outline-success {
    border-color: #28a745;
    color: #28a745;
}

.btn-outline-success:hover {
    background: #28a745;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(40, 167, 69, 0.4);
}

/* Exercises Section */
.exercises-section .card {
    border: 1px solid #e9ecef;
    border-radius: 10px;
    margin-bottom: 15px;
    overflow: hidden;
}

.exercises-section .card-header {
    background: linear-gradient(45deg, #6a11cb, #2575fc);
    color: white;
    border-bottom: none;
    padding: 15px 20px;
}

.exercises-section .btn-link {
    color: white;
    text-decoration: none;
    font-weight: 600;
    text-align: left;
    width: 100%;
}

.exercises-section .btn-link:hover {
    color: #f8f9fa;
    text-decoration: none;
}

.exercises-section .card-body {
    background: #f8f9fa;
}

.exercises-section .card-body ol, .exercises-section .card-body ul {
    padding-left: 20px;
}

.exercises-section .card-body li {
    margin-bottom: 10px;
}

/* MCQ Section */
.mcq-section .question-card {
    background: white;
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
    border: 1px solid #e9ecef;
}

.mcq-section .question-card h4 {
    color: #2c3e50;
    margin-bottom: 15px;
    font-weight: 600;
}

.mcq-section .form-check {
    margin-bottom: 10px;
}

.mcq-section .form-check-label {
    color: #555;
}

.mcq-section .answer {
    margin-top: 15px;
    padding: 15px;
    border-radius: 8px;
    background-color: #e8f5e9;
    border: 1px solid #c8e6c9;
}

.mcq-section .btn-secondary {
    background: #6c757d;
    border: none;
    margin-left: 10px;
}

.mcq-section .btn-secondary:hover {
    background: #5a6268;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(108, 117, 125, 0.4);
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero-section h1 {
        font-size: 2.2rem;
    }
    
    .hero-section p {
        font-size: 1rem;
    }
    
    .section-title h2 {
        font-size: 2rem;
    }
    
    .step-indicator {
        flex-direction: column;
        align-items: center;
    }
    
    .step {
        margin-bottom: 40px;
        width: 100%;
    }
    
    .step-indicator:before {
        display: none;
    }
    
    .simulation-controls .form-row .form-group {
        margin-bottom: 15px;
    }
}

@media (max-width: 480px) {
    .hero-section {
        padding: 50px 0;
    }
    
    .hero-section h1 {
        font-size: 1.8rem;
    }
    
    .definition-card, .concept-card, .simulation-card, .calculator-card,
    .comparison-card, .export-card, .import-card, .simulation-card {
        padding: 20px;
    }
    
    .keyword-badge {
        font-size: 0.8rem;
        padding: 6px 12px;
    }
    
    .btn-explore {
        padding: 12px 30px;
        font-size: 1rem;
    }
    
    .section-title {
        margin: 40px 0 30px;
    }
}

/* Animation Classes */
.animated {
    animation-duration: 1s;
    animation-fill-mode: both;
}

.fadeInUp {
    animation-name: fadeInUp;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translate3d(0, 30px, 0);
    }
    to {
        opacity: 1;
        transform: translate3d(0, 0, 0);
    }
}

/* High Contrast Mode Support */
@media (prefers-contrast: high) {
    body {
        background: #fff;
        color: #000;
    }
    
    .definition-card, .concept-card, .simulation-card, .calculator-card,
    .comparison-card, .export-card, .import-card, .simulation-card {
        border: 2px solid #000;
    }
}