/* ==========================================================================
   CSS Variables & Design System
   ========================================================================== */
:root {
    /* Color Palette */
    --bg-main: #f7f4ef; /* Lighter cream instead of the rose-tinted #e0d7d1 */
    --bg-white: #ffffff;
    --primary: #37618e;
    --gold: #e0a12f;
    --terracotta: #37618e; /* Re-mapped to primary blue so large accent blocks use the new blue */
    --accent: #e0a12f;
    --text-dark: #2d2d2d;
    --text-light: #555555;
    
    /* Typography */
    --font-heading: 'Lora', serif;
    --font-body: 'Inter', sans-serif;
    
    /* Layout */
    --max-width: 1200px;
    --nav-height: 94px;
    
    /* Shadows & Transitions */
    --shadow-sm: 0 2px 8px rgba(0,0,0,0.05);
    --shadow-md: 0 4px 12px rgba(0,0,0,0.08);
    --shadow-lg: 0 8px 24px rgba(0,0,0,0.12);
    --transition: all 0.3s ease;
}

/* ==========================================================================
   Reset & Base Styles
   ========================================================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-body);
    color: var(--text-dark);
    background-color: var(--bg-main);
    line-height: 1.6;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 500;
    line-height: 1.2;
    margin-bottom: 1rem;
    color: var(--text-dark);
}

p {
    margin-bottom: 1rem;
    color: var(--text-light);
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* ==========================================================================
   Utility Classes
   ========================================================================== */
.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 1.5rem;
}

.section-padding {
    padding: 5rem 0;
}

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

.bg-white {
    background-color: var(--bg-white);
}

.bg-accent {
    background-color: var(--terracotta);
    color: var(--bg-white);
}

.bg-accent h2, .bg-accent h3, .bg-accent h4, .bg-accent p {
    color: var(--bg-white);
}

.text-center {
    text-align: center;
}

.divider {
    height: 3px;
    width: 60px;
    background-color: var(--primary);
    margin: 1.5rem 0 2rem;
}

.text-center .divider {
    margin-left: auto;
    margin-right: auto;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.8rem 1.8rem;
    border-radius: 4px;
    font-weight: 500;
    text-align: center;
    cursor: pointer;
    font-family: var(--font-body);
    transition: var(--transition);
    border: 2px solid transparent;
}

.btn-primary {
    background-color: var(--primary);
    color: var(--bg-white);
}

.btn-primary:hover {
    background-color: #1a4f38;
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-outline {
    background-color: transparent;
    color: var(--primary);
    border-color: var(--primary);
}

.btn-outline:hover {
    background-color: var(--primary);
    color: var(--bg-white);
}

.bg-accent .btn-outline {
    color: var(--bg-white);
    border-color: var(--bg-white);
}

.bg-accent .btn-outline:hover {
    background-color: var(--bg-white);
    color: var(--terracotta);
}

/* Animations */
.fade-in-up {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.fade-in-up.appear {
    opacity: 1;
    transform: translateY(0);
}

/* ==========================================================================
   Navigation
   ========================================================================== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--nav-height);
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.nav-container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 1.5rem;
    height: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--primary);
}

.nav-links {
    display: flex;
    list-style: none;
    align-items: center;
    gap: 2rem;
}

.nav-links a:not(.btn) {
    font-weight: 500;
    color: var(--text-dark);
    position: relative;
}

.nav-links a:not(.btn)::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--gold);
    transition: var(--transition);
}

.nav-links a:not(.btn):hover::after {
    width: 100%;
}

.nav-btn {
    padding: 0.5rem 1.2rem;
}

.mobile-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
}

.bar {
    display: block;
    width: 25px;
    height: 3px;
    margin: 5px auto;
    transition: var(--transition);
    background-color: var(--text-dark);
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero {
    min-height: calc(100vh - var(--nav-height));
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: url('images/banner.PNG') center/cover no-repeat;
    background-color: var(--gold); /* Fallback */
    margin-top: var(--nav-height);
    padding: 4rem 1rem;
}

.hero-placeholder-label {
    position: absolute;
    bottom: 20px;
    right: 20px;
    background: rgba(0,0,0,0.5);
    color: white;
    padding: 8px 12px;
    font-size: 0.8rem;
    border-radius: 4px;
    z-index: 2;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(36, 102, 75, 0.7), rgba(0, 0, 0, 0.4));
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    color: var(--bg-white);
    max-width: 800px;
    padding: 0 1.5rem;
}

