:root {
    color-scheme: light;
    --ink: #17202a;
    --muted: #5e6975;
    --line: #d8dee6;
    --surface: #ffffff;
    --surface-2: #f5f7fa;
    --navy: #17324d;
    --teal: #0f766e;
    --gold: #d49423;
    --red: #b42318;
    --blue: #2f5f98;
    --shadow: 0 18px 42px rgba(23, 32, 42, 0.14);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: var(--surface-2);
    color: var(--ink);
    font-family: "Segoe UI", Arial, sans-serif;
    font-size: 16px;
    line-height: 1.5;
}

a {
    color: inherit;
}

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

h1:focus {
    outline: none;
}

.site-shell {
    min-height: 100vh;
}

.topbar {
    align-items: center;
    background: rgba(255, 255, 255, 0.96);
    border-bottom: 1px solid var(--line);
    display: grid;
    gap: 1rem;
    grid-template-columns: 1fr auto auto;
    left: 0;
    padding: 0.85rem clamp(1rem, 4vw, 4.5rem);
    position: sticky;
    right: 0;
    top: 0;
    z-index: 20;
}

.brand {
    align-items: center;
    display: inline-flex;
    gap: 0.75rem;
    text-decoration: none;
}

.brand-mark {
    align-items: center;
    background: var(--navy);
    border-radius: 6px;
    color: #fff;
    display: inline-flex;
    font-size: 0.86rem;
    font-weight: 800;
    height: 2.7rem;
    justify-content: center;
    width: 2.7rem;
}

.brand strong,
.brand small {
    display: block;
}

.brand small {
    color: var(--muted);
    font-size: 0.78rem;
}

.nav-links {
    display: flex;
    gap: 1.25rem;
}

.nav-links a,
.phone-link {
    color: var(--navy);
    font-size: 0.92rem;
    font-weight: 700;
    text-decoration: none;
}

.phone-link {
    border: 1px solid var(--line);
    border-radius: 6px;
    padding: 0.55rem 0.75rem;
}

.hero {
    background:
        linear-gradient(90deg, rgba(9, 23, 37, 0.86) 0%, rgba(9, 23, 37, 0.68) 46%, rgba(9, 23, 37, 0.16) 100%),
        url("/images/hero-container-yard.png") center/cover;
    color: #fff;
    display: grid;
    gap: clamp(1.5rem, 4vw, 4rem);
    grid-template-columns: minmax(0, 1.1fr) minmax(18rem, 0.52fr);
    min-height: 78vh;
    padding: clamp(3rem, 6vw, 6rem) clamp(1rem, 4vw, 4.5rem);
}

.hero-copy {
    align-self: center;
    max-width: 48rem;
}

.eyebrow {
    color: var(--gold);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    margin: 0 0 0.65rem;
    text-transform: uppercase;
}

.hero h1 {
    font-size: clamp(2.5rem, 5vw, 5rem);
    line-height: 0.98;
    margin: 0;
    max-width: 12ch;
}

.hero-summary {
    color: rgba(255, 255, 255, 0.86);
    font-size: 1.1rem;
    margin: 1.25rem 0 0;
    max-width: 43rem;
}

.hero-actions,
.support-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1.75rem;
}

.primary-action,
.secondary-action,
.submit-button {
    align-items: center;
    border-radius: 6px;
    display: inline-flex;
    font-weight: 800;
    justify-content: center;
    min-height: 2.8rem;
    padding: 0.75rem 1rem;
    text-decoration: none;
}

.action-button {
    cursor: pointer;
}

.primary-action,
.submit-button {
    background: var(--gold);
    border: 1px solid var(--gold);
    color: #111827;
}

.secondary-action {
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.42);
    color: #fff;
}

.trust-strip {
    border-top: 1px solid rgba(255, 255, 255, 0.25);
    display: grid;
    gap: 1rem;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    margin: 2rem 0 0;
    max-width: 38rem;
    padding-top: 1.25rem;
}

.trust-strip div {
    min-width: 0;
}

.trust-strip dt {
    font-size: 1.25rem;
    font-weight: 900;
}

.trust-strip dd {
    color: rgba(255, 255, 255, 0.75);
    margin: 0.15rem 0 0;
}

.hero-panel,
.summary-panel,
.quote-form,
.product-card {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 8px;
    color: var(--ink);
}

.hero-panel {
    align-self: end;
    box-shadow: var(--shadow);
    padding: 1.25rem;
}

