/* ===================================================================
   TABLE OF CONTENTS
===================================================================
   1.  IMPORTS & ROOT VARIABLES
       - Google Font Imports (REMOVED - ADD LOCAL PATHS)
       - Color Palette, Gradients, Fonts, and Sizing Variables
   2.  GENERAL & TYPOGRAPHY
       - Body & Base Styles
       - Responsive Headings (h1-h6)
       - Paragraph & General Text Styles
   3.  LAYOUT & WRAPPERS
       - Main Content Wrapper
   4.  HEADER & NAVBAR
       - Header Banner & Gradient Title
       - Main Navbar
       - Navigation Links & Buttons (Shared Styles)
       - Specific Button Styles (Dashboard, Login, etc.)
       - User Menu & Language Switcher
   5.  DROPDOWN MENUS
       - Custom Dropdown Styling
   6.  HOMEPAGE SECTIONS
       - Hero / Website Details
       - About Section
       - Feature Cards & Carousels
   7.  FOOTER
       - Main Footer Container
       - Partner Logo Strip
       - Social Icons & Contact Info
       - Copyright Bottom Bar
   8.  UTILITIES & COMPONENTS
       - Django Messages / Alerts
       - Floating Action Button (FAB)
   9.  RESPONSIVE DESIGN
       - Media Queries for Tablet & Mobile
   10. ACCESSIBILITY
       - High Contrast Mode Overrides
=================================================================== */


/* ===================================================================
   1. IMPORTS & ROOT VARIABLES
=================================================================== */

/* ===================================================================
   1. LOCAL FONT DEFINITIONS
=================================================================== */

/* --- Poppins Font Files --- */
@font-face {
  font-family: 'Poppins';
  src: url('/static/font/Poppins/Poppins-Regular.ttf') format('truetype');
  font-weight: 400; /* normal */
  font-style: normal;
}

@font-face {
  font-family: 'Poppins';
  src: url('/static/font/Poppins/Poppins-Medium.ttf') format('truetype');
  font-weight: 500; /* medium */
  font-style: normal;
}

@font-face {
  font-family: 'Poppins';
  src: url('/static/font/Poppins/Poppins-Bold.ttf') format('truetype');
  font-weight: 700; /* bold */
  font-style: normal;
}

/* --- Montserrat Font Files (for headings) --- */
@font-face {
  font-family: 'Montserrat';
  src: url('/static/font/Montserrat/Montserrat-Bold.ttf') format('truetype');
  font-weight: 700; /* bold */
  font-style: normal;
}

@font-face {
  font-family: 'Montserrat';
  src: url('/static/font/Montserrat/Montserrat-ExtraBold.ttf') format('truetype');
  font-weight: 800; /* extra-bold */
  font-style: normal;
}
/* ===================================================================
   2. ROOT VARIABLES
=================================================================== */

