html {
    font-size: 14px;
    position: relative;
    min-height: 100%;
}

@media (min-width: 768px) {
    html {
        font-size: 16px;
    }
}

body {
    background: #f4f8f5;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin-bottom: 60px;
    color: #1f2937;
}


/* =========================
   NAVBAR
========================= */

.navbar {
    background: linear-gradient(90deg, #14532d, #198754);
    box-shadow: 0 4px 15px rgba(0,0,0,0.08);
}

.navbar-brand,
.nav-link {
    color: white !important;
    font-weight: 500;
}

    .nav-link:hover {
        opacity: .85;
    }


/* =========================
   CARDS
========================= */

.card {
    border: none;
    border-radius: 18px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.08);
    overflow: hidden;
    background: white;
}

.card-header {
    background: linear-gradient(90deg, #198754, #157347);
    color: white;
    font-weight: 600;
    border: none;
    padding: 18px;
    font-size: 18px;
}

.card-body {
    padding: 30px;
}


/* =========================
   BUTTONS
========================= */

.btn-success,
.btn-primary {
    background: linear-gradient(90deg, #198754, #157347);
    border: none;
    border-radius: 12px;
    padding: 10px 20px;
    font-weight: 600;
    transition: .3s;
}

    .btn-success:hover,
    .btn-primary:hover {
        transform: translateY(-2px);
        box-shadow: 0 6px 14px rgba(25,135,84,.25);
    }


/* =========================
   INPUTS
========================= */

.form-control,
.form-select {
    border-radius: 12px;
    border: 1px solid #d1d5db;
    padding: 12px;
    transition: .3s;
    background-color: #fff;
}

    .form-control:focus,
    .form-select:focus {
        border-color: #198754;
        box-shadow: 0 0 0 0.2rem rgba(25,135,84,.15);
    }


/* =========================
   TABLES
========================= */

.table {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 18px rgba(0,0,0,0.05);
}

    .table thead {
        background: #198754;
        color: white;
    }

    .table th {
        border: none;
        padding: 15px;
        font-weight: 600;
    }

    .table td {
        padding: 14px;
        vertical-align: middle;
    }

    .table tbody tr:hover {
        background: #f0fdf4;
    }


/* =========================
   TITLES
========================= */

h1, h2, h3, h4 {
    color: #9efcc3;
    font-weight: 700;
}


/* =========================
   CONTAINERS
========================= */

.container-custom {
    background: white;
    padding: 30px;
    border-radius: 20px;
    box-shadow: 0 8px 24px rgba(0,0,0,.06);
    margin-top: 30px;
}


/* =========================
   LABELS
========================= */

label {
    font-weight: 600;
    margin-bottom: 8px;
    color: #374151;
}


/* =========================
   BADGES
========================= */

.badge-success {
    background: #dcfce7;
    color: #166534;
    padding: 8px 14px;
    border-radius: 30px;
    font-size: 12px;
}


/* =========================
   FOOTER
========================= */

footer {
    background: white;
    border-top: 1px solid #e5e7eb;
    padding: 15px;
    text-align: center;
    color: #6b7280;
}
body {
    margin: 0;
    background: #f4f8f5;
    font-family: 'Segoe UI', sans-serif;
}

/* ======================
   SIDEBAR
====================== */

.sidebar {
    width: 220px;
    height: 100vh;
    background: linear-gradient(180deg, #14532d, #198754);
    color: white;
    position: fixed;
    padding-top: 20px;
    box-shadow: 4px 0 15px rgba(0,0,0,0.08);
}

.logo-section {
    text-align: center;
    margin-bottom: 40px;
}

    .logo-section h3 {
        font-weight: bold;
        margin: 0;
    }

    .logo-section small {
        opacity: .8;
    }

.menu {
    list-style: none;
    padding: 0;
}

    .menu li {
        margin: 8px 15px;
    }

        .menu li a {
            display: flex;
            align-items: center;
            gap: 12px;
            color: white;
            text-decoration: none;
            padding: 14px;
            border-radius: 12px;
            transition: .3s;
            font-size: 15px;
        }

            .menu li a:hover {
                background: rgba(255,255,255,0.15);
                transform: translateX(5px);
            }

/* ======================
   MAIN CONTENT
====================== */

.main-content {
    margin-left: 220px;
    width: calc(100% );
}

/* ======================
   TOPBAR
====================== */

.topbar {
    height: 75px;
    background: white;
    padding: 0 30px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 4px 14px rgba(0,0,0,0.05);
}

.page-title {
    margin: 0;
    color: #14532d;
    font-weight: 700;
}

.user-box {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
    color: #374151;
}

    .user-box i {
        font-size: 28px;
        color: #198754;
    }

/* ======================
   CONTENT
====================== */

.content-wrapper {
    padding: 30px;
}

/* ======================
   CARDS
====================== */

.card {
    border: none;
    border-radius: 20px;
    box-shadow: 0 8px 24px rgba(0,0,0,.06);
}

.card-header {
    background: linear-gradient(90deg, #198754, #157347);
    color: white;
    border: none;
    padding: 18px;
    font-weight: 600;
}

/* ======================
   TABLES
====================== */

.table {
    background: white;
    border-radius: 15px;
    overflow: hidden;
}

    .table thead {
        background: #198754;
        color: white;
    }

/* ======================
   BUTTONS
====================== */

.btn-success {
    background: linear-gradient(90deg, #198754, #157347);
    border: none;
    border-radius: 10px;
    padding: 10px 18px;
}

    .btn-success:hover {
        transform: translateY(-2px);
    }


.tabla-card {
    border: none;
    border-radius: 22px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
    background: white;
}

    .tabla-card .card-header {
        background: linear-gradient(135deg, #198754, #14532d);
        color: white;
        padding: 22px;
        border: none;
    }

        .tabla-card .card-header h3 {
            font-weight: 700;
        }

.table {
    margin-bottom: 0;
}

    .table thead {
        background: #198754;
        color: white;
    }

        .table thead th {
            border: none;
            padding: 16px;
            font-size: 15px;
        }

    .table tbody td {
        padding: 18px;
        vertical-align: middle;
        border-color: #f1f1f1;
    }

    .table tbody tr {
        transition: .2s;
    }

        .table tbody tr:hover {
            background: #f0fdf4;
            transform: scale(1.003);
        }

.badge {
    padding: 8px 14px;
    border-radius: 30px;
    font-weight: 600;
}

.btn-light {
    border-radius: 10px;
    font-weight: 600;
}

.dataTables_wrapper .dataTables_filter input {
    border-radius: 10px;
    border: 1px solid #d1d5db;
    padding: 8px;
    margin-left: 10px;
}

.dataTables_wrapper .dataTables_length select {
    border-radius: 10px;
    border: 1px solid #d1d5db;
    padding: 5px;
}

.dataTables_wrapper .dataTables_paginate .paginate_button {
    border-radius: 8px !important;
    margin: 2px;
}

    .dataTables_wrapper .dataTables_paginate .paginate_button.current {
        background: #198754 !important;
        color: white !important;
        border: none !important;
    }

.btn-secondary {
    color: #fff;
    background-color: #a10000;
    border-color: #a10000;
}

    .btn-secondary:hover {
        color: #fff;
        background-color: #fb1616;
        border-color: #fb1616;
    }



.table > :not(caption) > * > * {
    padding: .5rem .5rem;
    background-color: #d1e7dd00;
    border-bottom-width: 1px;
    box-shadow: inset 0 0 0 9999px var(--bs-table-accent-bg);
}


.page-item.active .page-link {
    z-index: 3;
    color: #fff;
    background-color: #198754;
    border-color: #198754;
}

.page-link {
    color: #198754;
}



@media (max-width:768px) {

    .sidebar {
        position: fixed;
        left: -250px;
        top: 0;
        width: 250px;
        height: 100%;
        z-index: 1000;
        transition: all 0.3s ease;
    }

        .sidebar.active {
            left: 0;
        }

    .main-content {
        margin-left: 0 !important;
        width: 100% !important;
        flex: 1;
    }

    .d-flex {
        display: block !important;
    }

    .topbar {
        display: flex;
        align-items: center;
        gap: 10px;
    }

    #btnMenu {
        position: relative;
        z-index: 1001;
    }
}