:root {
    --color-navy: #12345a;
    --color-navy-dark: #0b223d;
    --color-blue: #2f6ea3;
    --color-blue-soft: #e8f1fa;
    --color-line: #d8e1ec;
    --color-bg: #f4f7fb;
    --color-panel: #ffffff;
    --color-text: #1f2d3d;
    --color-muted: #637083;
    --shadow-soft: 0 10px 28px rgba(18, 52, 90, 0.08);
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    min-width: 320px;
    color: var(--color-text);
    background: var(--color-bg);
    font-family: "Microsoft YaHei", "PingFang SC", "Segoe UI", Arial, sans-serif;
}

a {
    color: inherit;
    text-decoration: none;
}

.topbar {
    position: sticky;
    top: 0;
    z-index: 10;
    display: flex;
    align-items: center;
    gap: 20px;
    min-height: 64px;
    padding: 0 28px;
    color: #ffffff;
    background: var(--color-navy-dark);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    flex: 0 0 auto;
    font-weight: 700;
    white-space: nowrap;
}

.brand-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 6px;
    color: var(--color-navy-dark);
    background: #dbeafe;
    font-size: 13px;
    letter-spacing: 0;
}

.brand-text {
    font-size: 17px;
}

.main-nav {
    display: flex;
    align-items: stretch;
    gap: 2px;
    flex: 1 1 auto;
    min-width: 0;
    overflow-x: auto;
}

.nav-link {
    display: inline-flex;
    align-items: center;
    min-height: 64px;
    padding: 0 12px;
    color: rgba(255, 255, 255, 0.78);
    border-bottom: 3px solid transparent;
    font-size: 14px;
    white-space: nowrap;
}

.nav-link:hover,
.nav-link.active {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.08);
    border-bottom-color: #7db7e8;
}

.admin-link {
    flex: 0 0 auto;
    padding: 8px 12px;
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 6px;
    color: rgba(255, 255, 255, 0.88);
    font-size: 13px;
}

.user-actions {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    flex: 0 0 auto;
}

.user-name {
    color: rgba(255, 255, 255, 0.86);
    font-size: 13px;
    white-space: nowrap;
}

.logout-form {
    margin: 0;
}

.logout-button {
    padding: 8px 12px;
    color: rgba(255, 255, 255, 0.88);
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 6px;
    cursor: pointer;
    font: inherit;
    font-size: 13px;
}

.auth-body {
    min-height: 100vh;
    background: var(--color-bg);
}

.login-shell {
    display: grid;
    place-items: center;
    min-height: 100vh;
    padding: 24px;
}

.login-panel {
    width: min(420px, 100%);
    padding: 28px;
    background: #ffffff;
    border: 1px solid var(--color-line);
    border-radius: 8px;
    box-shadow: var(--shadow-soft);
}

.login-heading {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 22px;
}

.login-heading h1 {
    margin: 0 0 4px;
    font-size: 22px;
}

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

.login-panel form {
    display: grid;
    gap: 14px;
}

.login-button {
    padding: 11px 16px;
    color: #ffffff;
    background: var(--color-navy);
    border: 0;
    border-radius: 6px;
    cursor: pointer;
    font: inherit;
    font-weight: 700;
}

.form-error {
    margin-bottom: 14px;
    padding: 10px 12px;
    color: #9f1239;
    background: #fff1f2;
    border: 1px solid #fecdd3;
    border-radius: 6px;
}

.account-panel {
    max-width: 620px;
    padding: 22px;
    background: #ffffff;
    border: 1px solid var(--color-line);
    border-radius: 8px;
    box-shadow: var(--shadow-soft);
}

.account-form {
    display: grid;
    gap: 16px;
}

.account-form label {
    display: grid;
    gap: 7px;
    color: #334155;
    font-size: 13px;
    font-weight: 700;
}

.account-form input {
    width: 100%;
    padding: 10px 12px;
    color: var(--color-text);
    border: 1px solid var(--color-line);
    border-radius: 6px;
    font: inherit;
    font-weight: 400;
}

.field-help {
    color: var(--color-muted);
    font-size: 12px;
    font-weight: 400;
    line-height: 1.6;
}

.field-help ul {
    margin: 0;
    padding-left: 18px;
}

.field-error {
    color: #9f1239;
    font-size: 12px;
}

.account-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 4px;
}

.success-state {
    display: grid;
    gap: 10px;
}

.success-state strong {
    color: #166534;
    font-size: 18px;
}

.success-state p {
    margin-bottom: 8px;
    color: var(--color-muted);
}

.page-shell {
    width: min(1180px, calc(100% - 36px));
    margin: 0 auto;
    padding: 34px 0 48px;
}

.page-heading {
    margin-bottom: 24px;
    padding-bottom: 22px;
    border-bottom: 1px solid var(--color-line);
}

.compact-heading {
    margin-bottom: 18px;
}

.eyebrow {
    margin: 0 0 8px;
    color: var(--color-blue);
    font-size: 13px;
    font-weight: 700;
}

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

h1 {
    margin-bottom: 10px;
    color: var(--color-navy-dark);
    font-size: 30px;
    line-height: 1.25;
}

h2 {
    margin-bottom: 0;
    color: var(--color-navy-dark);
    font-size: 18px;
}

.heading-text {
    max-width: 720px;
    margin-bottom: 0;
    color: var(--color-muted);
    line-height: 1.7;
}

.summary-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
    margin-bottom: 22px;
}

.metric-card,
.panel,
.placeholder-panel {
    background: var(--color-panel);
    border: 1px solid var(--color-line);
    border-radius: 8px;
    box-shadow: var(--shadow-soft);
}

.metric-card {
    padding: 18px;
}

.metric-card p {
    margin-bottom: 12px;
    color: var(--color-muted);
    font-size: 14px;
}

.metric-card strong {
    display: block;
    margin-bottom: 8px;
    color: var(--color-navy-dark);
    font-size: 30px;
    line-height: 1;
}

.metric-card span,
.quick-item span,
.panel-heading span,
.placeholder-panel p {
    color: var(--color-muted);
    font-size: 13px;
}

.content-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 18px;
}

.panel {
    padding: 20px;
}

.wide-panel {
    grid-column: 1 / -1;
}

.panel-heading {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 18px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--color-line);
}

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

.quick-item {
    padding: 14px;
    background: var(--color-blue-soft);
    border: 1px solid #cfe0f2;
    border-radius: 8px;
}

.quick-item strong {
    display: block;
    margin-bottom: 6px;
    color: var(--color-navy);
}

.clean-list,
.notice-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.clean-list li,
.notice-list li {
    padding: 11px 0;
    border-bottom: 1px solid var(--color-line);
    color: #34465b;
}

.clean-list li:last-child,
.notice-list li:last-child {
    border-bottom: 0;
}

.page-messages {
    display: grid;
    gap: 8px;
    margin-bottom: 18px;
}

.market-yield-panel .page-messages {
    margin: -6px 0 12px;
}

.page-message {
    padding: 10px 12px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 700;
}

.page-message.success {
    color: #14532d;
    background: #dcfce7;
    border: 1px solid #86efac;
}

.page-message.error {
    color: #991b1b;
    background: #fee2e2;
    border: 1px solid #fecaca;
}

.page-message.info {
    color: #1d4f7a;
    background: #e8f1fa;
    border: 1px solid #b8d5ef;
}

.market-yield-panel {
    margin-bottom: 22px;
    padding: 20px;
}

.market-yield-heading {
    align-items: center;
}

.market-yield-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.market-yield-heading form {
    margin: 0;
}

.market-refresh-button,
.market-more-button,
.market-copy-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    padding: 7px 11px;
    color: var(--color-navy);
    background: #ffffff;
    border: 1px solid var(--color-line);
    border-radius: 6px;
    cursor: pointer;
    font: inherit;
    font-size: 13px;
    font-weight: 700;
}

.market-refresh-button:hover,
.market-more-button:hover,
.market-copy-button:hover {
    background: var(--color-blue-soft);
    border-color: #8db9df;
}

.market-refresh-button:disabled {
    color: #637083;
    background: #f3f6fa;
    border-color: var(--color-line);
    cursor: wait;
}

.market-copy-button.copied {
    color: #14532d;
    background: #dcfce7;
    border-color: #86efac;
}

.market-yield-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: -6px 0 12px;
    color: var(--color-muted);
    font-size: 12px;
}

.market-yield-table-wrap {
    overflow-x: auto;
    border: 1px solid var(--color-line);
    border-radius: 8px;
}

.market-yield-table {
    width: 100%;
    min-width: 680px;
    border-collapse: collapse;
    background: #ffffff;
    font-size: 12px;
}

.market-yield-table th,
.market-yield-table td {
    padding: 9px 10px;
    border-bottom: 1px solid var(--color-line);
    text-align: right;
    white-space: nowrap;
}

.market-yield-table thead th {
    color: #334155;
    background: #eef3f8;
    font-size: 12px;
    letter-spacing: 0;
}

.market-yield-table th:first-child,
.market-yield-table th:nth-child(2) {
    text-align: left;
}

.market-yield-table tbody th {
    color: var(--color-navy);
    font-weight: 700;
}

.market-yield-table tbody tr.previous-day {
    background: #fafcff;
}

