@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@500;600;700&family=Inter:wght@400;500;600&display=swap');

:root {
    --bg-deep: #04141f;
    --bg-mid: #061c29;
    --bg-soft: #082433;
    --teal: #2fd6c8;
    --teal-dim: #1a9c94;
    --amber: #f0b354;
    --amber-dim: #c88a35;
    --text: #dcecf2;
    --text-muted: #8fa9b6;
    --line: rgba(47, 214, 200, 0.16);
    --font-head: 'Cinzel', serif;
    --font-body: 'Inter', sans-serif;
    --header-h: 84px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: auto;
}

body {
    font-family: var(--font-body);
    background: var(--bg-deep);
    color: var(--text);
    font-size: 16px;
    line-height: 1.7;
    overflow-x: hidden;
}

body.fixed {
    overflow: hidden;
}

img {
    max-width: 100%;
    display: block;
}

a {
    color: inherit;
    text-decoration: none;
}

ul {
    list-style: none;
}

.container {
    width: 100%;
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 24px;
}

.preloader {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-deep);
}

.preloader img {
    width: 78px;
    height: 78px;
}

html.hide .preloader {
    display: none;
}

.section-title {
    font-family: var(--font-head);
    font-size: 42px;
    line-height: 1.2;
    font-weight: 700;
    color: #fff;
    margin-bottom: 22px;
    letter-spacing: 0.4px;
}

.eyebrow {
    display: inline-block;
    font-size: 12px;
    letter-spacing: 3px;
    text-transform: uppercase;
    font-weight: 600;
    color: var(--teal);
    margin-bottom: 14px;
    padding-left: 42px;
    position: relative;
}

.eyebrow::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    width: 30px;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--teal));
}

.list-title {
    font-family: var(--font-head);
    font-size: 19px;
    font-weight: 600;
    color: var(--amber);
    margin: 28px 0 14px;
    letter-spacing: 0.5px;
}

p {
    color: var(--text-muted);
    margin-bottom: 16px;
}

.feature-list li {
    position: relative;
    padding-left: 32px;
    margin-bottom: 12px;
    color: var(--text-muted);
}

.feature-list li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 10px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--teal);
    box-shadow: 0 0 0 4px rgba(47, 214, 200, 0.14), 0 0 14px rgba(47, 214, 200, 0.7);
}

.btn {
    display: inline-block;
    font-family: var(--font-head);
    font-size: 15px;
    font-weight: 700;
    letter-spacing: 1.6px;
    text-transform: uppercase;
    padding: 17px 42px;
    border-radius: 40px;
    margin-top: 14px;
    transition: transform 0.25s ease, box-shadow 0.25s ease, filter 0.25s ease;
}

.btn--primary {
    background: linear-gradient(105deg, var(--teal) 0%, var(--teal-dim) 45%, var(--amber) 130%);
    color: #032029;
    box-shadow: 0 10px 34px rgba(47, 214, 200, 0.28);
}

.btn--primary:hover {
    filter: brightness(1.08);
    box-shadow: 0 14px 40px rgba(47, 214, 200, 0.42);
}

@keyframes floatY {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

.btn--float {
    animation: floatY 3s ease-in-out infinite;
}

.btn--float:hover {
    animation-play-state: paused;
}

.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 100;
    transition: background 0.3s ease, box-shadow 0.3s ease, backdrop-filter 0.3s ease;
}

.header.scrolled {
    background: rgba(4, 20, 31, 0.92);
    backdrop-filter: blur(10px);
    box-shadow: 0 1px 0 var(--line), 0 12px 34px rgba(0, 0, 0, 0.45);
}

.header__inner {
    height: var(--header-h);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
}

.logo img {
    width: 34px;
    height: 34px;
}

.logo__text {
    font-family: var(--font-head);
    font-size: 22px;
    font-weight: 700;
    letter-spacing: 1.6px;
    text-transform: uppercase;
    background: linear-gradient(92deg, #ffffff 10%, var(--teal) 60%, var(--amber) 115%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav {
    display: flex;
    align-items: center;
    gap: 32px;
}

.nav a {
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0.6px;
    color: var(--text-muted);
    position: relative;
    padding: 6px 0;
    transition: color 0.25s ease;
}

.nav a::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--teal), var(--amber));
    transition: width 0.3s ease;
}

.nav a:hover {
    color: #fff;
}

.nav a:hover::after {
    width: 100%;
}

.burger-btn {
    display: none;
    background: transparent;
    border: 0;
    width: 40px;
    height: 32px;
    padding: 0;
    position: relative;
    cursor: pointer;
}

.burger-btn span {
    position: absolute;
    left: 4px;
    width: 32px;
    height: 2px;
    border-radius: 2px;
    background: var(--teal);
    transition: transform 0.3s ease, opacity 0.25s ease, top 0.3s ease;
}

.burger-btn span:nth-child(1) { top: 7px; }
.burger-btn span:nth-child(2) { top: 15px; }
.burger-btn span:nth-child(3) { top: 23px; }

.burger-btn.act span:nth-child(1) {
    top: 15px;
    transform: rotate(45deg);
}

