:root {
    --lsfd-red: #b51313;
    --lsfd-red-hover: #ad0e35;
    --lsfd-grey: #353333;
    --text-dark: #333333;
    --text-light: #ffffff;
    --bg-light: #f4f6f9;
    --font-body: 'Montserrat', sans-serif;
    --font-body2: 'Roboto Slab', serif;
    --font-heading: 'Open Sans', sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-light);
    color: var(--text-dark);
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}


/* --- Top Bar --- */
.top-bar {
    background-color: #0f2940;
    color: var(--text-light);
    font-size: 12px;
    font-weight: 500;
    font-family: var(--font-heading);
    min-height: 47px;
    display: flex;
    justify-content: flex-start;
    align-items: center;
    padding: 0 10px;
}

.header-seal {
    height: 22px;
    width: 22px;
}

#header-seal-div {
    display: flex;
    align-items: center;
    justify-content: center;
}

.top-bar .container-header {
    align-items: center;
    display: flex;
    gap: 5px;
}

@media (max-width: 860px) {
    .top-bar {
        position: sticky;
        top: 0;
        z-index: 102;
    }
}


/* --- Support Bar --- */
#support {
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: #000;
    color: var(--text-light);
    font-family: var(--font-body);
    font-size: 12px;
    letter-spacing: 2px;
    text-transform: uppercase;
    padding: 10px 0;
    height: 22px;
    box-sizing: content-box;
    font-weight: 400;
}

@media (max-width: 860px) {
    #support {
        position: sticky;
        top: 0;
        z-index: 101;
        padding: 8px 0;
        font-size: 11px;
        height: 18px;
    }
}

#brand {
    background-color: var(--lsfd-red);
    padding: 15px 20px;
    text-align: center;
}

@media (min-width: 1024px) {
    #brand {
        padding: 20px 380px;
    }
}

#brand a {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    color: #ffffff;
    text-decoration: none;
    transition: opacity 0.3s;
    padding: 10px 0px;
}

#brand a:hover {
    opacity: 0.9;
}

#brand .welcome-text {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 2px;
}

#brand .dept-name {
    font-size: 2.2rem;
    font-weight: 700;
    font-family: var(--font-heading);
    line-height: 1.1;
    letter-spacing: 3px;
    text-transform: uppercase;
}

@media (max-width: 860px) {
    #brand {
        padding: 10px 15px;
    }

    #brand .welcome-text {
        display: none;
    }

    #brand .dept-name {
        font-size: 1rem;
        letter-spacing: 1px;
    }
}

/* --- Fixed Header Container --- */
.fixed-header {
    position: relative;
    z-index: 100;
}

@media (max-width: 860px) {
    .fixed-header {
        position: sticky;
        top: 69px;
        z-index: 100;
        background-color: var(--lsfd-red);
    }

    #brand {
        background-color: var(--lsfd-red);
        position: relative;
        z-index: 101;
        /* Ensure brand stays on top */
    }

    .mobile-header-bar {
        background-color: var(--lsfd-grey);
    }
}


/* --- Navigation --- */
.main-nav {
    background-color: var(--lsfd-grey);
    height: 56px;
    padding: 0;
    position: relative;
    z-index: 50;
}

.main-nav .container {
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    padding: 0 20px;
}

@media (min-width: 1200px) {
    .main-nav .container {
        gap: 150px;
    }
}

.main-nav #navleft,
.main-nav #navright {
    height: 100%;
    flex: 1;
    display: flex;
    align-items: center;
}

.main-nav #navleft {
    justify-content: flex-end;
}

.main-nav #navright {
    justify-content: flex-start;
}

.main-nav ul {
    display: flex;
    justify-content: center;
    align-items: center;
    list-style: none;
    height: 100%;
    margin: 0;
    padding: 0;
}

.main-nav li {
    display: flex;
    align-items: center;
}

.main-nav ul.menu>li>a {
    white-space: nowrap;
}

