:root {
    --bg: #ffffff;
    --bg-soft: #f7f9fc;
    --paper: rgba(255, 255, 255, 0.96);
    --paper-strong: #ffffff;
    --paper-tint: #fbfcfe;
    --line: #e4ebf2;
    --line-strong: #d5dee8;
    --ink: #1a2430;
    --muted: #6d7683;
    --accent: #1d5148;
    --accent-strong: #143b35;
    --accent-soft: #edf5f1;
    --sub-accent: #5a738f;
    --sub-accent-soft: #eef3f8;
    --danger: #a43c45;
    --shadow: 0 22px 50px rgba(31, 37, 48, 0.08);
    --shadow-soft: 0 10px 24px rgba(31, 37, 48, 0.05);
    --radius: 24px;
    --font-zh: "Microsoft YaHei UI", "Microsoft YaHei", "PingFang SC", "Noto Sans SC", sans-serif;
    --font-ja: "Hiragino Sans", "Yu Gothic", "Meiryo", "Noto Sans JP", sans-serif;
    --font-latin: "Segoe UI", "Helvetica Neue", Arial, sans-serif;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: var(--font-zh);
    background:
        radial-gradient(circle at top right, rgba(29, 81, 72, 0.04), transparent 28%),
        linear-gradient(180deg, rgba(255, 255, 255, 1), rgba(247, 249, 252, 0.94)),
        #ffffff;
    background-size: auto, auto, auto, auto;
    color: var(--ink);
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

html[lang^="zh"] body {
    font-family: var(--font-zh);
}

html[lang^="ja"] body {
    font-family: var(--font-ja);
}

body,
button,
input,
select,
textarea {
    font-family: inherit;
}

a {
    color: var(--accent);
    text-decoration: none;
}

img {
    max-width: 100%;
    display: block;
}

.plan-image {
    width: 100%;
    max-height: 420px;
    object-fit: contain;
    border-radius: 16px;
    border: 1px solid var(--line);
    background: #fff;
    padding: 12px;
}

.layout-shell {
    min-height: 100vh;
    padding: 24px;
}

.site-header,
.section-head,
.button-row,
.search-bar,
.top-nav,
.photo-row,
.header-actions,
.language-switcher {
    display: flex;
    gap: 12px;
    align-items: center;
}

.site-header,
.section-head,
.button-row,
.search-bar,
.photo-row {
    justify-content: space-between;
}

.button-row.button-row-left {
    justify-content: flex-start !important;
}

.site-header {
    display: grid;
    grid-template-columns: minmax(280px, 1fr) minmax(0, 1.8fr);
    margin-bottom: 24px;
    padding: 20px 24px;
    position: relative;
    z-index: 60;
    overflow: visible;
    border-radius: var(--radius);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.99), rgba(251, 252, 254, 0.96));
    border: 1px solid rgba(228, 235, 242, 0.92);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.8),
        var(--shadow);
    backdrop-filter: blur(10px);
}

.header-actions {
    display: grid;
    gap: 10px;
    justify-items: end;
    align-items: flex-end;
    position: relative;
    z-index: 61;
}

.top-nav {
    flex-wrap: wrap;
    justify-content: flex-end;
    row-gap: 8px;
    column-gap: 8px;
    position: relative;
    z-index: 62;
    overflow: visible;
}

.top-nav a {
    display: inline-flex;
    align-items: center;
    min-height: 34px;
    padding: 0 12px;
    border-radius: 999px;
    color: var(--accent-strong);
    background: rgba(255, 255, 255, 0.94);
    border: 1px solid rgba(228, 235, 242, 0.92);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.86);
    transition: transform 0.18s ease, border-color 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

.top-nav a:hover {
    transform: translateY(-1px);
    background: rgba(248, 251, 254, 0.98);
    border-color: rgba(29, 81, 72, 0.2);
    box-shadow: 0 12px 24px rgba(31, 37, 48, 0.08);
}

.top-nav form {
    margin: 0;
}

.nav-menu {
    position: relative;
    z-index: 63;
}

.nav-menu summary {
    list-style: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 34px;
    padding: 0 12px;
    border-radius: 999px;
    color: var(--accent-strong);
    background: rgba(255, 255, 255, 0.94);
    border: 1px solid rgba(228, 235, 242, 0.92);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.86);
    cursor: pointer;
    transition: transform 0.18s ease, border-color 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

.nav-menu summary::-webkit-details-marker {
    display: none;
}

.nav-menu summary::after {
    content: "";
    width: 8px;
    height: 8px;
    border-right: 1.5px solid currentColor;
    border-bottom: 1.5px solid currentColor;
    transform: rotate(45deg) translateY(-1px);
    opacity: 0.68;
}

.nav-menu[open] summary,
.nav-menu summary:hover {
    transform: translateY(-1px);
    background: rgba(248, 251, 254, 1);
    border-color: rgba(29, 81, 72, 0.18);
    box-shadow: 0 12px 24px rgba(31, 37, 48, 0.08);
}

.nav-dropdown {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    min-width: 210px;
    display: grid;
    gap: 6px;
    padding: 12px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.99);
    border: 1px solid rgba(228, 235, 242, 0.94);
    box-shadow: 0 18px 40px rgba(31, 37, 48, 0.12);
    z-index: 80;
}

.nav-menu[open] {
    z-index: 79;
}

.nav-dropdown a {
    display: block;
    min-height: auto;
    padding: 10px 12px;
    border-radius: 12px;
    background: transparent;
    border: 0;
    box-shadow: none;
    color: var(--ink);
}

.nav-dropdown a:hover {
    transform: none;
    background: rgba(237, 245, 241, 0.92);
    border-color: transparent;
    box-shadow: none;
}

.dashboard-page .layout-shell {
    background:
        radial-gradient(circle at top center, rgba(29, 81, 72, 0.04), transparent 24%);
}

.dashboard-page .site-header,
.site-header-dashboard {
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.99), rgba(251, 252, 254, 0.97));
    border-color: rgba(228, 235, 242, 0.94);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.82),
        0 18px 42px rgba(31, 37, 48, 0.08);
}

.dashboard-page .brand,
.site-header-dashboard .brand {
    color: var(--ink);
    text-shadow: none;
}

.dashboard-page .brand-subtitle,
.site-header-dashboard .brand-subtitle {
    color: var(--muted);
}

.dashboard-page .top-nav a,
.dashboard-page .nav-menu summary,
.site-header-dashboard .top-nav a {
    color: var(--accent-strong);
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid rgba(228, 235, 242, 0.92);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.82);
}

.dashboard-page .top-nav a:hover,
.dashboard-page .nav-menu[open] summary,
.dashboard-page .nav-menu summary:hover,
.site-header-dashboard .top-nav a:hover {
    background: rgba(248, 251, 254, 1);
    border-color: rgba(29, 81, 72, 0.18);
}

.dashboard-page .lang-button,
.dashboard-page .button-secondary,
.site-header-dashboard .lang-button,
.site-header-dashboard .button-secondary {
    background: rgba(255, 255, 255, 0.96);
    color: var(--accent-strong);
    border: 1px solid rgba(228, 235, 242, 0.92);
}

