@import url('https://fonts.googleapis.com/css2?family=Dancing+Script:wght@700&family=Inter:wght@400;500;600;700&family=Montserrat:wght@600;700;800;900&display=swap');

:root {
    /* Color Palette */
    --color-bg: #FFFFFF;
    --color-text: #1A1A1A;
    --color-text-muted: #64748B;
    --color-primary: #0084A1;
    /* Southern Hills Teal */
    --color-primary-dark: #006880;
    --color-secondary: #F8FAFC;
    --color-accent: #FFFFFF;
    --color-border: #E2E8F0;
    --color-footer-bg: #006880; /* Dark Teal instead of Navy to prevent washing out the logo */

    /* Typography */
    --font-heading: 'Montserrat', sans-serif;
    --font-body: 'Inter', sans-serif;
    --font-accent: 'Dancing Script', cursive;

    /* Spacing */
    --spacer: 1rem;
    --section-padding: 8rem 2rem; /* Increased for breathing room */

    /* Transitions */
    --transition-fast: all 0.3s ease;
}

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

body {
    font-family: var(--font-body);
    color: var(--color-text);
    background-color: var(--color-bg);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.2;
}

.accent-text {
    font-family: var(--font-accent);
    color: var(--color-primary);
    font-size: 1.5em;
    font-weight: 400;
    margin-bottom: -10px;
    display: block;
}

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

ul {
    list-style: none;
}

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

/* Layout Utilities */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.section {
    padding: var(--section-padding);
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 1.125rem 2.5rem;
    border-radius: 50px; /* Pill shaped */
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition-fast);
    border: 2px solid transparent;
}

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

.btn-primary:hover {
    background-color: var(--color-primary-dark);
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(0, 132, 161, 0.3);

}

.btn-outline {
    background-color: rgba(255, 255, 255, 0.1);
    border: 2px solid white;
    color: white;
    font-weight: 600;
    backdrop-filter: blur(5px);
}

.btn-outline:hover {
    background-color: white;
    color: var(--color-primary);
    transform: translateY(-2px);
}

main {
    padding-top: 73px;
    /* Fixed header height */
}

/* Hero Section */
.hero {
    min-height: calc(100vh - 73px);
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background-image: url('assets/optimized/northpointe-church-fellowship-hall-meal.jpg');
    background-size: cover;
    background-position: center;
    position: relative;
    padding: 0 2rem;
    color: var(--color-accent);
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.75);
    /* Darker overlay for better contrast */
    z-index: 1;
}

.hero-content {
    max-width: 800px;
    z-index: 2;
}

.hero h1 {
    font-size: clamp(3rem, 8vw, 5rem);
    margin-bottom: 1.5rem;
    color: #FFFFFF;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

.hero p {
    font-size: 1.25rem;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 2.5rem;
    text-shadow: 0 1px 5px rgba(0, 0, 0, 0.3);
}

/* Header */
header {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--color-border);
    z-index: 1000;
    padding: 1rem 0;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

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

.nav-links {
    display: flex;
    gap: 2rem;
}

.nav-links a:hover {
    opacity: 0.7;
}

/* Footer */
footer {
    background-color: var(--color-footer-bg);
    color: white;
    padding: 5rem 2rem 0;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
}

.footer-top {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr;
    gap: 3rem;
    padding-bottom: 3rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-brand {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.footer-brand img {
    height: 50px;
    width: auto;
}

.footer-brand p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.95rem;
}

.footer-section h3 {
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    font-weight: 600;
}

.footer-section ul {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.footer-section a {
    color: rgba(255, 255, 255, 0.8);
    transition: var(--transition-fast);
    font-size: 0.95rem;
}

.footer-section a:hover {
    color: white;
    padding-left: 5px;
}

.footer-contact p {
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
}

.social-links {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

.social-links a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    transition: var(--transition-fast);
}

.social-links a:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-3px);
}

.social-links svg {
    width: 20px;
    height: 20px;
    fill: white;
}

.footer-bottom {
    padding: 2rem 0;
    text-align: center;
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
}

@media (max-width: 768px) {
    .footer-top {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
}

.sermon-card:hover img {
    transform: scale(1.05);
}

/* Mobile Menu */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    gap: 4px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
}

.mobile-menu-toggle span {
    width: 25px;
    height: 3px;
    background-color: var(--color-primary);
    transition: var(--transition-fast);
    border-radius: 2px;
}

.mobile-menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

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

.mobile-menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -6px);
}

/* Responsive Design */
@media (max-width: 768px) {

    /* Mobile Navigation */
    .mobile-menu-toggle {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: 73px;
        right: -100%;
        width: 100%;
        max-width: 300px;
        height: calc(100vh - 73px);
        background: white;
        flex-direction: column;
        padding: 2rem;
        gap: 1.5rem;
        box-shadow: -5px 0 15px rgba(0, 0, 0, 0.1);
        transition: right 0.3s ease-in-out;
        overflow-y: auto;
    }

    .nav-links.active {
        right: 0;
    }

    .nav-links a {
        font-size: 1.1rem;
        padding: 0.5rem 0;
        border-bottom: 1px solid var(--color-border);
    }

    /* Hero Adjustments */
    .hero {
        min-height: 70vh;
        height: auto;
        padding: 4rem 1.5rem 3rem;
        /* Extra top padding to avoid header */
    }

    .hero h1 {
        font-size: clamp(2rem, 8vw, 3rem) !important;
    }

    .hero p {
        font-size: 1rem !important;
    }

    .hero-btns {
        flex-direction: column;
        gap: 1rem;
        width: 100%;
    }

    .hero-btns a {
        width: 100%;
        text-align: center;
    }

    /* Section Padding */
    .section {
        padding: 3rem 1rem !important;
    }

    .container {
        padding: 0 1rem;
    }

    /* Grid Layouts */
    .footer-top {
        grid-template-columns: 1fr !important;
        gap: 2rem !important;
    }

    /* Two-column grids to single column */
    [style*="grid-template-columns: 1fr 1fr"] {
        grid-template-columns: 1fr !important;
        gap: 2rem !important;
    }

    /* Ministry sections */
    #ChildrensMinistry,
    #ConnectionGroups {
        grid-template-columns: 1fr !important;
        gap: 2rem !important;
    }

    /* Image heights */
    [style*="height: 400px"],
    [style*="height: 500px"] {
        height: 300px !important;
    }

    /* Typography */
    h1 {
        font-size: 2rem !important;
    }

    h2 {
        font-size: 1.75rem !important;
    }

    h3 {
        font-size: 1.25rem !important;
    }

    /* Featured Sermon */
    .section [style*="grid-template-columns: 1fr 1fr"] {
        grid-template-columns: 1fr !important;
    }

    /* Form adjustments */
    [style*="grid-template-columns: 1fr 1fr"][style*="gap: 1.5rem"] {
        grid-template-columns: 1fr !important;
    }

    /* Buttons */
    .btn {
        width: 100%;
        text-align: center;
    }
}

@media (max-width: 480px) {

    /* Extra small screens */
    .hero {
        height: 60vh;
    }

    .section {
        padding: 2rem 1rem !important;
    }

    h1 {
        font-size: 1.75rem !important;
    }

    h2 {
        font-size: 1.5rem !important;
    }

    .footer-brand img {
        height: 40px;
    }

    .social-links a {
        width: 35px;
        height: 35px;
    }
}
@media (max-width: 768px) {
    #featured-sermon {
        grid-template-columns: 1fr !important;
    }
}