.market-yield-date {
    width: 74px;
    color: var(--color-navy);
    background: #eef3f8;
    font-weight: 700;
    text-align: left !important;
    vertical-align: middle;
}

.market-yield-table tbody tr:last-child th,
.market-yield-table tbody tr:last-child td {
    border-bottom: 0;
}

.market-yield-empty {
    color: var(--color-muted);
    text-align: center !important;
}

.yield-cell {
    font-family: "Consolas", "SFMono-Regular", "Microsoft YaHei", monospace;
    font-size: 13px;
    font-weight: 700;
}

.yield-cell.up {
    color: #16a34a;
}

.yield-cell.down {
    color: #dc2626;
}

.yield-cell.flat,
.yield-cell.neutral {
    color: var(--color-muted);
}

.common-sites-panel {
    margin-top: 22px;
}

.common-sites-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 10px;
}

.common-site-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-height: 42px;
    padding: 10px 12px;
    color: var(--color-navy);
    background: #fbfcfe;
    border: 1px solid var(--color-line);
    border-radius: 6px;
    font-size: 14px;
    font-weight: 700;
}

.common-site-link:hover {
    background: var(--color-blue-soft);
    border-color: #8db9df;
}

.common-site-url {
    overflow: hidden;
    color: var(--color-muted);
    font-size: 12px;
    font-weight: 400;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.common-sites-admin {
    display: grid;
    gap: 12px;
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid var(--color-line);
}

.common-site-form,
.common-site-row {
    display: grid;
    grid-template-columns: minmax(120px, 0.8fr) minmax(220px, 1.5fr) 80px 72px auto;
    gap: 8px;
    align-items: center;
}

.common-site-form input,
.common-site-row input {
    width: 100%;
    min-width: 0;
    padding: 8px 9px;
    border: 1px solid var(--color-line);
    border-radius: 6px;
    font: inherit;
    font-size: 13px;
}

.common-site-check {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--color-muted);
    font-size: 13px;
    font-weight: 700;
}

.common-site-check input {
    width: auto;
}

.common-site-actions {
    display: flex;
    gap: 8px;
    color: var(--color-muted);
    font-size: 13px;
    font-weight: 700;
}

.common-site-empty {
    padding: 14px;
    color: var(--color-muted);
    background: #f8fafc;
    border: 1px dashed #cbd5e1;
    border-radius: 8px;
    text-align: center;
}

.common-sites-header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.common-sites-list {
    gap: 12px;
}

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

.common-sites-list.columns-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.common-sites-list.columns-4 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.common-sites-list.columns-5 {
    grid-template-columns: repeat(5, minmax(0, 1fr));
}

.common-site-link {
    display: grid;
    align-content: center;
    gap: 6px;
    min-height: 78px;
    padding: 14px 16px;
    font-size: 15px;
}

.common-site-name {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.common-site-edit-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    padding: 7px 11px;
    color: var(--color-navy);
    background: #ffffff;
    border: 1px solid var(--color-line);
    border-radius: 6px;
    font-size: 13px;
    font-weight: 700;
}

.common-site-edit-link:hover {
    background: var(--color-blue-soft);
    border-color: #8db9df;
}

.common-sites-bulk-form {
    display: grid;
    gap: 12px;
}

.common-site-layout-form {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
}

.common-site-layout-form label {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #334155;
    font-size: 13px;
    font-weight: 700;
}

.common-site-layout-form select {
    padding: 8px 9px;
    border: 1px solid var(--color-line);
    border-radius: 6px;
    font: inherit;
    font-size: 13px;
}

.common-site-check.danger-check {
    color: #991b1b;
}

.info-page {
    display: grid;
    gap: 16px;
}

.info-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 16px 18px;
}

.info-search-label,
.info-layout-form label,
.info-form-grid label,
.info-bulk-import label {
    display: grid;
    gap: 7px;
    color: #334155;
    font-size: 13px;
    font-weight: 700;
}

.info-search-label {
    flex: 1 1 460px;
}

.info-search-label input,
.info-layout-form select,
.info-form-grid input,
.info-bulk-import textarea,
.info-item-editor-row input {
    width: 100%;
    min-width: 0;
    padding: 10px 12px;
    color: var(--color-text);
    background: #ffffff;
    border: 1px solid var(--color-line);
    border-radius: 6px;
    font: inherit;
    font-weight: 400;
}

.info-bulk-import textarea {
    resize: vertical;
    line-height: 1.6;
}

.info-layout-form {
    display: flex;
    align-items: end;
    gap: 8px;
    flex-wrap: wrap;
}

.info-admin-create {
    padding: 0;
    overflow: hidden;
}

.info-admin-create > summary {
    padding: 16px 18px;
    color: var(--color-navy-dark);
    cursor: pointer;
    font-size: 16px;
    font-weight: 700;
}

.info-admin-create[open] > summary {
    border-bottom: 1px solid var(--color-line);
}

.info-card-grid {
    display: grid;
    gap: 16px;
}

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

.info-card-grid.columns-4 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.info-card-grid.columns-5 {
    grid-template-columns: repeat(5, minmax(0, 1fr));
}

.info-card {
    display: grid;
    gap: 10px;
    align-content: start;
    min-width: 0;
    padding: 14px;
    background: #ffffff;
    border: 1px solid #cfdceb;
    border-radius: 8px;
    box-shadow: var(--shadow-soft);
}

.info-card:hover {
    border-color: #a9c7e4;
    box-shadow: 0 14px 34px rgba(18, 52, 90, 0.12);
}

.info-card.inactive {
    opacity: 0.66;
}

.info-card.search-hidden {
    display: none !important;
}

.info-card.dragging {
    opacity: 0.5;
    outline: 2px solid #8db9df;
}

.info-card-head {
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: 10px;
    padding-bottom: 8px;
    border-bottom: 1px solid #e2e8f0;
}

.info-card-head h2 {
    margin-bottom: 2px;
    color: var(--color-navy-dark);
    font-size: 16px;
    line-height: 1.35;
}

.info-card-tag {
    display: inline-flex;
    margin: 0 5px 2px 0;
    padding: 2px 6px;
    color: #1d4f7a;
    background: #e8f1fa;
    border: 1px solid #b8d5ef;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
}

.info-card-tag.muted {
    color: #637083;
    background: #f1f5f9;
    border-color: #cbd5e1;
}

.info-drag-handle {
    flex: 0 0 auto;
    color: var(--color-muted);
    cursor: grab;
    font-size: 12px;
    font-weight: 700;
}

.info-card-items {
    display: grid;
    gap: 5px;
}

.info-card-item {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
    align-items: center;
    min-height: 34px;
    padding: 5px 6px 5px 10px;
    background: #f8fbff;
    border: 1px solid #dbe7f3;
    border-radius: 6px;
}

.info-card-text {
    min-width: 0;
    display: flex;
    align-items: baseline;
    gap: 4px;
    white-space: nowrap;
}

.info-card-text strong {
    flex: 0 0 auto;
    display: inline;
    margin: 0;
    color: var(--color-navy);
    font-size: 12px;
}

.info-card-text strong::after {
    content: "：";
}

.info-card-text span {
    flex: 1 1 auto;
    display: inline-block;
    min-width: 0;
    overflow: hidden;
    color: #334155;
    font-size: 13px;
    line-height: 1.35;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.info-copy-button {
    min-height: 26px;
    padding: 3px 8px;
    font-size: 12px;
    white-space: nowrap;
}

.info-copy-all {
    min-height: 32px;
    padding: 6px 10px;
}

.info-card-actions {
    display: flex;
    justify-content: flex-end;
}

.info-card-editor {
    padding: 9px;
    background: #f8fafc;
    border: 1px solid #dbe7f3;
    border-radius: 8px;
}

.info-card-editor > summary {
    color: var(--color-navy);
    cursor: pointer;
    font-size: 14px;
    font-weight: 700;
}

.info-card-form {
    display: grid;
    gap: 12px;
    padding: 14px;
}

.info-card-editor .info-card-form {
    padding: 10px 0 0;
}

.info-form-grid {
    display: grid;
    grid-template-columns: minmax(180px, 1fr) auto auto;
    gap: 14px;
    align-items: end;
}

.info-form-grid .wide {
    min-width: 0;
}

.info-form-grid label:has(input[type="checkbox"]) {
    display: flex;
    align-items: center;
    min-height: 36px;
}

.info-bulk-import {
    display: grid;
    gap: 8px;
    padding: 10px;
    background: #fbfcfe;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
}

.info-item-editor {
    display: grid;
    gap: 7px;
}

.info-item-editor-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding-bottom: 8px;
    border-bottom: 1px solid #e2e8f0;
}

.info-item-editor-list {
    display: grid;
    gap: 8px;
}

.info-item-editor-row {
    display: grid;
    grid-template-columns: minmax(90px, 0.8fr) minmax(160px, 1.4fr) auto;
    gap: 8px;
    align-items: center;
    padding: 6px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
}

.info-permission-box {
    display: grid;
    gap: 9px;
    padding: 10px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
}

.info-permission-box strong {
    color: #334155;
    font-size: 13px;
}

.info-permission-box > span {
    color: var(--color-muted);
    font-size: 12px;
    line-height: 1.5;
}

.info-user-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
    gap: 8px;
    max-height: 180px;
    overflow: auto;
}

.info-user-list label {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #334155;
    font-size: 13px;
}

