/* ============================================
   MalerRenner - Zentra-Style
   ============================================ */

:root {
    --color-primary: #312e81;
    --color-primary-hover: #3730a3;
    --color-accent: #7c3aed;
    --color-accent-hover: #6d28d9;
    --color-accent-light: rgba(124, 58, 237, 0.1);
    --color-bg: #f5f5f5;
    --color-surface: #ffffff;
    --color-text: #1a1a2e;
    --color-text-muted: #6b7280;
    --color-border: #e5e7eb;
    --color-success: #16a34a;
    --color-danger: #dc2626;
    --color-warning: #f59e0b;
    --sidebar-width: 230px;
    --sidebar-collapsed-width: 60px;
    --header-height: 48px;
    --mobile-nav-height: 56px;
    --radius: 8px;
    --sidebar-bg: #1e1b4b;
    --sidebar-text: rgba(255,255,255,0.55);
    --sidebar-text-hover: rgba(255,255,255,0.85);
    --sidebar-text-active: #ffffff;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background: var(--color-bg);
    color: var(--color-text);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

/* ============================================
   Layout
   ============================================ */

.app-container { display: flex; min-height: 100vh; }
.main-content { flex: 1; display: flex; flex-direction: column; min-height: 100vh; }

/* ============================================
   Sidebar
   ============================================ */

.sidebar {
    display: none;
    width: var(--sidebar-width);
    background: var(--sidebar-bg);
    position: fixed;
    top: 0; left: 0; bottom: 0;
    overflow-y: auto;
    overflow-x: hidden;
    z-index: 100;
    flex-direction: column;
    transition: width 0.2s ease;
}

/* Logo */
.nav-brand {
    padding: 14px 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f3f0ff;
    height: 86px;
    overflow: hidden;
}

.brand-logo {
    max-width: 85%;
    height: 54px;
    width: auto;
    object-fit: contain;
    display: block;
}

.brand-logo-mini {
    height: 28px;
    width: auto;
    display: none;
    object-fit: contain;
}

/* Collapse Toggle */
.sidebar-toggle {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding: 4px 18px;
    background: transparent;
    border: none;
    cursor: pointer;
    color: var(--sidebar-text);
    transition: all 0.15s;
    font-size: 1.3rem;
    line-height: 1;
}

.sidebar-toggle:hover {
    color: var(--sidebar-text-active);
}

.sidebar-collapsed .sidebar-toggle {
    justify-content: center;
    padding: 4px;
}

/* Nav Items */
.nav-menu {
    padding: 12px 0;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.nav-footer {
    padding: 8px 0;
    border-top: 1px solid rgba(255,255,255,0.08);
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 9px 20px;
    text-decoration: none;
    color: var(--sidebar-text);
    font-size: 0.86rem;
    font-weight: 500;
    transition: all 0.12s ease;
    position: relative;
    border-left: 3px solid transparent;
}

.nav-link:hover {
    color: var(--sidebar-text-hover);
    background: rgba(255,255,255,0.05);
}

.nav-link.active {
    color: var(--sidebar-text-active);
    background: rgba(124, 58, 237, 0.25);
    border-left-color: var(--color-accent);
    font-weight: 600;
}

.nav-svg {
    flex-shrink: 0;
    opacity: 0.7;
}

.nav-link.active .nav-svg {
    opacity: 1;
}

.nav-text {
    white-space: nowrap;
    overflow: hidden;
    transition: opacity 0.15s;
}

/* ============================================
   Sidebar Collapsed State
   ============================================ */

.sidebar-collapsed .sidebar {
    width: var(--sidebar-collapsed-width);
}

.sidebar-collapsed .main-content {
    margin-left: var(--sidebar-collapsed-width);
}

.sidebar-collapsed .brand-logo { display: none; }
.sidebar-collapsed .brand-logo-mini { display: block; }

.sidebar-collapsed .nav-brand {
    padding: 12px 8px;
}

.sidebar-collapsed .nav-link {
    padding: 10px 0;
    justify-content: center;
    border-left-width: 2px;
    gap: 0;
}

.sidebar-collapsed .nav-text {
    display: none;
}

.sidebar-collapsed .sidebar-toggle {
    right: -12px;
}

/* ============================================
   Header
   ============================================ */

.top-header {
    height: var(--header-height);
    background: var(--color-surface);
    border-bottom: 1px solid var(--color-border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    position: sticky;
    top: 0;
    z-index: 50;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.header-breadcrumb {
    font-size: 0.84rem;
    color: var(--color-text-muted);
}

.header-right {
    display: flex;
    align-items: center;
    gap: 14px;
}

.header-user {
    font-size: 0.84rem;
    color: var(--color-text);
    font-weight: 500;
}

.header-avatar {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: var(--color-primary);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: 600;
}

.header-title {
    font-size: 0.84rem;
    font-weight: 400;
    color: var(--color-text-muted);
}

.mobile-menu-btn {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--color-text-muted);
    padding: 2px;
    display: flex;
}

.btn-logout {
    padding: 4px 12px;
    border: 1px solid var(--color-danger);
    border-radius: var(--radius);
    background: transparent;
    color: var(--color-danger);
    font-size: 0.78rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.12s;
}

.btn-logout:hover {
    background: var(--color-danger);
    color: white;
}

/* ============================================
   Content
   ============================================ */

.content-area {
    flex: 1;
    padding: 24px 28px;
    padding-bottom: calc(var(--mobile-nav-height) + 16px);
    max-width: 100%;
    width: 100%;
}

/* ============================================
   Mobile Bottom Nav
   ============================================ */

.mobile-nav {
    display: flex;
    position: fixed;
    bottom: 0; left: 0; right: 0;
    height: var(--mobile-nav-height);
    background: var(--sidebar-bg);
    z-index: 100;
    justify-content: space-around;
    align-items: center;
    padding-bottom: env(safe-area-inset-bottom, 0);
}

.mobile-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    text-decoration: none;
    color: var(--sidebar-text);
    padding: 6px 14px;
    border-radius: 6px;
    transition: all 0.12s;
}

.mobile-nav-item.active {
    color: var(--sidebar-text-active);
    background: var(--color-accent);
}

.mobile-nav-icon { width: 20px; height: 20px; }
.mobile-nav-label { font-size: 0.6rem; font-weight: 600; }

/* ============================================
   Desktop
   ============================================ */

@media (min-width: 768px) {
    .sidebar { display: flex; }
    .main-content { margin-left: var(--sidebar-width); transition: margin-left 0.2s ease; }
    .mobile-nav { display: none; }
    .mobile-menu-btn { display: none; }
    .content-area { padding: 28px 36px; padding-bottom: 28px; }
}

/* ============================================
   Page Title
   ============================================ */

.page-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-text);
    margin-bottom: 24px;
}

