/*
Copyright (c) 2025-2026 Korobelnikov Roman Maksimovich (Коробельников Роман Максимович)
All rights reserved. This code is the exclusive property of Korobelnikov Roman Maksimovich.
Unauthorized use, modification, or distribution is prohibited.
*/

* {
    box-sizing: border-box;
}

html, body.landing {
    margin: 0;
    padding: 0;
}

body.landing {
    position: relative;
    min-height: 100vh;
    overflow-x: hidden;
    background: linear-gradient(180deg, #eef2fb, #f5f7fc);
    font-family: 'Manrope', system-ui, sans-serif;
}

@keyframes floatA {
    0%, 100% { transform: translate(0, 0) rotate(var(--r)); }
    50% { transform: translate(16px, -20px) rotate(calc(var(--r) + 2deg)); }
}

@keyframes floatB {
    0%, 100% { transform: translate(0, 0) rotate(var(--r)); }
    50% { transform: translate(-18px, -14px) rotate(calc(var(--r) - 2deg)); }
}

@keyframes floatC {
    0%, 100% { transform: translate(0, 0) rotate(var(--r)); }
    50% { transform: translate(12px, 18px) rotate(calc(var(--r) + 1.5deg)); }
}

.landing-drift {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 100vh;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
}

.drift-card {
    position: absolute;
    width: clamp(140px, 13%, 210px);
    --r: 0deg;
    opacity: 0.92;
    filter: saturate(0.92);
    animation-timing-function: ease-in-out;
    animation-iteration-count: infinite;
    will-change: transform;
    pointer-events: auto;
    z-index: 1;
    cursor: pointer;
    text-decoration: none;
    color: inherit;
    display: block;
    transition: opacity 0.2s ease, filter 0.2s ease;
}

.drift-card:hover {
    z-index: 20;
    opacity: 1;
}

.drift-card__body {
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 20px 40px -22px rgba(15, 27, 61, 0.18);
    overflow: hidden;
    outline: 3px solid transparent;
    transition: outline-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.drift-card:hover .drift-card__body {
    outline-color: #0f62fe;
    box-shadow: 0 30px 55px -20px rgba(15, 98, 254, 0.45);
    transform: scale(1.08);
}

.drift-card__cover {
    height: 76px;
    position: relative;
    background: repeating-linear-gradient(135deg, #dbe4f7 0px, #dbe4f7 8px, #eaf0fc 8px, #eaf0fc 16px);
}

.drift-card__badge {
    position: absolute;
    top: 6px;
    left: 6px;
    background: rgba(255, 255, 255, 0.92);
    color: #0f62fe;
    font-size: 10px;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 20px;
}

.drift-card__info {
    padding: 9px 11px 11px;
}

.drift-card__price {
    font-size: 13px;
    font-weight: 700;
    color: #0f1b3d;
}

.drift-card__line {
    font-size: 11px;
    color: #6b7794;
    margin-top: 3px;
}

.drift-card__verified {
    display: flex;
    gap: 6px;
    margin-top: 6px;
    align-items: center;
}

.drift-card__dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #0f62fe;
    flex-shrink: 0;
}

.drift-card__profile-head {
    display: flex;
    gap: 9px;
    align-items: center;
    padding: 11px 12px 6px;
}

.drift-card__avatar {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    color: #fff;
    font-weight: 700;
    font-size: 13px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.drift-card__profile-meta {
    min-width: 0;
}

.drift-card__profile-name {
    font-size: 13px;
    font-weight: 700;
    color: #0f1b3d;
    white-space: nowrap;
}

.drift-card__profile-role {
    font-size: 11px;
    color: #9aa4bd;
}

.drift-card__info--profile {
    padding: 0 12px 10px;
}

.landing-vignette {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 100vh;
    z-index: 1;
    pointer-events: none;
    background: radial-gradient(ellipse 72% 62% at 50% 40%, rgba(238, 242, 251, 1) 0%, rgba(240, 244, 252, 0.95) 50%, rgba(245, 247, 252, 0) 82%);
}

.landing-content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 100vh;
    pointer-events: none;
}

.landing-nav {
    width: 100%;
    max-width: 1440px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 28px 48px 0;
    gap: 16px;
    pointer-events: auto;
}

.landing-nav__brand-group {
    display: flex;
    align-items: center;
    gap: 16px;
}

.landing-nav__brand {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}

.landing-nav__brand img {
    width: 34px;
    height: 34px;
    object-fit: contain;
}

.landing-nav__brand span {
    font-size: 19px;
    font-weight: 800;
    color: #0f1b3d;
}

.landing-nav__links {
    display: flex;
    gap: 36px;
}

.landing-nav__links a {
    color: #2b3352;
    font-size: 15px;
    font-weight: 500;
    text-decoration: none;
}

.landing-nav__links a:hover {
    color: #0f62fe;
}

.landing-nav__actions {
    display: flex;
    gap: 12px;
}

/* .landing-btn/.landing-profile-btn set their own `display`, which otherwise beats the
   browser's default `[hidden] { display: none }` UA rule (same specificity, author origin
   wins) — without this, the hidden attribute on #landingLoginBtn/#landingProfileBtn has no
   visible effect and both the login link and profile icon show at the same time. */
.landing-nav__actions [hidden] {
    display: none !important;
}

.landing-btn {
    padding: 11px 22px;
    border-radius: 999px;
    border: none;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.15s ease, box-shadow 0.15s ease, opacity 0.15s ease;
}

.landing-btn:active {
    transform: translateY(1px);
}

.landing-btn--ghost {
    border: 1px solid #d7dcec;
    background: #ffffff;
    color: #0f1b3d;
}

.landing-btn--ghost:hover {
    box-shadow: 0 8px 20px -14px rgba(15, 27, 61, 0.3);
}

.landing-btn--primary {
    background: linear-gradient(135deg, #0f62fe 0%, #1f3b73 100%);
    color: #ffffff;
}

.landing-profile-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid #d7dcec;
    background: #ffffff;
    color: #556277;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.landing-profile-btn svg {
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.landing-profile-btn:hover {
    box-shadow: 0 8px 20px -14px rgba(15, 27, 61, 0.3);
}

.landing-profile-btn:active {
    transform: translateY(1px);
}

.landing-btn--primary:hover {
    box-shadow: 0 12px 26px -14px rgba(15, 98, 254, 0.55);
}

.landing-btn--lg {
    padding: 15px 30px;
    font-size: 15px;
    font-weight: 700;
}

.landing-btn--sm {
    padding: 8px 16px;
    font-size: 13px;
}

.landing-hero {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    width: 100%;
    max-width: 820px;
    padding: 64px 24px 0;
    pointer-events: none;
}

.landing-hero__badge,
.landing-hero__ctas,
.landing-search {
    pointer-events: auto;
}

.landing-hero__badge {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #ffffff;
    border: 1px solid #e4e8f4;
    border-radius: 999px;
    padding: 9px 18px;
    box-shadow: 0 8px 20px -14px rgba(15, 27, 61, 0.25);
    font-size: 13px;
    color: #3a4258;
    font-weight: 500;
}

.landing-hero__dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #0f62fe;
    flex-shrink: 0;
}

.landing-hero__title {
    font-size: 60px;
    line-height: 1.08;
    font-weight: 800;
    color: #0f1b3d;
    margin: 26px 0 0;
}

.landing-hero__title span {
    color: #0f62fe;
}

.landing-hero__subtitle {
    font-size: 19px;
    line-height: 1.5;
    color: #5b6480;
    margin: 22px 0 0;
}

.landing-hero__ctas {
    display: flex;
    gap: 14px;
    margin-top: 30px;
}

.landing-search {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 26px;
    background: #ffffff;
    border-radius: 999px;
    padding: 8px 8px 8px 22px;
    width: 620px;
    max-width: 100%;
    box-shadow: 0 16px 34px -20px rgba(15, 27, 61, 0.28);
}

.landing-search__icon {
    width: 16px;
    height: 16px;
    border: 2px solid #9aa4bd;
    border-radius: 50%;
    flex-shrink: 0;
}

.landing-search__input {
    border: none;
    outline: none;
    flex: 1;
    font-size: 15px;
    color: #2b3352;
    background: transparent;
    font-family: inherit;
    min-width: 0;
}

.landing-search__submit {
    padding: 12px 22px;
    border-radius: 999px;
    border: none;
    background: linear-gradient(135deg, #0f62fe 0%, #1f3b73 100%);
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    flex-shrink: 0;
}

.landing-hero__hint {
    font-size: 13px;
    color: #9aa4bd;
    margin-top: 14px;
}

.landing-spacer {
    flex: 1;
    min-height: 420px;
}

.landing-stats {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0 24px 36px;
    font-size: 14px;
    color: #5b6480;
}

.landing-stats__star {
    color: #0f62fe;
    font-size: 14px;
}

@media (max-width: 900px) {
    .landing-nav {
        padding: 20px 20px 0;
    }

    .landing-nav__links {
        display: none;
    }

    .landing-hero__title {
        font-size: 40px;
    }

    .landing-hero__subtitle {
        font-size: 16px;
    }

    .landing-hero__ctas {
        flex-direction: column;
        width: 100%;
    }

    .landing-hero__ctas .landing-btn {
        width: 100%;
    }

    .landing-search {
        padding-left: 16px;
    }
}

@media (max-width: 640px) {
    /* На телефоне карточки тоже плывут — мельче и бледнее, текст поверх остаётся читаемым. */
    .landing-drift {
        opacity: 0.8;
        overflow: hidden;
    }
    .landing-drift .drift-card {
        zoom: 0.72;
    }

    .landing-spacer {
        min-height: 80px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .drift-card {
        animation: none;
    }
}

@media (max-width: 520px) {
    .landing-nav__actions .landing-btn--ghost {
        display: none;
    }

    .landing-nav__brand-group .landing-btn--sm {
        display: none;
    }

    .landing-hero {
        padding-top: 40px;
    }

    .landing-search {
        flex-wrap: wrap;
        border-radius: 20px;
        padding: 12px 16px;
    }

    .landing-search__submit {
        width: 100%;
        margin-top: 8px;
    }
}