:root {
    /* -- Color Palette -- */
    --primary-color: #007bff;
    --primary-hover: #0056b3;
    --secondary-color: #6c757d;
    --dark-color: #212529;
    --text-dark: #343a40;
    --text-light: #ffffff;
    --body-bg: #f8f9fa;
    --component-bg: #ffffff;
    --accent-gold: #ffd700;

    /* -- Gradients -- */
    --gradient-primary: linear-gradient(to right, #6a11cb, #2575fc);
    --gradient-accent: linear-gradient(to right, #ffd700, #ffe066);

    /* -- Typography -- */
    --font-primary: 'Poppins', sans-serif;
    --font-headings: 'Montserrat', sans-serif;
    --base-font-size: 1rem;
    --line-height-base: 1.6;

    /* -- Borders & Shadows -- */
    --border-radius-default: 0.375rem;
    --border-radius-large: 10px;
    --shadow-soft: 0 8px 25px rgba(0, 0, 0, 0.1);
    --shadow-medium: 0 4px 15px rgba(0, 0, 0, 0.2);
    --shadow-hard: 0 8px 25px rgba(0, 0, 0, 0.4);
}


/* ===================================================================
   3. GENERAL & TYPOGRAPHY
=================================================================== */

/* -- Base Body Style (Consolidated) -- */
body {
    font-family: var(--font-primary);
    font-size: var(--base-font-size);
    color: var(--text-dark);
    background-color: var(--body-bg);
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* -- Headings -- */
h1, h2, h3, h4, h6 {
    font-family: var(--font-headings);
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 1rem;
    color: var(--text-light);
}
h3, {
    font-family: var(--font-headings);
    font-weight: 500;
    line-height: 1.1;
    margin-bottom: 1rem;
    color: var(--text-light);
}

h5 {
    font-family: var(--font-headings);
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 1rem;
    color: var(--text-dark);
}

h1 { font-size: calc(var(--base-font-size) * 2.5); }
h2 { font-size: calc(var(--base-font-size) * 2); }
h3 { font-size: calc(var(--base-font-size) * 1.75); }
h4 { font-size: calc(var(--base-font-size) * 1.5); }
h5 { font-size: calc(var(--base-font-size) * 1.25); }
h6 { font-size: calc(var(--base-font-size) * 1); }

/* -- Paragraphs & Links -- */
p {
    font-size: var(--base-font-size);
    line-height: var(--line-height-base);
    margin-bottom: 1rem;
    color: var(--text-dark);
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    color: var(--primary-hover);
    text-decoration: underline;
}


/* ===================================================================
   4. LAYOUT & WRAPPERS
=================================================================== */

.content-wrapper {
    background-color: var(--component-bg);
    border-radius: var(--border-radius-large);
    box-shadow: var(--shadow-soft);
    margin-top: 25px;
    margin-bottom: 25px;
    padding: 30px;
}

.content-wrapper-no-padding {
    background-color: var(--component-bg);
    border-radius: var(--border-radius-large);
    box-shadow: var(--shadow-soft);
}

/* ===================================================================
   5. HEADER & NAVBAR
=================================================================== */
/* ===================================================================
   5. HEADER & NAVBAR
=================================================================== */

/* -- Header Banner -- */
.header {
    background: var(--gradient-primary);
    color: var(--component-bg);
    padding: 20px 0;
    box-shadow: var(--shadow-medium);
}

/* Make headings inside the header white */
.header h1, .header h2, .header h3, .header h4, .header h5, .header h6 {
    color: var(--component-bg);
}

.gradient-text-title {
    background: var(--gradient-accent);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    font-weight: 800; /* Uses Extra-Bold Montserrat if available */
    text-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
}

/* -- Main Navbar -- */
.custom-navbar {
    background: var(--gradient-primary);
    box-shadow: var(--shadow-medium);
    padding-top: 0.75rem;
    padding-bottom: 0.75rem;
}

/* -- Shared Styles for Navbar Links & Buttons -- */
.custom-nav-btn, .custom-dashboard-link, .login-btn, .signup-btn, .language-switcher {
    display: inline-flex;
    align-items: center;
    padding: 0.6rem 1.2rem;
    margin: 0.04rem .26rem;
    font-weight: 500;
    border-radius: var(--border-radius-default);
    transition: all 0.3s ease;
    text-decoration: none;
    border: 1px solid transparent;
}

.custom-nav-btn i, .custom-dashboard-link i, .language-switcher i {
    margin-right: 0.5rem;
}

/* -- Standard Navigation Links -- */
.custom-nav-btn {
    color: var(--text-light) !important;
    border-color: var(--text-light);
}

.custom-nav-btn:hover,
.custom-nav-btn:focus {
    background-color: rgba(255, 255, 255, 0.15);
    color: var(--component-bg) !important;
    border-color: var(--component-bg);
    transform: translateY(-2px);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);
    text-decoration: none;
}

/* -- Active State for Nav Links -- */
.nav-item .nav-link.active.custom-nav-btn,
.nav-item .nav-link.active.custom-dashboard-link {
    color: var(--accent-gold) !important;
    background-color: rgba(255, 255, 255, 0.1);
    text-shadow: 0 0 10px rgba(255, 215, 0, 0.8);
    border-color: var(--accent-gold) !important;
    transform: scale(1.03);
    pointer-events: none;
}

/* -- Prominent Dashboard Link -- */
.custom-dashboard-link {
    color: var(--accent-gold) !important;
    font-weight: bold;
    text-shadow: 0 0 5px rgba(255, 215, 0, 0.5);
}

.custom-dashboard-link:hover {
    color: var(--component-bg) !important;
    background-color: rgba(255, 255, 255, 0.15);
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    text-decoration: none;
}

/* -- User Menu Button -- */
.user-menu-btn {
    background-color: #28a745 !important;
    border-color: #28a745 !important;
    color: var(--component-bg) !important;
    border-radius: 50px;
    margin-left: 0.5rem;
}

.user-menu-btn:hover {
    background-color: #218838 !important;
    border-color: #1e7e34 !important;
    transform: scale(1.03);
}

/* -- Login/Signup Buttons -- */
.login-btn {
    background-color: #ffc107 !important;
    border-color: #ffc107 !important;
    color: var(--text-dark) !important;
}

.form-btn {
    background: linear-gradient(to right, rgba(106, 17, 203, 0.8), rgba(37, 117, 252, 0.8)) !important;
    border-color: #ffc107 !important;
    color: var(--text-light) !important;
    font-weight: 600 !important;
    line-height: 1.3;
    margin-bottom: 1rem;
}

.login-btn:hover {
    background-color: #e0a800 !important;
    border-color: #d39e00 !important;
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.signup-btn {
    background-color: #17a2b8 !important;
    border-color: #17a2b8 !important;
    color: var(--component-bg) !important;
}

.signup-btn:hover {
    background-color: #138496 !important;
    border-color: #117a8b !important;
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

/* -- Language Switcher in Navbar -- */
.language-switcher {
    color: var(--text-light) !important;
}

.language-switcher:hover {
    color: var(--component-bg) !important;
    background-color: rgba(255, 255, 255, 0.1);
    transform: translateX(3px);
    text-decoration: none;
}
/* ===================================================================
   5. DROPDOWN MENUS
=================================================================== */
.custom-dropdown-menu {
    background-color: var(--component-bg);
    border-radius: 8px;
    box-shadow: var(--shadow-hard);
    border: none;
    overflow: hidden;
}

.custom-dropdown-item {
    color: var(--text-dark);
    transition: background-color 0.2s ease, color 0.2s ease;
    padding: 0.75rem 1.25rem;
    display: flex;
    align-items: center;
}

.custom-dropdown-item i {
    font-size: 1.1em;
    width: 25px;
    text-align: center;
    margin-right: 0.5rem;
}

.custom-dropdown-item:hover {
    background-color: #e9ecef;
    color: var(--primary-color);
}

.custom-dropdown-item.active {
    background-color: var(--primary-color);
    color: var(--component-bg);
    font-weight: 500;
}


/* ===================================================================
   6. HOMEPAGE SECTIONS (IMPROVED)
=================================================================== */

/* -- Modern Hero Section -- */
.hero-section {
    position: relative;
    padding: 8rem 0;
    background: var(--gradient-primary);
    overflow: hidden;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.1);
    z-index: 1;
}

.hero-section .container {
    z-index: 2;
}

.hero-section .register-btn {
    background-image: linear-gradient(to right, #ffc107 0%, #ff8c00 100%) !important;
    border: none !important;
    color: var(--dark-color) !important;
    font-weight: 600;
    box-shadow: 0 10px 30px rgba(255, 193, 7, 0.4) !important;
    transition: all 0.3s ease;
}

.hero-section .register-btn:hover {
    transform: translateY(-5px) scale(1.05);
    box-shadow: 0 15px 40px rgba(255, 193, 7, 0.6) !important;
}

/* -- SVG Shape Divider -- */
.hero-shape-divider {
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 100%;
    overflow: hidden;
    line-height: 0;
    transform: rotate(180deg);
    z-index: 2;
}

.hero-shape-divider svg {
    position: relative;
    display: block;
    width: calc(100% + 1.3px);
    height: 100px;
}

.hero-shape-divider .shape-fill {
    fill: var(--body-bg); /* Match the color of the section below */
}

/* -- Common Section Title -- */
.section-title {
    font-family: var(--font-headings);
    font-weight: 800;
    color: var(--dark-color);
    margin-bottom: 0.5rem;
}

/* -- About Section -- */
.about-section .about-icon {
    font-size: 8rem;
    opacity: 0.15;
}

/* -- Showcase Section (Tabs) -- */
.showcase-section .nav-pills .nav-link {
    background-color: #e9ecef;
    color: var(--secondary-color);
    font-weight: 600;
    padding: 0.75rem 1.5rem;
    border-radius: 50px;
    transition: all 0.3s ease;
}

.showcase-section .nav-pills .nav-link.active,
.showcase-section .nav-pills .show > .nav-link {
    background-color: var(--primary-color);
    color: #ffffff;
    box-shadow: 0 5px 15px rgba(var(--bs-primary-rgb), 0.4);
}

/* -- Feature Card (Legacy) -- */
.feature-card {
    background-color: #ffffff;
    border-radius: var(--border-radius-large);
    padding: 2rem;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.07);
    transition: all 0.3s ease;
    border: 1px solid #dee2e6;
    height: 100%;
}

.feature-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.12);
}

.feature-card-icon {
    margin-bottom: 1.5rem;
}

.feature-card-icon img {
    max-height: 80px;
    width: auto;
}

.feature-card-title {
    font-size: 1.25rem;
    margin-bottom: 1rem;
    color: var(--dark-color);
}

.feature-card-text {
    color: var(--secondary-color);
    font-size: 0.95rem;
}

/* -- Gallery Card -- */
.gallery-card {
    position: relative;
    border-radius: var(--border-radius-large);
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: box-shadow 0.3s ease;
}

.gallery-card:hover {
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.2);
}