/* ============================================
   Cards
   ============================================ */

.card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    padding: 20px 24px;
    margin-bottom: 16px;
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 14px;
}

.card-header h3 {
    font-size: 1rem;
    font-weight: 700;
    margin: 0;
}

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

@media (min-width: 900px) {
    .content-grid { grid-template-columns: 1fr 1fr; }
}

/* ============================================
   List Items
   ============================================ */

.list-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 11px 0;
    border-bottom: 1px solid var(--color-border);
}

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

.list-item-title {
    font-size: 0.88rem;
    font-weight: 500;
    color: var(--color-text);
}

.list-item-sub {
    font-size: 0.78rem;
    color: var(--color-text-muted);
}

/* Badges */
.badge {
    padding: 2px 10px;
    border-radius: 20px;
    font-size: 0.72rem;
    font-weight: 600;
}

.badge-open { background: #eef2ff; color: var(--color-primary); }
.badge-success { background: #f0fdf4; color: var(--color-success); }
.badge-danger { background: #fef2f2; color: var(--color-danger); }

/* Empty State */
.empty-state {
    text-align: center;
    padding: 28px 16px;
    color: var(--color-text-muted);
}

.empty-state p { margin: 0; font-size: 0.85rem; }

/* ============================================
   Buttons
   ============================================ */

.btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 15px;
    border: none;
    border-radius: var(--radius);
    font-size: 0.84rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.12s;
    text-decoration: none;
}

.btn:active { transform: scale(0.97); }
.btn-primary { background: var(--color-primary); color: white; }
.btn-primary:hover { background: var(--color-primary-hover); }
.btn-accent { background: var(--color-accent); color: white; }
.btn-accent:hover { background: var(--color-accent-hover); }
.btn-danger { background: var(--color-danger); color: white; }
.btn-outline { background: transparent; border: 1px solid var(--color-border); color: var(--color-text); }
.btn-outline:hover { background: var(--color-bg); }

/* ============================================
   Forms
   ============================================ */

.form-group { margin-bottom: 16px; }

.form-group label {
    display: block;
    font-size: 0.82rem;
    font-weight: 600;
    margin-bottom: 4px;
    color: var(--color-text);
}

.form-control {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    font-size: 0.88rem;
    background: var(--color-surface);
    color: var(--color-text);
    transition: border-color 0.12s;
}

.form-control:focus {
    outline: none;
    border-color: var(--color-accent);
    box-shadow: 0 0 0 2px rgba(124,58,237,0.12);
}

/* ============================================
   Tables
   ============================================ */

.table-responsive { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 0.85rem; }
th { text-align: left; padding: 10px 14px; font-weight: 600; color: var(--color-text-muted); border-bottom: 2px solid var(--color-border); font-size: 0.78rem; }
td { padding: 10px 14px; border-bottom: 1px solid var(--color-border); }
tr:hover { background: #fafafa; }

/* ============================================
   Alerts
   ============================================ */

.alert { padding: 12px 16px; border-radius: var(--radius); margin-bottom: 14px; font-size: 0.85rem; }
.alert-danger { background: #fef2f2; color: var(--color-danger); border: 1px solid #fecaca; }
.alert-success { background: #f0fdf4; color: var(--color-success); border: 1px solid #bbf7d0; }
.alert-warning { background: #fffbeb; color: #92400e; border: 1px solid #fde68a; }

/* ============================================
   Modal
   ============================================ */

.modal-backdrop { position: fixed; inset: 0; background: rgba(0,0,0,0.4); display: flex; align-items: center; justify-content: center; z-index: 200; padding: 16px; }
.modal { background: var(--color-surface); border-radius: var(--radius); width: 100%; max-width: 480px; max-height: 90vh; overflow-y: auto; padding: 24px; }
.modal-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; }
.modal-header h3 { margin: 0; }
.modal-footer { display: flex; justify-content: flex-end; gap: 8px; margin-top: 20px; }

/* ============================================
   Utilities
   ============================================ */

.text-muted { color: var(--color-text-muted); }
.text-danger { color: var(--color-danger); }
.text-success { color: var(--color-success); }
.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mb-1 { margin-bottom: 8px; }
.mb-2 { margin-bottom: 16px; }

/* ============================================
   Login Page
   ============================================ */

.login-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--color-bg);
    padding: 16px;
}

.login-container {
    width: 100%;
    max-width: 400px;
}

.login-card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    padding: 36px 32px;
}

.login-logo {
    text-align: center;
    margin-bottom: 28px;
}

.login-logo img {
    height: 60px;
    width: auto;
}

.login-title {
    font-size: 1.3rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 4px;
}

.login-subtitle {
    text-align: center;
    color: var(--color-text-muted);
    font-size: 0.85rem;
    margin-bottom: 24px;
}

.login-btn {
    width: 100%;
    padding: 10px;
    font-size: 0.9rem;
    justify-content: center;
    margin-top: 8px;
}

.loading-screen {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-text-muted);
}

/* ============================================
   SubNav / Expandable Menu
   ============================================ */

.nav-toggle, div.nav-toggle {
    width: 100%;
    background: none;
    border: none;
    outline: none;
    box-shadow: none;
    cursor: pointer;
    text-align: left;
    font-family: inherit;
    color: inherit;
}

.nav-chevron {
    margin-left: auto;
    opacity: 0.5;
    flex-shrink: 0;
}

.nav-toggle:hover .nav-chevron {
    opacity: 0.8;
}

.nav-subitems {
    display: flex;
    flex-direction: column;
}

.nav-sublink {
    padding-left: 50px !important;
    font-size: 0.82rem !important;
    opacity: 0.85;
}

.nav-sublink.active {
    opacity: 1;
}

.sidebar-collapsed .nav-chevron {
    display: none;
}

.sidebar-collapsed .nav-subitems {
    display: none;
}

/* Team Toggle - Final Fix */
div.nav-toggle {
    width: 100%;
    background: transparent !important;
    border: none !important;
    outline: none !important;
    box-shadow: none !important;
    cursor: pointer;
    text-align: left;
    font-family: inherit;
    color: var(--sidebar-text) !important;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 9px 20px;
    font-size: 0.86rem;
    font-weight: 500;
    border-left: 3px solid transparent !important;
    transition: all 0.12s ease;
}

div.nav-toggle:hover {
    color: var(--sidebar-text-hover) !important;
    background: rgba(255,255,255,0.05) !important;
}

div.nav-toggle.active {
    background: rgba(124, 58, 237, 0.25) !important;
    border-left-color: var(--color-accent) !important;
    color: var(--sidebar-text-active) !important;
}
/* Team Toggle - Final Fix */
div.nav-toggle {
    width: 100%;
    background: transparent !important;
    border: none !important;
    outline: none !important;
    box-shadow: none !important;
    cursor: pointer;
    text-align: left;
    font-family: inherit;
    color: var(--sidebar-text) !important;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 9px 20px;
    font-size: 0.86rem;
    font-weight: 500;
    border-left: 3px solid transparent !important;
    transition: all 0.12s ease;
}

div.nav-toggle:hover {
    color: var(--sidebar-text-hover) !important;
    background: rgba(255,255,255,0.05) !important;
}

div.nav-toggle.active {
    background: rgba(124, 58, 237, 0.25) !important;
    border-left-color: var(--color-accent) !important;
    color: var(--sidebar-text-active) !important;
}

/* ============================================
   Mitarbeiter Page
   ============================================ */

.ma-name {
    font-weight: 600;
    font-size: 0.88rem;
}

.ma-email {
    font-size: 0.78rem;
    color: var(--color-text-muted);
}

.table-actions {
    display: flex;
    gap: 6px;
    justify-content: flex-end;
}

.btn-sm {
    padding: 4px 10px;
    font-size: 0.78rem;
}

.modal-form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0 16px;
}

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

