/* --- FIREHOUSE MASTER STYLES v5.3 --- */
@import url('https://fonts.googleapis.com/css2?family=Oswald:wght@700&family=Inter:wght@400;600&display=swap');

/* 1. GLOBAL VARIABLES */
:root {
    --color-brand-red: #E6322C;
    --color-brand-red-dark: #b31d18;
    --color-brand-gold: #FAD968;
    --color-dark-charcoal: #1A1A1A; /* Perfectly matches logo file */
    --color-white: #FFFFFF;
    --color-text-dark: #1a1a1a;
    --color-text-muted: #4E4E4E;
    --color-border-subtle: #333333;
    --color-overlay: rgba(0,0,0,0.4);
    --font-heading: 'Oswald', sans-serif;
    --font-body: 'Inter', sans-serif;
    --spacing-xs: 0.5rem;
    --spacing-sm: 0.75rem;
    --spacing-md: 1.25rem;
    --spacing-lg: 1.75rem; /* The Header Gap */
    --border-radius: 4px;
}

/* 2. BASE RESET */
* { box-sizing: border-box; margin: 0; padding: 0; }
body { background-color: var(--color-white); color: var(--color-text-dark); font-family: var(--font-body); line-height: 1.6; }
.container { max-width: 1100px; margin: 0 auto; padding: 0 20px; }

/* 3. HEADER & NAVIGATION */
header { 
    background: #1A1A1A !important;
    padding: 10px 0; 
    border-bottom: 3px solid var(--color-brand-red); 
    margin-bottom: var(--spacing-lg); 
}
.nav-wrapper { display: flex; justify-content: space-between; align-items: center; }
.brand-link { display: flex; align-items: center; text-decoration: none; gap: 12px; }
.nav-logo { height: 60px; width: auto; display: block; }
.brand-text { font-family: var(--font-heading); font-size: 1.8rem; font-weight: 700; color: var(--color-brand-red); text-transform: uppercase; line-height: 1; }
.nav-links { display: flex; gap: 25px; list-style: none; align-items: center; }
.nav-links a, .nav-links a:visited { color: var(--color-white) !important; font-family: var(--font-heading); text-transform: uppercase; font-size: 1rem; text-decoration: none !important; transition: 0.3s; }
.nav-links a:hover { color: var(--color-brand-red) !important; }
.nav-btn { background: var(--color-brand-red); padding: 8px 16px !important; border-radius: var(--border-radius); font-weight: 600; }

