/* --- Import Google Fonts --- */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;700&family=Open+Sans:wght@400;700;800&display=swap');

/* --- Define CSS Variables (Root Scoped) --- */
:root {
    --sinclair-red: #AC1A2F;
    --sinclair-black: #000000;
    --sinclair-charcoal: #616366;
    --font-primary: 'Montserrat', sans-serif;
    --font-secondary: 'Open Sans', sans-serif;
}

/* --- Apply Base Styles --- */
body {
     opacity: 0;
    transition: opacity 0.15s ease-in;
    font-family: var(--font-secondary);
    font-size: 16px;
    line-height: 24px;
    color: var(--sinclair-black);
}

body.fonts-loaded {
    opacity: 1;
}

/* =================================================================== */
/* COMPONENT: NAVIGATION BAR                                           */
/* =================================================================== */
/* --- Header & Navigation --- */
.navbar {
    background-color: var(--sinclair-red);
    padding-top: 0;
    padding-bottom: 0;
}
/* --- MENU STYLES --- */

/* 1. Mobile View (collapsed) menu links */
.navbar-dark .navbar-collapse .navbar-nav .nav-link {
    color: white;
    padding: 1rem 1rem; /* Add vertical padding for better spacing */
    border-bottom: 1px solid rgba(255, 255, 255, 0.15); /* Add a subtle separator */
}
/* 2. Desktop view */
@media (min-width: 1200px) { /* xl breakpoint */
    .navbar-dark .navbar-nav .nav-link {
        color: white;
        font-weight: 700; 
        text-transform: uppercase;
        font-size: 0.8rem;
        line-height: 1rem;
        transition: border-color 0.2s ease-in-out;
        border-bottom: 3px solid transparent;
        height: 80px;         
        display: flex;          
        align-items: center;    
        justify-content: center;
        padding: 0 1rem;       
        width: 165px;
    }
}

/* Group the active, focus, and hover states for consistent styling. */
.navbar-dark .navbar-nav .nav-link.active,
.navbar-dark .navbar-nav .nav-link:hover,
.navbar-dark .navbar-nav .nav-link:focus {
    color: white; /* Keep text white on all states */
    border-bottom-color: white; /* Changes the border from transparent to white */
    outline: none; /* Removes the default browser outline on focus */
}

/* Styles for the action buttons in the collapsed mobile menu */
.navbar-collapse .d-xl-none .btn-nav {
    text-align: center;
    padding: 0.75rem 1rem;
    border-radius: 4px;
}

/* Adjusts the mobile menu button's focus to be an inner shadow */
.navbar-toggler:focus {
    box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.75);
}

/* Custom Nav Action Buttons */
.btn-nav {
    position: relative;
    color: white;
    text-transform: uppercase;
    font-size: 0.8rem;
    font-weight: 700;
    padding: 0.5rem;
    text-decoration: none;
    transition: background-color 0.3s ease;
}
.btn-nav:focus {
    z-index: 2;
    border-color: white !important;
}
.btn-nav-explore {
    background-color: var(--sinclair-black);
}
.btn-nav-request {
    background-color: #3d3f42; /* Darker than charcoal */
}
.btn-nav-apply {
    background-color: var(--sinclair-charcoal);
}


.btn-nav:hover {
    background-color: white;
    color: var(--sinclair-red); 
}
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-primary);
    font-weight: 700;
    color: var(--sinclair-red);
}



/* --- Custom Rounded Rectangular Button System --- */
/* 1. Base Button Style */
.btn-custom {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2rem; 
    min-width: 350px;
    font-family: var(--font-primary);
    font-weight: 700;
    font-size: 1.3rem;
    line-height: 1.3rem;
    text-transform: uppercase;
    text-decoration: none;
    border-radius: 8px;
    border: 2px solid transparent;
    transition: all 0.3s ease;
    cursor: pointer;
}

/* 2. Button Color Modifiers & Hover States */
.btn-primary {
    background-color: var(--sinclair-red);
    border-color: var(--sinclair-red);
    color: white;
}
.btn-primary:hover,
.btn-primary:focus {
    background-color: #8e1526;
    border-color: var(--sinclair-red);
    color: white;
}
.btn-primary:active {
    background-color: black !important;
    color: var(--sinclair-red);
    border-color: var(--sinclair-red);
}
.btn-outline-primary {
    background-color: white;
    color: var(--sinclair-red);
    border-color: var(--sinclair-red);
}
.btn-outline-primary:hover,
.btn-outline-primary:focus {
    background-color: var(--sinclair-red);
    border-color: var(--sinclair-red);
    color: white;
}
.btn-outline-primary:active {
    background-color: black !important;
    color: var(--sinclair-red);
    border-color: var(--sinclair-red);
}
.btn-dark {
    background-color: var(--sinclair-black);
    color: white;
}
.btn-dark:hover {
    background-color: #333;
    color: white;
}
.btn-outline-dark {
    background-color: white;
    color: var(--sinclair-black);
    border-color: var(--sinclair-black);
}
.btn-outline-dark:hover {
    background-color: var(--sinclair-black);
    color: white;
}

