/* ===== Base Reset ===== */
*,
*::before,
*::after {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background: #f4f6f9;
    color: #1f2937;
}

/* ===== Layout ===== */
.container {
    max-width: 1100px;
    margin: 2rem auto;
    padding: 0 1.5rem;
}

/* ===== Top Bar ===== */
.topbar {
    background: #111827;
    color: #f9fafb;
    padding: 0.9rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.topbar h1 {
    font-size: 1rem;
    margin: 0;
    font-weight: 600;
    letter-spacing: 0.04em;
}

.topbar .user {
    font-size: 0.85rem;
    opacity: 0.85;
}

/* ===== Headings ===== */
h1 {
    font-size: 1.6rem;
    margin-bottom: 1rem;
}

/* ===== Card ===== */
.card {
    background: #ffffff;
    border-radius: 10px;
    padding: 1.5rem;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
}

/* ===== Forms ===== */
form {
    max-width: 420px;
}

input {
    width: 100%;
    padding: 0.6rem 0.7rem;
    margin-bottom: 1rem;
    border-radius: 6px;
    border: 1px solid #d1d5db;
    font-size: 0.9rem;
    transition: border-color 0.2s, box-shadow 0.2s;
}

input:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
    outline: none;
}

/* ===== Buttons ===== */
button,
.btn {
    background: #2563eb;
    color: white;
    border: none;
    padding: 0.55rem 1.2rem;
    border-radius: 999px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s, transform 0.05s;
    text-decoration: none;
    display: inline-block;
}

button:hover,
.btn:hover {
    background: #1d4ed8;
}

button:active {
    transform: translateY(1px);
}

.btn-secondary {
    background: #374151;
}

.btn-secondary:hover {
    background: #111827;
}

/* ===== Table Styling ===== */
.table-wrapper {
    overflow-x: auto;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
}

table {
    width: 100%;
    border-collapse: collapse;
    background: white;
}

th, td {
    padding: 0.75rem 0.9rem;
    text-align: left;
    border-bottom: 1px solid #e5e7eb;
    font-size: 0.9rem;
}

th {
    background: #f9fafb;
    font-weight: 600;
    color: #374151;
}

tr:nth-child(even) td {
    background: #fafafa;
}

/* ===== Alerts ===== */
.alert {
    padding: 0.75rem 1rem;
    border-radius: 6px;
    margin-bottom: 1rem;
    font-size: 0.85rem;
}

.alert-error {
    background: #fee2e2;
    color: #991b1b;
}

.alert-success {
    background: #dcfce7;
    color: #14532d;
}

/* ===== Login Page Specific ===== */
.auth-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: radial-gradient(circle at top, #dbeafe, #f4f6f9 60%);
}

.auth-card {
    width: 100%;
    max-width: 380px;
    padding: 2rem;
    border-radius: 14px;
    background: white;
    box-shadow: 0 25px 60px rgba(0,0,0,0.1);
}

.auth-card h2 {
    text-align: center;
    margin-bottom: 1.5rem;
}
