/* =========================================================
   G70 DETAILING v30
   HOME recreated from the user's Figma reference.
   Reference frame ratio: 818 × 1704.
   ========================================================= */

:root {
    --bg: #000000;
    --nav-bg: #222222;
    --text: #ffffff;
    --muted: #929292;
    --gold: #f8d99a;
    --surface: #101415;
    --line: rgba(255,255,255,.09);
    --nav-height: 80px;
}

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

html {
    min-height: 100%;
    background: var(--bg);
    color-scheme: dark;
}

body {
    min-width: 320px;
    min-height: 100vh;
    overflow-x: hidden;
    background: var(--bg);
    color: var(--text);
    font-family:
        "Inter", -apple-system, BlinkMacSystemFont,
        "Segoe UI", sans-serif;
    -webkit-font-smoothing: antialiased;
    -webkit-tap-highlight-color: transparent;
}

button,
input,
select,
textarea {
    font: inherit;
}

button {
    color: inherit;
}

button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
a:focus-visible {
    outline: 2px solid var(--gold);
    outline-offset: 2px;
}

.app,
.content {
    width: min(100%, 600px);
    margin: 0 auto;
}

.app {
    padding-bottom:
        calc(
            var(--nav-height) +
            env(safe-area-inset-bottom)
        );
}

.home {
    padding-bottom: 23px;
    margin-top: -40px;
}

/* =========================
   HERO — Figma proportions
   ========================= */

.hero {
    position: relative;
    width: 100%;
    aspect-ratio: 818 / 1002;
    overflow: hidden;
    border-radius: 0 0 38px 38px;
    background: #080808;
    box-shadow: 0 5px 15px rgba(151, 151, 151, 0.55);
}

.hero-photo {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center top;
    pointer-events: none;
}

.hero-shade {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(
            180deg,
            rgba(0,0,0,.02) 0%,
            rgba(0,0,0,.02) 22%,
            rgba(0,0,0,.16) 42%,
            rgba(0,0,0,.22) 66%,
            rgba(0,0,0,.20) 100%
        );
    pointer-events: none;
}

.hero-header {
    position: absolute;
    z-index: 2;
    top: -15px;
    right: 0;
    left: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding:
        max(58px, calc(env(safe-area-inset-top) + 30px))
        7.6% 0;
    padding-left: 2%;
}

.brand-logo {
    display: block;
    width: 45%;
    height: auto;
}

.profile-top-button {
    display: grid;
    width: 10%;
    min-width: 40px;
    max-width: 56px;
    aspect-ratio: 1;
    place-items: center;
    padding: 0;
    border: 0;
    background: transparent;
    cursor: pointer;
}

.profile-top-button img {
    display: block;
    width: 100%;
    height: 100%;
}

/* Figma title + CTA */

.hero-copy {
    position: absolute;
    z-index: 2;
    inset: 0;
    pointer-events: none;
}

.hero-copy h1 {
    position: absolute;
    top: 26.4%;
    left: 6.5%;
    width: 88%;
    color: #fff;
    font-size: 27px;
    font-weight: 700;
    line-height: 1.24;
    letter-spacing: -.025em;
    text-shadow: 0 2px 10px rgba(0,0,0,.25);
}

.hero-copy h2 {
    position: absolute;
    top: 47.4%;
    left: 6.5%;
    width: 88%;
    color: #838383;
    font-size: 17px;
    font-weight: 700;
    line-height: 1.24;
    letter-spacing: -.025em;
    text-shadow: 0 2px 10px rgba(0,0,0,.25);
}

.hero-booking-button {
    position: absolute;
    bottom: 6.5%;
    left: 6.5%;
    display: flex;
    width: 65.5%;
    height: 10.2%;
    min-height: 54px;
    align-items: center;
    justify-content: space-between;
    padding: 0 5.2%;
    border: 0;
    border-radius: 30px;
    background: var(--gold);
    color: #000;
    font-size: 20px;
    font-weight: 700;
    cursor: pointer;
    z-index: 3;
    pointer-events: auto;
}

.hero-booking-button > span:first-child {
    transform: translateY(-1px);
}

.booking-arrow {
    position: relative;
    width: 20px;
    height: 20px;
    flex: 0 0 auto;
}

.booking-arrow::before,
.booking-arrow::after {
    content: "";
    position: absolute;
    right: 0;
    width: 15px;
    height: 4px;
    border-radius: 4px;
    background: #000;
    transform-origin: right center;
}

.booking-arrow::before {
    top: 55%;
    transform: translateY(-52%) rotate(45deg);
}

.booking-arrow::after {
    top: 45%;
    transform: translateY(-52%) rotate(-45deg);
}

/* =========================
   BENEFITS
   ========================= */

.benefits {
    display: grid;
    min-height: 235px;
    grid-template-columns: repeat(3, 1fr);
    align-items: start;
    padding: 30px 4.5% 18px;
    background: #000;
}