/* Keyboard nav helper: High-contrast focus style for all custom buttons */
a.btn-custom.btn-primary:focus,
a.btn-custom.btn-outline-primary:focus,
a.btn-custom.btn-dark:focus,
a.btn-custom.btn-outline-dark:focus{
    outline: none;
    box-shadow: 0 0 0 1px white, 0 0 0 2px var(--sinclair-black) !important;
}

/* 3. SVG Icon Styling */
.btn-custom .btn-icon-svg {
    margin-left: 0.75rem;
    width: 18px;
    height: 18px;
}
.btn-custom .icon-shape {
    transform: scale(1.5) !important;
    transform-origin: center !important;
}
.btn-primary .icon-bg { 
    fill: white; 
}
.btn-primary .icon-shape { 
    fill: var(--sinclair-red); 
}
.btn-outline-primary .icon-bg { 
    fill: var(--sinclair-red);
}
.btn-outline-primary .icon-shape { 
    fill: white; 
}
.btn-outline-primary:hover .icon-bg { 
    fill: white; 
}
.btn-outline-primary:hover .icon-shape { 
    fill: var(--sinclair-red); 
}
.btn-dark .icon-bg { 
    fill: white; 
}
.btn-dark .icon-shape { 
    fill: var(--sinclair-black); 
}
.btn-outline-dark .icon-bg { 
    fill: var(--sinclair-black); 
}
.btn-outline-dark .icon-shape { 
    fill: white; 
}
.btn-outline-dark:hover .icon-bg { 
    fill: white; 
}
.btn-outline-dark:hover .icon-shape { 
    fill: var(--sinclair-black); 
}


/* --- Section Divider Line --- */
.section-divider {
    margin: 0;
    border-color: white;
    border-top-width: .5rem; /* Controls the thickness of the line */
    opacity: 1; /* Overrides Bootstrap's default opacity for consistency */
}

/* =================================================================== */
/* COMPONENT: PAGE HERO                                                */
/* =================================================================== */
.page-hero {
    color: white;
    min-height: 100vh; /* Default height for inner pages */
    background-size: cover;
    background-position: start;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}
/* Styles for content within any hero */
.page-hero h1 {
    font-size: 3.5rem;
    font-weight: 700;
    color: white;
}

.page-hero .lead {
    font-size: 1.25rem;
}
/***** Specific background images for each page *****/
#hero-index {
    min-height: 100vh; /* Homepage hero is taller */
    background-image: linear-gradient(rgba(0,0,0,0.5), rgba(0,0,0,0.5)), url('../images/start-hero-bg.jpg');
}

#hero-investment {
    background-image: linear-gradient(rgba(0,0,0,0.5), rgba(0,0,0,0.5)), url('../images/investment-hero-bg.jpg');
}

#hero-pathways {
    background-image: linear-gradient(rgba(0,0,0,0.5), rgba(0,0,0,0.5)), url('../images/pathways-hero-bg.jpg');
}

#hero-experience {
    background-image: linear-gradient(rgba(0,0,0,0.5), rgba(0,0,0,0.5)), url('../images/experience-hero-bg.jpg');
}

#hero-launch {
    background-image: linear-gradient(rgba(0,0,0,0.5), rgba(0,0,0,0.5)), url('../images/launch-hero-bg.jpg');
}

#questions-hero {
    min-height: 100vh; 
    background-image: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)), url('../images/sinclair-grad.jpg');
}
#apply-hero {
    min-height: 100vh; 
    background-image: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)), url('../images/sinclair-rooftop.jpg');
}

#program-explorer-hero {
    background-image: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)), url('../images/sinclair-grads-outside.jpg');
    min-height: 60vh; 
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}
}
#program-explorer-hero h1 {
    font-size: 3.5rem;
    font-weight: 700;
    color: white;
}

/* Responsive adjustments for all heroes */
@media (max-width: 768px) {
    .page-hero {
        min-height: 500px;
    }
    .page-hero h1 {
        font-size: 2.5rem;
    }
}

