/**
 * Публичная главная / (index.html).
 * Подключать после /css/servicePortal.css (tokens.css через servicePortal).
 */

*, *::before, *::after {
    box-sizing: border-box;
}

body.home-page {
    margin: 0;
    font-family: var(--font-ui);
    background: var(--color-bg-page);
    color: var(--color-text);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    /* Как у шапки: контент от края viewport с фиксированным полем */
    --home-page-edge: 15px;
}

/* ——— Hero ——— */
.home-page .hero {
    position: relative;
    min-height: clamp(520px, 72vh, 680px);
    padding: 0 var(--home-page-edge) 48px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.home-page .hero__bg {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(
            125deg,
            rgba(8, 28, 58, 0.88) 0%,
            rgba(12, 52, 98, 0.72) 42%,
            rgba(21, 101, 192, 0.35) 100%
        ),
        var(--image-header-bg) center/cover no-repeat;
    z-index: 0;
    transform: scale(1.02);
}

.home-page .hero__glow {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.45;
    z-index: 1;
    pointer-events: none;
}

.home-page .hero__glow--a {
    width: 320px;
    height: 320px;
    top: 12%;
    right: -4%;
    background: #4fc3f7;
}

.home-page .hero__glow--b {
    width: 280px;
    height: 280px;
    bottom: 8%;
    left: -6%;
    background: #81c784;
}

.home-page .hero__inner {
    z-index: 2;
    width: 100%;
    max-width: none;
    margin: 0;
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: inherit;
}

/* Шапка на всю ширину окна — углы привязаны к viewport (15px), не к центрированной колонке */
.home-page .hero__nav-slot {
    position: relative;
    width: 100vw;
    max-width: 100vw;
    margin-left: calc(50% - 50vw);
    padding: 0 0 10px;
    box-sizing: border-box;
}

.home-page .hero__content {
    max-width: 640px;
    margin: 0 auto 28px;
    text-align: center;
    padding: 8px 12px 0;
    color: #fff;
}

.home-page .hero__eyebrow {
    margin: 0 0 12px;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.78);
}

.home-page .hero__title {
    margin: 0 0 14px;
    font-family: var(--font-display);
    font-size: clamp(1.85rem, 4.2vw, 2.75rem);
    font-weight: 800;
    line-height: 1.12;
    letter-spacing: -0.02em;
    text-wrap: balance;
}

.home-page .hero__lead {
    margin: 0;
    font-size: clamp(0.95rem, 1.8vw, 1.08rem);
    line-height: 1.55;
    color: rgba(255, 255, 255, 0.86);
    max-width: 52ch;
    margin-left: auto;
    margin-right: auto;
}

.home-page .hero__search-wrap {
    width: 100%;
    max-width: 960px;
    margin: 24px auto 0;
    padding: 0 4px;
}

.home-page .hero__search-card {
    padding: 0;
    background: transparent;
    border: none;
    border-radius: 0;
    box-shadow: none;
    backdrop-filter: none;
}

.home-page .hero__search-grid {
    display: grid;
    grid-template-columns: 1fr 1fr auto;
    gap: 12px;
    align-items: end;
}

.home-page .hero__field {
    display: flex;
    flex-direction: column;
    gap: 6px;
    min-width: 0;
}

.home-page .hero__field-label {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.92);
    text-shadow: 0 1px 8px rgba(0, 0, 0, 0.35);
}

.home-page .hero__field input[type="text"] {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid rgba(255, 255, 255, 0.55);
    border-radius: 12px;
    font-size: 0.95rem;
    font-family: inherit;
    background: rgba(255, 255, 255, 0.94);
    color: var(--color-text-strong);
    transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}

.home-page .hero__field input[type="text"]:focus {
    outline: none;
    border-color: var(--color-primary-bright);
    box-shadow: 0 0 0 3px rgba(25, 118, 210, 0.15);
}

.home-page .hero__field--activity {
    position: relative;
}

