@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Outfit:wght@400;500;600;700;800&display=swap');

:root {
    --primary: #0f4c81;       /* Classic Royal Blue */
    --primary-dark: #0a3357;  /* Darker Navy */
    --primary-light: #e6f0fa; /* Soft Light Blue */
    --accent: #457b9d;        /* Muted Blue */
    --bg-main: #f8fafc;       /* Light Slate Gray */
    --bg-card: #ffffff;
    --text-main: #1e293b;     /* Dark Slate */
    --text-muted: #64748b;    /* Slate Gray */
    --border-color: #e2e8f0;  /* Cool Gray */
    --success: #10b981;       /* Emerald Green */
    --success-light: #d1fae5;
    --warning: #f59e0b;       /* Amber Orange */
    --warning-light: #fef3c7;
    --danger: #ef4444;        /* Rose Red */
    --danger-light: #fee2e2;
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 18px;
}

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

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-main);
    color: var(--text-main);
    line-height: 1.5;
    min-height: 100vh;
    width: 100%;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Outfit', sans-serif;
    color: var(--primary-dark);
    font-weight: 700;
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: all 0.2s ease;
}

/* LOGIN LAYOUT (Premium 2-Column Split) */
.login-wrapper {
    display: flex;
    min-height: 100vh;
    width: 100vw;
}

.login-left {
    flex: 1.2;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 4rem;
    color: #ffffff;
    overflow: hidden;
}

.login-left::before {
    content: '';
    position: absolute;
    top: -20%;
    right: -20%;
    width: 80%;
    height: 80%;
    background: radial-gradient(circle, rgba(255,255,255,0.08) 0%, transparent 60%);
    border-radius: 50%;
    pointer-events: none;
}

.login-left::after {
    content: '';
    position: absolute;
    bottom: -10%;
    left: -10%;
    width: 60%;
    height: 60%;
    background: linear-gradient(45deg, rgba(255,255,255,0.03) 0%, transparent 70%);
    transform: rotate(30deg);
    pointer-events: none;
}

.login-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.5rem;
    font-weight: 800;
    font-family: 'Outfit', sans-serif;
}

.brand-icon {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 4px;
    width: 24px;
    height: 24px;
}

.brand-icon span {
    width: 10px;
    height: 10px;
    background-color: #ffffff;
    border-radius: 2px;
}

.brand-icon span:nth-child(2) {
    background-color: rgba(255,255,255,0.6);
}

.login-left-content {
    max-width: 480px;
    z-index: 10;
}

.login-left-content h2 {
    color: #ffffff;
    font-size: 2.5rem;
    line-height: 1.2;
    margin-bottom: 1.5rem;
}

.login-left-content p {
    color: rgba(255, 255, 255, 0.8);
    font-size: 1.1rem;
    line-height: 1.6;
}

.login-footer-text {
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.5);
    z-index: 10;
}

.login-right {
    flex: 1;
    background-color: #ffffff;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 3rem;
}

.login-card {
    width: 100%;
    max-width: 420px;
}

.login-header {
    margin-bottom: 2.5rem;
}

.login-header span {
    text-transform: uppercase;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    color: var(--accent);
    display: block;
    margin-bottom: 0.5rem;
}

.login-header h3 {
    font-size: 2rem;
    color: var(--primary-dark);
}

.login-header p {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin-top: 0.5rem;
}

/* Simulated Bypass Login Buttons */
.simulation-box {
    margin-top: 2rem;
    border: 1px dashed var(--border-color);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    background-color: var(--bg-main);
}

.simulation-box h4 {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 1rem;
    text-align: center;
}

.simulation-buttons {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.btn-simulation {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    background-color: #ffffff;
    border: 1px solid var(--border-color);
    padding: 0.75rem 1rem;
    border-radius: var(--radius-md);
    cursor: pointer;
    font-weight: 600;
    color: var(--text-main);
    transition: all 0.2s ease;
    box-shadow: var(--shadow-sm);
}

.btn-simulation:hover {
    border-color: var(--primary);
    background-color: var(--primary-light);
    color: var(--primary-dark);
    transform: translateY(-2px);
}

.btn-simulation img {
    width: 20px;
    height: 20px;
}

.simulation-note {
    font-size: 0.775rem;
    color: var(--text-muted);
    margin-top: 1rem;
    text-align: center;
    line-height: 1.4;
}

/* APP MAIN DASHBOARD LAYOUT */
.dashboard-container {
    display: flex;
    min-height: 100vh;
    width: 100%;
    overflow-x: hidden;
}

/* SIDEBAR */
.sidebar {
    width: 280px;
    background-color: var(--primary-dark);
    color: #ffffff;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 2rem 1.5rem;
    flex-shrink: 0;
}

.sidebar-top {
    display: flex;
    flex-direction: column;
    gap: 2.5rem;
}

.sidebar-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding-left: 0.5rem;
}

