:root {
    --mayo-blue: #0057b8;
    --mayo-blue-dark: #003da5;
    --ink: #162033;
    --muted: #5d6878;
    --line: #d9e1ec;
    --panel: #ffffff;
    --soft: #f3f7fb;
    --teal: #007c89;
    --gold: #b26b00;
    --shadow: 0 18px 50px rgba(16, 32, 56, 0.14);
}

* {
    box-sizing: border-box;
}

*,
*::before,
*::after {
    min-width: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: Arial, Helvetica, sans-serif;
    color: var(--ink);
    background: #fff;
    line-height: 1.55;
    overflow-x: hidden;
}

img {
    max-width: 100%;
}

a {
    color: var(--mayo-blue);
    text-decoration: none;
    overflow-wrap: anywhere;
}

a:hover {
    text-decoration: underline;
}

.container {
    width: min(1120px, calc(100% - 40px));
    margin: 0 auto;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 20;
    background: #fff;
    border-bottom: 1px solid var(--line);
}

.top-strip {
    background: var(--mayo-blue-dark);
    color: #fff;
    font-size: 0.82rem;
}

.strip-inner,
.nav-wrap,
.footer-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.strip-inner {
    min-height: 34px;
}

.strip-inner a {
    color: #fff;
    font-weight: 700;
}

.nav-wrap {
    min-height: 82px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 14px;
    color: var(--mayo-blue-dark);
    font-weight: 800;
    letter-spacing: 0;
    text-transform: uppercase;
}

.brand-logo {
    width: 42px;
    height: auto;
}

.brand:hover {
    text-decoration: none;
}

.brand-mark {
    width: 42px;
    height: 42px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3px;
    padding: 5px;
    background: var(--mayo-blue);
}

.brand-mark span {
    background: #fff;
    clip-path: polygon(50% 0, 100% 18%, 88% 100%, 50% 82%, 12% 100%, 0 18%);
}

.brand-text {
    font-size: 1.06rem;
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 26px;
    font-size: 0.95rem;
    font-weight: 700;
    white-space: normal;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.main-nav a {
    min-width: 0;
}

.main-nav a {
    color: var(--ink);
}

.main-nav .nav-action {
    color: #fff;
    background: var(--mayo-blue);
    padding: 10px 16px;
    border-radius: 4px;
}

.hero-section {
    position: relative;
    min-height: 640px;
    isolation: isolate;
    overflow: hidden;
    background: #dfe8f3;
}

.hero-media {
    position: absolute;
    inset: 0;
    background-image: linear-gradient(90deg, rgba(0, 39, 96, 0.55) 0%, rgba(0, 61, 165, 0.45) 40%, rgba(0, 61, 165, 0.18) 75%), url("assets/healthcare-hero.png");
    background-size: cover;
    background-position: center;
    z-index: -1;
}

.hero-layout {
    min-height: 640px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 36px;
    flex-wrap: wrap;
    padding: 0 36px;
}

.hero-copy {
    width: min(680px, 100%);
    color: #fff;
    padding: 72px 0 104px 0;
    z-index: 1;
}

.eyebrow {
    margin: 0 0 12px;
    color: var(--teal);
    font-size: 0.76rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.hero-copy .eyebrow {
    color: #b7fff7;
}

h1,
h2,
h3,
p {
    margin-top: 0;
}

h1 {
    margin-bottom: 18px;
    font-size: clamp(2.35rem, 6vw, 4.8rem);
    line-height: 1.02;
    font-weight: 800;
    letter-spacing: 0;
}

h2 {
    margin-bottom: 14px;
    font-size: clamp(1.8rem, 4vw, 3rem);
    line-height: 1.08;
    color: var(--mayo-blue-dark);
}

h3 {
    margin-bottom: 10px;
    font-size: 1.15rem;
    color: var(--ink);
}

.hero-lede {
    max-width: 560px;
    margin-bottom: 30px;
    font-size: 1.22rem;
    color: rgba(255, 255, 255, 0.9);
}

.hero-actions,
.request-layout {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    align-items: center;
}

.hero-image-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    margin-top: 24px;
}

.hero-image-grid img {
    width: 100%;
    min-height: 240px;
    object-fit: cover;
    border-radius: 18px;
    box-shadow: var(--shadow);
}

.primary-button,
.secondary-button,
.search-row button {
    min-height: 46px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 4px;
    padding: 12px 20px;
    font: inherit;
    font-weight: 800;
    cursor: pointer;
    text-align: center;
    white-space: normal;
}

.primary-button {
    color: #fff;
    background: var(--mayo-blue);
}

.primary-button:hover {
    background: var(--mayo-blue-dark);
    text-decoration: none;
}

.secondary-button {
    color: var(--mayo-blue-dark);
    background: #fff;
    border: 1px solid var(--line);
}

.secondary-button:hover {
    border-color: var(--mayo-blue);
    text-decoration: none;
}

.quick-actions {
    margin-top: -58px;
    position: relative;
    z-index: 2;
}

.action-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    background: #fff;
    box-shadow: var(--shadow);
    border: 1px solid rgba(217, 225, 236, 0.8);
}

