/*
Theme Name: Mary Retreat Centre
Theme URI: https://maryretreatcentre.org
Author URI: https://maryretreatcentre.org
Description: A peaceful and welcoming WordPress theme for Mary Retreat Centre, inspired by faith, serenity, and community.
Version: 1.0.1
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: mrc-theme
Tags: custom-background, custom-logo, custom-menu, featured-images, threaded-comments, translation-ready, church, retreat, christian
*/

/* ==========================================================================
   Base Styles
   ========================================================================== */

:root {
    --primary-blue: #215faf;
    --primary-dark: #1a4c8a;
    --primary-light: #5588DD;
    --white: #FFFFFF;
    --light-gray: #F5F7FA;
    --text-dark: #333333;
    --text-light: #666666;
    --accent-gold: #D4AF37;
}

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

body {
    font-family: 'Montserrat', 'Raleway', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--white);
}

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

a {
    color: var(--primary-blue);
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: var(--primary-dark);
}

/* ==========================================================================
   Typography
   ========================================================================== */

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

h1 {
    font-size: 2.5rem;
}

h2 {
    font-size: 2rem;
}

h3 {
    font-size: 1.75rem;
}

h4 {
    font-size: 1.5rem;
}

h5 {
    font-size: 1.25rem;
}

h6 {
    font-size: 1rem;
}

p {
    margin-bottom: 1.5rem;
}

/* ==========================================================================
   Layout
   ========================================================================== */

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.site-wrapper {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.site-content {
    flex: 1;
}

/* ==========================================================================
   Header
   ========================================================================== */

.site-header,
#masthead {
    background-color: #215faf;
    color: var(--white);
    padding: 1rem 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

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

.site-branding {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.custom-logo {
    max-height: 80px;
    width: auto;
}

.site-title {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--white);
    margin: 0;
    letter-spacing: -0.5px;
}

.site-title a {
    color: var(--white);
}

.site-description {
    font-size: 0.85rem;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.9);
    margin: 0;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

/* ==========================================================================
   Navigation
   ========================================================================== */

.main-navigation {
    display: flex;
    align-items: center;
}

.main-navigation ul {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.main-navigation a {
    color: var(--white);
    font-weight: 500;
    font-size: 1rem;
    padding: 0.5rem 0;
    transition: all 0.3s ease;
    position: relative;
}

.main-navigation a:hover,
.main-navigation a:focus {
    color: var(--accent-gold);
}

.main-navigation a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--accent-gold);
    transition: width 0.3s ease;
}

.main-navigation a:hover::after {
    width: 100%;
}

.menu-toggle {
    display: none;
    background-color: transparent;
    border: 2px solid var(--white);
    color: var(--white);
    padding: 0.5rem 1rem;
    cursor: pointer;
    font-size: 1rem;
}