.main-nav a {
    color: #ffffff;
    list-style: none;
    border: 0;
    margin: 0;
    outline: 0;
    box-sizing: border-box;
    transition: all 0.4s;
    display: block;
    line-height: 38px;
    padding: 9px 14px;
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 12px;
    font-weight: 500;
    font-style: normal;
    cursor: pointer;
}

.main-nav a:hover {
    background-color: #ffffff;
    color: var(--lsfd-red-hover);
}

/* --- Dropdown Menu --- */
.dropdown-item {
    position: relative;
    height: 100%;
    display: flex;
    align-items: center;
}

.dropdown-item:hover>a {
    background-color: #ffffff;
    color: var(--lsfd-red-hover);
}

.main-nav ul.dropdown-menu-right,
.main-nav ul.dropdown-menu-left {
    display: none;
    position: absolute;
    top: 100%;
    height: auto;
    background-color: #ffffff;
    width: 200px;
    flex-direction: column;
    align-items: flex-start;
    padding: 10px;
    z-index: 200;
    box-shadow: 0 3px 3px rgba(0, 0, 0, 0.2);
}

.main-nav ul.dropdown-menu-right {
    left: 0;
}

.main-nav ul.dropdown-menu-left {
    right: 0;
}

.dropdown-item:hover .dropdown-menu-right,
.dropdown-item:hover .dropdown-menu-left {
    display: flex;
}

.dropdown-menu-right li,
.dropdown-menu-left li {
    width: 100%;
    padding: 0;
}

.dropdown-menu-right li a,
.dropdown-menu-left li a {
    height: auto;
    width: 100%;
    padding: 10px 10px;
    margin: 0 0 4px 0;
    justify-content: flex-start;
    background-color: transparent;
    color: var(--lsfd-red-hover);
    line-height: 1.4em;
    font-weight: 500;
    white-space: normal;
}

.dropdown-menu-right li:not(:last-child),
.dropdown-menu-left li:not(:last-child) {
    border-bottom: none;
}

.dropdown-menu-right li a:hover,
.dropdown-menu-left li a:hover {
    background-color: #efefef;
    color: #000000;
}


/* --- Logo --- */
#logo {
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    z-index: 100;
    pointer-events: none;
    height: 0;
    width: 0;
    display: flex;
    justify-content: center;
    align-items: center;
}

.nav-logo-item {
    position: absolute;
    bottom: 25px;
    transform: translateY(50%);
}

.nav-logo {
    height: 125px;
    width: auto;
    filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.3));
    display: block;
    pointer-events: auto;
}

/* Hide central logo on mobile */
@media (max-width: 860px) {
    #logo {
        display: none;
    }
}


/* --- Hero Carousel --- */
.hero-carousel {
    position: relative;
    height: 400px;
    width: 100%;
    margin: 0 auto;
    overflow: hidden;
    background-color: #000;
    box-shadow: inset 0 0 100px rgba(0, 0, 0, 0.8), 0 10px 20px rgba(0, 0, 0, 0.3);
}

/* Reduced height for single-image carousels */
.hero-carousel:not(:has(.carousel-track-container)),
.hero-carousel:not(:has(.carousel-slide:nth-child(2))) {
    height: 300px;
}

@media (max-width: 768px) {
    .hero-carousel {
        height: 250px;
    }

    .hero-carousel:not(:has(.carousel-track-container)),
    .hero-carousel:not(:has(.carousel-slide:nth-child(2))) {
        height: 200px;
    }
}

.carousel-track-container {
    height: 100%;
    width: 100%;
}

.carousel-track {
    padding: 0;
    margin: 0;
    list-style: none;
    height: 100%;
    display: flex;
    transition: transform 0.5s ease-in-out;
}

.carousel-slide {
    min-width: 100%;
    height: 100%;
    background-position: center center;
    background-size: cover;
    background-repeat: no-repeat;
    background-attachment: scroll;
    box-shadow: inset 0 0 80px rgba(0, 0, 0, 0.6);
    /* Parallax handled by JS */
}