.action-grid a {
    min-height: 150px;
    padding: 28px;
    display: grid;
    align-content: start;
    gap: 8px;
    color: var(--ink);
    border-right: 1px solid var(--line);
}

.action-grid a:last-child {
    border-right: 0;
}

.action-grid a:hover {
    background: var(--soft);
    text-decoration: none;
}

.action-icon {
    width: 34px;
    height: 34px;
    display: inline-grid;
    place-items: center;
    color: #fff;
    background: var(--mayo-blue);
    border-radius: 50%;
    font-weight: 800;
}

.action-grid strong {
    font-size: 1.12rem;
}

.action-grid span:last-child,
.section-heading p,
.specialty-grid p,
.estimate-section p,
.location-list p,
.prototype-note,
.form-note {
    color: var(--muted);
}

.section-band,
.estimate-section,
.request-section {
    padding: 92px 0;
}

.section-band.light {
    background: var(--soft);
}

.section-heading {
    max-width: 740px;
    margin-bottom: 34px;
}

.section-heading.compact {
    max-width: 430px;
}

.search-panel {
    margin-bottom: 28px;
    padding: 24px;
    background: var(--soft);
    border: 1px solid var(--line);
    border-radius: 6px;
}

.search-panel label,
.form-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--ink);
    font-weight: 800;
}

.search-row {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 12px;
}

.search-row input,
.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    min-height: 46px;
    border: 1px solid #bdc9d8;
    border-radius: 4px;
    padding: 11px 12px;
    color: var(--ink);
    background: #fff;
    font: inherit;
}

.form-group input[readonly] {
    color: var(--mayo-blue-dark);
    background: #eef6ff;
    border-color: #8fb6e8;
    font-weight: 800;
}

.form-group textarea {
    resize: vertical;
}

.search-row button {
    color: #fff;
    background: var(--mayo-blue-dark);
}

.search-feedback {
    margin: 12px 0 0;
    font-size: 0.95rem;
    color: var(--muted);
}

.specialty-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

.specialty-grid article,
.location-list article,
.estimate-form {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 6px;
}

.specialty-grid article,
.location-list article {
    padding: 26px;
}

.tile-kicker {
    display: inline-block;
    margin-bottom: 16px;
    color: var(--gold);
    font-size: 0.76rem;
    font-weight: 800;
    text-transform: uppercase;
}

.specialty-grid a {
    font-weight: 800;
}

.estimate-section {
    background: linear-gradient(180deg, #fff 0%, #f7fbff 100%);
}

.estimate-layout {
    display: grid;
    grid-template-columns: 0.9fr 1.1fr;
    gap: 58px;
    align-items: start;
}

.metrics-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-top: 34px;
}

.metrics-row div {
    padding: 18px;
    background: #fff;
    border-left: 4px solid var(--teal);
    box-shadow: 0 8px 24px rgba(16, 32, 56, 0.08);
}

.metrics-row strong {
    display: block;
    color: var(--mayo-blue-dark);
    font-size: 1.8rem;
    line-height: 1;
}

.metrics-row span {
    color: var(--muted);
    font-size: 0.9rem;
}

.estimate-form {
    padding: 30px;
    border-top: 5px solid var(--mayo-blue);
    box-shadow: 0 20px 46px rgba(16, 32, 56, 0.13);
}

.payment-tabs {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 36px 0 20px;
}