.sidebar-brand h2 {
    color: #ffffff;
    font-size: 1.35rem;
    font-weight: 800;
}

.sidebar-menu {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    border-radius: var(--radius-md);
    color: rgba(255, 255, 255, 0.7);
    font-weight: 500;
    transition: all 0.2s ease;
}

.sidebar-link:hover, .sidebar-link.active {
    background-color: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

.sidebar-link svg {
    width: 20px;
    height: 20px;
    fill: currentColor;
}

.sidebar-footer {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.user-profile-summary {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 0.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.avatar-initial {
    width: 40px;
    height: 40px;
    background-color: var(--primary);
    color: #ffffff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.1rem;
    border: 2px solid rgba(255, 255, 255, 0.2);
}

.profile-info {
    overflow: hidden;
}

.profile-name {
    font-weight: 600;
    font-size: 0.9rem;
    white-space: nowrap;
    text-overflow: ellipsis;
    overflow: hidden;
}

.profile-role {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.5);
}

.btn-logout {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem;
    background-color: rgba(239, 68, 68, 0.15);
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-radius: var(--radius-md);
    color: #fca5a5;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-logout:hover {
    background-color: var(--danger);
    color: #ffffff;
    border-color: var(--danger);
}

/* MAIN CONTENT */
.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    width: 100%;
    min-width: 0;
    overflow-x: hidden;
}

.top-navbar {
    background-color: #ffffff;
    height: 70px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 2rem;
    position: sticky;
    top: 0;
    z-index: 100;
}

.navbar-title h1 {
    font-size: 1.5rem;
}

.navbar-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.badge-store {
    background-color: var(--primary-light);
    color: var(--primary-dark);
    padding: 0.4rem 1rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    border: 1px solid rgba(15, 76, 129, 0.15);
}

/* CONTENT CONTAINER */
.content-body {
    padding: 2rem;
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
}

/* STATS GRID */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card {
    background-color: #ffffff;
    border-radius: var(--radius-md);
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: transform 0.2s, box-shadow 0.2s;
}

.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.stat-value {
    font-size: 2rem;
    font-weight: 800;
    color: var(--primary-dark);
    line-height: 1.1;
    margin-top: 0.25rem;
}

.stat-label {
    font-size: 0.875rem;
    color: var(--text-muted);
    font-weight: 500;
}

.stat-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.stat-icon-primary {
    background-color: var(--primary-light);
    color: var(--primary);
}

.stat-icon-success {
    background-color: var(--success-light);
    color: var(--success);
}

.stat-icon-warning {
    background-color: var(--warning-light);
    color: var(--warning);
}

.stat-icon-danger {
    background-color: var(--danger-light);
    color: var(--danger);
}

/* GRID LAYOUTS */
.dashboard-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 1.5rem;
}

@media (max-width: 992px) {
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
}

/* CARDS */
.card {
    background-color: #ffffff;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
    margin-bottom: 1.5rem;
    overflow: hidden;
}