/* ============================================
   Stunden Page
   ============================================ */

.stunden-filter {
    display: flex;
    gap: 20px;
    align-items: flex-end;
    flex-wrap: wrap;
}

.stunden-filter .form-group {
    min-width: 180px;
}

.stunden-info {
    display: flex;
    gap: 20px;
    padding: 6px 0;
}

.stunden-info-item {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.stunden-info-label {
    font-size: 0.72rem;
    color: var(--color-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.stunden-info-value {
    font-size: 1.1rem;
    font-weight: 700;
}

.stunden-tabelle th {
    font-size: 0.74rem;
    padding: 8px 6px;
}

.stunden-tabelle td {
    padding: 4px 6px;
    vertical-align: middle;
}

.stunden-datum {
    font-weight: 600;
    font-size: 0.84rem;
}

.stunden-wochentag {
    font-size: 0.78rem;
    color: var(--color-text-muted);
}

.stunden-std {
    font-weight: 600;
    text-align: center;
    font-size: 0.88rem;
}

.stunden-summe td {
    padding: 12px 6px;
    border-top: 2px solid var(--color-text);
    border-bottom: none;
}

.form-control-sm {
    padding: 4px 6px;
    font-size: 0.82rem;
    height: auto;
}

.zeile-wochenende {
    background: #f9fafb;
}

.zeile-wochenende td {
    color: var(--color-text-muted);
}

.zeile-feiertag {
    background: #fef3c7;
}

.zeile-urlaub {
    background: #e0f2fe;
}

.zeile-krank {
    background: #fef2f2;
}

@media (max-width: 768px) {
    .stunden-filter {
        flex-direction: column;
    }

    .stunden-filter .form-group {
        min-width: 100%;
    }
}

.btn-success {
    background: var(--color-success);
    color: white;
}

.btn-success:hover {
    background: #15803d;
}

.btn-info {
    background: #2563eb;
    color: white;
}

.btn-info:hover {
    background: #1d4ed8;
}

a.btn {
    font-size: 0.84rem;
    padding: 7px 15px;
    line-height: 1.5;
    text-decoration: none;
}

.flex.gap-1 .btn {
    font-size: 0.78rem;
    padding: 5px 12px;
    line-height: 1.4;
    height: 30px;
    display: inline-flex;
    align-items: center;
    box-sizing: border-box;
}

.stunden-konto {
    padding-left: 16px;
    border-left: 2px solid var(--color-border);
    margin-left: 4px;
}

/* ============================================
   Breadcrumb Bar
   ============================================ */

.breadcrumb-bar {
    background: #fafafa;
    border-bottom: 1px solid var(--color-border);
    padding: 8px 20px;
}

.breadcrumb {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.82rem;
}

.breadcrumb-link {
    color: var(--color-text-muted);
    text-decoration: none;
    transition: color 0.12s;
}

.breadcrumb-link:hover {
    color: var(--color-accent);
}

.breadcrumb-sep {
    color: var(--color-text-muted);
    opacity: 0.5;
    font-size: 0.75rem;
}

.breadcrumb-current {
    color: var(--color-text);
    font-weight: 600;
}

@media (min-width: 768px) {
    .breadcrumb-bar {
        padding: 8px 36px;
    }
}

/* ============================================
   Baustellen
   ============================================ */

.baustellen-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
}

@media (min-width: 700px) {
    .baustellen-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

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

.baustelle-card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    padding: 18px 20px;
    cursor: pointer;
    transition: all 0.12s;
}

.baustelle-card:hover {
    border-color: var(--color-accent);
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.baustelle-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 8px;
}

.baustelle-card-header h3 {
    font-size: 0.95rem;
    font-weight: 700;
    margin: 0;
}

.baustelle-kunde {
    font-size: 0.84rem;
    color: var(--color-text);
    margin-bottom: 4px;
}

.baustelle-adresse {
    font-size: 0.78rem;
    color: var(--color-text-muted);
    margin-bottom: 8px;
}

.baustelle-meta {
    display: flex;
    gap: 12px;
    font-size: 0.75rem;
    color: var(--color-text-muted);
}

.badge-closed {
    background: #f3f4f6;
    color: #6b7280;
}

.detail-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid var(--color-border);
    font-size: 0.88rem;
}

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

.detail-label {
    color: var(--color-text-muted);
    font-size: 0.82rem;
}

.tagebuch-eintrag {
    padding: 14px 0;
    border-bottom: 1px solid var(--color-border);
}

.tagebuch-eintrag:last-child {
    border-bottom: none;
}

.tagebuch-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 6px;
}

