/* BIM DIVE - Design System & Custom Utilities */

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

/* CSS Variables for design system tokens */
:root {
    --navy-blue: #1E2D4A;
    --gold-accent: #C48B3B;
    --gold-accent-hover: #a6732e;
    --off-white: #F8FAFC;
    --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

body {
    font-family: 'Outfit', sans-serif;
    color: var(--navy-blue);
    background-color: #ffffff;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6, .brand-font {
    font-family: 'Montserrat', sans-serif;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}
::-webkit-scrollbar-track {
    background: #f1f5f9;
}
::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* Hide scrollbar utility */
.no-scrollbar::-webkit-scrollbar {
    display: none;
}
.no-scrollbar {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

/* Micro-animations and Transitions */
.hover-lift {
    transition: var(--transition-smooth);
}
.hover-lift:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 20px -8px rgba(30, 45, 74, 0.15);
}

.gold-glow {
    transition: var(--transition-smooth);
}
.gold-glow:hover {
    box-shadow: 0 0 15px rgba(196, 139, 59, 0.4);
    border-color: var(--gold-accent);
}

/* Smooth page load animation */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in {
    animation: fadeIn 0.4s ease-out forwards;
}

/* Active Navigation Line Hover Effect */
.nav-link {
    position: relative;
    transition: color 0.2s ease;
}
.nav-link::after {
    content: '';
    position: absolute;
    width: 100%;
    transform: scaleX(0);
    height: 2px;
    bottom: -4px;
    left: 0;
    background-color: var(--gold-accent);
    transform-origin: bottom right;
    transition: transform 0.25s ease-out;
}
.nav-link:hover::after {
    transform: scaleX(1);
    transform-origin: bottom left;
}

/* Dynamic glassmorphism panel */
.glass-panel {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.dark-glass-panel {
    background: rgba(30, 45, 74, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* ==========================================
   DARK MODE CUSTOM STYLES
   ========================================== */
.dark {
    background-color: #0f172a !important;
}

.dark body {
    background-color: #0f172a !important;
    color: #f8fafc !important;
}

.dark header, .dark footer {
    background-color: #1e293b !important;
    border-color: #334155 !important;
}

.dark nav a, .dark header button {
    color: #f1f5f9 !important;
}

.dark header svg text {
    fill: #ffffff !important;
}

.dark header svg tspan {
    fill: #C48B3B !important;
}

.dark .bg-white {
    background-color: #1e293b !important;
    color: #f1f5f9 !important;
}

.dark .bg-slate-50 {
    background-color: #1e293b !important;
}

.dark .bg-slate-100 {
    background-color: #1e293b !important;
}

.dark .bg-slate-200 {
    background-color: #334155 !important;
}

.dark [class*="text-[#1E2D4A]"] {
    color: #f8fafc !important;
}

.dark h1, .dark h2, .dark h3, .dark h4, .dark h5, .dark h6 {
    color: #f8fafc !important;
}

.dark .text-slate-900, .dark .text-slate-800, .dark .text-slate-700 {
    color: #f1f5f9 !important;
}

.dark .border-slate-100, .dark .border-slate-200, .dark .border-slate-300 {
    border-color: #334155 !important;
}

.dark .text-slate-500 {
    color: #94a3b8 !important;
}

.dark .text-slate-600 {
    color: #cbd5e1 !important;
}

.dark input, .dark textarea, .dark select {
    background-color: #1e293b !important;
    border-color: #334155 !important;
    color: #f1f5f9 !important;
}

.dark input::placeholder, .dark textarea::placeholder {
    color: #64748b !important;
}

.dark .reply-item, .dark .comment-container > div {
    background-color: rgba(30, 41, 59, 0.4) !important;
    border-color: #334155 !important;
}

.dark .glass-panel {
    background: rgba(30, 45, 74, 0.7) !important;
    border: 1px solid rgba(255, 255, 255, 0.05) !important;
}

.dark .focus-within\:bg-white:focus-within {
    background-color: #0f172a !important;
}

/* Dark Mode Autofill Fix */
.dark input:-webkit-autofill,
.dark input:-webkit-autofill:hover, 
.dark input:-webkit-autofill:focus, 
.dark input:-webkit-autofill:active {
    -webkit-box-shadow: 0 0 0 30px #1e293b inset !important;
    -webkit-text-fill-color: #f8fafc !important;
    caret-color: #f8fafc !important;
}

.dark button[class*="bg-[#1E2D4A]"] {
    background-color: var(--gold-accent) !important;
    color: white !important;
}
.dark button[class*="bg-[#1E2D4A]"]:hover {
    background-color: var(--gold-accent-hover) !important;
}

/* ==========================================
   DARK MODE FOR MULTI-SELECT INPUTS
   ========================================== */
.dark .ms-selected-tags {
    background-color: #1e293b !important;
    border-color: #334155 !important;
}

.dark .ms-container:focus-within .ms-selected-tags {
    background-color: #1e293b !important;
    border-color: var(--gold-accent) !important;
    box-shadow: 0 0 0 1px rgba(196, 139, 59, 0.2) !important;
}

.dark .ms-tag {
    background-color: var(--gold-accent) !important;
    color: white !important;
    border: 1px solid rgba(255,255,255,0.05) !important;
}

.dark .ms-tag.locked {
    background-color: #64748b !important;
}

.dark .ms-dropdown {
    background-color: #1e293b !important;
    border-color: #334155 !important;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.3), 0 4px 6px -2px rgba(0, 0, 0, 0.2) !important;
}

.dark .ms-dropdown-item {
    border-bottom: 1px solid #334155 !important;
    color: #f1f5f9 !important;
}

.dark .ms-dropdown-item:hover {
    background-color: #334155 !important;
    color: var(--gold-accent) !important;
}

.dark .ms-search-input {
    color: #f8fafc !important;
}

.dark .ms-search-input::placeholder {
    color: #64748b !important;
}

/* ==========================================
   DARK MODE HOVER STATE ADJUSTMENTS
   ========================================== */
.dark [class*="hover:bg-slate-50"]:hover {
    background-color: rgba(51, 65, 85, 0.3) !important;
}

.dark [class*="hover:bg-slate-100"]:hover {
    background-color: rgba(51, 65, 85, 0.4) !important;
}

.dark [class*="hover:bg-white"]:hover {
    background-color: rgba(51, 65, 85, 0.3) !important;
}

.dark [class*="hover:bg-slate-50/50"]:hover {
    background-color: rgba(51, 65, 85, 0.2) !important;
}

.dark #table-of-contents a {
    color: #94a3b8 !important;
}
.dark #table-of-contents a:hover {
    color: var(--gold-accent) !important;
}

.dark .category-badge {
    background-color: rgba(15, 23, 42, 0.8) !important;
    color: #f8fafc !important;
    border: 1px solid rgba(255, 255, 255, 0.05) !important;
}

.dark select option {
    background-color: #1e293b !important;
    color: #f1f5f9 !important;
}

/* Global aspect-ratio override for compact Join Banner */
#vectorBannerContainer {
    aspect-ratio: 900 / 230 !important;
}

/* Responsive Header Logo text fill */
.header-logo-svg .logo-text-main {
    fill: #1E2D4A;
    transition: fill 0.2s ease;
}
.header-logo-svg .logo-tspan-accent,
.header-logo-svg .logo-poly-accent {
    fill: #C48B3B;
}

/* Dark Theme Logo override */
.dark .header-logo-svg .logo-text-main {
    fill: #ffffff !important;
}