.dashboard-page .lang-button.active,
.site-header-dashboard .lang-button.active {
    background: linear-gradient(135deg, #1d5148 0%, #25665a 100%);
    color: #fff;
    border-color: transparent;
}

.language-switcher {
    gap: 8px;
}

.brand {
    font-size: 1.45rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    color: var(--ink);
}

.brand-subtitle,
.muted,
small,
.field-help {
    color: var(--muted);
}

.content-shell,
.stack {
    display: grid;
    gap: 18px;
}

.content-shell {
    position: relative;
    z-index: 1;
}

.page-shell {
    display: grid;
    gap: 18px;
}

.pagination-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}

.title-row {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    align-items: flex-start;
    margin-bottom: 18px;
}

.title-row h1,
.title-row h2,
.title-row p {
    margin: 0;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    border-radius: 999px;
    background: rgba(22, 95, 88, 0.08);
    color: var(--accent);
    font-size: 0.9rem;
    font-weight: 700;
    letter-spacing: 0.04em;
}

.page-intro {
    margin-top: 10px;
    max-width: 64ch;
    color: var(--muted);
    line-height: 1.7;
}

.data-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 16px;
}

.data-card {
    padding: 16px 18px;
    border: 1px solid rgba(228, 235, 242, 0.92);
    border-radius: 18px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 1), rgba(251, 252, 254, 0.94));
    box-shadow: var(--shadow-soft);
}

.data-card strong {
    display: block;
    margin-bottom: 6px;
}

.panel-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) minmax(280px, 0.9fr);
    gap: 18px;
}

.hero-panel {
    position: relative;
    overflow: hidden;
}

.hero-panel::after {
    content: "";
    position: absolute;
    right: -48px;
    top: -40px;
    width: 180px;
    height: 180px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(22, 95, 88, 0.14), rgba(22, 95, 88, 0.02) 70%);
    pointer-events: none;
}

.hero-panel > * {
    position: relative;
    z-index: 1;
}

.subtle-card {
    background: rgba(255, 255, 255, 0.9);
}

.meta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}

.status-pill,
.mini-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 7px 12px;
    border-radius: 999px;
    font-size: 0.92rem;
    font-weight: 700;
}

.mini-pill {
    padding: 5px 10px;
    font-size: 0.82rem;
}

.status-pill-active {
    background: rgba(29, 81, 72, 0.1);
    color: var(--accent);
}

.status-pill-expired {
    background: rgba(90, 115, 143, 0.12);
    color: var(--sub-accent);
}

.status-pill-verification {
    background: rgba(155, 44, 44, 0.12);
    color: var(--danger);
}

.status-pill-revoked {
    background: rgba(49, 42, 36, 0.12);
    color: var(--ink);
}

.role-protected-note {
    display: inline-flex;
    align-items: center;
    padding: 8px 14px;
    border-radius: 999px;
    background: rgba(233, 238, 243, 0.9);
    color: var(--muted);
    font-size: 0.9rem;
    font-weight: 600;
    white-space: nowrap;
}

.stats-strip {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 14px;
}

.stat-tile {
    padding: 18px;
    border-radius: 20px;
    border: 1px solid rgba(228, 235, 242, 0.92);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.99), rgba(251, 252, 254, 0.96));
    box-shadow: var(--shadow-soft);
}

.stat-tile strong {
    display: block;
    margin-top: 6px;
    font-size: 1.8rem;
}

.card {
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 24px;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.78),
        var(--shadow);
}

.hero {
    display: grid;
    gap: 18px;
}

.stats-grid,
.grid-two {
    display: grid;
    gap: 18px;
}

.stats-grid {
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.grid-two {
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
}

.stat-card {
    position: relative;
    overflow: hidden;
}

.stat-card-link {
    display: block;
    color: inherit;
    text-decoration: none;
    transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.stat-card-link:hover {
    transform: translateY(-2px);
    border-color: rgba(29, 81, 72, 0.28);
    box-shadow: 0 18px 38px rgba(31, 37, 48, 0.1);
}

.stat-card::after {
    content: "";
    position: absolute;
    right: -24px;
    bottom: -24px;
    width: 84px;
    height: 84px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(214, 223, 234, 0.8), rgba(214, 223, 234, 0.08) 68%);
    pointer-events: none;
}

.stat-card strong {
    display: block;
    margin-top: 8px;
    font-size: 2rem;
}

.stat-label {
    color: var(--muted);
}

.list-row {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 10px 12px;
    border-radius: 16px;
    background: var(--paper-strong);
    border: 1px solid rgba(228, 235, 242, 0.9);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
}

.list-row:hover {
    border-color: rgba(29, 81, 72, 0.2);
    background: linear-gradient(180deg, rgba(255, 255, 255, 1), rgba(237, 245, 241, 0.92));
    box-shadow: 0 10px 24px rgba(31, 37, 48, 0.08);
}

.list-row-main,
.list-row-side {
    display: grid;
    gap: 6px;
}

.list-row-side {
    justify-items: end;
    text-align: right;
}

.list-row--column {
    display: grid;
    gap: 12px;
}

.list-row__headline {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}

.list-row__headline small {
    color: var(--muted);
}

.stack--compact {
    gap: 10px;
}

.list-row-title {
    font-size: 0.95rem;
    font-weight: 700;
}

.list-row-meta {
    color: var(--muted);
    font-size: 0.84rem;
    line-height: 1.4;
}

.list-row.list-row--alert {
    border-color: #f3c6cc;
    background: #fff7f8;
    border-left: 4px solid #bf3348;
}

.list-row.list-row--alert:hover {
    border-color: #efb6bf;
    background: #fff3f5;
}

.list-row-title--alert {
    color: #7a4750;
}

.list-row-meta--alert {
    color: #7a4750;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 2px 8px;
    border-radius: 999px;
    font-weight: 700;
}

.status-badge--alert {
    background: #fdecee;
    border: 1px solid #f1c8cf;
    color: #bf3348;
}

.value-text--alert {
    color: #bf3348;
}

.data-card-value--alert {
    color: #bf3348;
    font-weight: 700;
}

.notice--alert {
    border: 1px solid #f3c6cc;
    background: #fff7f8;
}

.landlord-alert-notice {
    margin-top: 1rem;
}

.landlord-alert-stack {
    margin-top: 0.75rem;
}

.detail-grid {
    display: grid;
    grid-template-columns: minmax(120px, 160px) 1fr;
    gap: 12px 16px;
}

.detail-grid dt {
    color: var(--muted);
    font-weight: 600;
}

.detail-grid dd {
    margin: 0;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 16px;
    margin-top: 20px;
}

.full-span {
    grid-column: 1 / -1;
}

.field-panel {
    padding: 18px;
    border: 1px solid rgba(228, 235, 242, 0.92);
    border-radius: 18px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.99), rgba(251, 252, 254, 0.96));
    box-shadow: var(--shadow-soft);
}

.field-panel textarea,
.field-panel select[multiple] {
    min-height: 180px;
}

.field-errors {
    margin-top: 10px;
    color: var(--danger);
    font-size: 0.9rem;
    line-height: 1.6;
}

.field-errors ul {
    margin: 0;
    padding-left: 18px;
}