.benefits article {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.benefits img {
    display: block;
    width: 29px;
    height: 28px;
    margin-bottom: 20px;
    object-fit: contain;
}

.benefits article:nth-child(2) img {
    width: 36px;
}

.benefits p {
    color: var(--muted);
    font-size: 13px;
    font-weight: 700;
    line-height: 1.02;
}

/* =========================
   PROMOTION CARD
   ========================= */

.promo-card {
    position: relative;
    display: block;
    width: 94%;
    aspect-ratio: 690 / 236;
    margin: 3px auto 0px;
    overflow: hidden;
    border: 0;
    border-radius: 29px;
    background: #111;
    text-align: left;
    cursor: pointer;
    box-shadow: 0 5px 15px rgba(151, 151, 151, 0.55);
    transform: translateY(-60px);
}

.promo-photo {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.promo-shade {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(
            90deg,
            rgba(0,0,0,.40) 0%,
            rgba(0,0,0,.13) 58%,
            rgba(0,0,0,.03) 100%
        );
}

.promo-copy {
    position: absolute;
    z-index: 2;
    top: 28%;
    left: 4.8%;
    display: flex;
    flex-direction: column;
    color: #fff;
    transform: translateY(-20px);
}

.promo-copy strong {
    font-size: 20px;
    font-weight: 700;
    line-height: 1.27;
}

.promo-copy small {
    margin-top: 18px;
    font-size: 15px;
    font-weight: 700;
}

.promo-discount {
    position: absolute;
    z-index: 3;
    top: 17%;          /* НЕ ТРОГАЕМ */
    right: 5%;         /* НЕ ТРОГАЕМ */
    display: grid;
    place-items: center;
    width: 75px;       /* ширина */
    height: 28px;      /* высота */
    padding: 0;
    border-radius: 10px;
    background: #aa0000;
    color: #fff;
    font-size: 18px;
    font-weight: 700;
    transform: translateY(-5px);
}

/* =========================
   BOTTOM NAVIGATION
   ========================= */

.bottom-nav {
    position: fixed;
    z-index: 100;
    left: 50%;
    bottom: 0;
    display: grid;
    width: min(100%, 600px);
    height:
        calc(
            var(--nav-height) +
            env(safe-area-inset-bottom)
        );
    grid-template-columns: repeat(3, 1fr);
    transform: translateX(-50%);
    padding:
        10px 8%
        max(7px, env(safe-area-inset-bottom));
    background: var(--nav-bg);
}

.nav-item {
    display: flex;
    min-width: 0;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    border: 0;
    background: transparent;
    color: #fff;
    cursor: pointer;
}

.nav-icon {
    display: flex;
    width: 36px;
    height: 36px;
    flex: 0 0 36px;
    align-items: center;
    justify-content: center;
}

.nav-icon img {
    display: block;
    object-fit: contain;
}

#homeNavButton .nav-icon img {
    width: 26px;
    height: 26px;
}

#servicesButton .nav-icon img {
    width: 29px;
    height: 29px;
}

#promotionsButton .nav-icon img {
    width: 34px;
    height: 34px;
}

.nav-label {
    display: block;
    height: 15px;
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    line-height: 15px;
    letter-spacing: .015em;
    text-align: center;
    white-space: nowrap;
}

.nav-item.active .nav-label {
    color: #fff;
}

/* Existing JS hooks not visible on Home */

.hidden-action,
.visually-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0,0,0,0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

/* =========================================================
   Existing dynamic screens.
   Temporary styling retained until each Figma page is supplied.
   ========================================================= */

.content {
    min-height: 100vh;
    padding:
        max(24px, env(safe-area-inset-top))
        14px
        calc(
            var(--nav-height) +
            28px +
            env(safe-area-inset-bottom)
        );
}

.content > h2 {
    margin: 4px 0 19px;
    font-size: 28px;
    line-height: 1.05;
    letter-spacing: -.04em;
}

.content > p {
    margin-bottom: 12px;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.5;
}

.service-card,
.appointment-card,
.promotion-card {
    margin-bottom: 11px;
    overflow: hidden;
    border-radius: 17px;
    background:
        linear-gradient(
            145deg,
            #1b1b1b,
            transparent 55%
        ),
        #1b1b1b;
}

.service-card {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 17px;
}

.service-card h3,
.appointment-card h3,
.promotion-content h3 {
    font-size: 17px;
    line-height: 1.2;
}

.service-card p,
.appointment-card p,
.promotion-description {
    color: var(--muted);
    font-size: 12px;
    line-height: 1.45;
}

.service-price,
.appointment-price {
    margin: 0;
    color: var(--gold);
    font-size: 18px;
    font-weight: 850;
    line-height: 1.2;
}

.appointment-meta {
    display: flex;
    width: 100%;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 5px;
}

.appointment-meta .appointment-status {
    position: relative;
    top: 0;
    right: 0;
}

.service-duration {
    color: var(--muted);
    font-size: 11px;
}

.service-booking-button,
.primary-button,
.profile-save-button {
    width: 100%;
    min-height: 48px;
    padding: 12px 15px;
    border: 0;
    border-radius: 12px;
    background: var(--gold);
    color: #111;
    font-weight: 850;
    cursor: pointer;
}

.car-form,
.profile-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 22px;
}

.form-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-field > span {
    font-size: 11px;
    font-weight: 700;
}

.car-form input,
.car-form select,
С
.form-input,
.profile-form input {
    width: 100%;
    min-height: 49px;
    padding: 12px 13px;
    border: 1px solid var(--line);
    border-radius: 12px;
    outline: 0;
    background: #1b1b1b;
    color: var(--text);
}

.car-form textarea {
    min-height: 95px;
    resize: vertical;
}

.car-form label:not(.form-field) {
    display: flex;
    gap: 8px;
    color: var(--muted);
    font-size: 11px;
    line-height: 1.4;
}

.car-form label:not(.form-field) input[type="checkbox"] {
    width: 18px;
    min-height: 18px;
    height: 18px;
    accent-color: var(--gold);
}

.car-form a {
    color: var(--gold);
}

.cars-list {
    display: flex;
    flex-direction: column;
}

