.version-summary {
    display: grid;
    grid-template-columns: auto auto;
    gap: 2px 12px;
    font-size: 13px;
    color: var(--muted);
}
.version-summary strong { color: var(--text); }
.status-badge {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 4px;
    background: #eef1f5;
    color: #3c4659;
    font-size: 12px;
    font-weight: 750;
}
.status-ready { background: #e7f7ed; color: #176d3b; }
.status-failed { background: #fff0f0; color: #a53232; }
.status-deletion_pending { background: #fff4db; color: #8a5a00; }
/* =========================================================
   Tenant anlegen
   ========================================================= */

.tenant-create-card {
    padding: 0;
    overflow: hidden;
}

.tenant-create-card details {
    width: 100%;
}

.tenant-create-summary {
    list-style: none;
    display: flex;
    align-items: center;
    justify-content: space-between;

    padding: 24px 28px;

    cursor: pointer;

    background:
        linear-gradient(
            180deg,
            rgba(31, 94, 255, 0.025),
            rgba(31, 94, 255, 0.01)
        );
}

.tenant-create-summary::-webkit-details-marker {
    display: none;
}

.tenant-create-summary-left {
    display: flex;
    align-items: center;
    gap: 18px;
}

.tenant-create-icon {
    width: 54px;
    height: 54px;

    border-radius: 50%;

    display: flex;
    align-items: center;
    justify-content: center;

    background: rgba(31, 94, 255, 0.09);
    color: var(--accent);

    font-size: 22px;

    flex: 0 0 auto;
}

.tenant-create-summary h2 {
    margin: 0 0 4px 0;

    font-size: 22px;
    line-height: 1.25;

    color: var(--text);
}

.tenant-create-summary p {
    margin: 0;

    color: var(--muted);
    font-size: 14px;
    line-height: 1.5;
}

.tenant-create-chevron {
    width: 36px;
    height: 36px;

    display: flex;
    align-items: center;
    justify-content: center;

    border: 1px solid var(--line);
    border-radius: 9px;

    background: var(--card);
    color: var(--text);

    transition: transform 0.2s ease;
}

.tenant-create-card details:not([open]) .tenant-create-chevron {
    transform: rotate(180deg);
}

.platform-user-tenant {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.platform-user-tenant + .platform-user-tenant {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid rgba(128, 128, 128, 0.2);
}

.platform-role-form {
    display: flex;
    align-items: center;
    gap: 8px;
}

.platform-role-form select {
    min-width: 130px;
}

.tenant-table-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 18px;
}

.tenant-table-header h2 {
    margin: 0;
}

.tenant-table-header p {
    margin: 4px 0 0;
}

.tenant-schema-status {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    white-space: nowrap;
    font-weight: 600;
}

.tenant-schema-current {
    color: #16803c;
}

.tenant-schema-outdated {
    color: #b66a00;
}

.tenant-schema-error {
    color: var(--color-danger, #c53b3b);
}

.tenant-schema-upgrade {
    display: flex;
    align-items: center;
    gap: 10px;
}

.tenant-schema-upgrade form {
    margin: 0;
}

.tenant-schema-upgrade-button {
    color: #b66a00;
}

.tenant-schema-error-detail {
    max-width: 220px;
    margin-top: 4px;
    overflow: hidden;
    color: var(--color-danger, #c53b3b);
    font-size: 0.78rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.tenant-schema-upgrade-all {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 14px;
    border: 0;
    border-radius: 8px;
    cursor: pointer;
    font: inherit;
    font-weight: 600;
}

/* Formular */

.tenant-create-form {
    border-top: 1px solid var(--line);
}

.tenant-create-fields {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));

    gap: 34px;

    padding: 28px;
}

.tenant-create-fields .field-group {
    min-width: 0;
}

.tenant-create-fields label {
    display: block;

    margin-bottom: 8px;

    font-size: 14px;
    font-weight: 700;

    color: var(--text);
}

.required {
    color: var(--danger);
}


/* Inputs mit Icon */

.input-with-icon {
    display: flex;
    align-items: stretch;

    min-height: 46px;

    border: 1px solid var(--line);
    border-radius: 9px;

    overflow: hidden;

    background: var(--card);

    transition:
        border-color 0.15s ease,
        box-shadow 0.15s ease;
}

.input-with-icon:focus-within {
    border-color: var(--accent);

    box-shadow:
        0 0 0 3px rgba(31, 94, 255, 0.1);
}

.input-with-icon > i {
    width: 46px;

    display: flex;
    align-items: center;
    justify-content: center;

    flex: 0 0 46px;

    color: var(--muted);

    background: rgba(23, 32, 51, 0.025);

    border-right: 1px solid var(--line);
}

.input-with-icon input,
.input-with-icon select {
    width: 100%;
    min-width: 0;

    padding: 0 14px;

    border: 0;
    outline: 0;

    background: transparent;

    color: var(--text);

    font: inherit;
    font-size: 14px;
}

.input-with-icon input::placeholder {
    color: var(--muted);
    opacity: 0.75;
}

.input-with-icon select {
    cursor: pointer;
}


/* Hilfetext */
.field-help {
    margin-top: 8px;
    font-size: 13px;
    line-height: 1.5;
    color: var(--muted);
}

/* Unterer Bereich */
.tenant-create-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 20px 28px;
    border-top: 1px solid var(--line);
}

.tenant-create-info {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    max-width: 680px;
    padding: 12px 16px;
    border-radius: 9px;
    background: rgba(31, 94, 255, 0.04);
    color: var(--muted);
}

.tenant-create-info > i {
    margin-top: 2px;

    color: var(--accent);
    font-size: 17px;
}

.tenant-create-info div {
    display: flex;
    flex-direction: column;

    gap: 2px;
}

.tenant-create-info strong {
    color: var(--text);
    font-size: 13px;
}

.tenant-create-info span {
    font-size: 12px;
    line-height: 1.45;
}

/* Button */
.tenant-create-submit {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    gap: 8px;

    min-height: 44px;

    padding: 0 20px;

    border: 0;
    border-radius: 9px;

    background: var(--accent);
    color: #fff;

    font-size: 14px;
    font-weight: 700;

    white-space: nowrap;

    cursor: pointer;

    box-shadow:
        0 4px 12px rgba(31, 94, 255, 0.18);

    transition:
        transform 0.15s ease,
        box-shadow 0.15s ease,
        opacity 0.15s ease;
}

.tenant-create-submit:hover {
    transform: translateY(-1px);

    box-shadow:
        0 6px 16px rgba(31, 94, 255, 0.24);
}

.tenant-create-submit:active {
    transform: translateY(0);
}

/* Tablet */
@media (max-width: 900px) {

    .tenant-create-fields {
        grid-template-columns: 1fr;
        gap: 22px;
    }

    .tenant-create-footer {
        align-items: stretch;
        flex-direction: column;
    }

    .tenant-create-info {
        max-width: none;
    }

    .tenant-create-submit {
        align-self: flex-end;
    }
}

.btn-icon.restore { color: #176d3b; }
.btn-icon.restore:hover { color: #0f542d; background: #e7f7ed; }
.auth-card { width: min(100%, 460px); margin: 32px auto; }
.auth-card label + label { margin-top: 16px; }
.unauthenticated .main-content {
    width: 100%;
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    box-sizing: border-box;
}

.auth-page {
    width: 100%;
    display: flex;
    justify-content: center;
    box-sizing: border-box;
    padding: 48px 16px;
}

.auth-card {
    width: 100%;
    max-width: 440px;
    box-sizing: border-box;
}

.auth-header {
    margin-bottom: 28px;
    text-align: center;
}

.auth-header h1 {
    margin: 0 0 8px;
}

.auth-header p {
    margin: 0;
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.auth-form label {
    display: flex;
    flex-direction: column;
    gap: 7px;
    font-weight: 600;
}

.auth-form input {
    width: 100%;
    box-sizing: border-box;
}

.auth-form button {
    width: 100%;
    margin-top: 4px;
}

.auth-footer {
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid rgba(128, 128, 128, 0.25);
    text-align: center;
}

.verification-resend {
    margin-top: 16px;
}

.verification-resend summary {
    cursor: pointer;
    font-size: 0.9rem;
}

.verification-resend form {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 16px;
    text-align: left;
}
:root {
    --bg: #f5f7fa;
    --card: #ffffff;
    --text: #172033;
    --muted: #657085;
    --line: #dde3ec;
    --accent: #1f5eff;
    --accent-hover: #1749c9;
    --danger: #c53b3b;
}
* { box-sizing: border-box; }
body {
    min-height: 100vh;
    margin: 0;
    display: flex;
    flex-direction: column;
    font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: var(--bg);
    color: var(--text);
}
header {
    background: var(--header);
    color: white;
    padding: 18px 0;
}
.wrap { width: min(1180px, calc(100% - 40px)); margin: 0 auto; }
.header-inner { display: flex; gap: 14px; align-items: center; }
.brand-short { display: none; }
.brand { color: white; text-decoration: none; font-size: 20px; font-weight: 800; }
.brand-logo {
    display: block;
    width: 220px;
    height: 38px;
    padding: 4px 8px;
    object-fit: contain;
    object-position: left center;
}
.brand-logo-background {
    background: #fff;
    border-radius: 4px;
}
@media (max-width: 600px) {
    .remote-user-info i.fa-circle-user {
        font-size: 22px;
    }
}
.remote-user-info {
    cursor: pointer;
    outline: none;
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: var(--muted);
    user-select: none;
}
.remote-user-info i { font-size: 14px; }
.remote-groups {
    background: var(--line);
    border-radius: 99px;
    padding: 1px 8px;
    font-size: 11px;
}
.user-dropdown {
    margin-left: auto;
    position: relative;
}
.user-dropdown.open .user-dropdown-menu {
    visibility: visible;
    opacity: 1;
    transition: opacity .15s, visibility 0s;
}
/* Nur auf Geräten mit echtem Hover */
@media (hover: hover) and (pointer: fine) {
    .user-dropdown:hover .user-dropdown-menu {
        display: block;
    }
}
.user-dropdown-menu {
    visibility: hidden;
    opacity: 0;
    position: absolute;
    right: 0;
    top: calc(100% + 8px);
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 10px;
    box-shadow: 0 4px 16px rgba(23,32,51,.1);
    min-width: 160px;
    z-index: 100;
    overflow: hidden;
    transition: opacity .15s, visibility 0s linear .3s;
}
.user-dropdown-menu a {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 11px 16px;
    font-size: 14px;
    color: var(--text);
    text-decoration: none;
    white-space: nowrap;
}
.user-dropdown-menu a:hover {
    background: #f5f7fa;
    color: #e53935;
}
.user-dropdown:hover .user-dropdown-menu,
.user-dropdown:focus-within .user-dropdown-menu {
    visibility: visible;
    opacity: 1;
    transition: opacity .15s, visibility 0s;
}
.user-menu-tenant {
    padding: 10px 14px;
    border-bottom: 1px solid #e5e7eb;
}

.user-menu-tenant span {
    display: block;
    margin-bottom: 2px;

    color: var(--color-muted, #657085);
    font-size: 0.75rem;
}

.user-menu-tenant strong {
    display: block;

    color: var(--color-text, #172033);
    font-size: 0.9rem;
    font-weight: 600;
}
.user-create-card {
    padding: 0;
    overflow: hidden;
}

.user-create-card details {
    width: 100%;
}

.user-create-summary {
    list-style: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 24px 28px;
    cursor: pointer;

    background:
        linear-gradient(
            180deg,
            rgba(31, 94, 255, 0.025),
            rgba(31, 94, 255, 0.01)
        );
}

.user-create-summary::-webkit-details-marker {
    display: none;
}

.user-create-summary-left {
    display: flex;
    align-items: center;
    gap: 18px;
}

.user-create-icon {
    width: 54px;
    height: 54px;
    border-radius: 50%;

    display: flex;
    align-items: center;
    justify-content: center;

    background: rgba(31, 94, 255, 0.09);
    color: var(--accent);

    font-size: 22px;
    flex: 0 0 auto;
}

.user-create-summary h2 {
    margin: 0 0 4px 0;
    font-size: 22px;
    line-height: 1.25;
    color: var(--text);
}

.user-create-summary p {
    margin: 0;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.5;
}

.user-create-chevron {
    width: 36px;
    height: 36px;

    display: flex;
    align-items: center;
    justify-content: center;

    border: 1px solid var(--line);
    border-radius: 9px;

    background: var(--card);
    color: var(--text);

    transition: transform 0.2s ease;
}

.user-create-card details:not([open]) .user-create-chevron {
    transform: rotate(180deg);
}

.user-create-form {
    border-top: 1px solid var(--line);
}

.user-create-fields {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 28px;
    padding: 28px;
}

.user-create-fields .field-group {
    min-width: 0;
}

.user-create-fields label {
    display: block;
    margin-bottom: 8px;

    font-size: 14px;
    font-weight: 700;
    color: var(--text);
}

.user-create-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 24px;
    padding: 20px 28px;

    border-top: 1px solid var(--line);
}

.user-create-info {
    display: flex;
    align-items: flex-start;
    gap: 12px;

    max-width: 680px;
    padding: 12px 16px;

    border-radius: 9px;
    background: rgba(31, 94, 255, 0.04);

    color: var(--muted);
}

.user-create-info > i {
    margin-top: 2px;
    color: var(--accent);
    font-size: 17px;
}

.user-create-info div {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.user-create-info strong {
    color: var(--text);
    font-size: 13px;
}

.user-create-info span {
    font-size: 12px;
    line-height: 1.45;
}

.user-create-submit {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    gap: 8px;
    min-height: 44px;
    padding: 0 20px;

    border: 0;
    border-radius: 9px;

    background: var(--accent);
    color: #fff;

    font-size: 14px;
    font-weight: 700;

    white-space: nowrap;
    cursor: pointer;

    box-shadow:
        0 4px 12px rgba(31, 94, 255, 0.18);

    transition:
        transform 0.15s ease,
        box-shadow 0.15s ease;
}

.user-create-submit:hover {
    transform: translateY(-1px);
    box-shadow:
        0 6px 16px rgba(31, 94, 255, 0.24);
}

@media (max-width: 1000px) {
    .user-create-fields {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 700px) {
    .user-create-fields {
        grid-template-columns: 1fr;
    }

    .user-create-footer {
        flex-direction: column;
        align-items: stretch;
    }

    .user-create-submit {
        width: 100%;
    }
}
.subtitle { color: #a9b4c7; }
main {
    flex: 1;
    padding: 38px 0 70px;
}
.app-footer {
    border-top: 1px solid var(--line);
    padding: 18px 0;
    color: var(--muted);
    font-size: 12px;
}
.app-footer-inner {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 6px 14px;
}
.app-footer-inner span + span::before {
    content: "·";
    margin-right: 14px;
}
h1 { font-size: 34px; margin: 0 0 8px; }
h2 { margin-top: 0; }
.hero { margin-bottom: 28px; }
.hero p, .muted { color: var(--muted); }
.card {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 24px;
    margin: 0 0 22px;
    box-shadow: 0 3px 15px rgba(23, 32, 51, .04);
}
.grid, .mapping {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}
.mapping { margin: 18px 0 26px; }
label { display: flex; flex-direction: column; gap: 7px; font-weight: 650; }
input, select {
    width: 100%;
    border: 1px solid #cfd6e2;
    border-radius: 9px;
    padding: 11px 12px;
    background: white;
    font: inherit;
}
button, .button {
    display: inline-block;
    margin-top: 18px;
    border: 0;
    border-radius: 9px;
    padding: 11px 16px;
    background: var(--accent);
    color: white;
    text-decoration: none;
    font: inherit;
    font-weight: 750;
    cursor: pointer;
}
button:hover { background: var(--accent-hover); }
.button.secondary, button.secondary {
    background: #e8edf5;
    color: #293349;
}
button.danger { background: var(--danger); }
.button.danger:hover, button.danger:hover { background: #c53b3b; }
.required { color: var(--danger); }
.table-wrap { overflow-x: auto; }
table { border-collapse: collapse; width: 100%; min-width: 700px; }
th, td {
    text-align: left;
    border-bottom: 1px solid var(--line);
    padding: 11px 12px;
    vertical-align: top;
}
th { background: #f8fafc; font-size: 13px; color: #4a556b; }
.actions, .title-row, .inline-form {
    display: flex;
    gap: 12px;
    align-items: center;
    justify-content: space-between;
}
.actions .button, .title-row button, .inline-form button { margin-top: 0;}
.flash {
    border-radius: 10px;
    padding: 12px 15px;
    margin-bottom: 18px;
    border: 1px solid;
}
.actions {
    margin-bottom: 22px;
}
.flash.success { background: #ebf8f0; border-color: #b7e2c8; }
.flash.error { background: #fff0f0; border-color: #efc0c0; }
@media (max-width: 700px) {
    .grid, .mapping { grid-template-columns: 1fr; }
    .title-row, .inline-form { align-items: stretch; flex-direction: column; }
    .version-summary { align-self: flex-start; }
}


nav {
    margin-left: auto;
    display: flex;
    gap: 16px;
}
nav a {
    color: #d7dfec;
    text-decoration: none;
    font-weight: 650;
}
nav a:hover { color: white; }
.nav-saas, .nav-legacy {
    padding-left: 16px;
    border-left: 1px solid rgba(255,255,255,.3);
}
.saas-hero {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 16px;
}
.hero-action { margin-top: 0; white-space: nowrap; }
.import-card { min-width: 760px; }


/* iPad / touch packing mode */
.packing-shell {
    max-width: 1050px;
    margin: 0 auto;
}
.packing-sticky {
    position: sticky;
    top: 0;
    z-index: 20;
    background: rgba(245,247,250,.96);
    backdrop-filter: blur(12px);
    padding: 10px 0 16px;
    margin-bottom: 14px;
}
.packing-title-row {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 16px;
}
.packing-title-row h1 {
    margin: 4px 0 0;
    font-size: clamp(24px, 4vw, 38px);
}
.back-link {
    text-decoration: none;
    color: var(--accent);
    font-weight: 750;
}
.packing-total {
    font-size: clamp(22px, 4vw, 34px);
    white-space: nowrap;
}
.progress-track {
    height: 10px;
    background: #dfe5ee;
    border-radius: 999px;
    overflow: hidden;
}
.progress-track.big {
    height: 16px;
    margin-top: 14px;
}
.progress-fill {
    height: 100%;
    background: #2f80ed;
    border-radius: inherit;
    transition: width .18s ease;
}
.packing-percent {
    margin-top: 6px;
    text-align: right;
    color: var(--muted);
    font-weight: 700;
}
.sort-bar {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
    margin-top: 10px;
}
.sort-label {
    font-size: 13px;
    color: var(--muted);
    margin-right: 2px;
}
.sort-btn {
    background: #f0f3f8;
    border: 1px solid var(--line);
    border-radius: 99px;
    padding: 4px 12px;
    font-size: 13px;
    font-weight: 600;
    color: var(--text);
    cursor: pointer;
    margin-top: 0;
}
.sort-btn:hover { background: #e4e9f2; }
.sort-btn.active {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}
.packlist-card {
    position: relative;

    margin-bottom: 18px;
    padding: 24px;

    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 14px;

    box-shadow: 0 3px 15px rgba(23, 32, 51, 0.04);
}

.packlist-card-link {
    display: block;

    color: inherit;
    text-decoration: none;
}

.packlist-header-content {
    padding-right: 82px;
}

.packlist-actions {
    position: absolute;
    top: 24px;
    right: 24px;

    display: flex;
    align-items: center;
    gap: 6px;

    z-index: 2;
}

.packlist-actions form {
    margin: 0;
}

.icon-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 30px;
    height: 30px;
    margin: 0;
    padding: 0;

    border: 1px solid var(--line);
    border-radius: 6px;

    background: transparent;
    color: var(--muted);

    font-size: 13px;
    line-height: 1;

    cursor: pointer;

    transition:
        background 0.15s ease,
        border-color 0.15s ease,
        color 0.15s ease;
}

.icon-action:hover {
    border-color: var(--accent);
    background: rgba(31, 94, 255, 0.08);
    color: var(--accent);
}

.icon-action-danger {
    border-color: rgba(197, 59, 59, 0.3);
    color: var(--danger);
}

.icon-action-danger:hover {
    border-color: var(--danger);
    background: rgba(197, 59, 59, 0.08);
    color: var(--danger);
}

@media (max-width: 600px) {
    .packlist-card {
        padding: 16px;
    }

    .packlist-header-content {
        padding-right: 88px;
    }

    .packlist-actions {
        top: 16px;
        right: 16px;
    }

    .icon-action {
        width: 36px;
        height: 36px;

        font-size: 14px;
    }
}

.packlist-name {
    font-size: 22px;
    font-weight: 850;
    margin-bottom: 4px;
}
.packlist-meta {
    color: var(--muted);
    margin-bottom: 14px;
    display: flex;
    flex-direction: column;
    gap: 3px;
}
.packlist-event {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 13px;
}
.packlist-progress {
    display: flex;
    justify-content: space-between;
    margin-top: 8px;
}
.packing-event-meta {
    margin-top: 4px;
    font-size: 14px;
    display: flex;
    gap: 6px;
    align-items: center;
    flex-wrap: wrap;
}
.packing-category {
    margin: 24px 0 30px;
}
.packing-category h2 {
    font-size: 21px;
    margin: 0 0 10px;
}
.packing-items {
    grid-column: 1;
    display: grid;
    gap: 10px;
}
.packing-item {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 18px;
    align-items: center;
    background: white;
    border: 2px solid transparent;
    border-radius: 16px;
    padding: 16px;
    box-shadow: 0 2px 10px rgba(23,32,51,.05);
    transition: background .15s ease, border-color .15s ease, opacity .15s ease;
}
.packing-item.complete {
    background: #e9f8ee;
    border-color: #8fd3a5;
}
.packing-item.complete .packing-item-name {
    text-decoration: line-through;
    opacity: .72;
}
.packing-item.save-error {
    border-color: #d64c4c;
}
.packing-item-name {
    font-size: 20px;
    font-weight: 800;
    line-height: 1.25;
}
.packing-item-notes {
    margin-top: 6px;
    color: #9a5b00;
    font-weight: 700;
}
.packing-item-meta {
    display: flex;
    gap: 12px;
    margin-top: 5px;
    color: var(--muted);
    font-size: 13px;
    white-space: nowrap;
}
.packing-counter {
    display: grid;
    grid-template-columns: 56px 92px 56px;
    gap: 8px;
    align-items: stretch;
}
.count-btn,
.count-display {
    margin: 0;
    min-height: 60px;
    border-radius: 13px;
    font-size: 28px;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}
.count-btn {
    padding: 0;
    background: #e8edf5;
    color: #1d2738;
}
.count-btn.plus {
    background: #1f5eff;
    color: white;
}
.count-display {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 0 8px;
    background: #f6f8fb;
    color: #172033;
    font-size: 22px;
    font-weight: 850;
}
.count-separator {
    opacity: .35;
}
.reset-section {
    padding: 25px 0 80px;
}
.reset-btn {
    width: 100%;
    min-height: 54px;
}
@media (max-width: 840px) {
    .wrap {
        width: min(100% - 20px, 1180px);
    }
    main {
        padding-top: 18px;
    }
    .app-footer {
        padding: 14px 0;
        font-size: 11px;
    }
    .app-footer-inner {
        justify-content: center;
    }
    header {
        padding: 12px 0;
    }
    .brand-full { display: none; }
    .brand-logo {
        width: 116px;
        height: 30px;
    }
    .subtitle {
        display: none;
    }
    .user-name, .user-groups, .user-chevron { display: none; }
    nav {
        gap: 10px;
        font-size: 14px;
    }
    .sort-bar {
        transition: opacity .15s ease, max-height .15s ease, margin-top .15s ease;
        max-height: 100px;
        overflow: hidden;
    }
    .sort-bar.scroll-hidden {
        opacity: 0;
        max-height: 0;
        margin-top: 0;
        pointer-events: none;
    }
    .packing-item {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    .packing-item-name {
        font-size: var(--mobile-packing-font-size);
    }
    .packing-item-notes,
    .packing-item-meta {
        font-size: var(--mobile-packing-meta-font-size);
    }
    .packing-counter {
        grid-template-columns: 39px minmax(70px, 1fr) 39px;
        width: 100%;
    }
    .count-btn,
    .count-display {
        min-height: var(--mobile-packing-counter-height);
        font-size: var(--mobile-packing-counter-font-size);
        border-radius: 9px;
    }
}


.settings-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
    margin: 20px 0;
}
.field-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.field-group label {
    font-size: 13px;
    font-weight: 600;
    color: var(--text);
}
.field-group input,
.field-group select {
    padding: 9px 12px;
    border: 1px solid var(--line);
    border-radius: 8px;
    font-size: 14px;
    background: #fff;
    color: var(--text);
    outline: none;
    transition: border-color .15s;
}
.field-group input:focus,
.field-group select:focus {
    border-color: var(--accent);
}
.range-field input[type="range"] {
    width: min(100%, 360px);
    padding: 0;
    border: 0;
    accent-color: var(--accent);
}
.color-settings input[type="color"] {
    width: 100%;
    height: 42px;
    padding: 4px;
    cursor: pointer;
}
.checkbox-label {
    display: grid;
    grid-template-columns: 16px minmax(0, 1fr);
    align-items: center;
    gap: 8px;
    width: 100%;
    min-height: 42px;
    margin-top: 6px;
    padding: 9px 12px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--card);
    font-size: 13px;
    font-weight: 500;
    color: var(--muted);
    text-align: left;
    cursor: pointer;
}
.checkbox-label:hover { border-color: var(--accent); }
.field-group .checkbox-label input[type="checkbox"] {
    width: 16px;
    height: 16px;
    min-height: 0;
    margin: 0;
    padding: 0;
    flex: 0 0 auto;
    accent-color: var(--accent);
}
.brand-preview {
    display: block;
    max-width: 260px;
    max-height: 100px;
    margin: 4px 0 12px;
    object-fit: contain;
    object-position: left center;
}
@media (max-width: 700px) {
    .settings-form-grid { grid-template-columns: 1fr; }
}

.settings-summary {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin: 20px 0;
}
.settings-summary > div {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 14px;
    background: #f7f9fc;
    border: 1px solid var(--line);
    border-radius: 10px;
}
.settings-summary span {
    color: var(--muted);
    font-size: 13px;
}
.env-example {
    overflow-x: auto;
    background: #111827;
    color: #eef2f7;
    padding: 18px;
    border-radius: 10px;
    line-height: 1.6;
}
@media (max-width: 700px) {
    .settings-summary {
        grid-template-columns: 1fr;
    }
}

/* =========================================================
   RESPONSIVE VISIBILITY
   CrewLoad
   ========================================================= */


/*
 * Standardmäßig sind Tablet-/Desktop-Elemente sichtbar.
 * Die Klasse muss deshalb außerhalb der Media Query
 * nichts verändern.
 */


/* ---------------------------------------------------------
   Nur auf Smartphone sichtbar
   --------------------------------------------------------- */

.mobile-only {
    display: none !important;
}


/* ---------------------------------------------------------
   Smartphone
   Bis einschließlich 600px Breite
   --------------------------------------------------------- */

@media (max-width: 600px) {

    /*
     * Elemente mit dieser Klasse auf Smartphones ausblenden.
     *
     * Beispiel:
     * <a class="desktop-tablet-only">Einstellungen</a>
     */
    .desktop-tablet-only {
        display: none !important;
    }

    /*
     * Alternative/kurze Bezeichnung.
     * Kann verwendet werden, wenn ein beliebiges Element
     * auf dem Smartphone verschwinden soll.
     */
    .mobile-hidden {
        display: none !important;
    }

    /*
     * Elemente, die ausschließlich auf Smartphones
     * angezeigt werden sollen.
     */
    .mobile-only {
        display: block !important;
    }
}

/* ---------------------------------------------------------
   Changelog-Syling
   --------------------------------------------------------- */
.changelog {
    line-height: 1.6;
}

.changelog h1 {
    margin-top: 0;
}

.changelog h2 {
    margin-top: 2rem;
    padding-bottom: 0.4rem;
    border-bottom: 1px solid var(--muted);
}

.changelog h3 {
    margin-top: 1.2rem;
}

.changelog ul {
    padding-left: 1.5rem;
}

.changelog li {
    margin-bottom: 0.35rem;
}


/* =========================================================
   Company Setup / Onboarding
   ========================================================= */
.company-setup {
    width: 100%;
    max-width: 650px;
    margin: 60px auto;
}

.company-setup-card {
    background: var(--color-card, #ffffff);
    border: 1px solid #dfe5ee;
    border-radius: 18px;
    padding: 42px;
    box-shadow:
        0 1px 2px rgba(15, 23, 42, 0.03),
        0 12px 32px rgba(15, 23, 42, 0.06);
}

.company-setup-icon {
    width: 58px;
    height: 58px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 24px;
    border-radius: 16px;
    background: rgba(31, 94, 255, 0.1);
}

.company-setup-icon svg {
    width: 29px;
    height: 29px;
    fill: none;
    stroke: var(--color-accent, #1f5eff);
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.company-setup-heading {
    margin-bottom: 28px;
}

.setup-eyebrow {
    display: block;
    margin-bottom: 7px;
    color: var(--color-accent, #1f5eff);
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.company-setup-heading h1 {
    margin: 0 0 10px;
    color: var(--color-text, #172033);
    font-size: 30px;
    line-height: 1.2;
}

.company-setup-heading p {
    margin: 0;
    max-width: 500px;
    color: var(--color-muted, #657085);
    font-size: 16px;
    line-height: 1.55;
}

/* User */
.setup-user {
    display: flex;
    align-items: center;
    gap: 13px;
    margin-bottom: 32px;
    padding: 14px 16px;
    background: #f8fafc;
    border: 1px solid #e7ebf1;
    border-radius: 12px;
}

.setup-user-avatar {
    flex: 0 0 40px;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--color-accent, #1f5eff);
    color: #ffffff;
    font-size: 16px;
    font-weight: 700;
}

.setup-user-info {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.setup-user-info span {
    margin-bottom: 2px;
    color: var(--color-muted, #657085);
    font-size: 12px;
}

.setup-user-info strong {
    color: var(--color-text, #172033);
    font-size: 14px;
}

.setup-user-info small {
    margin-top: 2px;
    color: var(--color-muted, #657085);
    font-size: 12px;
}

/* Form */
.company-setup-form .form-group {
    margin-bottom: 24px;
}

.company-setup-form label {
    display: block;
    margin-bottom: 8px;
    color: var(--color-text, #172033);
    font-size: 14px;
    font-weight: 650;
}

.input-with-icon {
    position: relative;
}

.input-with-icon svg {
    position: absolute;
    top: 50%;
    left: 16px;
    width: 20px;
    height: 20px;
    transform: translateY(-50%);
    fill: none;
    stroke: #7b879b;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
    pointer-events: none;
}

.input-with-icon input {
    width: 100%;
    box-sizing: border-box;
    height: 52px;
    padding: 0 16px 0 48px;
    border: 1px solid #ccd5e2;
    border-radius: 10px;
    outline: none;
    background: #ffffff;
    color: var(--color-text, #172033);
    font: inherit;
    font-size: 15px;
    transition:
        border-color 0.15s ease,
        box-shadow 0.15s ease;
}

.input-with-icon input::placeholder {
    color: #9aa4b5;
}

.input-with-icon input:focus {
    border-color: var(--color-accent, #1f5eff);
    box-shadow: 0 0 0 3px rgba(31, 94, 255, 0.12);
}

.form-help {
    margin: 8px 0 0;
    color: var(--color-muted, #657085);
    font-size: 13px;
    line-height: 1.45;
}

/* Info */
.setup-info {
    display: flex;
    gap: 12px;
    margin: 28px 0;
    padding: 15px 16px;
    border-radius: 11px;
    background: rgba(31, 94, 255, 0.055);
}

.setup-info > svg {
    flex: 0 0 20px;
    width: 20px;
    height: 20px;
    margin-top: 1px;
    fill: none;
    stroke: var(--color-accent, #1f5eff);
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.setup-info strong {
    display: block;
    margin-bottom: 3px;
    color: var(--color-text, #172033);
    font-size: 13px;
}

.setup-info p {
    margin: 0;
    color: var(--color-muted, #657085);
    font-size: 13px;
    line-height: 1.5;
}

/* Button */
.company-setup-submit {
    width: 100%;
    height: 52px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;

    border: 0;
    border-radius: 10px;

    background: var(--color-accent, #1f5eff);
    color: #ffffff;

    font: inherit;
    font-size: 15px;
    font-weight: 700;

    cursor: pointer;

    transition:
        transform 0.1s ease,
        box-shadow 0.15s ease,
        opacity 0.15s ease;
}

.company-setup-submit:hover {
    box-shadow: 0 7px 18px rgba(31, 94, 255, 0.22);
}

.company-setup-submit:active {
    transform: translateY(1px);
}

.company-setup-submit svg {
    width: 19px;
    height: 19px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* Footer */
.company-setup-footer {
    margin: 18px auto 0;
    padding: 0 20px;
    color: var(--color-muted, #657085);
    font-size: 12px;
    line-height: 1.5;
    text-align: center;
}

/* Mobile */
@media (max-width: 700px) {
    .company-setup {
        margin: 24px auto;
    }
    .company-setup-card {
        padding: 28px 22px;
        border-radius: 14px;
    }
    .company-setup-heading h1 {
        font-size: 25px;
    }
}


/* =========================================================
   User Administration
   ========================================================= */

.user-admin-page {
    display: flex;
    flex-direction: column;
    gap: 24px;
}


/* ---------- Page Header ---------- */

.user-admin-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
    margin: 0 0 4px;
    padding: 0;
    background: transparent;
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

.user-admin-header > div:first-child {
    background: transparent;
}

.user-admin-header h1 {
    margin: 0;
    padding: 0;
    color: var(--color-text, #172033);
    font-size: 2rem;
    font-weight: 700;
    line-height: 1.15;
}

.user-admin-header p {
    margin: 8px 0 0;
    padding: 0;
    color: var(--color-muted, #657085);
    font-size: 1rem;
    line-height: 1.45;
}

.user-admin-tenant {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 3px;
    margin: 0;
    padding: 0;
    background: transparent;
    color: var(--color-muted, #657085);
    font-size: 0.875rem;
}

.user-admin-tenant strong {
    color: var(--color-text, #172033);
    font-weight: 650;
}


/* ---------- Administration Cards ---------- */

.admin-card {
    overflow: hidden;
    background: var(--color-card, #ffffff);
    border: 1px solid #dce3ed;
    border-radius: 16px;
    box-shadow: 0 4px 14px rgba(23, 32, 51, 0.035);
}

.admin-card-header {
    display: flex;
    align-items: center;
    gap: 18px;
    padding: 26px 30px;
    border-bottom: 1px solid #e1e6ee;
    background: linear-gradient(
        90deg,
        rgba(248, 250, 253, 0.95),
        rgba(255, 255, 255, 0.7)
    );
}

.admin-card-icon {
    display: flex;
    flex: 0 0 56px;
    width: 56px;
    height: 56px;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #e8efff;
    color: var(--color-accent, #1f5eff);
    font-size: 1.35rem;
}

.admin-card-heading {
    flex: 1;
    min-width: 0;
}

.admin-card-heading h2 {
    margin: 0;
    color: var(--color-text, #172033);
    font-size: 1.35rem;
    line-height: 1.25;
}

.admin-card-heading p {
    margin: 5px 0 0;
    color: var(--color-muted, #657085);
    line-height: 1.45;
}

.admin-card-toggle {
    display: flex;
    width: 40px;
    height: 40px;
    align-items: center;
    justify-content: center;
    border: 1px solid #d8e0eb;
    border-radius: 10px;
    background: #ffffff;
    color: var(--color-text, #172033);
    cursor: pointer;
}

.admin-card-body {
    padding: 28px 30px 30px;
}


/* ---------- Invitation Form ---------- */

.invitation-form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 28px;
}

.admin-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.admin-field label {
    color: var(--color-text, #172033);
    font-size: 0.9rem;
    font-weight: 650;
}

.required {
    color: var(--color-danger, #c53b3b);
}

.admin-input-group {
    display: flex;
    min-height: 50px;
    overflow: hidden;
    border: 1px solid #ccd6e3;
    border-radius: 10px;
    background: #ffffff;
    transition:
        border-color 0.15s ease,
        box-shadow 0.15s ease;
}

.admin-input-group:focus-within {
    border-color: var(--color-accent, #1f5eff);
    box-shadow: 0 0 0 3px rgba(31, 94, 255, 0.1);
}

.admin-input-icon {
    display: flex;
    width: 50px;
    flex: 0 0 50px;
    align-items: center;
    justify-content: center;
    border-right: 1px solid #dce3ed;
    background: #fbfcfe;
    color: #687791;
}

.admin-input-group input,
.admin-input-group select {
    width: 100%;
    min-width: 0;
    border: 0;
    outline: 0;
    background: transparent;
    padding: 0 16px;
    color: var(--color-text, #172033);
    font: inherit;
}

.admin-input-group input::placeholder {
    color: #a7b1c2;
}

.admin-field-help {
    margin: 0;
    color: var(--color-muted, #657085);
    font-size: 0.83rem;
    line-height: 1.4;
}


/* ---------- Info + Form Action ---------- */

.invitation-form-footer {
    display: flex;
    align-items: center;
    gap: 24px;
    margin-top: 24px;
}

.admin-info-box {
    display: flex;
    flex: 1;
    align-items: flex-start;
    gap: 13px;
    min-height: 62px;
    padding: 13px 16px;
    border-radius: 10px;
    background: #f2f6fd;
    color: var(--color-muted, #657085);
    font-size: 0.86rem;
    line-height: 1.4;
}

.admin-info-box > i {
    margin-top: 2px;
    color: var(--color-accent, #1f5eff);
    font-size: 1rem;
}

.admin-info-box strong {
    display: block;
    margin-bottom: 2px;
    color: var(--color-text, #172033);
}

.admin-primary-button {
    display: inline-flex;
    min-height: 48px;
    align-items: center;
    justify-content: center;
    gap: 9px;
    padding: 0 22px;
    border: 0;
    border-radius: 9px;
    background: var(--color-accent, #1f5eff);
    box-shadow: 0 5px 12px rgba(31, 94, 255, 0.18);
    color: #ffffff;
    font: inherit;
    font-weight: 650;
    white-space: nowrap;
    cursor: pointer;
    transition:
        transform 0.12s ease,
        box-shadow 0.12s ease;
}

.admin-primary-button:hover {
    transform: translateY(-1px);
    box-shadow: 0 7px 16px rgba(31, 94, 255, 0.23);
}


/* ---------- Tables ---------- */

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

.admin-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    font-size: 0.9rem;
}

.admin-table th {
    padding: 13px 16px;
    background: #f3f6fa;
    color: var(--color-text, #172033);
    font-size: 0.82rem;
    font-weight: 650;
    text-align: left;
    white-space: nowrap;
}

.admin-table th:first-child {
    border-radius: 10px 0 0 0;
}

.admin-table th:last-child {
    border-radius: 0 10px 0 0;
}

.admin-table td {
    padding: 14px 16px;
    border-bottom: 1px solid #e4e9f0;
    color: var(--color-text, #172033);
    vertical-align: middle;
}

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

.admin-table tbody tr:hover td {
    background: #fbfcfe;
}

.admin-table-empty {
    padding: 28px !important;
    color: var(--color-muted, #657085) !important;
    text-align: center;
}


/* ---------- Role Badges ---------- */

.role-badge {
    display: inline-flex;
    align-items: center;
    min-height: 26px;
    padding: 3px 11px;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 650;
}

.role-owner {
    background: #e4e8ff;
    color: #3045b5;
}

.role-admin {
    background: #e3edff;
    color: #1f5eff;
}

.role-dispatcher {
    background: #fff0c8;
    color: #946700;
}

.role-packer {
    background: #dcf3df;
    color: #28763b;
}


/* ---------- Delete / Revoke Button ---------- */

.admin-danger-button {
    display: inline-flex;
    width: 34px;
    height: 34px;
    align-items: center;
    justify-content: center;
    border: 1px solid #ffd0d0;
    border-radius: 8px;
    background: #fff1f1;
    color: #e33636;
    cursor: pointer;
    transition:
        background 0.12s ease,
        border-color 0.12s ease;
}

.admin-danger-button:hover {
    border-color: #ffbcbc;
    background: #ffe5e5;
}


/* ---------- Responsive ---------- */

@media (max-width: 800px) {
    .user-admin-header {
        flex-direction: column;
    }

    .user-admin-tenant {
        align-items: flex-start;
    }

    .invitation-form-grid {
        grid-template-columns: 1fr;
        gap: 18px;
    }

    .invitation-form-footer {
        flex-direction: column;
        align-items: stretch;
    }

    .admin-primary-button {
        width: 100%;
    }

    .admin-card-header {
        padding: 20px;
    }

    .admin-card-body {
        padding: 20px;
    }
}

@media (max-width: 520px) {
    .admin-card-icon {
        width: 46px;
        height: 46px;
        flex-basis: 46px;
    }

    .admin-card-header {
        gap: 13px;
    }

    .admin-card-heading h2 {
        font-size: 1.1rem;
    }

    .admin-card-toggle {
        display: none;
    }
}


/* =========================================================
   Tenant-Auswahl
   ========================================================= */

.tenant-select-page {
    width: 100%;
    max-width: 900px;
    margin: 0 auto;
    padding: 32px 0;
}

.tenant-select-header {
    margin-bottom: 28px;
    text-align: center;
}

.tenant-select-header > .tenant-select-icon {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 54px;
    height: 54px;
    margin: 0 auto 16px;

    border-radius: 14px;
    background: rgb(31 94 255 / 10%);

    color: var(--color-accent, #1f5eff);
    font-size: 1.35rem;
}

.tenant-select-header h1 {
    margin: 0;

    color: var(--color-text, #172033);
    font-size: 2rem;
    font-weight: 700;
}

.tenant-select-header p {
    margin: 8px 0 0;

    color: var(--color-muted, #657085);
    font-size: 1rem;
}

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

.tenant-select-form {
    margin: 0;
}

.tenant-select-card {
    display: flex;
    align-items: center;
    gap: 16px;

    width: 100%;
    min-height: 100px;
    padding: 20px;

    border: 1px solid #e0e4ec;
    border-radius: 14px;
    background: var(--color-card, #fff);

    color: var(--color-text, #172033);
    font: inherit;
    text-align: left;

    cursor: pointer;

    transition:
        border-color 0.15s ease,
        box-shadow 0.15s ease,
        transform 0.15s ease;
}

.tenant-select-card:hover {
    border-color: var(--color-accent, #1f5eff);
    box-shadow: 0 6px 20px rgb(0 0 0 / 7%);
    transform: translateY(-1px);
}

.tenant-select-card-icon {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;

    width: 46px;
    height: 46px;

    border-radius: 12px;
    background: rgb(31 94 255 / 10%);

    color: var(--color-accent, #1f5eff);
    font-size: 1.1rem;
}

.tenant-select-card-content {
    flex: 1;
    min-width: 0;
}

.tenant-select-card-content > strong {
    display: block;
    margin-bottom: 7px;

    overflow: hidden;

    font-size: 1rem;
    font-weight: 650;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.tenant-select-meta {
    display: flex;
    align-items: center;
    gap: 10px;

    color: var(--color-muted, #657085);
    font-size: 0.85rem;
}

.tenant-select-arrow {
    flex: 0 0 auto;

    color: var(--color-muted, #657085);
    font-size: 0.85rem;
}

.tenant-select-card:hover .tenant-select-arrow {
    color: var(--color-accent, #1f5eff);
}

.tenant-select-empty {
    grid-column: 1 / -1;

    padding: 48px 24px;

    border: 1px solid #e0e4ec;
    border-radius: 14px;
    background: var(--color-card, #fff);

    color: var(--color-muted, #657085);
    text-align: center;
}

.tenant-select-empty > i {
    display: block;
    margin-bottom: 14px;

    font-size: 2rem;
}

.tenant-select-empty strong {
    display: block;

    color: var(--color-text, #172033);
    font-size: 1rem;
}

.tenant-select-empty p {
    margin: 6px 0 0;
}

@media (max-width: 700px) {
    .tenant-select-page {
        padding: 20px 0;
    }

    .tenant-select-grid {
        grid-template-columns: 1fr;
    }

    .tenant-select-header h1 {
        font-size: 1.65rem;
    }
}

/* =========================================================
   Invitation
   ========================================================= */

.invitation-page {
    width: 100%;
    max-width: 720px;
    margin: 0 auto;
    padding: 32px 0;
}

.invitation-card {
    padding: 28px;

    border: 1px solid #e0e4ec;
    border-radius: 16px;
    background: var(--color-card, #fff);
    box-shadow: 0 4px 18px rgb(0 0 0 / 5%);
}

.invitation-header {
    display: flex;
    align-items: flex-start;
    gap: 16px;
}

.invitation-icon {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;

    width: 48px;
    height: 48px;

    border-radius: 12px;
    background: rgb(31 94 255 / 10%);

    color: var(--color-accent, #1f5eff);
    font-size: 1.2rem;
}

.invitation-header h1 {
    margin: 0;

    color: var(--color-text, #172033);
    font-size: 1.5rem;
}

.invitation-header p {
    margin: 6px 0 0;

    color: var(--color-muted, #657085);
    line-height: 1.5;
}

.invitation-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;

    margin: 24px 0;
    padding: 16px;

    border-radius: 12px;
    background: #f7f8fa;
}

.invitation-detail {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.invitation-detail > span {
    color: var(--color-muted, #657085);
    font-size: 0.78rem;
}

.invitation-detail > strong:not(.role-badge) {
    color: var(--color-text, #172033);
    font-size: 0.92rem;
}

.invitation-account,
.invitation-info,
.invitation-warning,
.invitation-register-info {
    display: flex;
    align-items: flex-start;
    gap: 12px;

    margin: 20px 0;
    padding: 15px 16px;

    border-radius: 10px;
}

.invitation-account,
.invitation-info {
    background: rgb(31 94 255 / 7%);
    color: var(--color-text, #172033);
}

.invitation-account-success {
    background: rgb(22 163 74 / 8%);
}

.invitation-account-success > i {
    color: #16a34a;
}

.invitation-warning {
    background: rgb(217 119 6 / 10%);
}

.invitation-warning > i {
    color: #d97706;
}

.invitation-info > i,
.invitation-register-info > i {
    color: var(--color-accent, #1f5eff);
}

.invitation-account div,
.invitation-info div,
.invitation-warning div {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.invitation-account span,
.invitation-info span,
.invitation-warning span,
.invitation-register-info span {
    color: var(--color-muted, #657085);
    font-size: 0.9rem;
    line-height: 1.45;
}

.invitation-account small {
    color: var(--color-muted, #657085);
}

.invitation-register-form {
    display: grid;
    gap: 18px;
    margin-top: 24px;
}

.invitation-register-form input:disabled {
    background: #f5f6f8;
    color: var(--color-muted, #657085);
    cursor: not-allowed;
}

.invitation-register-info {
    margin: 2px 0;
    background: rgb(31 94 255 / 7%);
}

.invitation-submit,
.invitation-secondary-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;

    width: 100%;
    padding: 11px 16px;

    border: 0;
    border-radius: 9px;

    font: inherit;
    font-weight: 600;
    text-decoration: none;

    cursor: pointer;
}

.invitation-submit {
    background: var(--color-accent, #1f5eff);
    color: #fff;
}

.invitation-submit:hover {
    filter: brightness(0.95);
}

.invitation-secondary-button {
    border: 1px solid #d9dee8;
    background: #fff;

    color: var(--color-text, #172033);
}

.invitation-action-form {
    margin: 0;
}

.invitation-help {
    color: var(--color-muted, #657085);
    font-size: 0.9rem;
}

@media (max-width: 600px) {
    .invitation-page {
        padding: 16px 0;
    }

    .invitation-card {
        padding: 20px;
    }

    .invitation-details {
        grid-template-columns: 1fr;
    }

    .invitation-header h1 {
        font-size: 1.3rem;
    }
}



.support-page {
    width: 100%;
    max-width: 840px;
    margin: 40px auto;
}

.support-card {
    background: var(--card-background, #fff);
    border-radius: 14px;
    padding: 36px 32px 30px;
    box-shadow: 0 2px 12px rgba(15, 23, 42, 0.08);
}

.support-header {
    margin-bottom: 30px;
}

.support-header h1 {
    margin: 0 0 6px;
}

.support-header p {
    margin: 0;
    color: #667085;
    line-height: 1.4;
}

.support-field {
    display: flex;
    flex-direction: column;
    width: 100%;
    margin-bottom: 22px;
}

.support-field label {
    display: block;
    margin-bottom: 7px;
    font-weight: 600;
}

.support-field input,
.support-field textarea {
    display: block;
    width: 100%;
    max-width: none;
    box-sizing: border-box;
}

.support-field textarea {
    min-height: 180px;
    resize: vertical;
}

.support-field-hint {
    display: block;
    width: 100%;
    margin-top: 7px;
    color: #667085;
    font-size: 0.875rem;
    line-height: 1.4;
}

.support-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
    width: 100%;
    box-sizing: border-box;
    margin-top: 4px;
    padding: 16px 18px;
    border-radius: 9px;
    background: #f5f5f5;
}

.support-info span {
    color: #667085;
}

.support-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 18px;
    margin-top: 28px;
}

.support-cancel {
    font-weight: 500;
}

.support-error-reference {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
    padding: 12px 16px;
    border-radius: 8px;
    background: #f5f5f5;
}

.support-error-reference strong {
    font-family: monospace;
}

@media (max-width: 700px) {
    .support-page {
        margin: 20px auto;
    }

    .support-card {
        padding: 24px 20px;
        border-radius: 10px;
    }

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

    .support-actions .btn,
    .support-cancel {
        width: 100%;
        box-sizing: border-box;
        text-align: center;
    }
}