.hero-content h1 {
    color: var(--bg-white);
    font-size: 4rem;
    margin-bottom: 1rem;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.service-time {
    font-size: 1.5rem;
    font-weight: 500;
    color: var(--accent);
    margin-bottom: 2rem;
    text-shadow: 0 1px 3px rgba(0,0,0,0.3);
}

.hero-contact {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 3rem;
}

.hero-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--bg-white);
    font-size: 1.1rem;
}

.hero-link:hover {
    color: var(--gold);
}

.hero-btn {
    font-size: 1.1rem;
    padding: 1rem 2.5rem;
}

/* ==========================================================================
   Hero Section Typography & Gradient Text
   ========================================================================== */
.hero-content .verse-text {
    font-family: 'Cormorant Garamond', serif;
    font-weight: 300;
    font-size: 3.5rem;
    font-style: italic;
    line-height: 1.2;
    color: var(--bg-white);
    margin-bottom: 1rem;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.verse-citation {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 400;
    font-style: normal;
    display: block;
    margin-top: 1.5rem;
}

.accent-text {
    color: var(--accent);
    /* Remove text shadow from the accent color so it pops more cleanly */
    text-shadow: none;
    font-weight: 400; /* Give it just a touch more weight to stand out */
}

/* ==========================================================================
   Mission Statement
   ========================================================================== */
.mission {
    text-align: center;
    background-color: var(--primary);
}

.mission-text {
    font-size: 2.5rem;
    color: var(--bg-white);
    max-width: 800px;
    margin: 0 auto 1.5rem;
    line-height: 1.4;
}

.drawn-underline {
    position: relative;
    display: inline-block;
    z-index: 1;
}

.drawn-underline::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 8px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 10' preserveAspectRatio='none'%3E%3Cpath d='M2,7 Q50,2 98,7' fill='none' stroke='%23e0a12f' stroke-width='3' vector-effect='non-scaling-stroke' stroke-linecap='round'/%3E%3C/svg%3E");
    background-size: 100% 100%;
    background-repeat: no-repeat;
    z-index: -1;
}

.coming-soon {
    font-style: italic;
    color: rgba(255, 255, 255, 0.8);
}

/* ==========================================================================
   Our Values (W.O.R.D.)
   ========================================================================== */
.values-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.value-card {
    background: var(--bg-white);
    padding: 2.5rem 2rem;
    border-radius: 8px;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    border-bottom: 4px solid var(--gold);
}

.value-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
    border-color: var(--primary);
}

.value-icon {
    color: var(--primary);
    margin-bottom: 1.5rem;
}

.value-icon svg {
    width: 48px;
    height: 48px;
    stroke: var(--primary);
}
/* ==========================================================================
   Our Beliefs
   ========================================================================== */
.beliefs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.belief-card {
    background: var(--bg-white);
    padding: 2.5rem 2rem;
    border-radius: 8px;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    border-top: 4px solid var(--primary);
    display: flex;
    flex-direction: column;
}

.belief-card h3 {
    color: var(--primary);
    margin-bottom: 1rem;
    font-size: 1.4rem;
}

.belief-card p {
    flex-grow: 1;
    margin-bottom: 1.5rem;
}

.scripture-ref {
    font-size: 0.9rem;
    font-style: italic;
    color: var(--gold);
    font-weight: 500;
}

.belief-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}


/* ==========================================================================
   Photo Strip
   ========================================================================== */
.photo-strip {
    width: 100%;
    overflow: hidden;
    background: var(--bg-main);
    padding: 2rem 0;
}

.photo-grid {
    display: flex;
    gap: 1rem;
    width: 100%;
    padding: 0 1rem;
}

.photo-item {
    flex: 1;
    height: 300px;
    object-fit: cover;
    border-radius: 12px;
    min-width: 0; /* Prevents flex items from overflowing if image is large */
}

/* ==========================================================================
   Meet the Pastor
   ========================================================================== */