label {
    display: inline-block;
    margin-bottom: 8px;
    font-weight: 600;
}

.field-help {
    margin: 8px 2px 0;
    font-size: 0.92rem;
    line-height: 1.5;
}

.checkbox-row {
    display: flex;
    gap: 10px;
    align-items: center;
    padding: 12px 14px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 1), rgba(251, 252, 254, 0.96));
}

.form-checkbox {
    width: 18px;
    height: 18px;
}

.choice-list ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 10px;
}

.choice-list li {
    margin: 0;
}

.choice-list label {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    padding: 12px 14px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 1), rgba(251, 252, 254, 0.96));
    margin: 0;
    font-weight: 500;
}

.choice-list input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin-top: 2px;
    flex: 0 0 auto;
}

.permission-section-list {
    display: grid;
    gap: 16px;
}

.permission-section-card {
    border: 1px solid var(--line);
    border-radius: 18px;
    padding: 18px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 1), rgba(250, 252, 254, 0.96));
    box-shadow: 0 10px 24px rgba(10, 36, 64, 0.05);
}

.permission-section-header {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: baseline;
    margin-bottom: 14px;
}

.permission-section-header h2 {
    margin: 0;
    font-size: 1rem;
}

.permission-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 10px;
}

.permission-option {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    padding: 12px 14px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.92);
    font-weight: 500;
    margin: 0;
}

.permission-option input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin-top: 2px;
    flex: 0 0 auto;
}

.form-control,
.form-select {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.96);
    color: var(--ink);
    font: inherit;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
    transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.form-control:focus,
.form-select:focus {
    outline: 2px solid rgba(29, 81, 72, 0.12);
    border-color: var(--accent);
    box-shadow: 0 0 0 4px rgba(29, 81, 72, 0.06);
}

.form-control-textarea {
    min-height: 120px;
    resize: vertical;
}

.button,
.button-secondary,
.link-button,
.lang-button {
    border: 0;
    border-radius: 999px;
    padding: 12px 18px;
    font: inherit;
    cursor: pointer;
}

.button {
    background: linear-gradient(135deg, #1d5148 0%, #25665a 100%);
    color: #fff;
    box-shadow: 0 12px 24px rgba(29, 81, 72, 0.18);
}

.button-secondary,
.lang-button {
    background: rgba(255, 255, 255, 0.98);
    color: var(--accent-strong);
    border: 1px solid rgba(228, 235, 242, 0.92);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.86);
}

.button-danger {
    background: linear-gradient(135deg, #b24a51 0%, #91363e 100%);
    color: #fff;
    box-shadow: 0 12px 24px rgba(164, 60, 69, 0.18);
}

.lang-button {
    padding: 8px 14px;
    font-size: 0.92rem;
}

.lang-button.active {
    background: linear-gradient(135deg, #1d5148 0%, #25665a 100%);
    color: #fff;
    border-color: transparent;
}

.link-button {
    padding: 0;
    background: transparent;
    color: var(--danger);
}

.error-box,
.notice {
    padding: 12px 14px;
    border-radius: 14px;
}

.error-box {
    background: #fff1f1;
    color: var(--danger);
}

.notice {
    background: linear-gradient(180deg, rgba(237, 245, 241, 0.98), rgba(246, 250, 248, 0.96));
}

.notice--subtle {
    background: rgba(244, 248, 252, 0.92);
    color: var(--muted);
}

.notice-warning {
    background: rgba(184, 111, 66, 0.12);
}

.notice-danger {
    background: rgba(155, 44, 44, 0.1);
}

.empty-state {
    padding: 24px;
    text-align: center;
    border: 1px dashed rgba(219, 229, 234, 0.95);
    border-radius: 18px;
    color: var(--muted);
    background: rgba(255, 255, 255, 0.84);
}

.code-block {
    overflow-x: auto;
    padding: 14px 16px;
    border-radius: 16px;
    background: #fbfcfe;
    border: 1px solid rgba(228, 235, 242, 0.95);
    font-family: "Consolas", "SFMono-Regular", monospace;
    font-size: 0.9rem;
    line-height: 1.7;
    white-space: pre-wrap;
    word-break: break-word;
}

.license-inline-code {
    display: inline-block;
    max-width: 100%;
    font-family: "Consolas", "SFMono-Regular", monospace;
    font-size: 0.92rem;
    line-height: 1.6;
    color: var(--ink);
}

.license-inline-code-break {
    overflow-wrap: anywhere;
    word-break: break-word;
}

.helper-list {
    display: grid;
    gap: 10px;
    margin: 0;
    padding-left: 18px;
    color: var(--muted);
    line-height: 1.65;
}

.photo-row {
    align-items: flex-start;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 1), rgba(251, 252, 254, 0.96));
}

.photo-row img {
    width: 144px;
    height: 108px;
    object-fit: cover;
    border-radius: 12px;
    border: 1px solid var(--line);
}

.inline-form {
    margin-top: 8px;
}

.contract-document-list {
    display: grid;
    gap: 0;
    max-height: 280px;
    overflow-y: auto;
    padding: 4px 0;
}

.contract-document-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 9px 0;
    border-bottom: 1px solid rgba(228, 235, 242, 0.92);
}

.contract-document-row:last-child {
    border-bottom: 0;
}

.contract-document-main {
    min-width: 0;
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 8px;
}

.contract-document-name {
    overflow-wrap: anywhere;
}

.contract-document-actions.inline-form {
    margin-top: 0;
    flex: 0 0 auto;
}

.contract-document-delete {
    border: 0;
    background: transparent;
    padding: 2px 0;
    color: var(--danger);
    font: inherit;
    font-size: 0.88rem;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
}

.contract-document-delete:hover,
.contract-document-delete:focus {
    text-decoration: underline;
    outline: none;
}

.auth-panel {
    min-height: 70vh;
    display: grid;
    place-items: center;
}

.auth-card,
.narrow-card {
    width: min(100%, 560px);
    margin: 0 auto;
}

.wide-card {
    width: min(100%, 1180px);
    margin: 0 auto;
}

.dashboard-shell {
    display: grid;
    gap: 22px;
    position: relative;
    padding: 28px;
    border-radius: 32px;
    background:
        radial-gradient(circle at top left, rgba(214, 223, 234, 0.3), transparent 24%),
        radial-gradient(circle at top right, rgba(29, 81, 72, 0.06), transparent 24%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.99) 0%, rgba(251, 252, 254, 0.98) 100%);
    border: 1px solid rgba(228, 235, 242, 0.94);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.84),
        0 26px 60px rgba(31, 37, 48, 0.08);
    overflow: hidden;
}

.dashboard-shell::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(214, 223, 234, 0.26) 1px, transparent 1px),
        linear-gradient(rgba(29, 81, 72, 0.03) 1px, transparent 1px);
    background-size: 40px 40px;
    opacity: 0.45;
    pointer-events: none;
}

.dashboard-shell::after {
    content: "";
    position: absolute;
    inset: -10% auto auto 14%;
    width: 46%;
    height: 44%;
    background: radial-gradient(circle, rgba(222, 229, 238, 0.6), transparent 64%);
    filter: blur(24px);
    pointer-events: none;
}

