/* Let expanded validation messages and small screens use the document scroll. */
#main:has(.quote-page) {
    block-size: auto;
    overflow: visible;
}

.quote-page {
    --quote-line: #c3dbe6;
    --quote-muted: #455e74;
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    align-content: center;
    min-block-size: var(--page-height);
    padding-block: clamp(24px, 4vh, 54px);
    background-color: #eaf3fa;
    background-image:
        radial-gradient(ellipse at 0% 5%, #c6dffc 0%, transparent 54%),
        radial-gradient(ellipse at 100% 90%, #c6eee8 0%, transparent 53%),
        linear-gradient(140deg, #edf5fe, #f6f9fd 50%, #e4f3f2);
}

.quote-content {
    max-width: 1170px;
}

.quote-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    padding-bottom: clamp(18px, 2.5vh, 28px);
    border-bottom: 1px solid var(--quote-line);
}

.quote-breadcrumb {
    display: flex;
    align-items: center;
    gap: 9px;
    color: var(--quote-muted);
    font-size: .8rem;
}

.quote-breadcrumb a:hover,
.quote-phone:hover strong {
    text-decoration: underline;
    text-underline-offset: 3px;
}

.quote-heading h1 {
    margin: 10px 0 6px;
    color: #102e48;
    font-size: clamp(2.2rem, 3.6vw, 3.5rem);
    line-height: 1.1;
    text-wrap: balance;
}

.quote-heading p {
    margin: 0;
    color: var(--quote-muted);
}

.quote-phone {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    flex: none;
    color: var(--quote-muted);
    font-size: .8rem;
}

.quote-phone .icon {
    width: 21px;
    height: 21px;
    color: #0876ac;
}

.quote-phone strong {
    display: block;
    color: var(--ink);
    font-size: 1.05rem;
    font-variant-numeric: tabular-nums;
}

.quote-form {
    padding-top: clamp(18px, 2.8vh, 32px);
}

.quote-form fieldset {
    min-inline-size: 0;
    margin: 0;
    padding: 0;
    border: 0;
}

.quote-form legend {
    padding: 0;
    margin: 0 0 14px;
    font-family: Manrope, sans-serif;
    font-size: clamp(1.12rem, 1.4vw, 1.35rem);
    font-weight: 750;
    letter-spacing: -.035em;
    line-height: 1.3;
}

.quote-topics.is-enhanced {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px;
}

.quote-product,
.is-enhanced .quote-other-topic {
    position: relative;
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
    min-height: clamp(78px, 8.6vh, 100px);
    padding: 10px clamp(8px, 1vw, 16px);
    border: 1px solid #cadbe9;
    border-radius: 13px;
    color: #193e5b;
    background: white;
    font-weight: 700;
    text-align: start;
    cursor: pointer;
}

.quote-product img {
    width: clamp(38px, 3.6vw, 56px);
    height: auto;
}

.quote-product:is(:hover, :focus-visible),
.is-enhanced .quote-other-topic:is(:hover, :focus-within) {
    border-color: #5191bb;
    background: #f3faff;
}

.quote-product[aria-pressed="true"],
.general-topic-selected .quote-other-topic {
    border-color: #095882;
    background: #103e60;
    color: white;
}

.quote-product[aria-pressed="true"]:hover,
.general-topic-selected .quote-other-topic:is(:hover, :focus-within) {
    background: #174e70;
    color: white;
}

.quote-product[aria-pressed="true"]::after {
    content: "✓";
    position: absolute;
    inset: 3px 8px auto auto;
    color: #b0f3ed;
    font-size: .85rem;
}

.quote-other-topic {
    display: grid;
    gap: 6px;
    color: var(--ink);
    font-size: .92rem;
}

.quote-other-topic .icon {
    display: none;
}

.quote-other-topic select,
.quote-form .form-field select {
    width: 100%;
    min-height: 46px;
    padding-inline: 12px;
    border: 1px solid #bfcedb;
    border-radius: 8px;
    color: var(--ink);
    background-color: white;
}

.is-enhanced .quote-other-topic .icon {
    display: block;
    order: -1;
    flex-shrink: 0;
    width: 26px;
    height: 26px;
}

.is-enhanced .quote-other-topic::after {
    content: "";
    width: 7px;
    height: 7px;
    margin: 0 3px 4px auto;
    flex: none;
    border: solid currentColor;
    border-width: 0 1.5px 1.5px 0;
    transform: rotate(45deg);
}

.is-enhanced .quote-other-topic select {
    position: absolute;
    inset: 0;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

.quote-other-topic:focus-within {
    outline: 3px solid #73abed;
    outline-offset: 2px;
}

.quote-body {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: start;
    gap: clamp(24px, 4vw, 56px);
    margin-top: clamp(24px, 3.5vh, 42px);
}

.quote-settings {
    display: grid;
    gap: 18px;
}

.quote-stage-options {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
}

.quote-stage-options label {
    position: relative;
    cursor: pointer;
}

.quote-stage-options input {
    position: absolute;
    opacity: 0;
}

.quote-stage-options span {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    min-height: 44px;
    padding: 6px 8px;
    text-align: center;
    line-height: 1.3;
    background: #ffffffd9;
    border: 1px solid #c6d6e2;
    border-radius: 24px;
    color: var(--quote-muted);
    font-size: .875rem;
    font-weight: 600;
}

.quote-stage-options input:checked + span {
    border-color: #326b93;
    background: #eaf5fc;
    color: #0f507e;
}

.quote-stage-options input:focus-visible + span {
    outline: 3px solid #73abed;
    outline-offset: 2px;
}

.quote-volume {
    padding: 16px;
    border: 1px solid var(--quote-line);
    border-radius: 12px;
    background: #ffffffde;
}

.quote-bundle span {
    font-weight: 600;
}

.quote-fields {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px 15px;
}

.quote-form .form-field {
    min-width: 0;
    margin: 0;
}

.quote-form .form-field label,
.volume-heading label {
    margin-bottom: 5px;
    font-size: .875rem;
    font-weight: 600;
}

.quote-form .form-field input {
    min-height: 46px;
    border-radius: 8px;
    border-color: #bfcedb;
    background-color: white;
    font-size: .9375rem;
}

.quote-form .form-field .input-validation-error {
    border-color: #b84242;
}

.quote-form .validation-summary-errors {
    margin-bottom: 18px;
    padding: 10px 16px;
    border-inline-start: 3px solid #b84242;
    background: #fff5f4;
}

.quote-form .validation-summary-errors ul {
    margin: 0;
    padding-inline-start: 1.2em;
}

.volume-heading {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 4px 12px;
}

.volume-heading label {
    margin: 0;
}

.volume-heading output {
    color: #0c5c9e;
    font-size: .8125rem;
    font-weight: 650;
}

.volume-range {
    display: block;
    width: 100%;
    height: 24px;
    margin: 5px 0 0;
    appearance: none;
    background: transparent;
    cursor: pointer;
}

.volume-range::-webkit-slider-runnable-track {
    height: 5px;
    border-radius: 9px;
    background: linear-gradient(to right, #126eca var(--volume-progress), #cfdeec var(--volume-progress));
}

.volume-range::-webkit-slider-thumb {
    appearance: none;
    width: 18px;
    height: 18px;
    margin-top: -6.5px;
    border: 3px solid white;
    border-radius: 50%;
    background: #126eca;
    box-shadow: 0 0 0 1px #89b6e5;
}

.volume-range::-moz-range-track {
    height: 5px;
    border-radius: 9px;
    background: #cfdeec;
}

.volume-range::-moz-range-progress {
    height: 5px;
    border-radius: 9px;
    background: #126eca;
}

.volume-range::-moz-range-thumb {
    width: 13px;
    height: 13px;
    border: 3px solid white;
    border-radius: 50%;
    background: #126eca;
    box-shadow: 0 0 0 1px #89b6e5;
}

@media (forced-colors: active) {
    .volume-range {
        appearance: auto;
    }
}

.volume-stops {
    display: flex;
    justify-content: space-between;
    gap: 2px;
}

.volume-stops button {
    min-height: 28px;
    padding: 0 3px;
    border: 0;
    background: transparent;
    color: var(--quote-muted);
    font-size: .75rem;
    cursor: pointer;
}

.volume-stops button[aria-pressed="true"] {
    color: #07559d;
    font-weight: bold;
}

.quote-bundle {
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 44px;
    font-size: .875rem;
    cursor: pointer;
}

.quote-bundle input {
    width: 18px;
    height: 18px;
    margin: 0;
    accent-color: var(--blue);
}

.quote-footer {
    margin-top: 18px;
}

.quote-submit {
    justify-content: space-between;
    width: 100%;
    min-height: 48px;
    border-radius: 9px;
    background: #0965bb;
}

.quote-submit:hover {
    background: #0956a3;
}

.quote-footer p {
    margin: 8px 0 0;
    color: var(--quote-muted);
    font-size: .8rem;
}

.quote-footer a,
.quote-edit {
    color: #175e9c;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.quote-footer a {
    white-space: nowrap;
}

.quote-review {
    margin-top: 26px;
    padding: clamp(20px, 3vw, 36px);
    border: 1px solid var(--quote-line);
    border-radius: 16px;
    background: white;
}

.quote-review h2 {
    margin-bottom: 10px;
}

.quote-review-list {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 18px;
    padding-block: 18px;
    border-block: 1px solid var(--quote-line);
}

.quote-review-list dt {
    color: var(--quote-muted);
    font-size: .8125rem;
}

.quote-review-list dd {
    margin: 2px 0 0;
    font-weight: 600;
    overflow-wrap: anywhere;
}

.quote-review-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 24px;
}

.quote-review-actions .quote-submit {
    width: auto;
}

.quote-edit {
    min-height: 44px;
    padding: 4px;
    border: 0;
    background: transparent;
    font-weight: 600;
}

@media (max-width: 930px) {
    .quote-topics.is-enhanced {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .is-enhanced .quote-other-topic {
        grid-column: 1 / -1;
        min-height: 42px;
    }

    .is-enhanced .quote-other-topic .icon {
        width: 20px;
        height: 20px;
    }

    .quote-body {
        gap: 24px;
    }
}

@media (max-width: 740px) {
    .quote-body {
        grid-template-columns: minmax(0, 1fr);
        gap: 24px;
    }

    .quote-settings {
        gap: 12px;
    }

    .quote-contact {
        padding-top: 20px;
        border-top: 1px solid var(--quote-line);
    }

    .quote-review-list {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 600px) {
    .quote-heading {
        align-items: flex-start;
        flex-direction: column;
        gap: 10px;
    }

    .quote-phone {
        min-height: 40px;
    }

    .quote-phone strong {
        display: inline;
        margin-left: 8px;
        font-size: .9375rem;
    }

    .quote-topics.is-enhanced {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .quote-product {
        min-height: 62px;
        padding: 8px 10px;
        font-size: .875rem;
    }

    .quote-contact .form-field input,
    .quote-other-topic select {
        font-size: 1rem;
    }
}

@media (max-width: 420px) {
    .quote-fields {
        grid-template-columns: minmax(0, 1fr);
    }

    .quote-stage-options {
        gap: 6px;
    }

    .quote-stage-options span {
        padding-inline: 3px;
        font-size: .8125rem;
    }

    .quote-review-actions {
        flex-direction: column-reverse;
        gap: 6px;
    }

    .quote-review-actions .quote-submit {
        width: 100%;
    }
}