.panel-header,
.summary-status,
.estimate-list li,
.spec-list li,
.price-stack div {
    align-items: center;
    display: flex;
    justify-content: space-between;
    gap: 1rem;
}

.panel-header span,
.estimate-list span,
.spec-list span,
.price-stack span {
    color: var(--muted);
}

.quote-total {
    color: var(--navy);
    font-size: clamp(2rem, 4vw, 3.25rem);
    font-weight: 900;
    line-height: 1;
    margin: 0.9rem 0 0.4rem;
}

.estimate-list,
.spec-list {
    display: grid;
    gap: 0.65rem;
    list-style: none;
    margin: 1rem 0;
    padding: 0;
}

.estimate-list li,
.spec-list li {
    border-top: 1px solid var(--line);
    padding-top: 0.65rem;
}

.fine-print {
    color: var(--muted);
    font-size: 0.86rem;
    margin-bottom: 0;
}

.quote-workspace,
.content-band,
.process-band,
.support-band {
    padding: clamp(2.5rem, 5vw, 4.5rem) clamp(1rem, 4vw, 4.5rem);
}

.section-heading {
    margin-bottom: 1.25rem;
    max-width: 50rem;
}

.section-heading h2,
.support-band h2 {
    color: var(--navy);
    font-size: clamp(1.8rem, 3vw, 3rem);
    line-height: 1.05;
    margin: 0;
}

.quote-grid {
    display: grid;
    gap: 1rem;
    grid-template-columns: minmax(0, 1.35fr) minmax(18rem, 0.65fr);
}

.quote-form,
.summary-panel {
    padding: clamp(1rem, 2.5vw, 1.5rem);
}

.quote-form {
    display: grid;
    gap: 1rem;
}

fieldset {
    border: 1px solid var(--line);
    border-radius: 8px;
    display: grid;
    gap: 0.9rem;
    margin: 0;
    padding: 1rem;
}

legend {
    color: var(--navy);
    font-weight: 900;
    padding: 0 0.35rem;
}

label {
    color: var(--muted);
    display: grid;
    gap: 0.35rem;
    font-size: 0.9rem;
    font-weight: 700;
}

input,
select,
textarea {
    background: #fff;
    border: 1px solid #c8d0da;
    border-radius: 6px;
    color: var(--ink);
    min-height: 2.7rem;
    padding: 0.65rem 0.75rem;
    width: 100%;
}

textarea {
    resize: vertical;
}

input:focus,
select:focus,
textarea:focus,
button:focus,
a:focus-visible {
    outline: 3px solid rgba(15, 118, 110, 0.25);
    outline-offset: 2px;
}

