:root {
    /* Color Palette */
    --primary-indigo: #3730a3;
    --primary-light: rgba(55, 48, 163, 0.08);
    --secondary-pink: #db2777;
    --text-dark: #1e293b;
    --text-muted: #64748b;
    --bg-main: #f8fafc;
    --bg-card: #ffffff;
    --border-color: #e2e8f0;

    /* Spacing System */
    --space-xs: 0.5rem;
    /* 8px */
    --space-sm: 1rem;
    /* 16px */
    --space-md: 1.5rem;
    /* 24px */
    --space-lg: 2rem;
    /* 32px */
    --space-xl: 3rem;
    /* 48px */

    /* Rounded Corners */
    --radius-sm: 8px;
    --radius-md: 12px;
    /* Standard for buttons/small boxes */
    --radius-lg: 16px;
    /* Standard for Cards/Modals */
    --radius-xl: 24px;
    --radius-full: 9999px;

    /* Shadows */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

/* Base Overrides */
body {
    font-family: 'Inter', 'Sarabun', sans-serif;
    background-color: var(--bg-main);
    color: var(--text-dark);
    line-height: 1.6;
}

/* Typography Hierarchy */
h1,
.h1 {
    font-weight: 800;
    font-size: 2.25rem;
    letter-spacing: -0.025em;
    margin-bottom: var(--space-md);
    font-family: 'Sarabun', sans-serif;
}

h2,
.h2 {
    font-weight: 700;
    font-size: 1.875rem;
    letter-spacing: -0.025em;
    margin-bottom: var(--space-sm);
    font-family: 'Sarabun', sans-serif;
}

h3,
.h3 {
    font-weight: 700;
    font-size: 1.5rem;
    color: var(--text-dark);
    font-family: 'Sarabun', sans-serif;
}

h4,
.h4 {
    font-weight: 600;
    font-size: 1.25rem;
    font-family: 'Sarabun', sans-serif;
}

h5,
.h5 {
    font-weight: 600;
    font-size: 1.1rem;
    font-family: 'Sarabun', sans-serif;
}

.text-muted {
    color: var(--text-muted) !important;
}

/* Standardized Icon Wrapper (40x40px) */
.icon-box,
.icon-box-lg,
.icon-box-sm {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.icon-box {
    width: 40px !important;
    height: 40px !important;
    min-width: 40px !important;
    border-radius: var(--radius-md) !important;
}

.icon-box-lg {
    width: 48px !important;
    height: 48px !important;
    min-width: 48px !important;
    border-radius: var(--radius-lg);
}

.icon-box-sm {
    width: 32px !important;
    height: 32px !important;
    min-width: 32px !important;
    border-radius: var(--radius-sm);
}

/* Premium Card & Container */
.card-premium {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    padding: var(--space-md);
    transition: box-shadow 0.3s ease;
}

.card-premium:hover {
    box-shadow: var(--shadow-md);
}

/* Buttons and UI Elements */
.btn {
    border-radius: var(--radius-md);
    font-weight: 600;
    padding: 0.6rem 1.25rem;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-pill {
    border-radius: var(--radius-full);
}

.btn-sm {
    padding: 0.4rem 0.8rem;
    font-size: 0.875rem;
}

.btn-icon-sm {
    width: 32px;
    height: 32px;
    padding: 0 !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-sm);
}

.form-control,
.form-select {
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    padding: 0.6rem 1rem;
    font-size: 0.95rem;
}

.form-control:focus {
    border-color: var(--primary-indigo);
    box-shadow: 0 0 0 3px var(--primary-light);
}

/* Layout Containers */
.mcu-container {
    width: 80%;
    margin-left: auto;
    margin-right: auto;
}

.mcu-container-wide {
    width: 90%;
    margin-left: auto;
    margin-right: auto;
}

.mcu-container-narrow {
    width: 60%;
    margin-left: auto;
    margin-right: auto;
}

@media (max-width: 1200px) {

    .mcu-container,
    .mcu-container-wide,
    .mcu-container-narrow {
        width: 95%;
    }
}

/* DataTables Overrides for Continuity */
.dataTables_wrapper .dataTables_paginate .paginate_button {
    border-radius: var(--radius-sm) !important;
    border: none !important;
}

.dataTables_wrapper .dataTables_paginate .paginate_button.current {
    background: var(--primary-indigo) !important;
    color: white !important;
}

/* Badges */
.badge {
    border-radius: var(--radius-full);
    padding: 0.4em 0.8em;
    font-weight: 600;
    font-size: 0.65rem;
    letter-spacing: 0.5px;
}