.car-actions {
    display: flex;
    gap: 8px;
    margin-top: 9px;
}

.car-actions button {
    flex: 1;
    padding: 10px;
    border: 1px solid var(--line);
    border-radius: 11px;
    background: #1b1b1b;
}

.car-actions button:last-child {
    color: #ff5050;
}

.booking-slots {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 7px;
}

.slot-button {
    min-height: 42px;
    padding: 9px 4px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #1b1b1b;
    font-weight: 700;
    box-shadow: 0 2px 5px rgba(151, 151, 151, 0.55);
}

.slot-button.selected {
    border-color: var(--gold);
    background: var(--gold);
    color: #111;
}

.slots-message,
.booking-phone-hint,
.appointments-empty,
.promotions-empty {
    color: var(--muted);
    font-size: 11px;
    line-height: 1.4;
}

.slots-message {
    grid-column: 1 / -1;
}

.appointments-section-title {
    margin: 25px 0 10px;
    color: var(--text);
    font-size: 17px;
    font-weight: 800;
    line-height: 1.2;
    text-transform: none;
}

.appointment-card {
    display: flex;
    flex-direction: column;
    gap: 9px;
    padding: 16px;
}

.appointment-datetime {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 12px;
    color: var(--muted);
    font-size: 11px;
}

.appointment-status {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 6px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 850;
    line-height: 1;
    white-space: nowrap;
}

.status-new {
    background: rgba(248,217,154,.12);
    color: var(--gold);
}

.status-confirmed {
    background: rgba(121,213,150,.1);
    color: #8ee0a8;
}

.status-completed {
    background: rgba(130,170,255,.09);
    color: #aac5ff;
}

.status-cancelled {
    background: rgba(255,115,115,.1);
    color: #ff5050;
}

.appointment-comment {
    padding-top: 9px;
    border-top: 1px solid var(--line);
}

.appointment-cancel-button {
    width: 100%;
    padding: 10px;
    border: 1px solid rgba(255,115,115,.25);
    border-radius: 11px;
    background: transparent;
    color: #ff5050;
}

.promotion-image {
    display: block;
    width: 100%;
    height: 180px;
    object-fit: cover;
}

.promotion-content {
    padding: 17px;
}

.promotion-content h3 {
    margin-bottom: 8px;
}

.promotion-description {
    margin-bottom: 11px;
}

.promotion-period {
    color: var(--muted);
    font-size: 10px;
}

.profile-message {
    min-height: 18px;
    color: var(--muted);
    font-size: 11px;
}

.profile-message-success {
    color: #79d596;
}

.profile-message-error {
    color: #ff7373;
}

[hidden] {
    display: none !important;
}

@media (max-width: 370px) {
    .hero-header {
        padding-top:
            max(
                45px,
                calc(env(safe-area-inset-top) + 22px)
            );
    }

    .hero-booking-button {
        min-height: 48px;
    }

    .benefits {
        min-height: 205px;
        padding-top: 25px;
    }

    .benefits img {
        margin-bottom: 15px;
    }

    .promo-card {
        margin-bottom: 35px;
    }

    .booking-slots {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        transition: none !important;
    }
}

.profile-top-button {
    position: relative !important;
    z-index: 100 !important;
    pointer-events: auto !important;
    cursor: pointer;
}

.profile-top-button img {
    pointer-events: none;
}

/* =========================================================
   ОБЩАЯ АНИМАЦИЯ КНОПОК
   ========================================================= */
button {
    transition:
        transform 0.17s ease,
        filter 0.17s ease,
        opacity 0.17s ease;
    -webkit-tap-highlight-color: transparent;
}

/* Момент нажатия */
button:active {
    transform: scale(0.97);
    filter: brightness(0.92);
}
.hero-booking-button {
    transition:
        transform 0.12s ease,
        filter 0.12s ease;
}
.hero-booking-button.is-pressed {
    transform: translateY(2px) scale(0.94);
    filter: brightness(0.84);
}

.promo-card {
    transition:
        transform 0.12s ease,
        filter 0.12s ease;
}

.promo-card.is-pressed {
    transform: translateY(-60px) scale(0.96);
    filter: brightness(0.82);
}

/* =========================================================
   BOTTOM NAV — active section
   ========================================================= */

.bottom-nav .nav-item {
    opacity: 0.38;
    transition:
        transform 0.12s ease,
        filter 0.12s ease;
}

.bottom-nav .nav-item.active {
    opacity: 1;
}

.bottom-nav .nav-item img,
.bottom-nav .nav-item span {
    opacity: 1;
}

/* Акция — удержание без прыжка */
.promo-card:active {
    transform: translateY(-60px) scale(0.96);
    filter: brightness(0.78);
}

.promo-card.is-pressed {
    transform: translateY(-60px) scale(0.96);
    filter: brightness(0.78);
}

/* =========================================================
   G70 — SERVICES PAGE
   ========================================================= */

.content:has(.services-page) {
    padding:
        max(24px, env(safe-area-inset-top))
        3%
        calc(
            var(--nav-height) +
            26px +
            env(safe-area-inset-bottom)
        );
}

.services-page {
    width: 100%;
    min-height: 100%;
    padding: 0 0 24px;
}

.services-title {
    margin: 4px 0 16px;
    font-size: 28px;
    line-height: 1.05;
}

.services-header,
.services-logo,
.services-profile-button {
    display: none !important;
}


/* =========================================================
   УСЛУГИ — КАТЕГОРИИ
   ========================================================= */