.info-form-actions,
.info-delete-form {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
}

.info-delete-form {
    margin-top: 10px;
}

.info-order-save {
    width: fit-content;
}

.info-empty-state {
    grid-column: 1 / -1;
    padding: 18px;
    color: var(--color-muted);
    background: #ffffff;
    border: 1px dashed #cbd5e1;
    border-radius: 8px;
    text-align: center;
}

.bond-reminder-panel {
    margin-bottom: 22px;
    padding: 20px;
    background: #ffffff;
    border: 1px solid var(--color-line);
    border-radius: 8px;
    box-shadow: var(--shadow-soft);
}

.bond-reminder-header,
.bond-section-title,
.bond-reminder-stats {
    display: flex;
    align-items: center;
}

.bond-reminder-header {
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 18px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--color-line);
}

.bond-reminder-header .eyebrow {
    margin-bottom: 6px;
}

.bond-reminder-stats {
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
}

.bond-reminder-stats span {
    padding: 6px 10px;
    color: #1f4f46;
    background: #e8f5f0;
    border: 1px solid #b9ddcf;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 700;
}

.bond-sections {
    display: grid;
    grid-template-columns: minmax(260px, 0.8fr) minmax(0, 1.6fr);
    gap: 18px;
}

.bond-section {
    min-width: 0;
}

.bond-section-title {
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
}

.bond-section-title h3 {
    margin: 0;
    color: var(--color-navy-dark);
    font-size: 16px;
}

.bond-section-title span {
    color: var(--color-muted);
    font-size: 13px;
}

.bond-event-list {
    display: grid;
    gap: 10px;
}

.bond-event-card {
    display: grid;
    gap: 8px;
    padding: 12px;
    background: #fbfcfe;
    border: 1px solid var(--color-line);
    border-radius: 8px;
}

.bond-event-card strong {
    color: var(--color-navy-dark);
    font-size: 14px;
}

.bond-event-card p {
    margin: 0;
    color: var(--color-muted);
    font-size: 13px;
    line-height: 1.6;
}

.bond-tag {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    justify-self: start;
    max-width: 220px;
    min-height: 24px;
    padding: 4px 8px;
    overflow: hidden;
    color: #ffffff;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.3;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.bond-table-wrap {
    width: 100%;
    overflow-x: auto;
    border: 1px solid var(--color-line);
    border-radius: 8px;
}

.bond-table {
    width: 100%;
    min-width: 760px;
    border-collapse: collapse;
    background: #ffffff;
    font-size: 13px;
}

.bond-table th,
.bond-table td {
    padding: 10px 12px;
    border-bottom: 1px solid var(--color-line);
    text-align: left;
    vertical-align: top;
}

.bond-table th {
    color: #334155;
    background: #eef3f8;
    font-weight: 700;
    white-space: nowrap;
}

.bond-table thead th {
    text-align: center;
    vertical-align: middle;
}

.bond-table tbody tr:nth-child(even) {
    background: #fafcff;
}

.bond-table tbody tr:last-child td {
    border-bottom: 0;
}

.bond-date {
    color: #b42318;
    font-weight: 700;
    white-space: nowrap;
}

.bond-empty-state {
    padding: 18px;
    color: var(--color-muted);
    background: #f8fafc;
    border: 1px dashed #cbd5e1;
    border-radius: 8px;
    text-align: center;
}

.bond-empty-state.small {
    padding: 14px;
    font-size: 13px;
}

.placeholder-panel {
    padding: 24px;
}

.placeholder-panel div {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
    color: var(--color-navy-dark);
}

.placeholder-panel p {
    max-width: 680px;
    margin-bottom: 0;
    line-height: 1.7;
}

.tool-grid {
    display: grid;
    gap: 18px;
}

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

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

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

.tool-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    min-height: 150px;
    padding: 22px;
    background: var(--color-panel);
    border: 1px solid var(--color-line);
    border-radius: 8px;
    box-shadow: var(--shadow-soft);
}

.tool-card.sortable {
    cursor: grab;
}

.tool-card.dragging {
    opacity: 0.55;
    outline: 2px solid #8db9df;
}

.tool-card p {
    margin: 10px 0 0;
    color: var(--color-muted);
    line-height: 1.7;
}

.tool-action {
    flex: 0 0 auto;
    padding: 10px 16px;
    color: #ffffff;
    background: var(--color-navy);
    border: 0;
    border-radius: 6px;
    cursor: pointer;
    font: inherit;
    font-size: 14px;
    font-weight: 700;
}

.tool-action:hover {
    background: var(--color-blue);
}

.toolbox-layout-form {
    display: flex;
    align-items: end;
    justify-content: flex-end;
    gap: 10px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.toolbox-layout-form label {
    display: grid;
    gap: 6px;
    color: #334155;
    font-size: 13px;
    font-weight: 700;
}

.toolbox-layout-form select {
    min-height: 38px;
    padding: 8px 10px;
    border: 1px solid var(--color-line);
    border-radius: 6px;
    font: inherit;
    font-size: 14px;
}

.intern-workspace {
    display: grid;
    grid-template-columns: 260px minmax(0, 1fr);
    gap: 18px;
    align-items: start;
}

.intern-workspace.public-schedule {
    grid-template-columns: minmax(0, 1fr);
}

.intern-sidebar,
.schedule-panel,
.schedule-modal {
    background: #ffffff;
    border: 1px solid var(--color-line);
    border-radius: 8px;
    box-shadow: var(--shadow-soft);
}

.intern-sidebar {
    position: sticky;
    top: 82px;
    display: grid;
    gap: 8px;
    padding: 16px;
}

.intern-sidebar-head,
.schedule-toolbar,
.schedule-actions,
.modal-head,
.modal-actions,
.schedule-detail-meta {
    display: flex;
    align-items: center;
}

.intern-sidebar-head {
    justify-content: space-between;
    margin-bottom: 8px;
}

.intern-sidebar-head h2,
.schedule-toolbar h2,
.modal-head h2 {
    margin: 0;
}

.intern-sidebar-head span,
.schedule-toolbar span,
.schedule-detail-meta {
    color: var(--color-muted);
    font-size: 13px;
}

.intern-list-item {
    display: grid;
    gap: 4px;
    width: 100%;
    padding: 11px 12px;
    color: var(--color-text);
    background: #f8fafc;
    border: 1px solid #dbe4ee;
    border-radius: 8px;
    cursor: pointer;
    font: inherit;
    text-align: left;
}

.intern-list-item.active {
    background: var(--color-blue-soft);
    border-color: #8db9df;
}

.intern-list-item span,
.intern-empty {
    color: var(--color-muted);
    font-size: 13px;
}

.intern-side-actions {
    display: grid;
    gap: 8px;
    margin-top: 8px;
    padding-top: 12px;
    border-top: 1px solid var(--color-line);
}

.full-width {
    width: 100%;
}

.schedule-panel {
    min-width: 0;
    padding: 18px;
}

.schedule-toolbar {
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 16px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--color-line);
}

.schedule-actions {
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
}

.icon-button,
.plain-button,
.primary-button,
.danger-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    min-height: 36px;
    padding: 8px 12px;
    border-radius: 6px;
    cursor: pointer;
    font: inherit;
    font-size: 13px;
    font-weight: 700;
}

.icon-button,
.plain-button {
    color: var(--color-navy-dark);
    background: #ffffff;
    border: 1px solid var(--color-line);
}

.icon-button {
    width: 36px;
    padding: 0;
}

.primary-button {
    color: #ffffff;
    background: var(--color-navy);
    border: 1px solid var(--color-navy);
}

.danger-button {
    color: #991b1b;
    background: #fff1f2;
    border: 1px solid #fecdd3;
}

.schedule-table-wrap {
    overflow-x: hidden;
    border: 1px solid var(--color-line);
    border-radius: 8px;
}

.schedule-grid {
    position: relative;
    display: grid;
    width: 100%;
    min-width: 0;
    background: #ffffff;
}

.schedule-head,
.schedule-time-slot,
.schedule-cell {
    border-right: 1px solid var(--color-line);
    border-bottom: 1px solid var(--color-line);
}

.schedule-head {
    position: sticky;
    top: 0;
    z-index: 3;
    padding: 10px;
    color: #334155;
    background: #eef3f8;
    font-size: 13px;
    font-weight: 700;
}

.schedule-head.day-column {
    text-align: center;
}

.schedule-head span {
    display: block;
    margin-top: 4px;
    color: var(--color-muted);
    font-weight: 400;
}

.schedule-time-slot {
    padding: 8px 10px;
    color: #334155;
    background: #eef3f8;
    font-size: 12px;
    line-height: 1.25;
}

.schedule-grid .schedule-cell {
    min-height: 34px;
    padding: 0;
    background: #fbfcfe;
    border-top: 0;
    border-left: 0;
    cursor: crosshair;
    font: inherit;
    text-align: center;
}

.schedule-grid .schedule-cell:hover {
    background: #eef6ff;
}

.weekend-cell-label {
    display: inline-flex;
    align-items: center;
    height: 100%;
    color: var(--color-muted);
    font-size: 13px;
    font-weight: 700;
}

.schedule-table {
    width: 100%;
    min-width: 860px;
    border-collapse: collapse;
    table-layout: fixed;
    background: #ffffff;
}