.dashboard-shell > * {
    position: relative;
    z-index: 1;
}

.dashboard-shell .card,
.dashboard-shell .list-row {
    color: var(--ink);
}

.dashboard-shell a {
    color: var(--accent);
}

.dashboard-shell a.button,
.dashboard-shell a.button:visited,
.dashboard-shell a.button:hover,
.dashboard-shell a.button:focus {
    color: #fff;
}

.dashboard-shell a.button-secondary,
.dashboard-shell a.button-secondary:visited,
.dashboard-shell a.button-secondary:hover,
.dashboard-shell a.button-secondary:focus {
    color: var(--accent-strong);
}

.dashboard-shell a.button-danger,
.dashboard-shell a.button-danger:visited,
.dashboard-shell a.button-danger:hover,
.dashboard-shell a.button-danger:focus {
    color: #fff;
}

.dashboard-shell .muted,
.dashboard-shell small,
.dashboard-shell .list-row-meta,
.dashboard-shell .stat-label,
.dashboard-shell .field-help {
    color: var(--muted);
}

.dashboard-banner {
    position: relative;
    overflow: hidden;
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.99) 0%, rgba(251, 252, 254, 0.98) 100%);
    border-color: rgba(228, 235, 242, 0.94);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.84),
        var(--shadow-soft);
}

.dashboard-banner::after {
    content: "";
    position: absolute;
    inset: auto -30px -30px auto;
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(222, 229, 238, 0.7), transparent 68%);
    pointer-events: none;
}

.dashboard-banner-warning {
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.99) 0%, rgba(248, 250, 253, 0.98) 100%);
    border-color: rgba(214, 223, 234, 0.9);
}

.dashboard-banner-danger {
    background:
        linear-gradient(135deg, rgba(255, 249, 249, 0.98) 0%, rgba(252, 241, 242, 0.98) 100%);
    border-color: rgba(164, 60, 69, 0.24);
}

.dashboard-banner-head {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    align-items: flex-start;
}

.dashboard-banner-eyebrow,
.dashboard-kicker {
    margin: 0 0 8px;
    font-size: 0.82rem;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--sub-accent);
}

.dashboard-banner h2,
.dashboard-hero-main h1,
.dashboard-hero-side h2,
.insight-card h2,
.dashboard-list-card h2 {
    color: var(--ink);
    text-shadow: none;
}

.dashboard-banner-stat {
    min-width: 120px;
    text-align: right;
}

.dashboard-banner-stat strong {
    display: block;
    font-size: 2.2rem;
    line-height: 1;
    color: var(--accent-strong);
    text-shadow: none;
}

.banner-tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 16px 0;
}

.banner-tag {
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.98);
    border: 1px solid rgba(228, 235, 242, 0.92);
    font-size: 0.92rem;
    color: var(--accent-strong);
}

.dashboard-hero {
    display: grid;
    grid-template-columns: minmax(0, 1.55fr) minmax(320px, 0.95fr);
    gap: 20px;
}

.dashboard-hero-main {
    min-height: 250px;
    display: grid;
    align-content: space-between;
    background:
        radial-gradient(circle at 70% 12%, rgba(222, 229, 238, 0.5), transparent 26%),
        linear-gradient(145deg, rgba(255, 255, 255, 0.99) 0%, rgba(251, 252, 254, 0.97) 100%);
    border: 1px solid rgba(228, 235, 242, 0.94);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.84),
        0 20px 40px rgba(31, 37, 48, 0.08);
}

.dashboard-hero-main::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, transparent, rgba(214, 223, 234, 0.45), transparent),
        linear-gradient(rgba(29, 81, 72, 0.06), transparent);
    background-size: 100% 2px, 2px 100%;
    background-repeat: no-repeat;
    background-position: top center, right center;
    pointer-events: none;
}

.dashboard-hero-main h1 {
    margin: 0 0 12px;
    font-size: clamp(2rem, 3vw, 3.2rem);
    line-height: 1.08;
}

.dashboard-hero-text {
    max-width: 58ch;
    margin: 0;
    color: var(--muted);
    line-height: 1.8;
}

.dashboard-search-bar {
    align-items: stretch;
}

.dashboard-search-bar .form-control {
    min-height: 54px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.98);
    border-color: rgba(228, 235, 242, 0.94);
    color: var(--ink);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.84);
}

.dashboard-search-bar .button {
    min-width: 110px;
    background: linear-gradient(135deg, #1d5148 0%, #25665a 100%);
    box-shadow: 0 12px 24px rgba(29, 81, 72, 0.18);
}

.dashboard-hero-side {
    background:
        radial-gradient(circle at top left, rgba(29, 81, 72, 0.08), transparent 28%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.99) 0%, rgba(251, 252, 254, 0.97) 100%);
    border-color: rgba(228, 235, 242, 0.92);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.84),
        0 18px 34px rgba(31, 37, 48, 0.08);
}

.dashboard-mini-chart {
    display: grid;
    grid-template-columns: 150px minmax(0, 1fr);
    gap: 20px;
    align-items: center;
    height: 100%;
}

.dashboard-donut {
    width: 146px;
    height: 146px;
    position: relative;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: transparent;
    box-shadow: none;
}

.dashboard-donut svg {
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

.dashboard-donut-track,
.dashboard-donut-value {
    fill: none;
    stroke-width: 10;
}

.dashboard-donut-track {
    stroke: rgba(224, 231, 239, 0.95);
}

.dashboard-donut-value {
    stroke: #1d5148;
    stroke-linecap: round;
}

.dashboard-donut-center {
    width: 106px;
    height: 106px;
    border-radius: 50%;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.99) 0%, rgba(249, 251, 254, 0.98) 100%);
    display: grid;
    place-items: center;
    text-align: center;
    box-shadow:
        inset 0 0 0 1px rgba(228, 235, 242, 0.92),
        0 10px 22px rgba(31, 37, 48, 0.06);
    position: absolute;
    inset: 20px;
}

.dashboard-donut-center strong {
    display: block;
    font-size: 1.85rem;
    line-height: 1;
    color: var(--accent-strong);
}

.dashboard-donut-center span {
    font-size: 0.86rem;
    color: var(--muted);
}

.dashboard-mini-chart-copy h2,
.insight-card h2 {
    margin: 0 0 8px;
    font-size: 1.2rem;
}

.dashboard-inline-stats {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin-top: 16px;
}

.dashboard-inline-stats div,
.dashboard-inline-stat-link {
    padding: 12px 14px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.98);
    border: 1px solid rgba(228, 235, 242, 0.92);
}

.dashboard-inline-stat-link {
    display: block;
    text-decoration: none;
    transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.dashboard-inline-stat-link:hover {
    transform: translateY(-2px);
    border-color: rgba(77, 117, 114, 0.28);
    box-shadow: 0 14px 28px rgba(31, 37, 48, 0.08);
}

.dashboard-inline-stats strong {
    display: block;
    font-size: 1.4rem;
    color: var(--accent-strong);
}

.dashboard-inline-stats span {
    font-size: 0.9rem;
    color: var(--muted);
}

.dashboard-stats-grid {
    grid-template-columns: repeat(6, minmax(0, 1fr));
}

.dashboard-stat-card {
    min-height: 150px;
    display: grid;
    align-content: start;
    gap: 4px;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.99) 0%, rgba(251, 252, 254, 0.97) 100%);
    border-color: rgba(228, 235, 242, 0.94);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.84),
        0 18px 34px rgba(31, 37, 48, 0.08);
}

