:root {
    --lk-primary: #1e3a5f;
    --lk-primary-dark: #142a47;
    --lk-accent: #4a90c2;
    --lk-success: #2e7d4f;
    --lk-warning: #c97a1a;
    --lk-danger: #b53a3a;
    --lk-bg: #f4f6f9;
}

body {
    background: var(--lk-bg);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

/* ─── Sidebar ─────────────────────────────────────────────── */

.sidebar {
    width: 250px;
    background: var(--lk-primary);
    color: white;
    display: flex;
    flex-direction: column;
    height: 100vh;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1000;
}

.sidebar-header {
    background: var(--lk-primary-dark);
}

.sidebar-logo {
    max-width: 120px;
    height: auto;
}

.sidebar-brand {
    font-weight: 700;
    font-size: 1.1rem;
    color: white;
}

.sidebar-sub {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.7);
}

.sidebar-section {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 600;
    padding: 0.5rem 0.75rem;
    cursor: pointer;
    user-select: none;
}

.sidebar-section:hover {
    color: rgba(255, 255, 255, 0.8);
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.5rem 0.75rem;
    color: rgba(255, 255, 255, 0.85);
    text-decoration: none;
    border-radius: 4px;
    font-size: 0.9rem;
    margin-bottom: 1px;
}

.sidebar-link:hover {
    background: rgba(255, 255, 255, 0.08);
    color: white;
}

.sidebar-link.active {
    background: var(--lk-accent);
    color: white;
    font-weight: 500;
}

.sidebar-link.disabled {
    color: rgba(255, 255, 255, 0.4);
    cursor: not-allowed;
}

.sidebar-link i {
    width: 18px;
    text-align: center;
}

.sidebar-footer {
    background: var(--lk-primary-dark);
}

/* ─── Main Content ────────────────────────────────────────── */

.main-content {
    margin-left: 250px;
    min-height: 100vh;
    padding: 1.5rem 2rem;
}

@media (max-width: 768px) {
    .sidebar { width: 220px; }
    .main-content { margin-left: 220px; padding: 1rem; }
}

/* ─── Login-Seite ─────────────────────────────────────────── */

.login-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--lk-primary) 0%, var(--lk-primary-dark) 100%);
    padding: 1rem;
}

.login-card {
    background: white;
    border-radius: 12px;
    padding: 2.5rem;
    max-width: 400px;
    width: 100%;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
}

.login-logo {
    text-align: center;
    margin-bottom: 1.5rem;
}

.login-logo img {
    max-width: 140px;
}

.login-title {
    text-align: center;
    color: var(--lk-primary);
    font-weight: 700;
    margin-bottom: 0.25rem;
}

.login-subtitle {
    text-align: center;
    color: #888;
    font-size: 0.85rem;
    margin-bottom: 2rem;
}

/* ─── Kacheln (Dashboard) ─────────────────────────────────── */

.tile {
    background: white;
    border-radius: 10px;
    padding: 1.25rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    border-left: 4px solid var(--lk-primary);
    transition: transform 0.15s, box-shadow 0.15s;
    text-decoration: none;
    color: inherit;
    display: block;
    height: 100%;
}

.tile:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.1);
    color: inherit;
}

.tile.success { border-left-color: var(--lk-success); }
.tile.warning { border-left-color: var(--lk-warning); }
.tile.danger  { border-left-color: var(--lk-danger); }
.tile.accent  { border-left-color: var(--lk-accent); }

.tile-title {
    font-size: 0.85rem;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.tile-value {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--lk-primary);
    line-height: 1.2;
}

.tile-sub {
    font-size: 0.85rem;
    color: #888;
    margin-top: 0.25rem;
}

/* ─── Tabellen ────────────────────────────────────────────── */

.table-card {
    background: white;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    overflow: hidden;
}

.table-card .table {
    margin-bottom: 0;
}

.table thead th {
    background: var(--lk-primary);
    color: white;
    font-weight: 500;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    border: none;
}

/* ─── Page Header ─────────────────────────────────────────── */

.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.page-header h1 {
    margin: 0;
    color: var(--lk-primary);
    font-size: 1.75rem;
    font-weight: 700;
}

/* ─── Status-Badges ───────────────────────────────────────── */

.status-bezahlt {
    background: var(--lk-success);
    color: white;
}

.status-offen {
    background: var(--lk-warning);
    color: white;
}

.status-rueckstand {
    background: var(--lk-danger);
    color: white;
}

/* ─── Buttons ─────────────────────────────────────────────── */

.btn-primary {
    background: var(--lk-primary);
    border-color: var(--lk-primary);
}

.btn-primary:hover,
.btn-primary:focus {
    background: var(--lk-primary-dark);
    border-color: var(--lk-primary-dark);
}

.btn-outline-primary {
    color: var(--lk-primary);
    border-color: var(--lk-primary);
}

.btn-outline-primary:hover {
    background: var(--lk-primary);
    border-color: var(--lk-primary);
}