.tagebuch-text {
    font-size: 0.85rem;
    color: var(--color-text-muted);
    line-height: 1.5;
    white-space: pre-line;
}

.tagebuch-datum-header {
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--color-text-muted);
    padding: 12px 0 6px;
    border-bottom: 1px solid var(--color-border);
    margin-bottom: 4px;
    text-transform: capitalize;
}

/* ============================================
   Bilder in Tagebuch
   ============================================ */

.tagebuch-bilder {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 10px;
}

.tagebuch-bild {
    position: relative;
    width: 120px;
    height: 90px;
    border-radius: 6px;
    overflow: hidden;
    border: 1px solid var(--color-border);
}

.tagebuch-bild img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    cursor: pointer;
    transition: opacity 0.12s;
}

.tagebuch-bild img:hover {
    opacity: 0.85;
}

.bild-loeschen {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: rgba(220, 38, 38, 0.85);
    color: white;
    border: none;
    font-size: 0.7rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.12s;
}

.tagebuch-bild:hover .bild-loeschen {
    opacity: 1;
}

.bild-hinzufuegen {
    width: 120px;
    height: 90px;
    border-radius: 6px;
    border: 2px dashed var(--color-border);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--color-text-muted);
    font-size: 0.8rem;
    font-weight: 500;
    transition: all 0.12s;
}