.split-row {
    display: grid;
    gap: 0.8rem;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.toggle-row {
    background: var(--surface-2);
    border: 1px solid var(--line);
    border-radius: 8px;
    display: grid;
    gap: 0.35rem;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    padding: 0.35rem;
}

.toggle-row button {
    background: transparent;
    border: 0;
    border-radius: 6px;
    color: var(--muted);
    cursor: pointer;
    font-weight: 800;
    min-height: 2.45rem;
}

.toggle-row button.active {
    background: var(--navy);
    color: #fff;
}

.check-option {
    align-items: center;
    color: var(--ink);
    display: flex;
    flex-direction: row;
    gap: 0.55rem;
}

.check-option input {
    accent-color: var(--teal);
    height: 1.05rem;
    min-height: auto;
    width: 1.05rem;
}

.submit-button {
    cursor: pointer;
    width: 100%;
}

.summary-panel {
    align-self: start;
    box-shadow: var(--shadow);
    position: sticky;
    top: 6rem;
}

.summary-panel h3 {
    color: var(--navy);
    font-size: 1.6rem;
    line-height: 1.1;
    margin: 1rem 0 0.45rem;
}

.summary-panel p {
    color: var(--muted);
}

.status-pill,
.availability-pill {
    border-radius: 999px;
    display: inline-flex;
    font-size: 0.8rem;
    font-weight: 900;
    padding: 0.3rem 0.55rem;
}

.status-high,
.availability-pill {
    background: rgba(15, 118, 110, 0.12);
    color: var(--teal);
}

.status-medium {
    background: rgba(212, 148, 35, 0.14);
    color: #8a5b08;
}

.status-limited {
    background: rgba(180, 35, 24, 0.12);
    color: var(--red);
}

.price-stack {
    background: var(--surface-2);
    border: 1px solid var(--line);
    border-radius: 8px;
    display: grid;
    gap: 0.75rem;
    margin: 1rem 0;
    padding: 1rem;
}

.price-stack strong {
    color: var(--navy);
    font-size: 1.35rem;
}

.lead-card {
    background: #eef7f5;
    border: 1px solid rgba(15, 118, 110, 0.25);
    border-radius: 8px;
    margin-top: 1rem;
    padding: 1rem;
}

.lead-card span {
    color: var(--teal);
    display: block;
    font-weight: 900;
}

.lead-card strong {
    color: var(--navy);
    display: block;
    font-size: 1.1rem;
    margin-top: 0.2rem;
}

.product-grid {
    display: grid;
    gap: 1rem;
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.product-card {
    overflow: hidden;
}

.product-card img {
    aspect-ratio: 4 / 3;
    display: block;
    object-fit: cover;
    width: 100%;
}

.product-card > div {
    padding: 1rem;
}

.product-card h3 {
    color: var(--navy);
    font-size: 1.2rem;
    line-height: 1.15;
    margin: 0.8rem 0 0.45rem;
}

.product-card p,
.support-band p {
    color: var(--muted);
}

.product-card dl {
    border-top: 1px solid var(--line);
    display: grid;
    gap: 0.65rem;
    margin: 1rem 0 0;
    padding-top: 0.75rem;
}

.product-card dl div {
    display: grid;
    gap: 0.1rem;
}

.product-card dt {
    color: var(--muted);
    font-size: 0.76rem;
    font-weight: 800;
    text-transform: uppercase;
}

.product-card dd {
    margin: 0;
}

.process-band {
    background: #e8eef5;
}

.flow {
    display: grid;
    gap: 0;
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.flow div {
    background: var(--surface);
    border: 1px solid var(--line);
    min-height: 12rem;
    padding: 1rem;
}

.flow div + div {
    border-left: 0;
}

.flow span {
    align-items: center;
    background: var(--blue);
    border-radius: 999px;
    color: #fff;
    display: inline-flex;
    font-weight: 900;
    height: 2rem;
    justify-content: center;
    width: 2rem;
}

.flow strong {
    color: var(--navy);
    display: block;
    font-size: 1.25rem;
    margin-top: 0.9rem;
}

.flow p {
    color: var(--muted);
    margin-bottom: 0;
}

.support-band {
    align-items: center;
    background: var(--navy);
    color: #fff;
    display: grid;
    gap: 1rem;
    grid-template-columns: minmax(0, 1fr) auto;
}

.support-band h2,
.support-band p {
    color: #fff;
}

.support-band p {
    margin-bottom: 0;
    max-width: 54rem;
}

.site-footer {
    align-items: center;
    background: #101820;
    color: rgba(255, 255, 255, 0.78);
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem 1.25rem;
    justify-content: space-between;
    padding: 1rem clamp(1rem, 4vw, 4.5rem);
}

.site-footer nav {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

.site-footer a {
    color: #fff;
    font-weight: 700;
    text-decoration: none;
}

.modal-backdrop {
    align-items: center;
    background: rgba(9, 23, 37, 0.68);
    display: flex;
    inset: 0;
    justify-content: center;
    padding: 1rem;
    position: fixed;
    z-index: 100;
}

.contact-modal {
    background: var(--surface);
    border-radius: 8px;
    box-shadow: var(--shadow);
    color: var(--ink);
    max-height: min(92vh, 52rem);
    max-width: 42rem;
    overflow-y: auto;
    padding: clamp(1rem, 3vw, 1.5rem);
    position: relative;
    width: min(100%, 42rem);
}

.modal-close {
    align-items: center;
    background: var(--surface-2);
    border: 1px solid var(--line);
    border-radius: 6px;
    color: var(--ink);
    cursor: pointer;
    display: inline-flex;
    font-size: 1.35rem;
    font-weight: 800;
    height: 2.25rem;
    justify-content: center;
    line-height: 1;
    position: absolute;
    right: 1rem;
    top: 1rem;
    width: 2.25rem;
}

.modal-heading {
    padding-right: 2.75rem;
}

.modal-heading h2,
.contact-success h2,
.legal-page h1 {
    color: var(--navy);
    font-size: clamp(1.7rem, 3vw, 2.5rem);
    line-height: 1.05;
    margin: 0;
}

.modal-heading p:not(.eyebrow),
.contact-success p,
.legal-page p,
.legal-page li {
    color: var(--muted);
}

.contact-modal form {
    display: grid;
    gap: 0.9rem;
    margin-top: 1.25rem;
}

.contact-modal .check-option {
    align-items: flex-start;
}

.contact-modal .check-option span {
    font-weight: 600;
}

.contact-modal .check-option a {
    color: var(--navy);
    font-weight: 800;
}

.field-hint {
    color: var(--teal);
    font-size: 0.8rem;
    font-weight: 700;
}

.form-error {
    background: rgba(180, 35, 24, 0.1);
    border: 1px solid rgba(180, 35, 24, 0.2);
    border-radius: 6px;
    color: var(--red);
    margin: 0;
    padding: 0.75rem;
}

.contact-success {
    display: grid;
    gap: 0.85rem;
}

.contact-success .primary-action {
    justify-self: start;
}

.legal-page {
    background: var(--surface);
    min-height: 100vh;
}

.legal-header,
.legal-content {
    margin: 0 auto;
    max-width: 58rem;
    padding: clamp(1.25rem, 4vw, 3rem);
}

.legal-header {
    align-items: center;
    display: flex;
    justify-content: space-between;
}

.legal-header a {
    color: var(--navy);
    font-weight: 800;
    text-decoration: none;
}

.legal-content {
    padding-top: 0;
}

.legal-content h2 {
    color: var(--navy);
    font-size: 1.2rem;
    margin: 1.8rem 0 0.4rem;
}

.legal-review-note {
    background: #fff8e8;
    border: 1px solid rgba(212, 148, 35, 0.3);
    border-radius: 8px;
    color: #6e4700;
    margin: 1rem 0;
    padding: 1rem;
}

.valid.modified:not([type=checkbox]) {
    outline: 1px solid #26b050;
}

.invalid {
    outline: 1px solid #e50000;
}

.validation-message {
    color: #e50000;
}

.blazor-error-boundary {
    background: #b32121;
    color: white;
    padding: 1rem;
}

.blazor-error-boundary::after {
    content: "An error has occurred.";
}

.darker-border-checkbox.form-check-input {
    border-color: #929292;
}

.form-floating > .form-control-plaintext::placeholder,
.form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder,
.form-floating > .form-control:focus::placeholder {
    text-align: start;
}

@media (max-width: 1080px) {
    .hero,
    .quote-grid,
    .support-band {
        grid-template-columns: 1fr;
    }

    .hero-panel,
    .summary-panel {
        position: static;
    }

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

@media (max-width: 760px) {
    .topbar {
        grid-template-columns: 1fr auto;
    }

    .nav-links {
        display: none;
    }

    .hero {
        min-height: auto;
        padding-block: 2.5rem;
    }

    .hero h1 {
        font-size: clamp(2rem, 9vw, 3rem);
        line-height: 1.03;
        max-width: 14ch;
    }

    .hero-summary {
        font-size: 1rem;
    }

    .trust-strip,
    .split-row,
    .product-grid,
    .flow {
        grid-template-columns: 1fr;
    }

    .flow div + div {
        border-left: 1px solid var(--line);
        border-top: 0;
    }

    .contact-modal {
        max-height: calc(100dvh - 1.5rem);
        padding: 1rem;
    }
}

@media (max-width: 480px) {
    .topbar {
        padding-inline: 0.8rem;
        row-gap: 0.55rem;
    }

    .brand small {
        display: none;
    }

    .phone-link {
        justify-self: start;
        min-height: 2.5rem;
        padding: 0.5rem 0.65rem;
    }

    .hero-actions,
    .support-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .hero-actions > *,
    .support-actions > *,
    .contact-success .primary-action {
        width: 100%;
    }

    .modal-heading {
        padding-right: 2.5rem;
    }

    .modal-heading h2,
    .contact-success h2 {
        font-size: 1.55rem;
    }

    .contact-modal .check-option {
        gap: 0.45rem;
    }

    .legal-header {
        align-items: flex-start;
        flex-direction: column;
        gap: 0.5rem;
    }
}

#blazor-error-ui {
    background: lightyellow;
    bottom: 0;
    box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2);
    box-sizing: border-box;
    color-scheme: light only;
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
}

#blazor-error-ui .dismiss {
    cursor: pointer;
    position: absolute;
    right: 0.75rem;
    top: 0.5rem;
}