.burger-btn.act span:nth-child(2) {
    opacity: 0;
}

.burger-btn.act span:nth-child(3) {
    top: 15px;
    transform: rotate(-45deg);
}

#mobile-menu {
    position: fixed;
    inset: 0;
    z-index: 99;
    background: rgba(4, 20, 31, 0.97);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

#mobile-menu.opened {
    opacity: 1;
    pointer-events: auto;
}

.mobile-nav {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 26px;
}

.mobile-nav a {
    font-family: var(--font-head);
    font-size: 24px;
    font-weight: 600;
    letter-spacing: 1.4px;
    color: var(--text);
}

.mobile-nav a:hover {
    color: var(--teal);
}

.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: calc(var(--header-h) + 60px) 0 80px;
    overflow: hidden;
}

.hero__bg {
    position: absolute;
    inset: 0;
    background: url('../img/hero-bg.webp') center / cover no-repeat;
}

.hero__bg::after {
    content: '';
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 22% 40%, rgba(47, 214, 200, 0.16), transparent 55%),
        linear-gradient(90deg, rgba(4, 20, 31, 0.95) 12%, rgba(4, 20, 31, 0.62) 55%, rgba(4, 20, 31, 0.88) 100%),
        linear-gradient(180deg, rgba(4, 20, 31, 0.7) 0%, transparent 30%, var(--bg-deep) 98%);
}

.hero__inner {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: 1.05fr 0.95fr;
    align-items: center;
    gap: 40px;
}

.hero__title {
    font-family: var(--font-head);
    font-size: 60px;
    line-height: 1.12;
    font-weight: 700;
    color: #fff;
    margin-bottom: 26px;
    text-shadow: 0 6px 40px rgba(0, 0, 0, 0.6);
}

.hero__text {
    font-size: 17px;
    color: #b8cfd9;
    max-width: 560px;
}

.hero__media {
    position: relative;
    display: flex;
    justify-content: center;
    animation: swimDrift 9.1s ease-in-out infinite alternate;
}

.hero__media::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 52%;
    transform: translate(-50%, -50%);
    width: 78%;
    padding-bottom: 78%;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(47, 214, 200, 0.3), transparent 68%);
    filter: blur(12px);
}

@keyframes swimDrift {
    from { transform: translateX(-9px); }
    to { transform: translateX(9px); }
}

@keyframes swimBob {
    from { translate: 0 9px; }
    to { translate: 0 -15px; }
}

@keyframes swimTilt {
    from { rotate: -1.8deg; }
    to { rotate: 1.8deg; }
}

.hero__media img {
    position: relative;
    max-height: 640px;
    width: auto;
    filter: drop-shadow(0 26px 50px rgba(0, 0, 0, 0.6));
    animation:
        swimBob 4.3s ease-in-out infinite alternate,
        swimTilt 6.7s ease-in-out infinite alternate;
}

.about,
.quest,
.puzzles,
.relics {
    padding: 110px 0;
    position: relative;
}

.about {
    background: var(--bg-mid);
}

.quest {
    background:
        radial-gradient(circle at 88% 18%, rgba(240, 179, 84, 0.09), transparent 46%),
        var(--bg-deep);
}

.puzzles {
    background: var(--bg-soft);
}

.relics {
    background:
        radial-gradient(circle at 14% 78%, rgba(47, 214, 200, 0.1), transparent 48%),
        var(--bg-deep);
}

.about__inner,
.quest__inner,
.puzzles__inner,
.relics__inner {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 70px;
}

.about__media img,
.quest__media img,
.puzzles__media img,
.relics__media img {
    position: relative;
    z-index: 2;
    width: 100%;
    border-radius: 18px;
    border: 1px solid var(--line);
    box-shadow: 0 26px 60px rgba(0, 0, 0, 0.5);
}

.about__media,
.quest__media,
.puzzles__media,
.relics__media {
    position: relative;
}

.about__media::after,
.quest__media::after,
.puzzles__media::after,
.relics__media::after {
    content: '';
    position: absolute;
    inset: -18px;
    border-radius: 26px;
    background: radial-gradient(circle at 50% 50%, rgba(47, 214, 200, 0.14), transparent 70%);
    z-index: 1;
}

.relics__note {
    margin-top: 26px;
    padding: 18px 22px;
    border-left: 2px solid var(--amber);
    background: rgba(240, 179, 84, 0.06);
    border-radius: 0 12px 12px 0;
    font-size: 14px;
    color: #a8bdc8;
}

.footer {
    position: relative;
    padding: 90px 0 0;
    background: var(--bg-mid);
    overflow: hidden;
}

.footer::before {
    content: '';
    position: absolute;
    inset: 0;
    background: url('../img/footer-bg.webp') center / cover no-repeat;
    opacity: 0.5;
}

.footer::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, var(--bg-deep) 0%, rgba(6, 28, 41, 0.86) 45%, rgba(6, 28, 41, 0.96) 100%);
}

.footer__inner,
.footer__bottom {
    position: relative;
    z-index: 2;
}

