:root {
    color-scheme: light;
}

body.booking-body {
    margin: 0;
    font-family: "Inter", "Segoe UI", sans-serif;
    background: #f6f8fb;
    color: #1f2937;
}

.booking-step[hidden] {
    display: none !important;
}

.booking-root {
    max-width: 880px;
    margin: 0 auto;
    padding: 24px 16px 48px;
}

.booking {
    background: #ffffff;
    border-radius: 18px;
    box-shadow: 0 24px 60px rgba(15, 23, 42, 0.08);
    padding: 32px clamp(16px, 4vw, 40px);
    display: grid;
    gap: 28px;
}

.booking__header {
    text-align: center;
    display: grid;
    gap: 12px;
}

.booking__title {
    margin: 0;
    font-size: clamp(1.6rem, 2.6vw, 2rem);
    font-weight: 700;
    color: #111827;
}

.booking__subtitle {
    margin: 0;
    font-size: clamp(0.95rem, 1.6vw, 1.05rem);
    color: #6b7280;
    line-height: 1.6;
}

.booking-form {
    display: grid;
    gap: 36px;
}


.booking-progress__list {
    list-style: none;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 10px;
    padding: 0;
    margin: 0;
}

.booking-progress__item {
    position: relative;
    display: grid;
    grid-template-columns: auto 1fr;
    align-items: center;
    gap: 10px;
    padding: 5px 5px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.9);
    color: #4b5563;
    font-weight: 600;
    border: 1px solid rgba(218, 73, 0, 0.25);
    transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
    cursor: pointer;
}

.booking-progress__item.is-active {
    background: linear-gradient(135deg, #ff6f2a, #da4900);
    color: #fff;
    transform: translateY(-1px);
}

.booking-progress__item.is-done {
    background: rgba(218, 73, 0, 0.12);
    color: #da4900;
}

.booking-progress__index {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(218, 73, 0, 0.18);
    color: #da4900;
    font-weight: 700;
    font-size: 0.95rem;
}

.booking-progress__item.is-active .booking-progress__index {
    background: rgba(255, 255, 255, 0.24);
    color: #fff;
}

.booking-progress__item.is-done .booking-progress__index {
    background: rgba(218, 73, 0, 0.22);
    color: #da4900;
}

.booking-progress__label {
    font-size: 0.75rem;
}

.booking-progress__item::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    pointer-events: none;
    box-shadow: 0 10px 28px rgba(218, 73, 0, 0.15);
    opacity: 0;
    transition: opacity 0.2s ease;
}

.booking-progress__item.is-active::after {
    opacity: 1;
}

.booking-progress__item.is-done:hover,
.booking-progress__item.is-active:hover {
    transform: translateY(-2px);
}

.booking-progress__item:not(.is-active):not(.is-done):hover {
    background: rgba(255, 244, 240, 0.96);
}

.booking-progress__item.is-disabled {
    opacity: 0.5;
    cursor: default;
    pointer-events: none;
}

[data-booking-sts-field] {
    display: none !important;
}

[data-booking-tire-storage] {
    display: none;
}

[data-booking-tire-storage].is-active {
    display: grid;
}

@media (max-width: 640px) {
    .booking-progress {
        overflow-x: auto;
        padding-inline: clamp(12px, 5vw, 20px);
        scroll-snap-type: x mandatory;
        -webkit-overflow-scrolling: touch;
    }

    .booking-progress__list {
        display: inline-flex;
        gap: 12px;
        padding-bottom: 6px;
        min-width: max-content;
    }

    .booking-progress__item {
        min-width: 160px;
        scroll-snap-align: start;
        padding: 8px 10px;
        gap: 8px;
    }

    .booking-progress__label {
        font-size: 0.75rem;
    }

    .booking-progress__index {
        width: 28px;
        height: 28px;
        font-size: 0.8rem;
    }
}

.booking-step {
    display: grid;
    gap: 24px;
}

.booking-step.is-active {
    animation: bookingStepFade 0.25s ease;
}

@keyframes bookingStepFade {
    from { opacity: 0; transform: translateY(4px); }
    to { opacity: 1; transform: translateY(0); }
}

.booking-step__title {
    margin: 0;
    font-size: clamp(1.2rem, 2vw, 1.35rem);
    font-weight: 600;
    color: #111827;
    font-size: 18px;
}

.booking-hint {
    margin: 0;
    font-size: 0.95rem;
    color: #6b7280;
}

.booking-hint--note {
    font-size: 0.85rem;
    color: #4b5563;
}

.booking-btn {
    border: none;
    border-radius: 12px;
    padding: 12px 18px;
    font-size: 0.98rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s ease, box-shadow 0.2s ease;
    background: #e5e7eb;
    color: #1f2937;
}