@media (max-width: 860px) {
    .carousel-slide {
        background-position: center center;
        background-size: cover;
    }
}

.carousel-slide img {
    display: none;
}

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    border: none;
    color: white;
    font-size: 1.2rem;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    opacity: 0;
    transition: background 0.3s, opacity 0.3s;
}

.hero-carousel:hover .carousel-btn {
    opacity: 1;
}

.carousel-btn:hover {
    background: rgba(0, 0, 0, 0.8);
}

.prev-btn {
    left: 20px;
}

.next-btn {
    right: 20px;
}


/* --- News Row --- */
.front-news {
    min-height: auto;
    /* Allow content to dictate height */
    display: flex;
    align-items: center;
    justify-content: center;
    padding-top: 40px;
}

.front-news-container {
    width: 60%;
    min-height: auto;
    margin-bottom: 20px;
}

@media (max-width: 860px) {
    .front-news-container {
        width: 90%;
    }
}

.front-news-container h2 {
    font-weight: 300;
    font-size: 30px;
    font-family: var(--font-body2);
    color: var(--lsfd-red);
    margin-top: 20px;
    margin-bottom: 20px;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 2px;
}

@media (max-width: 768px) {
    .front-news-container h2 {
        font-size: 24px;
        letter-spacing: 1px;
    }
}

.career-page-bg {
    background-color: #e5e9eb;
    width: 100%;
}

.content-wrapper {
    max-width: 950px;
    margin: 0 auto;
    padding: 0 0 40px 0;
    text-align: center;
    border-radius: 0;
}

.content-wrapper .content-section {
    margin-bottom: 30px;
}

.content-wrapper p {
    color: #353333;
    line-height: 1.625;
    font-size: 18px;
    font-style: normal;
    font-weight: 300;
    text-align: left;
}

.content-wrapper ul {
    text-align: left;
    margin-left: 60px;
    margin-top: 20px;
    margin-bottom: 30px;
    list-style-type: disc;
}

.content-wrapper li {
    font-size: 18px;
    font-weight: 300;
    color: #353333;
    line-height: 1.625;
    margin-bottom: 5px;
    padding-left: 10px;
}

@media (max-width: 768px) {
    .content-wrapper {
        padding: 0 20px 40px 20px;
    }

    .content-wrapper p,
    .content-wrapper li {
        font-size: 16px;
    }

    .content-wrapper ul {
        margin-left: 30px;
    }
}

.cta-link {
    display: inline-block;
    color: var(--lsfd-red);
    font-weight: 500;
    font-size: 24px;
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin: 40px auto 20px auto;
    transition: all 0.3s ease;
    width: 100%;
}

.cta-link:hover {
    color: var(--lsfd-red-hover);
    text-decoration: underline;
}

@media (max-width: 768px) {
    .cta-link {
        font-size: 18px;
        letter-spacing: 1px;
        margin: 30px auto 15px auto;
    }
}


/* --- Quick Links Row --- */
.row.darkgrey.quick {
    background-color: #353333;
    padding: 20px 0 30px 0;
    overflow: hidden;
    /* Contains floated columns */
}

.quick .wrapper.left {
    max-width: 920px;
    margin: 0 auto;
    display: block;
    clear: both;
}

