:root {
    --color-primary: #2d6a4f;
    --color-primary-dark: #1b4332;
    --color-primary-soft: #d8f3dc;
    --color-bg: #f8faf9;
    --color-surface: #ffffff;
    --color-text: #1a1a1a;
    --color-muted: #5c6670;
    --color-border: #d8e2dc;
    --color-error-bg: #fdecea;
    --color-error-text: #8a1c1c;
    --header-height: 76px;
    --layout-width: 90%;
    --radius: 12px;
    --shadow: 0 8px 24px rgba(27, 67, 50, 0.08);
    --font-sans: "Segoe UI", system-ui, sans-serif;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: var(--font-sans);
    background: var(--color-bg);
    color: var(--color-text);
    line-height: 1.5;
    min-height: 100vh;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: var(--color-surface);
    border-bottom: 1px solid var(--color-border);
    box-shadow: var(--shadow);
}

.preview-banner {
    position: sticky;
    top: 0;
    z-index: 101;
    background: #fff8e6;
    border-bottom: 1px solid #e6c200;
    color: #5c4a00;
}

.localhost-banner {
    position: sticky;
    top: 0;
    z-index: 102;
    background: #ffe8e8;
    border-bottom: 1px solid #d9534f;
    color: #7a1f1f;
    text-align: center;
    padding: 0.5rem 1rem;
    font-weight: 600;
    letter-spacing: 0.02em;
}

body.localhost-env .mail-activity .field-hint.mail-localhost-hint {
    margin-bottom: 1rem;
    padding: 0.65rem 0.85rem;
    border-radius: 6px;
    background: #f3f8f3;
    border: 1px solid #c5d9c5;
    color: #2d4a2d;
}

.preview-banner-inner {
    width: var(--layout-width);
    max-width: var(--layout-width);
    margin: 0 auto;
    padding: 0.5rem 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}

.preview-exit-form {
    margin: 0;
}

.site-header-inner {
    width: var(--layout-width);
    max-width: var(--layout-width);
    margin: 0 auto;
    padding: 0.75rem 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
}

.site-header-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    min-width: 0;
}

.brand {
    display: flex;
    align-items: center;
    gap: 1rem;
    text-decoration: none;
    color: inherit;
    min-width: 0;
}

.brand-logo {
    height: 41px;
    width: auto;
    max-width: 220px;
    object-fit: contain;
    flex-shrink: 0;
}

.brand-text {
    display: none;
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--color-primary-dark);
    white-space: nowrap;
}

.header-user {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.header-user-email {
    color: var(--color-muted);
    font-size: 0.95rem;
}

.page-content {
    padding: 1.5rem 0 3rem;
}

.app-shell,
.container,
.container-narrow {
    width: var(--layout-width);
    max-width: var(--layout-width);
    margin-left: auto;
    margin-right: auto;
}

.container-narrow {
    max-width: var(--layout-width);
}

.page-intro h1,
.card h1 {
    margin: 0 0 0.25rem;
    color: var(--color-primary-dark);
}

.subtitle {
    margin: 0 0 1rem;
    color: var(--color-muted);
}

.card,
.alert {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 1.25rem 1.5rem;
}

.page-content .card,
.page-content .alert {
    margin-top: 1.5rem;
}

.container-narrow > .card:first-child,
.container > .card:first-child,
.container > .page-intro + .stats-grid {
    margin-top: 0;
}

.card h2,
.alert h2,
.alert h1 {
    margin-top: 0;
    font-size: 1.1rem;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr));
    gap: 1rem;
    margin-top: 1.5rem;
    align-items: stretch;
}

.stat-card {
    margin-top: 0;
    display: flex;
    flex-direction: column;
    height: 100%;
    gap: 0.5rem;
}

