/* ===== PROFESSIONAL STYLING FOR ACK ST. MATHEWS CATHEDRAL, Karen-West ===== */
/* ===== GLOBAL STYLES ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* --- Primary Colors (inspired by the navy/blue trim) --- */
    --primary-dark: #1A2A4F;     /* Deep church navy */
    --primary-light: #2F416B;    /* Softer navy */

    /* --- Accent Colors (from roof red + sky blue + natural tones) --- */
    --accent-red: #C94A44;       /* Brick roof red */
    --accent-orange: #E8A248;    /* Warm golden highlight */
    --accent-blue: #6DB2E3;      /* Soft sky-blue trim */
    --accent-green: #27AE60;     /* Keep your original green (works for success/alerts) */

    /* --- Text Colors (improved contrast) --- */
    --text-light: #FFFFFF;       /* Pure white for dark backgrounds */
    --text-dark: #1A1A1A;        /* Neutral dark for readability */
    --text-gray: #5A6C7D;        /* Soft neutral gray */

    /* --- Background Colors (cream from church walls) --- */
    --bg-light: #F3E9D7;         /* Warm cream from building walls */
    --bg-lighter: #FFFFFF;       /* Clean white for sections/cards */

    /* --- Effects --- */
    --shadow: 0 5px 20px rgba(0, 0, 0, 0.10);
    --shadow-hover: 0 15px 40px rgba(0, 0, 0, 0.15);
    --border-radius: 12px;
    --transition: all 0.3s ease;


    /* Font Families */
    --heading-font: 'Playfair Display', 'Times New Roman', serif;
    --body-font: 'Open Sans', 'Arial', sans-serif;
}

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

/* Headings */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--heading-font);
    font-weight: 600;
    line-height: 1.3;
    margin-bottom: 0.5em;
}

h1 {
    font-size: 2.5rem;
    font-weight: 700;
}

h2 {
    font-size: 2rem;
    font-weight: 600;
}

h3 {
    font-size: 1.5rem;
    font-weight: 600;
}

h4 {
    font-size: 1.25rem;
    font-weight: 600;
}

h5 {
    font-size: 1.1rem;
    font-weight: 600;
}

h6 {
    font-size: 1rem;
    font-weight: 600;
}

/* Body scroll lock when menu is open */
body.menu-open {
    overflow: hidden;
}

/* ===== NAVBAR STYLES ===== */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-light) 100%);
    padding: 0 20px;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    height: 70px;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.2);
}

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

.logo a {
    color: var(--accent-orange);
    font-size: 1.4rem;
    font-weight: 700;
    text-decoration: none;
    transition: var(--transition);
    letter-spacing: 0.5px;
    font-family: var(--heading-font);
}

.logo a:hover {
    color: var(--bg-light);
    transform: translateY(-1px);
}

/* Nav links (desktop) */
.nav-links {
    display: flex;
    gap: 10px;
    align-items: center;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-links li a {
    color: var(--text-light);
    padding: 12px 18px;
    transition: var(--transition);
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    position: relative;
    text-decoration: none;
    display: block;
    font-family: var(--body-font);
}

.nav-links li a::after {
    content: '';
    position: absolute;
    bottom: 8px;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--accent-orange);
    transition: var(--transition);
    transform: translateX(-50%);
}

.nav-links li a:hover {
    color: var(--accent-orange);
    background: rgba(255, 255, 255, 0.1);
}

.nav-links li a:hover::after {
    width: 70%;
}

/* Dropdown */
.dropdown {
    position: relative;
}

.dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: var(--primary-light);
    padding: 10px 0;
    border-radius: var(--border-radius);
    min-width: 220px;
    box-shadow: var(--shadow);
    border: 1px solid rgba(255, 255, 255, 0.1);
    animation: dropdownFade 0.3s ease;
    z-index: 1001;
    list-style: none;
}