/* 4. HERO & INFO STRIP */
.hero { min-height: 350px; padding: 60px 0; background: #000 url('/assets/images/firehouse_hero.jpg') center/contain no-repeat; display: flex; align-items: center; justify-content: center; text-align: center; color: var(--color-white); }
.hero-content { background: var(--color-overlay); padding: 30px 40px; border-radius: 8px; max-width: 800px; width: 90%; }

.info-strip { display: flex !important; flex-direction: row !important; flex-wrap: nowrap !important; justify-content: space-between !important; gap: 20px; width: 100%; padding: 40px 0 10px 0; border-bottom: 1px solid #eee; }
.info-card { flex: 1 !important; text-align: center; padding: 20px; }

/* 5. SPOTLIGHT & POSTER CANVAS */
.spotlight-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: center; background: rgba(0, 0, 0, 0.05); padding: 2.5rem; border-radius: 8px; }
.poster-canvas { aspect-ratio: 1 / 1; width: 100%; background-size: cover; background-position: center; display: flex; flex-direction: column; justify-content: flex-end; border-radius: var(--border-radius); box-shadow: 0 10px 30px var(--color-overlay); }
.poster-content-overlay { padding: 0 15% 6rem 15%; text-align: center; }
.poster-title { font-family: var(--font-heading); color: var(--color-brand-gold); font-size: clamp(1.4rem, 2.5vw, 2rem); text-transform: uppercase; position: relative; top: -0.5rem; margin-bottom: var(--spacing-xs); }
.poster-date {
    font-family: var(--font-body);
    color: var(--color-white);
    font-weight: 700;
    font-size: 0.9rem; 
    text-transform: uppercase;
}
.html-content {
    white-space: normal; /* Allows Google's HTML tags to dictate the flow */
    word-wrap: break-word;
    color: var(--color-text-muted); /* #4E4E4E from your variables */
    font-size: 1.1rem;
    line-height: 1.6;
}

/* Force Google's <br> tags to actually create vertical space */
.html-content br {
    display: block;
    margin-top: 0.75rem;
    content: "";
}

/* Force Links to be visible and branded */
.html-content a {
    color: var(--color-brand-red) !important;
    text-decoration: underline !important;
    font-weight: 700;
}

/* Handle Google's automatic paragraph tags if present */
.html-content p {
    margin-bottom: 1rem;
}

/* Ensure bold text from Google is high-contrast */
.html-content b, .html-content strong {
    color: var(--color-text-dark);
    font-weight: 700;
}

/* 5.5. HOME HISTORY SECTION & CTAs */
.about-ctas { 
    margin-top: var(--spacing-md) !important; 
    padding-bottom: var(--spacing-md); 
}

/* 6. SOCIAL ICONS & FOOTER */
.social-icons-row, .footer-social { display: flex; gap: 15px; margin-top: 10px; }
.social-icons-row img, .footer-social img { width: 30px !important; height: 30px !important; object-fit: contain; }

#site-footer { padding:var(--spacing-md) 0; background: var(--color-dark-charcoal); color: var(--color-white); border-top: 1px solid var(--color-border-subtle); }
#site-footer .container { display: flex; flex-wrap: wrap; justify-content: space-between; }
#site-footer h3 { color: var(--color-brand-red); font-family: var(--font-heading); text-transform: uppercase; margin-bottom: 15px; }

/* 7. TYPOGRAPHY & BUTTONS */
h1, h2 { font-family: var(--font-heading); color: var(--color-brand-red); text-transform: uppercase; margin-bottom: 4px; }
.btn-primary { background: var(--color-brand-red); color: var(--color-white); padding: 12px 24px; text-decoration: none; display: inline-block; font-weight: bold; border-radius: var(--border-radius); }
.important-notice-board { background: var(--color-brand-red); color: var(--color-white); padding: 15px 0; border-bottom: 3px solid var(--color-brand-red-dark); }

/* 8. RESPONSIVE QUERIES */
@media screen and (max-width: 768px) {
    .nav-wrapper { flex-direction: column; gap: 15px; }
    .nav-links { flex-wrap: wrap; justify-content: center; gap: 15px; margin-top: 1rem; }
    .info-strip { flex-wrap: wrap !important; }
    .info-card { flex: 1 1 100% !important; border-bottom: 1px solid #eee; }
    .spotlight-grid { grid-template-columns: 1fr; padding: 1.5rem; }


    /* POSTER MOBILE FIX: Pulling text down away from the logo */
    .poster-canvas { 
        aspect-ratio: auto; 
        min-height: 350px; 
    }
    
    .poster-content-overlay { 
        padding: 0 10% 3rem 10% !important; /* Reduced bottom padding to lower the text */
    }
    
    .poster-title { 
        top: 0 !important; /* Removes the upward shift on mobile only */
        font-size: 1.5rem; 
        margin-bottom: 0.5rem;
    }

    .info-strip { flex-wrap: wrap !important; }
    .info-card { flex: 1 1 100% !important; border-bottom: 1px solid #eee; }
    .spotlight-grid { grid-template-columns: 1fr; padding: 1.5rem; }

/* HERO REFINEMENT: Moving H1 up and separating buttons */
    .hero {
        padding: 40px 0; /* Shaved down vertical padding */
    }

    .hero-content {
        padding: 20px 15px; /* Tighter padding for mobile */
    }

    .hero-content h1 {
        margin-top: -1rem; /* Moves H1 up */
        margin-bottom: 0.5rem;
        font-size: 1.8rem;
    }

    .hero-content p {
        margin-bottom: 1.5rem; /* Creates separation below the text */
        font-size: 1rem;
    }

    .hero-ctas {
        display: flex;
        flex-direction: column; /* Stacks buttons to prevent overlapping */
        gap: 1rem; /* Precise separation between buttons */
        align-items: center;
    }

    .hero-ctas .btn-primary {
        width: 100%; /* Ensures buttons are tap-friendly and uniform */
        max-width: 250px;
    }

}

/* --- ABOUT PAGE Story & History Sections --- */
.two-column-layout {
    display: flex;
    flex-wrap: wrap;
    gap: calc(var(--spacing-unit) * 4);
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px var(--spacing-unit);
}

.story-text {
    flex: 1 1 500px;
}

.story-image {
    flex: 0 1 400px;
    max-width: 400px;
}

.story-image img {
    width: 100%;
    height: auto;
    border-radius: var(--border-radius-default);
    border: 3px solid var(--color-accent);
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}

/* --- Mobile Responsiveness --- */
@media (max-width: 768px) {
    .story-text, .story-image {
        flex: 1 1 100%;
        max-width: 100%;
    }

    /* On mobile, we want the image to always come AFTER the text it describes */
    .story-image.reverse {
        order: 2; /* Moves the first image below the first text block on phones */
    }
    
    .two-column-layout {
        gap: calc(var(--spacing-unit) * 2);
    }
}

/* Team Grid Layout */
.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: calc(var(--spacing-unit) * 2);
    margin-top: calc(var(--spacing-unit) * 2);
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
    padding: 0 var(--spacing-unit);
}

.team-card {
    background: rgba(255, 255, 255, 0.05);
    padding: calc(var(--spacing-unit) * 2);
    border-left: 4px solid var(--color-primary);
    border-radius: var(--border-radius-default);
    transition: transform 0.2s ease;
}

.team-card:hover {
    transform: translateY(-5px);
    background: rgba(255, 255, 255, 0.08);
}

.team-card h4 {
    margin-bottom: 0.5rem;
    color: var(--color-accent); /* Distinguishes names from headers */
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .story-image {
        flex: 1 1 100%; /* Stacks on mobile */
        order: -1; /* Puts image above text on mobile */
    }
}

/* --- Direct Contact Buttons --- */
.contact-actions {
    display: flex;
    flex-wrap: wrap; 
    gap: var(--spacing-md); /* Uses your Master Spacing */
    margin: var(--spacing-md) 0;
    justify-content: flex-start;
}

.btn-contact {
    /* Prevents the full-page span */
    display: inline-flex; 
    align-items: center;
    justify-content: center;
    
    /* Branding */
    padding: 14px 28px;
    border-radius: var(--border-radius);
    font-family: var(--font-heading);
    text-transform: uppercase;
    text-decoration: none !important;
    font-weight: 700;
    min-width: 240px;
    transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Phone Button: Fire Red with White Text */
.btn-phone {
    background-color: var(--color-brand-red) !important;
    color: var(--color-white) !important; /* Fixes invisibility */
    border: 2px solid var(--color-brand-red);
}

/* FB Button: Facebook Blue with White Text */
.btn-facebook {
    background-color: #1877F2 !important;
    color: var(--color-white) !important; /* Fixes invisibility */
    border: 2px solid #1877F2;
}

.btn-contact:hover {
    filter: brightness(1.2);
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

/* Mobile Fix */
@media screen and (max-width: 480px) {
    .btn-contact {
        flex: 1 1 100%;
        max-width: 100%;
    }
}



/* Firehouse Custom Calendar Styles */
.firehouse-calendar-container {
    background-color: #F5EBD8; /* Vintage paper tone */
    padding: 2rem;
    border-radius: 8px;
    margin-top: 3rem;
}

.fh-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    border: 2px solid #141414;
}

.day-header {
    background-color: #1A1A1A;
    color: #FAD968; /* Gold Accent */
    font-family: 'Oswald', sans-serif;
    font-weight: 700;
    text-transform: uppercase;
    text-align: center;
    padding: 10px;
    border: 1px solid #333;
}

.calendar-day {
    min-height: 120px;
    background: #FFF;
    border: 1px solid #DDD;
    padding: 5px;
    position: relative;
}

.day-number {
    font-family: 'Inter', sans-serif;
    font-weight: 700;
    color: #CCC;
    float: right;
}

.event-name {
    font-family: 'Oswald', sans-serif;
    font-weight: 800;
    color: #E6322C; /* Primary Fire Red */
    text-transform: uppercase;
    font-size: 0.9rem;
    display: block;
    margin-top: 15px;
}

.event-time {
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    font-size: 0.75rem;
    color: #1A1A1A;
}

/* Special Saturday Styling: Black Bars */
.day-sat {
    background-color: #f9f9f9;
}

.day-sat .event-name {
    background-color: #141414;
    color: #FFFFFF;
    padding: 4px;
    text-align: center;
}

.footer-text-calendar {
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-align: center;
    margin-top: 20px;
    color: #1A1A1A;
}

/* Additional OR replacement calendar styles */
.fh-visual-calendar-wrapper {
    position: relative;
    width: 100%;
    max-width: 1200px;
    margin: 40px auto;
    /* BACKGROUND IMAGE REFERENCE IS HERE: */
    background: url('/assets/images/monthly-calendar-bg.png') no-repeat center center;
    background-size: contain;
    aspect-ratio: 1100 / 850;
    padding-top: 22%; /* Adjust based on the "Header" height in your PNG */
}

.fh-visual-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    width: 90%; 
    margin: 0 auto;
    height: 68%;
}

.fh-day-cell {
    padding: 8px 4px;
    display: flex;
    flex-direction: column;
}

.fh-event-name {
    font-family: 'Oswald', sans-serif;
    font-weight: 800;
    color: #7B1E1E; /* Firehouse Red */
    text-transform: uppercase;
    font-size: 0.8rem;
    line-height: 1.1;
}

/* Saturday Specific Highlight */
.fh-sat-cell .fh-event-name {
    background-color: #141414; /* Black Bar */
    color: #FFFFFF;
    padding: 3px 5px;
    display: inline-block;
    width: 100%;
}

.fh-event-time {
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    font-size: 0.65rem;
    color: #333;
    display: block;
}