.booking-btn[disabled] {
    cursor: not-allowed;
    opacity: 0.5;
}

.booking-btn:hover:not([disabled]) {
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.12);
}

.booking-btn--primary {
    background: linear-gradient(135deg, #ff6f2a, #da4900);
    color: #fff;
}

.booking-btn--accent {
    background: linear-gradient(135deg, #ff7b3f, #ff5722);
    color: #fff;
}

.booking-step__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.booking-field {
    display: grid;
    gap: 6px;
    width: 100%;
}

.booking-field--inline {
    max-width: 240px;
}

.booking-field__label {
    font-size: 0.9rem;
    font-weight: 600;
    color: #374151;
}

.booking-field__label--required::after {
    content: ' *';
    color: #da4900;
    font-weight: 700;
}

.booking-input {
    border: 1px solid #d1d5db;
    border-radius: 12px;
    padding: 12px 14px;
    font-size: 1rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    color: #111827;
    accent-color: #da4900;
}

.booking-input:focus {
    outline: none;
    border-color: #da4900;
    box-shadow: 0 0 0 3px rgba(218, 73, 0, 0.18);
}

.booking-input[type="date"],
.booking-input[type="time"] {
    color: #111827;
}

.booking-input[type="date"]::-webkit-datetime-edit,
.booking-input[type="date"]::-webkit-datetime-edit-text,
.booking-input[type="date"]::-webkit-datetime-edit-month-field,
.booking-input[type="date"]::-webkit-datetime-edit-day-field,
.booking-input[type="date"]::-webkit-datetime-edit-year-field,
.booking-input[type="time"]::-webkit-datetime-edit,
.booking-input[type="time"]::-webkit-datetime-edit-hour-field,
.booking-input[type="time"]::-webkit-datetime-edit-minute-field,
.booking-input[type="time"]::-webkit-datetime-edit-text {
    color: #111827;
}

.booking-input[type="date"]::-webkit-calendar-picker-indicator,
.booking-input[type="time"]::-webkit-calendar-picker-indicator {
    filter: invert(51%) sepia(73%) saturate(3101%) hue-rotate(360deg) brightness(94%) contrast(94%);
}

.booking-input--textarea {
    resize: vertical;
    min-height: 96px;
}

.booking-branch {
    display: grid;
    gap: 20px;
}

.booking-branch__map {
    width: 100%;
    min-height: 280px;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.08);
}

.booking-branch__list {
    display: grid;
    gap: 16px;
}

.booking-branch__list-items {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: 12px;
}

.booking-branch-card {
    border-radius: 14px;
    border: 1px solid rgba(15, 23, 42, 0.08);
    transition: box-shadow 0.2s ease, transform 0.2s ease;
    background: #fff;
    position: relative;
}

.booking-branch-card.is-active {
    border-color: #da4900;
    transform: translateY(-1px);
}

.booking-branch-card.is-active::after {
    content: '';
    position: absolute;
    top: 12px;
    right: 12px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #da4900;
    mask: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16"><path fill="white" d="M6.173 13.114a1 1 0 0 1-1.414 0l-3.59-3.589a1 1 0 1 1 1.414-1.415L6 10.526l6.414-6.415a1 1 0 0 1 1.414 1.415l-7.24 7.588a1 1 0 0 1-1.415 0z"/></svg>') center/12px 12px no-repeat;
}

.booking-branch-card__action {
    width: 100%;
    padding: 16px;
    display: grid;
    gap: 6px;
    text-align: left;
    background: none;
    border: none;
    cursor: pointer;
}

.booking-branch-card__name {
    font-size: 1.05rem;
    font-weight: 600;
    color: #111827;
}

.booking-branch-card__address {
    font-size: 0.95rem;
    color: #6b7280;
}

.booking-services {
    display: grid;
    gap: 12px;
}

.booking-services__category {
    border-radius: 16px;
    box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.08);
    background: #fff;
    overflow: hidden;
}

.booking-services__summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 16px;
    cursor: pointer;
    font-weight: 600;
    color: #1f2937;
}

.booking-services__summary-count {
    min-width: 32px;
    text-align: center;
    font-size: 0.85rem;
    color: #da4900;
}

.booking-services__items {
    display: grid;
    padding: 0 16px 16px;
    gap: 12px;
}

.booking-service-card {
    display: block;
    border-radius: 14px;
    padding: 5px 20px 5px 20px;
    border: 1px solid rgba(15, 23, 42, 0.08);
    cursor: pointer;
    transition: box-shadow 0.2s ease, transform 0.2s ease;
    position: relative;
}