.footer-headline h2 {
    margin: 20px 0 40px 0 !important;
    color: var(--text-light);
    font-family: var(--font-body);
    font-weight: 300;
    font-size: 24px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.quick .column.four {
    float: left;
    width: 21%;
    margin-right: 5%;
    margin-bottom: 25px;
}

.quick .column.four:last-child {
    margin-right: 0;
}

.quick p {
    font-size: 16px;
    color: var(--text-light);
    line-height: 1.8;
}

.quick strong {
    display: inline-block;
    font-family: var(--font-body);
    font-weight: normal;
    margin-bottom: 0;
    font-size: 1rem;
    text-transform: uppercase;
}

.quick a {
    text-decoration: none;
    font-weight: 300;
    color: #ffffff;
    font-size: 1rem;
    transition: color 0.3s;
}

.quick a:hover {
    color: #eceff0;
    text-decoration: none;
}

/* --- Mobile Header Bar --- */
.mobile-header-bar {
    display: none;
    background-color: var(--lsfd-grey);
    padding: 10px 25px;
    justify-content: center;
    align-items: center;
}

@media (max-width: 860px) {
    .mobile-header-bar {
        display: flex;
    }
}

/* --- Mobile Menu Toggle --- */
.menu-toggle {
    display: flex;
    flex-direction: column;
    justify-content: space-around;
    width: 30px;
    height: 25px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 1500;
}

.menu-toggle span {
    width: 30px;
    height: 3px;
    background: white;
    border-radius: 10px;
    transition: all 0.3s linear;
    position: relative;
    transform-origin: center;
    display: block;
    margin: 4px 0;
}

/* Animation for active state (X) */
.menu-toggle.active span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

.menu-toggle.active span:nth-child(2) {
    opacity: 0;
    transform: scale(0);
}

.menu-toggle.active span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

@media screen and (max-width: 860px) {
    .quick .column.four {
        float: none;
        width: 100%;
        margin-right: 0;
        text-align: left;
        padding: 0 5%;
    }

    .menu-toggle {
        display: flex;
    }

    .main-nav {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        background-color: var(--lsfd-grey);
        z-index: 99;
        overflow-y: auto;
        padding-top: 150px;
        /* Push menu down below header */
    }

    .main-nav.active {
        display: block;
    }

    .main-nav .container {
        flex-direction: column;
        height: auto;
        gap: 0;
        padding: 0;
    }

    .main-nav.active .container {
        padding-top: 35px;
    }

    .main-nav #navleft,
    .main-nav #navright {
        width: 100%;
        flex: none;
        justify-content: center;
    }

    .main-nav ul.menu {
        flex-direction: column;
        width: 100%;
        height: auto;
    }

    .main-nav ul.menu>li {
        width: 100%;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        display: block;
    }

    .main-nav ul.menu>li>a {
        padding: 20px;
        text-align: center;
        font-size: 16px;
        width: 100%;
        display: block;
        color: white;
        transition: all 0.3s ease;
    }

    .main-nav ul.menu>li>a:hover {
        background-color: white;
        color: var(--lsfd-red);
    }

    .dropdown-item {
        flex-direction: column;
        height: auto;
        display: block;
    }

    .main-nav ul.dropdown-menu-right,
    .main-nav ul.dropdown-menu-left {
        position: static;
        width: 100%;
        display: none;
        background-color: rgba(255, 255, 255, 0.05);
        box-shadow: none;
        padding: 0;
    }

    .dropdown-item.open>ul {
        display: flex;
    }

    .dropdown-menu-right li a,
    .dropdown-menu-left li a {
        color: white;
        text-align: center;
        padding: 15px;
        background-color: transparent;
        transition: all 0.3s ease;
    }

    .dropdown-menu-right li a:hover,
    .dropdown-menu-left li a:hover {
        background-color: white;
        color: var(--lsfd-red);
    }

    /* Keep parent menu item highlighted when hovering submenu */
    .dropdown-item:hover>a,
    .dropdown-item.open>a {
        background-color: white;
        color: var(--lsfd-red);
    }
}

/* --- Footer --- */
.main-footer {
    background-color: #ffffff;
    color: var(--lsfd-grey);
    padding: 40px 0;
    font-size: 0.85rem;
}

.footer-content {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0;
}

.footer-content>* {
    display: flex;
    align-items: center;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.footer-content>*:not(:last-child)::after {
    content: "|";
    margin: 0 7px;
    color: var(--lsfd-grey);
}

.footer-content a {
    color: var(--lsfd-grey);
    text-decoration: none;
    transition: all 0.3s;
}

@media (max-width: 768px) {
    .footer-content {
        flex-direction: column;
        text-align: center;
    }
}