.tab-button {
    padding: 12px 20px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: #fff;
    color: var(--ink);
    font: inherit;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s, color 0.2s;
}

.tab-button[aria-selected="true"],
.tab-button.active {
    border-color: var(--mayo-blue);
    background: var(--mayo-blue);
    color: #fff;
}

.form-panels {
    display: grid;
}

.estimate-form[hidden] {
    display: none;
}

.payment-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
}

.payment-header h3 {
    margin-bottom: 4px;
}

.payment-header .form-note {
    margin: 0;
}

.trust-badge {
    display: inline-flex;
    align-items: center;
    min-height: 32px;
    padding: 6px 10px;
    color: #0f5f3f;
    background: #e9f8ef;
    border: 1px solid #a8dfbd;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 800;
    text-transform: uppercase;
}

.estimate-form fieldset {
    margin: 24px 0 0;
    padding: 22px 0 0;
    border: 0;
    border-top: 1px solid var(--line);
}

.estimate-form legend {
    padding-right: 14px;
    color: var(--mayo-blue-dark);
    font-size: 0.92rem;
    font-weight: 800;
    text-transform: uppercase;
}

.top-note {
    margin-bottom: 0;
    padding: 12px 14px;
    color: var(--ink);
    background: #eef6ff;
    border-left: 4px solid var(--mayo-blue);
}

.card-fieldset {
    padding-bottom: 4px;
}

.payment-summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 18px;
    padding: 16px;
    background: #f8fbff;
    border: 1px solid var(--line);
    border-radius: 6px;
}

.payment-summary span {
    color: var(--muted);
    font-weight: 700;
}

.payment-summary strong {
    color: var(--mayo-blue-dark);
    font-size: 1.45rem;
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.form-group {
    margin-bottom: 18px;
}

.full-button {
    width: 100%;
}

.form-note {
    margin: 14px 0 0;
    font-size: 0.88rem;
}

.field-error {
    min-height: 20px;
    margin: 8px 0 0;
    color: #b42318;
    font-size: 0.88rem;
    font-weight: 700;
}

.field-error:not(:empty) {
    padding: 8px 10px;
    background: #fff1f0;
    border-left: 4px solid #b42318;
    border-radius: 4px;
}

.primary-button:disabled {
    cursor: wait;
    opacity: 0.82;
}

.primary-button.is-loading::before {
    content: "";
    width: 16px;
    height: 16px;
    margin-right: 10px;
    border: 2px solid rgba(255, 255, 255, 0.55);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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

.location-layout {
    display: grid;
    grid-template-columns: 0.8fr 1.2fr;
    gap: 42px;
}

.location-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
}

.location-card {
    position: relative;
    min-height: 260px;
    border-radius: 18px;
    overflow: hidden;
    box-shadow: var(--shadow);
    background-size: cover;
    background-position: center;
}

.location-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(8, 22, 44, 0.08) 0%, rgba(8, 22, 44, 0.65) 100%);
}

.location-card a {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 24px;
    z-index: 1;
    color: #fff;
    text-decoration: none;
}

.location-label {
    display: inline-flex;
    margin-bottom: 8px;
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.12);
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
}

.location-card strong {
    font-size: 1.3rem;
    line-height: 1.2;
}

.location-arizona { background-image: url("assets/photo_campus_arizona-campus-sunset_1296x555.avif"); }
.location-florida { background-image: url("assets/photo_campus_florida-campus-palm-trees_1296x555.avif"); }
.location-minnesota { background-image: url("assets/photo_campus_minnesota-campus-courtyard-gonda_1296x555.avif"); }
.location-healthsystem { background-image: linear-gradient(180deg, rgba(0,0,0,0.14), rgba(0,0,0,0.45)), url("assets/healing-starts-here-MC11REJU-600x800.avif"); }
.location-london { background-image: linear-gradient(180deg, rgba(0,0,0,0.14), rgba(0,0,0,0.45)), url("assets/world-class care-MC1XASH-600x800.avif"); }

.request-section {
    background: var(--mayo-blue-dark);
    color: #fff;
}

.request-section h2,
.request-section .eyebrow {
    color: #fff;
}

.request-section p {
    max-width: 650px;
    color: rgba(255, 255, 255, 0.84);
}

.request-layout {
    justify-content: space-between;
}

