:root {
    --bg: #eef1f5;
    --panel: #ffffff;
    --panel-soft: #f5f7fa;
    --line: #c9d0da;
    --line-strong: #aab3bf;
    --text: #203040;
    --muted: #617287;
    --navy: #334055;
    --green: #0b6a3d;
    --green-soft: #dff4e8;
    --orange: #f47a00;
    --orange-soft: #fff0e1;
    --shadow: 0 18px 42px rgba(34, 47, 62, 0.08);
    --radius: 18px;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    min-height: 100vh;
    color: var(--text);
    font-family: "Avenir Next", "Trebuchet MS", "Segoe UI", sans-serif;
    background:
        radial-gradient(circle at top right, rgba(244, 122, 0, 0.08), transparent 28%),
        linear-gradient(180deg, #f7f9fc 0%, #edf1f6 100%);
}

.page-shell {
    width: calc(100vw - 12px);
    margin: 6px auto 20px;
    min-height: calc(100vh - 12px);
    display: flex;
    flex-direction: column;
}

.brand-bar, .search-card, .filters-card, .table-card, .details-panel {
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.brand-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 6px;
    z-index: 15;
    gap: 16px;
    padding: 14px 18px;
    margin-bottom: 14px;
}

.brand-lockup {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
}

.brand-side {
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-items: flex-end;
    min-width: 0;
}

.brand-logo {
    width: 210px;
    max-width: 28vw;
    display: block;
}

.eyebrow {
    margin: 0 0 6px;
    color: var(--orange);
    font-size: 0.76rem;
    font-weight: 700;
    letter-spacing: 0.11em;
    text-transform: uppercase;
}

.brand-lockup h1, .filters-card h2, .table-card h2, .details-panel h2, .search-card h2 {
    margin: 0;
    font-size: 1.18rem;
    line-height: 1.1;
}

.subcopy, .details-address, .filters-summary, .details-placeholder p, .error-message {
    margin: 4px 0 0;
    color: var(--muted);
    font-size: 0.8rem;
}

.brand-stats {
    display: flex;
    flex-wrap: nowrap;
    gap: 8px;
    align-items: stretch;
    min-width: 0;
}

.account-actions {
    display: flex;
    align-items: flex-start;
    justify-content: flex-end;
    gap: 10px;
    flex-wrap: wrap;
}

.account-chip,
.account-link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    min-height: 36px;
    padding: 8px 12px;
    border-radius: 10px;
    border: 1px solid var(--line);
    background: #f7f9fc;
    color: var(--navy);
    text-decoration: none;
}

.account-chip {
    flex-direction: column;
    align-items: start;
    gap: 2px;
}

.account-chip-primary {
    min-width: 280px;
}

.account-chip-title {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--text);
}

.account-chip-subtitle {
    font-size: 0.82rem;
    color: var(--text);
}

.account-chip-meta {
    font-size: 0.7rem;
    color: var(--muted);
}

.account-role {
    color: #2b5fb8;
}

.sender-chip {
    max-width: 260px;
}

