@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;700;800&display=swap');

:root {
    --deep-sea: #0047AB;
    --sky-blue: #87CEFA;
    --golden-sun: #FFD700;
    --sunrise-orange: #FF8C00;
    --foam: #FFFFFF;
    --sand: #F4A460;
    --text-dark: #1A1A1A;
    --font-main: 'Montserrat', sans-serif;
}

html {
    scroll-behavior: smooth;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: var(--font-main);
    background-color: var(--foam);
    color: var(--text-dark);
    line-height: 1.6;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
header {
    background-color: var(--deep-sea);
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo img {
    height: 70px;
    display: block;
}

/* Burger Button */
.burger-menu {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 20px;
    cursor: pointer;
    z-index: 1001;
}

.burger-menu span {
    display: block;
    height: 3px;
    width: 100%;
    background-color: var(--foam);
    border-radius: 3px;
    transition: all 0.3s ease-in-out;
}

/* Burger Animation */
.burger-menu.active span:nth-child(1) {
    transform: translateY(8.5px) rotate(45deg);
}

.burger-menu.active span:nth-child(2) {
    opacity: 0;
}

.burger-menu.active span:nth-child(3) {
    transform: translateY(-8.5px) rotate(-45deg);
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 25px;
}

.nav-links a {
    color: var(--foam);
    text-decoration: none;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.9rem;
    transition: color 0.3s;
}

.nav-links a:hover {
    color: var(--golden-sun);
}

/* Hero Section */
#hero {
    background: linear-gradient(135deg, var(--deep-sea) 0%, var(--sky-blue) 100%);
    padding: 100px 0;
    color: var(--foam);
    text-align: center;
    position: relative;
}

#hero .hero-content {
    max-width: 800px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
}

#hero h1 {
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 30px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

#hero p {
    font-size: 1.25rem;
    margin-bottom: 40px;
    font-weight: 500;
}

.hero-image-wrap {
    position: relative;
    max-width: 500px;
    margin: 0 auto;
    left: -5%;
    /* Сдвиг всей композиции: отрицательное - влево, положительное - вправо */
}

.ship-img {
    width: 100%;
    filter: drop-shadow(0 20px 30px rgba(0, 0, 0, 0.2));
    animation: float 6s ease-in-out infinite;
}

.ship-overlay {
    position: absolute;
    top: 80%;
    left: 60%;
    transform: translate(-50%, -50%);
    width: 90%;
    z-index: 3;
    pointer-events: none;
    /* animation: float-alt 8s ease-in-out infinite; */
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0) rotate(-1deg);
    }

    50% {
        transform: translateY(-20px) rotate(1deg);
    }
}

@keyframes float-alt {

    0%,
    100% {
        transform: translate(-50%, -50%) translateY(0) rotate(1deg);
    }

    50% {
        transform: translate(-50%, -50%) translateY(-12px) rotate(-2deg);
    }
}

/* Sections General */
section {
    padding: 80px 0;
}

h2 {
    font-size: 2.5rem;
    color: var(--deep-sea);
    text-align: center;
    margin-bottom: 50px;
    position: relative;
    padding-bottom: 15px;
}

h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background-color: var(--sunrise-orange);
}

/* Cards Layout */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.card {
    background: var(--foam);
    padding: 30px;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s;
    border-top: 5px solid var(--sky-blue);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    height: 100%;
}

@media (max-width: 768px) {
    .card {
        padding: 20px;
    }
}

.card:hover {
    transform: translateY(-10px);
}

.card h3 {
    color: var(--deep-sea);
    margin-bottom: 15px;
}

/* Gas Stations */
#gas-stations {
    background-color: #f0f7ff;
}

/* Scoring Table */
.scoring-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 30px;
    background: var(--foam);
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.scoring-table th {
    background-color: var(--deep-sea);
    color: var(--foam);
    padding: 20px;
    text-align: left;
}

.scoring-table td {
    padding: 15px 20px;
    border-bottom: 1px solid #eee;
}

.scoring-table td:last-child {
    color: var(--sunrise-orange);
    font-weight: 700;
}

.scoring-table tr:last-child td {
    border-bottom: none;
}

/* Accordion FAQ */
.faq-item {
    margin-bottom: 15px;
    border: 2px solid var(--sky-blue);
    border-radius: 10px;
    overflow: hidden;
}

.faq-header {
    background-color: var(--foam);
    padding: 20px;
    cursor: pointer;
    font-weight: 700;
    display: flex;
    justify-content: space-between;
    transition: background 0.3s;
}

.faq-header:hover {
    background-color: #f0f7ff;
}

.faq-content {
    padding: 20px;
    background-color: #fff;
    display: none;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 15px 35px;
    background-color: var(--golden-sun);
    color: var(--deep-sea);
    text-decoration: none;
    font-weight: 800;
    border-radius: 50px;
    text-transform: uppercase;
    transition: all 0.3s;
    box-shadow: 0 4px 15px rgba(255, 215, 0, 0.4);
}

.btn:hover {
    background-color: var(--sunrise-orange);
    color: var(--foam);
    transform: scale(1.05);
}

/* Footer */
footer {
    background-color: var(--deep-sea);
    color: var(--foam);
    padding: 50px 0;
    text-align: center;
}

@media (max-width: 992px) {
    #hero h1 {
        font-size: 2.5rem;
    }

    .hero-image-wrap {
        max-width: 400px;
    }
}

@media (max-width: 768px) {
    #hero {
        padding: 60px 0;
    }

    #hero h1 {
        font-size: 2rem;
    }

    #hero p {
        font-size: 1.1rem;
    }

    .hero-image-wrap {
        max-width: 320px;
        left: 0;
        /* Убираем сдвиг на мобильных для центровки */
    }

    .ship-img {
        animation: float-mobile 6s ease-in-out infinite;
    }

    .ship-overlay {
        left: 50%;
    }

    .burger-menu {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 100%;
        height: 100vh;
        background-color: var(--deep-sea);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        transition: 0.5s;
        z-index: 1000;
        gap: 30px;
    }

    .nav-links.active {
        right: 0;
    }

    .nav-links a {
        font-size: 1.2rem;
    }

    nav {
        flex-direction: row;
        gap: 0;
    }

    h2 {
        font-size: 2rem;
    }

    .card-grid {
        grid-template-columns: 1fr;
    }

    .scoring-table {
        display: block;
        overflow-x: auto;
    }
}

@media (max-width: 480px) {
    #hero h1 {
        font-size: 1.7rem;
    }

    .logo img {
        height: 55px;
    }

    .nav-links a {
        font-size: 0.8rem;
    }

    .btn {
        width: 100%;
        padding: 15px 20px;
    }

    .container [style*="min-width: 300px"] {
        min-width: 100% !important;
    }
}

/* Мобильная анимация корабля с меньшей амплитудой поднятия */
@keyframes float-mobile {

    0%,
    100% {
        transform: translateY(0) rotate(-1deg);
    }

    50% {
        /* Опускаем верхнюю точку: вместо -20px делаем -10px */
        transform: translateY(-10px) rotate(1deg);
    }
}