/* =========================================
   CSS VARIABLES (BRAND COLORS)
========================================= */
:root {
    --brand-red: #8b0000;
    --brand-red-hover: #6e0000;
    --brand-orange: #ff6600;
    --brand-orange-hover: #e05500;
    
    --text-dark: #222;
    --text-light: #fff;
    --text-header: #5d2e00;
    
    --bg-light: #f7f7f7;
    --bg-dark: #222;
    --bg-card: #f9f9f9;
}

/* =========================================
   GLOBAL STYLES
========================================= */

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: Arial, Helvetica, sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--text-light);
}

img {
    max-width: 100%;
    height: auto; /* Image Safety: Ensures aspect ratio remains intact */
    display: block;
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}


/* =========================================
   BILINGUAL LANGUAGE TOGGLE
========================================= */

/* Automatically hide elements that don't match the active html lang attribute */
html[lang="en"] [lang="es"] { 
    display: none; 
}

html[lang="es"] [lang="en"] { 
    display: none; 
}

/* Styling for the language toggle button in the nav */
.btn-lang {
    background: none;
    border: 1px solid #fff;
    color: #fff;
    padding: 4px 10px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
    margin-left: 15px;
    transition: background 0.3s ease; /* Adds a smooth fade on hover */
}

.btn-lang:hover {
    background: rgba(255, 255, 255, 0.2);
}


/* =========================================
   CONTAINERS
========================================= */

.content-container,
.contact-container,
.footer-content,
.specials-grid,
.values-grid {
    width: 90%;
    max-width: 1200px;
    margin: auto;
}

/* =========================================
   HEADER
========================================= */