.stat {
    min-width: 0;
    padding: 9px 11px;
    background: linear-gradient(180deg, var(--panel-soft), #eef2f6);
    border: 1px solid var(--line);
    border-radius: 12px;
    white-space: nowrap;
}

.stat-cache {
    background: linear-gradient(180deg, #eef8f1, #dff4e8);
    border-color: #9ad0ae;
}

.stat-label {
    display: block;
    margin-bottom: 3px;
    color: var(--muted);
    font-size: 0.66rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.stat strong {
    font-size: 0.95rem;
    line-height: 1;
}

.search-card {
    padding: 16px 18px;
    margin-bottom: 12px;
}

.search-card-compact { padding: 10px 14px; }

.flash-stack {
    display: grid;
    gap: 10px;
    margin-bottom: 12px;
}

.flash-message {
    padding: 12px 14px;
    border-radius: 12px;
    border: 1px solid var(--line);
    background: #f7f9fc;
    font-size: 0.88rem;
}

.flash-success {
    border-color: #9ad0ae;
    background: #ebf8ef;
    color: var(--green);
}

.flash-error {
    border-color: #e4b2ae;
    background: #fff2f0;
    color: #9a3c30;
}

.flash-warning {
    border-color: #f2c594;
    background: #fff6e8;
    color: #965c12;
}

.zip-search-form {
    display: flex;
    align-items: end;
    gap: 14px;
}

.zip-field { width: min(360px, 100%); }

.zip-field label, .filters-grid label span, .detail-label {
    display: block;
    margin-bottom: 6px;
    font-size: 0.66rem;
    font-weight: 700;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

input, select, .primary-button, .secondary-button {
    height: 40px;
    border-radius: 10px;
    border: 1px solid var(--line-strong);
    font: inherit;
}

input, select {
    width: 100%;
    padding: 0 12px;
    background: #fff;
    color: var(--text);
    font-size: 0.9rem;
}

.primary-button, .secondary-button, .details-link { cursor: pointer; }

.primary-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 144px;
    padding: 0 16px;
    border: none;
    color: #fff;
    font-weight: 700;
    background: linear-gradient(135deg, var(--green), #159553);
    text-decoration: none;
}

.secondary-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 0 16px;
    color: var(--navy);
    font-weight: 700;
    background: linear-gradient(180deg, #f8fafc, #e9eef5);
    font-size: 0.9rem;
    text-decoration: none;
}

.refresh-button {
    position: relative;
    gap: 8px;
}

.refresh-button-spinner {
    width: 14px;
    height: 14px;
    border: 2px solid rgba(54, 64, 82, 0.24);
    border-top-color: var(--navy);
    border-radius: 999px;
    display: none;
    animation: refresh-spin 0.8s linear infinite;
}

.refresh-button.is-loading {
    pointer-events: none;
    opacity: 0.76;
}

.refresh-button.is-loading .refresh-button-spinner {
    display: inline-block;
}

@keyframes refresh-spin {
    to { transform: rotate(360deg); }
}

.results-shell {
    display: grid;
    grid-template-columns: minmax(0, 2.7fr) minmax(330px, 1fr);
    gap: 12px;
    align-items: start;
    flex: 1 1 auto;
    min-height: 0;
}

.results-main {
    min-width: 0;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.filters-card {
    padding: 12px 14px;
    margin-bottom: 10px;
}

.filters-topline, .table-card-header, .details-header {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    align-items: start;
}

.filters-summary {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    font-size: 0.76rem;
}

.filters-summary span, .detail-meta span {
    padding: 5px 8px;
    border-radius: 999px;
    background: var(--panel-soft);
    border: 1px solid var(--line);
}

.filters-grid {
    display: grid;
    grid-template-columns: 1.02fr 1.02fr 1.02fr 1fr 1fr 0.92fr 0.92fr 1fr;
    gap: 8px;
    margin-top: 12px;
}

.filters-actions {
    display: flex;
    align-items: end;
}

.filters-grid label span {
    margin-bottom: 5px;
    font-size: 0.6rem;
    letter-spacing: 0.09em;
}

.filters-grid select,
.filters-grid .secondary-button {
    height: 36px;
    font-size: 0.82rem;
    padding-left: 10px;
    padding-right: 10px;
}

.table-card {
    overflow: hidden;
    display: flex;
    flex-direction: column;
    min-height: 0;
    flex: 1 1 auto;
}

.table-card-header { padding: 12px 14px 8px; }

.keyword-chip-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
}

.keyword-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 30px;
    padding: 0 12px;
    border: 1px solid rgba(244, 122, 0, 0.24);
    border-radius: 999px;
    background: #fff7ef;
    color: #a85708;
    font-size: 0.76rem;
    font-weight: 700;
    text-decoration: none;
}

.keyword-chip strong {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 24px;
    height: 22px;
    padding: 0 7px;
    border-radius: 999px;
    background: rgba(244, 122, 0, 0.12);
    color: inherit;
    font-size: 0.72rem;
}

.keyword-chip.is-active {
    border-color: rgba(11, 106, 61, 0.28);
    background: #edf8f1;
    color: var(--green);
}

.keyword-chip.is-active strong {
    background: rgba(11, 106, 61, 0.12);
}

.keyword-chip-clear {
    border-color: var(--line);
    background: #f7f9fc;
    color: var(--navy);
}

.results-table-wrap {
    padding: 0 8px 8px;
    flex: 1 1 auto;
    min-height: 0;
    overflow: auto;
}

.toolbar-row {
    display: flex;
    justify-content: flex-end;
    margin-top: 10px;
}

.toolbar-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.results-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
    font-size: 0.75rem;
}

.results-table .col-slno { width: 64px; }
.results-table .col-date { width: 132px; }
.results-table .col-status { width: 122px; }
.results-table .col-job-value { width: 128px; }
.results-table .col-details { width: 98px; }
.results-table .col-scope { width: auto; }
.results-table .col-address { width: 260px; }

.results-table thead th {
    position: sticky;
    top: 0;
    z-index: 2;
    padding: 8px 8px;
    text-align: left;
    color: #eff4ff;
    font-size: 0.62rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    background: linear-gradient(180deg, #4b5568, #364052);
}

.table-sort-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: inherit;
    text-decoration: none;
}

.table-sort-link.is-active {
    color: #ffffff;
}

.table-sort-indicator {
    font-size: 0.72rem;
    line-height: 1;
}

.results-table tbody td {
    padding: 7px 8px;
    border-top: 1px solid #dde4ec;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.results-table tbody tr:nth-child(odd) { background: #f7f9fc; }

.results-table tbody tr.is-active { background: #e9f4ee; }

.score-pill, .status-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 42px;
    height: 24px;
    padding: 0 8px;
    border-radius: 999px;
    font-weight: 800;
    font-size: 0.7rem;
}

.score-pill {
    color: var(--green);
    background: var(--green-soft);
}

.status-pill {
    color: var(--navy);
    background: #e7edf4;
}

.numeric-cell, .mono-cell { font-variant-numeric: tabular-nums; }

.mono-cell { font-family: "IBM Plex Mono", "Consolas", monospace; }

.slno-cell {
    color: var(--muted);
    text-align: center;
}

.results-table thead th:nth-child(5),
.results-table tbody td:nth-child(5) {
    width: auto;
}

.results-table thead th:nth-child(6),
.results-table tbody td:nth-child(6) {
    width: 260px;
}

.cell-copy-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
}

.cell-copy-text {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
}

.details-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 62px;
    height: 28px;
    border: 1px solid rgba(244, 122, 0, 0.38);
    border-radius: 8px;
    background: var(--orange-soft);
    color: #b35700;
    font-weight: 700;
    font-size: 0.72rem;
}

.ghost-button,
.copy-icon {
    cursor: pointer;
}

.excel-button,
.contact-icon {
    text-decoration: none;
}

.excel-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    min-width: 126px;
    height: 34px;
    border-radius: 8px;
    border: 1px solid rgba(11, 106, 61, 0.24);
    background: #edf8f1;
    color: var(--green);
    font-size: 0.95rem;
    cursor: pointer;
}