.schedule-table th,
.schedule-table td {
    border-bottom: 1px solid var(--color-line);
    border-right: 1px solid var(--color-line);
    vertical-align: top;
}

.schedule-table th {
    padding: 10px;
    color: #334155;
    background: #eef3f8;
    font-size: 13px;
    text-align: left;
}

.schedule-table thead th:not(.time-column) {
    text-align: center;
}

.schedule-table thead span {
    display: block;
    margin-top: 4px;
    color: var(--color-muted);
    font-weight: 400;
}

.schedule-table td {
    height: 86px;
    padding: 7px;
    background: #fbfcfe;
}

.schedule-cell {
    cursor: crosshair;
}

.schedule-cell.selecting {
    background: #dbeafe;
    box-shadow: inset 0 0 0 2px #2f6ea3;
}

.schedule-table tr:last-child th,
.schedule-table tr:last-child td {
    border-bottom: 0;
}

.schedule-table th:last-child,
.schedule-table td:last-child {
    border-right: 0;
}

.time-column {
    width: auto;
    white-space: nowrap;
}

.copy-toast {
    position: fixed;
    right: 24px;
    bottom: 24px;
    z-index: 60;
    max-width: min(360px, calc(100vw - 48px));
    padding: 12px 16px;
    color: #ffffff;
    background: #123b63;
    border-radius: 8px;
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.22);
    font-size: 14px;
    font-weight: 700;
}

.copy-toast.error {
    background: #991b1b;
}

.schedule-block {
    display: grid;
    gap: 4px;
    width: 100%;
    min-height: 0;
    margin: 3px 6px;
    padding: 8px;
    border: 1px solid #b9ddcf;
    border-radius: 6px;
    color: #173b34;
    background: #e8f5f0;
    cursor: pointer;
    font: inherit;
    text-align: left;
    z-index: 2;
    overflow: hidden;
}

.schedule-block.leave {
    color: #475569;
    background: #e5e7eb;
    border-color: #cbd5e1;
}

.schedule-block span,
.schedule-block small {
    font-size: 12px;
}

.schedule-block strong {
    overflow-wrap: anywhere;
    font-size: 13px;
}

.modal-backdrop {
    position: fixed;
    inset: 0;
    z-index: 40;
    display: grid;
    place-items: center;
    padding: 24px;
    background: rgba(15, 23, 42, 0.36);
}

.modal-backdrop[hidden] {
    display: none;
}

.schedule-modal {
    width: min(620px, 100%);
    max-height: min(760px, calc(100vh - 48px));
    overflow-y: auto;
    padding: 20px;
}

.modal-head {
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--color-line);
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.form-grid label {
    display: grid;
    gap: 6px;
    color: #334155;
    font-size: 13px;
    font-weight: 700;
}

.form-grid .wide {
    grid-column: 1 / -1;
}

.form-help {
    color: var(--muted);
    display: block;
    font-size: 12px;
    font-weight: 400;
    margin-top: 6px;
}

.issuance-detail-preview {
    background: #f5f8fc;
    border: 1px solid #d9e3f0;
    border-radius: 8px;
    padding: 12px;
}

.issuance-detail-grid {
    display: grid;
    gap: 8px;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    margin-top: 8px;
}

.issuance-detail-grid > div {
    background: #fff;
    border: 1px solid #dce5ef;
    border-radius: 6px;
    display: grid;
    gap: 4px;
    padding: 10px;
}

.issuance-detail-grid span {
    color: var(--muted);
    font-size: 12px;
}

.issuance-detail-item label {
    color: #536b85;
    display: grid;
    font-size: 12px;
    gap: 4px;
}

.issuance-detail-item input {
    background: #fff;
    border: 1px solid #ccd8e6;
    border-radius: 5px;
    font: inherit;
    padding: 7px 8px;
}

.project-basic-info {
    display: grid;
    gap: 10px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin: 0;
    max-width: 1000px;
}

.project-basic-info > div {
    align-items: baseline;
    background: rgba(255, 255, 255, .68);
    border: 1px solid #dbe5f0;
    border-radius: 8px;
    display: flex;
    gap: 6px;
    min-width: 0;
    padding: 10px 12px;
}

.project-basic-info .wide {
    grid-column: 1 / -1;
}

.project-basic-info dt {
    color: #536b85;
    flex: 0 0 auto;
    font-size: 14px;
    font-weight: 600;
}

.project-basic-info dt::after {
    content: "：";
}

.project-basic-info dd {
    color: var(--ink);
    font-size: 14px;
    line-height: 1.6;
    margin: 0;
    overflow-wrap: anywhere;
}

.project-info-panel {
    background: #f8fafc;
    border: 1px solid #dbe5f0;
    border-left: 4px solid var(--color-navy);
    border-radius: 12px;
    margin-top: 16px;
    max-width: 1000px;
    padding: 14px;
}

.project-section-title {
    align-items: baseline;
    display: flex;
    justify-content: space-between;
    gap: 16px;
    margin: 0 0 10px;
}

.project-section-title > div {
    align-items: baseline;
    display: flex;
    gap: 10px;
}

.project-section-title span {
    color: var(--color-navy);
    font-size: 17px;
    font-weight: 700;
}

.project-section-title small {
    color: var(--color-muted);
    font-size: 12px;
}

.project-info-edit {
    background: #ffffff;
    border: 1px solid #c8d6e5;
    border-radius: 6px;
    color: var(--color-navy);
    cursor: pointer;
    font: inherit;
    font-size: 12px;
    font-weight: 700;
    padding: 5px 11px;
}

.project-info-edit:hover {
    background: #edf4fb;
    border-color: #9fb6cd;
}

.project-info-modal {
    max-width: 760px;
}

.project-info-varieties {
    border-top: 1px solid var(--color-line);
    padding-top: 14px;
}

.project-info-varieties > strong {
    color: var(--color-navy);
    display: block;
    margin-bottom: 10px;
}

#projectInfoVarietyFields {
    display: grid;
    gap: 12px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.project-info-variety {
    border: 1px solid var(--color-line);
    border-radius: 8px;
    display: grid;
    gap: 8px;
    margin: 0;
    min-width: 0;
    padding: 12px;
}

.project-info-variety legend {
    color: var(--color-navy);
    font-weight: 700;
    padding: 0 5px;
}

.project-info-variety label {
    gap: 4px;
}

.form-error {
    color: #b42318;
    margin: 0;
}

.bond-variety-grid {
    display: grid;
    gap: 16px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin-top: 12px;
    max-width: 1000px;
}

.bond-variety-card {
    background: rgba(255, 255, 255, .68);
    border: 1px solid #dbe5f0;
    border-radius: 10px;
    padding: 14px 16px;
}

.bond-variety-card h2 {
    color: #704527;
    font-size: 18px;
    margin: 0 0 10px;
    text-align: center;
}

.bond-variety-card dl {
    display: grid;
    gap: 6px;
    margin: 0;
}

.bond-variety-card dl > div {
    display: flex;
    gap: 6px;
}

.bond-variety-card dt {
    color: #8b6245;
    flex: 0 0 auto;
    font-weight: 600;
}

.bond-variety-card dt::after {
    content: "：";
}

.bond-variety-card dd {
    color: var(--ink);
    margin: 0;
}

@media (max-width: 760px) {
    .project-basic-info {
        grid-template-columns: 1fr;
    }

    .project-basic-info .wide {
        grid-column: auto;
    }

    .bond-variety-grid {
        grid-template-columns: 1fr;
    }

    #projectInfoVarietyFields {
        grid-template-columns: 1fr;
    }
}

.form-grid input,
.form-grid textarea {
    width: 100%;
    padding: 9px 10px;
    color: var(--color-text);
    border: 1px solid var(--color-line);
    border-radius: 6px;
    font: inherit;
    font-weight: 400;
}

.form-grid input:disabled,
.form-grid textarea:disabled {
    color: #64748b;
    background: #f8fafc;
}

.schedule-detail-meta {
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 14px;
}

.modal-actions {
    justify-content: flex-end;
    gap: 10px;
    margin-top: 18px;
}

.status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--color-blue);
}

.project-heading,
.sales-heading,
.sales-toolbar,
.project-card-actions,
.project-breadcrumb,
.sales-legend,
.import-mapping-grid label {
    display: flex;
    align-items: center;
}

.project-heading,
.sales-heading {
    justify-content: space-between;
    gap: 18px;
}

.project-heading > div,
.sales-heading > div {
    min-width: 0;
}

.project-heading > .plain-button {
    flex: 0 0 auto;
    font-size: 13px;
    padding: 8px 12px;
    white-space: nowrap;
}

.project-category-section {
    margin-bottom: 28px;
}

.project-alpha-filter {
    display: flex;
    gap: 6px;
    margin: 10px 0 14px;
    overflow-x: auto;
    padding-bottom: 2px;
}

.project-alpha-filter button {
    min-width: 32px;
    border: 1px solid #cbd7e4;
    border-radius: 6px;
    background: #ffffff;
    color: var(--color-navy);
    cursor: pointer;
    font: inherit;
    font-size: 13px;
    font-weight: 700;
    padding: 6px 9px;
}

.project-alpha-filter button.active {
    background: var(--color-navy);
    border-color: var(--color-navy);
    color: #ffffff;
}

