/*
 * Repair booking wizard (/quote) — site bundle only.
 *
 * Loaded as the LAST <link> in resources/views/site.blade.php so it wins the
 * cascade over style.css / responsive.css at equal specificity, no !important
 * needed. Every rule is scoped under .rb-wizard: nothing here may touch the
 * theme's own pages. Bump the ?v=N query string in site.blade.php when editing.
 */

.rb-wizard {
    --rb-accent: #71b745;
    --rb-accent-dark: #5da036;
    --rb-accent-soft: rgba(113, 183, 69, 0.12);
    --rb-ink: #041424;
    --rb-muted: #686868;
    --rb-border: rgba(4, 20, 36, 0.1);
    --rb-surface: #f3f8fd;
    --rb-radius: 10px;
}

/* The theme sets .style-three .contact-contetn h4 to a fixed 36px. */
.rb-wizard .contact-contetn h4 {
    font-size: clamp(24px, 6vw, 36px);
    margin-bottom: 10px;
}

.rb-wizard .contact-contetn p {
    color: var(--rb-muted);
    margin-bottom: 24px;
}

/* Overrides .add-white-bg's 39px 37px, which wastes a third of a small viewport. */
.rb-wizard .rb-card {
    padding: 32px 28px;
    border-radius: var(--rb-radius);
}

/* Fixed floor so swapping steps never jumps the page height. */
.rb-wizard .rb-step-body {
    min-height: 340px;
    padding-top: 4px;
}

/* ---------------------------------------------------------------- progress */

.rb-wizard .rb-progress {
    margin-bottom: 26px;
}

.rb-wizard .rb-progress .progress {
    height: 6px;
    background: var(--rb-surface);
    border-radius: 99px;
    overflow: hidden;
}

.rb-wizard .rb-progress .progress-bar {
    background: var(--rb-accent);
    transition: width 0.35s ease;
}

.rb-wizard .rb-steps {
    list-style: none;
    margin: 18px 0 0;
    padding: 0;
    gap: 4px;
}

.rb-wizard .rb-steps li {
    flex: 1 1 0;
    position: relative;
    text-align: center;
    min-width: 0;
}

.rb-wizard .rb-steps li::after {
    content: '';
    position: absolute;
    top: 14px;
    left: 50%;
    width: 100%;
    height: 2px;
    background: var(--rb-border);
    z-index: 0;
}

.rb-wizard .rb-steps li:last-child::after {
    display: none;
}

.rb-wizard .rb-steps li.is-done::after {
    background: var(--rb-accent);
}

.rb-wizard .rb-step-pip {
    position: relative;
    z-index: 1;
    display: block;
    margin: 0 auto;
    width: 28px;
    height: 28px;
    line-height: 24px;
    border-radius: 50%;
    border: 2px solid var(--rb-border);
    background: var(--rb-surface);
    color: var(--rb-muted);
    font-size: 12px;
    font-weight: 700;
    padding: 0;
    transition: 0.25s ease;
}