.sms-button {
    border-color: rgba(51, 64, 85, 0.18);
    background: #eef2f8;
    color: var(--navy);
}

.excel-button-icon {
    line-height: 1;
}

.excel-button-text {
    font-size: 0.8rem;
    font-weight: 700;
}

.ghost-button {
    height: 34px;
    padding: 0 12px;
    border-radius: 8px;
    border: 1px solid rgba(11, 106, 61, 0.24);
    background: #edf8f1;
    color: var(--green);
    font: inherit;
    font-weight: 700;
    font-size: 0.82rem;
}

.copy-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: #f7f9fc;
    color: var(--navy);
    font-size: 0.72rem;
    line-height: 1;
    flex: 0 0 auto;
}

.copy-inline {
    margin-left: 8px;
}

.contact-icons {
    display: flex;
    align-items: center;
    gap: 8px;
}

.contact-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #f7f9fc;
    color: var(--navy);
    font-size: 0.82rem;
}

.contact-empty {
    color: var(--muted);
}

.empty-state-cell {
    text-align: center;
    color: var(--muted);
}

.details-panel {
    position: sticky;
    top: 86px;
    min-height: 0;
    max-height: calc(100vh - 102px);
    padding: 12px;
}

.details-shell {
    display: flex;
    flex-direction: column;
    gap: 12px;
    min-height: 0;
}

