/* =============== Global Reset & Grundschrift =============== */
* {
    margin: 0; 
    padding: 0;
    box-sizing: border-box;
}
body {
    /* Nur globale Schrift und Hintergrund, KEINE zentrale Flex-Ausrichtung,
       damit die Sidebar im Dashboard nicht verschoben wird. */
    font-family: Arial, sans-serif;
    background: #f4f4f4;
}

/* =============== Login-spezifische Styles =============== */
/* Nur Seiten mit <body class="login-body"> bekommen horizontale/vertikale Zentrierung. */
.login-body {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Login-Container (weiße Box) */
.login-container {
    background: #fff;
    width: 320px;
    padding: 30px;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
    text-align: center;
}

.login-container h2 {
    margin-bottom: 20px;
    font-size: 1.5rem;
    color: #333;
}
.error-msg {
    color: #d00;
    margin-bottom: 15px;
}
.login-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}
.login-form input {
    padding: 10px;
    font-size: 1rem;
    border: 1px solid #ccc;
    border-radius: 4px;
}
.login-form button {
    padding: 10px;
    font-size: 1rem;
    background: #333;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}
.login-form button:hover {
    background: #444;
}

/* =============== Sidebar & Dashboard =============== */
.sidebar {
    width: 250px;
    background-color: #333;
    color: #fff;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    justify-content: space-between; 
    min-height: 100vh;
    position: fixed; /* optional */
}

.sidebar-header {
    padding: 20px;
    border-bottom: 1px solid #444;
}
.sidebar-header h2 {
    font-size: 1.2em;
    margin-bottom: 5px;
}
.sidebar-header p {
    font-size: 0.9em;
    color: #ccc;
}

.nav-links {
    list-style: none;
    margin: 0;
    padding: 0;
}
.nav-links li {
    border-bottom: 1px solid #444;
}
.nav-links li a {
    display: block;
    padding: 12px 20px;
    color: #fff;
    text-decoration: none;
    transition: background 0.3s;
}
.nav-links li a:hover {
    background-color: #444;
}

.sidebar-logout {
    border-top: 1px solid #444;
    padding: 20px;
}
.sidebar-logout a {
    color: #fff;
    text-decoration: none;
    display: inline-block;
    padding: 10px 15px;
    background-color: #555;
    transition: background 0.3s;
}
.sidebar-logout a:hover {
    background-color: #666;
}

/* Hauptinhalt rechts */
.main-content {
    margin-left: 250px; 
    padding: 20px;
}
.main-content h1 {
    margin-bottom: 10px;
}

/* === Tabellen-Styling === */
table.custom-table {
    width: 100%;
    border-collapse: collapse; 
    background-color: #fff;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    border-radius: 6px;
    overflow: hidden; /* für abgerundete Ecken bei table-outer */
    margin-top: 10px;
}

/* Tabellen-Kopf */
table.custom-table thead th {
    background-color: #f4f4f4;
    text-align: left;
    padding: 12px;
    font-weight: 600;
    border-bottom: 2px solid #ccc;
}

/* Tabellen-Zellen */
table.custom-table td {
    padding: 12px;
    border-bottom: 1px solid #eee;
}

/* Hover-Effekt für Tabellen-Zeilen */
table.custom-table tbody tr:hover {
    background-color: #fafafa;
}

/* Alternierende Zeilenfarbe (optional, statt Hover) 
   Wenn du lieber abwechselnde Zeilen willst:
*/
/*
table.custom-table tbody tr:nth-child(even) {
    background-color: #fafafa;
}
*/

/* === Link-/Button-Styling === */
a.btn {
    display: inline-block;
    padding: 6px 12px;
    margin: 2px;
    font-size: 0.9rem;
    color: #fff;
    text-decoration: none;
    border-radius: 4px;
    background-color: #0077cc; /* Corporate Farbe */
    transition: background 0.3s;
}
a.btn:hover {
    background-color: #005fa3;
}
a.btn-delete {
    background-color: #cc0000;
}
a.btn-delete:hover {
    background-color: #990000;
}
a.btn-edit {
    background-color: #44aa44;
}
a.btn-edit:hover {
    background-color: #378837;
}

/* Schmale Lücke zwischen Buttons */
.action-links a.btn {
    margin-right: 6px;
}

/* 
  === Link als "Sekundär-Button" z.B. 
  "Neuen Benutzer hinzufügen" 
*/
a.btn-secondary {
    background-color: #555;
}
a.btn-secondary:hover {
    background-color: #333;
}
