:root {
    --accent-color: cornflowerblue;
    --dark-color: #333;
    --light-color: #f8f9fa;
    --border-radius: 12px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Roboto', sans-serif;
}

body {
    background-color: #f5f5f5;
    color: #333;
    line-height: 1.6;
        background-image: url(/img/service/main_background.png);
}

/* Навигационная панель */
header {
    background-color: white;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 100;
    border-radius: 0 0 var(--border-radius) var(--border-radius);
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 5%;
    max-width: 1400px;
    margin: 0 auto;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo img {
    height: 50px;
}

.logo-text {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--accent-color);
}

.nav-links {
    display: flex;
    gap: 2rem;
}

.nav-links a {
    text-decoration: none;
    color: var(--dark-color);
    font-weight: 500;
    transition: color 0.3s;
}

.nav-links a:hover {
    color: var(--accent-color);
}

/* Основное содержание */
.container {
    max-width: 1400px;
    margin: 2rem auto;
    padding: 0 5%;
}

/* Герой-секция */
.hero {
    background: linear-gradient(135deg, rgba(100, 149, 237, 0.1) 0%, rgba(100, 149, 237, 0.2) 100%);
    padding: 3rem;
    border-radius: var(--border-radius);
    margin-bottom: 3rem;
    text-align: center;
}

.hero h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: var(--accent-color);
}

.hero p {
    font-size: 1.1rem;
    max-width: 800px;
    margin: 0 auto 1.5rem;
}

.patriotic-text {
    background-color: rgba(255, 255, 255, 0.8);
    padding: 1.5rem;
    border-radius: var(--border-radius);
    border-left: 4px solid var(--accent-color);
    margin-top: 2rem;
}

/* Стили слайдера */
.news-slider {
    position: relative;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    margin-bottom: 3rem;
}

.slider-container {
    display: flex;
    width: 100%;
    transition: transform 0.5s ease-in-out;
}

.slide {
    min-width: 100%;
    position: relative;
    flex-shrink: 0;
}

.slide img {
    width: 100%;
    height: 500px;
    object-fit: cover;
    display: block;
}

.slide-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 2rem;
    background: linear-gradient(to top, rgba(0,0,0,0.8) 0%, rgba(0,0,0,0) 100%);
    color: white;
}

.slide-title {
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
    text-shadow: 0 2px 4px rgba(0,0,0,0.5);
}

.slide p {
    font-size: 1.1rem;
    opacity: 0.9;
    text-shadow: 0 1px 2px rgba(0,0,0,0.5);
}

.slider-nav {
    position: absolute;
    bottom: 20px;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    gap: 10px;
    z-index: 10;
}

.slider-dot {
    width: 12px;
    height: 12px;
    background-color: rgba(255, 255, 255, 0.5);
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
}

.slider-dot.active {
    background-color: var(--accent-color);
    transform: scale(1.2);
}

.slider-dot:hover {
    background-color: rgba(255, 255, 255, 0.8);
}

/* Каталог экспонатов */
.catalog-section {
    margin-bottom: 3rem;
}

.category-filter {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.category-btn {
    padding: 0.5rem 1.5rem;
    background-color: white;
    border: 2px solid var(--accent-color);
    border-radius: 20px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s;
}

.category-btn:hover, .category-btn.active {
    background-color: var(--accent-color);
    color: white;
}

.aircraft-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

.aircraft-card {
    background-color: white;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s, box-shadow 0.3s;
    position: relative;
    height: auto;
    max-height: 350px;
}

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

.aircraft-card a {
    text-decoration: none;
    color: inherit;
    display: block;
    height: 100%;
}

.card-content {
    display: flex;
    height: 100%;
}

.card-image {
    width: 60%;
    position: relative;
    overflow: hidden;
}

.card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.aircraft-card:hover .card-image img {
    transform: scale(1.05);
}

.card-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 0.5s;
}

.aircraft-card:hover .card-video {
    opacity: 1;
}

.card-text {
    width: 40%;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.card-title {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--accent-color);
}

.card-category {
    display: inline-block;
    background-color: var(--accent-color);
    color: white;
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    margin-bottom: 1rem;
}

.card-description {
    margin-bottom: 1rem;
}

.card-specs {
    font-size: 0.9rem;
    color: #666;
}

.card-specs span {
    display: block;
    margin-bottom: 0.3rem;
}

/* Футер */
footer {
    background-color: var(--dark-color);
    color: white;
    padding: 2rem 5%;
    text-align: center;
    border-radius: var(--border-radius) var(--border-radius) 0 0;
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 1.5rem;
}

.footer-links a {
    color: white;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: var(--accent-color);
}

.social-icons {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.social-icons a {
    color: white;
    font-size: 1.5rem;
    transition: color 0.3s;
}

.social-icons a:hover {
    color: var(--accent-color);
}

.copyright {
    font-size: 0.9rem;
    opacity: 0.8;
}


/* Тест поиска и страниц */

.search-container {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 15px;

}

#search-input {
    padding: 0.5rem 1rem;
    border: 2px solid #ddd;
    border-radius: 20px 0 0 20px;
    outline: none;
    width: 350px;
    transition: all 0.3s;
}

#search-input:focus {
    border-color: var(--accent-color);
}

#search-btn {
    background: var(--accent-color);
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 0 20px 20px 0;
    cursor: pointer;
    transition: background 0.3s;
}

