﻿:root {
    /* Core Palette */
    --navy: #1a237e;
    --gold: #d4af37; /* Legal Gold */
    --gold-hover: #b8962e;
    --black: #121212;
    --grey-dark: #2c2c2c; /* Slightly lighter for better text contrast */
    --grey-light: #f8f9fa;
    --white: #ffffff;
    /* Functional Colors */
    --sidebar-width: 280px;
}

/* --- Global Improvements --- */
body {
    font-family: 'Montserrat', sans-serif;
    color: var(--black);
    background-color: var(--white);
    line-height: 1.6;
}

.font-playfair {
    font-family: 'Playfair Display', serif;
}

/* --- Visibility Helpers --- */
.bg-navy {
    background-color: var(--navy) !important;
}

.text-gold {
    color: var(--gold) !important;
}

.text-navy {
    color: var(--navy) !important;
}

/* Glassmorphism for boxes on dark backgrounds */
.bg-white-glass {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* --- Optimized Buttons --- */
.btn-gold {
    background-color: var(--gold);
    color: var(--white);
    font-weight: 700;
    border: none;
    transition: transform 0.2s, background-color 0.2s;
}

    .btn-gold:hover {
        background-color: var(--gold-hover);
        color: var(--white);
        transform: translateY(-2px);
    }

.btn-outline-gold {
    border: 2px solid var(--gold);
    color: var(--gold);
    font-weight: 600;
}

    .btn-outline-gold:hover {
        background-color: var(--gold);
        color: var(--white);
    }

.btn-navy {
    background-color: var(--navy);
    color: var(--white);
    border: none;
    font-weight: 700;
}

    .btn-navy:hover {
        background-color: #11195d;
        color: var(--white);
    }

.border-navy {
    border-color: var(--navy) !important;
}

.bg-navy-subtle {
    background-color: rgba(26, 35, 126, 0.08) !important;
}

/* --- Sidebar (Harmonized) --- */
.sidebar {
    width: var(--sidebar-width);
    background-color: var(--navy);
    color: var(--white);
    box-shadow: 4px 0 15px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    z-index: 1000;
}

/* Ensure the main area takes up the rest of the screen */
.flex-grow-1 {
    flex-grow: 1;
    min-width: 0; /* Important for preventing content overflow */
}

/* Scrollable content area */
main {
    height: 100vh;
    overflow-y: auto;
}

/* Responsive: on mobile, stack them, on desktop, side-by-side */
@media (max-width: 768px) {
    .d-flex {
        flex-direction: column;
    }

    .sidebar {
        width: 100% !important;
        height: auto !important;
        position: relative !important;
    }
}

/* Auth Specific Layout */
.auth-container {
    min-height: 100vh;
    background: linear-gradient(135deg, var(--navy) 0%, var(--black) 100%);
    padding: 2rem;
}

.auth-card {
    width: 100%;
    max-width: 450px;
    border: none;
}

.auth-toggle {
    background: rgba(255, 255, 255, 0.1);
    padding: 5px;
    border-radius: 50px;
}

    .auth-toggle .btn {
        border-radius: 50px !important;
        padding: 8px 25px;
        font-size: 0.9rem;
        font-weight: 600;
    }

/* Sub-toggle styling for Org/Individual */
.btn-outline-navy {
    border: 1px solid var(--navy);
    color: var(--navy);
    background: transparent;
}

    .btn-outline-navy:hover {
        background: rgba(26, 35, 126, 0.05);
        color: var(--navy);
    }

/* Ensure form controls look consistent */
.form-control {
    border: 1px solid #dee2e6;
    font-size: 0.95rem;
}

    .form-control:focus {
        border-color: var(--navy);
        box-shadow: 0 0 0 0.2rem rgba(26, 35, 126, 0.1);
    }

/* Sidebar Structural Overhaul */
.sidebar {
    width: var(--sidebar-width);
    background-color: var(--navy);
    min-height: 100vh;
    border-right: 1px solid rgba(255, 255, 255, 0.05);
}

.logo-circle {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    background-color: var(--gold);
}

.nav-section-label {
    font-size: 0.7rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.4);
    padding: 1.5rem 1.5rem 0.5rem 1.5rem;
    letter-spacing: 1.2px;
}

.nav-link-custom {
    display: flex;
    align-items: center;
    padding: 0.85rem 1.5rem;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: all 0.2s ease;
    border-left: 4px solid transparent;
}

    .nav-link-custom i {
        font-size: 1.1rem;
        margin-right: 12px;
        width: 20px;
        text-align: center;
    }

    .nav-link-custom:hover {
        color: var(--white);
        background: rgba(255, 255, 255, 0.05);
    }

    /* Blazor adds the 'active' class automatically */
    .nav-link-custom.active {
        color: var(--white);
        background: rgba(255, 255, 255, 0.08);
        border-left: 4px solid var(--gold);
    }

/* Main Content Area Styling */
main {
    background-color: var(--grey-light);
    overflow-y: auto;
}

.dashboard-header {
    background: white;
    padding: 1.5rem 2rem;
    border-bottom: 1px solid #e2e8f0;
}

/* Legal Input Styling */
.form-control {
    padding: 0.75rem;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

    .form-control:focus {
        border-color: var(--gold);
        box-shadow: 0 0 0 0.25rem rgba(212, 175, 55, 0.25);
    }

.border-navy-subtle {
    border-color: rgba(26, 35, 126, 0.2);
}

/* Subtle red background for overdue rows */
.table-danger-light {
    background-color: rgba(220, 53, 69, 0.05) !important;
}

/* Optional: strike-through for archived event dates */
.text-archived {
    text-decoration: line-through;
    opacity: 0.6;
}

/* Judges, Partners, Associates*/
.avatar-sm {
    flex-shrink: 0;
    border: 1px solid rgba(0,0,0,0.05);
}

.text-gold {
    color: #C5A059 !important;
}

.bg-navy {
    background-color: #001f3f !important;
}

.bg-gold {
    background-color: #C5A059 !important;
}

/* Custom 7-column grid for calendars */
.col-7-custom {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
}

.calendar-day {
    min-height: 120px;
    border-right: 1px solid #dee2e6;
    border-bottom: 1px solid #dee2e6;
    background-color: #fff;
    transition: background-color 0.2s;
}

    .calendar-day:hover {
        background-color: #f8f9fa;
    }

.bg-light-grey {
    background-color: #fcfcfc;
}

.today-highlight {
    background-color: #fffdf0 !important;
    border: 2px solid #ffc107 !important;
    z-index: 1;
}

.day-number {
    font-size: 0.85rem;
    padding: 2px 6px;
}

.event-container {
    padding: 2px;
    max-height: 85px;
    overflow-y: auto;
}

.event-pill {
    font-size: 0.7rem;
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.bg-gold {
    background-color: #FFD700;
}

.cursor-pointer {
    cursor: pointer;
}

.letter-spacing-1 {
    letter-spacing: 1px;
}

.xsmall {
    font-size: 0.75rem;
}

/*Sharepoint*/
.hover-bg-light:hover {
    background-color: rgba(0, 31, 63, 0.04); /* Navy tint */
}

.text-navy {
    color: #001f3f;
}

.text-gold {
    color: #d4af37;
}

.x-small {
    font-size: 0.7rem;
}

.font-monospace {
    font-family: 'Courier New', Courier, monospace;
}