.card-header {
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.card-header h3 {
    font-size: 1.1rem;
}

.card-body {
    padding: 1.5rem;
}

/* THEME LIST & DETAILS */
.theme-strip {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    padding: 1rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    margin-bottom: 1rem;
    transition: all 0.2s ease;
}

.theme-strip:hover {
    border-color: var(--primary);
    background-color: #fafbfc;
}

.theme-strip-img {
    width: 60px;
    height: 60px;
    border-radius: var(--radius-sm);
    object-fit: cover;
    background-color: #eaeaea;
}

.theme-strip-info {
    flex: 1;
}

.theme-strip-info h4 {
    font-size: 1rem;
    color: var(--primary-dark);
}

.theme-strip-meta {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 0.25rem;
    display: flex;
    gap: 1rem;
}

/* COLOR PALETTE SWATCH */
.palette-swatches {
    display: flex;
    gap: 6px;
    margin-top: 0.5rem;
}

.swatch {
    width: 20px;
    height: 20px;
    border-radius: 4px;
    border: 1px solid rgba(0,0,0,0.1);
    display: inline-block;
    cursor: pointer;
    position: relative;
}

.swatch:hover::after {
    content: attr(title);
    position: absolute;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
    background-color: rgba(0,0,0,0.8);
    color: #fff;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 9px;
    white-space: nowrap;
    z-index: 10;
}

/* BADGES */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.badge-active, .badge-approved {
    background-color: var(--success-light);
    color: var(--success);
}

.badge-draft, .badge-pending {
    background-color: var(--warning-light);
    color: var(--warning);
}

.badge-archived, .badge-revision {
    background-color: var(--danger-light);
    color: var(--danger);
}

/* TABLES */
.custom-table-container {
    overflow-x: auto;
}

.custom-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
}

.custom-table th {
    background-color: #f8fafc;
    color: var(--text-muted);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.custom-table td {
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--border-color);
    font-size: 0.9rem;
}

.custom-table tr:hover {
    background-color: #fafafa;
}

/* FORMS */
.form-group {
    margin-bottom: 1.25rem;
}

.form-group label {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-main);
    margin-bottom: 0.5rem;
}

.form-control {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background-color: #ffffff;
    font-family: inherit;
    font-size: 0.9rem;
    color: var(--text-main);
    transition: border-color 0.2s;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(15, 76, 129, 0.1);
}

textarea.form-control {
    min-height: 100px;
    resize: vertical;
}

.palette-picker-container {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

/* BUTTONS */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.65rem 1.25rem;
    border-radius: var(--radius-md);
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1px solid transparent;
}

.btn-primary {
    background-color: var(--primary);
    color: #ffffff;
}

.btn-primary:hover {
    background-color: var(--primary-dark);
    transform: translateY(-1px);
}

.btn-secondary {
    background-color: #ffffff;
    border-color: var(--border-color);
    color: var(--text-main);
}

.btn-secondary:hover {
    background-color: var(--bg-main);
    border-color: var(--text-muted);
}

.btn-success {
    background-color: var(--success);
    color: #ffffff;
}

.btn-success:hover {
    background-color: #059669;
}

.btn-danger {
    background-color: var(--danger);
    color: #ffffff;
}

.btn-danger:hover {
    background-color: #dc2626;
}

.btn-sm {
    padding: 0.4rem 0.85rem;
    font-size: 0.8rem;
    border-radius: var(--radius-sm);
}

/* UPLOAD CONTAINER */
.upload-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.upload-slot {
    border: 2px dashed var(--border-color);
    border-radius: var(--radius-md);
    padding: 2rem;
    text-align: center;
    background-color: #fafbfc;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
}

.upload-slot:hover {
    border-color: var(--primary);
    background-color: var(--primary-light);
}

.upload-icon {
    color: var(--text-muted);
    font-size: 2rem;
    margin-bottom: 0.75rem;
    display: block;
}

.upload-slot h4 {
    font-size: 0.95rem;
    color: var(--primary-dark);
    margin-bottom: 0.25rem;
}

.upload-slot p {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.upload-slot input[type="file"] {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

.uploaded-preview-img {
    width: 100%;
    max-height: 180px;
    object-fit: cover;
    border-radius: var(--radius-sm);
    margin-top: 1rem;
    border: 1px solid var(--border-color);
}

/* DETAIL PANELS */
.guideline-showcase {
    position: relative;
    border-radius: var(--radius-md);
    overflow: hidden;
    height: 250px;
    background-color: #eaeaea;
    margin-bottom: 1.5rem;
}

.guideline-showcase img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.guideline-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.8) 0%, transparent 100%);
    padding: 1.5rem;
    color: #ffffff;
}

.guideline-overlay h2 {
    color: #ffffff;
    font-size: 1.75rem;
}

.guideline-overlay p {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
}

/* DETAIL COLUMNS */
.detail-info-grid {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 1.5rem;
}

