/* ================================================================
   PIONEER LOGISTIC — BASE.CSS
   Базовые стили, типографика, reset
   ================================================================ */

/* ----- FONTS ----- */
@font-face {
    font-family: 'Archaica';
    src: url('../fonts/Archaica.woff2') format('woff2'),
         url('../fonts/Archaica.woff') format('woff');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Seenonim';
    src: url('../fonts/Seenonim.woff2') format('woff2'),
         url('../fonts/Seenonim.woff') format('woff');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

/* ----- RESET / NORMALIZE ----- */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: 'Seenonim', Arial, sans-serif;
    font-size: clamp(0.9rem, 1.5vw, 1.1rem);
    line-height: 1.6;
    color: #ffffff;
    background-color: #00060E;
    min-width: 360px;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Изображения */
img,
picture,
video,
canvas,
svg {
    display: block;
    max-width: 100%;
    height: auto;
}

/* Ссылки */
a {
    color: inherit;
    text-decoration: none;
    transition: opacity 0.2s ease;
}

a:hover {
    opacity: 0.8;
}

/* Кнопки */
button {
    font-family: inherit;
    font-size: inherit;
    background: none;
    border: none;
    cursor: pointer;
    color: inherit;
}

/* Списки */
ul,
ol {
    list-style: none;
}

/* Заголовки */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Archaica', Georgia, serif;
    font-weight: 400;
    line-height: 1.2;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

h1 {
    font-size: clamp(2.5rem, 5vw, 6rem);
}

h2 {
    font-size: clamp(1.5rem, 4vw, 3rem);
}

h3 {
    font-size: clamp(1.2rem, 2.5vw, 2rem);
}

/* Параграфы */
p {
    margin-bottom: 1em;
}

p:last-child {
    margin-bottom: 0;
}

/* ----- UTILITY CLASSES ----- */

/* Скрыть визуально, но оставить для скринридеров */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Контейнер */
.container {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding-left: clamp(20px, 4vw, 60px);
    padding-right: clamp(20px, 4vw, 60px);
}

/* Декоративные элементы */
.decor {
    pointer-events: none;
    user-select: none;
}

/* ----- FOCUS STATES (доступность) ----- */
:focus-visible {
    outline: 2px solid #d4af37;
    outline-offset: 2px;
}

/* ----- SELECTION ----- */
::selection {
    background-color: #d4af37;
    color: #00060E;
}
main {
    overflow: hidden;
}

/* ================================================================
   REQUEST MODAL — форма заявки
   ================================================================ */

body.is-modal-open {
    overflow: hidden;
}

/* затемнение + тёмный фон */
.request-modal {
    position: fixed;
    inset: 0;
    z-index: 30;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: clamp(16px, 4vw, 40px);

    background: rgba(0, 6, 14, 0.8);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

/* фон внутри модалки — тёмный градиент + menu-back */
.request-modal__dialog {
    position: relative;
    width: min(50vw, 1200px);
    min-width: 360px;
    max-width: 1200px;

    padding: clamp(20px, 3vw, 32px);
    border-radius: 14px;
    overflow: hidden;

    background:
        radial-gradient(circle at top, rgba(72, 175, 196, 0.25), transparent 55%),
        linear-gradient(135deg, #00060E 0%, #021426 50%, #00060E 100%);
    color: #ffffff;

    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6);
}

/* слой с текстурой */
.request-modal__dialog::before {
    content: "";
    position: absolute;
    inset: 0;
    background: url("/assets/img/menu-back.webp") center/cover no-repeat;
    opacity: 0.35;
    pointer-events: none;
}

.request-modal__form,
.request-modal__title,
.request-modal__close {
    position: relative;
    z-index: 1; /* поверх фонового слоя */
}

/* показ/скрытие */
.request-modal--open {
    opacity: 1;
    visibility: visible;
}

.request-modal__title {
    margin: 0 0 24px;
    font-family: 'Archaica', Georgia, serif;
    font-size: clamp(22px, 2.2vw, 28px);
    text-transform: uppercase;
    letter-spacing: 0.18em;
    color: #ffffff;
}

/* сетка полей: 2 колонки */
.request-modal__grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px 18px;
}

.request-modal__field {
    display: flex;
    flex-direction: column;
}

.request-modal__field--full {
    grid-column: 1 / -1;
}

.request-modal__label {
    margin-bottom: 6px;
    font-family: 'Seenonim', Arial, sans-serif;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.8);
}