.rb-wizard .rb-step-label {
    display: block;
    margin-top: 6px;
    font-size: 12px;
    font-weight: 600;
    color: var(--rb-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.rb-wizard .rb-steps li.is-done .rb-step-pip {
    background: var(--rb-accent);
    border-color: var(--rb-accent);
    color: #fff;
}

.rb-wizard .rb-steps li.is-current .rb-step-pip {
    background: #fff;
    border-color: var(--rb-accent);
    color: var(--rb-accent);
    box-shadow: 0 0 0 4px var(--rb-accent-soft);
}

.rb-wizard .rb-steps li.is-current .rb-step-label,
.rb-wizard .rb-steps li.is-done .rb-step-label {
    color: var(--rb-ink);
}

.rb-wizard button.rb-step-pip:hover {
    border-color: var(--rb-accent-dark);
}

.rb-wizard .rb-steps-compact {
    margin: 14px 0 0;
    font-size: 14px;
    font-weight: 600;
    color: var(--rb-ink);
}

.rb-wizard .rb-steps-compact span {
    color: var(--rb-muted);
    font-weight: 400;
}

/* ------------------------------------------------------- selectable cards */

.rb-wizard .rb-step-title {
    font-size: 18px;
    font-weight: 700;
    color: var(--rb-ink);
    margin-bottom: 4px;
}

.rb-wizard .rb-step-hint {
    font-size: 13px;
    color: var(--rb-muted);
    margin-bottom: 18px;
}

/* The 2px border matches .style-three .single-input-box input, so cards and
   text inputs read as one system. */
.rb-wizard .rb-option {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    min-height: 112px;
    padding: 22px 14px;
    background: #fff;
    border: 2px solid var(--rb-border);
    border-radius: var(--rb-radius);
    color: var(--rb-ink);
    font-weight: 600;
    font-size: 15px;
    text-align: center;
    cursor: pointer;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease,
        background-color 0.2s ease;
}

.rb-wizard .rb-option:hover {
    border-color: var(--rb-accent);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(4, 20, 36, 0.06);
}

.rb-wizard .rb-option.is-selected {
    border-color: var(--rb-accent);
    background: var(--rb-accent-soft);
    box-shadow: 0 0 0 3px rgba(113, 183, 69, 0.18);
}

.rb-wizard .rb-option:focus-visible {
    outline: 2px solid var(--rb-accent);
    outline-offset: 2px;
}

.rb-wizard .rb-option__icon {
    font-size: 26px;
    color: var(--rb-accent);
    line-height: 1;
}

.rb-wizard .rb-option__label {
    line-height: 1.35;
    word-break: break-word;
}

.rb-wizard .rb-option__tick {
    position: absolute;
    top: 8px;
    right: 10px;
    font-size: 15px;
    color: var(--rb-accent);
    opacity: 0;
    transition: opacity 0.2s ease;
}

.rb-wizard .rb-option.is-selected .rb-option__tick {
    opacity: 1;
}

/* Single-choice list rows — the model step, where a brand can carry dozens.
   One column on phones, two from md up, matching the issues grid. */
.rb-wizard .rb-list {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 10px;
    align-content: start;
}

@media (min-width: 768px) {
    .rb-wizard .rb-list {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* Height-capped so a long catalog never pushes Continue off the page. The
   negative margin cancels the padding that keeps focus rings and the scrollbar
   off the row borders. */
.rb-wizard .rb-list--scroll {
    max-height: 360px;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    padding: 3px 10px 3px 3px;
    margin: -3px -10px -3px -3px;
}

.rb-wizard .rb-list--scroll::-webkit-scrollbar {
    width: 8px;
}

.rb-wizard .rb-list--scroll::-webkit-scrollbar-thumb {
    background: rgba(4, 20, 36, 0.18);
    border-radius: 99px;
}

.rb-wizard .rb-list--scroll::-webkit-scrollbar-track {
    background: transparent;
}

.rb-wizard .rb-option--row {
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    text-align: left;
    min-height: 56px;
    padding: 14px 18px;
    gap: 12px;
    margin: 0;
    cursor: pointer;
}

.rb-wizard .rb-option--row:hover {
    /* No lift inside a scroll container — it fights the scrollbar. */
    transform: none;
}

.rb-wizard .rb-option--row .rb-option__label {
    flex: 1 1 auto;
}

/* The radio is the selected indicator here, so the corner tick is redundant. */
.rb-wizard .rb-option--row .rb-option__tick {
    display: none;
}

.rb-wizard .rb-option--row .form-check-input {
    flex: 0 0 auto;
    width: 20px;
    height: 20px;
    margin: 0;
    cursor: pointer;
}

.rb-wizard .rb-option--row .form-check-input:checked {
    background-color: var(--rb-accent);
    border-color: var(--rb-accent);
}

.rb-wizard .rb-option--row .form-check-input:focus {
    border-color: var(--rb-accent);
    box-shadow: 0 0 0 3px var(--rb-accent-soft);
}

/* Issue cards: same shell, laid out as a row with a price pill. */
.rb-wizard .rb-option--check {
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    text-align: left;
    min-height: auto;
    padding: 16px 18px;
    gap: 12px;
    margin: 0;
}

.rb-wizard .rb-option--check .rb-option__label {
    flex: 1 1 auto;
}

.rb-wizard .rb-option--check .form-check-input {
    flex: 0 0 auto;
    width: 20px;
    height: 20px;
    margin: 0;
    cursor: pointer;
}

.rb-wizard .rb-option--check .form-check-input:checked {
    background-color: var(--rb-accent);
    border-color: var(--rb-accent);
}

.rb-wizard .rb-option--check .form-check-input:focus {
    border-color: var(--rb-accent);
    box-shadow: 0 0 0 3px var(--rb-accent-soft);
}

.rb-wizard .rb-hint {
    margin: 16px 0 0;
    font-size: 13px;
    font-weight: 600;
    color: var(--rb-ink);
}

/* ------------------------------------------------- skeletons / empty state */

.rb-wizard .rb-skeleton {
    border-color: transparent;
    background: linear-gradient(
        90deg,
        var(--rb-surface) 25%,
        rgba(4, 20, 36, 0.05) 37%,
        var(--rb-surface) 63%
    );
    background-size: 400% 100%;
    animation: rb-shimmer 1.3s ease infinite;
    pointer-events: none;
}

@keyframes rb-shimmer {
    0% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0 50%;
    }
}

.rb-wizard .rb-empty {
    border: 1px dashed var(--rb-border);
    border-radius: var(--rb-radius);
    background: #fff;
    padding: 28px 20px;
    text-align: center;
    color: var(--rb-muted);
    font-size: 14px;
}

.rb-wizard .rb-empty a {
    color: var(--rb-accent-dark);
    text-decoration: underline;
}

/* --------------------------------------------------- schedule: days + slots */

.rb-wizard .rb-daystrip-wrap {
    position: relative;
}

.rb-wizard .rb-daystrip-wrap::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    bottom: 6px;
    width: 34px;
    pointer-events: none;
    background: linear-gradient(to right, rgba(255, 255, 255, 0), #fff);
}

.rb-wizard .rb-daystrip {
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 6px;
    scrollbar-width: thin;
}

.rb-wizard .rb-day {
    scroll-snap-align: start;
    flex: 0 0 auto;
    min-width: 84px;
    padding: 12px 14px;
    background: #fff;
    border: 2px solid var(--rb-border);
    border-radius: 8px;
    line-height: 1.25;
    cursor: pointer;
    transition: 0.2s ease;
}

.rb-wizard .rb-day:hover:not(:disabled) {
    border-color: var(--rb-accent);
}

.rb-wizard .rb-day.is-selected {
    border-color: var(--rb-accent);
    background: var(--rb-accent-soft);
}

.rb-wizard .rb-day:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.rb-wizard .rb-day:disabled .rb-day__date {
    text-decoration: line-through;
}

.rb-wizard .rb-day__wd {
    display: block;
    font-size: 13px;
    font-weight: 700;
    color: var(--rb-ink);
}

.rb-wizard .rb-day__date {
    display: block;
    font-size: 12px;
    color: var(--rb-muted);
}

.rb-wizard .rb-slot {
    width: 100%;
    min-height: 46px;
    padding: 10px 6px;
    background: #fff;
    border: 2px solid var(--rb-border);
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    color: var(--rb-ink);
    cursor: pointer;
    transition: 0.2s ease;
}

.rb-wizard .rb-slot:hover {
    border-color: var(--rb-accent);
}

.rb-wizard .rb-slot.is-selected {
    background: var(--rb-accent);
    border-color: var(--rb-accent);
    color: #fff;
}

.rb-wizard .rb-slot:focus-visible,
.rb-wizard .rb-day:focus-visible {
    outline: 2px solid var(--rb-accent);
    outline-offset: 2px;
}

/* ------------------------------------------------------------ contact step */

.rb-wizard .rb-field {
    margin-bottom: 18px;
}

.rb-wizard .rb-label {
    display: block;
    margin-bottom: 7px;
    font-size: 13px;
    font-weight: 700;
    color: var(--rb-ink);
}

/* The theme's .style-three .single-input-box input carries margin-bottom: 27px;
   spacing is owned by .rb-field here so labels stay attached to their input. */
.rb-wizard .rb-field .single-input-box input,
.rb-wizard .rb-field .single-input-box textarea {
    margin-bottom: 0;
}

/* 16px minimum stops iOS Safari from auto-zooming on focus. */
.rb-wizard input,
.rb-wizard textarea,
.rb-wizard select {
    font-size: 16px;
}

/* ----------------------------------------------------------------- summary */

.rb-wizard .rb-summary {
    position: sticky;
    top: 126px;
    padding: 26px 22px;
    border-radius: var(--rb-radius);
}

.rb-wizard .rb-summary h5 {
    font-size: 16px;
    font-weight: 700;
    color: var(--rb-ink);
    margin-bottom: 16px;
}

.rb-wizard .rb-summary__list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.rb-wizard .rb-summary__list li {
    padding: 8px 0 8px 12px;
    border-left: 2px solid var(--rb-border);
    margin-bottom: 4px;
}

.rb-wizard .rb-summary__list li.is-done {
    border-left-color: var(--rb-accent);
}

.rb-wizard .rb-summary__key {
    display: block;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: var(--rb-muted);
}

.rb-wizard .rb-summary__val {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: var(--rb-muted);
    word-break: break-word;
}

.rb-wizard .rb-summary__list li.is-done .rb-summary__val {
    color: var(--rb-ink);
}

.rb-wizard .rb-chip {
    display: inline-block;
    margin: 3px 4px 0 0;
    padding: 3px 9px;
    border-radius: 99px;
    background: var(--rb-accent-soft);
    color: var(--rb-ink);
    font-size: 12px;
    font-weight: 600;
}

.rb-wizard .rb-summary__note {
    margin: 10px 0 0;
    font-size: 12px;
    color: var(--rb-muted);
}

/* ------------------------------------------------------------ review table */

.rb-wizard .rb-review {
    margin-bottom: 20px;
}

.rb-wizard .rb-review th {
    width: 34%;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: var(--rb-muted);
    font-weight: 700;
    vertical-align: top;
    padding: 10px 10px 10px 0;
}

.rb-wizard .rb-review td {
    font-size: 15px;
    color: var(--rb-ink);
    vertical-align: top;
    padding: 10px 0;
    border-bottom: 1px solid var(--rb-border);
}

.rb-wizard .rb-edit {
    background: none;
    border: 0;
    padding: 0;
    margin-left: 8px;
    font-size: 12px;
    font-weight: 700;
    color: var(--rb-accent-dark);
    text-decoration: underline;
    cursor: pointer;
}

.rb-wizard .rb-terms {
    margin: 4px 0 0;
}

.rb-wizard .rb-terms label {
    font-size: 14px;
    color: var(--rb-ink);
}

.rb-wizard .rb-terms .form-check-input {
    width: 18px;
    height: 18px;
    margin-top: 0.15em;
}

.rb-wizard .rb-terms .form-check-input:checked {
    background-color: var(--rb-accent);
    border-color: var(--rb-accent);
}

.rb-wizard .rb-terms a {
    color: var(--rb-accent-dark);
    text-decoration: underline;
}

/* ------------------------------------------------------------- step footer */

.rb-wizard .rb-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 26px;
    padding-top: 20px;
    border-top: 1px solid var(--rb-border);
}

.rb-wizard .rb-nav .massage-sent-button {
    margin: 0;
}

.rb-wizard .rb-nav .massage-sent-button button:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

/* Matches the theme Continue button's 15px/38px so both line up. */
.rb-wizard .rb-back {
    background: #fff;
    border: 2px solid rgba(4, 20, 36, 0.15);
    color: var(--rb-ink);
    border-radius: 3px;
    padding: 13px 30px;
    font-weight: 600;
    cursor: pointer;
    transition: 0.3s ease;
}

.rb-wizard .rb-back:hover {
    border-color: var(--rb-ink);
}

.rb-wizard .rb-nav__hint {
    flex: 1 1 100%;
    order: 3;
    margin: 0;
    font-size: 12px;
    color: var(--rb-muted);
}

.rb-wizard .rb-errors {
    list-style: none;
    margin: 0 0 18px;
    padding: 14px 16px;
    border: 1px solid rgba(220, 53, 69, 0.3);
    border-radius: 8px;
    background: rgba(220, 53, 69, 0.06);
    color: #b02a37;
    font-size: 14px;
}

/* ------------------------------------------------------ confirmation page */

.rb-wizard .rb-success {
    text-align: center;
}

.rb-wizard .rb-success__icon {
    font-size: 64px;
    line-height: 1;
    color: var(--rb-accent);
}

.rb-wizard .rb-ref {
    display: inline-block;
    margin: 14px 0 6px;
    padding: 10px 22px;
    border-radius: 8px;
    background: var(--rb-accent-soft);
    color: var(--rb-ink);
    font-family: 'SFMono-Regular', Menlo, Consolas, monospace;
    font-size: 20px;
    font-weight: 700;
    letter-spacing: 2px;
}

.rb-wizard .rb-success .rb-nav {
    justify-content: center;
    border-top: 0;
}

/* --------------------------------------------------------------- responsive */

@media (max-width: 991.98px) {
    .rb-wizard .rb-summary {
        position: static;
        margin-top: 24px;
    }
}

@media (max-width: 575.98px) {
    .rb-wizard .rb-card {
        padding: 20px 16px;
    }

    .rb-wizard .rb-summary {
        padding: 20px 16px;
    }

    .rb-wizard .rb-step-body {
        min-height: 300px;
    }

    .rb-wizard .rb-nav {
        gap: 8px;
    }

    .rb-wizard .rb-back,
    .rb-wizard .rb-nav .massage-sent-button button {
        padding-left: 20px;
        padding-right: 20px;
    }

    .rb-wizard .rb-review th {
        width: 42%;
        font-size: 11px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .rb-wizard .rb-option,
    .rb-wizard .rb-slot,
    .rb-wizard .rb-day,
    .rb-wizard .rb-progress .progress-bar,
    .rb-wizard .rb-step-pip {
        transition: none;
    }

    .rb-wizard .rb-option:hover {
        transform: none;
    }

    .rb-wizard .rb-skeleton {
        animation: none;
    }
}