.gallery-card-img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.gallery-card:hover .gallery-card-img {
    transform: scale(1.1);
}

.gallery-card-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    color: #ffffff;
    padding: 3rem 1.5rem 1.5rem 1.5rem;
    transition: opacity 0.3s ease;
}

.gallery-card-title {
    font-weight: 700;
    font-size: 1.2rem;
    margin-bottom: 0.25rem;
}

.gallery-card-text {
    font-size: 0.9rem;
    opacity: 0.8;
}

/* ===================================================================
   HOMEPAGE SECTIONS - CAROUSEL ADDITIONS
=================================================================== */

/* Styles for the carousel controls inside the showcase section */
.showcase-section .carousel-control-prev,
.showcase-section .carousel-control-next {
    width: 5%; /* Adjust width of the control area */
}

.showcase-section .carousel-control-prev-icon,
.showcase-section .carousel-control-next-icon {
    background-color: rgba(0, 0, 0, 0.4); /* Dark background to be visible */
    border-radius: 50%;
    padding: 1.25rem; /* Make the icon background larger */
    background-size: 50%; /* Make the arrow icon inside smaller */
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    transition: background-color 0.3s ease;
}

.showcase-section .carousel-control-prev-icon:hover,
.showcase-section .carousel-control-next-icon:hover {
    background-color: rgba(var(--bs-primary-rgb), 0.8); /* Use primary color on hover */
}

