:root {
    --navy: #183665; --navy-dark: #10264a; --gold: #B9A92D; --gold-soft: #f3efd6;
    --ink: #1F1F1F; --text: #4C4C4C; --line: #d9dde4; --bg: #f5f6f8; --danger: #b3261e;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
body { font: 400 16px/1.6 Barlow, 'Helvetica Neue', Arial, sans-serif; color: var(--text); background: var(--bg); min-height: 100vh; }
.topbar { background: var(--navy); color: #fff; font-size: 14px; }
.topbar .wrap { max-width: 1040px; margin: 0 auto; padding: 8px 20px; text-align: right; }
.topbar a { color: #fff; text-decoration: none; }
.site-header { background: #fff; border-bottom: 4px solid var(--gold); }
.site-header .wrap { max-width: 1040px; margin: 0 auto; padding: 18px 20px; display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.site-header img { height: 56px; width: auto; display: block; }
.powered { font-size: 13px; }
.powered strong { color: var(--navy); font-weight: 500; }
.hero { background: var(--navy); color: #fff; padding: 40px 20px 72px; clip-path: ellipse(140% 100% at 50% 0%); }
.hero .wrap { max-width: 760px; margin: 0 auto; }
.hero h1 { font: 600 clamp(32px, 5vw, 44px)/1.05 'Barlow Condensed', 'Arial Narrow', sans-serif; text-transform: uppercase; letter-spacing: .5px; margin-bottom: 10px; }
.hero p { color: #d8e0ee; max-width: 56ch; }
.container { max-width: 760px; margin: -44px auto 24px; background: #fff; border: 1px solid var(--line); border-radius: 6px; overflow: hidden; position: relative; }
.progress-bar { background: #e4e7ec; height: 6px; }
.progress-fill { background: var(--gold); height: 100%; transition: width 0.3s ease; }
.step-indicator { padding: 14px 28px; font-size: 14px; border-bottom: 1px solid var(--line); }
.step-indicator strong { color: var(--navy); font-weight: 500; }
.form-content { padding: 28px; }
.step { display: none; }
.step.active { display: block; }
.step-title { font: 600 28px/1.1 'Barlow Condensed', 'Arial Narrow', sans-serif; color: var(--ink); text-transform: uppercase; margin-bottom: 22px; }
.form-group { margin-bottom: 18px; }
label { display: block; font-size: 15px; font-weight: 500; color: var(--ink); margin-bottom: 6px; }
input, select { width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-radius: 4px; font: inherit; color: var(--ink); background: #fff; }
input:focus, select:focus { outline: none; border-color: var(--navy); box-shadow: 0 0 0 3px rgba(24, 54, 101, .15); }
small { display: block; font-size: 13px; margin-top: 4px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.error { color: var(--danger); font-size: 13px; margin-top: 5px; display: none; }
.error.show { display: block; }
.buttons { display: flex; gap: 12px; justify-content: space-between; margin-top: 26px; padding-top: 20px; border-top: 1px solid var(--line); }
button { font: 600 18px/1 'Barlow Condensed', 'Arial Narrow', sans-serif; text-transform: uppercase; letter-spacing: .5px; padding: 14px 26px; border-radius: 4px; border: 2px solid var(--navy); cursor: pointer; }
button:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }
.btn-back { background: #fff; color: var(--navy); }
.btn-next { background: var(--navy); color: #fff; margin-left: auto; }
.btn-next:hover { background: var(--navy-dark); }
.summary { background: var(--bg); padding: 18px 20px; border-radius: 4px; border-left: 4px solid var(--gold); margin-bottom: 20px; }
.summary-row { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.summary-row:last-child { border-bottom: none; }
.premium-box { background: var(--navy); color: #d8e0ee; padding: 22px; border-radius: 6px; text-align: center; margin: 20px 0; }
.premium-value { font: 600 38px/1 'Barlow Condensed', 'Arial Narrow', sans-serif; color: #fff; margin-top: 8px; }
.loading { text-align: center; padding: 40px 20px; display: none; }
.spinner { border: 4px solid #e4e7ec; border-top: 4px solid var(--navy); border-radius: 50%; width: 40px; height: 40px; animation: spin 1s linear infinite; margin: 0 auto 20px; }
@keyframes spin { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } }
.site-footer { max-width: 760px; margin: 0 auto 40px; padding: 0 20px; font-size: 13px; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.site-footer a { color: var(--navy); }
@media (max-width: 560px) {
    .form-row { grid-template-columns: 1fr; }
    .form-content { padding: 20px; }
    .container { margin-left: 12px; margin-right: 12px; }
}

/* Round 1 additions */
.req { color: var(--danger); }
textarea { width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-radius: 4px; font: inherit; color: var(--ink); background: #fff; resize: vertical; }
textarea:focus { outline: none; border-color: var(--navy); box-shadow: 0 0 0 3px rgba(24, 54, 101, .15); }
.summary-section { font: 600 16px/1.2 'Barlow Condensed', 'Arial Narrow', sans-serif; text-transform: uppercase; letter-spacing: .5px; color: var(--navy); padding: 14px 0 4px; }
.summary-section:first-child { padding-top: 0; }
.summary-row span:last-child { text-align: right; color: var(--ink); }

/* Round 2: loss runs table */
.step-note { font-size: 14px; margin-bottom: 14px; }
.loss-table { border: 1px solid var(--line); border-radius: 4px; overflow-x: auto; }
.loss-row { display: grid; grid-template-columns: 1.2fr repeat(4, 1fr); gap: 10px; align-items: end; padding: 12px 14px; border-bottom: 1px solid var(--line); min-width: 620px; }
.loss-row:last-child { border-bottom: none; }
.loss-head { background: var(--bg); font-size: 13px; font-weight: 500; color: var(--ink); align-items: center; }
.loss-year { font-weight: 500; color: var(--ink); padding-bottom: 10px; }
.loss-year small { font-weight: 400; margin-top: 2px; }
.loss-row input { padding: 8px 10px; }
.loss-row input:disabled { background: var(--bg); color: #9aa1ab; }
.loss-row input.invalid { border-color: var(--danger); }
.loss-cell-label { display: none; font-size: 12px; margin-bottom: 4px; }
@media (max-width: 560px) {
    .loss-table { overflow-x: visible; }
    .loss-row { grid-template-columns: 1fr 1fr; min-width: 0; }
    .loss-head { display: none; }
    .loss-year { grid-column: 1 / -1; padding-bottom: 0; }
    .loss-cell-label { display: block; }
}

/* Round 3: locations & class codes */
.location-card { border: 1px solid var(--line); border-radius: 6px; margin-bottom: 16px; }
.location-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 16px; background: var(--bg); border-bottom: 1px solid var(--line); border-radius: 6px 6px 0 0; }
.location-title { font: 600 18px/1.2 'Barlow Condensed', 'Arial Narrow', sans-serif; text-transform: uppercase; letter-spacing: .5px; color: var(--navy); }
.location-title small { display: inline; font: 400 13px Barlow, Arial, sans-serif; text-transform: none; letter-spacing: 0; color: var(--text); margin-left: 6px; }
.location-body { padding: 16px; }
.form-row-3 { display: grid; grid-template-columns: 1fr 1.4fr 1fr; gap: 16px; }
.btn-add, .btn-remove { font: 500 15px Barlow, Arial, sans-serif; text-transform: none; letter-spacing: 0; padding: 8px 14px; border-radius: 4px; cursor: pointer; }
.btn-add { background: #fff; color: var(--navy); border: 1px dashed var(--navy); }
.btn-add:hover { background: var(--gold-soft); }
.btn-remove { background: transparent; color: var(--danger); border: 1px solid transparent; padding: 6px 10px; }
.btn-remove:hover { border-color: var(--danger); }
.class-search { position: relative; margin-bottom: 12px; }
.class-results { position: absolute; z-index: 10; left: 0; right: 0; top: 100%; background: #fff; border: 1px solid var(--line); border-radius: 4px; box-shadow: 0 8px 20px rgba(0,0,0,.12); max-height: 260px; overflow-y: auto; list-style: none; margin: 4px 0 0; padding: 0; }
.class-results li { padding: 9px 12px; cursor: pointer; font-size: 14px; border-bottom: 1px solid var(--bg); }
.class-results li:hover, .class-results li.active { background: var(--gold-soft); }
.class-results li b { color: var(--navy); font-weight: 600; margin-right: 8px; }
.class-results li.empty { cursor: default; color: var(--text); }
.class-table { border: 1px solid var(--line); border-radius: 4px; overflow-x: auto; }
.class-row { display: grid; grid-template-columns: 2.4fr 0.8fr 0.8fr 1.2fr auto; gap: 10px; align-items: center; padding: 10px 12px; border-bottom: 1px solid var(--line); min-width: 600px; }
.class-row:last-child { border-bottom: none; }
.class-row.head { background: var(--bg); font-size: 13px; font-weight: 500; color: var(--ink); }
.class-desc b { color: var(--navy); font-weight: 600; display: block; font-size: 14px; }
.class-desc span { font-size: 12px; line-height: 1.3; display: block; }
.class-row input { padding: 8px 10px; }
.class-row input.invalid, .location-body input.invalid, .location-body select.invalid { border-color: var(--danger); }
.class-empty { padding: 14px; font-size: 14px; text-align: center; }
.location-total { display: flex; justify-content: flex-end; gap: 18px; font-size: 14px; padding-top: 10px; }
.location-total b { color: var(--ink); font-weight: 500; }
.loc-error { color: var(--danger); font-size: 13px; margin-top: 8px; }
@media (max-width: 560px) {
    .form-row-3 { grid-template-columns: 1fr; }
    .class-table { overflow-x: visible; }
    .class-row { grid-template-columns: 1fr 1fr; min-width: 0; }
    .class-row.head { display: none; }
    .class-desc { grid-column: 1 / -1; }
}

/* Round 4: underwriting questions */
.uw-subtitle { font: 600 18px/1.2 'Barlow Condensed', 'Arial Narrow', sans-serif; text-transform: uppercase; letter-spacing: .5px; color: var(--navy); margin: 22px 0 10px; }
.uw-q { display: flex; justify-content: space-between; align-items: flex-start; gap: 18px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.uw-q.child { padding-left: 22px; border-left: 3px solid var(--gold); margin-left: 4px; }
.uw-text { color: var(--ink); font-size: 15px; }
.uw-text ul { margin: 6px 0 0 18px; }
.uw-text li { margin: 2px 0; }
.uw-q.invalid .uw-text { color: var(--danger); }
.uw-options { display: flex; gap: 8px; flex-shrink: 0; }
.uw-options label { display: flex; align-items: center; gap: 6px; margin: 0; padding: 6px 14px; border: 1px solid var(--line); border-radius: 4px; cursor: pointer; font-weight: 400; }
.uw-options input { width: auto; margin: 0; }
.uw-options label:has(input:checked) { border-color: var(--navy); background: var(--gold-soft); }
@media (max-width: 560px) { .uw-q { flex-direction: column; gap: 8px; } }

/* Round 5: reservation notice */
.notice-block { margin-top: 18px; padding: 14px 16px; border-left: 4px solid var(--gold); background: var(--gold-soft); border-radius: 4px; color: var(--ink); font-size: 15px; }
.notice-block b { display: block; margin-bottom: 4px; color: var(--navy); }
.notice-block a { color: var(--navy); font-weight: 500; white-space: nowrap; }

/* Round 6: owners & officers */
.owners-section { margin-top: 18px; padding-top: 14px; border-top: 1px dashed var(--line); }
.owners-section > label { margin-bottom: 2px; }
.muted { display: inline; font-size: 13px; color: var(--text); font-weight: 400; }
.owner-card { border: 1px solid var(--line); border-left: 4px solid var(--gold); border-radius: 4px; padding: 12px 14px; margin-bottom: 12px; background: #fff; }
.owner-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; color: var(--navy); }
.owner-card .uw-options label { font-weight: 400; }
.owner-questions { margin-top: 4px; }
.owner-card select.invalid, .owner-card input.invalid { border-color: var(--danger); }

/* Round 7: quote results */
.mock-banner { background: #fff4d6; border: 1px dashed var(--gold); color: #5a5215; font-size: 13px; padding: 8px 12px; border-radius: 4px; margin-bottom: 16px; }
.result-head { padding: 18px 20px; border-radius: 6px; margin-bottom: 18px; border-left: 5px solid var(--navy); background: var(--bg); }
.result-head h2 { font: 600 28px/1.1 'Barlow Condensed', 'Arial Narrow', sans-serif; text-transform: uppercase; color: var(--ink); margin-bottom: 6px; }
.result-head.ready { border-left-color: #2e7d32; }
.result-head.review { border-left-color: var(--gold); background: var(--gold-soft); }
.result-head.error { border-left-color: var(--danger); background: #fdf1f0; }
.result-head a { color: var(--navy); font-weight: 500; white-space: nowrap; }
.premium-min { display: block; margin-top: 6px; color: #d8e0ee; }
.breakdown { border: 1px solid var(--line); border-radius: 4px; }
.bd-group { background: var(--bg); padding: 8px 14px; font-weight: 500; color: var(--navy); font-size: 14px; border-bottom: 1px solid var(--line); }
.bd-row { display: flex; justify-content: space-between; gap: 16px; padding: 10px 14px; border-bottom: 1px solid var(--line); font-size: 14px; color: var(--ink); }
.bd-row small { display: block; color: var(--text); font-size: 12px; }
.bd-row b { color: var(--navy); font-weight: 600; }
.bd-amt { white-space: nowrap; font-variant-numeric: tabular-nums; }
.bd-amt.credit { color: #2e7d32; }
.bd-total { font-weight: 600; background: var(--gold-soft); border-bottom: none; }
.result-msgs { list-style: none; padding: 0; margin: 0 0 8px; }
.result-msgs li { padding: 10px 12px; border: 1px solid var(--line); border-left: 3px solid var(--gold); border-radius: 4px; margin-bottom: 8px; font-size: 14px; color: var(--ink); }
.link-btn { background: none; border: none; padding: 0; margin-left: 6px; font: 500 14px Barlow, Arial, sans-serif; text-transform: none; letter-spacing: 0; color: var(--navy); text-decoration: underline; cursor: pointer; }
.result-actions { display: flex; gap: 12px; justify-content: space-between; flex-wrap: wrap; margin-top: 22px; }
.btn-link { display: inline-block; text-decoration: none; text-align: center; padding: 14px 26px; border-radius: 4px; font: 600 18px/1 'Barlow Condensed', 'Arial Narrow', sans-serif; text-transform: uppercase; letter-spacing: .5px; border: 2px solid var(--navy); }
.result-id { font-size: 13px; margin-top: 16px; }
.result-new { margin-top: 14px; text-align: center; }

/* Round 9: mailing address + coverage options */
.check-label { display: flex; align-items: center; gap: 8px; font-weight: 400; cursor: pointer; }
.check-label input { width: auto; margin: 0; }
.mailing-toggle { margin-top: 4px; }
.options-box { border: 1px solid var(--line); border-radius: 4px; padding: 16px; }
.plan-option { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border: 1px solid var(--line); border-radius: 4px; margin-bottom: 8px; cursor: pointer; font-weight: 400; }
.plan-option input { width: auto; margin-top: 3px; }
.plan-option b { color: var(--ink); font-weight: 500; }
.plan-option small { display: block; margin-top: 2px; }
.plan-option:has(input:checked) { border-color: var(--navy); background: var(--gold-soft); }
#updateOptionsBtn:disabled { opacity: .5; cursor: default; }

/* Purchase (Pay at Bind) */
.purchase-box { border: 1px solid var(--line); border-radius: 4px; padding: 16px; margin-bottom: 16px; }
.purchase-box > p { margin-bottom: 8px; }
.purchase-due { font-size: 17px; color: var(--ink); }
.purchase-due b { color: var(--navy); font-weight: 600; }
.disclaimer-box { background: var(--bg); border-left: 4px solid var(--gold); padding: 12px 14px; font-size: 14px; color: var(--ink); margin: 12px 0; max-height: 220px; overflow-y: auto; }
.check-row { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; margin-bottom: 10px; cursor: pointer; }
.check-row input { width: auto; margin-top: 4px; }
.purchase-box .btn-next { margin-top: 6px; }
.btn-next:disabled { opacity: .5; cursor: not-allowed; }
.payment-section:not(:empty) { margin-top: 16px; min-height: 120px; }
.confirm-purchase { margin-top: 16px; padding: 14px; border: 2px solid var(--navy); border-radius: 4px; background: var(--gold-soft); }
.confirm-purchase p { color: var(--ink); margin-bottom: 10px; }
.mock-pay { border: 1px dashed var(--gold); background: #fff4d6; border-radius: 4px; padding: 14px; font-size: 14px; color: #5a5215; }
.mock-pay p { margin: 6px 0 10px; }
.mock-pay label { color: #5a5215; font-weight: 500; }
.mock-pay select { margin: 6px 0 12px; }

/* Documents */
.docs-box { border: 1px solid var(--line); border-radius: 4px; padding: 6px 16px; margin-bottom: 12px; }
.doc-list { list-style: none; margin: 0; padding: 0; }
.doc-list li { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); color: var(--ink); }
.doc-list li:last-child { border-bottom: none; }
.doc-list small { display: block; color: var(--text); }
.class-results li small { display: block; font-size: 12px; color: var(--text); margin-top: 2px; }
.class-results li.unavailable { cursor: default; color: #8a8f98; }
.class-results li.unavailable:hover { background: transparent; }
.class-results li.unavailable b { color: #8a8f98; }
.fixed-value { padding: 10px 12px; border: 1px solid var(--line); border-radius: 4px; background: var(--bg); color: var(--ink); }
.pay-help { margin-top: 14px; padding: 10px 12px; border-left: 4px solid var(--navy); background: var(--bg); color: var(--ink); font-size: 14px; }
.companion-hint { display: flex; gap: 12px; align-items: center; justify-content: space-between; margin: 8px 0; padding: 10px 12px; border-left: 4px solid var(--gold, #b9a92d); background: var(--bg); font-size: 14px; }
.companion-hint .link-btn { white-space: nowrap; }
.summary-row .paid-note { display: block; font-size: 12px; color: var(--text, #4C4C4C); margin-top: 2px; }