.dashboard-stat-card small {
    font-size: 0.9rem;
    line-height: 1.6;
}

.dashboard-stat-card strong {
    color: var(--accent-strong);
    text-shadow: none;
}

.dashboard-stat-card-accent {
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.99) 0%, rgba(249, 251, 254, 0.98) 100%);
}

.dashboard-stat-card-split {
    grid-column: span 2;
    display: flex;
    align-items: stretch;
    justify-content: space-between;
    gap: 18px;
    align-items: stretch;
}

.dashboard-stat-card-split__section {
    flex: 1 1 0;
    min-width: 0;
    display: grid;
    align-content: start;
    gap: 4px;
}

.dashboard-stat-card-split__divider {
    flex: 0 0 1px;
    width: 1px;
    background: linear-gradient(180deg, rgba(213, 222, 232, 0.12), rgba(213, 222, 232, 0.92), rgba(213, 222, 232, 0.12));
    margin: 2px 0;
}

.dashboard-insight-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
}

.insight-card {
    display: grid;
    gap: 18px;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.99) 0%, rgba(251, 252, 254, 0.97) 100%);
    border-color: rgba(228, 235, 242, 0.94);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.84),
        0 18px 34px rgba(31, 37, 48, 0.08);
}

.insight-card-head {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    align-items: flex-start;
}

.insight-head-stat {
    font-size: 2.4rem;
    line-height: 1;
    color: var(--accent-strong);
    text-shadow: none;
}

.insight-head-link,
.dashboard-value-link {
    color: inherit;
    text-decoration: none;
}

.insight-head-link:hover,
.dashboard-value-link:hover {
    color: var(--accent);
}

.meter-stack {
    display: grid;
    gap: 16px;
}

.meter-row {
    display: grid;
    gap: 10px;
}

.meter-copy {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    align-items: baseline;
}

.meter-copy span {
    color: var(--muted);
    font-size: 0.92rem;
}

.meter-track {
    height: 12px;
    border-radius: 999px;
    background: rgba(224, 231, 239, 0.92);
    overflow: hidden;
    box-shadow: inset 0 1px 2px rgba(122, 112, 92, 0.08);
}

.meter-progress {
    width: 100%;
    height: 100%;
    display: block;
    border: 0;
    border-radius: inherit;
    overflow: hidden;
    background: transparent;
    appearance: none;
    -webkit-appearance: none;
}

.meter-progress::-webkit-progress-bar {
    background: transparent;
}

.meter-progress::-webkit-progress-value {
    border-radius: inherit;
    background: linear-gradient(90deg, #1d5148 0%, #3f8173 100%);
    box-shadow: 0 8px 20px rgba(29, 81, 72, 0.18);
}

.meter-progress::-moz-progress-bar {
    border-radius: inherit;
    background: linear-gradient(90deg, #1d5148 0%, #3f8173 100%);
    box-shadow: 0 8px 20px rgba(29, 81, 72, 0.18);
}

.meter-progress-pending::-webkit-progress-value {
    background: linear-gradient(90deg, #7391a6 0%, #9fb6c5 100%);
}

.meter-progress-pending::-moz-progress-bar {
    background: linear-gradient(90deg, #7391a6 0%, #9fb6c5 100%);
}

.meter-progress-available::-webkit-progress-value {
    background: linear-gradient(90deg, #4a8797 0%, #7db6c4 100%);
}

.meter-progress-available::-moz-progress-bar {
    background: linear-gradient(90deg, #4a8797 0%, #7db6c4 100%);
}

.dashboard-risk-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.risk-card {
    padding: 16px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.98);
    border: 1px solid rgba(228, 235, 242, 0.92);
}

.risk-card-link {
    text-decoration: none;
    transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.risk-card-link:hover {
    transform: translateY(-2px);
    border-color: rgba(77, 117, 114, 0.28);
    box-shadow: 0 14px 28px rgba(31, 37, 48, 0.08);
}

.risk-card span,
.risk-card small {
    display: block;
}

.risk-card strong {
    display: block;
    margin: 8px 0 6px;
    font-size: 2rem;
    color: var(--accent-strong);
}

.risk-card small {
    color: var(--muted);
}

.risk-card-accent {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.99) 0%, rgba(249, 251, 254, 0.98) 100%);
}

.dashboard-inline-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
}

.dashboard-inline-link::after {
    content: "→";
}

.dashboard-main-grid {
    align-items: start;
}

.dashboard-list-card .section-head {
    align-items: flex-start;
}

.dashboard-list-card .section-head p {
    margin: 6px 0 0;
}

.dashboard-list-card {
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.99) 0%, rgba(251, 252, 254, 0.97) 100%);
    border-color: rgba(228, 235, 242, 0.94);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.84),
        0 18px 34px rgba(31, 37, 48, 0.08);
}

.dashboard-shell .dashboard-list-card,
.dashboard-shell .dashboard-main-grid .dashboard-list-card {
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.99) 0%, rgba(251, 252, 254, 0.97) 100%) !important;
    border-color: rgba(228, 235, 242, 0.94) !important;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.84),
        0 18px 34px rgba(31, 37, 48, 0.08) !important;
}

.dashboard-list-card .muted,
.dashboard-list-card p,
.dashboard-list-card small {
    color: var(--muted);
}

.dashboard-list-card h2,
.dashboard-list-card .section-head a {
    color: var(--ink) !important;
    text-shadow: none;
}

.dashboard-list-card .section-head a {
    font-weight: 700;
}

.dashboard-list-row {
    background: linear-gradient(180deg, rgba(255, 255, 255, 1) 0%, rgba(251, 252, 254, 0.98) 100%);
    border-color: rgba(228, 235, 242, 0.92);
}

.dashboard-list-row:hover {
    background: linear-gradient(180deg, rgba(255, 255, 255, 1) 0%, rgba(237, 245, 241, 0.96) 100%);
    box-shadow: 0 14px 30px rgba(31, 37, 48, 0.08);
}

@media (max-width: 920px) {
    .site-header {
        grid-template-columns: 1fr;
        align-items: stretch;
    }

    .header-actions,
    .top-nav {
        align-items: stretch;
        justify-items: stretch;
    }

    .panel-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-hero,
    .dashboard-insight-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-stats-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .dashboard-stat-card-split {
        grid-column: 1 / -1;
    }
}

