/* ============================================================
   Partner Console — Time Core design tokens (single source). v1.2 — glassmorphism portal-wide.
   Mirrors the TimeTracker "Time Core" design system so the
   Partner Portal matches the main web app. Change colours here
   ONCE and every page (login, onboarding, dashboard, admin)
   updates. Linked LAST in each page's <head> so it wins over
   any page-local <style>.
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
    /* Type — Time Core uses Inter (400/500/600/700/800) */
    --font-sans: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;

    /* Make Bootstrap components (buttons, tables, .text-muted, alerts) adopt Inter too */
    --bs-body-font-family: var(--font-sans);
    --bs-body-color: #4B5563;

    /* Brand */
    --brand-blue:        #084E80;   /* rollback to old blue: #03519B */
    --brand-blue-dark:   #063E66;   /* rollback to old dark blue: #023E76 */
    --brand-orange:      #F66E0A;
    --brand-orange-dark: #D65F08;

    /* Sidebar logo height — single knob to resize the nav logo everywhere */
    --nav-logo-h: 46px;

    /* Neutrals & surfaces */
    --bg:         #F3F5F4;
    --surface:    #FFFFFF;
    --border:     #E5E7EB;
    --text-body:  #4B5563;
    --text-muted: #6B7280;

    /* Opacity tints (flattened over white) */
    --blue-5:   #F2F6FA;
    --blue-10:  #E6EEF5;
    --blue-20:  #CDDCEB;
    --orange-10:#FEF1E8;
    --orange-20:#FCE3D2;

    /* Radius scale */
    --radius-md: 6px;   /* buttons    */
    --radius-lg: 8px;   /* icon chips */
    --radius-xl: 12px;  /* cards      */
}

/* Base — Inter everywhere, with the smoothing/feature settings Time Core uses */
body, .btn, .form-control, .form-select, .form-label, table, .badge, .alert, .dropdown-menu {
    font-family: var(--font-sans);
}
body {
    /* Soft brand gradient so frosted-glass surfaces read across the whole portal */
    background: linear-gradient(135deg, #E7F0FA 0%, #F3F5F4 45%, #FDEEE2 100%);
    background-attachment: fixed;
    min-height: 100vh;
    color: var(--text-body);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    font-feature-settings: 'cv11', 'ss01';   /* Inter's nicer single-storey a / curved details */
    text-rendering: optimizeLegibility;
}

/* Reusable frosted surface (use on any card/panel) */
.glass {
    background: rgba(255, 255, 255, .66);
    -webkit-backdrop-filter: blur(14px) saturate(125%);
    backdrop-filter: blur(14px) saturate(125%);
    border: 1px solid rgba(255, 255, 255, .65);
    border-radius: var(--radius-xl);
    box-shadow: 0 8px 30px rgba(8, 78, 128, .10);
}

/* Type scale — headings are Inter, bold, with tight tracking (Time Core standard) */
h1, h2, h3, h4, .h1, .h2, .h3 {
    color: var(--brand-blue);
    font-weight: 700;
    letter-spacing: -0.01em;
    line-height: 1.25;
}
h1, .h1 { font-weight: 800; letter-spacing: -0.02em; }   /* hero / page title */

/* Brand wordmark */
.brand { color: var(--brand-blue) !important; font-weight: 800; letter-spacing: -0.01em; }
.brand span { color: var(--brand-orange) !important; }
/* Sidebar logo image — height driven by --nav-logo-h, never overflows the sidebar */
.brand-logo { height: var(--nav-logo-h, 46px); width: auto; max-width: 100%; display: block; margin: 4px auto 12px; }

/* All buttons: Inter, medium-weight label with subtle tracking */
.btn { font-weight: 600; letter-spacing: .01em; }

/* Primary call-to-action — orange (Time Core "Primary Button") */
.btn-navy, .btn-cta {
    background: var(--brand-orange);
    border: none;
    color: #fff;
    font-weight: 700;
    border-radius: var(--radius-md);
    box-shadow: 0 1px 2px rgba(0, 0, 0, .08);
    transition: background .15s ease, transform .15s ease, box-shadow .15s ease;
}
.btn-navy:hover, .btn-navy:focus,
.btn-cta:hover, .btn-cta:focus {
    background: var(--brand-orange-dark);
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(214, 95, 8, .25);
}

/* Secondary — outlined blue (Time Core "Secondary Button") */
.btn-outline-brand {
    border: 2px solid var(--brand-blue);
    color: var(--brand-blue);
    background: #fff;
    font-weight: 700;
    border-radius: var(--radius-md);
}
.btn-outline-brand:hover { background: var(--blue-5); color: var(--brand-blue); }

/* Dashboard / admin top bar */
.topbar { background: var(--brand-blue) !important; color: #fff; }
.topbar .brand { color: #fff !important; }          /* wordmark stays white on blue */
.topbar .brand span { color: var(--brand-orange) !important; }  /* "VA" keeps orange */

/* Shared card shells become frosted glass everywhere (login, onboarding, dashboard, account) */
.card-d, .card-pf, .card-c, .card-pw, .stat {
    border-radius: var(--radius-xl);
    background: rgba(255, 255, 255, .66);
    -webkit-backdrop-filter: blur(14px) saturate(125%);
    backdrop-filter: blur(14px) saturate(125%);
    border: 1px solid rgba(255, 255, 255, .65);
    box-shadow: 0 8px 30px rgba(8, 78, 128, .10);
}

/* Links */
a { color: var(--brand-blue); }
a:hover { color: var(--brand-blue-dark); }

/* Inputs — blue focus ring */
.form-control:focus, .form-select:focus {
    border-color: var(--blue-20);
    box-shadow: 0 0 0 .2rem rgba(8, 78, 128, .15);
}

/* Uppercase field labels keep the muted tone */
label.form-label { color: var(--text-muted); }
