body.menu-open {
    overflow: hidden;
}

.app-layout {
    min-height: 100vh;
    display: flex;
    background: #f8fafc;
}

.app-sidebar {
    width: 260px;
    background: #0F172A;
    color: #fff;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 22px 18px;
    position: sticky;
    top: 0;
    height: 100vh;
    flex-shrink: 0;
}

.app-sidebar-top,
.app-sidebar-bottom {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.app-logo {
    display: block;
    margin-bottom: 10px;
}

.app-logo img {
    display: block;
    max-width: 160px;
    height: auto;
}

.app-create-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    border-radius: 14px;
    background: #F97316;
    color: #fff;
    text-decoration: none;
    font-weight: 700;
    padding: 0 16px;
    margin: 8px 0 18px;
}

.app-create-btn:hover {
    background: #C2410C;
}

.app-nav {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.app-nav-link {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 46px;
    padding: 0 14px;
    border-radius: 14px;
    color: rgba(255,255,255,0.88);
    text-decoration: none;
    transition: background 0.2s ease, color 0.2s ease;
}

.app-nav-link:hover {
    background: rgba(255,255,255,0.08);
    color: #fff;
}

.app-nav-link.is-active {
    background: rgba(249, 115, 22, 0.16);
    color: #fff;
    border: 1px solid rgba(249, 115, 22, 0.28);
}

.app-nav-link-logout {
    color: rgba(255,255,255,0.72);
}

.app-nav-icon {
  width: 20px;
  height: 20px;
  min-width: 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.app-nav-icon svg {
  width: 20px;
  height: 20px;
  display: block;
}

.app-main {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.app-mobilebar {
    display: none;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    background: rgba(255,255,255,0.9);
    border-bottom: 1px solid #e2e8f0;
    backdrop-filter: blur(10px);
    position: sticky;
    top: 0;
    z-index: 30;
}

.app-menu-toggle {
    border: 1px solid #cbd5e1;
    background: #fff;
    color: #0f172a;
    border-radius: 12px;
    width: 44px;
    height: 44px;
    font-size: 22px;
    cursor: pointer;
}

.app-mobile-logo img {
    height: 28px;
    width: auto;
    display: block;
}

.app-overlay {
    display: none;
}

.app-content {
    flex: 1;
}

@media (max-width: 980px) {
    .app-mobilebar {
        display: flex;
    }

    .app-sidebar {
        position: fixed;
        left: 0;
        top: 0;
        bottom: 0;
        transform: translateX(-100%);
        transition: transform 0.25s ease;
        z-index: 50;
        width: 280px;
        height: 100vh;
    }

    .app-sidebar.is-open {
        transform: translateX(0);
    }

    .app-overlay {
        display: block;
        position: fixed;
        inset: 0;
        background: rgba(15, 23, 42, 0.45);
        opacity: 0;
        pointer-events: none;
        transition: opacity 0.25s ease;
        z-index: 40;
    }

    .app-overlay.is-open {
        opacity: 1;
        pointer-events: auto;
    }
}

.app-sidebar {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 100vh;
}

.app-sidebar-top {
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.app-sidebar-bottom {
    margin-top: auto;
    padding-top: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.app-sidebar-bottom .app-nav-link {
    width: 100%;
}

.app-sidebar {
    display: flex;
    flex-direction: column;
    height: 100vh;
}

.app-sidebar-top {
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.app-sidebar-bottom {
    margin-top: auto;
    padding-top: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

@media (max-width: 900px) {
    .app-sidebar {
        height: 100dvh;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    .app-sidebar-top {
        min-height: auto;
    }

    .app-sidebar-bottom {
        margin-top: 24px;
        padding-bottom: 20px;
    }
}

/* FORM */

label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 6px;
    color: #475569;
}

.form-input {
    width: 100%;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 12px 14px;
    font-size: 15px;
    font-family: inherit;
    background: #fff;
    color: #0f172a;
    transition: border 0.15s ease, box-shadow 0.15s ease;
}

.form-input::placeholder {
    color: #94a3b8;
}

.form-input:focus {
    outline: none;
    border-color: #f97316;
    box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.15);
}

/* optional: nicer spacing im form */
.card form {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

/* inputs gruppen etwas cleaner */
.card form > div > div {
    display: flex;
    flex-direction: column;
}

/* button spacing */
.card form .actions {
    margin-top: 10px;
}

.app-main > .app-footer {
    margin-top: auto;
}

.app-create-btn-disabled {
    opacity: 0.55;
    cursor: not-allowed;
    pointer-events: none;
    filter: grayscale(0.15);
}

.app-mobilebar {
    position: sticky;
    top: 0;
    z-index: 80;
    height: 64px;
    display: none;
    align-items: center;
    gap: 10px;
    padding: 0 12px;
    background: rgba(255,255,255,.94);
    backdrop-filter: blur(18px);
    border-bottom: 1px solid rgba(15,23,42,.08);
}

.app-mobile-logo {
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.app-mobile-logo img {
    height: 28px;
    width: auto;
}

.app-mobile-focus {
    flex: 1;
    min-width: 0;
    display: flex;
    justify-content: center;
    gap: 6px;
}

.app-mobile-focus-item {
    min-width: 54px;
    padding: 5px 6px;
    border-radius: 12px;
    background: #f8fafc;
    border: 1px solid rgba(15,23,42,.07);
    text-align: center;
    text-decoration: none;
    color: #0f172a;
    line-height: 1.05;
}

.app-mobile-focus-item strong {
    display: block;
    font-size: 15px;
    font-weight: 800;
}

.app-mobile-focus-item span {
    display: block;
    margin-top: 2px;
    font-size: 9px;
    font-weight: 700;
    color: #64748b;
}

.app-mobile-focus-danger strong {
    color: #dc2626;
}

.app-mobile-account {
    position: relative;
    flex-shrink: 0;
}

.app-mobile-avatar {
    width: 36px;
    height: 36px;
    border: 0;
    border-radius: 999px;
    background: #f97316;
    color: #fff;
    font-size: 13px;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.app-mobile-account-menu {
    position: absolute;
    top: 46px;
    right: 0;
    width: 250px;
    display: none;
    padding: 8px;
    border-radius: 18px;
    background: #fff;
    border: 1px solid rgba(15,23,42,.08);
    box-shadow: 0 22px 60px rgba(15,23,42,.18);
}

.app-mobile-account-menu.is-open {
    display: block;
}

.app-mobile-account-head {
    padding: 10px 12px 9px;
    border-bottom: 1px solid rgba(15,23,42,.07);
    margin-bottom: 6px;
}

.app-mobile-account-head strong {
    display: block;
    font-size: 14px;
    color: #0f172a;
}

.app-mobile-account-head span {
    display: block;
    margin-top: 2px;
    font-size: 12px;
    color: #64748b;
}

.app-mobile-account-menu a {
    display: block;
    padding: 11px 12px;
    border-radius: 12px;
    color: #0f172a;
    text-decoration: none;
    font-size: 14px;
    font-weight: 650;
}

.app-mobile-account-menu a:hover {
    background: #f8fafc;
}

.app-mobile-account-divider {
    height: 1px;
    background: rgba(15,23,42,.08);
    margin: 6px 4px;
}

.app-mobile-account-menu a.is-logout {
    color: #dc2626;
}

@media (max-width: 900px) {
    .app-mobilebar {
        display: flex;
    }
}

@media (max-width: 390px) {
    .app-mobile-focus-item {
        min-width: 48px;
        padding-left: 4px;
        padding-right: 4px;
    }

    .app-mobile-focus-item span {
        font-size: 8px;
    }

    .app-mobile-logo img {
        height: 24px;
    }
}

.app-mobilebar-focus {
    justify-content: space-between;
}

.app-mobilebar-focus .app-mobile-focus {
    flex: 1;
    justify-content: center;
    max-width: 235px;
    margin: 0 auto;
}

.app-mobile-account-head-link {
    text-decoration: none;
}

.app-mobile-account-menu .app-mobile-account-head-link:hover {
    background: #f8fafc;
}

@media (max-width: 900px) {
    .app-logo-mobile-menu {
        display: flex;
        justify-content: center;
        padding: 18px 18px 14px;
        margin-bottom: 6px;
    }

    .app-logo-mobile-menu img {
        max-width: 160px;
        height: auto;
    }
}

.app-mobilebar {
    z-index: 80;
}

.app-sidebar {
    z-index: 120;
}

.app-overlay {
    z-index: 110;
}

@media (max-width: 900px) {
    .app-sidebar {
        position: fixed;
        top: 0;
        left: 0;
        height: 100dvh;
        z-index: 120;
    }

    .app-overlay {
        position: fixed;
        inset: 0;
        z-index: 110;
    }
}

.app-mobile-page-title {
    flex: 1;
    text-align: center;
    font-size: 15px;
    font-weight: 800;
    color: #0f172a;
}

.app-mobile-page-title {
    flex: 1;
    text-align: center;
    font-size: 15px;
    font-weight: 800;
    color: #0f172a;
}

@media (max-width: 900px) {
    .dashboard-page-head {
        display: none !important;
    }
}

.app-mobile-greeting {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start; /* DAS ist entscheidend */
    text-align: left;
    line-height: 1.1;
    padding-left: 8px; /* optional für Abstand zum Burger */
}

.greeting-line-1 {
    font-size: 12px;
    opacity: 0.7;
    font-weight: 500;
}

.greeting-line-2 {
    font-size: 15px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Standard aus */
.app-mobile-meta-inline {
    display: none;
}

/* NUR mobil anzeigen */
@media (max-width: 900px) {
    .app-mobile-meta-inline {
        display: flex;
        align-items: center;
        gap: 6px;
        margin-top: 4px;
        min-width: 0;
    }

    .app-mobile-meta-company {
        color: #f97316;
        font-size: 12px;
        font-weight: 800;
        max-width: 150px;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .app-mobile-meta-chip {
        flex-shrink: 0;
        font-size: 11px;
        font-weight: 700;
        padding: 3px 8px;
        border-radius: 999px;
    }
}

.app-mobile-avatar {
    text-decoration: none;
}

.app-theme-toggle {
    width: 100%;
    border: 0;
    background: transparent;
    font: inherit;
    cursor: pointer;
    text-align: left;
    opacity: 0.82;
}

.app-theme-toggle:hover {
    background: rgba(255,255,255,0.08);
    color: #fff;
    opacity: 1;
}

.app-theme-toggle .app-nav-icon {
    font-size: 17px;
}