a.stat-card-link {
    text-decoration: none;
    color: inherit;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

a.stat-card-link:hover,
a.stat-card-link:focus-visible {
    border-color: var(--color-primary, #2d6a4f);
    box-shadow: 0 0 0 2px rgba(45, 106, 79, 0.12);
}

.stat-card-warning {
    border-color: #e6c200;
    background: #fffdf5;
}

.stat-card-warning .stat-value {
    color: #7a5d00;
}

.planner-filter-form {
    margin-bottom: 0.75rem;
}

.planner-row-overdue {
    background: #fff9f9;
}

.species-summary-ratio {
    text-align: right;
    white-space: nowrap;
}

.species-ratio-value {
    font-variant-numeric: tabular-nums;
    font-weight: 600;
    color: var(--color-primary-dark);
}

.species-summary-total th,
.species-summary-total td {
    border-top: 2px solid var(--color-border);
    background: #f8faf9;
}

.stat-label {
    color: var(--color-muted);
    font-size: 0.875rem;
    line-height: 1.35;
}

.stat-value {
    font-size: 1.75rem;
    color: var(--color-primary-dark);
    line-height: 1.1;
    margin-top: auto;
}

.stats-grid-groundcare {
    grid-template-columns: repeat(auto-fit, minmax(9.5rem, 1fr));
}

@media (min-width: 900px) {
    .stats-grid-groundcare {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (min-width: 1200px) {
    .stats-grid-groundcare {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

@media (min-width: 1400px) {
    .stats-grid-groundcare {
        grid-template-columns: repeat(7, minmax(0, 1fr));
    }
}

.form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

/**
 * Kompakte Formulare (Stammdaten / kurze Eingaben):
 * kleinere Abstände, Labels und Inputs; begrenzte Gesamtbreite.
 */
.form--compact {
    gap: 0.65rem;
    max-width: 40rem;
}

.form--compact.form {
    max-width: 48rem;
}

.form--compact .form-group {
    gap: 0.2rem;
}

.form--compact .form-group label {
    font-size: 0.82rem;
    font-weight: 600;
}

.form--compact .form-group input:not([type="checkbox"]):not([type="radio"]):not([type="file"]),
.form--compact .form-group select,
.form--compact .form-group textarea,
.form--compact .form-group .input {
    padding: 0.4rem 0.55rem;
    font-size: 0.875rem;
    border-radius: 8px;
}

.form--compact .form-group textarea {
    min-height: 4rem;
}

.form--compact .form-grid,
.form--compact .form-grid-2,
.form--compact .form-grid-3,
.form--compact .form-row {
    gap: 0.65rem;
}

.form--compact .hint {
    margin: 0;
    font-size: 0.78rem;
}

.form--compact .form-actions {
    margin-top: 0.15rem;
    gap: 0.45rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.form-group label {
    font-weight: 600;
    font-size: 0.95rem;
}

.form-group input {
    padding: 0.65rem 0.75rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    font: inherit;
    background: #fff;
}

.form-group input:focus {
    outline: 2px solid rgba(45, 106, 79, 0.25);
    border-color: var(--color-primary);
}

.form-group textarea {
    padding: 0.65rem 0.75rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    font: inherit;
    background: #fff;
    resize: vertical;
    min-height: 6rem;
}

.form-group textarea:focus {
    outline: 2px solid rgba(45, 106, 79, 0.25);
    border-color: var(--color-primary);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 1rem;
}

.company-settings-logo-preview {
    margin: 0 0 1rem;
    padding: 1rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    background: #fff;
}

.company-settings-logo-image {
    display: block;
    max-width: 220px;
    max-height: 72px;
    width: auto;
    height: auto;
}

.snippet-editor-list {
    display: grid;
    gap: 1rem;
    margin-bottom: 1.25rem;
}

.snippet-editor-row {
    display: grid;
    gap: 0.35rem;
}

.snippet-editor-controls {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 0.5rem;
    align-items: start;
}

.snippet-editor-input {
    width: 100%;
    min-height: 4.5rem;
    resize: vertical;
}

.snippet-reset-form {
    margin-top: 1rem;
}

.snippet-defaults-details {
    margin-top: 1.25rem;
}

.snippet-defaults-list {
    margin: 0.75rem 0 0;
    padding-left: 1.25rem;
}

.filter-form {
    margin: 0;
}

.filter-form .form-group {
    margin: 0;
}

.map-section {
    margin-top: 0.5rem;
}

.map-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.map-status {
    color: var(--color-muted);
    font-size: 0.9rem;
    line-height: 1.4;
    flex: 1 1 12rem;
}

.map-status-error {
    color: var(--color-error-text);
    font-weight: 600;
}

.map-stats {
    color: var(--color-text);
    font-size: 0.95rem;
    font-weight: 600;
    margin: 0;
}

.map-container-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    min-height: 280px;
    margin: 0;
    padding: 1rem;
    text-align: center;
    color: var(--color-muted);
    background: var(--color-bg);
    font-size: 0.95rem;
    line-height: 1.45;
}

.map-container.map-load-error .map-container-placeholder {
    color: var(--color-error-text);
    font-weight: 600;
}

.map-container {
    width: 100%;
    height: 320px;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    overflow: hidden;
    touch-action: manipulation;
}

.map-container-overview {
    height: min(55vh, 520px);
}

.map-container-boundary {
    height: min(50vh, 480px);
}

.property-boundary-section .map-toolbar {
    flex-wrap: wrap;
    gap: 0.5rem 1rem;
}

.container-property-areas {
    width: 90vw;
    max-width: 1400px;
    margin-left: auto;
    margin-right: auto;
}

.card-property-areas-map {
    padding: 1rem 1.1rem;
}

.property-areas-section {
    margin-bottom: 0;
    font-size: 0.8125rem;
}

.property-areas-section > .hint:first-child {
    margin-bottom: 0.55rem;
    font-size: 0.76rem;
}

.property-areas-top-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.35rem 0.55rem;
    margin-bottom: 0.55rem;
}

.property-areas-top-bar .area-type-quickselect {
    flex: 1 1 auto;
    margin: 0;
    min-width: min(100%, 12rem);
}

.property-areas-map-shell {
    position: relative;
}

/* Keep Leaflet +/- free: stack type + action chrome to the right of zoom. */
.property-areas-map-chrome-top {
    position: absolute;
    top: 0.5rem;
    left: 3.4rem;
    right: 0.5rem;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.4rem;
    max-width: calc(100% - 3.9rem);
    pointer-events: none;
}

.property-areas-map-chrome-types {
    position: static;
    max-width: 100%;
    pointer-events: auto;
}

.property-areas-map-chrome-types .property-areas-top-bar {
    margin: 0;
    display: inline-flex;
    max-width: 100%;
    padding: 0.3rem 0.35rem;
    border: 1px solid rgba(15, 23, 42, 0.12);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: 0 2px 10px rgba(15, 23, 42, 0.12);
}

.property-areas-map-chrome-types .area-type-quickselect {
    margin: 0;
}

.property-areas-map-overlay {
    position: static;
    z-index: auto;
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.28rem;
    max-width: 100%;
    margin: 0;
    padding: 0.35rem 0.4rem;
    border: 1px solid rgba(15, 23, 42, 0.12);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: 0 2px 10px rgba(15, 23, 42, 0.12);
    pointer-events: auto;
}

.property-areas-map-overlay .btn-sm {
    font-size: 0.68rem;
    padding: 0.22rem 0.48rem;
    line-height: 1.25;
    white-space: nowrap;
}

.area-type-quickselect {
    display: flex;
    flex-wrap: wrap;
    gap: 0.28rem;
    margin: 0 0 0.55rem;
}

.area-type-quickselect-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.28rem;
    padding: 0.18rem 0.42rem;
    border: 1px solid var(--color-border);
    border-radius: 4px;
    background: #fff;
    color: var(--color-text);
    font: inherit;
    font-size: 0.66rem;
    line-height: 1.2;
    cursor: pointer;
    transition: border-color 0.15s ease, background-color 0.15s ease;
}

.area-type-quickselect-btn:hover {
    border-color: var(--color-primary);
}

.area-type-quickselect-btn.is-active {
    border-color: var(--color-primary);
    background: var(--color-primary-soft);
}

.area-type-quickselect-swatch {
    width: 0.48rem;
    height: 0.48rem;
    border-radius: 999px;
    flex-shrink: 0;
    border: 1px solid rgb(0 0 0 / 0.12);
}

.area-type-quickselect-label {
    white-space: nowrap;
}

.area-type-quickselect-group {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 0.35rem 0.55rem;
    width: 100%;
    padding: 0.28rem 0.35rem;
    border: 1px dashed var(--color-border);
    border-radius: 6px;
    background: var(--color-surface-muted, #f8fafc);
}

.area-type-quickselect-group-label {
    flex: 0 0 100%;
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: var(--color-text-muted, #64748b);
}

.area-type-quickselect-group-items {
    display: flex;
    flex-wrap: wrap;
    gap: 0.28rem;
    align-items: flex-start;
}

.area-type-quickselect-subgroup {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.22rem 0.35rem;
    padding: 0.12rem 0.28rem;
    border-radius: 4px;
    background: #fff;
    border: 1px solid var(--color-border);
}

.area-type-quickselect-subgroup-label {
    font-size: 0.68rem;
    font-weight: 600;
    color: var(--color-text-muted, #64748b);
}

.area-type-quickselect-subgroup-items {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 0.22rem;
}

.area-setting-fieldset {
    margin: 0;
    padding: 0;
    border: 0;
}

.area-setting-fieldset legend {
    margin: 0 0 0.35rem;
    padding: 0;
    font-size: 0.74rem;
    font-weight: 700;
}

.area-setting-choice {
    display: inline-flex;
    align-items: center;
    gap: 0.28rem;
    margin-right: 0.75rem;
    font-size: 0.78rem;
}

.area-setting-text .form-group {
    margin-bottom: 0.35rem;
}

.area-setting-text label {
    display: block;
    margin-bottom: 0.18rem;
    font-size: 0.74rem;
    font-weight: 600;
}

.area-setting-text input[type="text"] {
    width: 100%;
    max-width: 28rem;
    font: inherit;
    font-size: 0.78rem;
    padding: 0.28rem 0.42rem;
    border: 1px solid var(--color-border);
    border-radius: 4px;
}

.area-setting-choice-block {
    display: flex;
    width: 100%;
    margin-bottom: 0.22rem;
}

.area-setting-fieldset.is-cleaning-disabled {
    opacity: 0.55;
}

.area-setting-fieldset.is-cleaning-disabled [data-cleaning-method] {
    pointer-events: none;
}

.area-type-settings {
    display: grid;
    gap: 0.45rem;
    margin: 0 0 0.65rem;
}

.area-type-settings-panel {
    border: 1px solid var(--color-border);
    border-radius: 6px;
    background: #fff;
    overflow: hidden;
    display: none;
}

.area-type-settings-panel.is-active {
    display: block;
    border-color: var(--color-primary);
}

.area-type-settings-panel.is-editing-selection {
    box-shadow: 0 0 0 2px rgb(22 163 74 / 0.18);
}

.area-type-settings-panel-head {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.35rem 0.55rem;
    background: var(--color-surface-muted, #f8fafc);
    border-bottom: 1px solid var(--color-border);
}

.area-type-settings-panel-swatch {
    width: 0.48rem;
    height: 0.48rem;
    border-radius: 999px;
    border: 1px solid rgb(0 0 0 / 0.12);
    flex-shrink: 0;
}

.area-type-settings-panel-title {
    margin: 0;
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--color-text);
}

.area-type-settings-panel-body {
    padding: 0.45rem 0.55rem 0.5rem;
}

.area-type-settings-placeholder {
    margin: 0;
    font-size: 0.78rem;
}

.area-settings-fields {
    display: grid;
    gap: 0.35rem;
}

.area-setting-row {
    padding-bottom: 0.35rem;
    border-bottom: 1px solid var(--color-border);
}

.area-setting-row:last-child {
    padding-bottom: 0;
    border-bottom: none;
}

.area-setting-row.is-care-disabled {
    opacity: 0.55;
}

.area-setting-row.is-care-disabled .area-setting-toggle {
    cursor: not-allowed;
}

.area-setting-row-main {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35rem 0.75rem;
}

.area-setting-toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.78rem;
    font-weight: 600;
    cursor: pointer;
}

.area-setting-toggle input {
    width: 0.85rem;
    height: 0.85rem;
    margin: 0;
}

.area-setting-alt {
    margin: 0.15rem 0 0 1.15rem;
    font-size: 0.66rem;
    line-height: 1.25;
}

.area-setting-count {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    min-width: 0;
}

.area-setting-count label {
    font-size: 0.66rem;
    color: var(--color-muted);
    white-space: nowrap;
}

.area-setting-count input[type='number'] {
    width: 3.25rem;
    padding: 0.15rem 0.35rem;
    font-size: 0.78rem;
}

.area-popup {
    font-size: 0.78rem;
    line-height: 1.35;
}

.area-popup-attrs {
    margin: 0.35rem 0 0;
    padding-left: 1rem;
}

.area-popup-attrs li {
    margin: 0.1rem 0;
}

.area-popup-empty {
    margin: 0.35rem 0 0;
    color: var(--color-muted);
}

.area-popup-badge {
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--color-muted);
}

.property-areas-measurement {
    margin: 0 0 0.65rem;
    padding: 0.45rem 0.6rem;
    border: 1px solid rgb(22 163 74 / 0.22);
    border-radius: 6px;
    background: rgb(22 163 74 / 0.06);
    min-height: 6.35rem;
    box-sizing: border-box;
}

.property-areas-measurement-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(11rem, 0.95fr);
    gap: 0.5rem 1rem;
    align-items: start;
}

.property-areas-measurement-selected,
.property-areas-measurement-summary {
    min-width: 0;
}

.property-areas-measurement-empty {
    margin: 0;
    min-height: 3.55rem;
    display: flex;
    align-items: center;
    font-size: 0.78rem;
    color: var(--color-text-muted, #64748b);
}

.property-areas-measurement-values {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr));
    gap: 0.35rem 0.75rem;
    margin: 0;
    min-height: 3.55rem;
}

.property-areas-measurement-values[hidden],
.property-areas-measurement-empty[hidden] {
    display: none !important;
}

.property-areas-measurement-head {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0.35rem 0.55rem;
    margin-bottom: 0.35rem;
}

.property-areas-measurement-label {
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    color: var(--color-text-muted, #64748b);
}

.property-areas-measurement-title {
    font-size: 0.82rem;
    color: var(--color-text);
}

.property-areas-measurement-row {
    display: grid;
    grid-template-columns: minmax(6.5rem, auto) 1fr;
    gap: 0.35rem 0.55rem;
    align-items: baseline;
    margin: 0;
}

.property-areas-measurement-row[hidden] {
    display: none !important;
}

.property-areas-measurement-row dt {
    margin: 0;
    font-size: 0.74rem;
    color: var(--color-text-muted, #64748b);
}

.property-areas-measurement-row dd {
    margin: 0;
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--color-text);
}

.property-areas-measurement-row-net dd {
    color: #166534;
}

.property-areas-measurement-water-note {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0.35rem 0.55rem;
    margin: 0.4rem 0 0;
    padding-top: 0.4rem;
    border-top: 1px solid rgb(22 163 74 / 0.15);
    font-size: 0.74rem;
}

.property-areas-measurement-water-note[hidden] {
    display: none !important;
}

.property-areas-measurement-water-label {
    color: var(--color-text-muted, #64748b);
}

.property-areas-measurement-water-value {
    font-size: 0.82rem;
    font-weight: 700;
    color: #0284c7;
}

.property-areas-summary-empty {
    margin: 0;
    min-height: 3.55rem;
    display: flex;
    align-items: center;
    font-size: 0.74rem;
    color: var(--color-text-muted, #64748b);
}

.property-areas-summary-empty[hidden],
.property-areas-summary-table-wrap[hidden] {
    display: none !important;
}

.property-areas-summary-table-wrap {
    overflow-x: auto;
}

.property-areas-summary-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.74rem;
}

.property-areas-summary-table th,
.property-areas-summary-table td {
    padding: 0.2rem 0.35rem;
    text-align: left;
    border-bottom: 1px solid rgb(22 163 74 / 0.15);
    vertical-align: middle;
}

.property-areas-summary-table th {
    font-size: 0.66rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: var(--color-text-muted, #64748b);
}

.property-areas-summary-table th:nth-child(2),
.property-areas-summary-table td:nth-child(2) {
    text-align: center;
    width: 2.5rem;
}

.property-areas-summary-table th:nth-child(n+3),
.property-areas-summary-table td:nth-child(n+3) {
    text-align: right;
    white-space: nowrap;
}

.property-areas-summary-swatch {
    display: inline-block;
    width: 0.45rem;
    height: 0.45rem;
    border-radius: 999px;
    margin-right: 0.35rem;
    vertical-align: middle;
    border: 1px solid rgb(0 0 0 / 0.12);
}

.property-areas-summary-table tfoot th,
.property-areas-summary-table tfoot td {
    border-bottom: none;
    border-top: 1px solid rgb(22 163 74 / 0.28);
    font-weight: 700;
    padding-top: 0.35rem;
}

.property-areas-summary-pending td {
    font-size: 0.68rem;
    font-style: italic;
    color: var(--color-text-muted, #64748b);
    border-top: none;
    padding-top: 0.15rem;
}

.property-areas-summary-area-split .property-areas-area-gross {
    color: var(--color-text);
}

.property-areas-summary-area-split .property-areas-area-sep {
    color: var(--color-text-muted, #64748b);
    font-weight: 400;
}

.property-areas-summary-area-split .property-areas-area-service {
    color: #166534;
    font-weight: 700;
}

body.property-areas-map-fullscreen .property-areas-measurement {
    margin-bottom: 0.45rem;
}

.property-areas-toolbar-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.28rem;
}

@media (max-width: 720px) {
    .property-areas-measurement-layout {
        grid-template-columns: 1fr;
    }
}

.property-areas-fullscreen-btn {
    margin-left: 0;
}

.property-areas-edit-shape-btn.is-editing {
    border-color: var(--color-primary);
    background: var(--color-primary-soft);
}

.property-areas-section .area-type-quickselect-group-label,
.property-areas-section .area-type-quickselect-subgroup-label,
.property-areas-section .property-areas-measurement-label,
.property-areas-section .property-areas-summary-table th,
.property-areas-section .area-popup-badge,
.property-areas-section .property-areas-summary-pending td {
    font-size: 0.62rem;
}

.property-areas-section .area-setting-fieldset legend,
.property-areas-section .area-setting-text label,
.property-areas-section .property-areas-measurement-row dt,
.property-areas-section .property-areas-measurement-water-note,
.property-areas-section .property-areas-summary-empty,
.property-areas-section .property-areas-summary-table,
.property-areas-section .area-setting-alt,
.property-areas-section .area-setting-count label {
    font-size: 0.68rem;
}

.property-areas-section .area-setting-choice,
.property-areas-section .area-setting-text input[type="text"],
.property-areas-section .area-type-settings-panel-title,
.property-areas-section .area-type-settings-placeholder,
.property-areas-section .area-setting-toggle,
.property-areas-section .area-setting-count input[type='number'],
.property-areas-section .area-popup,
.property-areas-section .property-areas-measurement-empty {
    font-size: 0.72rem;
}

.property-areas-section .property-areas-measurement-title,
.property-areas-section .property-areas-measurement-row dd,
.property-areas-section .property-areas-measurement-water-value {
    font-size: 0.76rem;
}

.property-areas-save-hint {
    margin: 0.85rem 0 0;
}

.map-container-areas {
    width: 100%;
    height: clamp(280px, 45vh, 380px);
}

body.property-areas-map-fullscreen {
    overflow: hidden;
}

body.property-areas-map-fullscreen .localhost-banner,
body.property-areas-map-fullscreen .preview-banner,
body.property-areas-map-fullscreen .app-header,
body.property-areas-map-fullscreen .app-footer,
body.property-areas-map-fullscreen .page-toolbar,
body.property-areas-map-fullscreen .property-areas-save-hint,
body.property-areas-map-fullscreen .property-areas-section > .hint:first-child {
    display: none !important;
}

body.property-areas-map-fullscreen .page-content {
    padding: 0;
    margin: 0;
    height: 100vh;
    height: 100dvh;
}

body.property-areas-map-fullscreen .container-property-areas {
    width: 100%;
    max-width: none;
    margin: 0;
    height: 100%;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

body.property-areas-map-fullscreen .card-property-areas-map {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
    height: 100%;
    margin: 0;
    padding: 0.65rem 0.75rem;
    border: none;
    border-radius: 0;
    box-shadow: none;
}

body.property-areas-map-fullscreen .card-property-areas-map > .form {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

body.property-areas-map-fullscreen .property-areas-section {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

body.property-areas-map-fullscreen .area-type-settings {
    flex-shrink: 0;
    max-height: min(32vh, 280px);
    overflow-y: auto;
}

body.property-areas-map-fullscreen .property-areas-map-shell {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

body.property-areas-map-fullscreen .map-container-areas {
    flex: 1;
    min-height: 0;
    height: auto !important;
}

body.property-areas-map-fullscreen .property-areas-map-chrome-top {
    z-index: 1100;
}

@media (max-width: 640px) {
    .property-areas-map-chrome-top {
        left: 3.25rem;
        max-width: calc(100% - 3.75rem);
    }
}

@media (min-width: 768px) {
    .area-settings-fields-lawn {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        column-gap: 0.75rem;
    }

    .area-settings-fields-lawn .area-setting-row {
        border-bottom: none;
        padding-bottom: 0;
    }

    .card-property-areas-map {
        padding: 1.15rem 1.35rem;
    }

    .map-container-areas {
        height: clamp(380px, 55vh, 560px);
    }
}

@media (min-width: 1024px) {
    .map-container-areas {
        height: clamp(460px, 65vh, 720px);
    }
}

.container-property-plants {
    max-width: min(96vw, 1180px);
}

.property-plants-section > .hint:first-child {
    margin-top: 0;
}

.property-plants-section .plant-type-settings {
    position: relative;
    z-index: 2;
}

.property-plants-section .plant-type-settings-panel.is-active {
    scroll-margin-top: 6.5rem;
}

.property-plants-section .property-plants-summary {
    position: relative;
    z-index: 2;
}

/* Compact attribute typography — match Flächen */
.property-plants-section .area-type-settings-panel-title,
.property-plants-section .plant-files-title,
.property-plants-section .property-plants-summary-empty,
.property-plants-section .property-plants-summary-table,
.property-plants-section .property-plants-summary-table th {
    font-size: 0.68rem;
}

.property-plants-section .plant-type-settings-panel label,
.property-plants-section .plant-type-settings-panel select,
.property-plants-section .plant-type-settings-panel input[type='text'],
.property-plants-section .plant-files-empty-hint,
.property-plants-section .plant-files-hint,
.property-plants-section .plant-files-note,
.property-plants-section .plant-file-name,
.property-plants-section .plant-file-identify-title,
.property-plants-section .plant-file-identify-panel {
    font-size: 0.72rem;
}

.property-plants-section .plant-files-actions .btn-sm,
.property-plants-section .plant-file-meta .btn-sm {
    font-size: 0.68rem;
    padding: 0.22rem 0.48rem;
}

.property-plants-section .plant-replacement-planned-row {
    margin-top: 0.45rem;
}

.property-plants-section .plant-replacement-planned-toggle {
    font-size: 0.72rem;
}

.property-plants-summary {
    margin: 0.85rem 0 1rem;
    padding: 0.85rem 1rem;
    border: 1px solid var(--color-border);
    border-radius: 10px;
    background: var(--color-surface-muted, #f8faf8);
}

.property-plants-summary-empty {
    margin: 0.35rem 0 0;
    color: var(--color-text-muted);
    font-size: 0.88rem;
}

.property-plants-summary-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.82rem;
}

.property-plants-summary-table th,
.property-plants-summary-table td {
    padding: 0.35rem 0.5rem;
    border-bottom: 1px solid var(--color-border);
    text-align: left;
}

.property-plants-map-status {
    position: absolute;
    left: 0.65rem;
    right: 0.65rem;
    bottom: calc(0.65rem + min(34%, 220px) + 0.35rem);
    z-index: 1000;
    margin: 0;
    padding: 0.35rem 0.55rem;
    border: 1px solid rgba(15, 23, 42, 0.12);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.1);
    font-size: 0.78rem;
    line-height: 1.35;
    pointer-events: none;
}

.property-plants-map-status.is-error {
    color: #b42318;
}

.property-plants-map-shell {
    position: relative;
    isolation: isolate;
    z-index: 1;
}

/* Keep Leaflet +/- free: stack type + action chrome to the right of zoom. */
.property-plants-map-chrome-top {
    position: absolute;
    top: 0.5rem;
    left: 3.4rem;
    right: 0.5rem;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.4rem;
    max-width: calc(100% - 3.9rem);
    pointer-events: none;
}

.property-plants-map-chrome-types {
    position: static;
    max-width: 100%;
    pointer-events: auto;
}

.property-plants-map-chrome-types .property-plants-top-bar {
    margin: 0;
    display: inline-flex;
    max-width: 100%;
    padding: 0.3rem 0.35rem;
    border: 1px solid rgba(15, 23, 42, 0.12);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: 0 2px 10px rgba(15, 23, 42, 0.12);
}

.property-plants-map-chrome-types .plant-type-quickselect {
    margin: 0;
}

.property-plants-map-chrome-files {
    position: relative;
    z-index: 1;
    margin: 0.65rem 0 0;
    max-height: min(40vh, 280px);
    overflow: auto;
    padding: 0.45rem 0.55rem;
    border: 1px solid rgba(15, 23, 42, 0.12);
    border-radius: 10px;
    background: #fff;
    box-shadow: 0 1px 4px rgba(15, 23, 42, 0.08);
    pointer-events: auto;
}

.property-plants-map-overlay {
    position: static;
    z-index: auto;
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.28rem;
    max-width: 100%;
    margin: 0;
    padding: 0.35rem 0.4rem;
    border: 1px solid rgba(15, 23, 42, 0.12);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: 0 2px 10px rgba(15, 23, 42, 0.12);
    pointer-events: auto;
}

.property-plants-map-overlay .btn-sm {
    font-size: 0.68rem;
    padding: 0.22rem 0.48rem;
    line-height: 1.25;
    white-space: nowrap;
}

.desktop-only-inline {
    display: none !important;
}

@media (hover: hover) and (pointer: fine) {
    .desktop-only-inline {
        display: inline-flex !important;
    }
}

.plant-photos-window-page {
    padding-bottom: 2rem;
}

.plant-photos-window-card {
    padding: 1rem 1.1rem 1.25rem;
}

.plant-photos-window-head {
    margin-bottom: 0.75rem;
}

.plant-photos-window-title {
    margin: 0 0 0.35rem;
    font-size: 1.15rem;
}

.plant-photos-window-meta {
    margin: 0;
}

.plant-photos-window-empty {
    margin: 0.75rem 0 0;
}

.plant-photos-window-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 1rem;
    margin-top: 0.75rem;
}

.plant-photos-window-gallery .plant-file-item {
    width: auto;
}

.plant-photos-window-gallery .plant-file-preview img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
}

.map-container-plants {
    height: clamp(340px, 50vh, 520px);
}

.map-container-plants:focus {
    outline: none;
}

.map-container-plants:focus-visible {
    outline: 2px solid rgba(22, 163, 74, 0.45);
    outline-offset: 2px;
}

.property-plants-reference-area {
    pointer-events: none !important;
}

.map-container-plants .property-plant-point-marker {
    cursor: pointer;
}

.map-container-plants .leaflet-interactive.property-plant-point-marker {
    cursor: pointer;
}

.map-container-plants .property-plant-point-icon {
    background: transparent !important;
    border: none !important;
    cursor: pointer;
}

.map-container-plants .property-plant-point-icon-inner {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    border-radius: 999px;
    filter: drop-shadow(0 1px 1px rgba(15, 23, 42, 0.35));
}

.map-container-plants .property-plant-point-icon-inner svg {
    width: 100%;
    height: 100%;
    display: block;
    stroke: currentColor;
}

.map-container-plants .property-plant-point-icon.is-selected .property-plant-point-icon-inner {
    background: rgba(255, 255, 255, 0.92);
    box-shadow: 0 0 0 2px currentColor, 0 1px 4px rgba(15, 23, 42, 0.22);
    padding: 0.12rem;
}

.plant-species-text-input {
    margin-top: 0.45rem;
}

.plant-files-root {
    margin: 1rem 0;
    padding: 0.9rem 1rem;
    border: 1px solid var(--color-border);
    border-radius: 10px;
    background: var(--color-surface-muted, #f8faf8);
}

.plant-files-root.is-disabled {
    opacity: 0.92;
}

.plant-files-head {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 1rem;
    align-items: baseline;
    margin-bottom: 0.5rem;
}

.map-files-panel-head {
    align-items: center;
    margin-bottom: 0.35rem;
}

.map-files-panel.is-collapsed .map-files-panel-head {
    margin-bottom: 0;
}

.map-files-panel-toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
    color: inherit;
    font: inherit;
    font-weight: 600;
    font-size: 0.92rem;
    cursor: pointer;
    text-align: left;
}

.map-files-panel-toggle:hover,
.map-files-panel-toggle:focus-visible {
    color: var(--color-primary, #15803d);
}

.map-files-panel-chevron {
    display: inline-block;
    width: 0.55rem;
    height: 0.55rem;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(45deg);
    transition: transform 0.15s ease;
    margin-top: -0.15rem;
}

.map-files-panel.is-collapsed .map-files-panel-chevron {
    transform: rotate(-45deg);
    margin-top: 0.1rem;
}

.map-files-panel.is-collapsed .map-files-panel-body,
.map-files-panel.is-collapsed .map-files-panel-head-hint {
    display: none;
}

.property-plants-map-chrome-files.map-files-panel.is-collapsed,
.property-trees-map-chrome-files.map-files-panel.is-collapsed {
    max-height: none;
    overflow: visible;
}

.plant-files-title {
    font-weight: 600;
    font-size: 0.92rem;
}

.plant-files-actions,
.property-photos-root .plant-files-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
    margin: 0.65rem 0;
}

.property-photos-limit-hint {
    margin: 0;
}

.plant-files-photo-list,
.plant-files-document-list,
.property-photos-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
    margin-top: 0.65rem;
}

.plant-file-item {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    width: min(100%, 220px);
}

.plant-file-item-pending .plant-file-preview-pending {
    display: flex;
    align-items: center;
    justify-content: center;
    background: repeating-linear-gradient(
        -45deg,
        rgba(148, 163, 184, 0.12),
        rgba(148, 163, 184, 0.12) 8px,
        rgba(148, 163, 184, 0.2) 8px,
        rgba(148, 163, 184, 0.2) 16px
    );
}

.plant-file-item-pending .plant-file-name {
    color: var(--color-text-muted, #64748b);
    font-size: 0.78rem;
}

.plant-file-identify-panel {
    margin-top: 0.15rem;
    padding: 0.45rem 0.5rem;
    border: 1px solid var(--color-border);
    border-radius: 8px;
    background: #fff;
    font-size: 0.78rem;
}

.plant-file-identify-title {
    margin: 0 0 0.35rem;
    font-size: 0.78rem;
    font-weight: 600;
}

.plant-file-meta .plant-file-identify-btn,
.plant-file-meta .plant-file-delete-btn {
    width: 100%;
}

.plant-file-preview {
    display: block;
    width: 108px;
    height: 78px;
    border: 1px solid var(--color-border);
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
}

.plant-file-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    cursor: zoom-in;
}

.plant-file-preview-doc {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.78rem;
    text-decoration: none;
    color: var(--color-text);
}

.plant-file-meta {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.plant-file-name {
    font-size: 0.72rem;
    line-height: 1.25;
    word-break: break-word;
}

.plant-file-date {
    font-size: 0.58rem;
    line-height: 1.2;
    color: var(--color-text-muted, #64748b);
}

.plant-file-baumschau {
    display: block;
    font-size: 0.62rem;
    line-height: 1.25;
    color: var(--color-text-muted, #64748b);
}

.property-document-preview {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.property-document-date {
    margin-top: 0.15rem;
}

.plant-files-status.is-error {
    color: #b42318;
}

body.property-plants-map-fullscreen {
    overflow: hidden;
}

body.property-plants-map-fullscreen .localhost-banner,
body.property-plants-map-fullscreen .preview-banner,
body.property-plants-map-fullscreen .app-header,
body.property-plants-map-fullscreen .app-footer,
body.property-plants-map-fullscreen .page-toolbar,
body.property-plants-map-fullscreen .property-plants-section > .hint:first-child,
body.property-plants-map-fullscreen .plant-files-hint,
body.property-plants-map-fullscreen .plant-files-note,
body.property-plants-map-fullscreen .plant-files-document-btn,
body.property-plants-map-fullscreen .plant-files-document-list,
body.property-plants-map-fullscreen .property-plants-summary {
    display: none !important;
}

body.property-plants-map-fullscreen .page-content {
    padding: 0;
    margin: 0;
    height: 100vh;
    height: 100dvh;
}

body.property-plants-map-fullscreen .container-property-plants,
body.property-plants-map-fullscreen .container-property-areas {
    width: 100%;
    max-width: none;
    margin: 0;
    height: 100%;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

body.property-plants-map-fullscreen .card-property-areas-map {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
    height: 100%;
    margin: 0;
    padding: 0.65rem 0.75rem;
    border: none;
    border-radius: 0;
    box-shadow: none;
}

body.property-plants-map-fullscreen .card-property-areas-map > .form {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

body.property-plants-map-fullscreen .property-plants-section {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
    max-height: 100%;
    margin: 0;
    padding: 0;
    overflow: hidden;
}

body.property-plants-map-fullscreen .plant-type-settings {
    position: relative;
    z-index: 1200;
    flex: 0 0 auto;
    flex-shrink: 0;
    max-height: min(32vh, 280px);
    overflow-y: auto;
    margin-bottom: 0.35rem;
}

body.property-plants-map-fullscreen .plant-type-settings-panel-head {
    display: none;
}

body.property-plants-map-fullscreen .property-plants-map-shell {
    position: relative;
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
    overflow: hidden;
}

body.property-plants-map-fullscreen .map-container-plants {
    position: relative;
    flex: 1;
    min-height: 0;
    width: 100%;
    height: auto !important;
    border-radius: 0;
}

body.property-plants-map-fullscreen .property-plants-map-chrome-top,
body.property-plants-map-fullscreen .property-plants-map-status {
    z-index: 1100;
}

body.property-plants-map-fullscreen .property-plants-map-chrome-files {
    position: relative;
    z-index: 1;
    flex: 0 0 auto;
    max-height: min(28vh, 220px);
    margin: 0;
    border-radius: 0;
    border-left: 0;
    border-right: 0;
    border-bottom: 0;
}

body.property-plants-map-fullscreen .property-plants-map-status {
    bottom: auto;
    top: 50%;
    left: 50%;
    right: auto;
    transform: translate(-50%, -50%);
    max-width: min(92%, 22rem);
    text-align: center;
    pointer-events: none;
}

.property-plants-fullscreen-btn {
    margin-left: 0;
}

@media (max-width: 640px) {
    .property-plants-map-chrome-top {
        left: 3.25rem;
        max-width: calc(100% - 3.75rem);
    }

    .property-plants-map-chrome-files {
        max-height: min(42vh, 260px);
    }
}

@media (min-width: 768px) {
    .map-container-plants {
        height: clamp(380px, 55vh, 560px);
    }
}

@media (min-width: 1024px) {
    .map-container-plants {
        height: clamp(460px, 65vh, 720px);
    }
}

.container-property-trees {
    max-width: min(96vw, 1180px);
}

.property-trees-section > .hint:first-child {
    margin-top: 0;
}

.property-trees-section .property-tree-settings {
    position: relative;
    z-index: 2;
}

.property-trees-section .property-tree-settings-panel.is-active {
    scroll-margin-top: 6.5rem;
}

.property-trees-section .property-trees-summary {
    position: relative;
    z-index: 2;
}

.property-trees-section .area-type-settings-panel-title,
.property-trees-section .property-trees-summary-empty,
.property-trees-section .property-trees-summary-table,
.property-trees-section .property-trees-summary-table th {
    font-size: 0.68rem;
}

.property-trees-section .property-tree-settings-panel label,
.property-trees-section .property-tree-settings-panel select,
.property-trees-section .property-tree-settings-panel input[type='text'] {
    font-size: 0.72rem;
}

.tree-species-text-input {
    margin-top: 0.45rem;
}

.property-trees-section .tree-settings-inventory-row {
    display: grid;
    gap: 0.35rem;
    margin-top: 0.35rem;
    max-width: 10rem;
}

.property-trees-section .tree-planned-rows .area-setting-toggle {
    margin: 0;
}

.tree-measurements-grid {
    gap: 0.45rem 0.65rem;
    margin-top: 0.35rem;
    align-items: start;
}

.tree-measurements-grid .form-group {
    margin-bottom: 0;
}

.tree-measurements-grid .field-hint {
    margin: 0.1rem 0 0;
    font-size: 0.68rem;
    line-height: 1.2;
}

.property-trees-section .tree-measurements-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.property-trees-section .tree-measurements-grid input[type='text'] {
    width: 100%;
    max-width: 7.5rem;
}

@media (max-width: 720px) {
    .property-trees-section .tree-measurements-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .property-trees-section .tree-measurements-grid input[type='text'] {
        max-width: none;
    }
}

body.property-trees-map-fullscreen .tree-measurements-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

body.property-trees-map-fullscreen .tree-measurements-grid input[type='text'] {
    max-width: 6.5rem;
}

@media (max-width: 900px) {
    body.property-trees-map-fullscreen .tree-measurements-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

.property-trees-summary {
    margin: 0.85rem 0 1rem;
    padding: 0.85rem 1rem;
    border: 1px solid var(--color-border);
    border-radius: 10px;
    background: var(--color-surface-muted, #f8faf8);
}

.property-trees-summary-empty {
    margin: 0.35rem 0 0;
    color: var(--color-text-muted);
    font-size: 0.88rem;
}

.property-trees-summary-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.82rem;
}

.property-trees-summary-table th,
.property-trees-summary-table td {
    padding: 0.35rem 0.5rem;
    border-bottom: 1px solid var(--color-border);
    text-align: left;
}

.property-trees-map-status {
    position: absolute;
    left: 0.65rem;
    right: 0.65rem;
    bottom: 0.65rem;
    z-index: 1000;
    margin: 0;
    padding: 0.35rem 0.55rem;
    border: 1px solid rgba(15, 23, 42, 0.12);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.1);
    font-size: 0.78rem;
    line-height: 1.35;
    pointer-events: none;
}

.property-trees-map-status.is-error {
    color: #b42318;
}

.property-trees-map-shell {
    position: relative;
    isolation: isolate;
    z-index: 1;
}

.property-trees-map-chrome-top {
    position: absolute;
    top: 0.5rem;
    left: 3.4rem;
    right: 0.5rem;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.4rem;
    max-width: calc(100% - 3.9rem);
    pointer-events: none;
}

.property-trees-map-overlay {
    position: static;
    z-index: auto;
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.28rem;
    max-width: 100%;
    margin: 0;
    padding: 0.35rem 0.4rem;
    border: 1px solid rgba(15, 23, 42, 0.12);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: 0 2px 10px rgba(15, 23, 42, 0.12);
    pointer-events: auto;
}

.property-trees-map-overlay .btn-sm {
    font-size: 0.68rem;
    padding: 0.22rem 0.48rem;
    line-height: 1.25;
    white-space: nowrap;
}

.property-trees-map-chrome-files {
    position: relative;
    z-index: 1;
    margin: 0.65rem 0 0;
    max-height: min(40vh, 280px);
    overflow: auto;
    padding: 0.45rem 0.55rem;
    border: 1px solid rgba(15, 23, 42, 0.12);
    border-radius: 10px;
    background: #fff;
    box-shadow: 0 1px 4px rgba(15, 23, 42, 0.08);
    pointer-events: auto;
}

.property-trees-section .property-trees-map-chrome-files .plant-files-title,
.property-trees-section .property-trees-map-chrome-files .plant-files-hint,
.property-trees-section .property-trees-map-chrome-files .plant-files-note,
.property-trees-section .property-trees-map-chrome-files .plant-files-empty-hint,
.property-trees-section .property-trees-map-chrome-files .plant-file-name,
.property-trees-section .property-trees-map-chrome-files .plant-file-identify-title,
.property-trees-section .property-trees-map-chrome-files .plant-file-identify-panel {
    font-size: 0.68rem;
}

.property-trees-section .property-trees-map-chrome-files .plant-files-actions .btn-sm,
.property-trees-section .property-trees-map-chrome-files .plant-file-meta .btn-sm {
    font-size: 0.68rem;
    padding: 0.22rem 0.48rem;
}

.map-container-trees {
    height: clamp(340px, 50vh, 520px);
}

.map-container-trees.is-crown-measuring,
.map-container-trees.is-crown-measuring .leaflet-container {
    cursor: crosshair !important;
}

.property-trees-crown-measure-btn.is-active {
    outline: 2px solid #f59e0b;
    outline-offset: 1px;
}

.map-container-trees .property-tree-point-icon {
    background: transparent !important;
    border: none !important;
    cursor: pointer;
}

.map-container-trees .property-tree-point-icon-inner {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    filter: drop-shadow(0 1px 2px rgba(15, 23, 42, 0.35));
}

.map-container-trees .property-tree-point-icon-inner svg {
    width: 100%;
    height: 100%;
    stroke: currentColor;
    fill: none;
}

.map-container-trees .property-tree-point-icon.is-selected .property-tree-point-icon-inner {
    filter: drop-shadow(0 0 0 2px rgba(22, 163, 74, 0.45));
}

.property-trees-reference-layer {
    pointer-events: none !important;
}

body.property-trees-map-fullscreen {
    overflow: hidden;
}

body.property-trees-map-fullscreen .localhost-banner,
body.property-trees-map-fullscreen .preview-banner,
body.property-trees-map-fullscreen .app-header,
body.property-trees-map-fullscreen .app-footer,
body.property-trees-map-fullscreen .page-toolbar,
body.property-trees-map-fullscreen .property-trees-section > .hint:first-child,
body.property-trees-map-fullscreen .property-trees-summary,
body.property-trees-map-fullscreen .property-trees-map-chrome-files {
    display: none !important;
}

body.property-trees-map-fullscreen .page-content {
    padding: 0;
    margin: 0;
    height: 100vh;
    height: 100dvh;
}

body.property-trees-map-fullscreen .container-property-trees,
body.property-trees-map-fullscreen .container-property-areas,
body.property-trees-map-fullscreen .container-property-plants {
    width: 100%;
    max-width: none;
    margin: 0;
    height: 100%;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

body.property-trees-map-fullscreen .card-property-areas-map {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
    height: 100%;
    margin: 0;
    padding: 0.65rem 0.75rem;
    border: none;
    border-radius: 0;
    box-shadow: none;
}

body.property-trees-map-fullscreen .card-property-areas-map > .form {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

body.property-trees-map-fullscreen .property-trees-section {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
    max-height: 100%;
    margin: 0;
    padding: 0;
    overflow: hidden;
}

body.property-trees-map-fullscreen .property-tree-settings {
    position: relative;
    z-index: 1200;
    flex: 0 0 auto;
    flex-shrink: 0;
    max-height: min(48vh, 400px);
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    margin-bottom: 0.35rem;
}

body.property-trees-map-fullscreen .property-tree-settings .area-type-settings-panel-body {
    padding-bottom: 0.65rem;
}

body.property-trees-map-fullscreen .tree-planned-rows {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem 1rem;
    margin-top: 0.35rem;
}

body.property-trees-map-fullscreen .tree-planned-rows .area-setting-toggle {
    white-space: nowrap;
}

body.property-trees-map-fullscreen .property-tree-settings-panel-head {
    display: none;
}

body.property-trees-map-fullscreen .property-trees-map-shell {
    position: relative;
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
    overflow: hidden;
}

body.property-trees-map-fullscreen .map-container-trees {
    position: relative;
    flex: 1;
    min-height: 0;
    width: 100%;
    height: auto !important;
    border-radius: 0;
}

body.property-trees-map-fullscreen .property-trees-map-chrome-top,
body.property-trees-map-fullscreen .property-trees-map-status {
    z-index: 1100;
}

.map-container-trees .property-tree-point-icon,
.map-container-trees .leaflet-marker-icon.property-tree-point-icon,
.map-container-trees .leaflet-marker-draggable {
    opacity: 1 !important;
    visibility: visible !important;
}

@media (max-width: 640px) {
    .property-trees-map-chrome-top {
        left: 3.25rem;
        max-width: calc(100% - 3.75rem);
    }
}

@media (min-width: 768px) {
    .map-container-trees {
        height: clamp(380px, 55vh, 560px);
    }
}

@media (min-width: 1024px) {
    .map-container-trees {
        height: clamp(460px, 65vh, 720px);
    }
}

@media (max-width: 480px) {
    .container-property-areas {
        width: 94vw;
    }

    .area-type-quickselect-btn {
        font-size: 0.62rem;
        padding: 0.14rem 0.34rem;
    }
}

@media (min-width: 768px) {
    .map-container {
        height: 420px;
    }

    .map-container-overview {
        height: min(70vh, 720px);
    }

    .map-container-boundary {
        height: min(65vh, 640px);
    }
}

.map-overview-meta {
    margin: 0 0 1rem;
}

.send-section,
.send-log-section,
.amendments-section {
    margin-top: 1.5rem;
    padding-top: 1.25rem;
    border-top: 1px solid var(--color-border);
}

.table-subtext {
    margin-top: 0.25rem;
    font-size: 0.82rem;
    color: var(--color-muted);
    line-height: 1.35;
}

.certificate-banner {
    margin-bottom: 1rem;
}

.amendment-item {
    margin-bottom: 1rem;
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--color-border);
}

.amendment-item:last-child {
    border-bottom: none;
}

.amendment-meta {
    color: var(--color-muted);
    font-size: 0.85rem;
    margin-bottom: 0.35rem;
}

.inspection-fieldset {
    border: 0;
    margin: 0;
    padding: 0;
}

.inspection-fieldset:disabled {
    opacity: 1;
}

.inspection-fieldset:disabled input,
.inspection-fieldset:disabled select,
.inspection-fieldset:disabled textarea {
    background: var(--color-bg);
    color: var(--color-text);
}

.form-section {
    margin-top: 1.5rem;
    padding-top: 1.25rem;
    border-top: 1px solid var(--color-border);
}

.form-section:first-of-type {
    margin-top: 0;
    padding-top: 0;
    border-top: 0;
}

.form-section-title {
    font-size: 1rem;
    font-weight: 600;
    margin: 0 0 0.75rem;
}

.form-subsection-title {
    font-size: 0.95rem;
    font-weight: 600;
    margin: 0 0 0.75rem;
}

.form-section-tools {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 0.75rem;
}

.repeatable-rows {
    display: grid;
    gap: 1rem;
}

.repeatable-row {
    padding: 1rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md, 8px);
    background: var(--color-surface-muted, #f8faf9);
}

.repeatable-row-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 0.5rem;
}

.checkbox-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 0.5rem 1rem;
}

.checkbox-grid-compact {
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    margin-bottom: 1rem;
}

.snippet-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: center;
    margin-bottom: 1rem;
}

.checkbox-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 400;
    cursor: pointer;
}

.inspection-fieldset:disabled .checkbox-item {
    cursor: default;
}

.customer-email-section-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 0.75rem;
}

.customer-email-rows {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.customer-email-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr);
    gap: 0.75rem 1rem;
    padding: 0.85rem 1rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    background: var(--color-bg);
}

.customer-email-row .form-group {
    min-width: 0;
}

.customer-email-row input {
    width: 100%;
    max-width: 100%;
}

.customer-email-row-footer {
    grid-column: 1 / -1;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 0.75rem;
    padding-top: 0.15rem;
    border-top: 1px solid var(--color-border);
    margin-top: 0.15rem;
}

@media (max-width: 640px) {
    .customer-email-section-head {
        flex-direction: column;
        align-items: stretch;
    }

    .customer-email-row {
        grid-template-columns: 1fr;
    }
}

.property-address-section-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 0.75rem;
}

.property-address-rows {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.map-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem 1.25rem;
    margin: 0 0 1rem;
}

.map-legend-item {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.9rem;
    color: var(--color-text);
}

.map-legend-dot {
    width: 14px;
    height: 14px;
    border-radius: 999px;
    border: 2px solid #fff;
    box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.12);
}

.map-legend-dot-active {
    background: #2d6a4f;
}

.map-legend-dot-sick {
    background: #c2410c;
}

.map-legend-dot-removed {
    background: #6b7280;
}

.tree-map-tooltip {
    font: inherit;
    font-size: 0.9rem;
    line-height: 1.35;
    padding: 0.35rem 0.55rem;
    border-radius: 6px;
    box-shadow: var(--shadow);
}

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

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.65rem 1rem;
    border-radius: var(--radius);
    border: 1px solid transparent;
    font: inherit;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
}

.btn:disabled,
.btn[disabled] {
    opacity: 0.45;
    cursor: not-allowed;
    pointer-events: none;
    filter: grayscale(0.35);
}

.btn-primary {
    background: var(--color-primary);
    color: #fff;
}

.btn-primary:hover {
    background: var(--color-primary-dark);
}

.btn-primary:disabled:hover,
.btn-primary[disabled]:hover {
    background: var(--color-primary);
}

.btn-secondary {
    background: #fff;
    color: var(--color-primary-dark);
    border-color: var(--color-border);
}

.btn-secondary:hover {
    background: var(--color-bg);
}

.btn-secondary:disabled:hover,
.btn-secondary[disabled]:hover {
    background: #fff;
}

.btn-sm {
    padding: 0.4rem 0.75rem;
    font-size: 0.9rem;
}

.btn-icon {
    width: 2.15rem;
    height: 2.15rem;
    min-width: 2.15rem;
    padding: 0;
    gap: 0;
}

.btn-icon-glyph {
    display: inline-flex;
    width: 1.15rem;
    height: 1.15rem;
    align-items: center;
    justify-content: center;
    line-height: 0;
}

.btn-icon-glyph svg {
    width: 100%;
    height: 100%;
    display: block;
}

.btn-icon-with-plus {
    width: auto;
    min-width: 2.75rem;
    padding: 0 0.45rem;
    gap: 0.15rem;
}

.btn-icon-plus {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.15rem;
    font-weight: 700;
    line-height: 1;
    margin-top: -0.05rem;
}

.btn-with-icon {
    gap: 0.4rem;
    padding-left: 0.45rem;
    padding-right: 0.85rem;
}

.btn-with-icon-plus {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    font-weight: 700;
    line-height: 1;
    margin-top: -0.05rem;
}

.btn-with-icon-glyph {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.55rem;
    height: 1.55rem;
    border-radius: 0.45rem;
    background: rgba(255, 255, 255, 0.92);
    color: var(--color-primary-dark);
    line-height: 0;
    flex-shrink: 0;
}

.btn-with-icon-glyph svg {
    width: 0.95rem;
    height: 0.95rem;
    display: block;
}

.btn-with-icon-label {
    line-height: 1.2;
}

.btn-secondary.btn-with-icon .btn-with-icon-glyph {
    background: var(--color-primary-soft);
    color: var(--color-primary-dark);
}

.badge {
    display: inline-block;
    padding: 0.15rem 0.5rem;
    border-radius: 999px;
    font-size: 0.85rem;
}

.badge-ok,
.badge-role {
    background: #d8f3dc;
    color: var(--color-primary-dark);
}

.badge-info {
    background: #dbeafe;
    color: #1e40af;
}

.definition-list {
    margin: 1rem 0;
}

.definition-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 0.75rem 1.5rem;
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--color-border, #e5e7eb);
}

.definition-row:last-child {
    border-bottom: none;
}

.definition-row dt {
    margin: 0;
    color: var(--color-muted, #6b7280);
}

.definition-row dd {
    margin: 0;
    text-align: right;
}

.alert-error {
    background: var(--color-error-bg);
    color: var(--color-error-text);
    border-color: #f5c2c7;
}

.alert-success {
    background: #e8f5e9;
    color: #1b4332;
    border-color: #b7dfb9;
}

.alert-warning {
    background: #fff8e1;
    color: #7a5d00;
    border-color: #ffe082;
}

.alert-info {
    background: #e8f4fd;
    color: #0c5460;
    border-color: #b8daff;
}

.demo-bid-link-notice {
    border-left: 4px solid #e6a700;
    background: #fff8e6;
    color: #5c4a00;
    border-color: #ffe082;
}

.demo-bid-links-card {
    border-color: #e6c200;
    box-shadow: 0 0 0 1px rgba(230, 194, 0, 0.25);
}

.demo-only-badge {
    display: inline-block;
    margin-right: 0.35rem;
    padding: 0.15rem 0.5rem;
    border-radius: 999px;
    background: #e6a700;
    color: #3d2f00;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    vertical-align: middle;
}

.demo-only-badge--header {
    display: block;
    margin: 0.25rem 0 0;
    width: fit-content;
}

.demo-bid-link-cell {
    min-width: 11rem;
}

.demo-bid-link-cell .demo-only-badge {
    margin-bottom: 0.35rem;
}

.demo-bid-link-btn {
    display: inline-block;
}

.demo-login-hint {
    margin-bottom: 1rem;
}

.demo-login-list {
    margin: 0.65rem 0 0;
    padding-left: 1.1rem;
}

.demo-login-list li + li {
    margin-top: 0.35rem;
}

.demo-login-list code {
    word-break: break-all;
}

.demo-login-reset {
    margin: 0.75rem 0 0;
}

.reset-actions {
    display: grid;
    gap: 1rem;
}

.reset-card-header {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.5rem 1rem;
    margin-bottom: 0.5rem;
}

.reset-card-header h2 {
    margin: 0;
    font-size: 1.1rem;
}

.reset-count {
    color: var(--color-muted);
    font-size: 0.95rem;
}

.reset-form {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--color-border);
}

.form-links {
    margin: 1.25rem 0 0;
    text-align: center;
}

.form-links a {
    color: var(--color-primary);
    text-decoration: none;
    font-weight: 600;
}

.form-links a:hover {
    text-decoration: underline;
}

.hint {
    margin-bottom: 0;
    color: var(--color-muted);
    font-size: 0.95rem;
}

.cv-ui-tip {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.15rem;
    height: 1.15rem;
    margin-left: 0.2rem;
    padding: 0;
    border: 1px solid var(--color-border);
    border-radius: 999px;
    background: var(--color-surface);
    color: var(--color-muted);
    font-size: 0.7rem;
    font-weight: 700;
    line-height: 1;
    cursor: help;
    vertical-align: middle;
}

.cv-ui-tip:hover,
.cv-ui-tip:focus,
.cv-ui-tip.is-open {
    border-color: var(--color-primary);
    color: var(--color-primary);
    outline: none;
}

.cv-ui-tip.is-open::after {
    content: attr(title);
    position: absolute;
    z-index: 40;
    left: 50%;
    transform: translateX(-50%);
    top: calc(100% + 0.35rem);
    width: max-content;
    max-width: 16rem;
    padding: 0.4rem 0.55rem;
    border-radius: 6px;
    background: #1a1a1a;
    color: #fff;
    font-size: 0.78rem;
    font-weight: 500;
    line-height: 1.35;
    white-space: normal;
    box-shadow: var(--shadow);
    pointer-events: none;
}

.item-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.item-list li {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--color-border);
}

.item-list li:last-child {
    border-bottom: none;
}

.item-list span {
    color: var(--color-muted);
    font-size: 0.95rem;
}

code {
    background: var(--color-bg);
    padding: 0.1rem 0.35rem;
    border-radius: 4px;
    font-size: 0.9em;
}

.admin-nav {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem 1rem;
    padding-top: 0.15rem;
    border-top: 1px solid var(--color-border);
}

.admin-nav a {
    color: var(--color-primary-dark);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
}

.admin-nav a:hover {
    text-decoration: underline;
}

.page-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}

.page-toolbar-stacked {
    align-items: flex-start;
}

.page-toolbar .page-intro {
    margin: 0;
}

.page-toolbar .subtitle {
    margin-bottom: 0;
}

.page-toolbar-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    flex-shrink: 0;
}

.action-links {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-bottom: 0.75rem;
}

.card-table {
    overflow: hidden;
}

.table-wrap {
    overflow-x: auto;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.95rem;
}

.data-table th,
.data-table td {
    padding: 0.75rem 0.5rem;
    border-bottom: 1px solid var(--color-border);
    text-align: left;
    vertical-align: middle;
}

.data-table th {
    color: var(--color-muted);
    font-size: 0.85rem;
    font-weight: 600;
}

.table-sort-link {
    color: inherit;
    text-decoration: none;
}

.table-sort-link:hover {
    color: var(--color-primary-dark);
    text-decoration: underline;
}

.data-table--row-links tbody tr.is-row-link {
    cursor: pointer;
}

.data-table--row-links tbody tr.is-row-link:hover td {
    background: var(--color-primary-soft, #eef6f1);
}

.data-table tbody tr:last-child td {
    border-bottom: none;
}

.table-actions {
    white-space: nowrap;
    text-align: right;
    vertical-align: middle;
}

.data-table td.table-actions,
.data-table th.table-actions {
    display: table-cell;
    width: 1%;
}

.data-table .input-price {
    width: 100%;
    max-width: 7.5rem;
    min-width: 5rem;
}

.pricing-tier-table .input-compact {
    width: 100%;
    min-width: 4.5rem;
    max-width: 8rem;
}

.pricing-tier-actions {
    width: 3rem;
    text-align: center;
    vertical-align: middle;
}

.offer-prices-section .section-title {
    margin-bottom: 0.35rem;
}

.offer-prices-section-hint {
    margin: 0;
}

.offer-prices-table {
    table-layout: fixed;
}

.offer-prices-table col.offer-prices-col-tier {
    width: 11rem;
}

.offer-prices-table col.offer-prices-col-label {
    width: auto;
}

.offer-prices-table col.offer-prices-col-price {
    width: 7.5rem;
}

.offer-prices-table col.offer-prices-col-unit {
    width: 11rem;
}

.offer-prices-table tr.offer-prices-section-row td {
    padding-top: 1.25rem;
    padding-bottom: 0.5rem;
    border-bottom: none;
    background: var(--color-bg);
}

.offer-prices-table tbody tr:first-child.offer-prices-section-row td {
    padding-top: 0.25rem;
}

.offer-prices-table tr.offer-prices-section-row .section-title {
    margin: 0 0 0.35rem;
}

.offer-prices-table tr.offer-prices-section-spacer td {
    padding: 0.35rem 0;
    border-bottom: none;
    background: var(--color-bg);
}

.offer-prices-table th:nth-child(3),
.offer-prices-table td.offer-prices-price {
    text-align: right;
}

.offer-prices-table th:nth-child(4),
.offer-prices-table td.offer-prices-unit {
    white-space: nowrap;
}

.offer-prices-table td.offer-prices-tier,
.offer-prices-table td.offer-prices-label,
.offer-prices-table td.offer-prices-price,
.offer-prices-table td.offer-prices-unit {
    vertical-align: middle;
}

.offer-prices-table .input-price {
    width: 100%;
    max-width: none;
    min-width: 0;
    padding: 0.5rem 0.65rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    font: inherit;
    background: #fff;
    text-align: right;
    box-sizing: border-box;
}

.offer-prices-table .input-price:focus {
    outline: 2px solid rgba(45, 106, 79, 0.25);
    border-color: var(--color-primary);
}

.offer-prices-tier-empty {
    color: var(--color-border);
}

.offer-prices-form > .form-actions {
    margin-top: 1.5rem;
}

.badge-type {
    background: #eef4ff;
    color: #274690;
}

.badge-inactive {
    background: #f1f3f5;
    color: #5c6670;
}

.badge-warning {
    background: #fff8e1;
    color: #7a5d00;
}

.badge-danger {
    background: #fdecea;
    color: #9b1c1c;
}

.badge-report {
    font-weight: 600;
}

.badge-report-open {
    background: #fff3cd;
    color: #856404;
}

.badge-report-in_progress {
    background: #eef4ff;
    color: #274690;
}

.badge-report-resolved {
    background: #e8f5e9;
    color: #2d6a4f;
}

.detail-list {
    display: grid;
    gap: 0.85rem;
    margin: 0 0 1rem;
}

.detail-list div {
    display: grid;
    gap: 0.2rem;
}

.detail-list dt {
    margin: 0;
    color: var(--color-muted);
    font-size: 0.85rem;
    font-weight: 600;
}

.detail-list dd {
    margin: 0;
}

.report-detail-row td {
    background: var(--color-bg);
    font-size: 0.92rem;
    padding-top: 0.35rem;
    padding-bottom: 0.85rem;
}

.report-detail-label {
    display: inline-block;
    min-width: 7rem;
    color: var(--color-muted);
    font-weight: 600;
}

.report-tree-links {
    margin-top: 0.5rem;
}

.report-card {
    margin-bottom: 1.25rem;
}

.report-card-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}

.report-card-title {
    margin: 0 0 0.35rem;
    font-size: 1.15rem;
}

.report-card-meta {
    margin: 0;
    color: var(--color-muted);
    font-size: 0.92rem;
}

.report-card-photos {
    margin-top: 1rem;
}

.report-reply-form {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--color-border);
}