.project-search {
    align-items: center;
    background: #ffffff;
    border: 1px solid var(--color-line);
    border-radius: 9px;
    display: flex;
    gap: 14px;
    margin-bottom: 20px;
    padding: 12px 14px;
}

.project-search > label {
    color: var(--color-navy);
    flex: 0 0 auto;
    font-size: 14px;
    font-weight: 700;
}

.project-search > div {
    display: flex;
    flex: 1 1 auto;
    gap: 8px;
}

.project-search input {
    border: 1px solid #cbd7e4;
    border-radius: 6px;
    flex: 1 1 auto;
    font: inherit;
    min-width: 0;
    padding: 9px 11px;
}

.project-search input:focus {
    border-color: var(--color-blue);
    outline: 2px solid rgba(47, 110, 163, .14);
}

.project-search button {
    background: transparent;
    border: 0;
    color: var(--color-blue);
    cursor: pointer;
    font: inherit;
    padding: 0 8px;
}

.project-search-empty {
    color: var(--color-muted);
    grid-column: 1 / -1;
    padding: 24px;
    text-align: center;
}

.mistake-heading {
    margin-bottom: 18px;
}

.mistake-heading h1 {
    margin-bottom: 8px;
}

.mistake-heading p:last-child,
.mistake-panel-title p {
    color: var(--color-muted);
    margin-bottom: 0;
}

.mistake-entry-panel,
.mistake-review-panel {
    background: #ffffff;
    border: 1px solid var(--color-line);
    border-radius: 10px;
    box-shadow: var(--shadow-soft);
    margin-bottom: 20px;
}

.mistake-entry-panel {
    border-left: 4px solid var(--color-navy);
    padding: 18px;
}

.mistake-panel-title,
.mistake-review-toolbar {
    align-items: center;
    display: flex;
    justify-content: space-between;
    gap: 16px;
}

.mistake-panel-title {
    margin-bottom: 14px;
}

.mistake-panel-title h2,
.mistake-review-toolbar h2 {
    font-size: 19px;
    margin: 0 0 4px;
}

.mistake-form {
    display: grid;
    gap: 14px;
    grid-template-columns: 210px minmax(0, 1fr);
}

.mistake-form label {
    display: grid;
    gap: 6px;
    font-size: 13px;
    font-weight: 700;
}

.mistake-form select,
.mistake-form textarea,
.mistake-review-toolbar select {
    border: 1px solid #cbd7e4;
    border-radius: 6px;
    font: inherit;
    padding: 9px 10px;
}

.mistake-form textarea {
    line-height: 1.65;
    resize: vertical;
}

.mistake-content-label {
    align-items: center;
    display: flex;
    justify-content: space-between;
    gap: 10px;
}

.mistake-ai-button {
    background: #eef4ff;
    border: 1px solid #bfd0ed;
    border-radius: 999px;
    color: #204f86;
    cursor: pointer;
    font: inherit;
    font-size: 12px;
    padding: 4px 10px;
}

.mistake-ai-button:hover {
    background: #dfeaff;
}

.mistake-ai-button:disabled {
    cursor: wait;
    opacity: .65;
}

.mistake-ai-suggestion {
    background: #f5f8ff;
    border: 1px solid #cad8ee;
    border-radius: 8px;
    grid-column: 2;
    padding: 12px;
}

.mistake-ai-suggestion > div {
    align-items: center;
    display: flex;
    justify-content: space-between;
}

.mistake-ai-suggestion p {
    line-height: 1.7;
    margin: 10px 0;
    white-space: pre-wrap;
}

.mistake-ai-suggestion > .primary-button {
    display: block;
    margin-left: auto;
}

.mistake-form-actions {
    align-items: center;
    display: flex;
    grid-column: 1 / -1;
    justify-content: flex-end;
    gap: 12px;
}

#mistakeFormError {
    color: #b42318;
}

.mistake-review-toolbar {
    border-bottom: 1px solid var(--color-line);
    padding: 14px 16px;
}

.mistake-review-toolbar > div {
    align-items: baseline;
    display: flex;
    gap: 10px;
}

.mistake-review-toolbar > div span {
    color: var(--color-muted);
    font-size: 13px;
}

.mistake-review-toolbar label {
    align-items: center;
    display: flex;
    gap: 8px;
    font-size: 13px;
}

.mistake-table {
    border-collapse: collapse;
    width: 100%;
}

.mistake-table th {
    background: #eef3f8;
    color: var(--color-navy);
    padding: 11px 16px;
    text-align: left;
}

.mistake-table th:first-child {
    width: 190px;
}

.mistake-table td {
    border-bottom: 1px solid #e7edf3;
    padding: 15px 16px;
    vertical-align: top;
}

.mistake-table tbody tr:last-child td {
    border-bottom: 0;
}

.mistake-table td:first-child small {
    color: var(--color-muted);
    display: block;
    font-size: 11px;
    margin-top: 7px;
}

.mistake-type-badge {
    background: #e8f1fa;
    border-radius: 999px;
    color: #1f5f91;
    display: inline-block;
    font-size: 12px;
    font-weight: 700;
    padding: 4px 9px;
}

.mistake-content {
    line-height: 1.75;
    overflow-wrap: anywhere;
    white-space: pre-wrap;
}

.mistake-row-actions {
    display: flex;
    gap: 7px;
    justify-content: flex-end;
    margin-top: 10px;
}

.mistake-row-actions button {
    font-size: 12px;
    padding: 5px 9px;
}

.mistake-filter-empty,
.mistake-initial-empty td {
    color: var(--color-muted);
    padding: 28px;
    text-align: center;
}

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

    .mistake-ai-suggestion {
        grid-column: 1;
    }

    .mistake-panel-title,
    .mistake-review-toolbar {
        align-items: stretch;
        flex-direction: column;
    }

    .mistake-table th:first-child {
        width: 125px;
    }
}

.project-issuer-list {
    display: grid;
    gap: 18px;
}

.project-issuer-group {
    overflow: hidden;
    background: #ffffff;
    border: 1px solid #cfdceb;
    border-radius: 10px;
    box-shadow: var(--shadow-soft);
}

.project-issuer-heading {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    padding: 15px 18px;
    color: var(--color-navy-dark);
    background: linear-gradient(135deg, #f7fbff, #eef5fc);
    border-bottom: 1px solid transparent;
    cursor: pointer;
    list-style: none;
}

.project-issuer-heading::-webkit-details-marker {
    display: none;
}

.project-issuer-heading::after {
    content: "⌄";
    grid-column: 4;
    color: var(--color-muted);
    font-size: 18px;
    transform: rotate(-90deg);
    transition: transform 0.16s ease;
}

.project-issuer-group[open] > .project-issuer-heading {
    border-bottom-color: var(--color-line);
}

.project-issuer-group[open] > .project-issuer-heading::after {
    transform: rotate(0);
}

.project-issuer-avatar {
    display: grid;
    place-items: center;
    width: 46px;
    height: 46px;
    color: #ffffff;
    background: var(--color-navy);
    border-radius: 11px;
    font-size: 22px;
    font-weight: 800;
    line-height: 1;
}

.project-issuer-title {
    display: grid;
    min-width: 0;
}

.project-issuer-title strong {
    overflow: hidden;
    font-size: 17px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.project-issuer-title small,
.project-issuer-count {
    color: var(--color-muted);
    font-size: 12px;
}

.project-issuer-count {
    padding: 4px 9px;
    background: #ffffff;
    border: 1px solid var(--color-line);
    border-radius: 999px;
    white-space: nowrap;
}

.project-issuer-group > .project-card-grid {
    padding: 16px;
    box-shadow: none;
}

.project-card-grid,
.project-feature-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.project-card,
.project-feature-card {
    min-width: 0;
    background: #ffffff;
    border: 1px solid var(--color-line);
    border-radius: 9px;
    box-shadow: var(--shadow-soft);
}

.project-card {
    display: grid;
    overflow: hidden;
}

.project-card-main {
    display: grid;
    align-content: start;
    gap: 8px;
    min-height: 150px;
    padding: 20px;
}

.project-card-main:hover,
.project-feature-card.active:hover {
    background: #f8fbff;
    border-color: #9cbdda;
}

.project-card h3 {
    margin: 2px 0 0;
    color: var(--color-navy-dark);
    font-size: 18px;
}

.project-card p,
.project-card small,
.project-feature-card p,
.project-recycle-list p {
    margin: 0;
    color: var(--color-muted);
    line-height: 1.6;
}

.project-type-badge {
    justify-self: start;
    padding: 4px 8px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
}

.project-type-badge.issuance {
    color: #14532d;
    background: #dcfce7;
}

.project-type-badge.declaration {
    color: #1e3a8a;
    background: #dbeafe;
}

.project-card-actions {
    justify-content: flex-end;
    gap: 8px;
    padding: 10px 14px;
    background: #f8fafc;
    border-top: 1px solid var(--color-line);
}

.project-empty {
    grid-column: 1 / -1;
    padding: 24px;
    color: var(--color-muted);
    background: #ffffff;
    border: 1px dashed #cbd5e1;
    border-radius: 8px;
    text-align: center;
}

.project-recycle {
    margin-top: 34px;
}

.project-recycle > summary {
    color: var(--color-navy);
    cursor: pointer;
    font-weight: 700;
}

.project-recycle-list {
    display: grid;
    gap: 8px;
    margin-top: 14px;
}

.project-recycle-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 14px;
}

.project-recycle-list > div,
.recycle-row-list > div {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 12px;
    background: #f8fafc;
    border: 1px solid var(--color-line);
    border-radius: 7px;
}

.project-modal select,
.import-modal select,
.import-modal input,
.survey-import-modal select,
.survey-import-modal input {
    width: 100%;
    min-height: 38px;
    padding: 8px 10px;
    color: var(--color-text);
    background: #ffffff;
    border: 1px solid var(--color-line);
    border-radius: 6px;
    font: inherit;
}

.project-delete-modal {
    width: min(460px, 100%);
}

.project-delete-modal p {
    color: var(--color-text);
    line-height: 1.7;
}

.project-delete-modal .project-delete-hint {
    margin-top: 10px;
    padding: 10px 12px;
    color: #8b2635;
    background: #fff4f4;
    border: 1px solid #ffd1d6;
    border-radius: 7px;
    font-size: 13px;
}

.project-breadcrumb {
    gap: 8px;
    margin-bottom: 14px;
    color: var(--color-muted);
    font-size: 13px;
}

.project-breadcrumb a {
    color: var(--color-blue);
}

.sales-control-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 8px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--color-line);
}