.home-page .btn-search.hero__search-submit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 46px;
    padding: 12px 22px;
    border: none;
    border-radius: 12px;
    background: linear-gradient(135deg, #1976d2 0%, #0d47a1 100%);
    color: #fff;
    font-weight: 700;
    font-size: 0.92rem;
    letter-spacing: 0.02em;
    cursor: pointer;
    font-family: inherit;
    white-space: nowrap;
    box-shadow: 0 10px 24px rgba(13, 71, 161, 0.35);
    transition: transform 0.15s, box-shadow 0.2s, filter 0.2s;
}

.home-page .btn-search.hero__search-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 28px rgba(13, 71, 161, 0.42);
    filter: brightness(1.05);
}

.home-page .btn-search__icon {
    display: inline-flex;
    width: 22px;
    height: 22px;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    font-size: 0.85rem;
}

/* ——— FX ticker (шапка) ——— */
.home-page .fx-top {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.92);
    border-radius: var(--radius-xl);
    border: 1px solid rgba(255, 255, 255, 0.5);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
    color: #0b3b66;
    font-weight: 700;
    font-size: 0.72rem;
    line-height: 1.1;
    max-width: 240px;
}

.home-page .fx-top__date {
    font-size: 0.76rem;
}

.home-page .fx-top__line {
    font-weight: 700;
}

.home-page .fx-ticker {
    display: inline-block;
    font-size: 0.8rem;
    color: #37474f;
    padding: 8px 14px;
    background: rgba(255, 255, 255, 0.92);
    border-radius: var(--radius-md);
    border: 1px solid rgba(255, 255, 255, 0.45);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
}

/* ——— Activity combobox ——— */
.home-page .activity-tor-hint {
    font-size: 0.7rem;
    color: rgba(255, 255, 255, 0.78);
    margin: 0;
    line-height: 1.3;
    text-shadow: 0 1px 6px rgba(0, 0, 0, 0.35);
    position: absolute;
    left: 0;
    right: 0;
    top: calc(100% + 4px);
    transform: translateY(0);
    pointer-events: none;
}

.home-page .activity-dropdown {
    display: none;
    position: absolute;
    top: calc(100% + 24px);
    left: 0;
    right: 0;
    max-height: 260px;
    overflow: auto;
    background: var(--color-surface);
    border: 1px solid var(--color-border-subtle);
    border-radius: 14px;
    z-index: 2500;
    box-shadow: 0 18px 48px rgba(15, 35, 55, 0.16);
}

.home-page .activity-dropdown.show {
    display: block;
}

.home-page .activity-item {
    padding: 11px 14px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--color-text-strong);
    border-bottom: 1px solid #f1f5f9;
}

.home-page .activity-item:last-child {
    border-bottom: none;
}

.home-page .activity-item:hover {
    background: var(--color-bg-hero-tint);
}

/* ——— Main ——— */
.home-page .home-main {
    flex: 1;
}

/* ——— Sections ——— */
.home-page .section {
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 40px var(--home-page-edge) 44px;
    box-sizing: border-box;
    scroll-margin-top: 24px;
}

.home-page .section--spotlight {
    padding-top: 28px;
}

.home-page .section--muted {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.65) 0%, rgba(227, 242, 253, 0.35) 100%);
    border-radius: 0;
    max-width: none;
    width: 100%;
    margin: 0;
    padding-left: var(--home-page-edge);
    padding-right: var(--home-page-edge);
}

.home-page .section__head {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px 24px;
    margin-bottom: 24px;
}

.home-page .section__intro {
    flex: 1 1 280px;
    max-width: 640px;
}

.home-page .section__kicker {
    display: inline-block;
    margin-bottom: 8px;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--color-primary);
    background: rgba(21, 101, 192, 0.1);
}

.home-page .section__title {
    margin: 0 0 8px;
    font-size: clamp(1.25rem, 2.4vw, 1.65rem);
    font-weight: 800;
    line-height: 1.2;
    color: var(--color-text-heading);
    letter-spacing: -0.02em;
}

.home-page .section__desc {
    margin: 0;
    font-size: 0.92rem;
    line-height: 1.5;
    color: var(--color-text-muted);
}

.home-page .section__link {
    flex: 0 0 auto;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    color: var(--color-primary);
    text-decoration: none;
    padding-bottom: 2px;
    border-bottom: 2px solid transparent;
    transition: border-color 0.2s, color 0.2s;
}

