:root {
    /* Colors */
    --color-primary: #1F5E4F;
    --color-primary-dark: #17483D;
    --color-accent: #D4A437;
    --color-background: #FAFAF7;
    --color-section: #F1F1ED;
    --color-highlight: #E8F2EF;
    --color-text-main: #2B2B2B;
    --color-text-secondary: #6B6B6B;
    --color-white: #FFFFFF;
    --color-secondary-bg: #f3f7f5;
    --color-soft-green-tint: #eef5f1;

    /* Typography */
    --font-heading: "Merriweather", serif;
    --font-body: "Source Sans 3", sans-serif;
    --line-height-base: 1.6;
    --font-size-base: 16px;

    /* Layout */
    --container-width: clamp(1000px, 70vw, 1400px);
    --container-padding: 20px;
    --section-spacing-desktop: 80px;
    --section-spacing-tablet: 70px;
    --section-spacing-mobile: 50px;

    /* Spacing */
    --space-2xs: 4px;
    --space-xs: 8px;
    --space-sm: 12px;
    --space-md: 16px;
    --space-lg: 24px;
    --space-xl: 32px;
    --space-2xl: 48px;
    --space-3xl: 64px;
    --space-4xl: 80px;

    /* Buttons */
    --button-height: 48px;
    --button-height-large: 60px;
    --button-padding-x: 24px;
    --button-padding-y: 14px;

    /* Borders & Radius */
    --border-radius-small: 4px;
    --border-radius-medium: 8px;
    --border-radius-large: 12px;

    /* Shadows */
    --shadow-soft: 0 2px 6px rgba(0, 0, 0, 0.08);
    --shadow-medium: 0 6px 18px rgba(0, 0, 0, 0.12);
}

/* Box sizing */
*,
*::before,
*::after {
    box-sizing: border-box;
}

/* Remote Default Margins */
* {
    margin: 0;
}

/* Smooth scrolling for anchor links */
html {
    scroll-behavior: smooth;
}

/* Base body Styles */
body {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background-color: var(--color-background);
    color: var(--color-text-main);
    font-family: var(--font-body);
    font-size: var(--font-size-base);
    line-height: var(--line-height-base);
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
}

html, body {
    min-height: 100%;
    margin: 0;
}

/* Media Defaults */
img,
picture,
svg,
video {
    display: block;
    max-width: 100%;
}

/* Form elements inherit fonts */
input,
button,
textarea,
select {
    font: inherit;
}

/* Button defaults */
button {
    border: none;
    background: none;
    cursor: pointer;
}

/* Prevent text overflow issues */
h1,
h2,
h3,
h4,
h5,
h6 {
    overflow-wrap: break-word;
}

/* Lists */
ul,
ol {
    list-style: none;
}

/* Links */
a {
    text-decoration: none;
    color: inherit;
}

/* Tables */
table {
    border-collapse: collapse;
    width: 100%;
}

/* =========================================
            Typography Foundation
========================================= */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    color: var(--color-text-main);
    line-height: 1.25;
}

p {
    color: var(--color-text-main);
}

small {
    color: var(--color-text-secondary);
}

/* =========================================
            Layout Foundation
========================================= */
.container {
    width: 100%;
    max-width: var(--container-width);
    padding-left: var(--container-padding);
    padding-right: var(--container-padding);
    margin: 0 auto;
}

.section {
    padding-top: var(--section-spacing-desktop);
    padding-bottom: var(--section-spacing-desktop);
}

.section-alt {
    background-color: var(--color-section);
}

/* =========================================
            Button Foundation
========================================= */
.button {
    display: inline-block;
    align-items: center;
    justify-content: center;

    min-height: var(--button-height);
    padding: var(--button-padding-y) var(--button-padding-x);
    border-radius: var(--border-radius-medium);

    font-family: var(--font-body);
    font-weight: 700;
    text-align: center;

    transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.button:hover {
    transform: translateY(-1px);
}

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

.button-secondary {
    background-color: var(--color-primary);
    color: var(--color-white);
}

/* =========================================
            Hero Section
========================================= */
.hero-band {
    position: relative;
    width: 100%;
    height: clamp(160px, 20vh, 260px);
    background-image: url("../assets/images/church_front_landscape.jpg");
    background-size: cover;
    background-position: center 80%;
    background-repeat: no-repeat;
}

.hero-band-overlay {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    inset: 0;
    background: linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0.35),
        rgba(0, 0, 0, 0.15),
        rgba(0, 0, 0, 0.35)
    );
}

.hero-band-content {
    text-align: center;
    position: relative;
    z-index: 2;
}