/* =================================================================== */
/* VALUE & AFFORDABILITY PAGE STYLES                                   */
/* =================================================================== */
/* --- Tuition Chart Section --- */
#tuition-comparison {
    background-color: var(--sinclair-black);
    color: white;
    padding: 5rem 0 3rem 0;
}
#tuition-comparison h2, 
#tuition-comparison h3,
#tuition-comparison h4 {
    color: white;
}
.chart-text-block {
    text-align: center;
    margin-bottom: 2rem;
}
.chart-container {
    height: 450px;
    display: flex;
    align-items: flex-end;
    justify-content: space-around;
    border-bottom: 1px solid #6c757d;
    width: 100%;
}
@media (min-width: 992px) {
    .chart-wrapper {
        position: relative; 
    }
    .chart-text-block {
        position: absolute;
        top: 80px;
        left: 0;
        width: 75%;
        text-align: left;
        z-index: 10;
        margin-bottom: 0; 
    }
}
.bar-group {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 24%;
    height: 100%;
    justify-content: flex-end; 
}
.bar {
    width: 90%;
    max-width: 80px;
    border-radius: 4px 4px 0 0;
    position: relative;
    overflow: hidden;
}
.bar-red {
    background-color: var(--sinclair-red);
}
.bar-gray {
    background-color: #6c757d;
}
.bar .price {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    text-align: center;
    font-weight: 700;
    font-size: 0.9rem;
    padding-bottom: 0.5rem;
}
.bar-group .label {
    font-weight: 700;
    font-size: 0.8rem;
    margin-bottom: 0;
    margin-top: 0.3rem;
    text-transform: uppercase;
}
.bar-group .sub-label {
    font-size: 0.7rem;
    color: #adb5bd;
    line-height: 1.2;
    text-align: center;
    min-height: 2.4em; /* This forces alignment by standardizing height */
}
.bar, .bar-labels {
    width: 90%;
    max-width: 80px;
}
.bar-labels {
    margin-top: 0.5rem;
    text-align: center;
}
.bar-group .label {
    margin-top: 0;
}
.footnote {
    font-size: 0.7rem;
    color: #adb5bd;
    text-align: left;
}

/* --- Tuition Rates Section --- */
#tuition-rates {
    background-color: var(--sinclair-black);
    padding-bottom: 5rem;
}

.rate-box {
    background-color: white;
    border-radius: 8px;
    padding: 1.5rem;
    display: flex;
    align-items: center;
    margin: 1rem;
    justify-content: center;
}

.rate-box:last-child {
    margin-bottom: 0;
}
.rate-icon {
    flex-shrink: 0; /* Prevents the icon from shrinking */
}
.rate-icon svg {
    width: 60px;
    height: 60px;
    fill: var(--sinclair-red); /* This colors your SVG icon red */
}
.rate-text {
    margin-left: 2rem;
}
.rate-text h3 {
    color: var(--sinclair-black);
    font-size: 2.25rem;
    margin-bottom: 0;
    line-height: 1;
}
.rate-text p {
    color: var(--sinclair-charcoal);
    margin-bottom: 0;
}
/* --- Financial Aid Section --- */
#financial-aid {
    padding: 5rem 0;
}
#financial-aid h2, 
#financial-aid h4 {
    color: var(--sinclair-black);
}   

/* =================================================================== */
/* PATHWAYS PAGE STYLES                                                */
/* =================================================================== */

/* --- In-Demand Section Chart Styles --- */
.value-chart {
    display: flex;
    justify-content: center;
    align-items: flex-end;
    gap: 0.75rem;
    min-height: 350px;
}

.chart-label {
    color: var(--sinclair-red);
    font-weight: 700;
    text-align: center;
    line-height: 1.1;
    font-size: 1.1rem;
}

.chart-bar {
    background-color: #6c757d;
    width: 75px;
    border-radius: 4px 4px 0 0;
    display: flex;
    justify-content: center;
    align-items: flex-end;
    overflow: hidden;
}

.bar-value {
    color: white;
    font-weight: 700;
    white-space: nowrap;
    writing-mode: vertical-rl;
    transform: rotate(180deg);
    padding-top: 0.5rem;
    font-size: 1.2rem;
}
/* --- In-Demand Section Grid Layout --- */
.in-demand-grid {
    display: grid;
    grid-template-columns: 1fr; /* A single column for mobile stacking */
    gap: 2rem; /* The space between items when stacked on mobile */
}

