.quiz-section {
    background: white;
    padding: 2rem;
    border-radius: 1rem;
    box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.1);
    margin: 2rem 0;
}

.quiz-question {
    font-size: 1.2rem;
    font-weight: 500;
    margin-bottom: 1.5rem;
    text-align: center;
}

.quiz-options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.quiz-option {
    padding: 1rem;
    border: 2px solid #e5e7eb;
    border-radius: 0.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
}

.quiz-option:hover {
    border-color: #2563eb;
    transform: translateY(-2px);
}

.quiz-option.correct {
    background: #dcfce7;
    border-color: #22c55e;
}

.quiz-option.wrong {
    background: #fee2e2;
    border-color: #ef4444;
}

    :root {
        --primary-gradient: linear-gradient(135deg, #2563eb, #9333ea);
        --secondary-gradient: linear-gradient(135deg, #eff6ff, #f5f3ff);
        --card-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
        --card-hover-shadow: 0 8px 15px rgba(0, 0, 0, 0.15);
    }

 
    body {
        background-color: #f8fafc;
        margin: 0;
        font-family: 'Inter', sans-serif;
        color: #1f2937;
    }


    .history-section {
        max-width: 1024px;
        margin: 0 auto;
        padding: 2rem;
        opacity: 0;
        transform: translateY(20px);
        animation: fadeInUp 0.8s ease forwards;
    }

    @keyframes fadeInUp {
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }


    .section-header {
        text-align: center;
        margin-bottom: 3rem;
        position: relative;
    }

    .section-title {
        font-size: 2.5rem;
        font-weight: bold;
        margin-bottom: 1rem;
        background: var(--primary-gradient);
        -webkit-background-clip: text;
        background-clip: text;
        color: transparent;
        position: relative;
        display: inline-block;
    }

    
    .section-title::before {
        content: '';
        position: absolute;
        top: -20%;
        left: -10%;
        width: 120%;
        height: 140%;
        background: radial-gradient(circle, rgba(37, 99, 235, 0.1) 0%, transparent 70%);
        animation: pulse 3s infinite;
        z-index: -1;
    }

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


    .decorative-line {
        width: 6rem;
        height: 4px;
        margin: 0 auto;
        background: var(--primary-gradient);
        border-radius: 2px;
        position: relative;
    }

 
    .decorative-line::after {
        content: '';
        position: absolute;
        top: -2px;
        left: -2px;
        right: -2px;
        bottom: -2px;
        background: var(--primary-gradient);
        filter: blur(8px);
        opacity: 0.3;
    }


    .intro-card {
        padding: 2rem;
        border-radius: 1rem;
        background: var(--secondary-gradient);
        border: 1px solid rgba(37, 99, 235, 0.1);
        box-shadow: var(--card-shadow);
        margin-bottom: 2rem;
        position: relative;
        overflow: hidden;
    }


    .intro-card::before {
        content: '';
        position: absolute;
        top: -50%;
        left: -50%;
        width: 200%;
        height: 200%;
        background: linear-gradient(45deg, transparent 40%, rgba(37, 99, 235, 0.1) 50%, transparent 60%);
        animation: shimmer 3s infinite linear;
        pointer-events: none;
    }

    @keyframes shimmer {
        from { transform: translateX(-100%) rotate(45deg); }
        to { transform: translateX(100%) rotate(45deg); }
    }

    .intro-text {
        font-size: 1.125rem;
        line-height: 1.7;
        color: #374151;
        position: relative;
    }


    .history-card {
        background: white;
        border-radius: 1rem;
        overflow: hidden;
        box-shadow: var(--card-shadow);
        transition: all 0.3s ease;
        margin-bottom: 1.5rem;
        border: 1px solid rgba(37, 99, 235, 0.1);
        position: relative;
    }

    .history-card:hover {
        box-shadow: var(--card-hover-shadow);
        transform: translateY(-2px);
    }

  
    .card-header {
        padding: 1.5rem;
        cursor: pointer;
        display: flex;
        justify-content: space-between;
        align-items: center;
        background: white;
        transition: background 0.3s ease;
        position: relative;
    }

    .card-title {
        font-size: 1.5rem;
        font-weight: 600;
        color: #1f2937;
        margin: 0;
        transition: color 0.3s ease;
    }


    .card-content {
        max-height: 0;
        opacity: 0;
        padding: 0 1.5rem;
        overflow: hidden;
        transition: max-height 0.5s ease, opacity 0.5s ease, padding 0.5s ease;
        background: linear-gradient(135deg, white, #f8fafc);
    }

    .card-content.active {
        max-height: 1000px;
        opacity: 1;
        padding: 1.5rem;
    }



    .card-text {
        color: #4b5563;
        line-height: 1.7;
        margin-bottom: 1rem;
    }

   
    .fact-box {
        background: rgba(37, 99, 235, 0.05);
        padding: 1.2rem;
        border-radius: 0.8rem;
        margin-top: 1.5rem;
        transform: translateY(10px);
        opacity: 0;
        transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
        transition-delay: 0.1s;
        border-left: 4px solid #2563eb;
        position: relative;
    }

    .fact-box::before {
        content: '💡';
        position: absolute;
        top: -12px;
        left: -12px;
        background: white;
        padding: 4px;
        border-radius: 50%;
        box-shadow: var(--card-shadow);
    }

    .card-content.active .fact-box {
        transform: translateY(0);
        opacity: 1;
    }

    .fact-text {
        color: #1e40af;
        font-size: 0.95rem;
        margin: 0;
        line-height: 1.6;
    }

   
    .chevron {
        width: 24px;
        height: 24px;
        transition: transform 0.3s ease;
        stroke: #2563eb;
        stroke-width: 2.5;
    }

    .chevron.active {
        transform: rotate(180deg);
    }

  
    .history-card::after {
        content: '';
        position: absolute;
        left: 0;
        right: 0;
        bottom: 0;
        height: 3px;
        background: var(--primary-gradient);
        transform: scaleX(0);
        transition: transform 0.3s ease;
    }

    .history-card:hover::after {
        transform: scaleX(1);
    }
      
    .quiz-section {
        background: white;
        padding: 2rem;
        border-radius: 1rem;
        box-shadow: var(--card-shadow);
        margin: 2rem 0;
    }

    .quiz-question {
        font-size: 1.2rem;
        font-weight: 500;
        margin-bottom: 1.5rem;
        text-align: center;
    }

    .quiz-options {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
        gap: 1rem;
        margin-bottom: 1.5rem;
    }
    body {
        font-family: 'Open Sans', sans-serif;
    }
    
    h2.section-title, h3.card-title {
        font-family: 'Roboto', sans-serif;
    }
    
    .quiz-option {
        padding: 1rem;
        border: 2px solid #e5e7eb;
        border-radius: 0.5rem;
        cursor: pointer;
        transition: all 0.3s ease;
        text-align: center;
    }

    .quiz-option:hover {
        border-color: #2563eb;
        transform: translateY(-2px);
    }
    :target {
        scroll-margin-top: 80px; /* Высота навигационной панели */
    }
    
    .quiz-option.correct {
        background: #dcfce7;
        border-color: #22c55e;
    }

    .quiz-option.wrong {
        background: #fee2e2;
        border-color: #ef4444;
    }

    body {
        font-family: 'Roboto', sans-serif;
        background-color: #f8f9fa;
        transition: background-color 0.3s, color 0.3s;
    }
    body.dark-mode {
        background-color: #121212;
        color: #ffffff;
    }
    header {
        position: relative;
        width: 100%;
        height: 100vh;
        overflow: hidden;
    }
    .carousel-inner img {
        width: 100%;
        height: 100vh;
        object-fit: cover;
    }
    .carousel-caption {
        background: rgba(0, 0, 0, 0.5);
        padding: 20px;
        border-radius: 10px;
    }
    nav.navbar {
        transition: background-color 0.3s;
    }
    nav.navbar.sticky {
        background-color: rgba(52, 58, 64, 0.95) !important;
        transition: background-color 0.3s;
    }
    section {
        padding: 60px 0;
    }
    section h2 {
        margin-bottom: 30px;
        position: relative;
        font-family: 'Montserrat', sans-serif;
    }
    
    footer {
        background-color: #343a40;
        color: white;
        padding: 40px 0;
        text-align: center;
    }
    .icon {
        font-size: 2rem;
        color: #0d6efd;
        margin-bottom: 20px;
    }
    .dark-mode nav.navbar {
        background-color: rgba(18, 18, 18, 0.95) !important;
    }

    body::-webkit-scrollbar {
display: none; 
}


    #backToTop {
display: none; 
position: fixed;
bottom: 20px;
right: 20px;
z-index: 100;
background-color: #007BFF;
color: white;
border: none;
border-radius: 40%;
padding: 10px 15px;
cursor: pointer;
box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.1);
font-size: 18px;
transition: opacity 0.3s ease, transform 0.3s ease;
}

#backToTop:hover {
background-color: #0056b3; 
transform: scale(1.1); 
}

#backToTop:active {
transform: scale(0.95);
}


    .theme-switch {
        position: fixed;
        top: 20px;
        right: 20px;
        z-index: 1001;
    }
    .theme-switch input {
        display: none;
    }
    .theme-switch label {
        cursor: pointer;
        text-indent: -9999px;
        width: 50px;
        height: 25px;
        background: grey;
        display: block;
        border-radius: 100px;
        position: relative;
    }
    .theme-switch label:after {
        content: '';
        position: absolute;
        top: 2px;
        left: 2px;
        width: 21px;
        height: 21px;
        background: #fff;
        border-radius: 90px;
        transition: 0.3s;
    }
    .theme-switch input:checked + label {
        background: #0d6efd;
    }
    .theme-switch input:checked + label:after {
        left: calc(100% - 2px);
        transform: translateX(-100%);
    }