/* -----------------------------
   RESET
----------------------------- */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* -----------------------------
   BODY
----------------------------- */

body {
    font-family:
        Inter,
        system-ui,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        sans-serif;
    background: #f5f7fa;
    color: #1f2937;
    line-height: 1.5;
}

/* -----------------------------
   NAVBAR
----------------------------- */

.navbar {
    background: #111827;
    border-bottom: 1px solid #1f2937;
    padding: 1rem 2rem;
}

.nav-left {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.nav-left a {
    color: #f9fafb;
    text-decoration: none;
    padding: 0.5rem 0.9rem;
    border-radius: 8px;
    transition:
        background 0.2s ease,
        color 0.2s ease;
}

.nav-left a:hover {
    background: #374151;
}

/* -----------------------------
   MAIN CONTAINER
----------------------------- */

.container {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 1rem;
}

/* -----------------------------
   TOOLBAR
----------------------------- */

.toolbar {
    display: flex;

    justify-content: space-between;

    align-items: center;

    gap: 1rem;

    margin-bottom: 1.5rem;
}

/* -----------------------------
   BUTTONS / LINKS
----------------------------- */
/* 
.toolbar a,
button {
    background: #2563eb;

    color: white;

    border: none;

    text-decoration: none;

    padding: 0.7rem 1rem;

    border-radius: 8px;

    cursor: pointer;

    font-size: 0.95rem;

    transition:
        background 0.2s ease,
        transform 0.1s ease;
}

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

.toolbar a:active,
button:active {
    transform: scale(0.98);
} */

/* -----------------------------
   INPUTS
----------------------------- */

input,
select,
textarea {
    width: 100%;

    padding: 0.7rem 0.9rem;

    border: 1px solid #d1d5db;

    border-radius: 8px;

    background: white;

    font-size: 0.95rem;

    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

input:focus,
select:focus,
textarea:focus {
    outline: none;

    border-color: #2563eb;

    box-shadow:
        0 0 0 3px rgba(37, 99, 235, 0.15);
}

/* -----------------------------
   TABLES
----------------------------- */

table {
    width: 100%;

    border-collapse: collapse;

    background: white;

    border-radius: 12px;

    overflow: hidden;

    box-shadow:
        0 2px 8px rgba(0, 0, 0, 0.05);
}

/* -----------------------------
   TABLE HEADER
----------------------------- */

thead {
    background: #f3f4f6;
}

th {
    text-align: left;

    padding: 1rem;

    font-weight: 600;

    color: #374151;

    border-bottom: 1px solid #e5e7eb;

    user-select: none;
}

/* sortable columns */

th[data-sort] {
    cursor: pointer;

    transition:
        background 0.2s ease;
}

th[data-sort]:hover {
    background: #e5e7eb;
}

/* -----------------------------
   TABLE BODY
----------------------------- */

td {
    padding: 1rem;

    border-bottom: 1px solid #f1f5f9;
}

tbody tr {
    transition:
        background 0.15s ease;
}

tbody tr:hover {
    background: #f9fafb;
}

tr.inactive {
    background-color: #a18d8d;
}

/* remove last border */

tbody tr:last-child td {
    border-bottom: none;
}

/* -----------------------------
   CARDS / PANELS
----------------------------- */

.card {
    background: white;

    border-radius: 12px;

    padding: 1.5rem;

    box-shadow:
        0 2px 8px rgba(0, 0, 0, 0.05);
}

/* -----------------------------
   FORMS
----------------------------- */

form {
    display: flex;

    flex-direction: column;

    gap: 1rem;
}

label {
    font-weight: 600;

    color: #374151;
}

/* -----------------------------
   HEADINGS
----------------------------- */

h1,
h2,
h3 {
    margin-bottom: 1rem;

    color: #111827;
}

/* -----------------------------
   SMALL TEXT
----------------------------- */

small {
    color: #6b7280;
}

/* -----------------------------
   ALERTS
----------------------------- */

.alert {
    padding: 1rem;

    border-radius: 8px;

    margin-bottom: 1rem;
}

.alert-success {
    background: #dcfce7;

    color: #166534;
}

.alert-error {
    background: #fee2e2;

    color: #991b1b;
}

/* -----------------------------
   RESPONSIVE
----------------------------- */

@media (max-width: 768px) {

    .toolbar {
        flex-direction: column;

        align-items: stretch;
    }

    .nav-left {
        flex-wrap: wrap;
    }

    table {
        display: block;

        overflow-x: auto;
    }
}








/* -----------------------------
   ACTION BUTTONS
----------------------------- */

.actions {
    display: flex;

    gap: 0.5rem;

    align-items: center;

    flex-wrap: wrap;
}

.btn {
    display: inline-flex;

    align-items: center;

    justify-content: center;

    gap: 0.3rem;

    padding: 0.45rem 0.8rem;

    border-radius: 8px;

    text-decoration: none;

    border: none;

    cursor: pointer;

    font-size: 0.9rem;

    transition:
        background 0.2s ease,
        transform 0.1s ease;
}

.btn:hover {
    transform: translateY(-1px);
}

/* VIEW */

.btn-view {
    background: #e0f2fe;

    color: #0369a1;
}

.btn-view:hover {
    background: #bae6fd;
}

/* EDIT */

.btn-edit {
    background: #fef3c7;

    color: #92400e;
}

.btn-edit:hover {
    background: #fde68a;
}

/* DELETE */

.btn-delete {
    background: #fee2e2;

    color: #991b1b;
}

.btn-delete:hover {
    background: #fecaca;
}

/* inline form */

.inline-form {
    display: inline;
}