#search-btn:hover {
    background: #4a80e8;
}

.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    margin-top: 2rem;
}

.pagination button {
    background: var(--accent-color);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    transition: background 0.3s;
}

.pagination button:disabled {
    background: #ccc;
    cursor: not-allowed;
}

.pagination button:hover:not(:disabled) {
    background: #4a80e8;
}

.page-numbers {
    display: flex;
    gap: 0.5rem;
}

.page-numbers button {
    background: #ddd;
    color: #333;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
}

.page-numbers button.active {
    background: var(--accent-color);
    color: white;
}

/* Викторина */

/* Стили для таблицы результатов на главной странице (ВРЕМЕННО) */
.victorine-results {
    margin: 3rem 0;
    padding: 2rem;
    background-color: white;
    border-radius: var(--border-radius);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
}

.victorine-results h2 {
    color: var(--accent-color);
    margin-bottom: 1.5rem;
    text-align: center;
}

.victorine-results table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1rem;
}

.victorine-results th, .victorine-results td {
    padding: 0.75rem;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

.victorine-results th {
    background-color: var(--accent-color);
    color: white;
}

.victorine-results tr:nth-child(even) {
    background-color: #f9f9f9;
}

.victorine-results tr:hover {
    background-color: #f1f1f1;
}

@media (max-width: 768px) {
    .victorine-results table {
        display: block;
        overflow-x: auto;
    }
    
    .victorine-modal {
        width: 95%;
    }
}

/* Стили для раздела результатов викторины */
.victorine-section {
    background-color: white;
    border-radius: var(--border-radius);
    padding: 2rem;
    margin-bottom: 3rem;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
}

.victorine-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.victorine-filter {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.victorine-filter select {
    padding: 0.5rem 1rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    background-color: white;
    font-size: 1rem;
}

#refresh-victorine {
    background-color: var(--accent-color);
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1rem;
    transition: background-color 0.3s;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

#refresh-victorine:hover {
    background-color: #4a80e8;
}

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

.stat-card {
    background-color: #f8f9fa;
    border-radius: var(--border-radius);
    padding: 1.5rem;
    text-align: center;
    border-left: 4px solid var(--accent-color);
}

.stat-card h3 {
    color: var(--accent-color);
    margin-bottom: 0.5rem;
    font-size: 1rem;
}

.stat-card p {
    font-size: 1.5rem;
    font-weight: bold;
    margin: 0;
}

.victorine-results-table {
    overflow-x: auto;
}

#victorine-results {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1rem;
}

#victorine-results th {
    background-color: var(--accent-color);
    color: white;
    padding: 0.75rem;
    text-align: left;
}

#victorine-results td {
    padding: 0.75rem;
    border-bottom: 1px solid #ddd;
}

#victorine-results tr:nth-child(even) {
    background-color: #f9f9f9;
}

#victorine-results tr:hover {
    background-color: #f1f1f1;
}

/* Дополнительные стили для викторины */
.quiz-results .result-score {
    margin: 1.5rem 0;
    text-align: center;
}

.quiz-results .score-percentage {
    font-size: 3rem;
    font-weight: bold;
    color: var(--accent-color);
    display: block;
}

.quiz-results .score-details {
    font-size: 1rem;
    color: #666;
}

.score-bar-container {
    position: relative;
    height: 24px;
    background-color: #f0f0f0;
    border-radius: 12px;
    overflow: hidden;
}

.score-bar {
    height: 100%;
    background-color: var(--accent-color);
    transition: width 0.5s ease;
}

.score-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 0.8rem;
    font-weight: bold;
    text-shadow: 0 1px 2px rgba(0,0,0,0.3);
}

/* Анимации */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.victorine-modal {
    animation: fadeIn 0.3s ease-out;
}

.quiz-option {
    animation: fadeIn 0.3s ease-out;
    animation-fill-mode: backwards;
}

.quiz-option:nth-child(1) { animation-delay: 0.1s; }
.quiz-option:nth-child(2) { animation-delay: 0.2s; }
.quiz-option:nth-child(3) { animation-delay: 0.3s; }
.quiz-option:nth-child(4) { animation-delay: 0.4s; }




/* Дополнения к основному CSS для страницы источников */
.source-category:last-child {
    margin-bottom: 0;
}

.source-list li {
    transition: transform 0.2s;
}

.source-list li:hover {
    transform: translateX(5px);
}






/* Адаптивность */
@media (max-width: 768px) {
    .navbar {
        flex-direction: column;
        gap: 1rem;
        padding: 1rem;
    }

    .nav-links {
        gap: 1rem;
    }

    .hero {
        padding: 2rem 1rem;
    }

    .slide img {
        height: 250px;
    }
    
    .slide-content {
        padding: 1.5rem;
    }
    
    .slide-title {
        font-size: 1.5rem;
    }

    .card-content {
        flex-direction: column;
        height: auto;
    }

    .card-image, .card-text {
        width: 100%;
    }

    .card-image {
        height: 200px;
    }

    .aircraft-card {
        max-height: 500px;
    }
        .victorine-controls {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .victorine-filter {
        width: 100%;
    }
    
    .victorine-filter select {
        width: 100%;
    }
    
    #refresh-victorine {
        width: 100%;
        justify-content: center;
    }
    
    .victorine-stats {
        grid-template-columns: 1fr;
    }
}