.site-header {
    /* Warm Amber/Gold Gradient     background: linear-gradient(135deg, #FFC107 0%, #FFD54F 100%); */

    background: linear-gradient(135deg, #a1c4fd 0%, #fbc2eb 100%);
    
    /* Subtle Ribbon/Swirl Pattern Overlay 
    background-image: 
        radial-gradient(circle at 100% 50%, rgba(255, 255, 255, 0.3) 20%, transparent 20%),
        radial-gradient(circle at 0% 50%, rgba(255, 255, 255, 0.3) 20%, transparent 20%),
        linear-gradient(135deg, #FFC107 0%, #FFD54F 100%);
    */ 
 
    /* Text and Layout */
    color: var(--text-header);
    padding: 20px 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    border-bottom: 3px solid #FFA000;
}

.site-footer {
    background: linear-gradient(135deg, #a1c4fd 0%, #fbc2eb 100%);
}

.logo {
    display: flex;
    align-items: center; 
    gap: 15px;            
}

.logo-image {
    width: 70px;         
    height: auto;
    border-radius: 16px;
    border: 1px solid #aaaaaa;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.25);
}

.logo h1 {
    margin: 0;
    color: var(--brand-red); 
}

.logo p {
    font-size: 0.9rem;
    margin-top: 5px;
}

.main-nav {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.main-nav a {
    color: var(--text-header);
    font-weight: 600;
    padding: 10px 15px;
    text-decoration: none;
    transition: color 0.3s ease;
}

.main-nav a:hover, 
.main-nav a:focus-visible,
.main-nav a.active {
    color: var(--brand-red); 
    text-decoration: underline;
    outline: none;
}

/* =========================================
   HERO SECTION
========================================= */

.hero {
    min-height: 550px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.hero-overlay {
    background-color: rgba(0, 0, 0, 0.55);
    color: var(--text-light);
    text-align: center;
    padding: 50px;
    width: 90%;
    max-width: 700px;
    border-radius: 8px;
}

.hero h2 {
    font-size: 3rem;
    margin-bottom: 20px;
}

.hero p {
    font-size: 1.2rem;
    margin-bottom: 30px;
}


/* =========================================
   PAGE HERO 
========================================= */

.page-hero {
    background-color: #261C14; 
    background-image: none; 
    color: #F5F5F5; 
    text-align: center;
    padding: 100px 20px;
    border-bottom: 3px solid #D84315; 
}

.page-hero h2 {
    font-size: 3rem;
    margin-bottom: 20px;
    color: #FFECB3 !important; 
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.6); 
}

.page-hero p {
    max-width: 700px;
    margin: auto;
    font-size: 1.2rem;
    font-weight: 500; 
    line-height: 1.5;
    color: #E0E0E0; 
}

/* =========================================
   BUTTONS
========================================= */

.btn-primary,
.btn-secondary {
    display: inline-block;
    padding: 16px 32px;
    font-size: 1.1rem;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 1px;
    text-decoration: none;
    border-radius: 50px;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    transition: background-color 0.3s ease, transform 0.2s ease, color 0.3s ease;
}

.btn-primary {
    background-color: var(--brand-red);
    color: var(--text-light);
    box-shadow: 0 4px 15px rgba(211, 47, 47, 0.4);
}

.btn-primary:hover,
.btn-primary:focus-visible {
    background-color: var(--brand-red-hover);
    color: var(--text-light);
    transform: scale(1.02);
    outline: 2px solid var(--text-dark);
    outline-offset: 2px;
}

.btn-secondary {
    background-color: var(--text-dark);
    color: var(--text-light);
}

.btn-secondary:hover,
.btn-secondary:focus-visible {
    background-color: #111;
    color: var(--text-light);
    transform: scale(1.02);
    outline: 2px solid var(--text-dark);
    outline-offset: 2px;
}

/* =========================================
   SECTIONS
========================================= */

section {
    padding: 70px 5%;
}

section h2 {
    margin-bottom: 25px;
    font-size: 2.2rem;
    text-align: center;
}


/* =========================================
   GALLERY
========================================= */

.gallery-main {
    padding: 80px 20px;
    background-color: var(--text-light); 
    text-align: center;
}

.gallery-main h2 {
    font-size: 2.2rem;
    color: var(--brand-red);
    margin-bottom: 40px;
    text-transform: uppercase;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.gallery-card {
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08);
    aspect-ratio: 1 / 1;
    background-color: #f4f4f4;
}

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

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

.gallery-card h3 {
    margin: 20px 0 10px;
}

.gallery-card p {
    padding: 0 20px;
}


/* =========================================
   CONTENT LAYOUTS
========================================= */

.content-container {
    display: flex;
    align-items: center;
    gap: 50px;
    flex-wrap: wrap;
}

.content-container.reverse {
    flex-direction: row-reverse;
}

.text-content,
.image-content {
    flex: 1;
    min-width: 300px;
}

.text-content p {
    margin-bottom: 20px;
}

.image-content img {
    border-radius: 8px;
}

/* =========================================
   VALUES SECTION
========================================= */

.values-section {
    background-color: var(--bg-light);
}

.values-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 30px;
}

.value-card {
    background-color: var(--text-light);
    padding: 30px;
    border-radius: 8px;
    text-align: center;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.value-card h3 {
    margin-bottom: 15px;
    color: var(--brand-red);
}

/* =========================================
   TIMELINE
========================================= */

.timeline {
    max-width: 900px;
    margin: auto;
}

.timeline-item {
    display: flex;
    gap: 30px;
    margin-bottom: 40px;
    align-items: flex-start;
}

.timeline-year {
    background-color: var(--brand-red);
    color: var(--text-light);
    padding: 12px 20px;
    border-radius: 4px;
    font-weight: bold;
    min-width: 100px;
    text-align: center;
}

.timeline-content h3 {
    margin-bottom: 10px;
}

/* =========================================
   FIND THE TRAILER
========================================= */

.find-the-trailer-title-section {
    background-image: url('../images/food-truck-front-bg.webp'); 
    background-size: cover;
    background-position: center;
    min-height: 400px; /* Responsive height fix */
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    margin-bottom: 40px;
}

.title-overlay {
    background-color: rgba(0, 0, 0, 0.6); 
    padding: 30px 40px;
    border-radius: 8px;
}

.title-overlay h1 {
    color: var(--text-light);
    text-transform: uppercase;
    margin: 0;
    font-size: 2.5rem;
    letter-spacing: 2px;
}

.locations-section {
    max-width: 1200px;
    margin: 0 auto 60px auto;
    padding: 0 20px;
    text-align: center;
}

.locations-section h2 {
    font-size: 2rem;
    margin-bottom: 30px;
    text-transform: uppercase;
}

.schedule-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    justify-items: center;
}

.schedule-card {
    background-color: var(--bg-card);
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 25px;
    width: 100%;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.schedule-card .day {
    font-size: 1.5rem;
    font-weight: bold;
    color: #d32f2f; 
    margin: 0;
}

.schedule-card .date {
    font-size: 1.2rem;
    font-weight: bold;
    color: var(--text-dark);
}

.schedule-card .location-name {
    font-size: 1.1rem;
    font-weight: 600;
    margin-top: 10px;
}

.schedule-card .address {
    color: #666;
    font-size: 0.95rem;
}

.schedule-card .time {
    font-weight: bold;
    color: var(--text-dark);
    margin: 10px 0;
}

.btn-order {
    display: inline-block;
    background-color: #d32f2f; 
    color: var(--text-light);
    padding: 10px 20px;
    text-decoration: none;
    border-radius: 4px;
    font-weight: bold;
    margin-top: auto; 
    transition: background-color 0.3s ease;
}

.btn-order:hover,
.btn-order:focus-visible {
    background-color: #b71c1c;
    outline: 2px solid var(--text-dark);
    outline-offset: 2px;
}

/* =========================================
   HOURS & LOCATION
========================================= */

.hours-location {
    background-color: var(--bg-light);
    display: flex;
    justify-content: center;
    gap: 80px;
    flex-wrap: wrap;
    text-align: center;
}

.hours ul li,
.location p {
    margin-bottom: 10px;
}

/* =========================================
   CONTACT PAGE
========================================= */

.contact-container {
    display: flex;
    gap: 50px;
    flex-wrap: wrap;
}

.contact-info,
.contact-form-container {
    flex: 1;
    min-width: 320px;
}

.info-block {
    margin-bottom: 30px;
}

.info-block h3 {
    margin-bottom: 10px;
    color: var(--brand-red);
}

.hours-list li {
    margin-bottom: 8px;
}

/* =========================================
   FORM STYLES
========================================= */

.contact-form {
    margin-top: 20px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 14px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 1rem;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: 2px solid var(--brand-orange);
    border-color: transparent;
}

.form-group textarea {
    resize: vertical;
}

/* =========================================
   MAP
========================================= */

.map-container {
    max-width: 1200px;
    margin: auto;
    border-radius: 8px;
    overflow: hidden;
}

/* =========================================
   CTA
========================================= */

.cta {
    background-color: var(--brand-red);
    color: var(--text-light);
    text-align: center;
}

.cta h2 {
    margin-bottom: 20px;
}

.cta p {
    margin-bottom: 30px;
    font-size: 1.1rem;
}

/* =========================================
   FOOTER
========================================= */

.site-footer {
    background-color: var(--bg-dark);
    color: var(--text-light);
    padding-top: 50px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    gap: 40px;
    flex-wrap: wrap;
    padding-bottom: 40px;
}

.footer-content h3 {
    margin-bottom: 15px;
    color: var(--brand-orange);
}

.footer-content li {
    margin-bottom: 10px;
}

.footer-bottom {
    border-top: 1px solid #444;
    text-align: center;
    padding: 20px;
    font-size: 0.9rem;
}

/* =========================================
   CUSTOM BACKGROUND (MOBILE PERFORMANCE FIX)
========================================= */

.main-content {
    background-image: url('../images/trailer_angle_view.avif');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: scroll; /* Mobile safe default */
}

@media (hover: hover) and (pointer: fine) {
    .main-content {
        background-attachment: fixed;
    }
}

/* Make sections readable over image */

.specials,
.about-preview,
.hours-location,
.cta {
    background-color: rgba(255, 255, 255, 0.85);
}

/* =========================================
   RESPONSIVE DESIGN
========================================= */

@media (max-width: 768px) {
    .site-header {
        flex-direction: column;
        text-align: center;
        gap: 15px;
        padding: 15px 5%;
    }

    .main-nav {
        flex-wrap: nowrap;
        overflow-x: auto;
        justify-content: flex-start;
        width: 100%;
        -webkit-overflow-scrolling: touch;
        padding-bottom: 5px;
        scrollbar-width: none; 
        
        /* Gradient mask creates a smooth fade on the right 15% of the navigation */
        -webkit-mask-image: linear-gradient(to right, black 85%, transparent 100%);
        mask-image: linear-gradient(to right, black 85%, transparent 100%);
    }

    /* Hide scrollbar for Chrome, Safari, and Edge */
    .main-nav::-webkit-scrollbar {
        display: none; 
    }

    /* Spacer item so the last link ("Contact") scrolls completely past the fade zone */
    .main-nav::after {
        content: "";
        min-width: 15%; 
        flex-shrink: 0; /* Ensures the end spacer never collapses */
        display: block;
    }

    .main-nav a {
        white-space: nowrap; /* Prevents link text from breaking to a second line */
        font-size: 0.9rem; 
        padding: 8px 12px;
        flex-shrink: 0; /* Keeps button padding crisp across all viewport widths */
    }

    /* Existing mobile layout rules */
    .hero h2,
    .page-hero h2 {
        font-size: 2.2rem;
    }

    .hero p,
    .page-hero p {
        font-size: 1rem;
    }

    .timeline-item {
        flex-direction: column;
    }

    .timeline-year {
        width: fit-content;
    }

    section {
        padding: 50px 5%;
    }
}
