/* Main Styles for CPDMS - Standard Theme */

:root {
    --primary-color: #0d6efd;
    --secondary-color: #6c757d;
    --success-color: #198754;
    --info-color: #0dcaf0;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
    --light-color: #f8f9fa;
    --dark-color: #212529;
    --body-bg: #f5f7fa;
    --card-bg: #ffffff;
    --text-color: #333333;
    --sidebar-width: 240px;
    --header-height: 50px;
    --transition-speed: 0.25s;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background-color: var(--body-bg);
    color: var(--text-color);
    font-size: 12px;
    line-height: 1.5;
    margin: 0;
    padding: 0;
    overflow-x: hidden;
}

/* Typography Standardized to 12px Base */
h1,
.h1 {
    font-size: 1.4rem !important;
    font-weight: 700;
}

h2,
.h2 {
    font-size: 1.25rem !important;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

h3,
.h3 {
    font-size: 1.1rem !important;
    font-weight: 600;
}

h4,
.h4 {
    font-size: 1rem !important;
    font-weight: 600;
}

h5,
.h5 {
    font-size: 0.9rem !important;
    font-weight: 600;
}

h6,
.h6 {
    font-size: 0.85rem !important;
    font-weight: 600;
}

.text-muted,
.small,
small {
    font-size: 12px !important;
}

/* Button Styling */
.btn {
    font-size: 12px;
    padding: 0.4rem 1rem;
    font-weight: 500;
    border-radius: 6px;
    transition: all var(--transition-speed);
}

.btn-sm {
    padding: 0.25rem 0.75rem;
    font-size: 11px;
}

/* Sidebar Styling */
.sidebar {
    height: 100vh;
    width: var(--sidebar-width);
    position: fixed;
    top: 0;
    left: 0;
    background-color: var(--dark-color);
    transition: all var(--transition-speed);
    z-index: 1001;
    overflow-y: auto;
}

.sidebar a {
    padding: 10px 18px;
    text-decoration: none;
    font-size: 13px;
    color: #bdbdbd;
    display: flex;
    align-items: center;
    transition: 0.2s;
}

.sidebar-category {
    font-size: 11px;
    text-transform: uppercase;
    color: #6c757d;
    padding: 20px 18px 8px;
    font-weight: 700;
    letter-spacing: 0.5px;
}

/* Main Content Area */
.main-content {
    margin-left: var(--sidebar-width);
    padding: 1.5rem;
    padding-top: calc(var(--header-height) + 1.5rem);
    transition: margin-left var(--transition-speed);
}

/* Navbar */
.top-navbar {
    height: var(--header-height);
    background-color: var(--card-bg);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    position: fixed;
    top: 0;
    left: var(--sidebar-width);
    right: 0;
    z-index: 999;
    display: flex;
    align-items: center;
    padding: 0 1.5rem;
}

/* Card Styling */
.card {
    border-radius: 8px;
    border: 1px solid rgba(0, 0, 0, 0.1);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05) !important;
}

.card-header {
    padding: 0.85rem 1.25rem;
    font-weight: 600;
    font-size: 13px;
}

.card-body {
    padding: 1.25rem;
}

/* Table Style Reversal - Back to standard */
.table {
    font-size: 12px;
}

.table th {
    font-weight: 600;
    background-color: transparent;
    border-bottom: 2px solid #dee2e6;
    color: #495057;
    text-transform: none;
    letter-spacing: normal;
}

.table td {
    padding: 0.75rem;
    vertical-align: middle;
}

/* Form Styling */
.form-label {
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #333;
}

.form-control,
.form-select {
    font-size: 12px;
    padding: 0.375rem 0.75rem;
    border-radius: 4px;
}

/* Custom Premium Components */
.btn-premium {
    background: linear-gradient(135deg, var(--primary-color), #0a58ca);
    color: white;
    border: none;
    box-shadow: 0 2px 4px rgba(13, 110, 253, 0.2);
}

/* Select2 Customization */
.select2-container--bootstrap-5 .select2-selection {
    font-size: 12px !important;
    min-height: 35px !important;
}

/* Badge Styling */
.badge {
    font-size: 11px !important;
    padding: 0.35em 0.65em !important;
    font-weight: 600;
}

/* Animations */
.fade-in {
    animation: fadeIn 0.4s ease-out forwards;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .sidebar {
        margin-left: -240px;
    }

    .sidebar.active {
        margin-left: 0;
    }

    .main-content {
        margin-left: 0;
        padding-top: 70px;
    }

    .top-navbar {
        left: 0;
        width: 100%;
    }

    /* Login Page Specifics */
    .login-container {
        max-width: 450px;
        width: 100%;
    }

    .glass-panel {
        background: rgba(255, 255, 255, 1);
        border: 1px solid rgba(0, 0, 0, 0.1);
        border-radius: 12px;
        box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    }

    .glass-panel h2 {
        font-size: 1.8rem !important;
    }

    .glass-panel .form-control {
        font-size: 14px !important;
        padding: 0.75rem 1rem !important;
    }

    .glass-panel .form-floating label {
        font-size: 14px !important;
    }

    .glass-panel .btn-lg {
        font-size: 16px !important;
        padding: 0.8rem !important;
    }

    .glass-panel p.text-muted {
        font-size: 14px !important;
    }