.sales-project-summary {
    flex: 1 1 auto;
    min-width: 280px;
}

.sales-project-summary .project-breadcrumb {
    margin-bottom: 5px;
    font-size: 12px;
}

.sales-project-line {
    display: flex;
    align-items: baseline;
    gap: 9px;
    min-width: 0;
    white-space: nowrap;
}

.sales-project-line h1 {
    overflow: hidden;
    margin: 0;
    font-size: 24px;
    text-overflow: ellipsis;
}

.sales-project-line > span:last-child {
    overflow: hidden;
    max-width: 180px;
    color: var(--color-muted);
    font-size: 13px;
    text-overflow: ellipsis;
}

.sales-module-badge {
    flex: 0 0 auto;
    padding: 3px 7px;
    color: #1d5d8f;
    background: #e9f3fb;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
}

.project-feature-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    max-width: 1000px;
}

.project-function-heading {
    margin: 0 0 12px;
    max-width: 1000px;
}

.project-function-heading .eyebrow {
    margin-bottom: 3px;
}

.project-function-heading h2 {
    color: var(--color-navy);
    font-size: 20px;
    margin: 0;
}

.project-feature-card {
    display: flex;
    gap: 16px;
    min-height: 180px;
    padding: 24px;
}

.project-feature-card > span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    width: 42px;
    height: 42px;
    color: #ffffff;
    background: var(--color-navy);
    border-radius: 8px;
    font-weight: 700;
}

.project-feature-card h2 {
    margin: 7px 0 10px;
}

.project-feature-card.disabled {
    color: #64748b;
    background: #f8fafc;
}

.project-feature-card.disabled > span {
    background: #94a3b8;
}

.project-feature-card small {
    display: inline-block;
    margin-top: 12px;
    padding: 4px 8px;
    color: #475569;
    background: #e2e8f0;
    border-radius: 999px;
}

.post-issuance-heading {
    align-items: flex-end;
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 18px;
}

.post-issuance-heading h1 {
    margin-bottom: 8px;
}

.post-issuance-heading p:last-child {
    color: var(--color-muted);
    margin: 0;
}

.post-issuance-upload {
    align-items: center;
    background: #f8fafc;
    border: 1px solid var(--color-line);
    border-left: 4px solid var(--color-navy);
    border-radius: 10px;
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 20px;
    padding: 16px 18px;
}

.post-issuance-upload h2 {
    font-size: 18px;
    margin-bottom: 5px;
}

.post-issuance-upload p {
    color: var(--color-muted);
    margin: 0;
}

.post-issuance-upload form {
    align-items: center;
    display: flex;
    flex: 0 0 auto;
    gap: 10px;
}

.post-issuance-messages p {
    border-radius: 8px;
    margin: 0 0 14px;
    padding: 10px 14px;
}

.post-issuance-messages .success {
    background: #ecfdf3;
    color: #067647;
}

.post-issuance-messages .error {
    background: #fef3f2;
    color: #b42318;
}

.post-issuance-workbook {
    background: #ffffff;
    border: 1px solid var(--color-line);
    border-radius: 10px;
    overflow: hidden;
}

.post-issuance-toolbar {
    align-items: center;
    background: #ffffff;
    border-bottom: 1px solid var(--color-line);
    display: flex;
    justify-content: flex-end;
    padding: 9px 12px;
}

.allocation-filter.active {
    background: var(--color-navy);
    border-color: var(--color-navy);
    color: #ffffff;
}

.post-issuance-tabs {
    background: #eef3f8;
    border-bottom: 1px solid var(--color-line);
    display: flex;
    gap: 3px;
    overflow-x: auto;
    padding: 8px 10px 0;
}

.post-issuance-tab {
    background: transparent;
    border: 0;
    border-bottom: 3px solid transparent;
    color: var(--color-muted);
    cursor: pointer;
    min-width: 150px;
    padding: 9px 14px 8px;
    text-align: left;
}

.post-issuance-tab.active {
    background: #ffffff;
    border-bottom-color: var(--color-blue);
    color: var(--color-navy);
    font-weight: 700;
}

.post-issuance-tab small {
    display: block;
    font-size: 11px;
    font-weight: 400;
    margin-top: 3px;
}

.post-issuance-sheet {
    padding: 14px;
}

.post-issuance-sheet-meta {
    align-items: center;
    display: flex;
    flex-wrap: wrap;
    gap: 8px 16px;
    margin-bottom: 12px;
}

.post-issuance-sheet-meta span {
    color: var(--color-muted);
    font-size: 12px;
}

.post-issuance-table-wrap {
    max-height: min(68vh, 720px);
    overflow: auto;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
}

.post-issuance-table {
    border-collapse: collapse;
    min-width: 940px;
    width: 100%;
}

.post-issuance-table th {
    background: var(--color-navy);
    color: #ffffff;
    font-size: 13px;
    padding: 10px;
    position: sticky;
    text-align: left;
    top: 0;
    white-space: nowrap;
    z-index: 4;
}

.column-filter-heading {
    align-items: center;
    display: flex;
    gap: 8px;
    justify-content: space-between;
    position: relative;
}

.column-filter-trigger {
    align-items: center;
    background: rgba(255, 255, 255, .12);
    border: 1px solid rgba(255, 255, 255, .35);
    border-radius: 4px;
    color: #ffffff;
    cursor: pointer;
    display: inline-flex;
    font-size: 9px;
    height: 24px;
    justify-content: center;
    padding: 0;
    width: 24px;
}

.column-filter-trigger:hover,
.column-filter-trigger.active {
    background: #ffffff;
    color: var(--color-navy);
}

.column-filter-trigger.active::after {
    background: #f79009;
    border-radius: 50%;
    content: "";
    height: 6px;
    position: absolute;
    right: -2px;
    top: -2px;
    width: 6px;
}

.column-filter-menu {
    background: #ffffff;
    border: 1px solid #cbd6e2;
    border-radius: 8px;
    box-shadow: 0 12px 30px rgba(15, 39, 66, .22);
    color: var(--color-text);
    max-height: min(380px, calc(100vh - 24px));
    padding: 12px;
    position: fixed;
    white-space: normal;
    width: 300px;
    z-index: 1000;
}

.column-filter-search input {
    border: 1px solid #cbd6e2;
    border-radius: 6px;
    color: var(--color-text);
    font: inherit;
    padding: 9px 10px;
    width: 100%;
}

.column-filter-search input:focus {
    border-color: var(--color-blue);
    box-shadow: 0 0 0 3px rgba(55, 132, 191, .12);
    outline: 0;
}

.column-filter-actions {
    display: flex;
    gap: 12px;
    padding: 8px 0 6px;
}

.column-filter-actions button {
    background: none;
    border: 0;
    color: var(--color-blue);
    cursor: pointer;
    font-size: 12px;
    padding: 0;
}

.column-filter-options {
    border-bottom: 1px solid #e7edf3;
    border-top: 1px solid #e7edf3;
    max-height: 230px;
    overflow-y: auto;
    padding: 5px 0;
}

.column-filter-options label {
    align-items: flex-start;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    font-weight: 400;
    gap: 7px;
    padding: 6px;
}

.column-filter-options label:hover {
    background: #f1f5f9;
}

.column-filter-options input {
    flex: 0 0 auto;
    margin-top: 2px;
}

.column-filter-options span {
    overflow-wrap: anywhere;
}

.column-filter-footer {
    display: flex;
    gap: 8px;
    justify-content: flex-end;
    padding-top: 9px;
}

.column-filter-footer button {
    padding: 6px 12px;
}

.post-issuance-table th .column-filter-menu button {
    font-size: 12px;
    white-space: nowrap;
}

.post-issuance-table td {
    border-bottom: 1px solid #e7edf3;
    padding: 9px 10px;
    vertical-align: middle;
}

.post-issuance-table tbody tr:hover {
    background: #f8fafc;
}

.post-issuance-table th:first-child,
.post-issuance-table td:first-child {
    text-align: center;
    width: 54px;
}

.post-issuance-table th:nth-child(2) {
    width: 31%;
}

.post-issuance-table th:nth-child(3) {
    width: 32%;
}

.post-issuance-table th:nth-child(4) {
    width: 150px;
}

