/* ================================================
   App Hub – Custom Styles
   Bootstrap 5 Dark Theme Overrides + Custom
   ================================================ */

/* --- Global / Body --- */
body {
    background-color: #0d1117;
    color: #c9d1d9;
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

main {
    flex: 1;
}

/* --- Bootstrap Dark Mode Overrides --- */
.card {
    background-color: #161b22;
    color: #c9d1d9;
    border-color: #30363d !important;
    border-radius: 12px;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.form-control,
.form-select,
.input-group-text {
    background-color: #0d1117;
    border-color: #30363d;
    color: #c9d1d9;
}

.form-control:focus,
.form-select:focus {
    background-color: #161b22;
    border-color: #388bfd;
    color: #c9d1d9;
    box-shadow: 0 0 0 3px rgba(56, 139, 253, 0.15);
}

.form-control::placeholder {
    color: #484f58;
}

.table-dark {
    --bs-table-bg: #161b22;
    --bs-table-striped-bg: #1c2128;
    --bs-table-hover-bg: #1c2128;
    --bs-table-border-color: #30363d;
}

.table-secondary th {
    background-color: #21262d !important;
    color: #8b949e;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-color: #30363d;
}

.list-group-item.bg-dark {
    background-color: #161b22 !important;
    color: #c9d1d9;
    border-color: #30363d !important;
}

.list-group-item.bg-dark:hover {
    background-color: #1c2128 !important;
}

.list-group-item.bg-dark.active {
    background-color: #1f3a6e !important;
    border-color: #388bfd !important;
    color: #c9d1d9;
}

.dropdown-menu-dark {
    background-color: #161b22;
    border-color: #30363d;
}

.dropdown-item:hover {
    background-color: #21262d;
    color: #c9d1d9;
}

/* --- Navbar --- */
.navbar.bg-dark {
    background-color: #010409 !important;
    border-bottom-color: #21262d !important;
}

.navbar-brand {
    font-size: 1.15rem;
    letter-spacing: -0.01em;
}

/* --- Footer --- */
.footer.bg-dark {
    background-color: #010409 !important;
    border-top-color: #21262d !important;
}

/* --- Login-Seite --- */
.login-page {
    background: radial-gradient(ellipse at center, #0d1f3c 0%, #0d1117 70%);
}

.login-card {
    width: 100%;
    max-width: 420px;
    background-color: #161b22;
    border: 1px solid #30363d;
    border-radius: 16px;
}

/* --- Dashboard App-Kacheln --- */
.app-card {
    background-color: #161b22;
    border: 1px solid #30363d !important;
    border-radius: 12px;
    transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.app-card:hover {
    transform: translateY(-4px);
    border-color: #388bfd !important;
    box-shadow: 0 8px 24px rgba(56, 139, 253, 0.12);
}

.app-icon {
    user-select: none;
    line-height: 1;
}

/* --- Admin Shortcut Cards --- */
.admin-shortcut-card {
    background-color: #161b22;
    border: 1px solid #30363d !important;
    border-radius: 12px;
    color: #c9d1d9 !important;
    transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.admin-shortcut-card:hover {
    transform: translateY(-3px);
    border-color: #388bfd !important;
    box-shadow: 0 6px 20px rgba(56, 139, 253, 0.1);
    color: #ffffff !important;
}

/* --- Admin Assign: App-Checkboxen --- */
.app-assign-card {
    background-color: #0d1117;
    border: 1px solid #30363d !important;
    border-radius: 8px;
    cursor: pointer;
    transition: border-color 0.15s ease, background-color 0.15s ease;
}

.app-assign-card.assigned,
.app-assign-card:has(.form-check-input:checked) {
    border-color: #388bfd !important;
    background-color: #1f3a6e !important;
}

/* --- Alert / Badge Anpassungen --- */
.alert-success {
    background-color: #1a3a2a;
    border-color: #2ea043;
    color: #56d364;
}

.alert-danger {
    background-color: #3b1c1c;
    border-color: #f85149;
    color: #ff7b72;
}

/* --- Scrollbar (Webkit) --- */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #0d1117;
}

::-webkit-scrollbar-thumb {
    background: #30363d;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #484f58;
}

/* --- Utilities --- */
.text-truncate-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