.report-thread {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.report-thread-item {
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: 0.85rem 1rem;
    background: var(--color-bg);
}

.report-thread-admin {
    background: #f4faf4;
    border-color: #cfe8cf;
}

.report-thread-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
    font-size: 0.88rem;
    color: var(--color-muted);
}

.report-thread-meta strong {
    color: var(--color-text);
}

.report-thread-body {
    white-space: normal;
    line-height: 1.5;
}

.report-row-new-activity td {
    background: #fff8e6;
}

.report-activity-badge {
    display: inline-block;
    margin-left: 0.35rem;
    font-size: 0.72rem;
    vertical-align: middle;
}

.report-activity-preview {
    display: block;
    margin-top: 0.25rem;
    max-width: 18rem;
}

.storage-summary {
    margin-bottom: 1rem;
}

.storage-breakdown {
    list-style: none;
    margin: 1rem 0 0;
    padding: 0;
    display: grid;
    gap: 0.5rem;
}

.storage-breakdown li {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--color-border);
    font-size: 0.92rem;
}

.storage-breakdown li:last-child {
    border-bottom: none;
}

.protocol-notice {
    margin-top: 1.25rem;
    padding-top: 1rem;
    border-top: 1px solid var(--color-border);
    color: var(--color-muted);
    font-size: 0.82rem;
}

.protocol-notice p {
    margin: 0.15rem 0;
}

.form-group select {
    padding: 0.65rem 0.75rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    font: inherit;
    background: #fff;
}

.form-group select:focus {
    outline: 2px solid rgba(45, 106, 79, 0.25);
    border-color: var(--color-primary);
}

.form-check {
    margin-top: 0.25rem;
}

.checkbox-label {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
}

.field-hint-rich {
    line-height: 1.55;
}

.field-hint-rich strong {
    color: var(--color-text);
}

.seo-preview-details {
    margin-top: 0.75rem;
}

.seo-preview-details summary {
    cursor: pointer;
    font-weight: 600;
    margin-bottom: 0.75rem;
}

.seo-advanced-details summary {
    cursor: pointer;
    font-weight: 600;
    margin-bottom: 0.75rem;
}

.seo-fixed-rules ul {
    margin: 0.35rem 0 0;
    padding-left: 1.25rem;
}

.form-actions-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
    justify-content: flex-end;
    margin-top: 0.5rem;
}

.check-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.check-list li {
    display: grid;
    grid-template-columns: 4rem 1fr;
    gap: 0.15rem 0.75rem;
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--color-border);
}

.check-list li:last-child {
    border-bottom: none;
}

.check-list small {
    grid-column: 2;
    color: var(--color-muted);
    font-size: 0.9rem;
}

.check-ok strong {
    color: var(--color-primary-dark);
}

.check-fail strong {
    color: var(--color-error-text);
}

.debug-output {
    margin: 1rem 0 0;
    padding: 0.75rem 1rem;
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    overflow-x: auto;
    font-size: 0.85rem;
    white-space: pre-wrap;
}

.login-status {
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.form-actions {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.form-footer {
    margin: 2rem -1.5rem -1.25rem;
    padding: 1.25rem 1.5rem;
    border-top: 2px solid var(--color-border);
    background: var(--color-bg);
    border-radius: 0 0 var(--radius) var(--radius);
}

.form-footer-hint {
    margin: 0 0 1rem;
    color: var(--color-muted);
    font-size: 0.9rem;
}

.form-footer .form-actions {
    margin: 0;
}

@media (max-width: 640px) {
    .brand-text {
        display: none;
    }

    .brand-logo {
        height: 34px;
        max-width: 151px;
    }

    .header-user-email {
        display: none;
    }

    .admin-nav {
        display: none;
    }
}

.container-form-wide {
    width: var(--layout-width);
    max-width: var(--layout-width);
}

.postal-autocomplete-wrap {
    position: relative;
}

.postal-autocomplete-list {
    position: absolute;
    z-index: 30;
    top: calc(100% + 0.25rem);
    left: 0;
    right: 0;
    margin: 0;
    padding: 0.25rem 0;
    list-style: none;
    background: #fff;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    max-height: 14rem;
    overflow-y: auto;
}

.postal-autocomplete-item {
    padding: 0.55rem 0.75rem;
    cursor: pointer;
}

.postal-autocomplete-item:hover,
.postal-autocomplete-item.is-active {
    background: #eef6f0;
    color: var(--color-primary-dark);
}

.property-addresses-block {
    margin: 0 0 1.25rem;
    padding: 0.9rem 1rem 1rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    background: #fafcfb;
}

.property-addresses-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.35rem;
}

.property-addresses-rows {
    display: grid;
    gap: 0.85rem;
}

.property-address-row {
    display: grid;
    grid-template-columns:
        minmax(4.5rem, 5.5rem)
        minmax(5.5rem, 0.7fr)
        minmax(10rem, 1.8fr)
        4.25rem
        5.25rem
        minmax(7rem, 1fr);
    gap: 0.45rem 0.55rem;
    align-items: start;
    padding: 0.75rem 0.85rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    background: #fff;
}

.property-address-row--no-house {
    grid-template-columns:
        minmax(4.5rem, 5.5rem)
        minmax(5.5rem, 0.7fr)
        minmax(10rem, 2fr)
        5.25rem
        minmax(7rem, 1fr);
}

.property-address-side {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.35rem;
    padding-top: 1.55rem;
    min-width: 0;
}

.property-address-row-title {
    font-size: 0.8rem;
    line-height: 1.25;
    color: var(--color-primary-dark);
}

.property-address-row .form-group {
    margin: 0;
    min-width: 0;
}

.property-address-row .form-group label {
    font-size: 0.82rem;
}

.property-address-row input {
    width: 100%;
    max-width: 100%;
}

.property-address-field-house input,
.property-address-field-postal input {
    text-align: left;
}

.property-address-street-hint {
    margin: 0.35rem 0 0;
    font-size: 0.78rem;
    line-height: 1.35;
    color: var(--color-muted);
}

.property-address-remove-btn {
    padding: 0.2rem 0.45rem;
    font-size: 0.75rem;
}

@media (max-width: 960px) {
    .property-address-row,
    .property-address-row--no-house {
        grid-template-columns: minmax(4.5rem, 5.5rem) 1fr 1fr;
    }

    .property-address-field-street {
        grid-column: 2 / -1;
    }

    .property-address-field-house,
    .property-address-field-postal,
    .property-address-field-city {
        grid-column: auto;
    }
}

@media (max-width: 640px) {
    .property-address-section-head {
        flex-direction: column;
        align-items: stretch;
    }

    .property-address-row,
    .property-address-row--no-house {
        grid-template-columns: 1fr;
    }

    .property-address-side {
        padding-top: 0;
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
    }

    .property-address-field-street {
        grid-column: auto;
    }
}

.species-picker {
    width: 100%;
    margin-bottom: 0.5rem;
    padding: 0.65rem 0.75rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    font: inherit;
    background: #fff;
}

.species-picker:focus {
    outline: 2px solid rgba(45, 106, 79, 0.25);
    border-color: var(--color-primary);
}

.toolbar-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: flex-end;
}

.section-title {
    margin: 0 0 0.75rem;
    font-size: 1.1rem;
    color: var(--color-primary-dark);
}

.admin-management {
    display: grid;
    gap: 1rem;
}

.orphan-storage {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--color-border);
}

.orphan-cleanup-form {
    margin-top: 1rem;
}