.post-issuance-table .number-cell {
    text-align: right;
    white-space: nowrap;
}

.real-investor-input,
.identity-select {
    background: #fffdf5;
    border: 1px solid #d5dfeb;
    border-radius: 5px;
    font: inherit;
    padding: 7px 8px;
    width: 100%;
}

.real-investor-input {
    line-height: 1.45;
    min-height: 58px;
    overflow: hidden;
    resize: none;
    white-space: pre-wrap;
    word-break: break-word;
}

.real-investor-input:focus,
.identity-select:focus {
    border-color: var(--color-blue);
    outline: 2px solid rgba(55, 132, 191, .14);
}

.save-state {
    color: #067647;
    display: block;
    font-size: 11px;
    min-height: 14px;
    margin-top: 2px;
}

.save-state.error {
    color: #b42318;
}

.post-issuance-export-actions {
    align-items: center;
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 16px;
}

.post-issuance-export-actions small {
    color: var(--color-muted);
}

@media (max-width: 760px) {
    .post-issuance-heading,
    .post-issuance-upload,
    .post-issuance-upload form {
        align-items: stretch;
        flex-direction: column;
    }

    .post-issuance-export-actions {
        align-items: stretch;
        flex-direction: column;
    }
}

.sales-toolbar {
    flex: 0 0 auto;
    flex-wrap: nowrap;
    justify-content: flex-end;
    gap: 6px;
    white-space: nowrap;
}

.sales-toolbar .plain-button,
.sales-toolbar .danger-button,
.sales-toolbar .primary-button {
    min-height: 34px;
    padding: 6px 10px;
    font-size: 13px;
}

.sales-legend {
    flex: 0 0 auto;
    flex-wrap: nowrap;
    gap: 4px;
    margin: 0;
}

.sales-legend span,
.sales-legend button {
    padding: 3px 6px;
    border: 1px solid transparent;
    border-radius: 999px;
    font-family: inherit;
    font-size: 12px;
    font-weight: 700;
}

