/* ==========================================================================
   SOLARHUB BY MDS DIGITAL SYSTEMS - NEXT-GEN DESIGN SYSTEM
   Paleta: Deep Slate Navy (#080C14, #0F172A), Solar Amber (#F59E0B, #FBBF24),
   Aurora Cyan (#06B6D4), Energy Emerald (#10B981).
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&family=Space+Grotesk:wght@500;600;700&display=swap');

:root {
    --solar-bg: #080c14;
    --solar-surface: #0f172a;
    --solar-surface-card: #131c31;
    --solar-surface-hover: #1e293b;
    --solar-border: rgba(255, 255, 255, 0.08);
    --solar-border-glow: rgba(245, 158, 11, 0.25);
    
    --solar-amber: #f59e0b;
    --solar-amber-light: #fbbf24;
    --solar-amber-dark: #d97706;
    --solar-cyan: #06b6d4;
    --solar-emerald: #10b981;
    --solar-rose: #f43f5e;
    
    --solar-text-main: #f8fafc;
    --solar-text-muted: #94a3b8;
    --solar-text-subtle: #64748b;
    
    --font-main: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-heading: 'Space Grotesk', var(--font-main);
}

/* Global resets & background */
body {
    font-family: var(--font-main);
    background-color: var(--solar-bg);
    color: var(--solar-text-main);
    margin: 0;
    padding: 0;
    -webkit-font-smoothing: antialiased;
    background-image: 
        radial-gradient(circle at 10% 15%, rgba(245, 158, 11, 0.06) 0%, transparent 45%),
        radial-gradient(circle at 90% 80%, rgba(6, 182, 212, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 50% 50%, rgba(15, 23, 42, 0.5) 0%, transparent 100%);
    background-attachment: fixed;
    min-height: 100vh;
}

h1, h2, h3, h4, h5, h6, .brand-font {
    font-family: var(--font-heading);
    letter-spacing: -0.02em;
    font-weight: 700;
}

/* Glass Cards */
.solar-card {
    background: rgba(19, 28, 49, 0.75);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--solar-border);
    border-radius: 1rem;
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.solar-card:hover {
    border-color: rgba(245, 158, 11, 0.35);
    box-shadow: 0 15px 35px -10px rgba(0, 0, 0, 0.7), 0 0 25px rgba(245, 158, 11, 0.12);
    transform: translateY(-3px);
}

.solar-card-glow {
    position: relative;
    overflow: hidden;
}

.solar-card-glow::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--solar-amber), var(--solar-cyan));
}

/* Navbar */
.solar-navbar {
    background: rgba(8, 12, 20, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--solar-border);
    padding: 0.85rem 0;
    position: sticky;
    top: 0;
    z-index: 1050;
    transition: all 0.3s ease;
}

.solar-brand {
    font-family: var(--font-heading);
    font-size: 1.45rem;
    font-weight: 800;
    background: linear-gradient(135deg, #ffffff 30%, var(--solar-amber-light) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
}

.solar-brand i {
    -webkit-text-fill-color: var(--solar-amber);
    filter: drop-shadow(0 0 8px rgba(245, 158, 11, 0.6));
}

.nav-link-solar {
    color: var(--solar-text-muted) !important;
    font-weight: 500;
    font-size: 0.95rem;
    padding: 0.5rem 0.9rem !important;
    border-radius: 0.5rem;
    transition: all 0.2s ease;
}

.nav-link-solar:hover {
    color: #ffffff !important;
    background: rgba(255, 255, 255, 0.05);
}

.nav-link-solar.active {
    color: var(--solar-amber) !important;
    background: rgba(245, 158, 11, 0.1);
}

/* Buttons */
.btn-solar-primary {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: #080c14 !important;
    font-weight: 700;
    font-size: 0.95rem;
    border: none;
    padding: 0.65rem 1.4rem;
    border-radius: 0.65rem;
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.35);
    transition: all 0.25s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
}

.btn-solar-primary:hover {
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
    box-shadow: 0 6px 22px rgba(245, 158, 11, 0.55);
    transform: translateY(-2px);
    color: #080c14 !important;
}

.btn-solar-outline {
    background: rgba(255, 255, 255, 0.03);
    color: var(--solar-text-main) !important;
    border: 1px solid var(--solar-border);
    font-weight: 600;
    font-size: 0.95rem;
    padding: 0.65rem 1.4rem;
    border-radius: 0.65rem;
    transition: all 0.25s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
}

.btn-solar-outline:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.25);
    color: #ffffff !important;
    transform: translateY(-2px);
}