/* On desktop, switch to a 2x2 grid */
@media (min-width: 992px) {
    .in-demand-grid {
        grid-template-columns: 7fr 5fr; /* Creates a 7/12 and 5/12 column split */
        grid-template-areas:
            "text-main  image"
            "chart      text-sub";
        gap: 1rem 3rem; /* Sets row and column gaps */
        align-items: end; /* Aligns the bottom row content */
    }

    /* Assigns each HTML div to a named area in the grid */
    .grid-text-main { grid-area: text-main; }
    .grid-image     { grid-area: image; }
    .grid-chart     { grid-area: chart; }
    .grid-text-sub  { grid-area: text-sub; }
}

/* --- Reusable Split Section Component --- */
.split-section .container-fluid {
    padding: 0;
}

/* On desktop, use flexbox for a side-by-side layout */
@media (min-width: 992px) {
    .split-section .container-fluid {
        display: flex;
    }
}

.split-section .image-column {
    padding: 0;
}

.split-section .image-column img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.split-section .text-column {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 3rem;
    color: white; /* Default text color for all split sections */
}

/* Unique styles for the program list in the "unlock-potential" section */
#unlock-potential .program-list {
    list-style: none;
    padding-left: 1.5rem;
}

#unlock-potential .program-list li {
    position: relative;
    padding-left: 1.25rem;
    margin-bottom: 0.5rem;
}

#unlock-potential .program-list li::before {
    content: '•';
    position: absolute;
    left: 0;
    color: white;
    font-size: 1.5rem;
    line-height: 1.2rem;
}

/* =================================================================== */
/* EXPERIENCE PAGE STYLES                                                */
/* =================================================================== */

/* --- Experience Page: Flexibility/Modality Section --- */
.modality-icon {
    text-align: center;
    padding: 1rem;
}

.modality-icon img {
    height: 150px; /* Controls the size of the SVG icon */
    margin-bottom: 0.5rem;
   filter: brightness(0) invert(1);
}

.modality-icon p {
    font-family: var(--font-primary);
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 0;
}


/* --- Reusable Content Block Utilities (if not already defined elsewhere) --- */
.content-block {
    padding: 4rem 0;
}
.content-block-red {
    background-color: var(--sinclair-red);
}
.content-block-dark {
    background-color: var(--sinclair-black);
}
.content-block-gray {
    background-color: var(--sinclair-charcoal);
}


/*Styles for bulleted list on Appl Page */

.list {
  display: inline-block; /* Allows the list to be centered as a block */
  text-align: left;    /* Aligns the text and bullets inside the list to the left */
  padding-left: 0;     /* Removes the default browser padding */
}


/* --- Footer: Keep Exploring and CTA Sections --- */
#keep-exploring {
    padding: 4rem 0;
    /* This adds a semi-transparent dark overlay */
    background-image: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)), url('../images/welcomeCenter.jpg');
    background-size: cover;
    background-position: center;
}
#cta {
    padding: 4rem 0;
    /* This uses Sinclair Red with an increased opacity for a stronger color */
    background-image: linear-gradient(rgba(172, 26, 47, 0.85), rgba(172, 26, 47, 0.85)), url('../images/cta-background.jpg');
    background-size: cover;
    background-position: center;
}

/* --- Footer: Divider Line --- */
.footer-divider {
    margin: 0;
    border-color: lightgray;
    border-top-width: 0.25rem; /* Controls the thickness of the line */
    opacity: 1; /* Overrides Bootstrap's default opacity for consistency */
}

/* ------------------------------*/
/* --- Program Explorer Page --- */
/*--------------------------------*/
/* Adjust the hero search button for mobile to allow the input field to be larger */
@media (max-width: 767.98px) { /* Applies to screens smaller than Bootstrap's 'md' breakpoint */
    #program-explorer-hero .btn-custom {
        min-width: auto; /* Remove the large fixed minimum width */
        font-size: 1.1rem; /* Adjust font size to better fit the smaller button */
    }
}
/* Custom keyboard focus styles for the hero search bar */
#program-explorer-hero #search-keyword:focus-visible {
    /* Override Bootstrap's default blue border and glow */
    border-color: #ced4da; 
    outline: none;
    /* Add a red inner shadow (inset) for focus */
    box-shadow: inset 0 0 0 2px var(--sinclair-red);
}

#program-explorer-hero .btn-custom:focus-visible {
    /* Override the default button focus style */
    outline: none;
    /* Add a semi-transparent white inner shadow (inset) for focus */
    box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.75);
}
/* --- Updates for the Filter Panel on the new background --- */
.filters-panel {
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    padding: 1.5rem;
    border-radius: 8px;
}

.filters-panel h3 {
    /* CHANGED: Text color is now black */
    color: var(--sinclair-black);
}

.filters-panel .list-group-item {
    background-color: #f8f9fa; /* Match panel background */
    /* CHANGED: Text color is now black */
    color: var(--sinclair-black);
    border-color: #dee2e6;
}