.sales-legend button { cursor: pointer; }
.sales-legend button:hover { filter: brightness(.96); }
.sales-legend button:focus-visible { outline: 2px solid #2f6ea3; outline-offset: 2px; }

.sales-status-rail {
    display: grid;
    grid-template-columns: auto auto minmax(320px, 1fr) auto;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
    padding: 5px;
    background: #f8fafc;
    border: 1px solid #dbe3ec;
    border-radius: 8px;
}

.sales-type-filter {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #475569;
    font-size: 12px;
    font-weight: 700;
    white-space: nowrap;
}

.sales-type-filter details {
    position: relative;
}

.sales-type-filter summary {
    min-width: 112px;
    height: 30px;
    box-sizing: border-box;
    padding: 5px 26px 5px 8px;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    color: #172b4d;
    background: #fff;
    cursor: pointer;
    list-style: none;
}

.sales-type-filter summary::-webkit-details-marker { display: none; }
.sales-type-filter summary::after {
    position: absolute;
    top: 8px;
    right: 9px;
    content: '⌄';
}

.sales-type-filter-menu {
    position: absolute;
    z-index: 20;
    top: calc(100% + 4px);
    left: 0;
    display: grid;
    min-width: 180px;
    max-height: 300px;
    padding: 6px;
    overflow-y: auto;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    background: #fff;
    box-shadow: 0 10px 24px rgba(15,47,85,.14);
}

.sales-type-filter-menu label {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 7px;
    border-radius: 4px;
    color: #172b4d;
    cursor: pointer;
    font-weight: 500;
}

.sales-type-filter-menu label:hover { background: #edf5fb; }
.sales-type-filter-menu input { margin: 0; }

.sales-legend .high { color: #166534; background: #dcfce7; }
.sales-legend .medium { color: #854d0e; background: #fef9c3; }
.sales-legend .low { color: #991b1b; background: #fee2e2; }
.sales-legend .stale { color: #475569; background: #f1f5f9; border-color: #94a3b8; border-style: dashed; }

.analysis-live-status {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
    min-height: 32px;
    margin: 0;
    padding: 6px 9px;
    color: #334155;
    background: #f8fafc;
    border: 1px solid #d7e0ea;
    border-radius: 8px;
    font-size: 13px;
}

.analysis-live-status strong { color: #163b60; }
.analysis-live-status > span:last-child {
    overflow: hidden;
    color: #64748b;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.analysis-status-dot {
    flex: 0 0 auto;
    width: 9px;
    height: 9px;
    background: #94a3b8;
    border-radius: 50%;
}

.analysis-live-status.running { background: #eaf3fa; border-color: #b9d5e9; }
.analysis-live-status.running .analysis-status-dot {
    background: #2f6ea3;
    box-shadow: 0 0 0 4px rgb(47 110 163 / 14%);
    animation: analysis-status-pulse 1.2s ease-in-out infinite;
}
.analysis-live-status.success { background: #ecf8f0; border-color: #b8dfc5; }
.analysis-live-status.success .analysis-status-dot { background: #22a65a; }
.analysis-live-status.stale { background: #fff9e6; border-color: #ead89b; }
.analysis-live-status.stale .analysis-status-dot { background: #d8a400; }
.analysis-live-status.error { background: #fff0f0; border-color: #efc1c1; }
.analysis-live-status.error .analysis-status-dot { background: #dc2626; }

@keyframes analysis-status-pulse {
    50% { opacity: .45; transform: scale(.82); }
}

.quota-total-bar {
    display: flex;
    align-items: baseline;
    flex: 0 0 auto;
    flex-wrap: nowrap;
    gap: 10px;
    margin: 0;
    padding: 3px 8px 3px 12px;
    color: #334155;
    background: transparent;
    border: 0;
    border-left: 1px solid #c8dbea;
    border-radius: 0;
    font-size: 13px;
    white-space: nowrap;
}

.quota-total-bar strong { color: #0b3b63; font-size: 15px; }
.quota-total-bar small { color: #64748b; }

.sales-toast {
    position: fixed;
    top: 88px;
    right: 18px;
    z-index: 80;
    width: min(520px, calc(100vw - 36px));
    box-shadow: 0 10px 30px rgb(15 42 68 / 18%);
}

.sales-table-panel {
    min-width: 0;
    background: #ffffff;
    border: 1px solid var(--color-line);
    border-radius: 9px;
    box-shadow: var(--shadow-soft);
}

.sales-table-wrap {
    max-height: calc(100vh - 190px);
    overflow: auto;
    border-radius: 9px;
}

.sales-table {
    width: 100%;
    min-width: 1432px;
    border-collapse: separate;
    border-spacing: 0;
    table-layout: fixed;
    font-size: 13px;
}

.sales-table th,
.sales-table td {
    padding: 4px 5px;
    border-right: 1px solid #dbe3ec;
    border-bottom: 1px solid #dbe3ec;
    vertical-align: middle;
}

.sales-table th {
    position: sticky;
    top: 0;
    z-index: 5;
    padding: 8px 6px;
    color: #ffffff;
    background: var(--color-navy);
    text-align: center;
    white-space: nowrap;
}

.sales-table th:first-child,
.sales-table td:first-child {
    position: sticky;
    left: 0;
    z-index: 4;
}

.sales-table th:first-child { z-index: 7; }
.sequence-heading {
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.sequence-heading input {
    width: 14px;
    height: 14px;
    margin: 0 5px 0 0;
    vertical-align: -2px;
    accent-color: #5da3d9;
    cursor: pointer;
}

.sales-table th[data-resizable-column] {
    padding-right: 12px;
}

.sales-column-resizer {
    position: absolute;
    top: 0;
    right: -4px;
    z-index: 9;
    width: 9px;
    height: 100%;
    padding: 0;
    background: transparent;
    border: 0;
    cursor: col-resize;
    touch-action: none;
}

.sales-column-resizer::after {
    position: absolute;
    top: 22%;
    right: 4px;
    width: 1px;
    height: 56%;
    content: '';
    background: rgba(255,255,255,.55);
}

.sales-column-resizer:hover::after,
.resizing-sales-column .sales-column-resizer::after {
    width: 2px;
    background: #ffffff;
}

.resizing-sales-column {
    cursor: col-resize;
    user-select: none;
}

.sales-table tbody tr {
    --sales-row-bg: #f8fafc;
    --sales-row-focus: #ffffff;
    background: var(--sales-row-bg);
}
.sales-table tbody tr.likelihood-high {
    --sales-row-bg: #ecf8f0;
    --sales-row-focus: #f5fcf7;
}
.sales-table tbody tr.likelihood-medium {
    --sales-row-bg: #fff9e6;
    --sales-row-focus: #fffdf4;
}
.sales-table tbody tr.likelihood-low {
    --sales-row-bg: #fff0f0;
    --sales-row-focus: #fff8f8;
}
.sales-table tbody tr.analysis-stale { background-image: repeating-linear-gradient(135deg, transparent 0, transparent 12px, rgba(100,116,139,.045) 12px, rgba(100,116,139,.045) 24px); }
.sales-table tbody tr td:first-child { background: inherit; }

.sales-table input:not([type="checkbox"]),
.sales-table select,
.sales-table textarea {
    width: 100%;
    min-width: 0;
    padding: 4px 6px;
    color: var(--color-text);
    background: var(--sales-row-bg);
    border: 1px solid rgba(100,116,139,.14);
    border-radius: 5px;
    font: inherit;
    line-height: 1.3;
}

.sales-table input.invalid-quota {
    color: #991b1b;
    background: #fff0f0;
    border-color: #dc2626;
    box-shadow: 0 0 0 2px rgb(220 38 38 / 10%);
}

.sales-table textarea {
    min-height: 32px;
    overflow: hidden;
    resize: none;
}

.sales-table input:focus,
.sales-table select:focus,
.sales-table textarea:focus {
    outline: 0;
    background: var(--sales-row-focus);
    border-color: #6ea5d1;
    box-shadow: 0 0 0 2px rgba(47,110,163,.12);
}

.sequence-cell {
    align-items: center;
    justify-content: center;
    gap: 7px;
    text-align: center;
}

.sequence-cell,
.feedback-cell {
    position: relative;
}

.sequence-cell.reorder-enabled { cursor: grab; }
.sequence-cell.reorder-enabled:active { cursor: grabbing; }
.sales-table tr.dragging { opacity: .55; }
.sales-table tr.drag-over td { box-shadow: inset 0 3px #2f6ea3; }

.ai-status-dot {
    width: 12px;
    height: 12px;
    padding: 0;
    background: #cbd5e1;
    border: 1px solid rgba(15,23,42,.15);
    border-radius: 50%;
    cursor: help;
}

.ai-status-dot.high { background: #22c55e; }
.ai-status-dot.medium { background: #eab308; }
.ai-status-dot.low { background: #ef4444; }

.auto-save-status {
    display: inline-flex;
    align-items: center;
    min-height: 34px;
    padding: 0 10px;
    color: #475569;
    background: #e8eef5;
    border: 1px solid #cbd7e5;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 700;
    white-space: nowrap;
}

.auto-save-status::before {
    width: 7px;
    height: 7px;
    margin-right: 6px;
    content: '';
    background: #64748b;
    border-radius: 50%;
}

.auto-save-status.saved { color: #166534; background: #ecf8f0; border-color: #b8dfc5; }
.auto-save-status.saved::before { background: #22a65a; }
.auto-save-status.pending { color: #854d0e; background: #fff9e6; border-color: #ead89b; }
.auto-save-status.pending::before { background: #d8a400; }
.auto-save-status.saving { color: #164e7a; background: #eaf3fa; border-color: #b9d5e9; }
.auto-save-status.saving::before { background: #2f6ea3; }
.auto-save-status.error { color: #991b1b; background: #fff0f0; border-color: #efc1c1; }
.auto-save-status.error::before { background: #dc2626; }

.import-modal {
    width: min(1180px, 100%);
}

.survey-import-modal {
    width: min(1320px, 100%);
}

.modal-help {
    margin: -4px 0 12px;
    color: var(--color-muted);
    font-size: 13px;
}

.survey-import-mapping {
    display: grid;
    grid-template-columns: repeat(6, minmax(130px, 1fr));
    gap: 10px;
    align-items: end;
    margin-bottom: 14px;
}

.survey-import-mapping label {
    display: flex;
    align-items: stretch;
    flex-direction: column;
    gap: 5px;
    color: #334155;
    font-size: 12px;
    font-weight: 700;
}

.survey-import-summary {
    margin: 2px 0 10px;
    color: #334155;
    font-size: 13px;
    font-weight: 700;
}

.survey-change-wrap {
    max-height: 480px;
}

.survey-change-table th:last-child,
.survey-change-table td:last-child {
    width: 82px;
    text-align: center;
}

.survey-change-table td:nth-child(1) { min-width: 190px; }
.survey-change-table td:nth-child(2) { min-width: 150px; }
.survey-change-table td:nth-child(3),
.survey-change-table td:nth-child(4) {
    min-width: 210px;
    white-space: pre-wrap;
    word-break: break-word;
}

.survey-sensitive-change td {
    background: #fff9e6;
}

.survey-sensitive-change td:nth-child(2) {
    color: #854d0e;
    font-weight: 700;
}

.survey-change-none td {
    color: #64748b;
    background: #f8fafc;
}

.import-warnings {
    margin-bottom: 12px;
    padding: 10px 12px;
    color: #92400e;
    background: #fffbeb;
    border: 1px solid #fde68a;
    border-radius: 7px;
}

.import-warnings[hidden] { display: none; }

.import-conflicts {
    display: grid;
    gap: 8px;
    margin-bottom: 14px;
    padding: 12px;
    background: #fff7ed;
    border: 1px solid #fdba74;
    border-radius: 8px;
}

.import-conflicts[hidden] { display: none; }

.import-conflicts h3 {
    margin: 0 0 2px;
    color: #9a3412;
    font-size: 14px;
}

.import-conflict-card {
    display: grid;
    grid-template-columns: 170px minmax(0, 1fr);
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    background: #ffffff;
    border: 1px solid #fed7aa;
    border-radius: 6px;
}

.import-conflict-card > span {
    color: #7c2d12;
    font-weight: 700;
}

.import-conflict-card select {
    width: 100%;
}

.import-conflict-card.resolved {
    background: #f0fdf4;
    border-color: #86efac;
}

.import-mapping-grid {
    display: grid;
    grid-template-columns: repeat(6, minmax(120px, 1fr));
    gap: 10px;
    align-items: end;
    margin-bottom: 14px;
}

.import-mapping-grid label {
    align-items: stretch;
    flex-direction: column;
    gap: 5px;
    color: #334155;
    font-size: 12px;
    font-weight: 700;
}

.import-preview-wrap {
    max-height: 430px;
    overflow: auto;
    border: 1px solid var(--color-line);
    border-radius: 8px;
}

.import-preview-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}

.import-preview-table th,
.import-preview-table td {
    padding: 8px 10px;
    border-bottom: 1px solid var(--color-line);
    text-align: left;
}

.import-preview-table th {
    position: sticky;
    top: 0;
    color: #334155;
    background: #eef3f8;
}

.recycle-row-list {
    display: grid;
    gap: 8px;
}

@media (max-width: 1500px) {
    .sales-control-header {
        align-items: stretch;
        flex-direction: column;
        gap: 8px;
    }

    .sales-toolbar {
        justify-content: flex-start;
        width: 100%;
        padding-bottom: 2px;
        overflow-x: auto;
    }

    .sales-status-rail {
        grid-template-columns: auto auto minmax(280px, 1fr);
    }

    .quota-total-bar {
        grid-column: 1 / -1;
        justify-content: flex-end;
        padding-top: 0;
        border-left: 0;
    }
}

@media (max-width: 900px) {
    .topbar {
        align-items: flex-start;
        flex-wrap: wrap;
        gap: 0 16px;
        padding: 12px 18px 0;
    }

    .main-nav {
        order: 3;
        flex-basis: 100%;
    }

    .nav-link {
        min-height: 48px;
    }

    .summary-grid,
    .content-grid {
        grid-template-columns: 1fr;
    }

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

    .bond-reminder-header {
        align-items: flex-start;
        flex-direction: column;
    }

    .bond-reminder-stats {
        justify-content: flex-start;
    }

    .bond-sections {
        grid-template-columns: 1fr;
    }

    .tool-grid.columns-3,
    .tool-grid.columns-4,
    .tool-grid.columns-5 {
        grid-template-columns: 1fr;
    }

    .tool-card {
        align-items: flex-start;
        flex-direction: column;
    }

    .intern-workspace {
        grid-template-columns: 1fr;
    }

    .intern-sidebar {
        position: static;
    }

    .schedule-toolbar {
        align-items: flex-start;
        flex-direction: column;
    }

    .schedule-actions {
        justify-content: flex-start;
    }

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

    .common-site-form,
    .common-site-row {
        grid-template-columns: 1fr;
    }

    .common-sites-list.columns-2,
    .common-sites-list.columns-3,
    .common-sites-list.columns-4,
    .common-sites-list.columns-5 {
        grid-template-columns: 1fr;
    }

    .info-toolbar {
        display: grid;
        align-items: stretch;
    }

    .info-layout-form {
        align-items: stretch;
    }

    .info-card-grid.columns-3,
    .info-card-grid.columns-4,
    .info-card-grid.columns-5 {
        grid-template-columns: 1fr;
    }

    .info-form-grid,
    .info-item-editor-row {
        grid-template-columns: 1fr;
    }

    .info-card-actions,
    .info-form-actions,
    .info-delete-form {
        justify-content: stretch;
    }

    .account-actions {
        align-items: stretch;
        flex-direction: column-reverse;
    }

    .project-heading,
    .sales-heading {
        align-items: flex-start;
        flex-direction: column;
    }

    .project-card-grid,
    .project-feature-grid {
        grid-template-columns: 1fr;
    }

    .sales-toolbar {
        justify-content: flex-start;
    }

    .sales-status-rail {
        display: flex;
        align-items: stretch;
        flex-direction: column;
    }

    .sales-legend { overflow-x: auto; }

    .quota-total-bar {
        justify-content: flex-start;
        overflow-x: auto;
    }

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

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

@media (max-width: 560px) {
    .brand-text {
        font-size: 15px;
    }

    .admin-link {
        margin-left: auto;
    }

    .page-shell {
        width: min(100% - 24px, 1180px);
        padding-top: 24px;
    }

    h1 {
        font-size: 24px;
    }
}