/* Ensure consistent height and centered content in the carousel items */
.showcase-section .carousel-item {
    padding: 1rem 0 3rem 0; /* Add padding to prevent content from touching controls */
}


/* ===================================================================
   7. FOOTER
=================================================================== */
.main-footer {
    background-color: #1a1e22; /* A very dark, near-black color */
    color: var(--text-light);
    font-family: var(--font-primary);
    border-top: 4px solid var(--primary-color);
}

/* Adds a subtle background texture to the main footer area */
.footer-bg-pattern {
    background-color: #212529; /* Standard dark footer color */
    /* REMOVED: background-image url */
    background-attachment: scroll;
}

.footer-section-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 1.5rem;
    position: relative;
    padding-bottom: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.footer-section-title::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 50px;
    height: 3px;
    background: var(--gradient-primary); /* Use main site gradient */
    border-radius: 2px;
}

/* About and Subscription Text */
.footer-about-text,
.footer-subscribe-text {
    color: var(--text-light);
    opacity: 0.8;
    line-height: 1.8;
    margin-bottom: 1.5rem;
}

/* Social Media Icons */
.social-icons a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 44px;
    height: 44px;
    background-color: rgba(255, 255, 255, 0.08);
    border-radius: 50%;
    color: #ffffff;
    font-size: 1.1rem;
    margin-right: 10px;
    transition: all 0.3s ease-in-out;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.social-icons a:hover {
    color: #ffffff !important;
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
    text-decoration: none;
}
/* Individual brand colors on hover */
.social-icon-fb:hover { background-color: #1877F2; }
.social-icon-tw:hover { background-color: #1DA1F2; }
.social-icon-yt:hover { background-color: #FF0000; }
.social-icon-in:hover { background-color: #C13584; }


/* Contact Info List */
.footer-contact-list li {
    display: flex;
    align-items: flex-start;
    margin-bottom: 1rem;
    color: var(--text-light);
    opacity: 0.9;
}

.footer-contact-list i {
    color: var(--primary-color);
    font-size: 1.1rem;
    margin-right: 15px;
    width: 20px;
    text-align: center;
    flex-shrink: 0;
    padding-top: 4px;
}

.footer-contact-list a {
    color: var(--text-light);
    text-decoration: none;
    transition: color 0.3s ease;
}
.footer-contact-list a:hover {
    color: #ffffff;
    text-decoration: underline;
}

/* Newsletter Signup Form */
.footer-subscribe-form .form-control {
    background-color: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #ffffff;
    border-radius: 0.375rem 0 0 0.375rem;
    padding: 0.75rem 1rem;
}

.footer-subscribe-form .form-control::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.footer-subscribe-form .form-control:focus {
    background-color: rgba(0, 0, 0, 0.3);
    box-shadow: 0 0 0 0.25rem rgba(var(--bs-primary-rgb), 0.5);
    border-color: var(--primary-color);
}

.footer-subscribe-form .btn {
    border-radius: 0 0.375rem 0.375rem 0;
    padding: 0.75rem 1.2rem;
}

/* Partner Logo Strip */
.footer-top-strip {
    padding: 20px 0;
    background-color: #ffffff;
    border-bottom: 1px solid #e9ecef;
}

.footer-logo-item img {
    max-height: 45px;
    width: auto;
    filter: grayscale(100%);
    opacity: 0.7;
    transition: all 0.3s ease-in-out;
}

.footer-logo-item:hover img {
    filter: grayscale(0%);
    opacity: 1;
    transform: scale(1.1);
}

/* Bottom Copyright Bar */
.footer-bottom {
    background-color: #121518;
    color: #adb5bd;
    padding: 15px 0;
    font-size: 0.9rem;
}

/* Responsive adjustments */
@media (max-width: 767.98px) {
    .footer-section-title {
        text-align: center;
    }

    .footer-section-title::after {
        left: 50%;
        transform: translateX(-50%);
    }

    .social-icons {
        justify-content: center;
    }
}


/* ===================================================================
   8. UTILITIES & COMPONENTS
=================================================================== */

/* -- Django Messages / Alerts -- */
.messages-container .alert {
    border-radius: 0.5rem;
    font-size: 1rem;
    padding: 1rem 1.5rem;
    position: relative;
    animation: fadeInOut 5s forwards;
}

@keyframes fadeInOut {
    0% { opacity: 0; transform: translateY(-10px); }
    10% { opacity: 1; transform: translateY(0); }
    90% { opacity: 1; transform: translateY(0); }
    100% { opacity: 0; transform: translateY(-10px); display: none; }
}


/* -- Floating Action Button (FAB) -- */
.fab-language-switcher {
    position: fixed;
    bottom: 25px;
    right: 25px;
    z-index: 1050;
}

/* ===================================================================
   9. RESPONSIVE DESIGN
=================================================================== */

/* -- For Tablets (screens smaller than 992px) -- */
@media (max-width: 991.98px) {
    .custom-navbar {
        /*
        * FIX: Changed from --gradient-end (which was undefined)
        * to --gradient-primary to match the desktop navbar.
        */
        background: var(--gradient-primary);
    }

    .navbar-collapse {
        padding: 1rem 0;
        /* This ensures the dropdown area doesn't have its own white bg */
        background-color: transparent;
    }

    /* Stack all navbar items vertically */
    .custom-nav-btn,
    .login-btn,
    .signup-btn,
    .custom-dashboard-link,
    .language-switcher,
    .user-menu-btn {
        width: 100%;
        text-align: left;
        margin-bottom: 8px;
        margin-right: 0 !important;
        padding: 0.8rem 1.2rem !important;
        font-size: 1rem;
        justify-content: flex-start;
    }
}
/* ===================================================================
   10. ACCESSIBILITY
=================================================================== */

/* -- High Contrast Mode Overrides -- */
body.high-contrast {
    background-color: black !important;
    color: yellow !important;
}

/* Universal text color override */
body.high-contrast h1, body.high-contrast h2, body.high-contrast h3,
body.high-contrast h4, body.high-contrast h5, body.high-contrast h6,
body.high-contrast p, body.high-contrast span, body.high-contrast a,
body.high-contrast div:not(.messages-container .alert),
body.high-contrast li, body.high-contrast label, body.high-contrast small {
    color: yellow !important;
    text-shadow: none !important;
}

/* Backgrounds and Borders */
body.high-contrast .header,
body.high-contrast .custom-navbar,
body.high-contrast .main-footer,
body.high-contrast .footer-bottom,
body.high-contrast .content-wrapper,
body.high-contrast .custom-dropdown-menu,
body.high-contrast .card,
body.high-contrast .feature-card {
    background: black !important;
    border: 1px solid yellow !important;
}

/* Remove gradients and shadows */
body.high-contrast .gradient-text-title {
    background: none !important;
    -webkit-text-fill-color: yellow !important;
}

body.high-contrast .social-icons a,
body.high-contrast .carousel-control-prev-icon,
body.high-contrast .carousel-control-next-icon {
    background-color: black !important;
    color: yellow !important;
    border: 1px solid yellow !important;
}

/* Buttons, Links, and Interactive Elements */
body.high-contrast .btn,
body.high-contrast .nav-link,
body.high-contrast .custom-nav-btn,
body.high-contrast .custom-dashboard-link,
body.high-contrast .language-switcher,
body.high-contrast .login-btn,
body.high-contrast .signup-btn {
    background: transparent !important;
    border-color: yellow !important;
    color: yellow !important;
    box-shadow: none !important;
}

body.high-contrast .btn:hover,
body.high-contrast .nav-link:hover,
body.high-contrast .custom-nav-btn:hover {
    background-color: rgba(255, 255, 0, 0.2) !important;
    color: yellow !important;
}

/* Active states */
body.high-contrast .nav-item .nav-link.active {
    background-color: rgba(255, 255, 0, 0.1) !important;
    border-style: dashed !important;
}

/* Remove image filters that reduce contrast */
body.high-contrast .footer-logo-item img {
    filter: none !important;
    opacity: 1 !important;
}


/* ===================================================================
   ABOUT PAGE STYLES
=================================================================== */

/* -- Page Header -- */
.page-header {
    position: relative;
    padding: 5rem 0;
    /* REMOVED: background-image url */
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}

.page-header-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to right, rgba(106, 17, 203, 0.8), rgba(37, 117, 252, 0.8));
}

/* -- Introduction & Objectives -- */
.objective-card {
    display: flex;
    align-items: center;
    background-color: #ffffff;
    padding: 1rem 1.5rem;
    border-radius: var(--border-radius-large);
    margin-bottom: 1rem;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    border-left: 5px solid var(--primary-color);
    transition: all 0.3s ease;
}

.objective-card:hover {
    transform: translateX(10px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.objective-card .objective-icon {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-right: 1.5rem;
}

.objective-card p {
    margin-bottom: 0;
    font-weight: 500;
    color: var(--text-dark);
}


/* -- Custom Accordion -- */
.custom-accordion .accordion-item {
    background-color: #ffffff;
    border: 1px solid #e9ecef;
    border-radius: var(--border-radius-large) !important;
    margin-bottom: 1rem;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

.custom-accordion .accordion-header {
    margin: 0;
}

.custom-accordion .accordion-button {
    background-color: #ffffff;
    color: var(--dark-color);
    font-weight: 600;
    font-size: 1.1rem;
    box-shadow: none !important;
}

.custom-accordion .accordion-button:not(.collapsed) {
    background: var(--gradient-primary);
    color: #ffffff;
    box-shadow: inset 0 -2px 5px rgba(0,0,0,0.1);
}

.custom-accordion .accordion-button:not(.collapsed)::after {
    filter: brightness(0) invert(1);
}

.custom-accordion .accordion-body {
    padding: 1.5rem;
}

/* -- Styled List (inside accordion) -- */
.styled-list {
    list-style: none;
    padding-left: 0;
}

.styled-list li {
    position: relative;
    padding-left: 2rem;
    margin-bottom: 0.75rem;
    line-height: 1.8;
}

.styled-list li::before {
    content: '\f058'; /* Font Awesome check-circle icon */
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    left: 0;
    top: 5px;
    color: var(--primary-color);
    font-size: 1rem;
}

/* -- Timeline Section -- */
.timeline-section {
    position: relative;
}

.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
}

.timeline::after {
    content: '';
    position: absolute;
    width: 4px;
    background-color: #e9ecef;
    top: 0;
    bottom: 0;
    left: 50%;
    margin-left: -2px;
}

.timeline-item {
    padding: 1rem 1.5rem;
    position: relative;
    width: 50%;
}

.timeline-item:nth-child(odd) {
    left: 0;
}

.timeline-item:nth-child(even) {
    left: 50%;
}

.timeline-item .timeline-icon {
    position: absolute;
    width: 50px;
    height: 50px;
    right: -25px;
    top: 30px;
    background-color: #ffffff;
    border: 4px solid var(--primary-color);
    border-radius: 50%;
    z-index: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.2rem;
    color: var(--primary-color);
}

.timeline-item:nth-child(even) .timeline-icon {
    left: -25px;
}

.timeline-content {
    padding: 1rem;
    background-color: #ffffff;
    position: relative;
    border-radius: var(--border-radius-large);
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
}

.timeline-content h4 {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--primary-color);
}
.timeline-content p {
    font-size: 0.95rem;
    margin-bottom: 0;
}

/* Responsive Timeline */
@media (max-width: 767.98px) {
    .timeline::after {
        left: 25px;
    }
    .timeline-item {
        width: 100%;
        padding-left: 60px;
        padding-right: 15px;
    }
    .timeline-item:nth-child(odd),
    .timeline-item:nth-child(even) {
        left: 0;
    }
    .timeline-item .timeline-icon {
        left: 0;
    }
}

/* ===================================================================
   RESOURCES PAGE STYLES
=================================================================== */

/* -- Resource Card -- */
.resource-card {
    background-color: #ffffff;
    border: 1px solid #e9ecef;
    border-radius: var(--border-radius-large);
    padding: 2rem 1.5rem;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
    /* Flexbox to push button to the bottom */
    display: flex;
    flex-direction: column;
}

.resource-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.1);
    border-color: var(--primary-color);
}

.resource-card-icon {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    line-height: 1;
}

.resource-card-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-dark);
    /* Set a fixed height to align titles across cards */
    min-height: 3.3em; /* Approx. 2 lines of text */
    margin-bottom: 1rem;
}