.prototype-note {
    padding: 22px 0;
    background: #fff7e8;
    border-top: 1px solid #f3d7a9;
}

.prototype-note strong {
    color: var(--ink);
}

.site-footer {
    padding: 28px 0;
    color: #fff;
    background: #111827;
    font-size: 0.92rem;
}

.modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 40;
    padding: 24px;
    background: rgba(8, 22, 44, 0.64);
    overflow-y: auto;
}

.modal.is-visible {
    display: grid;
    place-items: center;
}

.modal-content {
    width: min(520px, 100%);
    max-height: calc(100vh - 48px);
    overflow-y: auto;
    position: relative;
    padding: 34px;
    background: #fff;
    border-radius: 8px;
    box-shadow: var(--shadow);
    text-align: center;
}

.modal-content h2 {
    font-size: clamp(2rem, 8vw, 3rem);
    overflow-wrap: anywhere;
}

.close-button {
    position: absolute;
    top: 12px;
    right: 16px;
    border: 0;
    background: transparent;
    color: var(--muted);
    font-size: 2rem;
    line-height: 1;
    cursor: pointer;
}

.modal-mark {
    width: 52px;
    height: 52px;
    display: inline-grid;
    place-items: center;
    margin-bottom: 18px;
    color: #fff;
    background: var(--teal);
    border-radius: 50%;
    font-size: 1.5rem;
    font-weight: 800;
}

.failure-mark {
    background: #b42318;
}

.modal-content p {
    color: var(--muted);
}

.support-callout {
    margin-top: 22px;
    padding: 18px;
    background: var(--soft);
    border: 1px solid var(--line);
    border-radius: 6px;
    text-align: left;
}

.support-callout span {
    display: block;
    color: var(--muted);
    font-size: 0.85rem;
    font-weight: 800;
    text-transform: uppercase;
}

.support-callout strong {
    display: block;
    margin: 4px 0 14px;
    color: var(--ink);
    font-size: 1.35rem;
    overflow-wrap: anywhere;
}

.modal-content .secondary-button {
    margin-top: 8px;
    background: var(--soft);
}

/* Modal is non-closable by clicking outside or pressing Escape for all forms */
body:has(.modal.is-visible) {
    overflow: hidden;
}

@media (max-width: 1080px) {
    .container {
        width: min(100% - 36px, 960px);
    }

    .hero-layout {
        align-items: flex-start;
        gap: 24px;
    }

    .hero-copy {
        width: 100%;
        padding-bottom: 48px;
    }

    .hero-image-grid {
        grid-template-columns: 1fr;
    }

    .estimate-layout {
        grid-template-columns: 1fr;
        gap: 34px;
    }

    .estimate-form {
        width: min(760px, 100%);
    }

    .section-heading.compact {
        max-width: 620px;
    }
}