.btn-solar-cyan {
    background: linear-gradient(135deg, #06b6d4 0%, #0891b2 100%);
    color: #ffffff !important;
    font-weight: 700;
    border: none;
    box-shadow: 0 4px 15px rgba(6, 182, 212, 0.35);
}

/* Badges */
.badge-solar-amber {
    background: rgba(245, 158, 11, 0.15);
    color: #fbbf24;
    border: 1px solid rgba(245, 158, 11, 0.3);
    padding: 0.4rem 0.85rem;
    border-radius: 9999px;
    font-weight: 600;
    font-size: 0.78rem;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.badge-solar-cyan {
    background: rgba(6, 182, 212, 0.15);
    color: #67e8f9;
    border: 1px solid rgba(6, 182, 212, 0.3);
    padding: 0.4rem 0.85rem;
    border-radius: 9999px;
    font-weight: 600;
    font-size: 0.78rem;
}

.badge-solar-emerald {
    background: rgba(16, 185, 129, 0.15);
    color: #6ee7b7;
    border: 1px solid rgba(16, 185, 129, 0.3);
    padding: 0.4rem 0.85rem;
    border-radius: 9999px;
    font-weight: 600;
    font-size: 0.78rem;
}

/* Metrics & Stats Card */
.kpi-metric-val {
    font-family: var(--font-heading);
    font-size: 2.2rem;
    font-weight: 800;
    color: #ffffff;
    line-height: 1.1;
}

.kpi-metric-label {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--solar-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.kpi-icon-wrap {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
}

.kpi-amber {
    background: rgba(245, 158, 11, 0.15);
    color: var(--solar-amber);
    box-shadow: 0 0 15px rgba(245, 158, 11, 0.2);
}

.kpi-cyan {
    background: rgba(6, 182, 212, 0.15);
    color: var(--solar-cyan);
    box-shadow: 0 0 15px rgba(6, 182, 212, 0.2);
}

.kpi-emerald {
    background: rgba(16, 185, 129, 0.15);
    color: var(--solar-emerald);
    box-shadow: 0 0 15px rgba(16, 185, 129, 0.2);
}

/* Tables */
.table-solar {
    --bs-table-bg: transparent;
    color: var(--solar-text-main);
    border-collapse: separate;
    border-spacing: 0 0.5rem;
}

.table-solar thead th {
    background: rgba(15, 23, 42, 0.8);
    color: var(--solar-text-muted);
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 600;
    border: none;
    padding: 0.9rem 1.1rem;
}

.table-solar tbody tr {
    background: rgba(19, 28, 49, 0.6);
    border-radius: 0.75rem;
    transition: all 0.2s ease;
}

.table-solar tbody tr td {
    border: none;
    padding: 1.1rem;
    vertical-align: middle;
}

.table-solar tbody tr td:first-child {
    border-top-left-radius: 0.75rem;
    border-bottom-left-radius: 0.75rem;
}

.table-solar tbody tr td:last-child {
    border-top-right-radius: 0.75rem;
    border-bottom-right-radius: 0.75rem;
}

.table-solar tbody tr:hover {
    background: rgba(30, 41, 59, 0.85);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

/* Sidebar for CRM */
.solar-sidebar {
    width: 260px;
    height: 100vh;
    position: fixed;
    top: 0;
    left: 0;
    background: rgba(11, 16, 30, 0.95);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border-right: 1px solid var(--solar-border);
    z-index: 1040;
    display: flex;
    flex-direction: column;
    padding: 1.5rem 1rem;
    overflow-y: auto;
}

.solar-sidebar-header {
    padding: 0 0.75rem 1.5rem 0.75rem;
    border-bottom: 1px solid var(--solar-border);
    margin-bottom: 1.25rem;
}

.solar-nav-section-title {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--solar-text-subtle);
    font-weight: 700;
    padding: 0.75rem 0.75rem 0.35rem 0.75rem;
}

.solar-sidebar-link {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    padding: 0.7rem 0.85rem;
    color: var(--solar-text-muted) !important;
    text-decoration: none !important;
    border-radius: 0.65rem;
    font-weight: 500;
    font-size: 0.92rem;
    transition: all 0.2s ease;
    margin-bottom: 0.25rem;
}

.solar-sidebar-link:hover {
    color: #ffffff !important;
    background: rgba(255, 255, 255, 0.06);
    transform: translateX(3px);
}

.solar-sidebar-link.active {
    color: #ffffff !important;
    background: linear-gradient(90deg, rgba(245, 158, 11, 0.2) 0%, rgba(245, 158, 11, 0.05) 100%);
    border-left: 3px solid var(--solar-amber);
    font-weight: 600;
}

.solar-sidebar-link i {
    font-size: 1.15rem;
    width: 22px;
    text-align: center;
}

.solar-sidebar-link.active i {
    color: var(--solar-amber);
}

.solar-crm-content {
    margin-left: 260px;
    padding: 2rem;
    min-height: 100vh;
}

@media (max-width: 991px) {
    .solar-sidebar {
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }
    .solar-sidebar.show {
        transform: translateX(0);
    }
    .solar-crm-content {
        margin-left: 0;
        padding: 1rem;
    }
}

/* Hero Section Gradients */
.solar-hero-glow {
    position: relative;
    padding: 5rem 0 4rem 0;
}

.solar-hero-glow::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 600px;
    height: 400px;
    background: radial-gradient(circle, rgba(245, 158, 11, 0.12) 0%, rgba(6, 182, 212, 0.05) 50%, transparent 70%);
    filter: blur(60px);
    z-index: -1;
    pointer-events: none;
}