.orphan-files-table {
    margin-top: 1rem;
}

.orphan-select-col {
    width: 2.5rem;
    text-align: center;
}

.orphan-path-cell {
    max-width: 24rem;
    word-break: break-all;
}

.orphan-cleanup-hint {
    margin-top: 0.75rem;
}

.customer-login-cell {
    min-width: 14rem;
}

.customer-login-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 0.5rem;
}

.share-link-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 0.25rem;
    font-size: 0.9rem;
}

.customer-login-item {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35rem 0.5rem;
}

.customer-login-form {
    margin: 0;
}

.customer-login-more {
    display: inline-block;
    margin-top: 0.35rem;
}

.customer-delete-section {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--color-border);
}

.field-hint {
    margin: 0;
    color: var(--color-muted);
    font-size: 0.9rem;
}

.btn-danger {
    background: #fff;
    color: var(--color-error-text);
    border-color: #f1c0c0;
}

.btn-danger:hover {
    background: var(--color-error-bg);
}

.btn-danger:disabled {
    opacity: 0.55;
    cursor: not-allowed;
    background: #fff;
}

.btn-danger:disabled:hover {
    background: #fff;
}

.btn-danger-action {
    background: #dc2626;
    color: #fff;
    border-color: #b91c1c;
    font-weight: 700;
}

.btn-danger-action:hover {
    background: #b91c1c;
    color: #fff;
    border-color: #991b1b;
}

.app-header-actions {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    flex-wrap: wrap;
}

.inline-form {
    display: inline;
}

.property-pdf-form {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
}

.property-pdf-form .input-date-compact {
    padding: 0.45rem 0.55rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    font: inherit;
    background: #fff;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.table-actions form.inline-form {
    display: inline-block;
    margin-left: 0.35rem;
}

.table-actions-stacked {
    white-space: normal;
    min-width: 12rem;
}

.table-actions-stacked .inline-form,
.table-actions-stacked .btn {
    margin: 0.15rem 0.15rem 0.15rem 0;
}

/* Super-Admin: registrierte Mandanten — kompaktere Darstellung */
.super-tenants-registered .data-table {
    font-size: 0.8rem;
}

.super-tenants-registered .data-table th {
    font-size: 0.72rem;
}

.super-tenants-registered .data-table th,
.super-tenants-registered .data-table td {
    padding: 0.4rem 0.35rem;
}

.super-tenants-registered code {
    font-size: 0.88em;
}

.super-tenants-registered .btn-sm {
    padding: 0.25rem 0.5rem;
    font-size: 0.75rem;
}

.super-tenants-registered .input-sm,
.super-tenants-registered select.input-sm {
    font-size: 0.75rem;
    padding: 0.2rem 0.35rem;
}

.super-storage-table-wrap {
    overflow-x: auto;
}

.super-storage-table {
    font-size: 0.78rem;
    min-width: 72rem;
}

.super-storage-table th,
.super-storage-table td {
    white-space: nowrap;
}

.super-storage-table th.num,
.super-storage-table td.num {
    text-align: right;
}

.super-storage-table tfoot th {
    border-top: 2px solid var(--border-color, #d8dee4);
    background: var(--surface-muted, #f6f8fa);
}

.super-storage-legacy-row td {
    color: var(--text-muted, #57606a);
}

.super-tenants-registered .badge {
    font-size: 0.7rem;
    padding: 0.1rem 0.4rem;
}

.super-tenants-registered .hint {
    font-size: 0.75rem;
}

.super-tenants-registered .field-hint {
    font-size: 0.8rem;
}

.super-tenants-registered .table-actions-stacked {
    min-width: 9rem;
}

.super-tenants-registered .table-actions-stacked .inline-form,
.super-tenants-registered .table-actions-stacked .btn {
    margin: 0.1rem 0.1rem 0.1rem 0;
}

.super-tenants-registered td a {
    word-break: break-all;
}

.super-tenants-registered .demo-reset-details {
    margin-top: 0.35rem;
}

.super-tenants-registered .demo-reset-details summary {
    cursor: pointer;
    list-style: none;
}

.super-tenants-registered .demo-reset-details summary::-webkit-details-marker {
    display: none;
}

.super-tenants-registered .demo-reset-form {
    display: grid;
    gap: 0.5rem;
    margin-top: 0.5rem;
    min-width: 14rem;
}

.offer-publish-form {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35rem;
    margin-top: 0.25rem;
}

.offer-publish-form select.input-sm {
    min-width: 11rem;
    max-width: 100%;
    font-size: 0.85rem;
    padding: 0.25rem 0.4rem;
}

.checkbox-label-compact {
    margin: 0;
    font-size: 0.9rem;
}

.offer-acceptance-form {
    margin: 0;
}

.table-detail-row td {
    background: var(--color-bg);
    font-size: 0.9rem;
    color: var(--color-muted);
}

.detail-label {
    font-weight: 600;
    color: var(--color-text);
    margin-right: 0.35rem;
}

.photo-timeline {
    display: flex;
    gap: 1rem;
    overflow-x: auto;
    padding-bottom: 0.5rem;
    scroll-snap-type: x mandatory;
}

.photo-timeline-item {
    flex: 0 0 auto;
    width: 160px;
    margin: 0;
    scroll-snap-align: start;
}

.photo-timeline-item img {
    width: 160px;
    height: 120px;
    object-fit: cover;
    border-radius: var(--radius);
    border: 1px solid var(--color-border);
    display: block;
    cursor: zoom-in;
}

.photo-timeline-item figcaption {
    margin-top: 0.35rem;
    font-size: 0.85rem;
    color: var(--color-muted);
    text-align: center;
}

.photo-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

@media (min-width: 640px) {
    .photo-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

.photo-grid-item {
    margin: 0;
}

.photo-gallery-link {
    display: block;
    text-decoration: none;
    color: inherit;
    cursor: zoom-in;
}

.photo-grid-item img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    border-radius: var(--radius);
    border: 1px solid var(--color-border);
    display: block;
    cursor: zoom-in;
}

.photo-pdf-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    min-height: 8rem;
    padding: 1rem;
    border-radius: var(--radius);
    border: 1px solid var(--color-border);
    background: var(--color-surface-muted, #f6f7f9);
    text-decoration: none;
    color: inherit;
}

.photo-pdf-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 3rem;
    height: 3rem;
    border-radius: 0.5rem;
    background: #c62828;
    color: #fff;
    font-weight: 700;
    font-size: 0.85rem;
}

.photo-pdf-name {
    text-align: center;
    font-size: 0.85rem;
    word-break: break-word;
}

.photo-grid-item figcaption {
    margin-top: 0.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.photo-grid-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: flex-start;
    margin-top: 0.35rem;
}

.photo-caption-form {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    width: 100%;
    margin-bottom: 0.35rem;
}

.photo-caption-label {
    font-size: 0.8125rem;
    color: var(--color-muted);
}

.photo-caption-form textarea {
    width: 100%;
    min-height: 3.5rem;
    resize: vertical;
    font-size: 0.875rem;
}

.plant-identify-existing-btn.is-active {
    border-color: #15803d;
    background: #f0fdf4;
    color: #166534;
}

.plant-suggestion-box {
    margin-top: 0.75rem;
}

.plant-suggestion-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.35rem;
}

.plant-identify-panel {
    margin-top: 1rem;
    padding: 1rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    background: #f8faf8;
}

.plant-identify-title {
    margin: 0 0 0.35rem;
    font-size: 1rem;
}

.plant-identify-status {
    margin-top: 0.75rem;
    padding: 0.75rem 0.9rem;
    border-radius: var(--radius);
    border: 1px solid var(--color-border);
    background: #ffffff;
    font-size: 0.95rem;
}

.plant-identify-status.is-idle {
    color: var(--color-muted);
}

.plant-identify-status.is-loading {
    border-color: #d97706;
    background: #fffbeb;
    color: #92400e;
}

.plant-identify-status.is-success {
    border-color: #15803d;
    background: #f0fdf4;
    color: #166534;
}

.plant-identify-status.is-empty {
    border-color: #64748b;
    background: #f8fafc;
    color: #334155;
}

.plant-identify-status.is-error {
    border-color: #dc2626;
    background: #fef2f2;
    color: #991b1b;
}

#groundcare-plant-identify-retry {
    margin-top: 0.75rem;
}

.photo-size-label {
    font-size: 0.8rem;
    color: var(--color-muted);
}

.photo-picker-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin: 0.75rem 0;
}

.photo-picker-status {
    margin: 0.5rem 0 0;
    color: var(--color-muted);
    font-size: 0.9rem;
}