@media (max-width: 720px) {
    .layout-shell {
        padding: 16px;
    }

    .section-head,
    .button-row,
    .search-bar,
    .photo-row,
    .top-nav {
        flex-direction: column;
        align-items: stretch;
    }

    .nav-menu,
    .nav-dropdown {
        width: 100%;
    }

    .nav-dropdown {
        position: static;
        margin-top: 8px;
        min-width: 100%;
    }

    .detail-grid {
        grid-template-columns: 1fr;
    }

    .title-row,
    .meta-row,
    .list-row {
        flex-direction: column;
        align-items: stretch;
    }

    .list-row-side {
        justify-items: start;
        text-align: left;
    }

    .contract-document-row {
        align-items: flex-start;
    }

    .contract-document-actions.inline-form {
        align-self: flex-end;
    }

    .dashboard-mini-chart,
    .dashboard-risk-grid,
    .dashboard-inline-stats,
    .dashboard-stats-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-stat-card-split {
        grid-column: auto;
        display: grid;
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .dashboard-stat-card-split__divider {
        width: auto;
        height: 1px;
        margin: 0;
    }

    .dashboard-banner-head,
    .insight-card-head,
    .meter-copy {
        flex-direction: column;
        align-items: flex-start;
    }
}

.license-center-shell .dashboard-hero-main {
    min-height: 220px;
}

.license-center-hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
    justify-content: flex-start;
}

.button-row-wrap {
    flex-wrap: wrap;
    justify-content: flex-start;
}

.license-center-hero-actions .button {
    flex: 0 0 auto;
}

.license-center-summary {
    display: grid;
    gap: 14px;
    align-content: center;
    min-height: 100%;
}

.license-center-node-panel {
    display: grid;
    gap: 14px;
    margin-top: 20px;
}

.license-center-node-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.license-center-node-grid .data-card {
    min-height: 108px;
}

.license-center-page .top-nav a,
.license-center-page .top-nav .button-secondary {
    white-space: nowrap;
}

.inline-filter-form {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
}

.inline-filter-form .form-control {
    min-width: 220px;
    flex: 1 1 260px;
}

.inline-filter-form .form-select {
    min-width: 220px;
    flex: 0 1 260px;
}

.license-log-row {
    align-items: flex-start;
}

.log-details {
    margin-top: 10px;
}

.log-details summary {
    color: var(--accent-strong);
    cursor: pointer;
    font-size: 0.95rem;
}

.log-details pre {
    margin: 10px 0 0;
    padding: 14px 16px;
    border-radius: 18px;
    background: rgba(238, 245, 244, 0.95);
    color: var(--text-secondary);
    white-space: pre-wrap;
    word-break: break-word;
    font-size: 0.9rem;
    line-height: 1.55;
}

@media (max-width: 720px) {
    .license-center-hero-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .license-center-node-grid {
        grid-template-columns: 1fr;
    }
}

.landlord-trend-card {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.landlord-chart-layout {
    display: grid;
    grid-template-columns: minmax(220px, 260px) minmax(0, 1fr);
    gap: 18px;
    align-items: stretch;
}

.landlord-chart-layout-full {
    grid-template-columns: minmax(220px, 260px) minmax(0, 1fr);
}

.landlord-month-summary,
.landlord-chart-panel {
    border-radius: 20px;
    border: 1px solid rgba(23, 78, 109, 0.08);
    box-shadow: 0 12px 28px rgba(16, 44, 66, 0.06);
}

.landlord-month-summary {
    background: linear-gradient(180deg, rgba(252, 253, 254, 0.98), rgba(244, 248, 251, 0.96));
    padding: 24px 20px;
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.landlord-month-summary__month {
    margin: 0;
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--text-primary);
}

.landlord-month-summary__metrics {
    display: grid;
    gap: 14px;
}

.landlord-month-summary__metrics div {
    padding-top: 12px;
    border-top: 1px solid rgba(18, 52, 75, 0.08);
}

.landlord-month-summary__metrics span {
    display: block;
    color: var(--text-muted);
    font-size: 0.88rem;
    margin-bottom: 6px;
}

.landlord-month-summary__metrics strong {
    font-size: 1.2rem;
    color: var(--text-primary);
}

.landlord-chart-panel {
    padding: 18px 20px 14px;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(248, 251, 253, 0.96));
    border-color: rgba(23, 78, 109, 0.08);
    box-shadow: 0 14px 32px rgba(16, 44, 66, 0.06);
}

.landlord-chart-svg {
    width: 100%;
    height: 280px;
    display: block;
}

.landlord-chart-grid-line {
    stroke: rgba(103, 142, 168, 0.18);
    stroke-width: 1;
    stroke-dasharray: 3 5;
}

.landlord-chart-zero-line {
    stroke: rgba(34, 72, 96, 0.26);
    stroke-width: 1.2;
}

.landlord-chart-axis-label {
    fill: rgba(76, 110, 133, 0.88);
    font-size: 9px;
    font-weight: 700;
    dominant-baseline: middle;
}

.landlord-chart-bar {
    rx: 9;
    filter: drop-shadow(0 6px 12px rgba(16, 44, 66, 0.08));
}

.landlord-chart-bar-income {
    fill: rgba(226, 80, 87, 0.92);
}

.landlord-chart-bar-expense {
    fill: rgba(67, 181, 129, 0.92);
}

.landlord-chart-line {
    fill: none;
    stroke: rgba(32, 111, 98, 0.98);
    stroke-width: 3;
    stroke-linecap: round;
    stroke-linejoin: round;
    filter: drop-shadow(0 4px 8px rgba(32, 111, 98, 0.16));
}

.landlord-chart-line-marker {
    fill: #ffffff;
    stroke: rgba(32, 111, 98, 0.96);
    stroke-width: 2.2;
    filter: drop-shadow(0 4px 8px rgba(32, 111, 98, 0.18));
}

.landlord-trend-svg {
    width: 100%;
    height: 180px;
    border-radius: 18px;
    background: linear-gradient(180deg, rgba(228, 239, 244, 0.7), rgba(244, 248, 250, 0.95));
    border: 1px solid rgba(18, 52, 75, 0.08);
    padding: 8px;
}

.landlord-trend-line {
    fill: none;
    stroke-width: 3.5;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.landlord-trend-line-expected {
    stroke: rgba(118, 145, 161, 0.95);
}

.landlord-trend-line-gross {
    stroke: rgba(40, 126, 191, 0.96);
}

.landlord-trend-line-expense {
    stroke: rgba(191, 98, 57, 0.96);
}

.landlord-trend-line-received {
    stroke: rgba(32, 111, 98, 0.98);
}

.landlord-trend-legend,
.landlord-trend-months {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    color: var(--text-muted);
    font-size: 0.86rem;
}

.landlord-trend-months {
    justify-content: space-between;
    gap: 8px;
    margin-top: 6px;
}

.landlord-trend-dot {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 999px;
    margin-right: 8px;
}

.landlord-trend-dot-expected {
    background: rgba(118, 145, 161, 0.95);
}

.landlord-trend-dot-gross {
    background: rgba(226, 80, 87, 0.96);
}

.landlord-trend-dot-expense {
    background: rgba(67, 181, 129, 0.96);
}

.landlord-trend-dot-received {
    background: rgba(32, 111, 98, 0.98);
}

.report-meta {
    display: flex;
    gap: 10px 16px;
    align-items: center;
    flex-wrap: wrap;
    margin-top: 18px;
    color: var(--text-muted);
    font-size: 0.92rem;
}

.report-chip-bar {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.report-toolbar {
    display: flex;
    gap: 12px;
    justify-content: space-between;
    align-items: flex-end;
    flex-wrap: wrap;
    padding: 16px 18px;
    border-radius: 18px;
    background: linear-gradient(180deg, rgba(249, 251, 253, 0.98), rgba(242, 247, 251, 0.96));
    border: 1px solid rgba(38, 83, 115, 0.08);
}

.report-toolbar__primary {
    display: flex;
    gap: 12px;
    align-items: flex-end;
    flex-wrap: wrap;
}

.report-toolbar__field {
    display: grid;
    gap: 6px;
    min-width: 220px;
}

.report-toolbar__field span {
    color: var(--text-muted);
    font-size: 0.84rem;
    font-weight: 700;
}

.report-toolbar__field select {
    min-width: 220px;
}

.report-toolbar__submit {
    min-height: 44px;
}

.report-toolbar__meta {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    color: var(--text-muted);
    font-size: 0.88rem;
}

.report-toolbar__meta span {
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.94);
    border: 1px solid rgba(38, 83, 115, 0.08);
}

.report-filter-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(242, 247, 251, 0.98);
    border: 1px solid rgba(41, 92, 128, 0.12);
    color: var(--text-primary);
    font-size: 0.86rem;
}