.filters-panel .list-group-item.active {
    background-color: var(--sinclair-black);
    border-color: var(--sinclair-red);
    color: white; /* Ensure active item text is white */
}

.filters-panel .list-group-item:hover {
    background-color: #e9ecef; /* A slightly darker gray for hover */
    color: var(--sinclair-black); /* Add this line to make text black on hover */
}

/* Styles for the mobile filter accordion */
.filters-mobile-toggle a {
    display: flex;
    justify-content: space-between;
    align-items: center;
}


.filter-caret {
    border-style: solid;
    border-color: currentColor; /* This makes the caret match the text color (white or black) */
    border-width: 0 3px 3px 0;  /* Make the lines of the caret thicker */
    display: inline-block;
    padding: 4px;               /* Make the overall icon larger */
    transform: rotate(45deg);
    transition: transform 0.3s ease, margin-top 0.3s ease;
}

/* Rotates the caret to an up arrow when the menu is expanded */
.filters-mobile-toggle a[aria-expanded="true"] .filter-caret {
    transform: rotate(-135deg); /* Up arrow */
    margin-top: -4px;
}


@media (max-width: 991.98px) {
    /* Styles for the mobile accordion button */
    .filters-mobile-toggle .list-group-item.active {
        background-color: #f8f9fa;
        color: var(--sinclair-black);
        border: 2px solid var(--sinclair-red);
        font-weight: 700;
        padding: 0.9rem 1.25rem; /* Increase internal spacing */
    }

    /* When the accordion is open, this prevents the selected item inside from turning black */
    #filters-list .list-group-item.active {
        background-color: #f8f9fa;
        color: var(--sinclair-black);
        border-color: #dee2e6; /* Reset border from active state */
    }
}

/* Hides the empty "undefined" description in the program list widget */
.acalog-program-container {
    display: none;
}

/* --- Program Explorer Card Styles --- */

/* Grid container for the program cards */
.program-grid {
    display: grid;
    /* Create two columns of equal size */
    grid-template-columns: repeat(2, 1fr); 
    gap: 24px; /* Space between the cards */
}

/* Individual program card styling */
.program-card {
    border: 1px solid #dee2e6; /* Matches your filter panel border color */
    background-color: #f8f9fa; /* Matches your filter panel background */
    padding: 24px;
    border-radius: 8px; /* Matches your filter panel border-radius */
    display: flex;
    flex-direction: column; /* Stack content vertically */
    justify-content: space-between; /* Pushes button to the bottom */
    height: 100%; /* Make all cards in a row the same height */
    transition: box-shadow 0.2s ease-in-out, transform 0.2s ease-in-out;
}

.program-card:hover {
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    transform: translateY(-5px);
}

/* Program name styling (inherits h4 style from your file) */
.program-card .program-name {
    font-size: 1.25rem;
    margin-top: 0;
    margin-bottom: 12px;
}

/* Program type styling (e.g., "Type: Associate") */
.program-card .program-type {
    font-size: 1rem;
    color: var(--sinclair-charcoal); /* USE YOUR VARIABLE */
    margin-bottom: 24px;
    flex-grow: 1; /* Allows this element to grow, pushing the button down */
}

/* "View Details" button styling */
.program-card .btn-details {
    background-color: var(--sinclair-red); /* USE YOUR VARIABLE */
    color: #ffffff;
    border: none;
    padding: 12px 20px;
    text-transform: uppercase;
    font-family: var(--font-primary); /* USE YOUR VARIABLE */
    font-weight: 700;
    text-decoration: none;
    text-align: center;
    border-radius: 4px;
    align-self: flex-start; /* Aligns button to the left */
    transition: background-color 0.3s ease;
}

/* Button hover effect */
.program-card .btn-details:hover {
    background-color: #8e1526; /* Matches your .btn-primary:hover color */
    color: #ffffff;
}

/* * Responsive adjustments for smaller screens */
@media (max-width: 991.98px) { /* Bootstrap's 'lg' breakpoint */
    .program-grid {
        /* Switch to a single column on tablets and smaller */
        grid-template-columns: 1fr;
    }
}
        /* --- Sub-Footer Styling --- */
        .sub-footer {
        background-color: #f8f9fa;
        padding: .5rem 0;
        text-align: center;
        font-size: 0.9rem;
        }
        .sub-footer a {
        color: var(--sinclair-dark-gray);
        text-decoration: underline;
        transition: color 0.2s ease;
        }
        .sub-footer a:hover {
        color: var(--sinclair-red);
        }