.service-category-tabs {
    display: flex;
    width: 100%;
    gap: 7px;
    margin: 0 0 14px;
    overflow-x: auto;
    scrollbar-width: none;
}

.service-category-tabs::-webkit-scrollbar {
    display: none;
}

.service-category-tab {
    flex: 0 0 auto;
    padding: 6px 10px;
    border: 1px solid rgba(255,255,255,.16);
    border-radius: 999px;
    background: #171717;
    color: #aaa;
    font-size: 14px;
    font-weight: 700;
}

.service-category-tab.active {
    border-color: var(--gold);
    background: var(--gold);
    color: #111;
    opacity: 1;
}


/* =========================================================
   УСЛУГИ — СПИСОК КАРТОЧЕК
   ========================================================= */

.services-catalog {
    display: flex;
    width: 100%;
    flex-direction: column;
    gap: 13px;
}


/* =========================================================
   УСЛУГИ — КАРТОЧКА
   Размер карточки фиксирован и не зависит от текста.
   ========================================================= */

.service-catalog-card {
    position: relative;
    display: grid;
    width: 100%;
    height: 126px;
    min-height: 126px;
    max-height: 126px;
    grid-template-columns: 116px minmax(0, 1fr);
    gap: 0;
    padding: 5px;
    overflow: hidden;
    isolation: isolate;
    border: none;
    outline: none;
    border-radius: 21px;
    background: #1b1b1b;
    color: #fff;
    text-align: left;
    cursor: pointer;
    box-shadow: 0 3px 10px rgba(151, 151, 151, 0.55);
}


/* =========================================================
   УСЛУГИ — ФОТО
   Оставлено по последним выставленным пользователем размерам.
   ========================================================= */

.service-catalog-image {
    display: block;
    width: 116px;
    height: 116px;
    min-width: 116px;
    aspect-ratio: 1 / 1;
    border-radius: 18px;
    object-fit: cover;
    object-position: center;
    pointer-events: none;
}


/* =========================================================
   УСЛУГИ — ТЕКСТОВАЯ ОБЛАСТЬ
   Текст не управляет положением цены и кнопки.
   ========================================================= */

.service-catalog-body {
    position: relative;
    min-width: 0;
    height: 100%;
    padding: 7px 9px 6px 14px;
    pointer-events: auto;
}


/* =========================================================
   УСЛУГИ — НАЗВАНИЕ
   Отдельная область, допускает две строки.
   ========================================================= */

.service-catalog-name {
    display: -webkit-box;
    margin: 0;
    padding-right: 0;
    overflow: hidden;
    color: #fff;
    font-size: 18px;
    font-weight: 700;
    line-height: 1.08;
    pointer-events: none;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-clamp: 2;
}


/* =========================================================
   УСЛУГИ — ОПИСАНИЕ
   ========================================================= */

.service-catalog-description {
    display: -webkit-box;
    margin-top: 6px;
    overflow: hidden;
    color: #a9a9a9;
    font-size: 11px;
    font-weight: 700;
    line-height: 1.02;
    pointer-events: none;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    line-clamp: 3;
}


/* =========================================================
   УСЛУГИ — ЦЕНА
   Зафиксирована независимо от названия и описания.
   ========================================================= */

.service-catalog-price {
    position: absolute;
    left: 14px;
    bottom: 12px;
    display: block;
    margin: 0;
    padding: 0;
    color: var(--gold);
    font-size: 20px;
    font-weight: 700;
    line-height: 1;
    pointer-events: none;
}


/* =========================================================
   УСЛУГИ — КНОПКА «ЗАПИСАТЬСЯ»
   Зафиксирована независимо от текста и цены.
   ========================================================= */

.service-card-book-button {
    position: absolute;
    z-index: 5;
    right: 4px;
    bottom: 4px;
    margin: 0;
    padding: 10px 16px;
    border: 1.5px solid var(--gold);
    border-radius: 999px;
    background: transparent;
    color: var(--gold);
    font-size: 14px;
    font-weight: 800;
    line-height: 1;
    cursor: pointer;
    pointer-events: auto;
    touch-action: manipulation;
    transform-origin: center;
    transition:
        transform 0.12s ease,
        filter 0.12s ease,
        background-color 0.12s ease,
        color 0.12s ease;
}

/* Не даём общему button:active вмешиваться в эту анимацию. */
.service-card-book-button:active {
    transform: none;
    filter: none;
}

.service-card-book-button.is-pressed {
    background: var(--gold);
    color: #111;
    transform: scale(0.94);
    filter: brightness(0.84);
}


/* =========================================================
   УСЛУГИ — ПУСТОЙ СПИСОК
   ========================================================= */

.services-empty {
    padding: 28px 8px;
    color: var(--muted);
    font-size: 13px;
    text-align: center;
}


/* =========================================================
   BOOKING — ВЫБОР НЕСКОЛЬКИХ УСЛУГ
   ========================================================= */

.booking-services-section {
    margin-bottom: 20px;
}

.booking-services-section > h3 {
    margin: 0 0 12px;
    font-size: 18px;
}

.booking-service-list {
    max-height: 390px;
    overflow-y: auto;
    padding: 1px 2px 8px;
}

/* В режиме выбора услуг возвращаем обводку только выбранной карточке. */
.booking-service-list .service-catalog-card.selected {
    box-shadow:
        0 0 0 1px var(--gold),
        0 3px 10px rgba(151,151,151,.35);
}