.report-filter-chip strong {
    color: var(--text-muted);
    font-weight: 700;
}

.report-filter-chip em {
    font-style: normal;
    font-weight: 700;
}

.landlord-mapping-toolbar {
    display: grid;
    gap: 16px;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    margin-top: 6px;
}

.landlord-mapping-toolbar__block {
    display: grid;
    gap: 8px;
    padding: 14px 16px;
    border-radius: 18px;
    border: 1px solid rgba(38, 83, 115, 0.08);
    background: linear-gradient(180deg, rgba(249, 251, 253, 0.98), rgba(242, 247, 251, 0.96));
}

.landlord-mapping-toolbar__block label {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--text-primary);
}

.landlord-mapping-toolbar__row {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
}

.landlord-mapping-toolbar__row .form-control,
.landlord-mapping-toolbar__row .form-select {
    flex: 1 1 220px;
}

.landlord-mapping-preview {
    display: grid;
    gap: 14px;
    padding: 16px 18px;
    border-radius: 18px;
    border: 1px solid rgba(38, 83, 115, 0.08);
    background: rgba(250, 252, 254, 0.96);
}

.landlord-mapping-preview h3 {
    margin: 0;
    font-size: 1rem;
}

.landlord-mapping-pill-grid {
    display: grid;
    gap: 10px;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
}

.landlord-mapping-pill {
    display: grid;
    gap: 4px;
    padding: 12px 14px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid rgba(38, 83, 115, 0.08);
}

.landlord-mapping-pill strong {
    color: var(--text-muted);
    font-size: 0.82rem;
}

.landlord-mapping-pill span {
    color: var(--text-primary);
    font-weight: 700;
    word-break: break-word;
}

.landlord-preview-stack {
    display: grid;
    gap: 16px;
}

.landlord-preview-table-wrap {
    overflow-x: auto;
    border-radius: 14px;
    border: 1px solid rgba(38, 83, 115, 0.08);
    background: rgba(255, 255, 255, 0.98);
}

.landlord-preview-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.landlord-preview-table th,
.landlord-preview-table td {
    padding: 10px 12px;
    border-bottom: 1px solid rgba(38, 83, 115, 0.08);
    text-align: left;
    vertical-align: top;
    white-space: nowrap;
}

.landlord-summary-filter {
    display: grid;
    gap: 8px;
    min-width: 180px;
}

.landlord-summary-filter label {
    font-size: 0.86rem;
    font-weight: 700;
    color: var(--text-muted);
}

.landlord-preview-table th {
    background: rgba(243, 247, 251, 0.95);
    color: var(--text-muted);
    font-weight: 700;
}

.landlord-preview-table tr:last-child td {
    border-bottom: none;
}

.report-overview {
    display: grid;
    gap: 18px;
    margin-top: 18px;
}

.report-summary-band {
    display: grid;
    grid-template-columns: minmax(240px, 320px) minmax(0, 1fr);
    gap: 18px;
    padding: 20px 22px;
    border-radius: 20px;
    background: linear-gradient(180deg, rgba(253, 254, 255, 0.98), rgba(244, 249, 252, 0.96));
    border: 1px solid rgba(18, 52, 75, 0.08);
    box-shadow: 0 14px 28px rgba(14, 40, 60, 0.06);
}

.report-summary-primary {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.report-summary-period {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.88rem;
}

.report-summary-primary strong {
    font-size: 2.3rem;
    color: var(--text-primary);
    letter-spacing: -0.03em;
}

.report-summary-primary span {
    color: var(--text-muted);
}

.report-summary-metrics {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 14px;
}

.report-summary-metric {
    padding: 14px 16px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid rgba(18, 52, 75, 0.07);
    display: grid;
    gap: 4px;
}

.report-summary-metric span,
.report-summary-metric small {
    color: var(--text-muted);
    font-size: 0.86rem;
}

.report-summary-metric strong {
    color: var(--text-primary);
    font-size: 1.12rem;
}

.report-summary-metric--up strong {
    color: #14956d;
}

.report-summary-metric--down strong {
    color: #ff5c7a;
}

.billing-annual-panel {
    padding: 18px 20px;
    border-radius: 20px;
    background: linear-gradient(180deg, rgba(252, 253, 255, 0.98), rgba(245, 249, 252, 0.96));
    border: 1px solid rgba(18, 52, 75, 0.08);
    box-shadow: 0 14px 28px rgba(14, 40, 60, 0.06);
}

.billing-annual-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 12px;
}