.details-tabs {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.details-tab {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 120px;
    height: 38px;
    padding: 0 14px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: linear-gradient(180deg, #f9fbfe, #eef3f8);
    color: var(--navy);
    font: inherit;
    font-weight: 700;
    cursor: pointer;
}

.details-tab.is-active {
    background: linear-gradient(135deg, var(--green), #159553);
    color: #fff;
    border-color: rgba(11, 106, 61, 0.28);
}

.details-view {
    min-height: 0;
}

.details-content {
    max-height: calc(100vh - 180px);
    overflow-y: auto;
    padding-right: 4px;
}

.map-tab-content {
    max-height: calc(100vh - 180px);
    overflow-y: auto;
    padding-right: 4px;
}

.map-card {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.map-card-header {
    display: flex;
    justify-content: space-between;
    align-items: start;
    gap: 12px;
}

.map-open-link {
    width: auto;
    min-width: 180px;
    white-space: nowrap;
}

.map-frame-shell {
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: linear-gradient(180deg, #fbfcfe, #f1f4f8);
    min-height: 320px;
}

.map-frame {
    width: 100%;
    height: 320px;
    border: 0;
}

.map-location-list {
    display: grid;
    gap: 10px;
}

.map-location-item {
    display: grid;
    grid-template-columns: 34px minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 12px 14px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: linear-gradient(180deg, #fbfcfe, #f3f6fa);
    text-align: left;
    cursor: pointer;
}

.map-location-item.is-selected {
    border-color: rgba(11, 106, 61, 0.24);
    background: linear-gradient(180deg, #f1faf4, #e5f2ea);
}

.map-location-index {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 999px;
    background: var(--panel-soft);
    border: 1px solid var(--line);
    font-weight: 800;
}

.map-location-copy {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.map-location-copy strong,
.map-location-copy span {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.map-location-meta {
    color: var(--muted);
    font-size: 0.8rem;
    white-space: nowrap;
}

.detail-meta {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    font-size: 0.82rem;
}

.detail-section {
    padding-top: 12px;
}

.detail-accordion {
    margin-top: 14px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: linear-gradient(180deg, #fbfcfe, #f3f6fa);
    overflow: hidden;
}

.detail-accordion summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 16px;
    list-style: none;
    cursor: pointer;
    font-weight: 800;
}

.detail-accordion summary::-webkit-details-marker {
    display: none;
}

.accordion-count {
    min-width: 32px;
    height: 28px;
    padding: 0 10px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--panel-soft);
    border: 1px solid var(--line);
    color: var(--muted);
    font-size: 0.82rem;
}

.detail-fields {
    display: grid;
    gap: 10px;
    padding: 0 14px 14px;
}

.detail-contact-grid {
    display: grid;
    gap: 10px;
    padding: 0 14px 14px;
}

.detail-contact-card {
    padding: 12px 13px;
    background: linear-gradient(180deg, #fbfcfe, #f1f4f8);
    border: 1px solid var(--line);
    border-radius: 12px;
}

.detail-contact-value {
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: 10px;
    color: var(--text);
    line-height: 1.45;
    word-break: break-word;
}

.detail-contact-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 0 0 auto;
}

.detail-field {
    padding: 12px 13px;
    background: linear-gradient(180deg, #fbfcfe, #f1f4f8);
    border: 1px solid var(--line);
    border-radius: 12px;
}

.detail-value {
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: 8px;
    color: var(--text);
    line-height: 1.45;
    word-break: break-word;
}

.resident-cards {
    display: grid;
    gap: 12px;
    padding: 0 14px 14px;
}

.resident-card {
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #ffffff;
    overflow: hidden;
}

.resident-card h4 {
    margin: 0;
    padding: 12px 14px;
    font-size: 0.96rem;
    background: #eef3f8;
    border-bottom: 1px solid var(--line);
}

.loading-state {
    display: grid;
    place-items: center;
    min-height: 240px;
    color: var(--muted);
}

.modal-shell[hidden] {
    display: none;
}

.modal-shell {
    position: fixed;
    inset: 0;
    z-index: 40;
}

.modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(20, 30, 40, 0.55);
}

.modal-panel {
    position: relative;
    z-index: 1;
    width: min(860px, calc(100vw - 32px));
    margin: 28px auto;
    max-height: calc(100vh - 84px);
    overflow-y: auto;
    background: white;
    border-radius: 18px;
    box-shadow: 0 28px 64px rgba(15, 23, 42, 0.24);
}

.email-modal-card {
    padding: 20px;
}

.export-modal-card {
    padding: 18px;
}

.email-modal-header {
    display: flex;
    justify-content: space-between;
    gap: 12px;
}

.modal-close {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    border: 1px solid var(--line);
    background: #f7f9fc;
    color: var(--navy);
    font-size: 1.4rem;
    line-height: 1;
    cursor: pointer;
}

.email-form-grid {
    display: grid;
    grid-template-columns: 240px minmax(0, 1fr);
    gap: 14px;
}

.sms-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    margin-top: 14px;
}

.sms-wide {
    grid-column: 1 / -1;
}

.email-field {
    display: block;
    margin-top: 16px;
}

.email-body {
    width: 100%;
    min-height: 320px;
    padding: 14px;
    border-radius: 12px;
    border: 1px solid var(--line-strong);
    font: inherit;
    resize: vertical;
}

.sms-body {
    min-height: 220px;
}

.recipient-chip-wrap {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.recipient-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 999px;
    border: 1px solid rgba(244, 122, 0, 0.24);
    background: #fff5eb;
    color: #925100;
    font: inherit;
    cursor: pointer;
}

.recipient-chip-x {
    font-weight: 800;
}

.email-modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 18px;
}

.email-modal-actions .primary-button,
.email-modal-actions .secondary-button {
    width: auto;
}

.sms-callout {
    margin-top: 16px;
    padding: 12px 14px;
    border-radius: 12px;
    border: 1px solid #f2c594;
    background: #fff7ea;
}

.sms-callout-title {
    margin: 0 0 4px;
    font-weight: 800;
    color: #925100;
}

.consent-check {
    display: flex;
    align-items: start;
    gap: 10px;
    margin-top: 16px;
    font-size: 0.86rem;
}

.consent-check input {
    width: 18px;
    height: 18px;
    margin-top: 2px;
}

.profile-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.profile-fields {
    padding: 0;
}

.profile-actions {
    margin-top: 16px;
    justify-content: flex-start;
}

.profile-actions form {
    margin: 0;
}

.auth-page {
    display: grid;
    place-items: center;
}

.auth-shell {
    width: min(760px, calc(100vw - 24px));
    min-height: auto;
}

.auth-card {
    padding: 26px;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.auth-lockup {
    margin-bottom: 20px;
}

.auth-form {
    display: grid;
    gap: 12px;
}

.auth-divider {
    height: 1px;
    margin: 22px 0 16px;
    background: linear-gradient(90deg, transparent, var(--line), transparent);
}

.auth-support {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.auth-secondary-link {
    width: auto;
    min-width: 136px;
    justify-content: center;
    text-decoration: none;
}

.register-shell {
    width: min(1180px, calc(100vw - 24px));
}

.register-card {
    padding: 28px;
}

.register-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(320px, 0.9fr);
    gap: 18px;
}

.register-form {
    align-content: start;
}

.register-proof-card {
    padding: 18px;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: linear-gradient(180deg, #f9fbfd, #f0f4f8);
}

.register-callout {
    margin-top: 8px;
}

.register-consent {
    padding: 12px 14px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #fbfcfe;
}

.policy-shell {
    width: min(1120px, calc(100vw - 24px));
}

.policy-card {
    padding: 26px;
}

.policy-content {
    display: grid;
    gap: 14px;
    margin-top: 18px;
    font-size: 0.96rem;
    line-height: 1.65;
}

.policy-content p {
    margin: 0;
}

button:disabled,
input:disabled,
select:disabled,
textarea:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.export-form {
    margin-top: 14px;
}

.export-toolbar {
    display: flex;
    gap: 8px;
    margin-bottom: 12px;
}

.tiny-button {
    height: 30px;
    padding: 0 10px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #f7f9fc;
    color: var(--navy);
    font: inherit;
    font-size: 0.78rem;
    font-weight: 700;
    cursor: pointer;
}

.export-columns-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px 10px;
    max-height: 360px;
    overflow-y: auto;
    padding: 4px 2px 6px;
}

.export-column-option {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 10px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fbfcfe;
    font-size: 0.82rem;
}

.export-column-option input {
    width: 15px;
    height: 15px;
    margin: 0;
}

.landing-page {
    background:
        radial-gradient(circle at top left, rgba(13, 148, 90, 0.12), transparent 24%),
        radial-gradient(circle at top right, rgba(244, 122, 0, 0.16), transparent 28%),
        linear-gradient(180deg, #f8f3eb 0%, #eef4f7 52%, #edf1f6 100%);
}

.landing-shell {
    width: min(1240px, calc(100vw - 28px));
    margin: 14px auto 24px;
}

.landing-header,
.hero-panel,
.feature-card,
.workflow-panel,
.cta-panel {
    border: 1px solid rgba(125, 137, 153, 0.28);
    border-radius: 24px;
    box-shadow: 0 22px 52px rgba(34, 47, 62, 0.08);
    background: rgba(255, 255, 255, 0.84);
    backdrop-filter: blur(14px);
}

.landing-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    padding: 16px 20px;
    position: sticky;
    top: 14px;
    z-index: 20;
}

.landing-brand {
    display: inline-flex;
    align-items: center;
}

.landing-nav {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.landing-nav a {
    color: var(--navy);
    text-decoration: none;
    font-weight: 700;
    font-size: 0.92rem;
}

.landing-nav-cta {
    width: auto;
    min-width: 120px;
}

.landing-main {
    display: grid;
    gap: 18px;
    margin-top: 18px;
}

.hero-panel {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(320px, 0.8fr);
    gap: 18px;
    padding: 28px;
}

.hero-copy h1,
.auth-spotlight h1 {
    margin: 0;
    max-width: 12ch;
    font-size: clamp(2.8rem, 6vw, 4.9rem);
    line-height: 0.96;
    letter-spacing: -0.05em;
    color: #1d2b38;
}

.hero-subcopy {
    margin: 16px 0 0;
    max-width: 64ch;
    color: #526476;
    font-size: 1.05rem;
    line-height: 1.65;
}

.hero-actions,
.cta-actions,
.auth-inline-links {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.hero-actions {
    margin-top: 24px;
}

.hero-button {
    width: auto;
    min-width: 156px;
    height: 46px;
}

.ghost-link-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 132px;
    height: 46px;
    padding: 0 18px;
    border-radius: 999px;
    border: 1px solid rgba(51, 64, 85, 0.16);
    background: rgba(255, 255, 255, 0.7);
    color: var(--navy);
    font-weight: 700;
    text-decoration: none;
}

.hero-metrics {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    margin-top: 28px;
}

.hero-metric,
.workflow-step {
    padding: 16px;
    border-radius: 18px;
    background: linear-gradient(180deg, rgba(247, 250, 252, 0.92), rgba(236, 242, 247, 0.94));
    border: 1px solid rgba(125, 137, 153, 0.22);
}

.hero-metric strong {
    display: block;
    font-size: 1.25rem;
    color: #193142;
}

.hero-metric span {
    display: block;
    margin-top: 6px;
    color: var(--muted);
    font-size: 0.88rem;
}

.hero-card {
    padding: 22px;
    border-radius: 22px;
    background:
        radial-gradient(circle at top right, rgba(244, 122, 0, 0.14), transparent 35%),
        linear-gradient(180deg, #173042 0%, #233f54 100%);
    color: #eef5f9;
}

.hero-card h2,
.feature-card h2,
.workflow-panel h2,
.cta-panel h2,
.auth-card-header h2 {
    margin: 0;
    font-size: 1.7rem;
    line-height: 1.12;
}

.hero-card .eyebrow,
.auth-spotlight .eyebrow {
    color: #f8bf7a;
}

.landing-checklist {
    display: grid;
    gap: 10px;
    margin: 20px 0 0;
    padding: 0;
    list-style: none;
}

.landing-checklist li {
    position: relative;
    padding-left: 26px;
    line-height: 1.55;
}

.landing-checklist li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 9px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: linear-gradient(135deg, #f4a340, #ffd59b);
    box-shadow: 0 0 0 4px rgba(244, 163, 64, 0.14);
}

.hero-card-footer {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 24px;
}

.hero-chip {
    display: inline-flex;
    align-items: center;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.16);
    font-size: 0.82rem;
    font-weight: 700;
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.feature-card,
.workflow-panel,
.cta-panel {
    padding: 22px;
}

.feature-card p:not(.eyebrow),
.workflow-step p,
.cta-panel p:not(.eyebrow) {
    margin: 12px 0 0;
    color: var(--muted);
    line-height: 1.6;
}

.workflow-panel {
    display: grid;
    gap: 18px;
}

.workflow-steps {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

.workflow-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 14px;
    background: linear-gradient(135deg, #edf8f1, #dff4e8);
    color: var(--green);
    font-weight: 800;
}

.cta-panel {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 18px;
}

.auth-page-rich {
    background:
        radial-gradient(circle at top left, rgba(244, 122, 0, 0.16), transparent 24%),
        radial-gradient(circle at bottom right, rgba(11, 106, 61, 0.14), transparent 22%),
        linear-gradient(180deg, #f8f1e8 0%, #eef4f7 100%);
}

.auth-shell-wide {
    width: min(1180px, calc(100vw - 24px));
}

.auth-stage {
    display: grid;
    grid-template-columns: minmax(320px, 0.96fr) minmax(0, 1fr);
    gap: 20px;
    align-items: stretch;
}

.auth-spotlight,
.auth-card-rich {
    border: 1px solid rgba(125, 137, 153, 0.28);
    border-radius: 24px;
    box-shadow: 0 22px 52px rgba(34, 47, 62, 0.08);
}

.auth-spotlight {
    padding: 28px;
    background:
        radial-gradient(circle at top right, rgba(244, 122, 0, 0.18), transparent 34%),
        linear-gradient(180deg, #173042 0%, #23445a 100%);
    color: #eef5f9;
}

.auth-spotlight .hero-subcopy {
    color: rgba(238, 245, 249, 0.78);
}

.auth-brand-link {
    margin-bottom: 22px;
}

.auth-card-rich {
    padding: 28px;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(12px);
}

.auth-card-header {
    margin-bottom: 8px;
}

.auth-support-rich {
    align-items: end;
}

.auth-actions {
    justify-content: flex-start;
}

.auth-actions-split {
    justify-content: space-between;
}

.auth-proof-grid {
    margin-top: 22px;
}

.auth-proof-grid .detail-field {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.12);
}

.auth-proof-grid .detail-label,
.auth-proof-grid .detail-value,
.auth-proof-grid .detail-value a {
    color: #eef5f9;
}

.auth-inline-links .auth-secondary-link {
    width: auto;
}

.optin-page {
    min-height: 100vh;
}

.optin-shell {
    width: min(1320px, calc(100vw - 28px));
    margin: 18px auto 28px;
    display: grid;
    gap: 18px;
}

.optin-hero,
.optin-preview-card {
    border: 1px solid rgba(125, 137, 153, 0.28);
    border-radius: 28px;
    box-shadow: 0 22px 52px rgba(34, 47, 62, 0.08);
    background: rgba(255, 255, 255, 0.84);
    backdrop-filter: blur(14px);
}

.optin-hero {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(400px, 0.9fr);
    gap: 20px;
    padding: 22px;
}

.optin-copy {
    display: grid;
    align-content: start;
    gap: 16px;
    padding: 10px 6px 10px 2px;
}

.optin-chip-row,
.optin-trust-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.optin-proof {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.optin-proof-item {
    padding: 16px;
    border-radius: 18px;
    border: 1px solid rgba(125, 137, 153, 0.24);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.82), rgba(241, 246, 250, 0.88));
}

.optin-proof-item strong,
.optin-proof-item span {
    display: block;
}

.optin-proof-item strong {
    margin-bottom: 8px;
    font-size: 0.96rem;
}

.optin-proof-item span {
    color: var(--muted);
    line-height: 1.55;
    font-size: 0.88rem;
}

.optin-form-card {
    padding: 28px;
    border-radius: 24px;
    border: 1px solid rgba(125, 137, 153, 0.24);
    background:
        radial-gradient(circle at top right, rgba(244, 122, 0, 0.12), transparent 28%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(242, 247, 250, 0.98));
}

.optin-form {
    gap: 14px;
}

.optin-contact-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.optin-form .email-field small {
    display: block;
    margin-top: 6px;
    color: var(--muted);
    font-size: 0.76rem;
}

.optin-consent {
    background: rgba(251, 252, 254, 0.94);
}

.optin-trust-row span {
    padding: 5px 10px;
    border-radius: 999px;
    border: 1px solid var(--line);
    background: #f7fafc;
    color: var(--navy);
    font-size: 0.76rem;
    font-weight: 700;
}

.optin-preview-card {
    padding: 22px;
    display: grid;
    gap: 18px;
}

.optin-preview-copy {
    max-width: 760px;
}

.optin-product-shot {
    border-radius: 24px;
    border: 1px solid rgba(125, 137, 153, 0.28);
    background: linear-gradient(180deg, #f8fbfe, #eef3f8);
    overflow: hidden;
}

.optin-shot-toolbar {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    align-items: center;
    padding: 18px 20px;
    border-bottom: 1px solid rgba(125, 137, 153, 0.22);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(242, 247, 250, 0.92));
}

.optin-shot-search,
.optin-shot-metrics {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.optin-shot-label {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--muted);
    font-weight: 700;
}

.optin-shot-pill,
.optin-shot-metrics span {
    padding: 7px 10px;
    border-radius: 999px;
    border: 1px solid rgba(125, 137, 153, 0.26);
    background: #ffffff;
    font-size: 0.8rem;
    color: var(--navy);
}

.optin-shot-action {
    padding: 9px 14px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--green), #159553);
    color: #ffffff;
    font-size: 0.8rem;
    font-weight: 700;
}

.optin-shot-body {
    display: grid;
    grid-template-columns: minmax(0, 1.5fr) minmax(280px, 0.8fr);
    gap: 18px;
    padding: 18px;
}

.optin-shot-table,
.optin-shot-sidepanel {
    border-radius: 20px;
    border: 1px solid rgba(125, 137, 153, 0.24);
    background: rgba(255, 255, 255, 0.88);
}

.optin-shot-table-head,
.optin-shot-row,
.optin-side-list div {
    display: grid;
    grid-template-columns: 120px 120px 160px minmax(0, 1fr);
    gap: 12px;
    align-items: center;
    padding: 12px 14px;
}

.optin-shot-table-head {
    background: linear-gradient(180deg, #4b5568, #364052);
    color: #eff4ff;
    font-size: 0.68rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    font-weight: 700;
}

.optin-shot-row {
    border-top: 1px solid rgba(221, 228, 236, 0.9);
    font-size: 0.84rem;
    color: var(--navy);
}

.optin-shot-row:nth-child(even) {
    background: #f8fbfe;
}

.optin-shot-sidepanel {
    padding: 14px;
    display: grid;
    gap: 14px;
}

.optin-mini-map {
    position: relative;
    min-height: 210px;
    padding: 14px;
    border-radius: 18px;
    border: 1px solid rgba(125, 137, 153, 0.22);
    background:
        linear-gradient(135deg, rgba(33, 122, 186, 0.08), rgba(22, 163, 74, 0.12)),
        linear-gradient(180deg, #eef5fb, #e8f0e7);
    overflow: hidden;
}

.optin-mini-map span {
    position: relative;
    z-index: 1;
    display: inline-block;
    padding: 6px 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.88);
    border: 1px solid rgba(125, 137, 153, 0.22);
    font-size: 0.78rem;
    font-weight: 700;
}

.optin-map-dot {
    position: absolute;
    width: 18px;
    height: 18px;
    border-radius: 999px;
    background: #eb4335;
    box-shadow: 0 0 0 6px rgba(235, 67, 53, 0.16);
}

.optin-map-dot-a { top: 58px; left: 62%; }
.optin-map-dot-b { top: 122px; left: 34%; }
.optin-map-dot-c { top: 148px; left: 70%; }

.optin-side-list {
    display: grid;
    gap: 10px;
}

.optin-side-list div {
    grid-template-columns: 34px minmax(0, 1fr) auto;
    border-radius: 16px;
    border: 1px solid rgba(125, 137, 153, 0.24);
    background: #fbfdff;
}

.optin-side-list strong {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: #eef3f8;
}

.optin-side-list span {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.optin-side-list em {
    font-style: normal;
    color: var(--muted);
    font-size: 0.8rem;
}

@media (max-width: 1280px) {
    .brand-bar {
        align-items: start;
        flex-direction: column;
    }

    .brand-side {
        width: 100%;
        align-items: stretch;
    }

    .brand-stats {
        flex-wrap: wrap;
        width: 100%;
    }

    .filters-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .results-shell { grid-template-columns: 1fr; }
    .details-panel { position: static; min-height: 420px; max-height: none; }
    .export-columns-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .profile-grid { grid-template-columns: 1fr; }
    .register-layout { grid-template-columns: 1fr; }
}

@media (max-width: 1180px) {
    .feature-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .workflow-steps {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 980px) {
    .brand-bar, .brand-lockup, .zip-search-form, .filters-topline, .table-card-header, .details-header {
        flex-direction: column;
    }

    .brand-logo { max-width: 52vw; }
    .brand-stats { min-width: 0; width: 100%; }
    .account-actions { justify-content: flex-start; }
    .auth-support { flex-direction: column; align-items: stretch; }
    .filters-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .results-table th:nth-child(7), .results-table td:nth-child(7),
    .results-table th:nth-child(9), .results-table td:nth-child(9) { display: none; }
    .brand-bar { position: static; }
    .page-shell { min-height: auto; }
    .hero-panel,
    .auth-stage,
    .feature-grid,
    .workflow-steps,
    .optin-hero,
    .optin-shot-body {
        grid-template-columns: 1fr;
    }
    .optin-proof,
    .optin-contact-grid {
        grid-template-columns: 1fr;
    }
    .landing-header,
    .landing-nav,
    .cta-panel,
    .auth-support-rich,
    .optin-shot-toolbar {
        flex-direction: column;
        align-items: flex-start;
    }
    .hero-metrics { grid-template-columns: 1fr; }
    .map-card-header { flex-direction: column; }
    .map-open-link { width: 100%; }
}

@media (max-width: 720px) {
    .page-shell { width: calc(100vw - 8px); margin: 4px auto 12px; }
    .filters-grid { grid-template-columns: 1fr; }
    .results-table th:nth-child(6), .results-table td:nth-child(6),
    .results-table th:nth-child(8), .results-table td:nth-child(8),
    .results-table th:nth-child(9), .results-table td:nth-child(9) { display: none; }
    .details-panel { min-height: 300px; }
    .email-form-grid { grid-template-columns: 1fr; }
    .sms-form-grid { grid-template-columns: 1fr; }
    .export-columns-grid { grid-template-columns: 1fr; }
    .map-location-item { grid-template-columns: 34px minmax(0, 1fr); }
    .map-location-meta { grid-column: 2; }
    .detail-contact-value { flex-direction: column; }
    .landing-shell { width: calc(100vw - 12px); margin: 6px auto 16px; }
    .landing-header,
    .hero-panel,
    .feature-card,
    .workflow-panel,
    .cta-panel,
    .auth-spotlight,
    .auth-card-rich,
    .optin-hero,
    .optin-preview-card,
    .optin-form-card {
        padding: 18px;
        border-radius: 18px;
    }
    .hero-copy h1,
    .auth-spotlight h1 {
        max-width: none;
        font-size: 2.5rem;
    }
    .hero-actions,
    .cta-actions,
    .auth-inline-links,
    .auth-actions-split {
        width: 100%;
        flex-direction: column;
        align-items: stretch;
    }
    .landing-nav-cta,
    .hero-button,
    .ghost-link-button,
    .auth-secondary-link {
        width: 100%;
    }
    .optin-shell {
        width: calc(100vw - 12px);
        margin: 6px auto 16px;
    }
    .optin-shot-table-head,
    .optin-shot-row {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}