/* -- Call-to-Action (CTA) Section -- */
.cta-section {
    padding: 4rem 0;
    background: var(--gradient-primary);
    border-radius: var(--border-radius-large);
}

.cta-section h2 {
    color: #ffffff;
    text-shadow: 1px 1px 5px rgba(0,0,0,0.2);
}

.cta-section p {
    color: rgba(255, 255, 255, 0.9);
}

.cta-section .btn-light {
    padding: 0.75rem 2.5rem;
    border-radius: 50px;
    color: var(--primary-color);
    transition: all 0.3s ease;
}

.cta-section .btn-light:hover {
    background-color: var(--accent-gold);
    color: var(--dark-color);
    transform: scale(1.05);
}

/* ===================================================================
   ACTIVITIES PAGE STYLES
=================================================================== */

/* -- Key Dates Section -- */
.date-card {
    background-color: #ffffff;
    border-radius: var(--border-radius-large);
    box-shadow: 0 4px 20px rgba(0,0,0,0.06);
    text-align: center;
    padding: 2rem 1rem;
    border-top: 5px solid var(--primary-color);
    transition: all 0.3s ease;
    height: 100%;
}

.date-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.12);
    border-top-color: var(--accent-gold);
}

.date-card-day {
    font-size: 3.5rem;
    font-weight: 800;
    color: var(--dark-color);
    line-height: 1;
}