.bild-hinzufuegen:hover {
    border-color: var(--color-accent);
    color: var(--color-accent);
}

/* ============================================
   Wochenplan
   ============================================ */

.wochenplan-tabelle {
    table-layout: fixed;
}

.wochenplan-tabelle th {
    text-align: center;
    padding: 8px 4px;
}

.wochenplan-tag-name {
    font-size: 0.82rem;
    font-weight: 700;
}

.wochenplan-tag-datum {
    font-size: 0.72rem;
    font-weight: 400;
    color: var(--color-text-muted);
}

.wochenplan-ma {
    font-weight: 600;
    font-size: 0.85rem;
    white-space: nowrap;
}

.wochenplan-zelle {
    vertical-align: top;
    padding: 6px 4px;
    min-height: 50px;
    cursor: pointer;
    transition: background 0.1s;
}

.wochenplan-zelle:hover {
    background: #f0ecff;
}

.wochenplan-eintrag {
    background: var(--color-accent-light, #ede9fe);
    color: var(--color-accent);
    padding: 3px 6px;
    border-radius: 4px;
    font-size: 0.72rem;
    font-weight: 500;
    margin-bottom: 3px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.wochenplan-heute {
    background: #f5f3ff;
}

.wochenplan-samstag {
    background: #f9fafb;
    opacity: 0.7;
}

/* Wochenplan Einsatz-Details */
.wochenplan-zeit {
    font-size: 0.65rem;
    color: var(--color-accent);
    font-weight: 700;
    display: block;
    line-height: 1;
    margin-bottom: 1px;
}

.wochenplan-eintrag {
    background: var(--color-accent-light, #ede9fe);
    color: var(--color-text);
    padding: 3px 6px;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 500;
    margin-bottom: 3px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    border-left: 2px solid var(--color-accent);
}

.einsatz-zeile {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid var(--color-border);
    font-size: 0.88rem;
}

.einsatz-zeile:last-child {
    border-bottom: none;
}

.einsatz-zeit {
    font-weight: 700;
    color: var(--color-accent);
    margin-right: 10px;
    font-size: 0.84rem;
}

/* Wochenplan Navigation */
.wochenplan-nav {
    display: flex;
    align-items: center;
    gap: 6px;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: 24px;
    padding: 3px;
}

.wochenplan-nav .nav-btn {
    padding: 6px 14px;
    border: none;
    background: transparent;
    color: var(--color-text-muted);
    font-size: 0.82rem;
    font-weight: 500;
    cursor: pointer;
    border-radius: 20px;
    transition: all 0.12s;
}

.wochenplan-nav .nav-btn:hover {
    background: var(--color-bg);
    color: var(--color-text);
}

.wochenplan-nav .nav-btn-today {
    background: var(--color-accent);
    color: white;
}

.wochenplan-nav .nav-btn-today:hover {
    background: var(--color-accent-hover);
}

.wochenplan-nav .nav-datum {
    padding: 6px 16px;
    font-size: 0.84rem;
    font-weight: 700;
    color: var(--color-text);
}

.nav-datum-picker {
    border: none;
    background: transparent;
    color: var(--color-accent);
    font-size: 0.82rem;
    cursor: pointer;
    padding: 4px 6px;
    border-radius: 6px;
    width: 22px;
    opacity: 0.6;
    transition: opacity 0.12s;
}

.nav-datum-picker:hover {
    opacity: 1;
}

.nav-datum-picker::-webkit-calendar-picker-indicator {
    cursor: pointer;
    opacity: 0.6;
}

.nav-datum-picker::-webkit-calendar-picker-indicator:hover {
    opacity: 1;
}

.nav-datum-picker:focus,
.nav-datum-picker:focus-visible {
    outline: none;
    box-shadow: none;
}
/* ============================================
   Mobile Menü (Seitenleiste als Schublade)
   ============================================ */

.mobile-overlay { display: none; }

button.mobile-nav-item {
    background: none;
    border: none;
    font: inherit;
    cursor: pointer;
}

@media (max-width: 767.98px) {
    .sidebar-toggle { display: none; }

    .app-container.mobile-menu-open .sidebar {
        display: flex;
        width: min(280px, 84vw);
        bottom: var(--mobile-nav-height);
        box-shadow: 4px 0 24px rgba(15, 13, 40, 0.35);
        z-index: 120;
    }

    .app-container.mobile-menu-open .mobile-overlay {
        display: block;
        position: fixed;
        inset: 0;
        bottom: var(--mobile-nav-height);
        background: rgba(15, 13, 40, 0.45);
        z-index: 110;
    }

    .app-container.mobile-menu-open .sidebar .nav-text { display: inline; }
    .app-container.mobile-menu-open .sidebar .brand-logo { display: block; }
    .app-container.mobile-menu-open .sidebar .brand-logo-mini { display: none; }

    .mobile-nav-item { padding: 6px 8px; min-width: 56px; }
}

/* Monatsabschluss im Stundenzettel */
.stunden-abschluss-input { width: 96px; font-weight: 700; text-align: center; }
.stunden-abschluss-input::placeholder { color: #9ca3af; font-weight: 500; }