/* сами поля — белый с 10% прозрачности, белая обводка */
.request-modal__input,
.request-modal__textarea {
    width: 100%;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.8);
    background: rgba(255, 255, 255, 0.1);
    padding: 20px 12px;

    font-family: 'Seenonim', Arial, sans-serif;
    font-size: 14px;
    color: #ffffff;
}

.request-modal__input::placeholder,
.request-modal__textarea::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

.request-modal__textarea {
    resize: vertical;
    min-height: 80px;
}

/* чекбокс-согласие */
.request-modal__agree {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 18px;
    margin-bottom: 10px;
    font-size: 13px;
    font-family: 'Seenonim', Arial, sans-serif;
    color: rgba(255, 255, 255, 0.85);
}

.request-modal__agree a {
    color: #48AFC4;
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
}

/* скрываем системный чекбокс */
.request-modal__checkbox {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

/* кружок чекбокса */
.request-modal__checkbox-visual {
    flex: 0 0 26px;
    height: 26px;
    border-radius: 50%;
    border: 2px solid rgba(72, 175, 196, 0.7);
    background: transparent;
    position: relative;
    box-sizing: border-box;
    transition: background 0.2s ease, border-color 0.2s ease;
}

/* галочка */
.request-modal__checkbox-visual::after {
    content: "";
    position: absolute;
    inset: 0;
    margin: 6px 7px;
    border-radius: 2px;
    border-left: 2px solid transparent;
    border-bottom: 2px solid transparent;
    transform: rotate(-45deg);
    transition: border-color 0.2s ease;
}

/* состояние checked */
.request-modal__checkbox:checked + .request-modal__checkbox-visual {
    background: #0061ff; /* контрастный лаймовый круг */
    border-color: #0061ff;
}

.request-modal__checkbox:checked + .request-modal__checkbox-visual::after {
    border-color: #fcfcfcff; /* тёмная галочка */
}

/* кнопка — тот же стиль, что "Отправить заявку" (btn btn--primary уже описан в CSS кейсов) */
.request-modal__submit {
    width: 100%;
    margin-top: 8px;
}

/* крестик */
.request-modal__close {
    position: absolute;
    top: 16px;
    right: 18px;

    width: 34px;
    height: 34px;
    border-radius: 50%;

    display: flex;
    align-items: center;
    justify-content: center;

    font-size: 20px;
    line-height: 1;
    color: #ffffff;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.request-modal__close:hover {
}

/* мобильный адаптив */
@media (max-width: 767px) {
    .request-modal__dialog {
        width: 100%;
        min-width: 0;
        max-width: 520px;
    }

    .request-modal__grid {
        grid-template-columns: 1fr;
    }

    .request-modal__field--full {
        grid-column: auto;
    }
}

@media (max-width: 480px) {
    .request-modal__dialog {
        max-height: 100%;
        overflow-y: auto;
    }
}
.btn--primary {
    min-height: 60px;
}

/* ================================================================
   SCROLL ANIMATIONS — Анимации появления при скролле
   ================================================================ */

/* Начальное состояние элементов (до появления на экране) */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

/* Активное состояние (когда элемент виден) */
.fade-in.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* Вариация: появление слева */
.fade-in-left {
    opacity: 0;
    transform: translateX(-50px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.fade-in-left.is-visible {
    opacity: 1;
    transform: translateX(0);
}

/* Вариация: появление справа */
.fade-in-right {
    opacity: 0;
    transform: translateX(50px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.fade-in-right.is-visible {
    opacity: 1;
    transform: translateX(0);
}

/* Задержки для последовательного появления элементов */
.fade-in.delay-1,
.fade-in-left.delay-1,
.fade-in-right.delay-1 {
    transition-delay: 0.1s;
}

.fade-in.delay-2,
.fade-in-left.delay-2,
.fade-in-right.delay-2 {
    transition-delay: 0.2s;
}

.fade-in.delay-3,
.fade-in-left.delay-3,
.fade-in-right.delay-3 {
    transition-delay: 0.3s;
}