.hero-band-title {
    display: inline-block;
    background: rgba(0,0,0,0.55); /* dark translucent pill */
    color: #fff;
    padding: 0.45rem 1rem;
    border-radius: 12px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.45);
    -webkit-text-stroke: 0.04rem rgba(0,0,0,0.45);
    text-shadow: 0 6px 18px rgba(0,0,0,0.5);
    line-height: 1;
    z-index: 4;
    position: relative;
}

@media (max-width: 899px) {
    .section {
        padding-top: var(--section-spacing-mobile);
        padding-bottom: var(--section-spacing-mobile);
    }

    .hero-band,
    .hero-band-overlay {
        height: 150px;
    }

    .hero-band-title {
        padding: 0.25rem 0.6rem;
        border-radius: 8px;
    }
}

/* =========================================
            Navigation
=========================================== */
@media (min-width: 900px) {
    .main-nav {
        background-color: var(--color-primary);
        overflow: hidden;
    }

    .nav-menu {
        position: relative;
        display: flex;
        align-items: center;
        justify-content: center;
        min-height: 72px;
        margin: 0;
        padding: 0;
        list-style: none;
    }

    .nav-item {
        position: relative;
        display: flex;
        z-index: 1;
        padding: 0 24px;
    }

    .nav-item a {
        display: flex;
        align-items: center;
        justify-content: center;
        height: 72px;
        line-height: 1;
        font-family: var(--font-body);
        font-size: 1rem;
        font-weight: 600;
        color: var(--color-white);
        text-decoration: none;
    }

    /* Active item only when nav is not being hovered */
    .nav-menu:not(.is-hovering) .nav-item--active a {
        color: var(--color-text-main);
    }

    /* Currently hovered item */
    .nav-item.is-hovered a {
        color: var(--color-text-main);
    }

    .nav-indicator {
        position: absolute;
        top: 50%;
        left: 0;

        height: 48px;
        width: 0;

        background-color: var(--color-accent);
        border-radius: var(--border-radius-medium);

        transform: translateY(-50%);
        z-index: 0;
    }

    .nav-indicator.is-ready {
        transition: left 0.3s ease, width 0.3s ease;
    }

    .nav-menu-wrap {
        position: relative;
    }

    .nav-toggle {
        display: none;
        align-items: center;
        justify-content: center;
        gap: 8px;

        width: 100%;
        min-height: 64px;
        padding: 0 20px;

        font-family: var(--font-body);
        font-size: 1rem;
        font-weight: 600;
        color: var(--color-white);

        background: none;
        border: none;
        cursor: pointer;
    }

    .nav-toggle:focus-visible {
        outline: 3px solid var(--color-accent);
        outline-offset: -3px;
    }
}

@media (max-width: 899px) {
    .main-nav .container {
        display: flex;
        flex-direction: column;
        align-items: stretch;
        padding-left: 0;
        padding-right: 0;
        background-color: var(--color-primary);
    }

    .nav-toggle {
        display: inline-flex;
        align-items: center;
        justify-content: left;
        gap: 10px;
        width: 100%;
        min-height: 64px;
        padding: 0 20px;
        font-family: var(--font-body);
        font-size: 1rem;
        font-weight: 600;
        color: var(--color-white);
        z-index: 1;

        background: none;
        border: none;
        cursor: pointer;
    }

    .nav-menu-wrap {
        width: 100%;
        max-height: 0;
        overflow: hidden;   
        opacity: 0;
        transition: max-height 0.6s ease, opacity 0.5s ease;
        will-change: max-height, opacity;
        transform-origin: top;
    }

    .nav-menu-wrap.is-open {
        opacity: 1;
        max-height: 1000px;
    }

    .nav-menu {
        display: flex;
        flex-direction: column;
        align-items: stretch;
        justify-content: flex-start;
        min-height: auto;
        padding: 0;
    }

    .nav-item {
        display: block;
        width: 100%;
    }

    .nav-item a {
        display: flex;
        align-items: center;
        justify-content: flex-start;
        width: 100%;
        min-height: 56px;
        padding: 0 20px;
        border-top: 1px solid rgba(255, 255, 255, 0.12);
        color: var(--color-white);
    }

    .nav-item:last-child a {
        border-bottom: 1px solid rgba(255, 255, 255, 0.12);
    }

    .nav-item--active a {
        background-color: var(--color-accent);
        color: var(--color-text-main);
    }

    .nav-item a:hover {
        color: var(--color-text-main);
        background-color: var(--color-accent);
    }

    .nav-indicator {
        display: none;
    }

    /* .nav-toggle-text {
        color: var(--color-background);
        line-height: 1;
    } */

    .nav-toggle-icon {
        color: var(--color-background);
        font-size: 1.25rem;
        line-height: 1;;
    }
}

.site-main {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.site-footer {
    background-color: var(--color-primary);
    color: var(--color-white);
    text-align: center;
    padding: var(--space-md) 0;
    font-size: 0.9rem;
}