/* Mobile Menu */
@media (max-width: 768px) {
    .menu-toggle {
        display: block;
    }

    .main-navigation ul {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 100%;
        right: 0;
        background-color: var(--primary-dark);
        padding: 1rem;
        gap: 0;
        min-width: 200px;
    }

    .main-navigation.toggled ul {
        display: flex;
    }

    .main-navigation li {
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

    .main-navigation a {
        display: block;
        padding: 1rem;
    }
}

/* ==========================================================================
   Hero Section
   ========================================================================== */

.hero-section {
    background: linear-gradient(135deg, var(--primary-blue) 0%, var(--primary-dark) 100%);
    color: var(--white);
    padding: 6rem 0;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><path d="M50 10 L60 40 L90 40 L65 58 L75 90 L50 70 L25 90 L35 58 L10 40 L40 40 Z" fill="white" opacity="0.03"/></svg>');
    background-repeat: repeat;
    opacity: 0.1;
}

.hero-content {
    position: relative;
    z-index: 1;
}

.hero-title {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: var(--white);
    font-weight: 700;
}

.hero-subtitle {
    font-size: 1.3rem;
    margin-bottom: 2rem;
    opacity: 0.95;
}

.hero-cta {
    display: inline-flex;
    gap: 1rem;
}

.btn {
    padding: 0.875rem 2rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    display: inline-block;
}

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

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

.btn-secondary {
    background-color: transparent;
    color: var(--white);
    border-color: var(--white);
}

.btn-secondary:hover {
    background-color: var(--white);
    color: var(--primary-blue);
}

/* ==========================================================================
   Content Sections
   ========================================================================== */

.content-section {
    padding: 4rem 0;
}

.section-title {
    text-align: center;
    margin-bottom: 3rem;
    color: var(--primary-blue);
    position: relative;
    padding-bottom: 1rem;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background-color: var(--accent-gold);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.feature-card {
    text-align: center;
    padding: 2rem;
    background-color: var(--white);
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(51, 102, 204, 0.15);
}

.feature-icon {
    font-size: 3rem;
    color: var(--primary-blue);
    margin-bottom: 1rem;
}

.feature-title {
    color: var(--primary-blue);
    margin-bottom: 1rem;
}

.feature-description {
    color: var(--text-light);
}

/* ==========================================================================
   Posts & Pages
   ========================================================================== */

.posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.post-card {
    background-color: var(--white);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.post-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(51, 102, 204, 0.15);
}

.post-thumbnail img {
    width: 100%;
    height: 220px;
    object-fit: cover;
}

.post-content {
    padding: 1.5rem;
}

.post-title {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
}

.post-title a {
    color: var(--text-dark);
}

.post-title a:hover {
    color: var(--primary-blue);
}

.post-meta {
    font-size: 0.875rem;
    color: var(--text-light);
    margin-bottom: 1rem;
}

.post-excerpt {
    color: var(--text-light);
    margin-bottom: 1rem;
}

.read-more {
    color: var(--primary-blue);
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.read-more:hover {
    gap: 0.75rem;
}

/* Single Post/Page */
.single-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 3rem 20px;
}

.entry-header {
    margin-bottom: 2rem;
}

.entry-title {
    color: var(--primary-blue);
    margin-bottom: 1rem;
}

.entry-content {
    line-height: 1.8;
}

.entry-content h2,
.entry-content h3 {
    color: var(--primary-blue);
    margin-top: 2rem;
}

/* ==========================================================================
   Sidebar
   ========================================================================== */

.sidebar {
    background-color: var(--light-gray);
    padding: 2rem;
    border-radius: 8px;
}

.widget {
    margin-bottom: 2rem;
}

.widget-title {
    color: var(--primary-blue);
    font-size: 1.2rem;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--primary-blue);
}

.widget ul {
    list-style: none;
}

.widget li {
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.widget a {
    color: var(--text-dark);
}

.widget a:hover {
    color: var(--primary-blue);
    padding-left: 5px;
}

/* ==========================================================================
   Footer
   ========================================================================== */

.site-footer {
    background-color: var(--primary-dark);
    color: rgba(255, 255, 255, 0.9);
    padding: 3rem 0 1rem;
    margin-top: 4rem;
}

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

.footer-widget h3 {
    color: var(--white);
    font-size: 1.2rem;
    margin-bottom: 1rem;
}

.footer-widget ul {
    list-style: none;
}

.footer-widget li {
    margin-bottom: 0.5rem;
}

.footer-widget a {
    color: rgba(255, 255, 255, 0.8);
}

.footer-widget a:hover {
    color: var(--accent-gold);
}

.site-info {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.875rem;
}

.site-info a {
    color: var(--accent-gold);
}

/* ==========================================================================
   Forms
   ========================================================================== */

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="url"],
textarea,
select {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid #ddd;
    border-radius: 4px;
    font-family: inherit;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

input:focus,
textarea:focus,
select:focus {
    outline: none;
    border-color: var(--primary-blue);
}

button,
input[type="submit"] {
    background-color: var(--primary-blue);
    color: var(--white);
    padding: 0.875rem 2rem;
    border: none;
    border-radius: 4px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

button:hover,
input[type="submit"]:hover {
    background-color: var(--primary-dark);
}

/* ==========================================================================
   Utilities
   ========================================================================== */

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

.mt-1 { margin-top: 1rem; }
.mt-2 { margin-top: 2rem; }
.mt-3 { margin-top: 3rem; }
.mb-1 { margin-bottom: 1rem; }
.mb-2 { margin-bottom: 2rem; }
.mb-3 { margin-bottom: 3rem; }

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

/* ==========================================================================
   Responsive Design
   ========================================================================== */

@media (max-width: 768px) {
    h1 {
        font-size: 2rem;
    }

    h2 {
        font-size: 1.5rem;
    }

    .hero-title {
        font-size: 2rem;
    }

    .hero-subtitle {
        font-size: 1.1rem;
    }

    .hero-cta {
        flex-direction: column;
        align-items: center;
    }

    .btn {
        width: 100%;
        max-width: 300px;
    }

    .header-container {
        flex-direction: column;
        gap: 1rem;
    }

    .features-grid,
    .posts-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }

    .hero-section {
        padding: 3rem 0;
    }

    .content-section {
        padding: 2rem 0;
    }
}