.date-card-month {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.date-card-event {
    font-size: 1rem;
    font-weight: 500;
    color: var(--secondary-color);
}

/* -- Competition Phases Section -- */
.phase-card {
    display: flex;
    align-items: flex-start;
    gap: 1.5rem;
    text-align: left;
    height: 100%;
}

.phase-icon {
    flex-shrink: 0;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background-color: rgba(var(--bs-primary-rgb), 0.1);
    color: var(--primary-color);
    font-size: 1.5rem;
}

.phase-content h4 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--dark-color);
    margin-bottom: 0.5rem;
}

.phase-content p {
    font-size: 0.95rem;
    color: var(--secondary-color);
    line-height: 1.6;
    margin-bottom: 0;
}

/* ===================================================================
   ARCHIVES PAGE STYLES
=================================================================== */

.archive-card {
    display: block;
    position: relative;
    border-radius: var(--border-radius-large);
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    text-decoration: none;
    height: 250px; /* Give cards a consistent height */
}

.archive-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.2);
}

.archive-card-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.archive-card:hover .archive-card-img {
    transform: scale(1.1);
}

.archive-card-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 1.5rem;
    color: #ffffff;
    background: linear-gradient(to top, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.5) 50%, transparent 100%);
    z-index: 1;
    transition: all 0.3s ease;
}