.billing-annual-head strong {
    display: block;
    font-size: 1rem;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.billing-annual-head small {
    color: var(--text-muted);
    display: block;
    max-width: 720px;
}

.billing-annual-meta {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.billing-annual-meta span {
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid rgba(18, 52, 75, 0.08);
    color: var(--text-muted);
    font-size: 0.82rem;
    font-weight: 700;
}

.landlord-chart-panel-report {
    margin-top: 4px;
}

.report-chart-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 14px;
    margin-bottom: 12px;
}

.report-chart-head strong {
    display: block;
    color: rgba(242, 247, 249, 0.98);
    font-size: 1rem;
    margin-bottom: 4px;
}

.report-chart-head small {
    color: rgba(205, 222, 230, 0.72);
}

.report-chart-svg {
    width: 100%;
    height: 300px;
    display: block;
}

.report-chart-grid-line {
    stroke: rgba(210, 229, 239, 0.14);
    stroke-width: 1;
    stroke-dasharray: 4 6;
}

.report-chart-axis-label {
    fill: rgba(224, 239, 245, 0.76);
    font-size: 10px;
    font-weight: 700;
    dominant-baseline: middle;
}

.report-chart-segment {
    rx: 8;
    filter: drop-shadow(0 10px 16px rgba(0, 0, 0, 0.12));
}

.report-chart-labels,
.report-chart-legend {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    color: rgba(226, 239, 245, 0.78);
    font-size: 0.88rem;
}

.report-chart-labels {
    justify-content: space-between;
    margin-top: 10px;
    gap: 8px;
}

.report-chart-labels span {
    max-width: 92px;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.report-chart-legend {
    margin-top: 12px;
}

.report-chart-legend i {
    width: 10px;
    height: 10px;
    border-radius: 999px;
    display: inline-block;
    margin-right: 8px;
}

.report-table-shell {
    margin-top: 16px;
    overflow-x: auto;
    border-radius: 18px;
    border: 1px solid rgba(18, 52, 75, 0.08);
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 12px 24px rgba(14, 40, 60, 0.05);
}

.report-table {
    width: 100%;
    min-width: 760px;
    border-collapse: collapse;
}

.report-table thead th {
    background: rgba(242, 247, 251, 0.98);
    color: var(--text-primary);
    font-weight: 700;
    font-size: 0.88rem;
    padding: 12px 14px;
    text-align: left;
    border-bottom: 1px solid rgba(93, 138, 170, 0.12);
}

.report-table tbody th,
.report-table tbody td {
    padding: 12px 14px;
    border-bottom: 1px solid rgba(103, 141, 170, 0.1);
    font-size: 0.9rem;
    white-space: nowrap;
    color: var(--text-primary);
}

.report-table tbody th {
    font-weight: 700;
    background: rgba(249, 251, 253, 0.98);
}

.report-table tbody tr:last-child th,
.report-table tbody tr:last-child td {
    border-bottom: none;
}

.report-table tbody tr:nth-child(even) th,
.report-table tbody tr:nth-child(even) td {
    background: rgba(248, 250, 252, 0.96);
}

.report-table tbody tr:hover th,
.report-table tbody tr:hover td {
    background: rgba(238, 245, 249, 0.98);
}

.report-status-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 5px 10px;
    border-radius: 999px;
    background: rgba(49, 113, 160, 0.1);
    border: 1px solid rgba(120, 173, 214, 0.18);
    color: var(--text-primary);
    font-size: 0.82rem;
    font-weight: 700;
}

@media (max-width: 980px) {
    .landlord-chart-layout,
    .landlord-chart-layout-full,
    .report-summary-band {
        grid-template-columns: 1fr;
    }

    .report-toolbar {
        align-items: stretch;
    }

    .report-toolbar__primary,
    .report-toolbar__meta {
        width: 100%;
    }
}

.button-row.button-row-left {
    justify-content: flex-start !important;
}

.button-row-left {
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
    justify-content: flex-start !important;
}

.security-ops-hero {
    display: grid;
    gap: 20px;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    margin-bottom: 28px;
}

.security-ops-grid {
    display: grid;
    gap: 24px;
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
}

.security-ops-grid .card {
    min-height: 100%;
}

.map-shell {
    position: relative;
    width: 100%;
    height: 70vh;
    min-height: 520px;
    max-height: 820px;
    border-radius: 24px;
    background: radial-gradient(circle at 30% 30%, rgba(28, 68, 102, 0.35), rgba(5, 10, 20, 0.98));
    overflow: hidden;
}

.map-shell .geo-map {
    width: 100%;
    height: 100%;
}

.map-empty {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.95rem;
    color: var(--muted);
    background: rgba(255, 255, 255, 0.6);
}

.map-empty.hidden {
    display: none;
}

.globe-shell {
    position: relative;
    width: 100%;
    height: clamp(460px, 62vh, 860px);
    border-radius: 22px;
    overflow: hidden;
    background: #0a1117;
}

.globe-shell canvas,
.globe-shell .globe-map,
.globe-shell .globe-webgl {
    width: 100%;
    height: 100%;
    display: block;
    cursor: grab;
}

.globe-empty {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.95rem;
    color: var(--muted);
    background: rgba(10, 17, 23, 0.6);
}

.globe-empty.hidden {
    display: none;
}

.map-point {
    filter: drop-shadow(0 0 8px rgba(120, 200, 255, 0.9));
}

.map-point--hot {
    filter: drop-shadow(0 0 10px rgba(255, 120, 120, 0.95));
}

.pagination-row {
    display: flex;
    gap: 12px;
    align-items: center;
    justify-content: flex-end;
    margin-top: 12px;
}

.security-log-row {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    padding: 6px 10px;
    border-radius: 12px;
    border: 1px solid var(--line);
    background: var(--paper);
}

.filter-row {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: flex-end;
    margin-bottom: 10px;
}

.filter-row .field-row {
    min-width: 160px;
}

.button.button-ghost {
    background: transparent;
    border: 1px solid var(--line);
    color: var(--ink);
}

.selection-grid {
    display: grid;
    gap: 10px;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.selection-card {
    display: flex;
    gap: 10px;
    align-items: center;
    padding: 12px 14px;
    border-radius: 16px;
    border: 1px solid rgba(28, 61, 88, 0.08);
    background: linear-gradient(180deg, rgba(249, 252, 253, 0.98), rgba(241, 247, 249, 0.98));
    transition: transform .16s ease, box-shadow .16s ease, border-color .16s ease, background .16s ease;
}

.selection-card input {
    margin: 0;
    accent-color: var(--accent);
}

.selection-card strong {
    display: block;
}

.selection-card small {
    display: block;
    color: var(--text-muted);
    font-size: 0.8rem;
    margin-top: 2px;
}

.selection-card:hover {
    transform: translateY(-1px);
    border-color: rgba(34, 118, 116, 0.18);
    box-shadow: 0 10px 20px rgba(12, 34, 50, 0.06);
}

.selection-card:has(input:checked) {
    background: linear-gradient(180deg, rgba(231, 247, 243, 0.98), rgba(218, 240, 236, 0.98));
    border-color: rgba(34, 118, 116, 0.24);
    box-shadow: 0 12px 24px rgba(17, 91, 84, 0.08);
}

.grouped-nav {
    gap: 10px;
}

.nav-link {
    display: inline-flex;
    align-items: center;
    padding: 8px 14px;
    border-radius: 999px;
    border: 1px solid var(--line);
    color: var(--ink);
    text-decoration: none;
    background: rgba(255, 255, 255, 0.9);
    font-weight: 600;
    font-size: 0.95rem;
}

.nav-group {
    position: relative;
}

.nav-group-button {
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.9);
    color: var(--ink);
    border-radius: 999px;
    padding: 8px 14px;
    font-weight: 600;
    cursor: pointer;
    font-size: 0.95rem;
}

.nav-group-menu {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    min-width: 180px;
    background: var(--paper-strong);
    border: 1px solid var(--line);
    border-radius: 16px;
    box-shadow: var(--shadow-soft);
    padding: 8px;
    display: none;
    z-index: 10;
}

.nav-group-menu a {
    display: block;
    padding: 8px 10px;
    border-radius: 12px;
    color: var(--ink);
    text-decoration: none;
}

.nav-group-menu a:hover {
    background: var(--accent-soft);
    color: var(--accent-strong);
}

.nav-group:hover .nav-group-menu,
.nav-group:focus-within .nav-group-menu {
    display: block;
}

.security-log-row + .security-log-row {
    margin-top: 8px;
}

.security-log-meta {
    color: var(--muted);
    font-size: 0.8rem;
    line-height: 1.25;
}

@media (max-width: 1024px) {
    .security-ops-grid {
        grid-template-columns: 1fr;
    }
}