@keyframes dropdownFade {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.dropdown-menu li a {
    display: block;
    padding: 12px 20px;
    color: var(--text-light);
    white-space: nowrap;
    font-size: 0.9rem;
    text-transform: none;
    border-radius: 0;
    text-decoration: none;
    font-family: var(--body-font);
}

.dropdown-menu li a:hover {
    background: var(--accent-orange);
    color: var(--text-light);
}

.dropdown-menu li a::after {
    display: none;
}

/* Show dropdown on hover for desktop */
@media (min-width: 769px) {
    .dropdown:hover .dropdown-menu {
        display: block;
    }
}

/* ===== HAMBURGER MENU FIXES ===== */
.hamburger {
    display: none;
    cursor: pointer;
    background: transparent;
    border: none;
    padding: 8px;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
    z-index: 1002;
    position: relative;
}

.hamburger .bar {
    display: block;
    width: 25px;
    height: 3px;
    background-color: var(--text-light);
    transition: var(--transition);
    border-radius: 2px;
    transform-origin: center;
}

/* Hamburger to X Animation */
.hamburger.active .bar:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.hamburger.active .bar:nth-child(2) {
    opacity: 0;
    transform: translateX(-10px);
}

.hamburger.active .bar:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

/* ===== MAIN CONTENT AREA ===== */
main {
    min-height: calc(100vh - 200px);
    margin-top: 70px;
    font-family: var(--body-font);
}

/* ===== FOOTER STYLES ===== */
.footer {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-light) 100%);
    color: var(--text-light);
    padding: 60px 0 0;
    position: relative;
}

.footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--accent-orange), var(--accent-red), var(--accent-blue));
}

.footer-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.footer-section {
    margin-bottom: 30px;
}

.footer-section h3 {
    color: var(--accent-orange);
    margin-bottom: 25px;
    font-size: 1.3rem;
    font-weight: 700;
    position: relative;
    display: inline-block;
    font-family: var(--heading-font);
}

.footer-section h3::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 40px;
    height: 2px;
    background: var(--accent-orange);
}

.footer-section p, 
.footer-section li {
    margin-bottom: 12px;
    line-height: 1.7;
    font-size: 1rem;
    font-family: var(--body-font);
}

.footer-section ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-section ul li {
    margin-bottom: 8px;
}

.footer-section a {
    color: var(--text-light);
    transition: var(--transition);
    text-decoration: none;
    font-family: var(--body-font);
}

.footer-section a:hover {
    color: var(--accent-orange);
    padding-left: 5px;
}

.footer-section i {
    width: 20px;
    margin-right: 10px;
    color: var(--accent-orange);
}

.social-links {
    margin-top: 25px;
    display: flex;
    gap: 15px;
}

.social-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    font-size: 1.1rem;
    color: var(--text-light);
    transition: var(--transition);
    text-decoration: none;
}

.social-links a:hover {
    background: var(--accent-orange);
    color: var(--text-light);
    transform: translateY(-3px);
}