.home-page .section__link:hover {
    color: var(--color-primary-hover);
    border-bottom-color: var(--color-primary-hover);
}

/* ——— Cards ——— */
.home-page .cards {
    display: grid;
    gap: 18px;
}

/* Карусель секций главной */
.home-page .home-cards-carousel {
    position: relative;
    margin-top: 4px;
}

.home-page .home-cards-carousel__viewport {
    overflow-x: hidden;
    overflow-y: visible;
    margin: 0 44px;
}

.home-page .home-cards-carousel .cards--rail {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: calc((100% - 72px) / 5);
    grid-template-columns: none;
    align-items: start;
    gap: 18px;
    overflow-x: auto;
    overflow-y: visible;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x proximity;
    padding: 4px 2px 16px;
    scrollbar-width: none;
}

.home-page .home-cards-carousel .cards--rail::-webkit-scrollbar {
    display: none;
}

.home-page .home-cards-carousel .cards--rail > .card,
.home-page .home-cards-carousel .cards--rail > article.card {
    scroll-snap-align: start;
    min-width: 0;
    height: auto;
}

.home-page .card--activity .card__img-wrap {
    flex-shrink: 0;
}

/* Популярные экскурсии — карточки витрины (как tour-card) */
.home-page .home-cards-carousel--excursions .cards--excursions {
    grid-auto-columns: minmax(248px, 272px);
    gap: 20px;
}

.home-page .card-exc {
    display: flex;
    flex-direction: column;
    height: 100%;
    border-radius: 14px;
    overflow: hidden;
    text-decoration: none;
    color: inherit;
    background: var(--color-surface);
    border: 1px solid var(--color-border-muted);
    box-shadow: 0 2px 12px rgba(15, 23, 42, 0.08);
    transition: box-shadow 0.22s, transform 0.22s, border-color 0.22s;
}

.home-page .card-exc:hover {
    border-color: rgba(25, 118, 210, 0.35);
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.12);
    transform: translateY(-3px);
}