@media (max-width: 860px) {
    .nav-wrap,
    .strip-inner,
    .footer-inner {
        align-items: flex-start;
        flex-direction: column;
    }

    .nav-wrap {
        padding: 16px 0;
        gap: 14px;
    }

    .main-nav {
        width: 100%;
        overflow-x: auto;
        gap: 18px;
        padding-bottom: 4px;
        scrollbar-width: thin;
        justify-content: flex-start;
    }

    .main-nav a {
        white-space: normal;
    }

    .hero-layout {
        flex-direction: column;
        align-items: stretch;
    }

    .hero-section,
    .hero-layout {
        min-height: auto;
    }

    .hero-copy {
        padding: 36px 0 30px;
        text-align: center;
    }

    .hero-image-grid {
        grid-template-columns: 1fr;
    }

    .hero-image-grid img {
        min-height: 200px;
    }

    .payment-tabs {
        width: 100%;
    }

    .tab-button {
        flex: 1 1 0;
        min-width: 0;
    }

    .form-panels,
    .estimate-form {
        width: 100%;
    }

    .form-grid {
        grid-template-columns: 1fr;
    }

    .action-grid,
    .specialty-grid,
    .location-layout {
        grid-template-columns: 1fr;
    }

    .action-grid a {
        min-height: auto;
        border-right: 0;
        border-bottom: 1px solid var(--line);
    }

    .action-grid a:last-child {
        border-bottom: 0;
    }

    .quick-actions {
        margin-top: 0;
    }

    .section-band,
    .estimate-section,
    .request-section {
        padding: 66px 0;
    }

    .metrics-row {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .modal {
        padding: 18px;
    }
}

@media (max-width: 640px) {
    .container {
        width: min(100% - 28px, 1120px);
    }

    .brand-text {
        font-size: 0.95rem;
    }

    .main-nav {
        font-size: 0.9rem;
    }

    .hero-section,
    .hero-layout {
        min-height: auto;
    }

    .hero-media {
        background-image: linear-gradient(180deg, rgba(0, 39, 96, 0.9) 0%, rgba(0, 61, 165, 0.7) 58%, rgba(0, 61, 165, 0.25) 100%), url("assets/healthcare-hero.png");
        background-position: 70% center;
    }

    .hero-copy {
        padding: 34px 0 40px;
    }

    .hero-actions {
        display: grid;
        grid-template-columns: 1fr;
    }

    .search-row,
    .form-grid,
    .metrics-row,
    .request-layout {
        grid-template-columns: 1fr;
    }

    .hero-actions,
    .request-layout {
        align-items: stretch;
    }

    .primary-button,
    .secondary-button,
    .search-row button {
        width: 100%;
    }

    .estimate-form,
    .search-panel,
    .specialty-grid article,
    .location-list article {
        padding: 22px;
    }

    .payment-tabs {
        gap: 8px;
    }

    .tab-button {
        width: 100%;
    }

    .hero-image-grid {
        gap: 10px;
    }

    .hero-image-grid img {
        min-height: 160px;
    }

    .hero-copy h1 {
        font-size: clamp(2rem, 10vw, 2.6rem);
    }

    .hero-lede {
        font-size: 1.05rem;
    }
}

    .payment-header {
        align-items: flex-start;
        flex-direction: column;
        gap: 10px;
    }

    .payment-summary {
        align-items: flex-start;
        flex-direction: column;
        gap: 6px;
    }

    .modal-content {
        padding: 28px 24px;
    }

    .support-callout {
        padding: 16px;
    }
}

@media (max-width: 430px) {
    .container {
        width: min(100% - 22px, 1120px);
    }

    .nav-wrap {
        min-height: auto;
    }

    .brand {
        gap: 10px;
    }

    .brand-mark {
        width: 36px;
        height: 36px;
    }

    .brand-text {
        font-size: 0.86rem;
    }

    .main-nav {
        gap: 12px;
        font-size: 0.84rem;
    }

    .main-nav .nav-action {
        padding: 9px 12px;
    }

    h1 {
        font-size: clamp(2rem, 12vw, 2.7rem);
    }

    h2 {
        font-size: clamp(1.55rem, 9vw, 2.15rem);
    }

    .hero-lede {
        font-size: 1.03rem;
    }

    .section-band,
    .estimate-section,
    .request-section {
        padding: 52px 0;
    }

    .action-grid a,
    .estimate-form,
    .search-panel,
    .specialty-grid article,
    .location-list article {
        padding: 18px;
    }

    .estimate-form fieldset {
        margin-top: 20px;
        padding-top: 18px;
    }

    .form-group input,
    .form-group select,
    .form-group textarea,
    .search-row input {
        min-height: 48px;
        font-size: 1rem;
    }

    .primary-button,
    .secondary-button,
    .search-row button {
        min-height: 48px;
        padding: 12px 14px;
    }

    .modal {
        padding: 12px;
    }

    .modal-content {
        max-height: calc(100vh - 24px);
        padding: 24px 18px;
    }

    .modal-mark {
        width: 46px;
        height: 46px;
        margin-bottom: 14px;
    }

    .modal-content h2 {
        margin-bottom: 12px;
        font-size: clamp(1.8rem, 11vw, 2.35rem);
    }

    .support-callout strong {
        font-size: 1.12rem;
    }
}

@media (max-width: 350px) {
    .container {
        width: min(100% - 18px, 1120px);
    }

    .main-nav {
        gap: 10px;
        font-size: 0.8rem;
    }

    .estimate-form,
    .search-panel,
    .support-callout {
        padding: 14px;
    }

    .payment-summary {
        padding: 14px;
    }

    .modal-content {
        padding: 22px 14px;
    }
}
