/* ==========================================================================
   General Body & Typography
   ========================================================================== */

body {
    background-color: #0a192f; /* Dark Navy Blue */
    color: #cbd5e0; /* Light Gray-Blue for text */
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    padding-top: 110px; /* Space for the overlapping navbar */
}

/* Remove top padding for pages without the main navbar, like login */
body.login-page {
    padding-top: 0;
}

a {
    color: #f97316; /* Orange */
    text-decoration: none;
}

a:hover {
    color: #fb923c; /* Lighter Orange */
}

h1, h2, h3, h4, h5, h6 {
    color: #ffffff;
}

/* ==========================================================================
   Navigation Bar
   ========================================================================== */

.navbar {
    background-color: #1e293b; /* Slightly lighter Navy */
    padding: 0.75rem 2rem;
    border-bottom: 1px solid #334155;
    display: flex;
    align-items: center;
    width: 100%;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1000;
    height: 110px; /* Fixed height for the navbar itself */
}

/* The circular container for the logo */
.navbar .logo-link {
    position: absolute;
    top: 15px;
    left: 2rem;
    z-index: 1001;
    height: 120px;
    width: 120px;
    background-color: #ffffff;
    border-radius: 50%;
    border: 4px solid #ea580c;
    box-shadow: 0 5px 15px rgba(0,0,0,0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s ease;
}

.navbar .logo-link:hover {
    transform: scale(1.05);
}

/* The logo image inside the circle */
.navbar .navbar-logo {
    height: 80%;
    width: auto;
    position: static;
}

/* Container for user info and hamburger menu */
.navbar-links {
    display: flex;
    align-items: center;
    margin-left: auto; /* Pushes this container to the far right */
}

.user-info {
    display: flex;
    flex-direction: column;
    align-items: flex-end; /* Align text to the right */
    margin-right: 1.5rem;
    line-height: 1.3;
}

.user-name {
    font-weight: bold;
    font-size: 1rem;
    color: #ffffff;
}

.user-career-span {
    font-size: 0.75rem;
    color: #94a3b8;
    font-style: italic;
}

.user-stats {
    font-size: 0.8rem;
    color: #a0aec0;
}

/* Hamburger Menu */
.hamburger-menu {
    position: relative;
    display: inline-block;
}

.hamburger-icon {
    cursor: pointer;
    padding: 0.5rem;
}

.hamburger-icon .bar {
    display: block;
    width: 30px;
    height: 4px;
    margin: 6px auto;
    background-color: #ea580c;
    transition: 0.4s;
}

.dropdown-menu {
    display: none;
    position: absolute;
    right: 0;
    background-color: #2d3748;
    min-width: 160px;
    box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
    z-index: 1;
    border-radius: 0.375rem;
    border: 1px solid #4a5568;
}

.dropdown-menu a {
    color: #cbd5e0;
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    margin-left: 0; /* Override default link margin */
}

.dropdown-menu a:hover {
    background-color: #4a5568;
    color: #ffffff;
}

.show {
    display: block;
}

/* ==========================================================================
   Cards & Content Sections
   ========================================================================== */

.card {
    background-color: #1e293b;
    border: 1px solid #334155;
    border-radius: 0.5rem;
}

.list-group-item {
    background-color: #334155;
    border-color: #4a5568;
    color: #e2e8f0;
}

/* NEW: Custom hover state for actionable list items in our dark theme */
.list-group-item-action:hover,
.list-group-item-action:focus {
    background-color: #475569; /* Slightly lighter, but still dark, grey-blue */
    color: #ffffff; /* Make the main text pure white on hover for better contrast */
}

/* Rule to fix heading colors inside list items */
.list-group-item h5, .list-group-item h6 {
    color: #ffffff;
}

.filter-card {
    background-color: #1e293b;
    border: 1px solid #334155;
    padding: 1.5rem;
    border-radius: 0.5rem;
}

.fixture-card {
    background-color: #1e293b;
    border: 1px solid #334155;
    margin-bottom: 1.5rem;
    border-radius: 0.5rem;
    overflow: hidden;
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
}

a.scorecard-link:hover .fixture-card,
.whats-on-list a:hover .fixture-card {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
}

.fixture-header {
    background-color: #2d3748;
    padding: 0.75rem 1.25rem;
    font-weight: bold;
    color: #ea580c;
}

.fixture-card .team-name {
    color: #ffffff;
}


/* ==========================================================================
   Archive & Admin Page Tabs
   ========================================================================== */
.archive-tabs,
.nav-tabs {
    border-bottom: 2px solid #334155;
    margin-bottom: 1.5rem;
}

.archive-tabs .nav-link,
.nav-tabs .nav-link {
    color: #cbd5e0;
    font-size: 1.1rem;
    font-weight: 500;
    border: none;
    border-bottom: 2px solid transparent;
    padding: 0.75rem 1.25rem;
    text-decoration: none;
    transition: color 0.2s ease, border-color 0.2s ease;
}

.archive-tabs .nav-link:hover,
.nav-tabs .nav-link:hover {
    color: #ffffff;
    border-bottom-color: #475569;
}

.archive-tabs .nav-link.active,
.nav-tabs .nav-link.active {
    color: #f97316;
    background-color: transparent;
    border-color: #f97316;
}

.archive-tabs .nav-link.active:hover,
.nav-tabs .nav-link.active:hover {
    color: #f97316;
}

.archive-tabs .nav-link:focus,
.nav-tabs .nav-link:focus {
    outline: none;
    box-shadow: none;
}


/* ==========================================================================
   Forms & Buttons
   ========================================================================== */

.form-control, .form-select {
    background-color: #334155;
    border: 1px solid #475569;
    color: #e2e8f0;
    border-radius: 0.375rem;
}

.form-control:focus, .form-select:focus {
    background-color: #334155;
    border-color: #f97316;
    color: #e2e8f0;
    box-shadow: 0 0 0 0.25rem rgba(249, 115, 22, 0.25);
}

.form-control::placeholder {
    color: #94a3b8;
}

.form-label {
    color: #94a3b8;
}

.btn-primary {
    background-color: #ea580c;
    border-color: #ea580c;
    color: #ffffff;
}

.btn-primary:hover {
    background-color: #c2410c;
    border-color: #c2410c;
}

/* ==========================================================================
   Dashboard "What's On" Styles
   ========================================================================== */

.event-date-box { 
    background-color: #2d3748; 
    color: #ffffff; 
    border-radius: 0.375rem; 
    padding: 0.5rem; 
    width: 70px; 
    flex-shrink: 0; 
}

.event-date-box .month { 
    font-size: 0.8rem; 
    font-weight: bold; 
    text-transform: uppercase; 
    color: #f97316; 
}

.event-date-box .day { 
    font-size: 2rem; 
    font-weight: bold; 
    line-height: 1; 
}

.event-date-box .time { 
    font-size: 0.9rem; 
}

.event-details { 
    flex-grow: 1; 
}

/* Month pagination styles */
.nav-pills .nav-link { 
    color: #cbd5e0; 
}

.nav-pills .nav-link.active,
.nav-pills .show > .nav-link { 
    background-color: #ea580c; 
    color: #ffffff; 
}


/* ==========================================================================
   Responsive Styles (Media Queries)
   ========================================================================== */

@media (max-width: 768px) {
    body {
        padding-top: 80px; /* Reduce body padding on smaller screens */
    }

    .navbar .logo-link {
        height: 90px;
        width: 90px;
        top: 5px;
        left: 1rem;
        border-width: 3px;
    }
    
    .navbar .navbar-logo {
        height: 85%;
    }

    .user-info {
        display: none; /* Hide user info text on small screens to save space */
    }
}

/* ==========================================================================
   Fullscreen Mode Styles
   ========================================================================== */

body.fullscreen-active .navbar,
body.fullscreen-active > .container-fluid > h1,
body.fullscreen-active > .container-fluid > .filter-card {
    display: none !important;
}

body.fullscreen-active #results-header > div {
    display: none !important;
}

body.fullscreen-active {
    padding-top: 0 !important;
}

body.fullscreen-active #scorecard-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: #0a192f;
    overflow-y: auto;
    padding: 1rem;
    z-index: 5000;
}

body.fullscreen-active #fullscreen-toggle {
    position: fixed;
    top: 1rem;
    right: 1.5rem;
    z-index: 5001;
}

.alert-success {
    background-color: #166534;
    color: #dcfce7;
    border: 1px solid #16a34a;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}

.alert-danger { /* Used for both warning and error for consistency */
    background-color: #991b1b;
    color: #fecaca;
    border: 1px solid #dc2626;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}