.archive-card-title {
    font-family: var(--font-headings);
    font-weight: 700;
    font-size: 1.75rem;
    margin: 0;
}

.archive-card-cta {
    display: inline-block;
    font-weight: 500;
    margin-top: 0.25rem;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.3s ease;
}

.archive-card:hover .archive-card-cta {
    opacity: 1;
    transform: translateY(0);
}

/* ===================================================================
   CONTACT US PAGE STYLES
=================================================================== */

.contact-section .contact-wrapper {
    background-color: #ffffff;
    border-radius: var(--border-radius-large);
    box-shadow: 0 10px 40px rgba(0,0,0,0.1);
    overflow: hidden;
}

.contact-info-panel {
    background: var(--gradient-primary);
    color: #ffffff;
    padding: 3rem;
}

.contact-info-panel a {
    color: #ffffff;
    text-decoration: none;
}
.contact-info-panel a:hover {
    text-decoration: underline;
}

.contact-details-list li {
    display: flex;
    align-items: flex-start;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.contact-details-list .contact-icon {
    flex-shrink: 0;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background-color: rgba(255,255,255,0.15);
    font-size: 1.2rem;
}

.contact-details-list .contact-text strong {
    display: block;
    margin-bottom: 0.25rem;
    opacity: 0.8;
}
.contact-details-list .contact-text p {
    margin: 0;
    color: #ffffff;
    font-weight: 500;
}

.contact-form-panel {
    padding: 3rem;
}

.contact-form-panel .form-control {
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    padding: 0.75rem 1rem;
}

.contact-form-panel .form-control:focus {
    background-color: #ffffff;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.25rem rgba(var(--bs-primary-rgb), 0.25);
}

.map-section {
    width: 100%;
    height: 450px; /* Same height as the iframe */
}

.map-section iframe {
    filter: grayscale(80%) contrast(1.2); /* Optional: Stylish map filter */
}

/* ===================================================================
   ARCHIVE DETAIL PAGE STYLES
=================================================================== */

.archive-section .section-title {
    position: relative;
    padding-bottom: 1rem;
}

/* Creates a decorative line under the section title */
.archive-section .section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background-color: var(--primary-color);
    border-radius: 2px;
}

.archive-item-card {
    display: flex;
    flex-direction: column;
    background-color: #ffffff;
    border-radius: var(--border-radius-large);
    box-shadow: 0 4px 15px rgba(0,0,0,0.06);
    text-decoration: none;
    overflow: hidden;
    border: 1px solid #e9ecef;
    transition: all 0.3s ease;
}

.archive-item-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.12);
    border-color: var(--primary-color);
}

.archive-item-img-container {
    background-color: #f8f9fa;
    padding: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-bottom: 1px solid #e9ecef;
}

.archive-item-img {
    max-width: 80%;
    height: auto;
    max-height: 120px;
    object-fit: contain;
}

.archive-item-body {
    padding: 1rem;
    text-align: center;
    margin-top: auto; /* Pushes the body to the bottom */
}

.archive-item-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-dark);
}/* ===================================================================
   INSTRUCTIONS PAGE - DOCUMENT CARDS
=================================================================== */

.section-title-underline {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--dark-color);
    padding-bottom: 0.75rem;
    margin-bottom: 2rem;
    border-bottom: 3px solid var(--primary-color);
    display: inline-block;
}

.document-card {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    background: linear-gradient(to top right, #ffffff, #f8f9fa);
    padding: 1.25rem;
    border-radius: var(--border-radius-large);
    border: 2px solid transparent; /* Prepare for gradient border */
    background-clip: padding-box; /* Important for gradient border */
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
    height: 100%;
    position: relative;
    transition: all 0.3s ease;
}

.document-card::before {
    content: '';
    position: absolute;
    top: 0; right: 0; bottom: 0; left: 0;
    z-index: -1;
    margin: -2px; /* Must be equal to border width */
    border-radius: inherit; /* Follow the parent's border-radius */
    background: linear-gradient(to right, rgba(106, 17, 203, 0.2), rgba(37, 117, 252, 0.2));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.document-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.document-card:hover::before {
    opacity: 1;
}

.document-card__icon {
    flex-shrink: 0;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--gradient-primary);
    color: var(--text-light);
    font-size: 1.2rem;
    box-shadow: 0 4px 10px rgba(var(--bs-primary-rgb), 0.3);
}

.document-card__content {
    line-height: 1.4;
}

.document-card__title {
    display: block;
    font-weight: 600;
    color: var(--text-dark);
}

.document-card__meta {
    color: var(--secondary-color);
    font-size: 0.85rem;
}

/* Modifier for special document cards */
.document-card--special .document-card__icon {
    background: var(--gradient-accent);
    color: var(--dark-color);
    box-shadow: 0 4px 10px rgba(255, 215, 0, 0.4);
}

.document-card--special::before {
    background: var(--gradient-accent);
}

.sub-section {
    padding-top: 1.5rem;
    border-top: 1px solid #e9ecef;
}

.sub-section-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--dark-color);
    margin-bottom: 1.5rem;
}
/* ===================================================================
   INSTRUCTIONS PAGE - ANIMATED AGREEMENT PANEL (SCANNER OPTION)
=================================================================== */

