/* GLS Paket Monitor - Custom Styles */

:root {
    --sidebar-width: 260px;
    --sidebar-bg: #1a1d23;
    --sidebar-hover: #2a2d35;
    --sidebar-active: #3b82f6;
}

/* ── Layout ─────────────────────────────────────────── */

body {
    min-height: 100vh;
    background: #0f1117;
}

.sidebar {
    width: var(--sidebar-width);
    min-height: 100vh;
    background: var(--sidebar-bg);
    position: fixed;
    top: 0;
    left: 0;
    z-index: 100;
    border-right: 1px solid rgba(255, 255, 255, 0.05);
}

.main-content {
    margin-left: var(--sidebar-width);
    min-height: 100vh;
}

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

.sidebar-brand {
    padding: 0.5rem;
    display: flex;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding-bottom: 1rem;
}

.sidebar .nav-link {
    color: #9ca3af;
    border-radius: 8px;
    padding: 0.6rem 1rem;
    transition: all 0.2s;
    font-size: 0.9rem;
}

.sidebar .nav-link:hover {
    background: var(--sidebar-hover);
    color: #fff;
}

.sidebar .nav-link.active {
    background: var(--sidebar-active);
    color: #fff;
    font-weight: 500;
}

/* ── Cards ──────────────────────────────────────────── */

.card {
    background: #1a1d23;
    border-radius: 12px;
}

.card-header {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding: 1rem 1.25rem;
}

.stat-card {
    transition: transform 0.2s, box-shadow 0.2s;
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.stat-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.stat-value {
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1.2;
}

.stat-label {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* ── Tables ─────────────────────────────────────────── */

.table {
    --bs-table-bg: transparent;
}

.table thead th {
    background: rgba(255, 255, 255, 0.03);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #9ca3af;
    padding: 0.75rem 1rem;
    font-weight: 600;
}

.table tbody td {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
    vertical-align: middle;
}

.table-hover tbody tr:hover {
    background: rgba(255, 255, 255, 0.03);
}

/* ── Badges ─────────────────────────────────────────── */

.badge {
    font-weight: 500;
    padding: 0.4em 0.8em;
    border-radius: 6px;
}

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

.btn {
    border-radius: 8px;
    font-size: 0.875rem;
}

.btn-group-sm .btn {
    padding: 0.25rem 0.5rem;
}

/* ── Forms ──────────────────────────────────────────── */

.form-control,
.form-select {
    background: #2a2d35;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: #e5e7eb;
}

.form-control:focus,
.form-select:focus {
    background: #2a2d35;
    border-color: var(--sidebar-active);
    box-shadow: 0 0 0 0.2rem rgba(59, 130, 246, 0.15);
    color: #e5e7eb;
}

.form-control[readonly] {
    background: #1f2228;
    opacity: 0.7;
}

/* ── Alerts ─────────────────────────────────────────── */

.alert {
    border-radius: 10px;
    border: none;
}

/* ── Modal ──────────────────────────────────────────── */

.modal-content {
    background: #1a1d23;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
}

/* ── Dropdown ───────────────────────────────────────── */

.dropdown-menu {
    background: #2a2d35;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
}

.dropdown-item {
    color: #e5e7eb;
    border-radius: 4px;
    margin: 2px 4px;
    padding: 0.4rem 0.8rem;
}

.dropdown-item:hover {
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
}

/* ── Toast ──────────────────────────────────────────── */

.toast {
    background: #2a2d35;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
}

/* ── Scrollbar ──────────────────────────────────────── */

::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: #3a3d45;
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: #4a4d55;
}

/* ── List Group ─────────────────────────────────────── */

.list-group-item {
    background: transparent;
    border-color: rgba(255, 255, 255, 0.03);
    padding: 0.75rem 1.25rem;
}

/* ── Responsive ─────────────────────────────────────── */

@media (max-width: 768px) {
    .sidebar {
        width: 100%;
        min-height: auto;
        position: relative;
        border-right: none;
        border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    }

    .sidebar .nav {
        flex-direction: row !important;
        overflow-x: auto;
        flex-wrap: nowrap;
    }

    .sidebar .mt-auto {
        display: none;
    }

    .main-content {
        margin-left: 0;
    }

    .d-flex {
        flex-direction: column;
    }
}

/* ── Code ───────────────────────────────────────────── */

code {
    color: #60a5fa;
    font-size: 0.85rem;
}

pre {
    font-size: 0.85rem;
}