.footer__inner {
    display: grid;
    grid-template-columns: 1.4fr 1fr 0.8fr;
    gap: 50px;
    padding-bottom: 60px;
}

.footer__brand .logo {
    margin-bottom: 20px;
}

.footer__title {
    font-family: var(--font-head);
    font-size: 18px;
    color: #fff;
    margin-bottom: 10px;
    letter-spacing: 0.5px;
}

.footer__desc {
    font-size: 15px;
    max-width: 380px;
}

.footer__nav {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer__nav a {
    font-size: 15px;
    color: var(--text-muted);
    transition: color 0.25s ease, padding-left 0.25s ease;
}

.footer__nav a:hover {
    color: var(--teal);
    padding-left: 6px;
}

.footer__contact-label {
    display: block;
    font-size: 12px;
    letter-spacing: 2.4px;
    text-transform: uppercase;
    color: var(--amber);
    margin-bottom: 12px;
}

.footer__contact a {
    color: var(--text);
    border-bottom: 1px solid var(--line);
    transition: color 0.25s ease, border-color 0.25s ease;
}

.footer__contact a:hover {
    color: var(--teal);
    border-color: var(--teal);
}

.footer__bottom {
    border-top: 1px solid var(--line);
    padding-top: 24px;
    padding-bottom: 28px;
}

.footer__bottom p {
    margin: 0;
    font-size: 14px;
    color: #6f8894;
}

.legal-page {
    padding: calc(var(--header-h) + 80px) 0 100px;
    background:
        radial-gradient(circle at 82% 6%, rgba(47, 214, 200, 0.08), transparent 45%),
        var(--bg-deep);
}

.legal-content {
    max-width: 900px;
    margin: 0 auto;
}

.legal-content h1 {
    font-family: var(--font-head);
    font-size: 44px;
    line-height: 1.18;
    color: #fff;
    margin-bottom: 10px;
}

.legal-content h2 {
    font-family: var(--font-head);
    font-size: 24px;
    color: var(--teal);
    margin: 40px 0 14px;
    letter-spacing: 0.5px;
}

.legal-content h3 {
    font-family: var(--font-head);
    font-size: 19px;
    color: var(--amber);
    margin: 30px 0 12px;
}

.legal-content .legal-date {
    font-size: 14px;
    color: var(--amber);
    margin-bottom: 34px;
}

.legal-content p {
    font-size: 16px;
}

.legal-content ul {
    margin: 0 0 20px;
}

.legal-content ul li {
    position: relative;
    padding-left: 26px;
    margin-bottom: 10px;
    color: var(--text-muted);
}

.legal-content ul li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 11px;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--teal);
}

.legal-content a {
    color: var(--teal);
    border-bottom: 1px solid var(--line);
}

.legal-content a:hover {
    border-color: var(--teal);
}

.legal-content strong {
    color: var(--text);
}

@media (max-width: 1024px) {
    .nav {
        gap: 22px;
    }

    .hero__title {
        font-size: 46px;
    }

    .section-title {
        font-size: 34px;
    }

    .about__inner,
    .quest__inner,
    .puzzles__inner,
    .relics__inner {
        gap: 44px;
    }

    .footer__inner {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    :root {
        --header-h: 70px;
    }

    .nav {
        display: none;
    }

    .burger-btn {
        display: block;
    }

    .hero {
        min-height: auto;
        padding: calc(var(--header-h) + 50px) 0 60px;
        text-align: center;
    }

    .hero__inner {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .hero__content {
        order: 2;
    }

    .hero__media {
        order: 1;
    }

    .hero__media img {
        max-height: 380px;
    }

    .hero__text {
        margin-left: auto;
        margin-right: auto;
    }

    .hero__title {
        font-size: 36px;
    }

    .about,
    .quest,
    .puzzles,
    .relics {
        padding: 70px 0;
    }

    .about__inner,
    .quest__inner,
    .puzzles__inner,
    .relics__inner {
        grid-template-columns: 1fr;
        gap: 34px;
    }

    .about__media,
    .puzzles__media {
        order: 2;
    }

    .about__content,
    .puzzles__content {
        order: 1;
    }

    .footer {
        padding-top: 60px;
    }

    .footer__inner {
        grid-template-columns: 1fr;
        gap: 36px;
        padding-bottom: 30px;
    }

    .footer__nav {
        align-items: center;
    }

    .footer__contact {
        text-align: center;
    }

    .footer__nav a:hover {
        padding-left: 0;
    }

    .footer__bottom {
        margin-top: 14px;
        padding-top: 34px;
        padding-bottom: 40px;
        text-align: center;
    }

    .legal-content h1 {
        font-size: 32px;
    }
}

@media (max-width: 640px) {
    .container {
        padding-left: 18px;
        padding-right: 18px;
    }

    .hero__title {
        font-size: 30px;
    }

    .section-title {
        font-size: 27px;
    }

    .logo__text {
        font-size: 18px;
    }

    .btn {
        width: 100%;
        text-align: center;
        padding: 16px 24px;
        font-size: 14px;
    }

    .mobile-nav a {
        font-size: 20px;
    }

    .legal-content h2 {
        font-size: 21px;
    }
}