.home-page .card-exc__media {
    position: relative;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: linear-gradient(145deg, #e8eef5 0%, #eceff1 100%);
}

.home-page .card-exc__img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.home-page .card-exc__img--placeholder {
    width: 100%;
    height: 100%;
    min-height: 120px;
}

.home-page .card-exc__body {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    gap: 8px;
    padding: 12px 14px 14px;
}

.home-page .card-exc__tags {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    min-height: 0;
}

.home-page .card-exc__tag {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 6px;
    font-size: 0.68rem;
    font-weight: 700;
    line-height: 1.3;
    color: #374151;
    background: #f3f4f6;
}

.home-page .card-exc__tag--with-icon {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    max-width: 100%;
}

.home-page .card-exc__tag-icon {
    width: 18px;
    height: 18px;
    object-fit: contain;
    flex-shrink: 0;
}

.home-page .card-exc__tag-text {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.home-page .card-exc__tag--rec {
    color: #fff;
    background: #374b5c;
}

.home-page .card-exc__title {
    margin: 0;
    font-size: 0.92rem;
    font-weight: 800;
    line-height: 1.35;
    color: #1e293b;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.home-page .card-exc__rating {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px 6px;
    font-size: 0.78rem;
}

.home-page .card-exc__stars {
    display: inline-flex;
    gap: 1px;
    letter-spacing: -0.05em;
}

.home-page .card-exc__star {
    color: #d1d5db;
    font-size: 0.82rem;
    line-height: 1;
}

.home-page .card-exc__star--on {
    color: #f59e0b;
}

.home-page .card-exc__rating-val {
    font-weight: 700;
    color: #1e293b;
}

.home-page .card-exc__reviews {
    color: #6b7280;
    font-weight: 500;
}

.home-page .card-exc__org {
    margin: 0;
    font-size: 0.75rem;
    line-height: 1.4;
    color: #6b7280;
}

.home-page .card-exc__org strong {
    color: #374151;
    font-weight: 700;
}

.home-page .card-exc__foot {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 10px;
    margin-top: auto;
    padding-top: 6px;
}

.home-page .card-exc__meta-col {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
    flex: 1 1 auto;
}

.home-page .card-exc__loc,
.home-page .card-exc__dur {
    display: flex;
    align-items: flex-start;
    gap: 4px;
    font-size: 0.72rem;
    line-height: 1.35;
    color: #6b7280;
}

.home-page .card-exc__ico {
    flex-shrink: 0;
    font-size: 0.75rem;
    line-height: 1.2;
}

.home-page .card-exc__price-col {
    flex: 0 0 auto;
    text-align: right;
}

.home-page .card-exc__from {
    display: block;
    font-size: 0.65rem;
    color: #9ca3af;
    line-height: 1.2;
}

.home-page .card-exc__price {
    display: block;
    font-size: 1.05rem;
    font-weight: 800;
    color: #1e293b;
    line-height: 1.2;
    white-space: nowrap;
}

.home-page .home-cards-carousel .cards__empty {
    grid-column: 1 / -1;
    flex: 1 1 100%;
    text-align: center;
    color: #6c757d;
    padding: 24px 12px;
}

.home-page .home-cards-carousel__btn {
    position: absolute;
    top: 50%;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    margin: 0;
    padding: 0;
    border: 1px solid var(--color-border-muted);
    border-radius: 50%;
    background: var(--color-surface);
    color: var(--color-primary);
    font-size: 1.45rem;
    line-height: 1;
    cursor: pointer;
    box-shadow: var(--shadow-card-soft);
    transform: translateY(-50%);
    transition: background 0.15s, opacity 0.15s, box-shadow 0.15s;
}

.home-page .home-cards-carousel__btn:hover:not(:disabled) {
    background: var(--color-bg-hero-tint);
    box-shadow: var(--shadow-card-lift);
}

.home-page .home-cards-carousel__btn:disabled {
    opacity: 0.35;
    cursor: default;
}

.home-page .home-cards-carousel__btn--prev {
    left: 0;
}

.home-page .home-cards-carousel__btn--next {
    right: 0;
}

.home-page .home-cards-carousel:not(.home-cards-carousel--scrollable) .home-cards-carousel__btn {
    opacity: 0.25;
    pointer-events: none;
}

@media (max-width: 1100px) {
    .home-page .home-cards-carousel .cards--rail {
        grid-auto-columns: calc((100% - 54px) / 4);
    }

    .home-page .home-cards-carousel--excursions .cards--excursions {
        grid-auto-columns: minmax(228px, 252px);
    }
}

@media (max-width: 900px) {
    .home-page .hero__search-grid {
        grid-template-columns: 1fr 1fr;
    }

    .home-page .hero__search-submit {
        grid-column: 1 / -1;
        width: 100%;
    }

    .home-page .home-cards-carousel .cards--rail {
        grid-auto-columns: calc((100% - 36px) / 3);
    }

    .home-page .home-cards-carousel--excursions .cards--excursions {
        grid-auto-columns: minmax(220px, 240px);
    }
}

@media (max-width: 720px) {
    .home-page .hero .crm-service-header__left {
        max-width: calc(100vw - 30px);
    }

    .home-page .home-header-brand-nav {
        flex-direction: column;
        gap: 8px;
    }

    .home-page .hero .crm-service-header__inner {
        min-height: 128px;
    }

    .home-page .hero .crm-service-header__tail {
        top: var(--home-page-edge);
        right: max(var(--home-page-edge), env(safe-area-inset-right, 0px));
        max-width: calc(100vw - var(--home-page-edge) * 2);
    }

    .home-page .hero {
        min-height: auto;
        padding-bottom: 32px;
    }

    .home-page .hero__search-grid {
        grid-template-columns: 1fr;
    }

    .home-page .home-cards-carousel__viewport {
        margin: 0 36px;
    }

    .home-page .home-cards-carousel .cards--rail {
        grid-auto-columns: minmax(156px, 168px);
    }

    .home-page .home-cards-carousel--excursions .cards--excursions {
        grid-auto-columns: minmax(248px, 88vw);
    }

    .home-page .section--muted {
        padding-left: var(--home-page-edge);
        padding-right: var(--home-page-edge);
    }
}

@media (max-width: 420px) {
    .home-page .home-cards-carousel .cards--rail {
        grid-auto-columns: minmax(140px, 148px);
    }
}

.home-page .card {
    position: relative;
    background: var(--color-surface);
    border-radius: 18px;
    overflow: hidden;
    border: 1px solid var(--color-border-muted);
    box-shadow: var(--shadow-card-soft);
    transition: border-color 0.25s, box-shadow 0.25s, transform 0.22s;
    cursor: pointer;
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
}

.home-page .card:hover {
    border-color: rgba(25, 118, 210, 0.35);
    box-shadow: var(--shadow-card-lift);
    transform: translateY(-4px);
}

.home-page .card__meta {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 5px 9px;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--color-text-strong);
    background: rgba(255, 255, 255, 0.94);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.home-page .card__star {
    color: var(--star);
    font-size: 0.85rem;
}

.home-page .card__img-wrap {
    position: relative;
    margin: 0;
    border-radius: 0;
    overflow: hidden;
    aspect-ratio: 4 / 5;
    background: linear-gradient(145deg, #e3f2fd 0%, #eceff1 100%);
}

.home-page .card__info-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 3;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 24px;
    padding: 0 8px;
    border: none;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.94);
    color: var(--color-primary);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
    cursor: help;
    font: inherit;
    line-height: 1;
}

.home-page .card__info-btn--empty {
    opacity: 0.72;
}

.home-page .card__info-label {
    font-size: 0.62rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    line-height: 1;
}

.home-page .card__info-tip {
    position: absolute;
    left: 8px;
    right: 8px;
    bottom: 8px;
    z-index: 4;
    display: none;
    max-height: 46%;
    overflow-y: auto;
    padding: 10px 12px;
    border-radius: 10px;
    background: rgba(15, 23, 42, 0.92);
    color: #fff;
    font-size: 0.75rem;
    font-weight: 500;
    line-height: 1.45;
    text-align: left;
    white-space: normal;
    word-break: break-word;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.28);
    pointer-events: none;
}