.photo-grid-pending {
    margin-top: 1rem;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.form-group input[type="file"] {
    font: inherit;
}

.filter-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.filter-tabs .btn.is-active {
    border-color: var(--color-primary);
    background: #ecfdf5;
    color: #166534;
}

.export-textarea {
    width: 100%;
    min-height: 12rem;
    padding: 0.85rem 1rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 0.9rem;
    line-height: 1.45;
    resize: vertical;
}

@media (min-width: 768px) {
    .form-row {
        grid-template-columns: 1fr 1fr;
    }
}

.tender-revision-form {
    margin-top: 1.25rem;
    padding-top: 1rem;
    border-top: 1px solid var(--color-border);
}

.tender-round-scope .tender-scope-description {
    margin-bottom: 1rem;
    line-height: 1.55;
}

.tender-round-deadlines {
    display: grid;
    gap: 0.75rem;
    margin: 0;
}

.tender-round-deadlines dt {
    font-weight: 600;
    margin: 0;
}

.tender-round-deadlines dd {
    margin: 0.15rem 0 0;
}

.tender-pricing-summary {
    margin: 1rem 0;
}

.tender-award-form {
    margin-top: 0.5rem;
}

.tender-inline-form {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    align-items: flex-end;
    margin: 0.75rem 0 1.25rem;
}

.tender-transfer-form {
    margin-top: 0.75rem;
    max-width: 28rem;
}

.tender-property-address-lines {
    display: block;
    margin-top: 0.25rem;
}

.tender-property-address-line {
    display: block;
}

.tender-round-attachments {
    margin-top: 1rem;
}

.tender-round-attachment-preview {
    margin: 0.5rem 0 0.75rem;
    max-width: 20rem;
}

.tender-round-attachment-preview img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 0.375rem;
    border: 1px solid var(--border-color, #d8dee4);
}

.tender-internal-docs-cell {
    min-width: 14rem;
    vertical-align: top;
}

.tender-internal-upload-form {
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px solid var(--border-color, #d8dee4);
}

.tender-internal-documents {
    margin-bottom: 0.5rem;
}

.tender-round-documents-admin .tender-round-attachment-preview {
    max-width: 12rem;
}

.tender-upload-form {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color, #d8dee4);
}

.form-stack {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.form-grid {
    display: grid;
    gap: 1rem;
}

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

@media (min-width: 640px) {
    .form-grid-2 {
        grid-template-columns: 1fr 1fr;
    }
}

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

@media (min-width: 900px) {
    .form-grid-3 {
        grid-template-columns: repeat(3, 1fr);
    }
}

.form-divider {
    border: 0;
    border-top: 1px solid var(--border-color, #d9e6d9);
    margin: 1.25rem 0;
}

.form-section-subtitle {
    margin: 0 0 0.75rem;
    font-size: 1rem;
}

.nested-section {
    margin-bottom: 1.25rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color, #e8efe8);
}

.property-document-explorer {
    display: grid;
    grid-template-columns: minmax(220px, 280px) minmax(0, 1fr);
    gap: 1rem;
    align-items: stretch;
    min-height: calc(100vh - 10rem);
}

.property-document-explorer-sidebar {
    border: 1px solid var(--border-color, #d7e0d7);
    border-radius: var(--radius-md, 8px);
    background: var(--color-surface, #fff);
    padding: 0.75rem;
    position: sticky;
    top: 0.75rem;
    align-self: stretch;
    min-height: calc(100vh - 10rem);
    max-height: calc(100vh - 6rem);
    overflow: auto;
}

.property-document-explorer-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    margin-bottom: 0.75rem;
}

.property-document-explorer-status {
    margin: 0 0 0.5rem;
}

.property-document-explorer-tree,
.property-document-explorer-children {
    list-style: none;
    margin: 0;
    padding: 0;
}

.property-document-explorer-tree {
    font-size: 0.8rem;
    line-height: 1.25;
}

.property-document-explorer-children {
    padding-left: 0.95rem;
}

.property-document-explorer-node {
    margin: 0;
}

.property-document-explorer-node-row {
    display: flex;
    align-items: center;
    gap: 0.1rem;
    padding-left: calc(var(--explorer-level, 0) * 0.1rem);
}

.property-document-explorer-node-btn {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    width: 100%;
    border: 0;
    background: transparent;
    text-align: left;
    padding: 0.18rem 0.3rem;
    border-radius: 5px;
    cursor: pointer;
    color: inherit;
    font: inherit;
    font-size: inherit;
}

.property-document-explorer-node.is-document > .property-document-explorer-node-btn {
    padding-left: calc(0.4rem + 1.25rem);
}

.property-document-explorer-node.is-selected > .property-document-explorer-node-btn,
.property-document-explorer-node.is-selected > .property-document-explorer-node-row .property-document-explorer-node-btn {
    background: #e8f3ea;
    color: var(--color-primary, #2f6f3a);
}

.property-document-explorer-node-btn:hover,
.property-document-explorer-node-btn:focus-visible {
    background: #f2f6f2;
}

.property-document-explorer-twistie {
    flex: 0 0 0.95rem;
    width: 0.95rem;
    border: 0;
    background: transparent;
    cursor: pointer;
    padding: 0;
    color: #6a766c;
    line-height: 1;
    font-size: 0.7rem;
}

.property-document-explorer-twistie.is-empty {
    visibility: hidden;
}

.property-document-explorer-node.is-expanded > .property-document-explorer-node-row .property-document-explorer-twistie {
    transform: rotate(90deg);
}

.property-document-explorer-label {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.property-document-explorer-tip {
    position: fixed;
    z-index: 10050;
    max-width: min(28rem, calc(100vw - 1rem));
    padding: 0.4rem 0.55rem;
    border-radius: 6px;
    border: 1px solid #c5d0c6;
    background: #1f2933;
    color: #fff;
    font-size: 0.78rem;
    line-height: 1.35;
    box-shadow: 0 6px 18px rgba(15, 23, 20, 0.22);
    pointer-events: none;
    white-space: normal;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.property-document-explorer-tip[hidden] {
    display: none !important;
}

.property-document-explorer-icon {
    flex: 0 0 0.95rem;
    width: 0.95rem;
    height: 0.95rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: relative;
    line-height: 0;
}

.property-document-explorer-icon-svg {
    display: block;
    width: 1.1rem;
    height: 1.1rem;
}

.property-document-explorer-icon.is-folder {
    color: #d4a017;
}

.property-document-explorer-icon.is-trash {
    color: #6b7280;
}

.property-document-explorer-node.is-trash > .property-document-explorer-node-row {
    margin-top: 0.35rem;
    border-top: 1px solid rgba(0, 0, 0, 0.08);
    padding-top: 0.35rem;
}

.property-document-explorer-icon.is-file {
    color: #6a766c;
}

.property-document-explorer-icon.is-image {
    color: #2f8f4a;
}

.property-document-explorer-icon.is-pdf {
    color: #c94a4a;
}

.property-document-explorer-icon.is-email {
    color: #6a5aad;
}

.property-document-explorer-icon.is-word {
    width: 1.15rem;
    height: 1.15rem;
}

.property-document-explorer-word-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.15rem;
    height: 1.15rem;
    border-radius: 3px;
    background: #2b579a;
    color: #fff;
    font-size: 0.72rem;
    font-weight: 700;
    font-family: "Segoe UI", Calibri, Arial, sans-serif;
    line-height: 1;
    letter-spacing: -0.02em;
}

.property-document-explorer-node.is-drop-target > .property-document-explorer-node-btn,
.property-document-explorer-node.is-drop-target > .property-document-explorer-node-row {
    outline: 2px solid var(--color-primary, #2f6f3a);
    outline-offset: -2px;
    border-radius: 6px;
}

.property-document-explorer-node.is-dragging {
    opacity: 0.45;
}

.property-document-explorer-main {
    min-width: 0;
}

.property-document-explorer-doc-pane {
    border: 1px solid var(--border-color, #d7e0d7);
    border-radius: var(--radius-md, 8px);
    background: var(--color-surface, #fff);
    padding: 1rem;
    min-height: 24rem;
}

.property-document-explorer-doc-head {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.property-document-explorer-doc-title {
    margin: 0;
    font-size: 1.1rem;
}

.property-document-explorer-doc-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
}

.property-document-explorer-doc-preview {
    min-height: 20rem;
    background: #f7f9f7;
    border-radius: 6px;
    overflow: auto;
}

.property-document-explorer-doc-image {
    display: block;
    max-width: 100%;
    height: auto;
    margin: 0 auto;
}

.property-document-explorer-doc-frame {
    width: 100%;
    min-height: 28rem;
    border: 0;
    background: #fff;
}

.property-document-explorer-doc-frame.is-pdf {
    min-height: 36rem;
    height: min(70vh, 48rem);
}

.property-document-pdfjs-host,
.property-document-pdfjs {
    display: flex;
    flex-direction: column;
    min-height: min(70vh, 48rem);
    background: #fff;
}

.property-document-pdfjs-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.45rem;
    padding: 0.55rem 0.75rem;
    border-bottom: 1px solid #d5ddd6;
    background: #f3f6f3;
}

.property-document-pdfjs-page-label {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.9rem;
}

.property-document-pdfjs-page-input {
    width: 4.2rem;
    padding: 0.2rem 0.35rem;
}

.property-document-pdfjs-status {
    margin: 0.4rem 0.75rem 0;
}

.property-document-pdfjs-status.is-error {
    color: #8a1f1f;
}

.property-document-pdfjs-scroller {
    flex: 1 1 auto;
    overflow: auto;
    min-height: 28rem;
    max-height: min(70vh, 48rem);
    padding: 0.75rem;
    background: #e8ece8;
}

.property-document-pdfjs-page {
    display: flex;
    justify-content: center;
    margin: 0 auto 0.85rem;
}

.property-document-pdfjs-canvas {
    display: block;
    max-width: 100%;
    height: auto;
    background: #fff;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.12);
}

.property-document-pdfjs-placeholder {
    width: min(100%, 720px);
    min-height: 240px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f7f9f7;
    color: #5a6b5c;
    border: 1px dashed #c5d0c6;
}

.property-document-explorer-attach-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.4rem;
    padding: 0.65rem 0.75rem;
    margin-bottom: 0.5rem;
    background: #eef2ef;
    border: 1px solid #d8dee4;
    border-radius: 6px;
}

.property-document-explorer-attach-label {
    font-size: 0.8rem;
    font-weight: 600;
    color: #52606d;
    margin-right: 0.25rem;
}

.property-document-explorer-attach-chip {
    appearance: none;
    border: 1px solid #c5ced1;
    border-radius: 999px;
    background: #fff;
    color: #1f2933;
    font: inherit;
    font-size: 0.8rem;
    padding: 0.25rem 0.65rem;
    cursor: pointer;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.property-document-explorer-attach-chip:hover,
.property-document-explorer-attach-chip.is-active {
    border-color: #2f6fed;
    background: #edf3ff;
    color: #1a4fb8;
}

.property-document-explorer-attach-chip.is-mail {
    border-style: dashed;
}

.property-document-explorer-attach-count {
    margin-left: 0.35rem;
    font-size: 0.75rem;
    color: #6b7280;
}

.property-document-explorer-doc-html {
    padding: 1rem 1.25rem;
    background: #fff;
}

.property-document-explorer-doc-text {
    margin: 0;
    padding: 1rem 1.25rem;
    background: #fff;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
    font-size: 0.85rem;
    line-height: 1.45;
    white-space: pre-wrap;
    word-break: break-word;
    overflow: auto;
    max-height: min(70vh, 40rem);
}

.property-document-explorer-template .property-document-explorer-folder-pane {
    padding: 1.25rem;
}

.property-document-explorer-template-heading {
    margin: 0 0 0.75rem;
    font-size: 1.1rem;
}

@media (max-width: 900px) {
    .property-document-explorer {
        grid-template-columns: 1fr;
    }

    .property-document-explorer {
        min-height: 0;
    }

    .property-document-explorer-sidebar {
        position: static;
        min-height: 22rem;
        max-height: 40vh;
    }
}

.property-documents-root {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    outline: none;
}

.property-documents-dropzone {
    border: 2px dashed var(--border-color, #c5d0c5);
    border-radius: var(--radius-md, 8px);
    background: var(--color-surface-muted, #f8faf9);
    cursor: pointer;
    transition: border-color 0.15s ease, background-color 0.15s ease;
}

.property-documents-dropzone.is-dragover,
.property-documents-root:focus .property-documents-dropzone {
    border-color: var(--color-primary, #2f6f3a);
    background: #f2f8f2;
}

.property-documents-dropzone-inner {
    padding: 1.5rem;
    text-align: center;
}

.property-documents-dropzone-inner p {
    margin: 0.5rem 0 1rem;
    color: var(--color-text-muted, #5f6b63);
}

.property-documents-hint {
    margin: 0;
}

.property-documents-status {
    padding: 0.75rem 1rem;
    border-radius: var(--radius-md, 8px);
    background: #fff4f4;
    color: #8a1f1f;
}

.property-documents-list {
    display: grid;
    gap: 1rem;
}

.property-documents-list > .property-document-item.is-folder-filtered-out,
.property-documents-list > .property-email-group.is-folder-filtered-out,
.property-documents-list > .property-document-item[hidden],
.property-documents-list > .property-email-group[hidden] {
    display: none !important;
}

.property-document-item {
    display: grid;
    grid-template-columns: 8rem minmax(0, 1fr);
    gap: 1rem;
    padding: 1rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md, 8px);
    background: var(--color-surface-muted, #f8faf9);
}

.property-document-preview {
    min-width: 0;
    max-width: 8rem;
}

.property-document-preview img,
.property-document-preview .photo-gallery-link img {
    display: block;
    width: 100%;
    max-width: 8rem;
    height: 6rem;
    object-fit: cover;
    border-radius: 0.375rem;
    border: 1px solid var(--border-color, #d8dee4);
    cursor: zoom-in;
}

.property-document-word-actions {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0.35rem;
    min-height: 6rem;
    justify-content: center;
}

.property-document-word-actions .property-document-file-link {
    min-height: 0;
    flex: 1;
}

.property-docx-preview-overlay {
    position: fixed;
    inset: 0;
    z-index: 1200;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    background: rgba(15, 23, 42, 0.55);
}

.property-docx-preview-overlay[hidden] {
    display: none !important;
}

.property-docx-preview-dialog {
    width: min(56rem, 100%);
    max-height: min(90vh, 52rem);
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    padding: 1rem 1.1rem 1.1rem;
    border-radius: 0.75rem;
    background: #fff;
    box-shadow: 0 18px 50px rgba(15, 23, 42, 0.28);
}

.property-docx-preview-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
}

.property-docx-preview-title {
    margin: 0;
    font-size: 1.05rem;
    line-height: 1.3;
    word-break: break-word;
}

.property-docx-preview-status {
    margin: 0;
}

.property-docx-preview-body {
    overflow: auto;
    flex: 1 1 auto;
    min-height: 12rem;
    padding: 1rem 1.1rem;
    border: 1px solid #e2e8f0;
    border-radius: 0.5rem;
    background: #f8fafc;
    line-height: 1.55;
}

.property-docx-preview-body h1,
.property-docx-preview-body h2,
.property-docx-preview-body h3 {
    margin: 0 0 0.65rem;
}

.property-docx-preview-body p {
    margin: 0 0 0.75rem;
}

.property-docx-preview-note {
    margin: 0;
}

.property-docx-editor-overlay {
    position: fixed;
    inset: 0;
    z-index: 1210;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    background: rgba(15, 23, 42, 0.55);
}

.property-docx-editor-overlay[hidden] {
    display: none !important;
}

.property-docx-editor-dialog {
    width: min(56rem, 100%);
    max-height: min(92vh, 56rem);
    overflow: auto;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    padding: 1rem 1.1rem 1.1rem;
    border-radius: 0.75rem;
    background: #fff;
    box-shadow: 0 18px 50px rgba(15, 23, 42, 0.28);
}

.property-docx-editor-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
}

.property-docx-editor-heading {
    margin: 0;
    font-size: 1.05rem;
}

.property-documents-word-warning {
    margin: 0 0 1rem;
}

.property-documents-word-warning p {
    margin: 0.4rem 0 0;
}

.property-documents-help-word-warning {
    margin: 0 0 1rem;
    padding: 0;
    color: #b42318;
    font-size: 0.95rem;
    line-height: 1.45;
}

.property-documents-help-word-warning strong {
    color: #912018;
}

.property-docx-editor-page .property-docx-editor-host {
    margin-top: 0.5rem;
    min-height: 480px;
}

.property-docx-editor-page .property-docx-tinymce-input {
    width: 100%;
    min-height: 480px;
    box-sizing: border-box;
}

.property-docx-editor-page .tox-tinymce {
    margin-top: 0;
}

.property-docx-editor-save-mode {
    margin: 0.75rem 0 0;
    padding: 0.65rem 0.75rem;
    border: 1px solid #d9e6d9;
    border-radius: 8px;
}

.property-docx-editor-save-mode[hidden] {
    display: none !important;
}

.property-docx-editor-save-mode legend {
    padding: 0 0.25rem;
    font-weight: 600;
}

.property-docx-editor-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.75rem;
}

.property-document-version-meta {
    margin: 0.15rem 0 0.35rem;
}

.property-document-version-history {
    margin: 0.35rem 0 0.6rem;
}

.property-document-version-list {
    margin: 0.35rem 0 0;
    padding-left: 1.1rem;
}

.property-document-version-list li {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 0.75rem;
    align-items: baseline;
    margin-bottom: 0.25rem;
}

.property-docx-editor-status {
    margin: 0;
}

.property-document-file-link {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 6rem;
    padding: 0.75rem;
    border-radius: 0.375rem;
    border: 1px solid var(--border-color, #d8dee4);
    background: #fff;
    text-align: center;
    font-weight: 600;
}

.property-document-name {
    font-weight: 600;
    margin-bottom: 0.75rem;
    word-break: break-word;
}

@media (max-width: 640px) {
    .property-document-item {
        grid-template-columns: 1fr;
    }
}

.property-document-attachment-compact {
    margin-top: 0.5rem;
}

.property-document-attachment-compact .property-documents-dropzone-inner {
    padding: 1rem;
}

.property-document-attachment-compact .property-documents-dropzone-inner p {
    margin: 0 0 0.75rem;
    font-size: 0.9rem;
}

.property-document-attachment-hint {
    margin: 0 0 0.5rem;
}

.property-document-attachment-compact .property-document-item {
    grid-template-columns: 4.5rem 1fr;
    padding: 0.75rem;
}

.property-document-attachment-compact .property-document-preview img,
.property-document-attachment-compact .property-document-file-link {
    min-height: 4rem;
    height: 4rem;
}

.property-document-source {
    margin: -0.35rem 0 0.5rem;
}

.property-email-group {
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md, 8px);
    background: var(--color-surface-muted, #f8faf9);
    padding: 1rem;
    display: grid;
    gap: 0.75rem;
}

.property-email-group-main {
    margin: 0;
}

.property-email-group-attachments {
    border-top: 1px solid var(--border-color, #d8dee4);
    padding-top: 0.75rem;
}

.property-email-group-attachments-title {
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.property-email-attachment-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 0.5rem;
}

.property-email-attachment-item {
    display: grid;
    grid-template-columns: 3.5rem 1fr;
    gap: 0.75rem;
    align-items: center;
    padding: 0.5rem 0.75rem;
    border: 1px solid var(--border-color, #e5ebe7);
    border-radius: 0.375rem;
    background: #fff;
}

.property-email-attachment-preview img,
.property-email-attachment-preview .property-document-file-link {
    min-height: 2.75rem;
    height: 2.75rem;
}

.property-document-follow-up-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.4rem;
    margin: 0.35rem 0 0.5rem;
}

.property-document-follow-up-btn.is-due,
.property-document-follow-up-chip.is-due {
    border-color: #d97706;
    color: #92400e;
    background: #fffbeb;
}

.property-document-follow-up-chip {
    font-size: 0.8rem;
    color: #52606d;
}

.property-email-attachment-name {
    font-weight: 500;
    word-break: break-word;
}

.property-email-group-actions {
    display: flex;
    justify-content: flex-end;
}

.checkbox-inline {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0.35rem 0;
}

.field {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.field-label {
    font-weight: 600;
    font-size: 0.95rem;
}

.input,
.field .input,
.field textarea,
.form-group .input,
.form-group textarea,
.form-group input:not([type="checkbox"]):not([type="radio"]):not([type="file"]) {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    padding: 0.65rem 0.75rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    font: inherit;
    background: #fff;
}

.field textarea,
.form-group textarea {
    resize: vertical;
}

.input:focus,
.field .input:focus,
.field textarea:focus,
.form-group textarea:focus,
.form-group input:focus {
    outline: 2px solid rgba(45, 106, 79, 0.25);
    border-color: var(--color-primary);
}

.checkbox-fieldset {
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    padding: 1rem 1.25rem;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

#vendor-invite-section[hidden] {
    display: none !important;
}

#vendor-list-container {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.checkbox-row {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    width: 100%;
    margin: 0;
    cursor: pointer;
}

.checkbox-row input[type="checkbox"] {
    flex-shrink: 0;
    margin-top: 0.15rem;
}

.checkbox-fieldset-legend {
    font-weight: 600;
    padding: 0 0.35rem;
}

.checkbox-fieldset .form-group {
    width: 100%;
    margin: 0;
}

.checkbox-label-block {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    font-weight: 600;
    width: 100%;
}

.checkbox-label-block input[type="checkbox"] {
    flex-shrink: 0;
    margin-top: 0.15rem;
}

.simple-list {
    list-style: none;
    padding: 0;
    margin: 0.5rem 0 1rem;
}

.simple-list li {
    display: flex;
    gap: 0.5rem;
    align-items: center;
    padding: 0.35rem 0;
    border-bottom: 1px solid var(--color-border);
}

.subsection-title {
    font-size: 1rem;
    margin: 1rem 0 0.5rem;
}

.container.narrow {
    max-width: 40rem;
}

.site-footer {
    border-top: 1px solid var(--color-border);
    background: var(--color-surface);
    padding: 1rem 1rem 0.85rem;
    margin-top: 2rem;
    font-size: 0.875rem;
    color: var(--color-muted);
}

.site-footer-inner {
    max-width: 72rem;
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem 1.25rem;
    align-items: flex-end;
    justify-content: space-between;
}

.site-footer-copy {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    min-width: 0;
}

.site-footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--color-text);
    font-weight: 600;
}

.site-footer-brand .site-footer-company {
    margin: 0;
    font-size: 1rem;
    font-weight: 600;
    color: var(--color-text);
}

.site-footer-product {
    font-size: 1rem;
}

.site-footer-company {
    margin: 0.1rem 0 0;
    color: var(--color-text);
    font-weight: 600;
}

.site-footer-claim {
    margin: 0;
    font-style: italic;
    color: var(--color-primary-dark);
}

.site-footer-copyright {
    margin: 0.15rem 0 0;
    font-size: 0.8125rem;
}

.site-footer-platform {
    margin: 0;
    max-width: 42rem;
    font-size: 0.8125rem;
    line-height: 1.35;
}

.site-footer-platform a,
.site-footer-platform-link,
.site-footer-platform a:visited,
.site-footer-platform-link:visited {
    color: inherit;
    text-decoration: underline;
    text-underline-offset: 0.12em;
}

.site-footer-platform a:hover,
.site-footer-platform-link:hover {
    color: inherit;
    opacity: 0.85;
}

.platform-footer-preview .site-footer-platform {
    margin-top: 0.35rem;
}

.send-progress-overlay {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    background: rgba(15, 23, 42, 0.45);
}

.send-progress-overlay[hidden] {
    display: none !important;
}

body.send-progress-active {
    overflow: hidden;
}

.send-progress-panel {
    width: min(100%, 22rem);
    padding: 1.5rem 1.75rem;
    border-radius: var(--radius);
    background: #ffffff;
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.18);
    text-align: center;
}

.send-progress-spinner {
    width: 2.5rem;
    height: 2.5rem;
    margin: 0 auto 1rem;
    border: 3px solid #e2e8f0;
    border-top-color: var(--color-primary, #15803d);
    border-radius: 50%;
    animation: send-progress-spin 0.85s linear infinite;
}

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

.send-progress-title {
    margin: 0;
    font-weight: 600;
    color: var(--color-text);
    line-height: 1.45;
}

.send-progress-message {
    margin: 0;
    color: var(--color-text);
    line-height: 1.45;
}

.send-progress-detail {
    margin: 0.5rem 0 0;
    font-size: 0.875rem;
    color: var(--color-muted);
}

.send-progress-detail[hidden] {
    display: none;
}

.input-mono {
    font-family: Consolas, 'Courier New', monospace;
    font-size: 0.9rem;
}

.site-footer-logo {
    width: 28px;
    height: 28px;
    object-fit: contain;
    flex-shrink: 0;
}

.site-footer a {
    color: var(--color-primary);
    text-decoration: none;
}

.site-footer a:hover {
    text-decoration: underline;
}

.gps-acquire-modal {
    position: fixed;
    inset: 0;
    z-index: 12000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

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

.gps-acquire-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.35);
}

.gps-acquire-dialog {
    position: relative;
    width: min(100%, 24rem);
    margin: 0;
    z-index: 1;
}

.gps-acquire-quality {
    font-weight: 600;
    margin: 0.75rem 0;
}

.gps-acquire-quality-good {
    color: #1b4332;
}

.gps-acquire-quality-medium {
    color: #9a6700;
}

.gps-acquire-quality-bad,
.gps-acquire-quality-reject {
    color: #8a1c1c;
}

.gps-acquire-list {
    list-style: none;
    margin: 0.25rem 0 0;
    padding: 0;
    max-height: 8rem;
    overflow: auto;
}

.gps-acquire-list li {
    padding: 0.2rem 0;
    border-bottom: 1px solid var(--color-border);
    font-variant-numeric: tabular-nums;
}

.gps-acquire-actions {
    display: flex;
    gap: 0.5rem;
    justify-content: flex-end;
    margin-top: 1rem;
}

body.photo-lightbox-open {
    overflow: hidden;
}

.photo-lightbox {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: center;
    background: rgba(15, 23, 42, 0.94);
    padding: 1rem;
}

.photo-lightbox[hidden] {
    display: none !important;
}

.photo-lightbox-stage {
    position: relative;
    flex: 1 1 auto;
    min-height: 0;
    width: 100%;
    display: flex;
    align-items: stretch;
    justify-content: flex-start;
    overflow: hidden;
    touch-action: none;
    user-select: none;
    -webkit-user-select: none;
}

.photo-lightbox-stage-swipeable {
    cursor: grab;
}

.photo-lightbox-stage-dragging {
    cursor: grabbing;
}

.photo-lightbox-track {
    display: flex;
    height: 100%;
    flex: 0 0 auto;
    align-items: stretch;
    transition: transform 0.22s ease;
    will-change: transform;
}

.photo-lightbox-slide {
    flex: 0 0 auto;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 3.5rem;
    box-sizing: border-box;
}

.photo-lightbox-slide img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: var(--radius);
    box-shadow: 0 18px 48px rgba(0, 0, 0, 0.35);
    user-select: none;
    -webkit-user-drag: none;
}

.photo-lightbox-close,
.photo-lightbox-nav {
    position: absolute;
    z-index: 2;
    border: 0;
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    cursor: pointer;
    line-height: 1;
    transition: background 0.15s ease;
}

.photo-lightbox-close:hover,
.photo-lightbox-nav:hover {
    background: rgba(255, 255, 255, 0.22);
}

.photo-lightbox-close {
    top: 1rem;
    right: 1rem;
    width: 2.75rem;
    height: 2.75rem;
    border-radius: 999px;
    font-size: 1.75rem;
}

.photo-lightbox-nav {
    top: 50%;
    transform: translateY(-50%);
    width: 2.75rem;
    height: 2.75rem;
    border-radius: 999px;
    font-size: 2rem;
}

.photo-lightbox-prev {
    left: 1rem;
}

.photo-lightbox-next {
    right: 1rem;
}

.photo-lightbox-counter {
    flex: 0 0 auto;
    margin: 0.75rem 0 0;
    text-align: center;
    color: rgba(255, 255, 255, 0.88);
    font-size: 0.95rem;
}

.photo-lightbox-date {
    flex: 0 0 auto;
    margin: 0.25rem 0 0;
    text-align: center;
    color: rgba(255, 255, 255, 0.75);
    font-size: 0.75rem;
}

@media (max-width: 640px) {
    .photo-lightbox-slide {
        padding: 0 0.5rem;
    }

    .photo-lightbox-nav {
        width: 2.35rem;
        height: 2.35rem;
        font-size: 1.6rem;
    }

    .photo-lightbox-prev {
        left: 0.5rem;
    }

    .photo-lightbox-next {
        right: 0.5rem;
    }
}

.trade-type-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1rem;
}

.trade-type-card {
    display: block;
    text-decoration: none;
    color: inherit;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.trade-type-card:hover {
    border-color: var(--color-primary);
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
}

.trade-type-card-title {
    margin: 0 0 0.5rem;
    font-size: 1.05rem;
    line-height: 1.35;
}

.trade-type-card-meta {
    margin: 0;
    color: var(--color-muted);
    font-size: 0.92rem;
}

.trade-rating {
    white-space: nowrap;
    color: #b45309;
    letter-spacing: 0.05em;
}

/* --- App shell redesign (Header, Footer, Navigation) --- */

.app-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(8px);
    border-bottom: 1px solid var(--color-border);
    box-shadow: var(--shadow);
}

.app-header-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.85rem 0 0.65rem;
    min-width: 0;
}

.app-brand {
    display: inline-flex;
    align-items: center;
    gap: 0.85rem;
    text-decoration: none;
    color: inherit;
    min-width: 0;
}

.app-brand-logo {
    height: 44px;
    width: auto;
    max-width: 220px;
    object-fit: contain;
    flex-shrink: 0;
}

.app-brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
    min-width: 0;
}

.app-brand-text strong {
    font-size: 1.1rem;
    color: var(--color-primary-dark);
}

.app-brand-text small {
    font-size: 0.82rem;
    color: var(--color-muted);
}

.app-access-kind {
    color: var(--color-primary-dark);
    font-weight: 600;
}

.access-kind-panel {
    margin: 0 0 1.25rem;
    padding: 0.9rem 1rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    background: linear-gradient(180deg, #ffffff 0%, var(--color-primary-soft) 100%);
}

.access-kind-panel--superadmin {
    background: linear-gradient(180deg, #ffffff 0%, #e8f0ff 100%);
    border-color: #c7d8f8;
}

.access-kind-label {
    display: block;
    font-weight: 700;
    color: var(--color-primary-dark);
    line-height: 1.35;
}

.access-kind-description,
.access-kind-subtype {
    margin: 0.45rem 0 0;
    font-size: 0.9rem;
    color: var(--color-muted);
    line-height: 1.45;
}

.access-kind-subtype {
    font-size: 0.82rem;
}

.badge-access {
    background: var(--color-primary-soft);
    color: var(--color-primary-dark);
}

.app-header-actions {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    flex-wrap: nowrap;
    justify-content: flex-end;
    flex-shrink: 0;
}

.app-user-menu {
    position: relative;
}

.app-user-menu > summary {
    list-style: none;
}

.app-user-menu > summary::-webkit-details-marker {
    display: none;
}

.app-user-menu-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    padding: 0;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    background: var(--color-surface);
    color: var(--color-primary-dark);
    cursor: pointer;
    transition: background 0.15s ease, border-color 0.15s ease;
}

.app-user-menu-toggle:hover,
.app-user-menu[open] > .app-user-menu-toggle {
    background: var(--color-primary-soft);
    border-color: #b7d8c2;
}

.app-burger {
    display: inline-flex;
    flex-direction: column;
    justify-content: center;
    gap: 0.28rem;
    width: 1.15rem;
}

.app-burger span {
    display: block;
    height: 2px;
    width: 100%;
    border-radius: 2px;
    background: currentColor;
}

.app-user-menu-panel {
    position: absolute;
    top: calc(100% + 0.4rem);
    right: 0;
    z-index: 120;
    min-width: 15.5rem;
    max-width: min(20rem, calc(100vw - 1.5rem));
    padding: 0.65rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    background: var(--color-surface);
    box-shadow: var(--shadow);
    display: grid;
    gap: 0.35rem;
}

.app-user-menu-meta {
    display: grid;
    gap: 0.4rem;
    padding: 0.35rem 0.5rem 0.55rem;
    border-bottom: 1px solid var(--color-border);
    margin-bottom: 0.15rem;
}

.app-user-email {
    color: var(--color-text);
    font-size: 0.92rem;
    font-weight: 600;
    word-break: break-word;
}

.app-user-menu-link {
    display: block;
    padding: 0.55rem 0.65rem;
    border-radius: 8px;
    color: var(--color-primary-dark);
    text-decoration: none;
    font-size: 0.92rem;
    font-weight: 600;
}

.app-user-menu-link:hover {
    background: var(--color-primary-soft);
}

.app-user-menu-link--danger {
    color: var(--color-error-text);
}

.app-user-menu-link--danger:hover {
    background: var(--color-error-bg);
}

.app-user-menu-link--soon {
    opacity: 0.65;
    cursor: default;
    pointer-events: none;
}

.app-user-menu-link--soon small {
    font-weight: 500;
    color: var(--color-muted);
}

.app-nav-compact {
    display: flex;
    align-items: stretch;
    gap: 0.45rem;
    overflow-x: auto;
    padding: 0.35rem 0 0.75rem;
    scrollbar-width: thin;
}

.app-nav-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.45rem 0.75rem;
    border: 1px solid var(--color-border);
    border-radius: 999px;
    background: var(--color-surface);
    color: var(--color-primary-dark);
    text-decoration: none;
    font-size: 0.88rem;
    font-weight: 600;
    white-space: nowrap;
    flex: 0 0 auto;
    transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.app-nav-chip:hover {
    border-color: var(--color-primary);
    background: var(--color-primary-soft);
}

.app-nav-chip.is-active {
    background: var(--color-primary);
    border-color: var(--color-primary);
    color: #fff;
}

.app-nav-icon {
    display: inline-flex;
    width: 1.1rem;
    height: 1.1rem;
    flex-shrink: 0;
}

.app-nav-icon svg {
    width: 100%;
    height: 100%;
}

.app-nav-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    width: auto;
    min-width: 1.35rem;
    height: 1.35rem;
    padding: 0 0.28rem;
    border-radius: 999px; /* 1-stellig ≈ Kreis, mehrstellig = Kapsel links/rechts rund */
    background: #dc2626;
    color: #fff;
    font-size: 0.72rem;
    font-weight: 700;
    line-height: 1;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

/* Ab 2 Stellen: etwas mehr seitliches Polster → klar abgerundetes Rechteck */
.app-nav-badge.is-wide {
    min-width: 1.7rem;
    padding: 0 0.45rem;
}

.app-nav-chip.is-active .app-nav-badge {
    background: #fff;
    color: var(--color-primary-dark);
}

.app-nav-tiles {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(11.5rem, 1fr));
    gap: 0.85rem;
    margin-top: 1rem;
}

.app-nav-tile {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    min-height: 8.5rem;
    padding: 1rem 1rem 0.85rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    background: var(--color-surface);
    box-shadow: var(--shadow);
    text-decoration: none;
    color: inherit;
    transition: transform 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

.app-nav-tile:hover {
    transform: translateY(-2px);
    border-color: var(--color-primary);
}

.app-nav-tile.is-disabled {
    opacity: 0.72;
    cursor: default;
    pointer-events: none;
    background: #f4f6f5;
}

.app-nav-tile.is-active {
    border-color: var(--color-primary);
    background: linear-gradient(180deg, #ffffff 0%, var(--color-primary-soft) 100%);
}

.app-module-group {
    margin-top: 1.5rem;
}

.app-module-group:first-of-type {
    margin-top: 0.5rem;
}

.app-module-group-title {
    margin: 0 0 0.65rem;
    font-size: 0.95rem;
    color: var(--color-primary-dark);
}

.app-module-subgroup {
    margin-top: 1rem;
}

.app-module-subgroup:first-of-type {
    margin-top: 0.75rem;
}

.app-module-subgroup-title {
    margin: 0 0 0.5rem;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--color-text);
}

.app-module-subgroup-hint {
    margin: 0;
}

.app-module-status {
    display: inline-block;
    margin-top: 0.15rem;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    color: var(--color-muted);
}

.app-nav-tile .app-nav-icon {
    width: 1.65rem;
    height: 1.65rem;
    color: var(--color-primary-dark);
}

/* Alias: gleiche Icon-Größe wie Dashboard (falls irgendwo noch app-nav-tile-icon steht) */
.app-nav-tile .app-nav-tile-icon {
    display: inline-flex;
    width: 1.65rem;
    height: 1.65rem;
    flex-shrink: 0;
    color: var(--color-primary-dark);
}

.app-nav-tile .app-nav-tile-icon svg {
    width: 100%;
    height: 100%;
}

.app-nav-tile-label {
    font-weight: 700;
    color: var(--color-primary-dark);
    line-height: 1.25;
}

.app-nav-tile-desc {
    font-size: 0.82rem;
    color: var(--color-muted);
    line-height: 1.35;
}

.app-nav-tile .app-nav-badge {
    position: absolute;
    top: 0.65rem;
    right: 0.65rem;
}

.app-nav-tile .app-nav-badges {
    position: absolute;
    top: 0.55rem;
    right: 0.55rem;
    display: flex;
    flex-direction: row-reverse;
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 0.25rem;
    max-width: 7.5rem;
}

.app-nav-tile .app-nav-badges .app-nav-badge {
    position: static;
}

.app-nav-badge.is-overdue {
    background: #dc2626;
}

.app-nav-badge.is-today {
    background: #2563eb;
}

.app-nav-badge.is-upcoming {
    background: #16a34a;
}

.app-home-intro {
    margin-bottom: 0.25rem;
}

.module-icons-table .module-icon-picker {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    min-width: 14rem;
}

.module-icon-preview {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    border-radius: 8px;
    background: var(--color-primary-soft);
    color: var(--color-primary-dark);
}

.module-icon-preview .app-nav-icon {
    width: 1.35rem;
    height: 1.35rem;
}

.module-icon-select {
    min-width: 10rem;
    max-width: 100%;
}

.module-icon-current-label {
    display: block;
    max-width: 12rem;
}

.module-icon-current-label-de {
    display: block;
    color: var(--color-text);
    font-weight: 600;
}

.module-icon-current-label-sub {
    display: block;
    margin-top: 0.1rem;
    color: var(--color-muted);
    font-size: 0.78rem;
}

.module-icon-lib-thumb,
.module-icon-fa-thumb {
    width: 1.35rem;
    height: 1.35rem;
    object-fit: contain;
    display: block;
}

.app-nav-icon-lib-wrap,
.app-nav-icon-fa-wrap {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.module-icon-fa-svg,
.module-icon-lucide-svg {
    width: 100%;
    height: 100%;
    display: block;
}

body.module-icon-overlay-open {
    overflow: hidden;
}

.module-icon-overlay {
    position: fixed;
    inset: 0;
    z-index: 1200;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.module-icon-overlay[hidden] {
    display: none !important;
}

.module-icon-overlay-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 20, 0.45);
}

.module-icon-overlay-panel {
    position: relative;
    width: min(960px, 100%);
    max-height: min(85vh, 820px);
    display: flex;
    flex-direction: column;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.module-icon-overlay-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem 1.1rem 0.75rem;
    border-bottom: 1px solid var(--color-border);
}

.module-icon-overlay-header h2 {
    margin: 0;
    font-size: 1.15rem;
}

.module-icon-overlay-subtitle {
    margin: 0.25rem 0 0;
    color: var(--color-muted);
    font-size: 0.85rem;
}

.module-icon-overlay-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    align-items: center;
    padding: 0.85rem 1.1rem;
    border-bottom: 1px solid var(--color-border);
}

.module-icon-search {
    flex: 1 1 14rem;
    min-width: 12rem;
    padding: 0.55rem 0.75rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
}

.module-icon-tabs {
    display: inline-flex;
    gap: 0.35rem;
    flex-wrap: wrap;
}

.module-icon-tab {
    border: 1px solid var(--color-border);
    background: #fff;
    color: var(--color-primary-dark);
    border-radius: 999px;
    padding: 0.35rem 0.8rem;
    cursor: pointer;
    font-size: 0.85rem;
}

.module-icon-tab.is-active {
    background: var(--color-primary);
    border-color: var(--color-primary);
    color: #fff;
}

.module-icon-grid-wrap {
    overflow: auto;
    padding: 0.85rem 1rem 1rem;
}

.module-icon-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(7.5rem, 1fr));
    gap: 0.65rem;
}

.module-icon-choice {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.35rem;
    min-height: 7.25rem;
    padding: 0.65rem 0.45rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    background: #fff;
    cursor: pointer;
    transition: border-color 0.15s ease, transform 0.15s ease;
}

.module-icon-choice:hover {
    border-color: var(--color-primary);
    transform: translateY(-1px);
}

.module-icon-choice .app-nav-icon {
    width: 1.75rem;
    height: 1.75rem;
    color: var(--color-primary-dark);
}

.module-icon-choice-label {
    font-size: 0.76rem;
    line-height: 1.25;
    text-align: center;
    color: var(--color-text);
    font-weight: 600;
    word-break: break-word;
}

.module-icon-choice-label-sub {
    font-size: 0.68rem;
    line-height: 1.2;
    text-align: center;
    color: var(--color-muted);
    word-break: break-word;
}

.module-icon-grid-empty {
    grid-column: 1 / -1;
    margin: 0;
    color: var(--color-muted);
}

.form-actions-top {
    margin-bottom: 1rem;
}

.app-login {
    max-width: min(28rem, var(--layout-width));
}

.app-login .card {
    margin-top: 0;
}

.app-footer {
    border-top: 1px solid var(--color-border);
    background: var(--color-surface);
    margin-top: 1rem;
    padding: 0.35rem 0;
    font-size: 0.75rem;
    color: var(--color-muted);
}

.app-footer--slim {
    margin-top: 0.75rem;
}

.app-footer-slim-line {
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 0.35rem 0.45rem;
    line-height: 1.2;
    text-align: center;
}

.app-footer-slim-sep {
    opacity: 0.55;
}

.app-footer-slim-line a,
.app-footer-slim-line a:visited {
    color: var(--color-primary-dark);
    text-decoration: none;
    font-weight: 600;
}

.app-footer-slim-line a:hover {
    text-decoration: underline;
}

.app-footer-slim-version {
    opacity: 0.8;
}

.app-footer-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 1rem 2rem;
    align-items: end;
}

.app-footer-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.app-footer-logo {
    width: 32px;
    height: 32px;
    object-fit: contain;
    flex-shrink: 0;
}

.app-footer-company {
    display: block;
    color: var(--color-text);
    font-size: 1rem;
}

.app-footer-product {
    margin: 0.1rem 0 0;
    color: var(--color-muted);
    font-size: 0.85rem;
}

.app-footer-claim {
    margin: 0.65rem 0 0;
    font-style: italic;
    color: var(--color-primary-dark);
}

.app-footer-platform {
    margin: 0.35rem 0 0;
    max-width: 42rem;
    font-size: 0.8125rem;
    line-height: 1.35;
}

.app-footer-platform a,
.app-footer-platform a:visited {
    color: inherit;
    text-decoration: underline;
}

.app-footer-meta {
    text-align: right;
}

.app-footer-copyright {
    margin: 0;
    font-size: 0.8125rem;
}

.app-footer-version {
    display: inline-block;
    margin-top: 0.35rem;
    color: var(--color-primary);
    text-decoration: none;
    font-weight: 600;
}

.app-footer-version:hover {
    text-decoration: underline;
}

@media (max-width: 768px) {
    .app-brand-text small {
        display: none;
    }

    .app-footer-grid {
        grid-template-columns: 1fr;
    }

    .app-footer-meta {
        text-align: left;
    }

    .app-nav-tiles {
        grid-template-columns: repeat(auto-fill, minmax(9.5rem, 1fr));
    }
}

/* Baumaufnahme — Sektions-Accordion */
.tree-aufnahme-page .tree-aufnahme-intro {
    margin-bottom: 1rem;
}

.tree-aufnahme-sections {
    display: grid;
    gap: 0.75rem;
}

.tree-aufnahme-section {
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md, 0.5rem);
    background: var(--color-surface, #fff);
    overflow: hidden;
}

.tree-aufnahme-section-toggle {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    width: 100%;
    margin: 0;
    padding: 0.85rem 1rem;
    border: 0;
    background: var(--color-bg, #f8fafc);
    color: inherit;
    font: inherit;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    text-align: left;
}

.tree-aufnahme-section-toggle:hover,
.tree-aufnahme-section-toggle:focus-visible {
    color: var(--color-primary, #15803d);
}

.tree-aufnahme-section.is-open .tree-aufnahme-section-toggle {
    border-bottom: 1px solid var(--color-border);
}

.tree-aufnahme-section-chevron {
    display: inline-block;
    width: 0.55rem;
    height: 0.55rem;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(-45deg);
    transition: transform 0.15s ease;
    flex-shrink: 0;
}

.tree-aufnahme-section.is-open .tree-aufnahme-section-chevron {
    transform: rotate(45deg);
}

.tree-aufnahme-section-body {
    padding: 1rem;
}

.tree-aufnahme-section-body .form-section {
    margin-top: 0;
    padding-top: 0;
    border-top: 0;
}

.tree-aufnahme-section-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tree-aufnahme-section-nav-top {
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--color-border);
}

.tree-aufnahme-section-nav-bottom {
    margin-top: 1.25rem;
    padding-top: 0.75rem;
    border-top: 1px solid var(--color-border);
    justify-content: flex-end;
}

.tree-aufnahme-section-placeholder {
    margin: 0;
}

.tree-aufnahme-save-status {
    margin: 0 0 1rem;
}

.tree-aufnahme-save-status.is-error {
    color: #b42318;
}

.tree-aufnahme-files {
    margin-top: 0;
}

.tree-aufnahme-section-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(220px, 280px);
    gap: 1.25rem;
    align-items: start;
}

.tree-aufnahme-section-layout {
    display: grid;
    gap: 1.25rem;
}

.tree-aufnahme-section-grid-templates-only {
    justify-content: end;
}

.tree-aufnahme-section-grid-templates-only .tree-aufnahme-template-panel {
    grid-column: 2;
    width: 100%;
    max-width: 280px;
    justify-self: end;
}

.tree-aufnahme-section-full .form-section {
    margin-top: 0;
    padding-top: 0;
    border-top: 0;
}

.tree-aufnahme-page .tree-aufnahme-section-full .form-group {
    width: 100%;
}

.tree-aufnahme-page .tree-aufnahme-section-full input:not([type='checkbox']):not([type='radio']):not([type='file']),
.tree-aufnahme-page .tree-aufnahme-section-full select,
.tree-aufnahme-page .tree-aufnahme-section-full textarea {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

.tree-aufnahme-section-main .form-section {
    margin-top: 0;
    padding-top: 0;
    border-top: 0;
}

.tree-aufnahme-page .tree-aufnahme-section-main,
.tree-aufnahme-page .tree-aufnahme-section-body > .form-section {
    min-width: 0;
}

.tree-aufnahme-page .tree-aufnahme-section-main .form-group,
.tree-aufnahme-page .tree-aufnahme-section-body > .form-section .form-group {
    width: 100%;
}

.tree-aufnahme-page .tree-aufnahme-section-body > .form-section > .form-grid {
    margin-bottom: 1rem;
}

.tree-aufnahme-page .tree-aufnahme-section-main input:not([type='checkbox']):not([type='radio']):not([type='file']),
.tree-aufnahme-page .tree-aufnahme-section-main select,
.tree-aufnahme-page .tree-aufnahme-section-main textarea,
.tree-aufnahme-page .tree-aufnahme-section-body > .form-section input:not([type='checkbox']):not([type='radio']):not([type='file']),
.tree-aufnahme-page .tree-aufnahme-section-body > .form-section select,
.tree-aufnahme-page .tree-aufnahme-section-body > .form-section textarea {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

.tree-aufnahme-template-admin-section label.form-group,
.tree-aufnahme-template-admin-section .tree-aufnahme-template-label-input,
.tree-aufnahme-template-admin-section .tree-aufnahme-template-text-input {
    display: block;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

.tree-aufnahme-template-panel {
    position: sticky;
    top: 1rem;
    padding: 0.85rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md, 0.5rem);
    background: var(--color-bg, #f8fafc);
}

.tree-aufnahme-template-title {
    margin: 0 0 0.75rem;
    font-size: 0.95rem;
    font-weight: 600;
}

.tree-aufnahme-template-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.tree-aufnahme-template-btn {
    width: 100%;
    justify-content: flex-start;
    text-align: left;
    white-space: normal;
}

.tree-aufnahme-template-empty {
    margin: 0;
}

.tree-aufnahme-next-control-preview {
    font-size: 1.05rem;
    font-weight: 600;
    margin: 0.25rem 0 0;
}

.tree-aufnahme-template-admin-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-bottom: 0.75rem;
}

.tree-aufnahme-template-admin-head .form-section-title {
    margin: 0;
}

@media (max-width: 900px) {
    .tree-aufnahme-section-grid {
        grid-template-columns: 1fr;
    }

    .tree-aufnahme-template-panel {
        position: static;
    }

    .tree-aufnahme-section-grid-templates-only .tree-aufnahme-template-panel {
        grid-column: 1;
        max-width: none;
        justify-self: stretch;
    }
}

.tree-aufnahme-abschluss {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.tree-aufnahme-baumschau-next {
    margin: 0;
}

.tree-aufnahme-abschluss-options {
    margin-top: 0.25rem;
}

.tree-aufnahme-abschluss-actions {
    margin-top: 0.25rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tree-aufnahme-baumschau-status.is-error {
    color: #b42318;
}

.container-property-baumschauen {
    width: 90vw;
    max-width: 90vw;
    margin-left: auto;
    margin-right: auto;
}

.property-baumschauen-section {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.property-baumschauen-table-wrap {
    width: 100%;
    overflow-x: visible;
}

.property-baumschauen-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.92rem;
}

.property-baumschauen-table th,
.property-baumschauen-table td {
    padding: 0.55rem 0.65rem;
    border-bottom: 1px solid var(--color-border);
    vertical-align: top;
    text-align: left;
}

.property-baumschauen-table th {
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: var(--color-text-muted, #64748b);
    white-space: nowrap;
}

.property-baumschauen-row.is-without-baumschau {
    background: rgba(234, 179, 8, 0.08);
}

.property-baumschauen-tree-label {
    font-weight: 600;
}

.property-baumschauen-badge {
    display: inline-block;
    margin-top: 0.25rem;
    padding: 0.1rem 0.45rem;
    border-radius: 999px;
    font-size: 0.72rem;
    line-height: 1.35;
}

.property-baumschauen-badge-warning {
    background: rgba(234, 179, 8, 0.18);
    color: #92400e;
}

.property-baumschauen-next-input {
    width: 5.5rem;
    max-width: 100%;
    margin-right: 0.35rem;
}

.property-baumschauen-next-input.is-overdue {
    border-color: #b45309;
    background: rgba(234, 179, 8, 0.12);
}

.property-baumschauen-next-input.is-due_soon {
    border-color: #ca8a04;
}

.property-baumschauen-vitality {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    white-space: nowrap;
}

.property-baumschauen-vitality-dot {
    width: 0.62rem;
    height: 0.62rem;
    border-radius: 50%;
    flex-shrink: 0;
}

.property-baumschauen-history {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35rem 0.5rem;
}

.property-baumschauen-history-select {
    display: block;
    width: auto;
    min-width: 11rem;
    max-width: 18rem;
    margin-bottom: 0;
    font-size: 0.85rem;
}

.property-baumschauen-history .property-baumschauen-view-btn {
    flex-shrink: 0;
}

.property-baumschauen-count {
    display: block;
    width: 100%;
    font-size: 0.72rem;
}

.tree-aufnahme-sections.is-readonly input:disabled,
.tree-aufnahme-sections.is-readonly select:disabled,
.tree-aufnahme-sections.is-readonly textarea:disabled {
    opacity: 0.92;
    cursor: default;
}

.property-baumschauen-actions {
    white-space: nowrap;
}

.property-baumschau-billing-year-form {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.65rem 1rem;
    margin: 0 0 1.25rem;
}

.property-baumschau-billing-actions {
    margin-top: 1.25rem;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.65rem 1rem;
}

.property-baumschau-billing-finalize-form,
.property-baumschau-billing-share-form {
    display: inline-flex;
    margin: 0;
}

.property-baumschau-care-warning {
    color: var(--color-danger, #b91c1c);
    font-weight: 600;
}

.property-baumschau-billing-photo-scale {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    font-size: 0.92rem;
}

.property-baumschau-billing-photo-scale select {
    min-width: 9rem;
}

.property-baumschau-billing-share-box label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.35rem;
}

.property-baumschau-billing-share-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: center;
}

.property-baumschau-billing-share-input {
    flex: 1 1 16rem;
    min-width: 12rem;
}

.property-groundcare-share-section {
    margin-top: 1.75rem;
    padding-top: 1.25rem;
    border-top: 1px solid rgba(0, 0, 0, 0.08);
}

.property-groundcare-share-finalize {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.65rem 1rem;
    margin: 0 0 1.25rem;
}

.property-groundcare-share-label {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.45rem;
    font-weight: 600;
}

.property-groundcare-share-label-input {
    min-width: 6.5rem;
    max-width: 12rem;
    font-weight: 500;
}

.property-groundcare-share-list-heading {
    margin: 0 0 0.75rem;
    font-size: 1.05rem;
}

.property-groundcare-share-items {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 1rem;
}

.property-groundcare-share-item {
    padding: 0.85rem 1rem;
    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 0.5rem;
    background: rgba(0, 0, 0, 0.015);
}

.property-groundcare-share-item-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0.35rem 0.85rem;
    margin-bottom: 0.55rem;
}

.property-groundcare-share-item-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.55rem 0.85rem;
    margin-top: 0.55rem;
}

@media (max-width: 900px) {
    .property-baumschauen-table-wrap {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
}

.container-property-statistics {
    width: 90vw;
    max-width: 90vw;
    margin-left: auto;
    margin-right: auto;
}

.property-statistics {
    display: flex;
    flex-direction: column;
    gap: 1.75rem;
}

.property-statistics-maps {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-bottom: 0.25rem;
}

.property-statistics-map-panel.map-files-panel {
    border: 1px solid var(--color-border, #e2e8f0);
    border-radius: 0.5rem;
    padding: 0.65rem 0.75rem 0.75rem;
    background: var(--color-surface, #fff);
}

.property-statistics-map-panel-head.map-files-panel-head {
    margin-bottom: 0.5rem;
}

.property-statistics-map-panel.is-collapsed {
    padding-bottom: 0.65rem;
}

.property-statistics-map-container {
    width: 100%;
    min-height: 320px;
    height: 42vh;
    max-height: 520px;
    border-radius: 0.35rem;
    overflow: hidden;
    border: 1px solid var(--color-border, #e2e8f0);
}

.property-statistics-maps-is-static .property-statistics-map-container {
    height: 360px;
    min-height: 360px;
    max-height: 360px;
    pointer-events: none;
    cursor: default;
}

.property-statistics-maps-is-static .map-files-panel-toggle {
    cursor: default;
    pointer-events: none;
}

.property-statistics-maps-is-static .map-files-panel-chevron {
    visibility: hidden;
}

.property-statistics-maps-is-static .leaflet-control-container {
    pointer-events: none;
}

.property-map-layer-controls {
    margin-bottom: 1rem;
    padding: 0.75rem 0.85rem;
    border: 1px solid var(--color-border, #e2e8f0);
    border-radius: 0.5rem;
    background: var(--color-surface, #fff);
}

.property-map-layer-controls-intro {
    margin-top: 0.25rem;
    margin-bottom: 0.75rem;
}

.property-map-layer-controls-grid {
    display: grid;
    gap: 0.75rem 1.25rem;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.property-map-layer-fieldset {
    margin: 0;
    padding: 0.5rem 0.65rem 0.65rem;
    border: 1px solid var(--color-border, #e2e8f0);
    border-radius: 0.35rem;
}

.property-map-layer-fieldset legend {
    padding: 0 0.25rem;
    font-size: 0.85rem;
    font-weight: 600;
}

.property-map-layer-check {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    margin: 0.35rem 0 0;
    font-size: 0.92rem;
}

.property-map-layer-controls-actions {
    margin: 0.85rem 0 0;
}

.property-map-colors-grid {
    display: grid;
    gap: 0.65rem 1.25rem;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.property-map-colors-grid-single {
    max-width: 420px;
}

.property-map-color-row {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 0.75rem;
    align-items: center;
}

.property-map-color-row label {
    font-size: 0.92rem;
}

.property-map-color-input-wrap {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.property-map-color-input-wrap input[type="color"] {
    width: 2.75rem;
    height: 2rem;
    padding: 0;
    border: 1px solid var(--color-border, #e2e8f0);
    border-radius: 0.25rem;
    cursor: pointer;
}

.property-map-color-hex {
    width: 6.5rem;
    font-family: ui-monospace, monospace;
    font-size: 0.85rem;
}

@media print {
    .container-property-statistics {
        width: 100% !important;
        max-width: 100% !important;
    }

    .property-statistics-maps {
        break-inside: avoid;
        page-break-inside: avoid;
    }

    .property-statistics-map-panel.map-files-panel {
        break-inside: avoid;
        page-break-inside: avoid;
    }

    .property-statistics-map-container,
    .property-statistics-maps-is-static .property-statistics-map-container {
        overflow: hidden !important;
    }

    .property-statistics-map-container .leaflet-container,
    .property-statistics-map-container .leaflet-pane,
    .property-statistics-map-container .leaflet-tile,
    .property-statistics-map-container .leaflet-overlay-pane svg {
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }
}

.property-statistics-intro {
    margin: 0;
}

.property-statistics-section {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.property-statistics-heading {
    margin: 0;
    font-size: 1.05rem;
    font-weight: 650;
    color: var(--color-text, #0f172a);
    border-bottom: 1px solid var(--color-border);
    padding-bottom: 0.35rem;
}

.property-statistics-subsection {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
}

.property-statistics-subheading {
    margin: 0;
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--color-text-muted, #64748b);
}

.property-statistics-table-wrap {
    width: 100%;
    overflow-x: visible;
}

.property-statistics-table-wrap-inline {
    max-width: 28rem;
}

.property-statistics-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.92rem;
}

.property-statistics-table th,
.property-statistics-table td {
    padding: 0.55rem 0.65rem;
    border-bottom: 1px solid var(--color-border);
    vertical-align: top;
    text-align: left;
}

.property-statistics-table thead th {
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: var(--color-text-muted, #64748b);
    white-space: nowrap;
}

.property-statistics-table-compact th {
    width: 55%;
    font-weight: 500;
    color: var(--color-text-muted, #64748b);
}

.property-statistics-table-compact td {
    font-weight: 600;
}

.property-statistics-total-row th,
.property-statistics-total-row td {
    font-weight: 650;
    border-top: 2px solid var(--color-border);
    background: rgba(148, 163, 184, 0.08);
}

.property-statistics-metrics {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem 2rem;
    margin: 0;
}

.property-statistics-metrics > div {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
}

.property-statistics-metrics dt {
    margin: 0;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: var(--color-text-muted, #64748b);
}

.property-statistics-metrics dd {
    margin: 0;
    font-size: 0.95rem;
    font-weight: 600;
}

@media (max-width: 900px) {
    .property-statistics-table-wrap {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
}

.property-groundcare-calculation .property-groundcare-settings-grid {
    margin-bottom: 0.5rem;
}

.property-groundcare-calculation .property-groundcare-settings-grid .form-row-full {
    grid-column: 1 / -1;
}

.property-groundcare-calculation .property-groundcare-checkbox-label {
    display: inline-flex;
    align-items: flex-start;
    gap: 0.5rem;
    font-weight: 600;
    cursor: pointer;
}

.property-groundcare-calculation .property-groundcare-checkbox-label input[type="checkbox"] {
    margin-top: 0.2rem;
}

.property-groundcare-voluntary-cleaning-disclaimer {
    font-weight: 600;
    color: var(--color-text, #1e293b);
}

.property-groundcare-calculation .property-groundcare-settings-grid .hint {
    margin-top: 0.35rem;
    margin-bottom: 0;
}

.property-groundcare-save-status {
    min-height: 1.25rem;
    margin-bottom: 0.75rem;
    font-size: 0.85rem;
    color: var(--color-text-muted, #64748b);
}

.property-groundcare-save-status.is-pending {
    color: var(--color-text-muted, #64748b);
}

.property-groundcare-save-status.is-saved {
    color: var(--color-success, #15803d);
}

.property-groundcare-save-status.is-error {
    color: var(--color-danger, #b91c1c);
}

.property-one-time-calculation {
    width: 100%;
}

.property-one-time-calculation-table-wrap {
    width: 100%;
}

.property-one-time-calculation-table .property-one-time-select-col,
.property-one-time-calculation-table .property-one-time-select-cell {
    width: 4.5rem;
    text-align: center;
    vertical-align: middle;
}

.property-one-time-calculation-table tbody tr.is-disabled {
    opacity: 0.65;
}

.property-one-time-calculation-table tbody tr.is-disabled [data-field="amount"] {
    color: var(--color-text-muted, #64748b);
}

.property-one-time-section-row td {
    padding-top: 1.1rem;
    padding-bottom: 0.45rem;
    border-bottom: none;
    background: var(--color-bg, #f8fafc);
}

.property-one-time-section-row.is-first-section td {
    padding-top: 0.35rem;
}

.property-one-time-section-title {
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--color-text, #0f172a);
}

.property-one-time-calculation-table tfoot th,
.property-one-time-calculation-table tfoot td {
    border-top: 1px solid var(--color-border, #e2e8f0);
}

.property-one-time-calculation-table tfoot .property-one-time-meta-row th,
.property-one-time-calculation-table tfoot .property-one-time-meta-row td {
    padding-top: 0.85rem;
}

.property-one-time-setting-input {
    width: 100%;
    max-width: 14rem;
}

.property-one-time-meta-hint {
    font-size: 0.82rem;
    color: var(--color-text-muted, #64748b);
    white-space: nowrap;
}

.property-one-time-summary-row td:last-child {
    text-align: right;
    font-variant-numeric: tabular-nums;
}

.property-one-time-removal-cell {
    min-width: 8.5rem;
}

.property-one-time-removal-controls {
    display: flex;
    align-items: center;
    gap: 0.45rem;
}

.property-one-time-removal-toggle-label {
    display: inline-flex;
    margin: 0;
    cursor: pointer;
}

.property-one-time-line-removal:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.property-one-time-line-multiplier,
.property-one-time-line-removal {
    width: 5.5rem;
    max-width: 100%;
}

.property-one-time-line-removal {
    width: 6.5rem;
}

.property-one-time-removal-empty {
    color: var(--color-text-muted, #64748b);
}

.property-groundcare-line-multiplier,
.property-groundcare-line-visits {
    width: 5.5rem;
    max-width: 100%;
}

.property-groundcare-line-visits.is-inherited {
    opacity: 0.85;
}

.property-groundcare-savings-discount td {
    color: var(--color-success, #15803d);
    font-weight: 600;
}

.property-groundcare-savings-surcharge td {
    color: var(--color-danger, #b91c1c);
    font-weight: 600;
}

.is-hidden {
    display: none !important;
}

.property-metrics-token-panel {
    margin-bottom: 1.5rem;
    padding: 1rem 1.1rem;
    border: 1px solid var(--color-border, #dbe3ef);
    border-radius: 0.75rem;
    background: var(--color-surface-muted, #f8fafc);
}

.property-metrics-token-intro {
    margin-top: 0.35rem;
}

.property-metrics-token-status,
.property-metrics-token-action-status {
    margin: 0.75rem 0;
    font-size: 0.9rem;
    color: var(--color-text-muted, #64748b);
}

.property-metrics-token-action-status.is-error {
    color: var(--color-danger, #b91c1c);
}

.property-metrics-token-link-row {
    margin-bottom: 0.75rem;
}

.property-metrics-token-link-row label {
    display: block;
    margin-bottom: 0.35rem;
    font-weight: 600;
}

.property-metrics-token-link-field {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.property-metrics-token-link-input {
    flex: 1 1 auto;
    min-width: 0;
}

.property-metrics-token-actions {
    display: flex;
    gap: 0.75rem;
    align-items: center;
    flex-wrap: wrap;
}

.property-metrics-snapshot-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.property-metrics-snapshot-tabs .btn.is-active {
    background: var(--color-primary, #166534);
    color: #fff;
    border-color: var(--color-primary, #166534);
}

@media (max-width: 700px) {
    .property-metrics-token-link-field {
        flex-direction: column;
        align-items: stretch;
    }
}

.super-mail-inbound-link {
    color: inherit;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.super-mail-inbound-link:hover {
    color: var(--color-primary, #2f6b3f);
}

.mail-inbound-overlay {
    position: fixed;
    inset: 0;
    z-index: 1200;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
}

.mail-inbound-overlay-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.55);
}

.mail-inbound-overlay-panel {
    position: relative;
    z-index: 1;
    width: min(920px, 100%);
    max-height: calc(100vh - 3rem);
    overflow: auto;
    background: var(--color-surface, #fff);
    border-radius: 12px;
    box-shadow: 0 24px 48px rgba(15, 23, 42, 0.25);
    padding: 1.25rem 1.5rem 1.5rem;
}

.mail-inbound-overlay-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}

.mail-inbound-overlay-header > div:first-child {
    flex: 1 1 auto;
}

.mail-inbound-overlay-header .mail-inbound-refresh-form {
    margin: 0;
}

.mail-inbound-detail-grid {
    display: grid;
    grid-template-columns: 140px 1fr;
    gap: 0.5rem 1rem;
    margin: 0 0 1rem;
}

.mail-inbound-detail-grid dt {
    margin: 0;
    font-weight: 600;
    color: var(--color-text-muted, #64748b);
}

.mail-inbound-detail-grid dd {
    margin: 0;
}

.mail-inbound-attachment-list {
    margin: 0;
    padding-left: 1.1rem;
}

.mail-inbound-body-text {
    white-space: pre-wrap;
    word-break: break-word;
    background: var(--color-surface-muted, #f8fafc);
    border: 1px solid var(--color-border, #e2e8f0);
    border-radius: 8px;
    padding: 1rem;
    max-height: 360px;
    overflow: auto;
    margin: 0;
    font: inherit;
}

.mail-inbound-body-content {
    background: var(--color-surface-muted, #f8fafc);
    border: 1px solid var(--color-border, #e2e8f0);
    border-radius: 8px;
    padding: 1rem;
    max-height: 420px;
    overflow: auto;
}

.mail-inbound-body-content img,
.mail-inbound-inline-image {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 0.75rem 0;
    border-radius: 6px;
}

.mail-inbound-inline-images {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.property-photos-toolbar {
    align-items: center;
}

.property-photos-target-hint {
    margin: 0;
}

.property-photos-tree {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 1rem;
}

.property-photo-section,
.property-photo-group {
    border: 1px solid var(--color-border, #e2e8f0);
    border-radius: 10px;
    background: var(--color-surface-muted, #f8fafc);
}

.property-photo-section-head,
.property-photo-group-head {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem 0.75rem;
    padding: 0.75rem 0.9rem;
    border-bottom: 1px solid var(--color-border, #e2e8f0);
    background: #fff;
    border-radius: 10px 10px 0 0;
}

.property-photo-group-toggle,
.property-photo-section-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin: 0;
    padding: 0.15rem;
    border: 0;
    background: transparent;
    color: inherit;
    cursor: pointer;
}

.property-photo-group-toggle:hover,
.property-photo-group-toggle:focus-visible,
.property-photo-section-toggle:hover,
.property-photo-section-toggle:focus-visible {
    color: var(--color-primary, #2563eb);
}

.property-photo-group-chevron {
    display: inline-block;
    width: 0.55rem;
    height: 0.55rem;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(45deg);
    transition: transform 0.15s ease;
    margin-top: -0.15rem;
}

.property-photo-group.is-collapsed > .property-photo-group-head .property-photo-group-chevron,
.property-photo-section.is-collapsed > .property-photo-section-head .property-photo-group-chevron {
    transform: rotate(-45deg);
    margin-top: 0.1rem;
}

.property-photo-group.is-collapsed > .property-photo-group-body,
.property-photo-section.is-collapsed > .property-photo-section-ungrouped {
    display: none;
}

.property-photo-section-title,
.property-photo-group-title {
    font-weight: 600;
    flex: 1 1 12rem;
}

.property-photo-group-number {
    font-variant-numeric: tabular-nums;
    color: var(--color-text-muted, #64748b);
    min-width: 2.5rem;
}

.property-photo-group-drag-handle {
    border: 0;
    background: transparent;
    cursor: grab;
    color: var(--color-text-muted, #64748b);
    font-size: 1rem;
    line-height: 1;
    padding: 0.15rem 0.25rem;
}

.property-photo-group-drag-handle:active {
    cursor: grabbing;
}

.property-photo-group-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
}

.property-photo-item-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    margin-top: 0.35rem;
}

.property-photo-group-description-wrap {
    padding: 0 0.9rem 0.75rem;
}

.property-photo-group-description-label {
    display: block;
    margin: 0 0 0.35rem;
    font-size: 0.85rem;
    color: var(--color-text-muted, #64748b);
}

.property-photo-group-description {
    width: 100%;
    min-height: 4.5rem;
    resize: vertical;
    box-sizing: border-box;
    padding: 0.55rem 0.65rem;
    border: 1px solid var(--color-border, #e2e8f0);
    border-radius: 8px;
    font: inherit;
    line-height: 1.4;
    background: #fff;
}

.property-photo-group-description:focus {
    outline: none;
    border-color: var(--color-primary, #2563eb);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

.property-photo-group-body,
.property-photo-section-ungrouped .property-photo-dropzone {
    padding: 0.75rem 0.9rem;
}

.property-photo-groups {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    padding: 0 0.9rem 0.9rem;
}

.property-photo-dropzone,
.property-photo-groups {
    min-height: 3rem;
    border-radius: 8px;
    transition: background-color 0.15s ease, outline-color 0.15s ease;
}

.property-photo-dropzone.is-drop-target,
.property-photo-groups.is-drop-target {
    outline: 2px dashed var(--color-primary, #2563eb);
    outline-offset: 2px;
    background: rgba(37, 99, 235, 0.06);
}

.tenant-mail-help {
    margin-bottom: 1rem;
    padding: 0;
    background: #f8fafc;
    border-color: #dbeafe;
}

.collapsible-help {
    margin-bottom: 1rem;
    padding: 0;
    overflow: hidden;
}

.collapsible-help-summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    cursor: pointer;
    list-style: none;
    user-select: none;
}

.collapsible-help-summary::-webkit-details-marker {
    display: none;
}

.collapsible-help-summary::before {
    content: "▸";
    flex-shrink: 0;
    font-size: 0.95rem;
    color: var(--color-primary, #2563eb);
    transition: transform 0.15s ease;
}

.collapsible-help[open] > .collapsible-help-summary::before {
    transform: rotate(90deg);
}

.collapsible-help-title {
    font-size: 1.02rem;
    font-weight: 600;
    color: var(--color-text, #1a202c);
}

.collapsible-help-toggle-hint {
    font-size: 0.78rem;
    color: var(--color-text-muted, #718096);
    white-space: nowrap;
}

.collapsible-help-body {
    padding: 0 1rem 1rem;
    border-top: 1px solid var(--color-border, #e2e8f0);
}

.collapsible-help-lead {
    margin: 0.75rem 0 0.65rem;
    font-size: 0.92rem;
    line-height: 1.45;
    color: var(--color-text-muted, #4a5568);
}

.collapsible-help-grid {
    display: grid;
    gap: 0.85rem 1.25rem;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.collapsible-help-grid-single {
    grid-template-columns: 1fr;
}

.collapsible-help-grid h3 {
    margin: 0 0 0.35rem;
    font-size: 0.92rem;
}

.collapsible-help-list {
    margin: 0;
    padding-left: 1.1rem;
    font-size: 0.88rem;
    line-height: 1.45;
    color: var(--color-text-muted, #4a5568);
}

.collapsible-help-list li + li {
    margin-top: 0.35rem;
}

.collapsible-help-note {
    margin: 0.65rem 0 0;
    padding: 0.55rem 0.65rem;
    font-size: 0.88rem;
    line-height: 1.4;
    background: #eff6ff;
    border-radius: 6px;
    border: 1px solid #bfdbfe;
}

.property-hub-help,
.property-module-help {
    background: #f8fafc;
    border-color: #dbeafe;
}

.tenant-mail-list {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
    margin-top: 0.75rem;
}

.tenant-mail-row {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
    padding: 0.65rem 0.75rem;
    border: 1px solid var(--color-border, #e2e8f0);
    border-radius: 8px;
    background: #fff;
}

/* E-Mail: Toolbar + Neu/Klassisch */
.tenant-mail-toolbar-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    align-items: center;
}

.tenant-mail-nav-actions,
.tenant-mail-primary-actions,
.tenant-mail-conversation-actions {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0.4rem;
    margin: 0 0 0.65rem;
    padding: 0.55rem 0.65rem 0.65rem;
    border: 1px solid var(--color-border, #cbd5e0);
    border-bottom: none;
    background: #f8fafc;
}

.tenant-mail-actions-label {
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    color: #4a5568;
    margin: 0;
}

.mail-compose-recipient-group {
    display: block;
    margin-bottom: 0.75rem;
}

.mail-compose-recipient-group-title {
    font-weight: 700;
    font-size: 0.85rem;
    margin: 0.15rem 0 0.35rem;
    color: #2d3748;
}

.mail-compose-recipient-group .company-contact-row,
#company-contact-list .company-contact-row {
    display: block;
    font-weight: normal;
    margin: 0.25rem 0;
    line-height: 1.35;
}

.tenant-mail-actions-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: center;
}

.tenant-mail-actions-row--secondary {
    padding-top: 0.35rem;
    border-top: 1px dashed var(--color-border, #cbd5e0);
}

.tenant-mail-nav-actions {
    border-radius: 10px 10px 0 0;
    margin-bottom: 0;
}

.tenant-mail-primary-actions {
    margin-top: 0;
    margin-bottom: 0;
    border-top: none;
    border-radius: 0;
}

.tenant-mail-conversation-actions {
    margin-top: 0;
    border-top: none;
    border-radius: 0;
}

.tenant-mail-nav-actions .btn,
.tenant-mail-primary-actions .btn,
.tenant-mail-conversation-actions .btn {
    font-size: 0.78rem;
    font-weight: 600;
    line-height: 1.25;
    padding: 0.22rem 0.55rem;
    border-radius: 5px;
    border: 1px solid #a0aec0;
    background: #edf2f7;
    color: #2d3748;
    box-shadow: none;
}

.tenant-mail-nav-actions .btn:hover,
.tenant-mail-primary-actions .btn:hover,
.tenant-mail-conversation-actions .btn:hover {
    background: #e2e8f0;
    border-color: #718096;
    color: #1a202c;
}

.tenant-mail-nav-actions .btn:focus-visible,
.tenant-mail-primary-actions .btn:focus-visible,
.tenant-mail-conversation-actions .btn:focus-visible {
    outline: 2px solid #4a5568;
    outline-offset: 1px;
}

.tenant-mail-conversation-actions .btn[disabled],
.tenant-mail-conversation-actions button:disabled {
    opacity: 0.45;
    cursor: not-allowed;
    background: #edf2f7;
    border-color: #a0aec0;
    color: #2d3748;
}

.tenant-mail-follow-up-chip {
    display: inline-block;
    margin-left: 0.35rem;
    padding: 0.05rem 0.35rem;
    border-radius: 4px;
    background: #edf2f7;
    font-size: 0.78rem;
    font-weight: 600;
}

.tenant-mail-follow-up-due .tenant-mail-follow-up-chip {
    background: #fef3c7;
    color: #92400e;
}

.tenant-mail-follow-up-modal,
.tenant-mail-akte-modal {
    position: fixed;
    inset: 0;
    z-index: 12000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.tenant-mail-follow-up-modal[hidden],
.tenant-mail-akte-modal[hidden] {
    display: none;
}

.tenant-mail-follow-up-backdrop,
.tenant-mail-akte-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.35);
}

.tenant-mail-follow-up-dialog,
.tenant-mail-akte-dialog {
    position: relative;
    z-index: 1;
    width: min(100%, 26rem);
    margin: 0;
    padding: 1rem 1.1rem 1.1rem;
}

.tenant-mail-follow-up-dialog-head,
.tenant-mail-akte-dialog-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin: 0 0 0.65rem;
}

.tenant-mail-follow-up-dialog-head h3,
.tenant-mail-akte-dialog-head h3 {
    margin: 0;
    font-size: 1.05rem;
}

.tenant-mail-follow-up-form .form-group {
    margin: 0 0 0.75rem;
}

.tenant-mail-follow-up-dialog-actions,
.tenant-mail-akte-dialog-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: flex-end;
    margin-top: 0.25rem;
}

.tenant-mail-reply-modal {
    position: fixed;
    inset: 0;
    z-index: 12000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.tenant-mail-reply-modal[hidden] {
    display: none;
}

.tenant-mail-reply-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.35);
}

.tenant-mail-reply-dialog {
    position: relative;
    z-index: 1;
    width: min(100%, 36rem);
    max-height: min(92vh, 44rem);
    overflow: auto;
    margin: 0;
    padding: 1rem 1.1rem 1.1rem;
}

.tenant-mail-reply-dialog-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin: 0 0 0.65rem;
}

.tenant-mail-reply-dialog-head h3 {
    margin: 0;
    font-size: 1.05rem;
}

.tenant-mail-reply-dialog-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: flex-end;
    margin-top: 0.25rem;
}

.mail-attachment-word {
    display: inline-block;
    padding: 0.35rem 0.55rem;
    border: 1px solid #90cdf4;
    border-radius: 6px;
    background: #ebf8ff;
    text-decoration: none;
    color: inherit;
    font-size: 0.9rem;
}

.mail-attachment-word:hover {
    background: #bee3f8;
}

.mail-word-hover-tip {
    position: fixed;
    z-index: 13000;
    width: min(28rem, 92vw);
    max-height: min(22rem, 60vh);
    overflow: auto;
    padding: 0.65rem 0.75rem;
    background: #fff;
    border: 1px solid #a0aec0;
    border-radius: 8px;
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.14);
}

.mail-word-hover-tip-head {
    margin: 0 0 0.45rem;
}

.mail-word-hover-tip-body {
    font-size: 0.88rem;
    line-height: 1.4;
}

.mail-word-preview-html {
    max-height: 16rem;
    overflow: auto;
}

.mail-word-preview-html p {
    margin: 0 0 0.5rem;
}

.mail-word-hover-tip-foot {
    margin: 0.5rem 0 0;
    border-top: 1px solid #e2e8f0;
    padding-top: 0.4rem;
}

.mail-word-choice-modal {
    position: fixed;
    inset: 0;
    z-index: 12000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.mail-word-choice-modal[hidden] {
    display: none;
}

.mail-word-choice-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.35);
}

.mail-word-choice-dialog {
    position: relative;
    z-index: 1;
    width: min(100%, 26rem);
    margin: 0;
    padding: 1rem 1.1rem 1.1rem;
}

.mail-word-choice-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin: 0 0 0.65rem;
}

.mail-word-choice-head h3 {
    margin: 0;
    font-size: 1.05rem;
}

.mail-word-choice-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.mail-word-choice-remember {
    display: flex;
    align-items: center;
    gap: 0.45rem;
}

.mail-word-viewer-modal {
    position: fixed;
    inset: 0;
    z-index: 12100;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.mail-word-viewer-modal[hidden] {
    display: none;
}

.mail-word-viewer-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
}

.mail-word-viewer-dialog {
    position: relative;
    z-index: 1;
    width: min(100%, 48rem);
    max-height: min(90vh, 40rem);
    display: flex;
    flex-direction: column;
    margin: 0;
    padding: 1rem 1.1rem 1.1rem;
}

.mail-word-viewer-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin: 0 0 0.65rem;
    flex-shrink: 0;
}

.mail-word-viewer-head h3 {
    margin: 0;
    font-size: 1.05rem;
    word-break: break-word;
}

.mail-word-viewer-body {
    flex: 1;
    min-height: 12rem;
    max-height: min(65vh, 30rem);
    overflow: auto;
    padding: 0.75rem 0.85rem;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    background: #fff;
}

.mail-word-viewer-body .mail-word-preview-html {
    max-height: none;
    overflow: visible;
}

.mail-word-viewer-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: flex-end;
    margin-top: 0.85rem;
    flex-shrink: 0;
}

.tenant-mail-property-include-modal,
.tenant-mail-include-modal {
    position: fixed;
    inset: 0;
    z-index: 12000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.tenant-mail-property-include-modal[hidden],
.tenant-mail-include-modal[hidden] {
    display: none;
}

.tenant-mail-property-include-backdrop,
.tenant-mail-include-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.35);
}

.tenant-mail-property-include-dialog,
.tenant-mail-include-dialog {
    position: relative;
    z-index: 1;
    width: min(100%, 28rem);
    margin: 0;
    padding: 1rem 1.1rem 1.1rem;
}

.tenant-mail-property-include-dialog--wide {
    width: min(100%, 34rem);
}

.tenant-mail-property-contacts-list {
    max-height: 12rem;
    overflow: auto;
    border: 1px solid #cbd5e0;
    border-radius: 6px;
    padding: 0.45rem 0.55rem;
    background: #fff;
}

.tenant-mail-property-contact-row {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    padding: 0.35rem 0.15rem;
    border-bottom: 1px solid #edf2f7;
    cursor: pointer;
    font-size: 0.92rem;
}

.tenant-mail-property-contact-row:last-child {
    border-bottom: 0;
}

.tenant-mail-property-contact-row.is-disabled {
    opacity: 0.55;
    cursor: default;
}

.tenant-mail-property-contact-row input {
    margin-top: 0.2rem;
}

.tenant-mail-property-contact-row span {
    display: block;
    line-height: 1.35;
}

.tenant-mail-property-contact-meta,
.tenant-mail-property-contact-email {
    font-size: 0.82rem;
    color: #4a5568;
}

.tenant-mail-property-include-head,
.tenant-mail-include-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin: 0 0 0.65rem;
}

.tenant-mail-property-include-head h3,
.tenant-mail-include-head h3 {
    margin: 0;
    font-size: 1.05rem;
}

.tenant-mail-property-include-actions,
.tenant-mail-include-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: flex-end;
}

.tenant-mail-property-include-actions a[aria-disabled="true"],
.tenant-mail-include-actions a[aria-disabled="true"] {
    opacity: 0.45;
    pointer-events: none;
}

.tenant-mail-shell-client .tenant-mail-nav-actions,
.tenant-mail-shell-client .tenant-mail-primary-actions {
    margin-bottom: 0;
    border-bottom: none;
}

.tenant-mail-shell-client .tenant-mail-conversation-actions {
    margin-bottom: 0;
}

.tenant-mail-shell-client .tenant-mail-client {
    border-top-left-radius: 0;
    border-top-right-radius: 0;
}

.tenant-mail-shell-classic .tenant-mail-nav-actions {
    border-bottom: none;
    border-radius: 10px 10px 0 0;
    margin-bottom: 0;
}

.tenant-mail-shell-classic .tenant-mail-primary-actions {
    border-bottom: none;
    border-radius: 0;
    margin-bottom: 0;
}

.tenant-mail-shell-classic .tenant-mail-conversation-actions {
    border-bottom: 1px solid var(--color-border, #cbd5e0);
    border-radius: 0 0 10px 10px;
    margin-bottom: 0.85rem;
}

.tenant-mail-ui-toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    margin-left: 0.25rem;
    padding: 0.2rem 0.35rem 0.2rem 0.55rem;
    border: 1px solid var(--color-border, #cbd5e0);
    border-radius: 8px;
    background: #f8fafc;
}

.tenant-mail-ui-toggle-label {
    font-size: 0.8rem;
    color: var(--color-text-muted, #64748b);
    margin-right: 0.15rem;
}

/* E-Mail: Mailclient-Layout */
.tenant-mail-shell-client {
    max-width: 1400px;
}

.tenant-mail-client {
    display: grid;
    grid-template-columns: 11rem minmax(14rem, 22rem) minmax(0, 1fr);
    gap: 0;
    min-height: 32rem;
    border: 1px solid var(--color-border, #cbd5e0);
    border-radius: 10px;
    background: #fff;
    overflow: hidden;
}

.tenant-mail-client-compose {
    grid-column: 1 / -1;
    padding: 0;
}

.tenant-mail-client-folders,
.tenant-mail-client-list {
    border-right: 1px solid var(--color-border, #e2e8f0);
    background: #f8fafc;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.tenant-mail-client-folders {
    padding: 0.75rem 0.65rem;
}

.tenant-mail-client-aside-title {
    margin: 0 0 0.5rem;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    color: #4a5568;
}

.tenant-mail-client-folder-nav {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}

.tenant-mail-client-folder {
    display: block;
    padding: 0.45rem 0.6rem;
    border-radius: 6px;
    text-decoration: none;
    color: inherit;
    font-size: 0.92rem;
    border: 1px solid transparent;
}

.tenant-mail-client-folder:hover {
    background: #edf2f7;
}

.tenant-mail-client-folder.is-active {
    background: #e2e8f0;
    border-color: #cbd5e0;
    font-weight: 600;
}

.tenant-mail-client-status-filters {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    margin-top: 1rem;
    padding-top: 0.75rem;
    border-top: 1px solid #e2e8f0;
}

.tenant-mail-client-list-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.5rem;
    padding: 0.75rem 0.75rem 0.35rem;
}

.tenant-mail-client-list-ul {
    list-style: none;
    margin: 0;
    padding: 0 0.4rem 0.75rem;
    overflow-y: auto;
    flex: 1;
}

.tenant-mail-client-item {
    display: block;
    padding: 0.55rem 0.65rem;
    margin: 0.2rem 0;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    background: #fff;
    text-decoration: none;
    color: inherit;
}

.tenant-mail-client-item.is-internal {
    border-left: 3px solid #90caf9;
}

.tenant-mail-client-item.is-external {
    border-left: 3px solid #a5d6a7;
}

.tenant-mail-client-item.is-external-property {
    border-left: 3px solid #a0aec0;
    background: #f7fafc;
}

.tenant-mail-client-item:hover {
    background: #f7fafc;
}

.tenant-mail-client-item.is-active {
    background: #ebf4ff;
    border-color: #90cdf4;
    box-shadow: inset 0 0 0 1px #bee3f8;
}

.tenant-mail-client-item.has-unread .tenant-mail-client-item-subject {
    font-weight: 700;
}

.tenant-mail-client-item-top {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    margin-bottom: 0.2rem;
    font-size: 0.78rem;
}

.tenant-mail-client-item-badge {
    padding: 0.05rem 0.35rem;
    border-radius: 4px;
    background: #edf2f7;
    font-weight: 600;
}

.tenant-mail-client-item.is-external .tenant-mail-client-item-badge {
    background: #e8f5e9;
}

.tenant-mail-client-item.is-external-property .tenant-mail-client-item-badge {
    background: #edf2f7;
    color: #4a5568;
}

.tenant-mail-client-item.is-internal .tenant-mail-client-item-badge {
    background: #e3f2fd;
}

.tenant-mail-client-item-new {
    padding: 0.05rem 0.35rem;
    border-radius: 4px;
    background: #dc2626;
    color: #fff;
    font-weight: 700;
    font-size: 0.72rem;
}

.tenant-mail-client-item-date {
    margin-left: auto;
    color: #718096;
    white-space: nowrap;
}

.tenant-mail-client-item-subject {
    font-size: 0.95rem;
    line-height: 1.3;
    margin-bottom: 0.15rem;
    word-break: break-word;
}

.tenant-mail-client-item-property {
    font-size: 0.8rem;
    line-height: 1.3;
    margin: 0 0 0.12rem;
    color: #4a5568;
    word-break: break-word;
}

.tenant-mail-client-item-meta {
    font-size: 0.8rem;
    margin: 0;
}

.tenant-mail-client-empty {
    padding: 0.75rem;
}

.tenant-mail-client-reading {
    min-width: 0;
    overflow: auto;
    background: #fff;
    padding: 0.75rem;
}

.tenant-mail-client-reading > .card {
    margin: 0;
    border: none;
    box-shadow: none;
}

.tenant-mail-client-reading-empty {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    min-height: 18rem;
    padding: 1.5rem;
    color: #4a5568;
}

.tenant-mail-client-reading-empty h2 {
    margin: 0 0 0.5rem;
    font-size: 1.15rem;
}

@media (max-width: 960px) {
    .tenant-mail-client {
        grid-template-columns: 1fr;
        min-height: 0;
    }

    .tenant-mail-client-folders,
    .tenant-mail-client-list {
        border-right: none;
        border-bottom: 1px solid var(--color-border, #e2e8f0);
    }

    .tenant-mail-client-folder-nav {
        flex-direction: row;
        flex-wrap: wrap;
    }

    .tenant-mail-client-list-ul {
        max-height: 16rem;
    }

    .tenant-mail-client-reading {
        min-height: 20rem;
    }
}

.form-inline-filter {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    align-items: flex-end;
}

.property-photos-upload-drop,
.property-photo-dropzone {
    transition: background-color 0.15s ease, outline-color 0.15s ease, border-color 0.15s ease;
}

.property-photos-upload-drop.is-file-dragover,
.property-photo-dropzone.is-file-dragover,
.property-photos-root.is-file-dragover .property-photos-upload-drop {
    outline: 2px dashed var(--color-primary, #2563eb);
    outline-offset: 3px;
    background: rgba(37, 99, 235, 0.08);
}

.property-photo-dropzone:empty::after {
    content: 'Fotos hier ablegen oder „Foto hochladen“ nutzen';
    display: block;
    padding: 1.25rem 0.75rem;
    text-align: center;
    color: var(--color-text-muted, #64748b);
    font-size: 0.9rem;
}

.property-photo-item.is-dragging,
.property-photo-group.is-dragging {
    opacity: 0.55;
}

.property-photo-item {
    position: relative;
}

.property-photo-drag-handle,
.property-photo-group-drag-handle {
    cursor: grab;
    user-select: none;
}

.property-photo-drag-handle {
    align-self: flex-start;
    border: 0;
    background: transparent;
    color: var(--color-text-muted, #64748b);
    font-size: 1rem;
    line-height: 1;
    padding: 0.1rem 0.15rem 0;
}

.property-photo-drag-handle:active,
.property-photo-group-drag-handle:active {
    cursor: grabbing;
}

.property-photo-group-head.is-drop-target {
    outline: 2px dashed var(--color-primary, #2563eb);
    outline-offset: -2px;
    background: rgba(37, 99, 235, 0.08);
}

.property-photo-item.is-drop-before,
.property-photo-group.is-drop-before {
    box-shadow: inset 0 3px 0 0 var(--color-primary, #2563eb);
}

.property-photo-group .property-photo-group {
    background: #fff;
}

.property-photos-root.is-touch-dragging,
.property-photos-root.is-touch-dragging * {
    touch-action: none;
    user-select: none;
}

.property-photo-touch-ghost {
    position: fixed;
    z-index: 10000;
    pointer-events: none;
    padding: 0.4rem 0.7rem;
    border-radius: 8px;
    background: rgba(15, 23, 42, 0.88);
    color: #fff;
    font-size: 0.85rem;
    font-weight: 600;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.25);
}

.person-groups-layout {
    display: grid;
    grid-template-columns: minmax(16rem, 20rem) minmax(0, 1fr);
    gap: 1rem;
    margin-top: 1rem;
}

@media (max-width: 900px) {
    .person-groups-layout {
        grid-template-columns: 1fr;
    }
}

.person-groups-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.person-groups-list-item {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
    padding: 0.65rem 0.75rem;
    border: 1px solid var(--color-border, #e2e8f0);
    border-radius: 8px;
    text-decoration: none;
    color: inherit;
    background: #fff;
}

.person-groups-list-item.is-active,
.person-groups-list-item:hover {
    border-color: var(--color-primary, #2563eb);
    background: rgba(37, 99, 235, 0.05);
}

.person-groups-list-name {
    font-weight: 600;
}

.person-groups-members,
.person-groups-permission-section {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
    margin: 0.75rem 0 1rem;
}

.person-groups-permission-section {
    border: 1px solid var(--color-border, #e2e8f0);
    border-radius: 8px;
    padding: 0.75rem 0.9rem;
}

.person-groups-permission-section legend {
    padding: 0 0.35rem;
    font-weight: 600;
}

.person-groups-member,
.person-groups-permission {
    display: flex;
    gap: 0.65rem;
    align-items: flex-start;
    padding: 0.45rem 0.55rem;
    border-radius: 6px;
    background: var(--color-surface-muted, #f8fafc);
}

.person-groups-permission.is-disabled {
    opacity: 0.55;
    color: var(--color-text-muted, #64748b);
}

.person-groups-permission.is-disabled input {
    cursor: not-allowed;
}

.person-groups-member.is-primary {
    opacity: 0.85;
}

.person-groups-member span,
.person-groups-permission span {
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
}

/* Firmenkontakte — kompakter Editor (Test, angelehnt an Maps/Statistik) */
.company-contact-editor {
    font-size: 0.875rem;
}

.company-contact-editor-details > summary {
    list-style: none;
    cursor: pointer;
}

.company-contact-editor-details > summary::-webkit-details-marker {
    display: none;
}

.company-contact-editor__summary {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.5rem 1rem;
    margin: 0 0 0.65rem;
}

.company-contact-editor__title {
    margin: 0;
    font-size: 0.92rem;
    font-weight: 600;
    color: var(--color-text, #0f172a);
}

.company-contact-editor__toggle-hint {
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--color-muted, #64748b);
}

.company-contact-editor-details[open] > .company-contact-editor__summary {
    margin-bottom: 0.85rem;
    padding-bottom: 0.55rem;
    border-bottom: 1px solid var(--color-border, #e2e8f0);
}

.company-contact-persons {
    margin: 1rem 0;
    padding: 0.75rem;
    border: 1px solid var(--color-border, #e2e8f0);
    border-radius: 0.65rem;
    background: #f8fafc;
}

.company-contact-persons__head {
    margin-bottom: 0.65rem;
}

.company-contact-persons__title {
    margin: 0 0 0.25rem;
    font-size: 0.9rem;
}

.company-contact-persons__rows {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    margin-bottom: 0.65rem;
}

.company-contact-person-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(9.5rem, 1fr));
    gap: 0.55rem;
    padding: 0.65rem;
    border: 1px solid var(--color-border, #e2e8f0);
    border-radius: 0.55rem;
    background: #fff;
}

.company-contact-person-row .repeatable-row-actions {
    display: flex;
    align-items: flex-end;
}

.company-contact-editor .form-group label {
    font-size: 0.82rem;
    font-weight: 600;
}

.company-contact-editor .form-group input,
.company-contact-editor .form-group select,
.company-contact-editor .form-group textarea {
    font-size: 0.875rem;
    padding: 0.45rem 0.6rem;
}

.company-contact-editor .form-group textarea {
    min-height: 4.5rem;
}

.company-contact-editor .hint {
    font-size: 0.78rem;
}

.company-contact-editor .company-contact-rating__caption {
    font-size: 0.68rem;
}

.company-contact-list-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 0.75rem 1.25rem;
    margin-bottom: 0.85rem;
}

.company-contact-list-title {
    margin: 0;
    font-size: 1.1rem;
}

.company-contact-filter {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 0.65rem 0.85rem;
    flex: 1 1 18rem;
    justify-content: flex-end;
}

.company-contact-filter__search {
    margin: 0;
    flex: 1 1 14rem;
    min-width: 12rem;
    max-width: 22rem;
}

.company-contact-filter__inactive {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    margin: 0 0 0.35rem;
    font-size: 0.875rem;
    white-space: nowrap;
}

.company-contact-category-row {
    background: #f1f5f9;
}

.company-contact-category-row td {
    padding-top: 0.55rem;
    padding-bottom: 0.45rem;
}

.company-contact-category-toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
    color: #2563eb;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
    text-align: left;
}

.company-contact-category-toggle__icon {
    display: inline-block;
    width: 0.55rem;
    height: 0.55rem;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(45deg);
    transition: transform 0.12s ease;
    flex-shrink: 0;
}

.company-contact-category-row.is-collapsed .company-contact-category-toggle__icon,
.company-contact-category-row[aria-expanded="false"] .company-contact-category-toggle__icon {
    transform: rotate(-45deg);
}

.company-contact-category-toggle__count {
    font-weight: 400;
}

.company-contact-company-name {
    padding-left: 1.65rem !important;
}

.company-contact-table .company-contact-company-row.is-filter-hidden,
.company-contact-table .company-contact-company-row.is-category-collapsed,
.company-contact-table .company-contact-category-row.is-filter-hidden {
    display: none;
}

.company-contact-categories-field {
    margin: 0.85rem 0 0.25rem;
}

.company-contact-category-checks {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    max-height: 22rem;
    overflow: auto;
    padding: 0.55rem 0.65rem;
    border: 1px solid var(--color-border, #e2e8f0);
    border-radius: 0.55rem;
    background: #f8fafc;
}

.company-contact-category-group__title {
    margin: 0 0 0.35rem;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.01em;
    color: var(--color-muted, #64748b);
    text-transform: none;
}

.company-contact-category-group__items {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem 0.75rem;
}

.company-contact-category-check {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    margin: 0;
    font-size: 0.85rem;
    font-weight: 500;
    white-space: normal;
    max-width: 100%;
    cursor: pointer;
}

.company-contact-category-check input {
    margin: 0;
    flex: 0 0 auto;
}

.company-contact-category-add {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: center;
    margin-top: 0.55rem;
}

.grunddaten-page-subtitle {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0.35rem 0.5rem;
}

.grunddaten-page-subtitle__customer,
.grunddaten-page-subtitle__address {
    font-weight: 600;
    color: var(--color-text, #0f172a);
}

.grunddaten-page-subtitle__sep {
    color: var(--color-muted, #64748b);
}

.grunddaten-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    margin: 0 0 1rem;
    padding: 0.3rem;
    border: 1px solid var(--color-border, #e2e8f0);
    border-radius: 10px;
    background: #f8fafc;
}

.grunddaten-tab {
    flex: 1 1 8.5rem;
    margin: 0;
    padding: 0.55rem 0.75rem;
    border: 1px solid transparent;
    border-radius: 8px;
    background: transparent;
    color: inherit;
    font: inherit;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    text-align: center;
}

.grunddaten-tab:hover {
    background: #fff;
    border-color: #cbd5e1;
}

.grunddaten-tab.is-active {
    background: #fff;
    border-color: var(--color-primary, #0f766e);
    color: var(--color-primary-dark, #0f766e);
    box-shadow: 0 0 0 1px rgba(15, 118, 110, 0.12);
}

.grunddaten-tab-panel:not(.is-active) {
    display: none;
}

.grunddaten-tab-panel.is-active {
    display: block;
}

.grunddaten-tab-panel .form-section-title {
    margin-top: 1rem;
    margin-bottom: 0.45rem;
    font-size: 0.95rem;
}

.grunddaten-vertrag-akte {
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid var(--color-border, #e2e8f0);
}

.grunddaten-vertrag-dropzone {
    margin: 0.75rem 0;
}

.grunddaten-vertrag-status {
    margin: 0.5rem 0 0;
}

.grunddaten-vertrag-status.is-error {
    color: #8a1f1f;
}

.grunddaten-vertrag-items {
    list-style: none;
    margin: 0.75rem 0 0;
    padding: 0;
    display: grid;
    gap: 0.5rem;
}

.grunddaten-vertrag-item {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
    padding: 0.65rem 0.85rem;
    border: 1px solid var(--color-border, #e2e8f0);
    border-radius: 8px;
    background: var(--color-surface-muted, #f8faf9);
}

.grunddaten-vertrag-item a {
    font-weight: 600;
    word-break: break-word;
}

.grunddaten-vertrag-dialog {
    border: 1px solid var(--color-border, #e2e8f0);
    border-radius: 12px;
    padding: 0;
    max-width: min(28rem, calc(100vw - 2rem));
    width: 100%;
    box-shadow: 0 16px 40px rgba(15, 23, 42, 0.18);
}

.grunddaten-vertrag-dialog::backdrop {
    background: rgba(15, 23, 42, 0.35);
}

.grunddaten-vertrag-dialog-inner {
    padding: 1.1rem 1.2rem 1.2rem;
}

.grunddaten-vertrag-dialog-inner h3 {
    margin: 0 0 0.5rem;
    font-size: 1.05rem;
}

.grunddaten-vertrag-dialog-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: flex-end;
    margin-top: 1rem;
}

.staff-create-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: center;
    margin-top: 0.75rem;
}

.staff-login-list {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
}

.staff-login-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem 1rem;
    justify-content: space-between;
    align-items: flex-start;
    padding: 0.7rem 0.8rem;
    border: 1px solid var(--color-border, #e2e8f0);
    border-radius: 8px;
    background: #fff;
}

.staff-login-row.is-editing {
    border-color: #93c5fd;
    background: #f8fbff;
}

.staff-edit-form {
    flex: 1 1 100%;
    max-width: none;
    margin: 0.25rem 0 0;
    padding-top: 0.65rem;
    border-top: 1px solid var(--color-border, #e2e8f0);
}

.person-groups-sidebar .form--compact {
    max-width: none;
}

.staff-login-row.is-inactive {
    opacity: 0.7;
}

.staff-login-meta {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
    min-width: 12rem;
}

.staff-login-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    align-items: center;
}

.staff-inline-form {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    align-items: center;
    margin: 0;
}

.staff-mail-toggle {
    display: inline-flex;
    gap: 0.3rem;
    align-items: center;
    font-size: 0.85rem;
    color: var(--color-text-muted, #64748b);
}

.staff-access-note {
    margin-top: 1rem;
    border-color: var(--color-primary, #2563eb);
}

.staff-access-note-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    justify-content: space-between;
    align-items: center;
}

.staff-access-slip {
    margin-top: 0.75rem;
    padding: 1rem 1.1rem;
    border: 1px dashed var(--color-border, #cbd5e1);
    border-radius: 8px;
    background: #fff;
}

.staff-access-slip h3 {
    margin: 0 0 0.75rem;
    font-size: 1.1rem;
}

.staff-access-dl {
    display: grid;
    gap: 0.65rem;
    margin: 0;
}

.staff-access-dl > div {
    display: grid;
    gap: 0.15rem;
}

.staff-access-dl dt {
    font-size: 0.8rem;
    color: var(--color-text-muted, #64748b);
}

.staff-access-dl dd {
    margin: 0;
    word-break: break-word;
}

.staff-access-secret {
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 1.05rem;
    font-weight: 600;
}

.staff-access-link {
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 0.9rem;
}

@media print {
    body:has(.staff-access-note) header,
    body:has(.staff-access-note) footer,
    body:has(.staff-access-note) nav,
    body:has(.staff-access-note) .page-toolbar,
    body:has(.staff-access-note) .card:not(.staff-access-note),
    body:has(.staff-access-note) .person-groups-layout,
    body:has(.staff-access-note) .no-print {
        display: none !important;
    }

    body:has(.staff-access-note) .staff-access-note {
        border: none;
        box-shadow: none;
        margin: 0;
        padding: 0;
    }

    body:has(.staff-access-note) .staff-access-slip {
        border: 1px solid #000;
    }
}

/* Mail-Anhang-Picker: Drag & Drop + kumulatives Auswählen */
.mail-attachment-picker {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.mail-attachment-picker-input {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.mail-attachment-dropzone {
    border: 2px dashed #a0aec0;
    border-radius: 8px;
    padding: 0.85rem 1rem;
    background: #f7fafc;
    text-align: center;
    cursor: pointer;
    transition: border-color 0.15s ease, background 0.15s ease;
}

.mail-attachment-dropzone.is-dragover {
    border-color: #3182ce;
    background: #ebf8ff;
}

.mail-attachment-dropzone-title {
    margin: 0 0 0.25rem;
    font-weight: 600;
    font-size: 0.95rem;
}

.mail-attachment-dropzone-hint {
    margin: 0 0 0.65rem;
    color: var(--color-muted, #718096);
    font-size: 0.85rem;
}

.mail-attachment-picker-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.mail-attachment-picker-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.4rem 0.6rem;
    background: #fff;
    border: 1px solid var(--color-border, #e2e8f0);
    border-radius: 6px;
}

.mail-attachment-picker-name {
    font-size: 0.9rem;
    word-break: break-word;
}

.mail-attachment-picker-remove {
    flex: 0 0 auto;
    min-width: 2rem;
    padding: 0.15rem 0.45rem;
    line-height: 1.2;
}

.mail-attachment-picker-status {
    margin: 0;
}

.mail-attachment-picker-status-error {
    color: #c53030;
}

/* Persönliche Barrierefreiheit (data-a11y-active am <html>) */
.user-settings-preview-shell[data-a11y-active="1"] .alert-success {
    background: var(--a11y-success-bg, #e8f5e9);
    color: var(--a11y-success-text, #1b4332);
    border-color: var(--a11y-success-border, #b7dfb9);
}

.user-settings-preview-shell[data-a11y-active="1"] .alert-warning {
    background: var(--a11y-warning-bg, #fff8e1);
    color: var(--a11y-warning-text, #7a5d00);
    border-color: var(--a11y-warning-border, #ffe082);
}

.user-settings-preview-shell[data-a11y-active="1"] .alert-error {
    background: var(--a11y-danger-bg, var(--color-error-bg));
    color: var(--a11y-danger-text, var(--color-error-text));
    border-color: var(--a11y-danger-border, #f5c2c7);
}

.user-settings-preview-shell[data-a11y-active="1"] .alert-info {
    background: var(--a11y-info-bg, #e8f4fd);
    color: var(--a11y-info-text, #0c5460);
    border-color: var(--a11y-info-border, #b8daff);
}

.user-settings-preview-shell[data-a11y-active="1"] .badge-ok {
    background: var(--color-primary-soft, #d8f3dc);
    color: var(--color-primary-dark, #1b4332);
}

.user-settings-preview-shell[data-a11y-active="1"] .badge-warning {
    background: var(--a11y-warning-bg, #fff8e1);
    color: var(--a11y-warning-text, #7a5d00);
}

.user-settings-preview-shell[data-a11y-active="1"] .badge-danger {
    background: var(--a11y-danger-bg, #fdecea);
    color: var(--a11y-danger-text, #9b1c1c);
}

.user-settings-preview-shell[data-a11y-active="1"] .badge-info {
    background: var(--a11y-info-bg, #eef4ff);
    color: var(--a11y-info-text, #274690);
}

.user-settings-preview-shell[data-a11y-active="1"] .app-nav-badge {
    background: var(--a11y-nav-badge-bg, #dc2626);
    color: #fff;
}

.user-settings-preview-shell[data-a11y-active="1"] .user-settings-preview-link a {
    color: var(--color-primary, #2d6a4f);
}

[data-a11y-active="1"] .alert-success,
[data-a11y-active="1"] .user-settings-preview-shell[data-a11y-active="1"] .alert-success {
    background: var(--a11y-success-bg, #e8f5e9);
    color: var(--a11y-success-text, #1b4332);
    border-color: var(--a11y-success-border, #b7dfb9);
}

[data-a11y-active="1"] .alert-warning,
[data-a11y-active="1"] .user-settings-preview-shell[data-a11y-active="1"] .alert-warning {
    background: var(--a11y-warning-bg, #fff8e1);
    color: var(--a11y-warning-text, #7a5d00);
    border-color: var(--a11y-warning-border, #ffe082);
}

[data-a11y-active="1"] .alert-error,
[data-a11y-active="1"] .user-settings-preview-shell[data-a11y-active="1"] .alert-error {
    background: var(--a11y-danger-bg, var(--color-error-bg));
    color: var(--a11y-danger-text, var(--color-error-text));
    border-color: var(--a11y-danger-border, #f5c2c7);
}

[data-a11y-active="1"] .alert-info,
[data-a11y-active="1"] .user-settings-preview-shell[data-a11y-active="1"] .alert-info {
    background: var(--a11y-info-bg, #e8f4fd);
    color: var(--a11y-info-text, #0c5460);
    border-color: var(--a11y-info-border, #b8daff);
}

[data-a11y-active="1"] .badge-ok,
[data-a11y-active="1"] .badge-role,
[data-a11y-active="1"] .badge-report-resolved,
[data-a11y-active="1"] .user-settings-preview-shell[data-a11y-active="1"] .badge-ok {
    background: var(--color-primary-soft, #d8f3dc);
    color: var(--color-primary-dark, #1b4332);
}

[data-a11y-active="1"] .badge-warning,
[data-a11y-active="1"] .user-settings-preview-shell[data-a11y-active="1"] .badge-warning {
    background: var(--a11y-warning-bg, #fff8e1);
    color: var(--a11y-warning-text, #7a5d00);
}

[data-a11y-active="1"] .badge-danger,
[data-a11y-active="1"] .user-settings-preview-shell[data-a11y-active="1"] .badge-danger {
    background: var(--a11y-danger-bg, #fdecea);
    color: var(--a11y-danger-text, #9b1c1c);
}

[data-a11y-active="1"] .badge-info,
[data-a11y-active="1"] .badge-type,
[data-a11y-active="1"] .user-settings-preview-shell[data-a11y-active="1"] .badge-info {
    background: var(--a11y-info-bg, #eef4ff);
    color: var(--a11y-info-text, #274690);
}

[data-a11y-active="1"] .app-nav-badge,
[data-a11y-active="1"] .user-settings-preview-shell[data-a11y-active="1"] .app-nav-badge {
    background: var(--a11y-nav-badge-bg, #dc2626);
    color: #fff;
}

.user-settings-zoom-hint kbd {
    display: inline-block;
    padding: 0.1rem 0.35rem;
    border: 1px solid var(--color-border, #d8e2dc);
    border-radius: 4px;
    background: var(--color-surface, #fff);
    font-size: 0.88em;
    font-family: inherit;
}

.container-user-settings .user-settings-section {
    margin-bottom: 1.25rem;
}

.container-user-settings .user-settings-section h2 {
    margin-top: 0;
}

.user-settings-rules {
    display: grid;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.user-settings-rule-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 10rem) auto;
    gap: 0.65rem;
    align-items: end;
}

.user-settings-rule-arrow {
    padding-bottom: 0.55rem;
    color: var(--color-muted, #5c6670);
    font-weight: 700;
}

.user-settings-rule-to {
    width: 100%;
    min-height: 2.5rem;
    padding: 0.15rem;
    border: 1px solid var(--color-border, #d8e2dc);
    border-radius: 8px;
    background: #fff;
}

.user-settings-preview-shell {
    padding: 1rem;
    border: 1px solid var(--color-border, #d8e2dc);
    border-radius: var(--radius, 12px);
    background: var(--color-bg, #f8faf9);
}

.user-settings-preview-grid {
    display: grid;
    gap: 0.65rem;
    margin-bottom: 0.85rem;
}

.user-settings-preview-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 0.85rem;
}

.user-settings-preview-map {
    display: flex;
    flex-wrap: wrap;
    gap: 0.85rem 1.25rem;
    margin-bottom: 0.75rem;
}

.user-settings-map-item {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.92rem;
}

.user-settings-map-dot {
    width: 0.75rem;
    height: 0.75rem;
    border-radius: 999px;
    border: 1px solid rgba(0, 0, 0, 0.15);
}

.user-settings-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
}

@media (max-width: 720px) {
    .user-settings-rule-row {
        grid-template-columns: 1fr;
    }

    .user-settings-rule-arrow {
        display: none;
    }
}

.form-row-checkbox label {
    display: flex;
    align-items: center;
    gap: 0.45rem;
}
