@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
    --active-blue: #0d9488;
    --bg-light: #f4f6f8;
    --card-bg: #ffffff;
    --text-main: #111827;
    --text-muted: #6b7280;
    --border-color: #e5e7eb;
}

/* 1. RESET */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* 2. UNIVERSAL LAYOUT (NO MORE FLEX SIDEBARS) */
html,
body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-light);
    color: var(--text-main);
    display: block !important;
    min-height: 100vh;
    overflow-x: hidden;
}

/* 3. MAIN CONTENT WRAPPER */
.main-content {
    display: block !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* 4. UNIVERSAL TOP HEADER */
.modern-header {
    background: #ffffff;
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 1000;
    width: 100%;
    height: 80px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.02);
}

.header-container {
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 40px;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* Header Branding */

.brand-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: var(--text-main);
    transition: opacity .2s;
}

.brand-logo:hover {
    opacity: .8;
}

/* NEW - SVG Logo */

.brand-logo-img {
    height: 32px;
    width: auto;
    display: block;
    object-fit: contain;
    flex-shrink: 0;
}

/* Keep this even if you're not using it right now */

.brand-text {
    font-weight: 800;
    font-size: 1.25rem;
    letter-spacing: -0.02em;
    display: flex;
    align-items: center;
    gap: 12px;
}

.brand-role {
    font-size: 0.65rem;
    font-weight: 700;
    background: #f3f4f6;
    color: #4b5563;
    padding: 4px 10px;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-top: 2px;
}

/* Header Navigation */

.header-right-wrapper {
    display: flex;
    align-items: center;
    gap: 32px;
}

.header-nav {
    display: flex;
    align-items: center;
    gap: 36px;
}

.nav-link {
    color: #6b7280;
    text-decoration: none;
    font-size: .95rem;
    font-weight: 500;
    transition: all .2s ease;
    display: flex;
    align-items: center;
    gap: 6px;
    position: relative;
    padding: 8px 0;
}

.nav-link:hover {
    color: var(--text-main);
}

.nav-link.active {
    color: var(--text-main);
    font-weight: 600;
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--text-main);
    border-radius: 2px;
}

.form-link {
    color: #ffffff !important;
    background: var(--text-main);
    padding: 8px 20px;
    border-radius: 8px;
    font-weight: 600;
    border: 1px solid var(--text-main);
    transition: .2s;
}

.form-link.active::after {
    display: none;
}

.form-link:hover {
    background: #374151;
    transform: translateY(-1px);
}

/* Header Profile */

.header-divider {
    width: 1px;
    height: 32px;
    background: var(--border-color);
}

.profile-menu {
    display: flex;
    align-items: center;
    gap: 20px;
}

.avatar {
    width: 40px;
    height: 40px;
    background: #f9fafb;
    color: var(--text-main);
    border: 1px solid var(--border-color);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-weight: 700;
    font-size: .95rem;
}

.logout-link {
    color: #6b7280;
    text-decoration: none;
    font-weight: 500;
}

.logout-link:hover {
    color: #ef4444;
}

/* 5. GLOBAL PAGE COMPONENTS */

.dashboard-container {
    padding: 40px 32px;
    max-width: 1440px;
    margin: 0 auto;
    width: 100%;
}

.grid-row-4 {
    display: grid;
    grid-template-columns: repeat(4,1fr);
    gap: 24px;
    margin-bottom: 30px;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 24px;
}

.card,
.stat-card,
.chart-container {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 1px 3px rgba(0,0,0,.05);
}

@media(max-width:1024px){

    .header-nav,
    .header-right-wrapper{
        gap:20px;
    }

    .header-container{
        padding:0 24px;
    }

    .grid-row-4{
        grid-template-columns:repeat(2,1fr);
    }

    .dashboard-grid{
        grid-template-columns:1fr;
    }

}