@media (max-width: 768px) {
    .detail-info-grid {
        grid-template-columns: 1fr;
    }
}

.info-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-weight: 700;
    text-transform: uppercase;
    display: block;
    margin-bottom: 0.25rem;
}

.info-val {
    font-size: 1rem;
    font-weight: 600;
    color: var(--primary-dark);
}

/* SUBMISSION DETAIL PHOTOS POPUP */
.submission-review-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-bottom: 1.5rem;
}

@media (max-width: 768px) {
    .submission-review-grid {
        grid-template-columns: 1fr;
    }
}

.review-photo-card {
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
    background-color: var(--bg-main);
}

.review-photo-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.review-photo-title {
    padding: 0.75rem;
    text-align: center;
    font-size: 0.85rem;
    font-weight: 600;
    background-color: #ffffff;
    border-top: 1px solid var(--border-color);
}

.empty-photo-placeholder {
    height: 200px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    background-color: #f1f5f9;
    font-size: 0.8rem;
    text-align: center;
    padding: 1rem;
}

.empty-photo-placeholder svg {
    width: 32px;
    height: 32px;
    margin-bottom: 0.5rem;
    opacity: 0.4;
}

/* ALERT MESSAGES */
.alert {
    padding: 1rem 1.25rem;
    border-radius: var(--radius-md);
    margin-bottom: 1.5rem;
    font-weight: 500;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.alert-success {
    background-color: var(--success-light);
    color: #065f46;
    border: 1px solid rgba(16, 185, 129, 0.2);
}

.alert-error {
    background-color: var(--danger-light);
    color: #991b1b;
    border: 1px solid rgba(239, 68, 68, 0.2);
}

/* MOBILE & RESPONSIVE COMPATIBILITY (FIT FOR ALL MOBILE SCREEN SIZES) */

/* Minimalist Hamburger Button (Unequal Length Lines) */
.mobile-menu-toggle {
    display: none; /* Hidden by default on desktop */
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    width: 24px;
    height: 18px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 1010;
    gap: 5px;
}

.mobile-menu-toggle span {
    display: block;
    height: 2.5px;
    background-color: var(--primary-dark);
    border-radius: 2px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.mobile-menu-toggle span:nth-child(1) {
    width: 24px;
}

.mobile-menu-toggle span:nth-child(2) {
    width: 14px;
}

/* Sidebar Backdrop */
.sidebar-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    background-color: rgba(10, 51, 87, 0.4);
    backdrop-filter: blur(4px);
    z-index: 990;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.sidebar-backdrop.active {
    opacity: 1;
    pointer-events: auto;
}

/* Sibling selector animation for Hamburger menu icon */
.sidebar.open ~ .main-content .mobile-menu-toggle span:nth-child(1) {
    transform: translateY(4px) rotate(45deg);
    width: 24px;
}

.sidebar.open ~ .main-content .mobile-menu-toggle span:nth-child(2) {
    transform: translateY(-3.5px) rotate(-45deg);
    width: 24px;
}

@media (max-width: 768px) {
    /* Enable Hamburger & Backdrop UI elements */
    .mobile-menu-toggle {
        display: flex;
    }
    
    .sidebar-backdrop {
        display: block;
    }

    /* 1. Convert Sidebar to Slide-Out Drawer overlay (using display:none by default to prevent layout shift) */
    .sidebar {
        display: none !important;
        position: fixed;
        top: 0;
        left: 0;
        bottom: 0;
        width: 280px;
        height: 100vh;
        z-index: 1000;
        box-shadow: var(--shadow-lg);
        background-color: var(--primary-dark);
        flex-direction: column;
        justify-content: space-between;
        padding: 2rem 1.5rem;
    }
    
    .sidebar.open {
        display: flex !important;
        animation: sidebarSlideIn 0.3s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    }

    @keyframes sidebarSlideIn {
        from { transform: translateX(-100%); }
        to { transform: translateX(0); }
    }
    
    /* 2. Top Navbar - Left align hamburger and title with wrap protection */
    .top-navbar {
        height: auto;
        padding: 0.75rem 1rem;
        flex-direction: row;
        flex-wrap: wrap; /* Let elements wrap on narrow viewport sizes */
        gap: 0.75rem;
        align-items: center;
        justify-content: space-between;
    }
    
    .navbar-title h1 {
        font-size: 1.15rem;
        margin: 0;
        line-height: 1.2;
    }
    
    .navbar-actions {
        width: auto;
        display: flex;
        align-items: center;
        flex-wrap: wrap; /* Wrap badge and switch buttons if needed */
        gap: 0.5rem;
    }
    
    /* 3. Content Body Padding */
    .content-body {
        padding: 1rem;
    }
    
    /* 4. Stats Grid */
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
        margin-bottom: 1.25rem;
    }
    
    .stat-card {
        padding: 1rem;
        gap: 0.5rem;
    }
    
    .stat-value {
        font-size: 1.5rem;
    }
    
    .stat-icon {
        width: 38px;
        height: 38px;
    }
    
    /* 5. Theme Strips */
    .theme-strip {
        flex-direction: column;
        align-items: stretch;
        text-align: center;
        gap: 0.75rem;
        padding: 1rem;
    }
    
    .theme-strip-img {
        width: 100%;
        height: 120px;
    }
    
    .theme-strip-meta {
        justify-content: center;
        flex-wrap: wrap;
        gap: 0.5rem;
    }
    
    .palette-swatches {
        justify-content: center;
    }
    
    /* 6. Form grids & tables */
    form div[style*="grid-template-columns"] {
        grid-template-columns: 1fr !important;
        gap: 0.75rem !important;
    }
    
    /* 7. Compliancy Chart container */
    .chart-container {
        height: 150px;
    }
    
    /* 8. Login responsive layout */
    .login-wrapper {
        flex-direction: column;
    }
    
    .login-left {
        flex: none;
        padding: 2.5rem 1.5rem;
        text-align: center;
    }
    
    .login-brand {
        justify-content: center;
        margin-bottom: 1.5rem;
    }
    
    .login-left-content {
        max-width: 100%;
    }
    
    .login-left-content h2 {
        font-size: 1.75rem;
        margin-bottom: 0.5rem;
    }
    
    .login-left-content p {
        font-size: 0.9rem;
    }
    
    .login-right {
        padding: 2.5rem 1.5rem;
    }
    
    /* 9. Calendar responsive schedule view */
    .calendar-grid-header, .calendar-grid {
        grid-template-columns: repeat(7, 1fr) !important;
    }
    
    .calendar-day-header {
        font-size: 0.65rem;
        padding: 4px;
        text-overflow: ellipsis;
        overflow: hidden;
        white-space: nowrap;
    }
    
    .calendar-day {
        min-height: 50px !important;
        padding: 4px !important;
    }
    
    .day-num {
        font-size: 0.75rem;
    }
    
    .calendar-theme-badge {
        font-size: 0.55rem !important;
        padding: 1px 2px !important;
        margin-top: 2px;
        line-height: 1.1;
    }
    
    /* 10. Modals */
    div[id*="Modal"] > div.card, div[id*="modal"] > div.card {
        width: 95% !important;
        margin: 1rem auto !important;
    }

    /* 11. Table Cell Padding and Alerts Optimization for Mobile */
    .custom-table th {
        padding: 0.6rem 0.85rem !important;
        font-size: 0.7rem !important;
    }
    
    .custom-table td {
        padding: 0.85rem 0.85rem !important;
        font-size: 0.8rem !important;
    }
    
    .alert {
        padding: 0.75rem 1rem !important;
        font-size: 0.8rem !important;
        align-items: flex-start !important;
    }
    
    .alert svg {
        flex-shrink: 0;
        margin-top: 2px;
    }
    
    /* Elegant thin horizontal scrollbar for scrollable grids */
    .chart-container::-webkit-scrollbar, .table-responsive::-webkit-scrollbar {
        height: 5px;
    }
    
    .chart-container::-webkit-scrollbar-thumb, .table-responsive::-webkit-scrollbar-thumb {
        background-color: rgba(15, 76, 129, 0.2);
        border-radius: 10px;
    }
}

@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .top-navbar {
        padding: 0.75rem 1rem !important;
    }
    
    .navbar-title h1 {
        font-size: 1.1rem !important;
    }
    
    .badge-store {
        padding: 0.3rem 0.75rem !important;
        font-size: 0.75rem !important;
    }
}