.service-select-mark {
    position: absolute;
    z-index: 6;
    top: 8px;
    right: 8px;
    display: grid;
    width: 24px;
    height: 24px;
    place-items: center;
    border: 1px solid rgba(255,255,255,.28);
    border-radius: 50%;
    color: transparent;
    font-size: 15px;
    font-weight: 900;
}

.service-catalog-card.selected .service-select-mark {
    border-color: var(--gold);
    background: var(--gold);
    color: #111;
}

.booking-service-summary {
    position: sticky;
    z-index: 20;
    bottom: calc(var(--nav-height) + env(safe-area-inset-bottom) + 8px);
    margin-top: 10px;
    padding: 12px 14px;
    border: 1px solid rgba(248,217,154,.35);
    border-radius: 14px;
    background: rgba(20,20,20,.96);
    color: var(--gold);
    font-size: 13px;
    font-weight: 800;
    backdrop-filter: blur(10px);
}

/* ===== BOOKING: CARS ===== */

.booking-car-field {
    width: 100%;
    margin-top: 24px;
}

.booking-car-heading {
    margin: 0 0 12px;
    font-size: 17px;
    font-weight: 800;
    line-height: 1.2;
    color: var(--text);
}

.booking-car-cards {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.booking-car-card {
    display: flex;
    width: 100%;
    min-height: 68px;
    align-items: center;
    justify-content: space-between;
    padding: 11px 16px;
    border: none;
    border-radius: 17px;
    background: #171717;
    text-align: left;
}

.booking-car-info {
    display: flex;
    flex-direction: column;
    gap: 7px;
}

.booking-car-mark {
    display: grid;
    width: 24px;
    height: 24px;
    min-width: 24px;
    place-items: center;
    border: 1px solid rgba(255,255,255,.28);
    border-radius: 50%;
    color: transparent;
    font-size: 15px;
    font-weight: 900;
}

.booking-car-mark::after {
    content: "✓";
}

.booking-car-card.selected .booking-car-mark {
    border-color: var(--gold);
    background: var(--gold);
    color: #111;
}

.booking-car-name {
    color: #fff;
    font-size: 16px;
    font-weight: 800;
    line-height: 1.2;
}

.booking-car-details {
    color: var(--muted);
    font-size: 13px;
    font-weight: 600;
    line-height: 1.2;
}

.booking-car-details {
    display: flex;
    align-items: center;
    gap: 9px;
}

.booking-car-plate {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 25px;
    padding: 2px 9px;
    border: 1px solid #666;
    border-radius: 6px;
    color: #fff;
    font-size: 14px;
    font-weight: 800;
    line-height: 1;
    letter-spacing: 0.7px;
    background: #11111100;
}

.booking-car-color {
    color: var(--muted);
    font-size: 13px;
    font-weight: 600;
}

.booking-date-picker {
    position: relative;
    width: 100%;
}

.booking-date-button {
    width: 100%;
    height: 58px;
    padding: 0 18px;
    border: 1px solid #11111100;
    border-radius: 16px;
    background: #1b1b1b;
    color: var(--muted);
    font-size: 16px;
    font-weight: 600;
    text-align: left;
}

.booking-date-button.selected {
    color: #fff;
}

.booking-date-input {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    margin: 0;
    opacity: 0;
    cursor: pointer;
}

.booking-datetime-section {
    margin-top: 28px;
}

.booking-date-field > span,
.booking-time-field > span,
.booking-comment-field > span {
    font-size: 17px;
    font-weight: 800;
    line-height: 1.2;
}

.booking-date-field > span,
.booking-comment-field > span {
    display: block;
    margin-bottom: 5px;
}

.booking-time-field {
    margin-top: 18px;
}

/* ===== BOOKING: VERTICAL SPACING ===== */

.booking-datetime-section {
    margin-top: 28px;
}

.booking-time-field {
    margin-top: 10px;
}

.booking-comment-section {
    margin-top: 28px;
}

.booking-date-field > span,
.booking-time-field > span,
.booking-comment-field > span {
    display: block;
    margin-bottom: 5px;
}

.booking-form button[type="submit"]:disabled {
    background: var(--gold);
    color: #111;
    opacity: 0.38;
    cursor: default;
    transform: none;
    filter: none;
}

.booking-form button[type="submit"]:not(:disabled) {
    background: var(--gold);
    color: #111;
    opacity: 1;
}

.booking-comment-field textarea {
    width: 100%;
    min-height: 72px;
    box-sizing: border-box;
    padding: 14px 16px;

    border: 1px solid #ffffff00;
    border-radius: 16px;

    background: #1b1b1b;
    color: var(--text);

    font-size: 15px;
    line-height: 1.35;

    resize: none;
    outline: none;
}

.booking-comment-field textarea::placeholder {
    color: var(--muted);
    opacity: 1;
}

.booking-comment-field textarea:focus {
    border-color: var(--gold);
}

.booking-comment-section {
    margin-bottom: 18px;
}

.bottom-nav.keyboard-open {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}
/* =========================================================
   PROFILE DASHBOARD
   ========================================================= */

.content:has(.profile-page) {
    padding-right: 20px;
    padding-left: 20px;
}

.profile-page {
    width: 100%;
}

.profile-page-title {
    margin: 4px 0 18px;
    font-size: 28px;
    font-weight: 800;
    line-height: 1.05;
    letter-spacing: -.04em;
}

.profile-user-card {
    display: flex;
    min-height: 104px;
    align-items: center;
    gap: 16px;
    padding: 17px 18px;
    border: 1px solid var(--line);
    border-radius: 20px;
    background: #1b1b1b;
    box-shadow: 0 5px 15px rgba(151, 151, 151, 0.55);
}

.profile-user-avatar {
    display: grid;
    width: 64px;
    height: 64px;
    min-width: 64px;
    place-items: center;
    overflow: hidden;
    border: 1px solid rgba(248,217,154,.55);
    border-radius: 50%;
    background: rgba(248,217,154,.06);
}

.profile-user-avatar img {
    display: block;
    width: 100%;
    height: 100%;
}

.profile-user-info {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 7px;
}

.profile-user-name {
    overflow: hidden;
    color: var(--text);
    font-size: 20px;
    font-weight: 800;
    line-height: 1.15;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.profile-user-phone {
    color: var(--muted);
    font-size: 14px;
    font-weight: 600;
}

.profile-dashboard-section {
    margin-top: 30px;
}

.profile-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 11px;
}

.profile-section-header h3 {
    margin: 0;
    color: var(--text);
    font-size: 18px;
    font-weight: 800;
    line-height: 1.2;
}

.profile-section-action {
    flex: 0 0 auto;
    padding: 5px 0;
    border: 0;
    background: transparent;
    color: var(--gold);
    font-size: 13px;
    font-weight: 750;
}

.profile-cars-list,
.profile-appointments-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.profile-car-card,
.profile-appointment-card {
    display: flex;
    width: 100%;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 15px 16px;
    border: 0;
    border-radius: 17px;
    background: #1b1b1b;
    color: var(--text);
    text-align: left;
}

.profile-car-card {
    min-height: 76px;
}

.profile-car-info,
.profile-appointment-body {
    display: flex;
    min-width: 0;
    flex: 1;
    flex-direction: column;
}

.profile-car-info {
    gap: 7px;
}

.profile-car-name {
    overflow: hidden;
    font-size: 16px;
    font-weight: 800;
    line-height: 1.2;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.profile-car-details {
    display: flex;
    align-items: center;
    gap: 9px;
    min-height: 25px;
}

.profile-car-plate {
    display: inline-flex;
    min-height: 25px;
    align-items: center;
    justify-content: center;
    padding: 2px 9px;
    border: 1px solid #666;
    border-radius: 4px;
    background: #11111100;
    color: #fff;
    font-size: 12px;
    font-weight: 800;
    line-height: 1;
    letter-spacing: .7px;
}

.profile-car-color,
.profile-appointment-car {
    color: var(--muted);
    font-size: 13px;
    font-weight: 600;
}

.profile-row-arrow {
    flex: 0 0 auto;
    color: #777;
    font-size: 30px;
    font-weight: 300;
    line-height: 1;
}

.profile-appointment-card {
    min-height: 128px;
}

.profile-appointment-body {
    gap: 6px;
}

.profile-appointment-status {
    display: inline-flex;
    align-self: flex-start;
    padding: 5px 9px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 800;
    line-height: 1;
}

.profile-appointment-datetime {
    margin-top: 2px;
    font-size: 15px;
    font-weight: 800;
    line-height: 1.25;
}

.profile-appointment-services {
    overflow: hidden;
    color: #e9e9e9;
    font-size: 13px;
    font-weight: 650;
    line-height: 1.3;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.profile-dashboard-empty,
.profile-dashboard-message {
    margin: 0;
    padding: 15px 16px;
    border-radius: 17px;
    background: #1b1b1b;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.4;
}

.profile-dashboard-error {
    color: #ff5050;
}

.appointment-car {
    margin: 0;
    color: var(--text);
    font-size: 15px;
    font-weight: 700;
    line-height: 1.25;
}

.appointment-datetime {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 12px;
    color: var(--muted);
    font-size: 14px;
    font-weight: 600;
    line-height: 1.25;
}
/* =========================================================
   PROMOTIONS — visual cards
   ========================================================= */

.promotions-page {
    width: 100%;
}

.promotions-title {
    margin: 4px 0 18px;
    font-size: 28px;
    line-height: 1.05;
    letter-spacing: -.04em;
}

.promotions-list {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.promotion-card.promotion-card-featured {
    position: relative;
    margin: 0;
    overflow: hidden;
    border-radius: 18px;
    background: #1b1b1b;
    box-shadow: 0 10px 28px rgba(0,0,0,.22);
}

.promotion-card-featured .promotion-media {
    position: relative;
    height: 205px;
    overflow: hidden;
    background: #1b1b1b;
}

.promotion-card-featured .promotion-image {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.promotion-card-featured .promotion-image-shade {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(
        180deg,
        rgba(0,0,0,.02) 35%,
        rgba(0,0,0,.42) 100%
    );
}

.promotion-card-featured .promotion-discount {
    position: absolute;
    top: 13px;
    right: 13px;
    display: inline-flex;
    min-width: 62px;
    height: 34px;
    align-items: center;
    justify-content: center;
    padding: 0 12px;
    border-radius: 11px;
    background: #aa0000;
    color: #ffffff;
    font-size: 16px;
    font-weight: 850;
    line-height: 1;
}

.promotion-card-featured .promotion-content {
    padding: 15px 16px 16px;
    background: linear-gradient(
        180deg,
        #1b1b1b 100%
    );
}

.promotion-card-featured .promotion-content h3 {
    margin: 0 0 7px;
    color: var(--text);
    font-size: 18px;
    font-weight: 800;
    line-height: 1.18;
    letter-spacing: -.02em;
}

.promotion-card-featured .promotion-description {
    margin: 0;
    color: #a5a5a5;
    font-size: 13px;
    line-height: 1.4;
}

.promotion-card-featured .promotion-period {
    display: flex;
    align-items: center;
    gap: 9px;
    margin-top: 13px;
    color: #d4d4d4;
    font-size: 12px;
    font-weight: 600;
    line-height: 1.2;
}

.promotion-card-featured .promotion-calendar-icon {
    display: inline-flex;
    width: 22px;
    height: 22px;
    flex: 0 0 22px;
    align-items: center;
    justify-content: center;
    color: var(--gold);
}

.promotion-card-featured .promotion-calendar-icon svg {
    display: block;
    width: 20px;
    height: 20px;
}

@media (max-width: 380px) {
    .promotion-card-featured .promotion-media {
        height: 190px;
    }

    .promotion-card-featured .promotion-content h3 {
        font-size: 17px;
    }
}

/* HOME PROMOTION — same geometry as service card */
.promo-card.home-promotion-card {
    display:grid; width:94%; height:126px; min-height:126px; max-height:126px;
    aspect-ratio:auto; grid-template-columns:116px minmax(0,1fr); gap:0;
    padding:5px; overflow:hidden; isolation:isolate; border:none;
    border-radius:21px; background:#1b1b1b; color:#fff; text-align:left;
    box-shadow:0 3px 10px rgba(151,151,151,.55);
}
.home-promotion-image {
    display:block; width:116px; height:116px; min-width:116px; aspect-ratio:1/1;
    border-radius:18px; object-fit:cover; object-position:center; pointer-events:none;
}
.home-promotion-body { position:relative; min-width:0; height:116px; padding:7px 9px 6px 14px; }
.home-promotion-discount {
    position:absolute; top:6px; right:7px; display:inline-flex; min-width:46px;
    height:23px; align-items:center; justify-content:center; padding:0 7px;
    border-radius:8px; background:#aa0000; color:#fff; font-size:12px;
    font-weight:850; line-height:1;
}
.home-promotion-title {
    display:-webkit-box; margin:0; padding-right:52px; overflow:hidden; color:#fff;
    font-size:16px; font-weight:800; line-height:1.08; letter-spacing:-.02em;
    -webkit-box-orient:vertical; -webkit-line-clamp:2; line-clamp:2;
}
.home-promotion-card:not(.has-discount) .home-promotion-title { padding-right:0; }
.home-promotion-description {
    display:-webkit-box; margin:6px 0 0; overflow:hidden; color:#a5a5a5;
    font-size:11px; line-height:1.25; -webkit-box-orient:vertical;
    -webkit-line-clamp:2; line-clamp:2;
}
.home-promotion-period {
    position:absolute; right:9px; bottom:7px; left:14px; display:flex; min-width:0;
    align-items:center; gap:6px; color:#d4d4d4; font-size:10px; font-weight:600;
    line-height:1; white-space:nowrap;
}
.home-promotion-calendar-icon {
    display:inline-flex; width:17px; height:17px; flex:0 0 17px;
    align-items:center; justify-content:center; color:var(--gold);
}
.home-promotion-calendar-icon svg { display:block; width:17px; height:17px; }

/* =========================================================
   HOME PROMOTION v74 — full-photo card
   ========================================================= */

.promo-card.home-promotion-card {
    position: relative;
    display: block;
    width: 94%;
    height: 126px;
    min-height: 126px;
    max-height: 126px;
    padding: 0;
    overflow: hidden;
    border: 0;
    border-radius: 21px;
    background: #111;
    box-shadow: 0 3px 10px rgba(151,151,151,.55);
}

.home-promotion-image {
    position: absolute;
    inset: 0;
    display: block;
    width: 100%;
    height: 100%;
    min-width: 0;
    border-radius: 0;
    object-fit: cover;
    object-position: center;
    pointer-events: none;
}

.promo-card.home-promotion-card::after {
    content: "";
    position: absolute;
    z-index: 1;
    inset: 0;
    pointer-events: none;
    background:
        linear-gradient(
            0deg,
            rgba(0,0,0,.92) 0%,
            rgba(0,0,0,.78) 24%,
            rgba(0,0,0,.50) 48%,
            rgba(0,0,0,.16) 72%,
            rgba(0,0,0,.08) 100%
        );
}

.home-promotion-body {
    position: absolute;
    z-index: 2;
    inset: 0;
    height: auto;
    padding: 13px 14px 11px;
    pointer-events: none;
}

.home-promotion-title {
    display: -webkit-box;
    width: calc(100% - 72px);
    margin: 0;
    padding: 0;
    overflow: hidden;
    color: #fff;
    font-size: 17px;
    font-weight: 800;
    line-height: 1.08;
    letter-spacing: -.02em;
    text-shadow: 0 2px 8px rgba(0,0,0,.8);
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-clamp: 2;
}

.home-promotion-card:not(.has-discount) .home-promotion-title {
    width: 100%;
    padding-right: 0;
}

.home-promotion-discount {
    position: absolute;
    top: 11px;
    right: 12px;
    display: inline-flex;
    min-width: 54px;
    height: 27px;
    align-items: center;
    justify-content: center;
    padding: 0 9px;
    border-radius: 9px;
    background: #aa0000;
    color: #fff;
    font-size: 14px;
    font-weight: 850;
    line-height: 1;
    box-shadow: 0 2px 8px rgba(0,0,0,.25);
}

.home-promotion-description {
    display: none;
}

.home-promotion-period {
    position: absolute;
    right: 14px;
    bottom: 11px;
    left: 14px;
    display: flex;
    min-width: 0;
    align-items: center;
    gap: 7px;
    color: #f0f0f0;
    font-size: 11px;
    font-weight: 650;
    line-height: 1;
    white-space: nowrap;
    text-shadow: 0 2px 7px rgba(0,0,0,.9);
}

.home-promotion-calendar-icon {
    display: inline-flex;
    width: 18px;
    height: 18px;
    flex: 0 0 18px;
    align-items: center;
    justify-content: center;
    color: var(--gold);
}

.home-promotion-calendar-icon svg {
    display: block;
    width: 18px;
    height: 18px;
}



/* =========================================================
   HOME PROMOTION v76 — admin-selected full-photo card
   ========================================================= */
.promo-card.home-promotion-card[hidden] {
    display: none !important;
}

.promo-card.home-promotion-card {
    height: 170px;
    min-height: 170px;
    max-height: 170px;
}

.home-promotion-discount {
    top: 13px;
    right: 13px;
    min-width: 62px;
    height: 34px;
    padding: 0 12px;
    border-radius: 11px;
    font-size: 16px;
}

.home-promotion-title {
    width: calc(100% - 92px);
    font-size: 18px;
}

.home-promotion-period {
    bottom: 13px;
    font-size: 12px;
}

/* =========================
   REGISTRATION
   ========================= */

   .registration-form .form-field > span {
    font-size: 15px;
    font-weight: 800;
    line-height: 1.2;
}

.registration-form a {
    color: var(--gold);
}


/* Кнопка регистрации */

.registration-form .primary-button {
    display: flex;
    width: 100%;
    min-height: 52px;
    align-items: center;
    justify-content: center;
    margin-top: 14px;
    padding: 0 18px;
    text-align: center;
    font-size: 15px;
    font-weight: 850;
    line-height: 1;
    background: var(--gold);
    color: #111;
}

.registration-consent {
    display: flex;
    width: 100%;
    box-sizing: border-box;
    align-items: flex-start;
    gap: 12px;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.4;
    cursor: pointer;
}

.registration-consent {
    position: relative;

    display: grid;
    grid-template-columns: 24px minmax(0, 1fr);
    column-gap: 12px;

    width: 100%;
    box-sizing: border-box;

    align-items: start;

    color: var(--muted);
    font-size: 14px;
    line-height: 1.4;

    cursor: pointer;
}


/* Настоящий checkbox остаётся для логики формы,
   но визуально его не показываем */

.registration-consent input[type="checkbox"] {
    position: absolute;

    width: 1px;
    height: 1px;

    opacity: 0;
    pointer-events: none;
}


/* Та же галочка, что в карточке услуги */

.registration-consent-mark {
    display: grid;

    width: 24px;
    height: 24px;

    place-items: center;

    border: 1px solid rgba(255,255,255,.28);
    border-radius: 50%;

    color: transparent;

    font-size: 15px;
    font-weight: 900;

    box-sizing: border-box;
}


/* Выбранное состояние */

.registration-consent input[type="checkbox"]:checked
+ .registration-consent-mark {
    border-color: var(--gold);
    background: var(--gold);
    color: #111;
}


.registration-consent-text {
    display: block;
    min-width: 0;
}


.registration-consent-text a {
    color: var(--gold);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.registration-consent-text {
    display: block;
    flex: 1;
    min-width: 0;
}

.registration-consent-text a {
    color: var(--gold);
    text-decoration: underline;
    text-underline-offset: 2px;
}

/* =========================================================
   REGISTRATION — consent controls
   Same visual mark as service selection.
   ========================================================= */

.registration-form .registration-consent {
    position: relative;
    display: grid;
    grid-template-columns: 24px minmax(0, 1fr);
    column-gap: 12px;
    width: 100%;
    box-sizing: border-box;
    align-items: center;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.4;
    cursor: pointer;
}

.registration-form .registration-consent input[type="checkbox"] {
    position: absolute;
    width: 1px;
    height: 1px;
    min-height: 0;
    margin: 0;
    padding: 0;
    opacity: 0;
    pointer-events: none;
    appearance: none;
    -webkit-appearance: none;
}

.registration-form .registration-consent-mark {
    display: grid;
    width: 24px;
    height: 24px;
    min-width: 24px;
    place-items: center;
    box-sizing: border-box;
    border: 1px solid rgba(255,255,255,.28);
    border-radius: 50%;
    background: transparent;
    color: transparent;
    font-size: 15px;
    font-weight: 900;
    line-height: 1;
}

.registration-form .registration-consent input[type="checkbox"]:checked
+ .registration-consent-mark {
    border-color: var(--gold);
    background: var(--gold);
    color: #111;
}

.registration-form .registration-consent-text {
    display: block;
    min-width: 0;
}

.registration-form .registration-consent-text a {
    color: var(--gold);
    text-decoration: underline;
    text-underline-offset: 2px;
}

/* Проверка доступа Owner/Admin перед показом клиентского интерфейса */

body.admin-check-pending .app {
    visibility: hidden;
}

.admin-check-loader {
    display: none;
}

body.admin-check-pending .admin-check-loader {
    position: fixed;
    inset: 0;
    z-index: 99999;

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

    background: #000;
}

.admin-check-spinner {
    width: 36px;
    height: 36px;

    border: 3px solid rgba(255, 255, 255, 0.2);
    border-top-color: #fff;
    border-radius: 50%;

    animation: admin-check-spin 0.8s linear infinite;
}

@keyframes admin-check-spin {
    to {
        transform: rotate(360deg);
    }
}