/* Define the animation */
@keyframes scanner-sweep {
  0% {
    transform: translateX(-110%);
  }
  100% {
    transform: translateX(110%);
  }
}

.agreement-panel-styled {
    display: flex;
    align-items: flex-start;
    gap: 1.5rem;
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    border-left: 5px solid var(--primary-color);
    padding: 1.5rem;
    border-radius: var(--border-radius-large);
    margin-top: 2rem;
    position: relative; /* Required for the pseudo-element */
    overflow: hidden; /* Keeps the scanner inside the panel */
}

/* This is the scanner highlight */
.agreement-panel-styled::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100px; /* Width of the highlight */
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(var(--bs-primary-rgb), 0.3),
        transparent
    );
    filter: blur(5px);
    /* Apply the animation here! */
    animation: scanner-sweep 3s infinite linear;
}


.agreement-panel-styled__icon {
    flex-shrink: 0;
    font-size: 1.75rem;
    color: var(--primary-color);
    margin-top: 0.25rem;
    position: relative; /* Ensures icon is on top of the scanner */
    z-index: 2;
}

.agreement-panel-styled__content {
    position: relative; /* Ensures content is on top of the scanner */
    z-index: 2;
}

.agreement-panel-styled__content .form-check {
    padding-left: 0;
}

.agreement-panel-styled__content .form-check-input {
    width: 1.5em;
    height: 1.5em;
    margin-top: 0.25em;
    float: left;
    margin-right: 0.75em;
}

.agreement-panel-styled__content .form-check-label {
    font-size: 1.1rem;
    color: var(--dark-color);
}
/* ===================================================================
   FORM WIZARD / MULTI-STEP FORM STYLES
=================================================================== */

.form-wizard-wrapper {
    background-color: var(--component-bg);
    border-radius: var(--border-radius-large);

    overflow: hidden;
}

/* -- Progress Bar -- */
.form-wizard-progress {
    display: flex;
    justify-content: space-between;
    padding: 2rem 1.5rem;
    background-color: #f8f9fa;
    border-bottom: 1px solid #dee2e6;
}

/* Default State for each step */
.progress-step {
    text-align: center;
    position: relative;
    flex: 1;
    color: var(--secondary-color);
}
.progress-step-icon {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: #e9ecef;
    margin: 0 auto 0.5rem auto;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    border: 3px solid #ced4da;
    transition: all 0.3s ease;
}
.progress-step-label {
    font-weight: 600;
    font-size: 0.9rem;
}
.progress-step::after {
    content: '';
    position: absolute;
    top: 25px;
    left: 50%;
    width: 100%;
    height: 3px;
    background-color: #ced4da; /* Default grey line */
    z-index: -1;
    transform: translateX(50%);
    transition: background-color 0.3s ease;
}
.progress-step:last-child::after {
    display: none;
}

/* Completed State (Green) */
.progress-step.completed .progress-step-icon {
    background-color: #d1e7dd; /* Light green */
    border-color: #198754;   /* Bootstrap success green */
    color: #198754;
}
.progress-step.completed .progress-step-label {
    color: var(--dark-color);
}
.progress-step.completed::after {
    background-color: #198754; /* IMPROVED: Line between completed steps is green */
}


/* Active State (Blue) */
.progress-step.active .progress-step-icon {
    background-color: var(--primary-color);
    border-color: var(--primary-hover);
    color: #ffffff;
    transform: scale(1.1);
    box-shadow: 0 0 15px rgba(var(--bs-primary-rgb), 0.5);
}
.progress-step.active .progress-step-label {
    color: var(--primary-color);
}

/* -- Form Sections -- */

.form-section {
    background: var(--gradient-primary);
    border: 1px solid #e9ecef;
    border-radius: var(--border-radius-large);
    margin-bottom: 2rem;
    overflow: hidden;
}
.form-section-header {
     background: var(--gradient-primary);
}
.form-section-header h5 {
    margin: 0;
    font-size: 1.1rem;
    color: var(--dark-color);
    display: flex;
    align-items: center;
}
.form-section-body {
    padding: 1.5rem;
}

/* -- Conditional Sections (inside a form section) -- */
.conditional-section {
    background-color: #e9f5ff;
    border: 1px solid #bde0fe;
    border-radius: var(--border-radius-large);
    padding: 1.5rem;
    margin-top: 1rem;
}

/* -- Custom Modal Styles -- */
.custom-modal .modal-header {
    background: var(--gradient-primary);
    color: #ffffff;
}
.custom-modal .modal-header .btn-close {
    filter: brightness(0) invert(1);
}
.custom-modal .modal-footer {
    background-color: #f8f9fa;
}