.footer-bottom {
    background: rgba(0, 0, 0, 0.3);
    padding: 25px 0;
    text-align: center;
    margin-top: 50px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-bottom p {
    margin: 8px 0;
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.95rem;
    font-family: var(--body-font);
}

.footer-bottom a {
    color: var(--accent-orange);
    text-decoration: none;
    font-weight: 600;
    font-family: var(--body-font);
}

.footer-bottom a:hover {
    text-decoration: underline;
}

/* Paragraph and text elements */
p {
    font-family: var(--body-font);
    margin-bottom: 1rem;
    line-height: 1.7;
}

strong, b {
    font-weight: 600;
    font-family: var(--body-font);
}

em, i {
    font-style: italic;
    font-family: var(--body-font);
}

/* ===== MOBILE STYLES - CRITICAL FIXES ===== */

/* Small devices (landscape phones, 577px to 768px) */
@media (max-width: 768px) {
    .navbar {
        padding: 0 15px;
        height: 60px;
    }
    
    .logo {
        width: 100%;
        justify-content: space-between;
        align-items: center;
    }
    
    .logo a {
        font-size: 1.1rem;
        flex: 1;
    }
    
    .hamburger {
        display: flex;
        position: relative;
        top: 0;
        right: 0;
        margin: 0;
    }
    
    .nav-links {
        display: none;
        position: fixed;
        top: 60px;
        left: 0;
        height: calc(100vh - 60px);
        width: 100%;
        background: var(--primary-dark);
        flex-direction: column;
        padding: 20px 0;
        gap: 0;
        overflow-y: auto;
        z-index: 1001;
        margin: 0;
    }
    
    .nav-links.show {
        display: flex;
        animation: slideIn 0.3s ease-out;
    }
    
    @keyframes slideIn {
        from {
            opacity: 0;
            transform: translateX(-100%);
        }
        to {
            opacity: 1;
            transform: translateX(0);
        }
    }
    
    .nav-links li {
        width: 100%;
        text-align: left;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        margin: 0;
    }
    
    .nav-links li:last-child {
        border-bottom: none;
    }
    
    .nav-links a {
        display: block;
        padding: 16px 20px;
        font-size: 1rem;
        border-radius: 0;
        text-align: left;
        width: 100%;
    }
    
    .nav-links a::after {
        display: none;
    }
    
    /* Dropdown menu styles for mobile */
    .dropdown-menu {
        position: static;
        display: none;
        background: rgba(255, 255, 255, 0.05);
        width: 100%;
        box-shadow: none;
        border: none;
        border-radius: 0;
        animation: none;
        padding: 0;
        margin: 0;
    }
    
    .dropdown-menu.show {
        display: block;
        animation: slideDown 0.3s ease-out;
    }
    
    @keyframes slideDown {
        from {
            opacity: 0;
            max-height: 0;
        }
        to {
            opacity: 1;
            max-height: 500px;
        }
    }
    
    .dropdown-menu li a {
        padding: 14px 20px 14px 40px;
        font-size: 0.95rem;
        border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    }
    
    .dropdown-menu li:last-child a {
        border-bottom: none;
    }
    
    .dropdown > a::after {
        content: ' ▾';
        float: right;
        transition: transform 0.3s ease;
    }
    
    .dropdown > a.active::after {
        transform: rotate(180deg);
    }
    
    main {
        margin-top: 60px;
    }
    
    .footer-container {
        grid-template-columns: 1fr;
        gap: 30px;
        text-align: center;
    }
    
    .footer-section h3::after {
        left: 50%;
        transform: translateX(-50%);
    }
    
    .social-links {
        justify-content: center;
    }

    /* Mobile font size adjustments */
    h1 {
        font-size: 2rem;
    }
    
    h2 {
        font-size: 1.75rem;
    }
    
    h3 {
        font-size: 1.4rem;
    }
}

/* Extra small devices (portrait phones, less than 576px) */
@media (max-width: 575px) {
    .navbar {
        padding: 0 10px;
    }
    
    .logo a {
        font-size: 1rem;
    }
    
    .nav-links {
        padding: 15px 0;
    }
    
    .nav-links a {
        padding: 14px 15px;
        font-size: 0.95rem;
    }
    
    .dropdown-menu li a {
        padding: 12px 15px 12px 35px;
    }
    
    .footer {
        padding: 40px 0 0;
    }
    
    .footer-container {
        padding: 0 15px;
        gap: 25px;
    }
    
    .footer-section h3 {
        font-size: 1.2rem;
        margin-bottom: 20px;
    }
    
    .footer-bottom {
        padding: 20px 15px;
        margin-top: 30px;
    }
    
    .footer-bottom p {
        font-size: 0.9rem;
    }

    /* Extra small font size adjustments */
    h1 {
        font-size: 1.8rem;
    }
    
    h2 {
        font-size: 1.5rem;
    }
    
    h3 {
        font-size: 1.3rem;
    }
}

/* Medium devices (tablets, 769px to 1200px) */
@media (min-width: 769px) and (max-width: 1200px) {
    .navbar {
        padding: 0 20px;
    }
    
    .nav-links {
        gap: 8px;
    }
    
    .nav-links li a {
        padding: 10px 15px;
        font-size: 0.9rem;
    }
    
    .logo a {
        font-size: 1.2rem;
    }
}

/* Large devices (desktops, 1201px and up) */
@media (min-width: 1201px) {
    .navbar {
        padding: 0 40px;
    }
    
    .nav-links {
        gap: 15px;
    }
    
    .nav-links li a {
        padding: 15px 20px;
    }
}