.home-page .card__img-wrap:has(.card__info-btn:hover) .card__info-tip,
.home-page .card__img-wrap:has(.card__info-btn:focus-visible) .card__info-tip {
    display: block;
}

.home-page .card__info-btn:hover,
.home-page .card__info-btn:focus-visible {
    background: #fff;
    box-shadow: 0 6px 16px rgba(25, 118, 210, 0.28);
}

.home-page .card__img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.35s ease;
}

.home-page .card:hover .card__img {
    transform: scale(1.04);
}

.home-page .card__body {
    padding: 14px 14px 16px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.home-page .card__name {
    margin: 0 0 6px;
    font-size: 0.92rem;
    font-weight: 700;
    line-height: 1.3;
    color: var(--color-text-heading);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.home-page .card__sub {
    margin: 0;
    margin-top: auto;
    font-size: 0.78rem;
    color: var(--color-text-muted);
    display: flex;
    align-items: center;
    gap: 4px;
    line-height: 1.35;
}

.home-page .card__sub--activity {
    gap: 6px;
    flex-wrap: wrap;
}

.home-page .card__sub-chip {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    min-width: 0;
}

.home-page .card__sub-chip--element span:last-child {
    font-size: 0.92rem;
    font-weight: 800;
    color: var(--color-text-strong);
}

.home-page .card__sub-chip--count {
    font-size: 0.78rem;
    font-weight: 700;
}

.home-page .card__sub-icon {
    font-size: 1.6rem;
    line-height: 1;
    transform: translateY(-0.8px);
}

.home-page .card__sub-icon-img {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.home-page .card__sub-sep {
    opacity: 0.55;
}

.home-page .card__sub .globe {
    font-size: 0.85rem;
}

/* ——— Footer ——— */
.home-page .site-footer {
    background: linear-gradient(180deg, #1a1d23 0%, #12141a 100%);
    color: rgba(255, 255, 255, 0.88);
    padding: 32px var(--home-page-edge) 40px;
    margin-top: auto;
    box-sizing: border-box;
}

.home-page .site-footer__inner {
    width: 100%;
    max-width: none;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.home-page .site-footer__brand {
    font-weight: 800;
    font-size: 1.15rem;
    letter-spacing: 0.02em;
}

.home-page .site-footer__nav {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 18px;
    font-size: 0.8rem;
}

.home-page .site-footer__nav a {
    color: rgba(255, 255, 255, 0.62);
    text-decoration: none;
    transition: color 0.2s;
}

.home-page .site-footer__nav a:hover {
    color: #fff;
}

/* ——— Modal (вход / регистрация) ——— */
.home-page .modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(8, 18, 32, 0.72);
    z-index: 1000;
    justify-content: center;
    align-items: center;
    backdrop-filter: blur(8px);
}

.home-page .modal-content {
    background: var(--color-surface);
    padding: 24px;
    border-radius: 20px;
    width: 100%;
    max-width: 400px;
    position: relative;
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.28);
    margin: 16px;
}

.home-page .close-modal {
    position: absolute;
    top: 12px;
    right: 14px;
    cursor: pointer;
    font-size: 24px;
    color: #bbb;
    line-height: 1;
    border: none;
    background: none;
    padding: 0;
}

.home-page .close-modal:hover {
    color: #666;
}

.home-page .modal-tabs {
    display: flex;
    margin-bottom: 16px;
    border-bottom: 1px solid #eee;
}

.home-page .modal-tabs .tab-btn {
    flex: 1;
    padding: 10px;
    border: none;
    background: none;
    cursor: pointer;
    color: var(--color-text-soft);
    font-size: 14px;
    font-weight: 600;
    font-family: inherit;
}

.home-page .modal-tabs .tab-btn.active {
    color: var(--color-primary);
    border-bottom: 2px solid var(--color-primary);
    margin-bottom: -1px;
}

.home-page .modal-form {
    display: none;
    flex-direction: column;
    gap: 10px;
}

.home-page .modal-form.active {
    display: flex;
}

.home-page .modal-form input,
.home-page .modal-form select {
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: var(--radius-md);
    font-size: 13px;
    outline: none;
    box-sizing: border-box;
    font-family: inherit;
    width: 100%;
}

.home-page .modal-form input:focus,
.home-page .modal-form select:focus {
    border-color: var(--color-primary);
}

.home-page .modal-form > button {
    width: 100%;
    padding: 12px;
    font-size: 14px;
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    font-weight: 600;
    font-family: inherit;
}

.home-page .btn-login-modal {
    background: var(--color-primary);
    color: var(--color-surface);
}

.home-page .btn-reg-modal {
    background: var(--color-success);
    color: var(--color-surface);
}

.home-page .checkbox-row {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: #444;
}

.home-page .checkbox-row input[type="checkbox"] {
    width: auto;
    margin: 0;
}

.home-page #businessBlock {
    display: none;
    flex-direction: column;
    gap: 10px;
}

.home-page #regEmailStatus {
    font-size: 12px;
    margin-top: -4px;
    min-height: 14px;
}

.home-page .password-hint {
    margin-top: -4px;
    margin-bottom: 2px;
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 7px;
    padding: 8px;
    font-size: 11px;
    color: #555;
}

.home-page .password-hint-title {
    font-weight: 600;
    margin-bottom: 4px;
    color: #444;
}

.home-page .password-rule {
    display: block;
    line-height: 1.35;
}

.home-page .rule-ok {
    color: #1e8e3e;
}

.home-page .rule-bad {
    color: #d93025;
}

.home-page .pac-container {
    z-index: 20000 !important;
    font-family: inherit;
    border-radius: var(--radius-md);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

.home-page .pass-wrap {
    position: relative;
    width: 100%;
    display: block;
}

.home-page .pass-wrap input {
    width: 100%;
    margin: 0;
    padding-right: 46px;
    box-sizing: border-box;
}

.home-page .pass-toggle {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    border: 0 !important;
    background: transparent;
    cursor: pointer;
    color: #666;
    font-size: 12px;
    padding: 0;
    appearance: none;
    -webkit-appearance: none;
}

.home-page .pass-toggle:hover {
    color: #333;
}

.home-page .pass-toggle:focus {
    outline: none;
}

.home-page .reg-post-verify {
    flex-direction: column;
    gap: 10px;
    padding-top: 12px;
    margin-top: 8px;
    border-top: 1px solid #e9ecef;
}

.home-page .reg-post-verify[hidden] {
    display: none !important;
}

.home-page .reg-post-verify:not([hidden]) {
    display: flex;
}

.home-page .reg-post-verify__hint {
    margin: 0;
    font-size: 12px;
    color: #444;
    line-height: 1.45;
}

.home-page .reg-verify-status {
    margin: 0;
    font-size: 12px;
    min-height: 16px;
}

/* Шапка внутри hero — не фиксированная, на фоне гор */
.home-page .hero .crm-service-header {
    position: relative;
    z-index: 5;
    width: 100%;
    max-width: none;
    margin: 0;
    background: transparent !important;
    box-shadow: none !important;
}

.home-page .hero .crm-service-header__inner {
    position: relative;
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 0;
    min-height: 72px;
    box-sizing: border-box;
}

/* ГидТур — верхний левый угол: 15px сверху и слева от края окна */
.home-page .hero .crm-service-header__left {
    position: absolute;
    top: var(--home-page-edge);
    left: max(var(--home-page-edge), env(safe-area-inset-left, 0px));
    z-index: 6;
    margin: 0;
    max-width: min(420px, calc(100vw - 280px));
}

.home-page .home-header-brand-nav {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.home-page .hero .crm-service-brand-cluster {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
    flex: 0 0 auto;
}

/* Портал: иконки интерфейсов справа от «ГидТур» */
.home-page .hero .home-portal-nav-grid {
    display: flex !important;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 6px;
    margin: 0 !important;
    justify-content: flex-start;
    align-content: flex-start;
}

.home-page .hero .home-portal-nav-grid a.crm-portal-interface-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: auto;
    height: auto;
    min-width: 0;
    padding: 2px;
    border-radius: 0;
    text-decoration: none;
    background: transparent !important;
    border: none !important;
    backdrop-filter: none;
    box-shadow: none;
    transition: opacity 0.15s, transform 0.15s;
}

.home-page .hero .home-portal-nav-grid a.crm-portal-interface-link:hover {
    background: transparent !important;
    transform: translateY(-1px);
    opacity: 0.85;
}

.home-page .hero .home-portal-nav-grid a.crm-portal-interface-link.portal-nav--active-sector {
    box-shadow: none;
    opacity: 1;
}

.home-page .hero .home-portal-nav-grid a.crm-portal-interface-link.portal-nav--active-sector .crm-portal-interface-link__img {
    filter: brightness(0) invert(1) drop-shadow(0 0 4px rgba(255, 255, 255, 0.75));
}

.home-page .hero .home-portal-nav-grid .crm-portal-interface-link__img {
    width: 26px;
    height: 26px;
}

.home-page .hero .crm-service-brand {
    font-size: 1.45rem;
    font-weight: 800;
    line-height: 1.1;
    color: rgba(255, 255, 255, 0.98);
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.35);
}

.home-page .hero .crm-service-version {
    font-size: 0.68rem;
    font-weight: 500;
    line-height: 1.2;
    color: rgba(255, 255, 255, 0.78);
    opacity: 1;
}

.home-page .hero .crm-service-header__inner > .nav-buttons.site-portal-nav {
    display: none;
}

.home-page .hero .crm-service-header__spacer {
    display: none;
}

/* Правый верхний угол — зеркально «ГидТур»: 15px сверху и справа */
.home-page .hero .crm-service-header__tail {
    position: absolute;
    top: var(--home-page-edge);
    right: max(var(--home-page-edge), env(safe-area-inset-right, 0px));
    left: auto;
    z-index: 6;
    margin: 0;
    padding: 0;
    display: flex;
    align-items: flex-start;
    justify-content: flex-end;
    gap: 10px;
    flex-wrap: wrap;
    max-width: min(56vw, calc(100vw - 180px));
}

.home-page .hero .crm-service-header__fx-cluster {
    align-items: flex-start;
    justify-content: flex-end;
    gap: 8px;
}

.home-page .hero #portalUserBlock {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.home-page .hero .crm-portal-user-stack {
    align-items: flex-end;
    text-align: right;
}

.home-page .hero #portalGuestBlock {
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

.home-page .hero .crm-portal-fx-trigger {
    border: none !important;
    background: transparent !important;
    backdrop-filter: none;
    min-width: 0;
    padding: 2px;
}