.booking-service-card:hover {
    border-color: rgba(218, 73, 0, 0.35);
}

.booking-service-card input[type="checkbox"] {
    display: none;
}

.booking-service-card.is-selected {
    border-color: #da4900;
    transform: translateY(-1px);
}
.booking-service-card.is-selected .booking-service-card__title {
    color: #da4900;
}

.booking-service-card.is-selected::after {
    content: '';
    position: absolute;
    top: 7px;
    left: 2px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #da4900;
    mask: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16"><path fill="white" d="M6.173 13.114a1 1 0 0 1-1.414 0l-3.59-3.589a1 1 0 1 1 1.414-1.415L6 10.526l6.414-6.415a1 1 0 0 1 1.414 1.415l-7.24 7.588a1 1 0 0 1-1.415 0z"/></svg>') center/12px 12px no-repeat;
    pointer-events: none;
}

.booking-service-card.is-disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.booking-service-card__body {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.booking-service-card__title {
    font-weight: 600;
    color: #111827;
}

.booking-services__items .booking-service-card__title{
    font-size: 14px;
}

.booking-service-card__meta {
    font-size: 0.7rem;
    color: #000
}

.booking-slots {
    display: grid;
    gap: 18px;
}

.booking-slots__grid {
    display: grid;
    gap: 14px;
}

.booking-slots__group {
    display: grid;
    gap: 12px;
}

.booking-slots__group-title {
    margin: 0;
    font-size: 0.9rem;
    color: #6b7280;
}

.booking-slots__list {
    display: grid;
    gap: 8px;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
}

.booking-slot-btn {
    border: none;
    border-radius: 12px;
    padding: 12px;
    background: #f3f4f6;
    font-size: 12px;
    cursor: pointer;
    transition: background-color 0.2s ease, transform 0.2s ease;
    color: #111827;
}

.booking-slot-btn:hover {
    background: #e5e7eb;
}

.booking-slot-btn.is-selected {
    background: linear-gradient(135deg, #ff6f2a, #da4900);
    color: #fff;
    transform: translateY(-1px);
}

.booking-slots__empty {
    border-radius: 14px;
    background: #f9fafb;
    padding: 24px;
    text-align: center;
    color: #6b7280;
    font-size: 0.95rem;
}

.booking-grid {
    display: grid;
    gap: 16px;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.booking-field--wide {
    grid-column: 1 / -1;
}

.booking-feedback {
    margin: 0;
    padding: 14px 18px;
    border-radius: 12px;
    background: rgba(218, 73, 0, 0.1);
    color: #da4900;
    font-size: 0.95rem;
}

.booking-feedback.app-error {
    background: rgba(239, 68, 68, 0.12);
    color: #b91c1c;
}

.booking-summary {
    display: grid;
    gap: 18px;
}

.booking-summary__block {
    border-radius: 14px;
    padding: 16px;
    background: #f9fafb;
    display: grid;
    gap: 6px;
}

.booking-summary__title {
    margin: 0;
    font-size: 0.95rem;
    font-weight: 600;
    color: #111827;
}

.booking-summary__value {
    margin: 0;
    font-size: 0.98rem;
    color: #374151;
}

.booking-summary__meta {
    margin: -5px 0 0;
    font-size: 0.88rem;
    color: #6b7280;
}

.booking-summary__list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: 6px;
    font-size: 0.95rem;
    color: #374151;
}

.booking-summary__list--compact {
    gap: 4px;
}

.booking-summary__label {
    font-weight: 600;
    color: #6b7280;
}

.booking-success {
    padding: 20px;
    color: #111827;
    margin: 0 auto;
    max-width: 500px;
    margin-bottom: 50px;
    text-align: center;
}

.booking-success__title {
    margin: 0 0 8px;
    font-size: clamp(1.25rem, 2.2vw, 1.45rem);
    font-weight: 700;
    color: #da4900;
}

.booking-success__text {
    margin: 0;
    color: #4b5563;
    font-size: 0.98rem;
}

.booking-success__details {
    display: grid;
    gap: 10px;
    padding: 16px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.8);
}

.booking-success__label {
    font-weight: 600;
    color: #111827;
}

.booking-success__services {
    margin: 4px 0 0;
    padding-left: 20px;
    color: #1f2937;
}

.booking-success__note {
    margin: 0;
    font-size: 0.95rem;
    color: #4b5563;
}

@media (max-width: 640px) {
    .booking {
        padding: 24px 16px;
    }

    .booking-branch__map {
        min-height: 220px;
    }

    .booking-slot-btn {
        font-size: 0.9rem;
        padding: 10px;
    }
}