.pastor-card {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    background: var(--bg-white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
}

.pastor-image-wrapper {
    height: 100%;
    min-height: 400px;
    overflow: hidden;
    display: flex;
}

.pastor-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.pastor-content {
    padding: 3rem;
    padding-left: 0;
}

.subtitle {
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 0.85rem;
    color: var(--primary);
    font-weight: 600;
    display: block;
    margin-bottom: 0.5rem;
}

/* ==========================================================================
   Sermons
   ========================================================================== */
.sermon-intro {
    max-width: 600px;
    margin: 0 auto 3rem;
    font-size: 1.1rem;
}

.spotify-embed {
    max-width: 800px;
    margin: 0 auto 3rem;
    border-radius: 12px;
    box-shadow: var(--shadow-lg);
    background: #191414; /* Spotify dark bg */
}

/* ==========================================================================
   Plan Your Visit
   ========================================================================== */
.visit-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.visit-info {
    margin-top: 2rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

.info-item h4 {
    color: var(--gold);
    margin-bottom: 0.5rem;
}

.form-placeholder {
    background: var(--bg-white);
    border-radius: 12px;
    padding: 3rem;
    text-align: center;
    color: var(--text-dark);
    box-shadow: var(--shadow-lg);
}

.form-placeholder-inner {
    border: 2px dashed #ccc;
    padding: 4rem 2rem;
    border-radius: 8px;
}

.small-text {
    font-size: 0.85rem;
    color: var(--text-light);
    margin-top: 0.5rem;
}

/* ==========================================================================
   FAQ Section
   ========================================================================== */
.faq {
    background-color: var(--bg-main);
}

.faq-accordion {
    max-width: 800px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.faq-item {
    background-color: var(--bg-white);
    border-radius: 8px;
    box-shadow: var(--shadow-sm);
    overflow: hidden;
    transition: var(--transition);
}

.faq-question {
    width: 100%;
    text-align: left;
    padding: 1.5rem 2rem;
    background: none;
    border: none;
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: 500;
    color: var(--primary);
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: var(--transition);
}

.faq-question:hover {
    color: var(--text-dark);
}

.faq-icon {
    font-size: 1.5rem;
    color: var(--gold);
    transition: transform 0.3s ease;
    font-weight: 300;
}

.faq-item.active .faq-icon {
    transform: rotate(45deg);
    color: var(--terracotta);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.1, 0.7, 0.1, 1), padding 0.4s ease;
    padding: 0 2rem;
    background-color: var(--bg-white);
}

.faq-item.active .faq-answer {
    max-height: 500px; /* arbitrary max-height for transition to work */
    padding-bottom: 1.5rem;
}

.faq-answer p {
    margin: 0;
    color: var(--text-dark);
}

.faq-answer em {
    color: var(--terracotta);
    font-style: italic;
    font-size: 0.9rem;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.footer {
    background-color: var(--primary);
    color: var(--bg-white);
    padding-top: 4rem;
}

.footer h3, .footer h4 {
    color: var(--bg-white);
}

.footer p {
    color: rgba(255, 255, 255, 0.8);
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-bottom {
    background-color: #274769; /* Darker shade of the primary blue */
    padding: 1.5rem 0;
    text-align: center;
}

.footer-bottom p {
    margin: 0;
    font-size: 0.9rem;
}

/* ==========================================================================
   Media Queries
   ========================================================================== */
@media (max-width: 992px) {
    .pastor-card {
        grid-template-columns: 1fr;
        gap: 0;
    }
    
    .pastor-content {
        padding: 3rem;
    }
    
    .visit-grid {
        grid-template-columns: 1fr;
    }
    
    .hero-content h1 {
        font-size: 3rem;
    }
}

@media (max-width: 768px) {
    .mobile-toggle {
        display: block;
    }
    
    .nav-links {
        position: fixed;
        left: -100%;
        top: var(--nav-height);
        flex-direction: column;
        background-color: var(--bg-white);
        width: 100%;
        height: calc(100vh - var(--nav-height));
        text-align: center;
        transition: 0.3s;
        box-shadow: var(--shadow-md);
        padding-top: 2rem;
        gap: 1.5rem;
    }
    
    .nav-links.active {
        left: 0;
    }
    
    .hero-content h1 {
        font-size: 2.5rem;
    }
    
    .hero-contact {
        flex-direction: column;
        gap: 1rem;
        align-items: center;
    }
    
    .photo-grid {
        flex-wrap: wrap;
    }
    
    .photo-item {
        flex: 1 0 calc(50% - 1rem);
        height: 200px;
    }
    
    .mission-text {
        font-size: 1.8rem;
    }
}

@media (max-width: 480px) {
    .photo-item {
        flex: 1 0 100%;
    }
    
    .visit-info {
        grid-template-columns: 1fr;
    }
    
    .form-placeholder {
        padding: 1.5rem;
    }
}
