/*
Theme Name: Lexham Estate Theme
Description: Custom theme for Lexham Estate & Gardens
Version: 1.0
*/

/* ============================================
   RESET & BASE
   ============================================ */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Lato', sans-serif;
    font-size: 15px;
    line-height: 1.6;
    color: #333;
    background: #fff;
}

a {
    text-decoration: none;
    color: inherit;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Playfair Display', serif;
    font-weight: 400;
    line-height: 1.3;
    color: #1a1a1a;
}

/* ============================================
   HEADER
   ============================================ */
.site-header {
    background: #fff;
    border-bottom: 1px solid #e5e5e5;
    padding: 18px 0;
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1150px;
    margin: 0 auto;
    padding: 0 20px;
}

.nav-left, .nav-right {
    display: flex;
    align-items: center;
    gap: 40px;
}

.nav-left a, .nav-right a:not(.social-links a) {
    font-size: 11px;
    letter-spacing: 1.5px;
    color: #444;
    font-weight: 400;
    transition: color 0.3s;
}

.nav-left a:hover, .nav-right a:hover {
    color: #6b8e23;
}

.site-logo {
    text-align: center;
}

.site-logo a {
    display: block;
}

.site-logo h1 {
    font-family: 'Playfair Display', serif;
    font-size: 28px;
    font-weight: 700;
    letter-spacing: 4px;
    color: #1a1a1a;
    margin: 0;
}

.site-logo p {
    font-size: 9px;
    letter-spacing: 2.5px;
    color: #666;
    margin-top: 2px;
}

.social-links {
    display: flex;
    gap: 15px;
    margin-left: 20px;
    align-items: center;
}

.social-links a {
    display: flex;
    align-items: center;
    color: #444;
    transition: color 0.3s;
}

.social-links a:hover {
    color: #6b8e23;
}

.social-links svg {
    width: 18px;
    height: 18px;
    fill: currentColor;
}

/* Dropdown Menu Styles */
.nav-item {
    position: relative;
}

.nav-item > a {
    display: block;
    padding: 5px 0;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: #fff;
    min-width: 200px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
    z-index: 1000;
    padding: 10px 0;
    margin-top: 10px;
}

.dropdown-menu::before {
    content: '';
    position: absolute;
    top: -10px;
    left: 0;
    right: 0;
    height: 10px;
}

.nav-item:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
}

.dropdown-menu a {
    display: block;
    padding: 8px 20px;
    font-size: 12px;
    letter-spacing: 0.5px;
    color: #444;
    transition: background 0.2s, color 0.2s;
}

.dropdown-menu a:hover {
    background: #f5f5f5;
    color: #6b8e23;
}

/* ============================================
   BUTTONS
   ============================================ */
.btn-primary {
    display: inline-block;
    background: #6b8e23;
    color: #fff;
    padding: 12px 28px;
    font-size: 13px;
    font-family: 'Lato', sans-serif;
    letter-spacing: 0.5px;
    border: none;
    border-radius: 2px;
    cursor: pointer;
    transition: background 0.3s;
}

.btn-primary:hover {
    background: #5a7a1e;
}

.btn-outline {
    display: inline-block;
    background: transparent;
    color: #333;
    padding: 10px 25px;
    font-size: 12px;
    font-family: 'Lato', sans-serif;
    letter-spacing: 0.5px;
    border: 1px solid #444;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-outline:hover {
    background: #333;
    color: #fff;
}

/* ============================================
   HERO SECTION
   ============================================ */
.hero-section {
    position: relative;
    height: 480px;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.35);
}

.hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
    padding: 0 20px;
    max-width: 1150px;
    margin: 0 auto;
}

.hero-content h2 {
    font-family: 'Playfair Display', serif;
    font-size: 38px;
    font-weight: 400;
    color: #fff;
    line-height: 1.35;
    margin-bottom: 30px;
    text-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

/* ============================================
   THREE CARDS SECTION
   ============================================ */
.cards-section {
    padding: 50px 0;
    background: #fff;
}

.cards-container {
    display: flex;
    justify-content: space-between;
    gap: 35px;
    max-width: 1150px;
    margin: 0 auto;
    padding: 0 20px;
}

.card {
    flex: 1;
    text-align: center;
}

.card-image {
    margin-bottom: 20px;
    overflow: hidden;
}

.card-image img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    transition: transform 0.4s;
}

.card:hover .card-image img {
    transform: scale(1.05);
}

.card h3 {
    font-family: 'Playfair Display', serif;
    font-size: 26px;
    font-weight: 400;
    margin-bottom: 12px;
    color: #1a1a1a;
}

.card p {
    font-size: 13px;
    color: #666;
    line-height: 1.7;
    margin-bottom: 18px;
    padding: 0 5px;
}

/* ============================================
   WELCOME SECTION
   ============================================ */
.welcome-section {
    background: #f7f6f2;
    padding: 50px 0;
}

.welcome-container {
    display: flex;
    align-items: stretch;
    max-width: 1150px;
    margin: 0 auto;
    padding: 0 20px;
}

.welcome-content {
    flex: 0 0 50%;
    padding: 45px 40px 45px 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.welcome-content h2 {
    font-family: 'Playfair Display', serif;
    font-size: 28px;
    font-weight: 400;
    color: #1a1a1a;
    margin-bottom: 18px;
    line-height: 1.25;
}

.welcome-content p {
    font-size: 14px;
    color: #555;
    line-height: 1.7;
    margin-bottom: 10px;
}

.welcome-content .btn-outline {
    margin-top: 18px;
    align-self: flex-start;
}

.welcome-image {
    flex: 0 0 50%;
    overflow: hidden;
}

.welcome-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    min-height: 320px;
}

/* ============================================
   HOUSE SECTION
   ============================================ */
.house-section {
    background: #fff;
    padding: 50px 0;
}

.house-container {
    display: flex;
    align-items: stretch;
    max-width: 1150px;
    margin: 0 auto;
    padding: 0 20px;
}

.house-main-image {
    flex: 0 0 50%;
    overflow: hidden;
}

.house-main-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    min-height: 320px;
}

.house-content-box {
    flex: 0 0 50%;
    padding: 45px 0 45px 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    background: #fff;
}

.house-content-box h3 {
    font-family: 'Playfair Display', serif;
    font-size: 28px;
    margin-bottom: 18px;
}

.house-content-box p {
    font-size: 14px;
    color: #555;
    line-height: 1.7;
    margin-bottom: 15px;
}

.house-content-box .btn-outline {
    align-self: flex-start;
    margin-top: 10px;
}

/* ============================================
   EVENTS SECTION
   ============================================ */
.events-section {
    background: #e9efe0;
    padding: 50px 0;
}

.events-section > h2 {
    font-family: 'Playfair Display', serif;
    font-size: 34px;
    text-align: center;
    margin-bottom: 45px;
    color: #1a1a1a;
    max-width: 1150px;
    margin-left: auto;
    margin-right: auto;
    padding: 0 20px;
}

.events-container {
    display: flex;
    justify-content: space-between;
    gap: 35px;
    max-width: 1150px;
    margin: 0 auto;
    padding: 0 20px;
}

.event-card {
    flex: 1;
    background: #fff;
    overflow: hidden;
}

.event-image {
    overflow: hidden;
}

.event-image img {
    width: 100%;
    height: 220px;
    object-fit: cover;
}

.event-content {
    padding: 25px 30px 30px;
    text-align: center;
}

.event-content h4 {
    font-family: 'Playfair Display', serif;
    font-size: 18px;
    font-weight: 400;
    margin-bottom: 8px;
    color: #1a1a1a;
}

.event-content .event-date {
    font-size: 12px;
    color: #555;
    margin-bottom: 3px;
}

.event-content .event-location {
    font-size: 11px;
    color: #777;
    margin-bottom: 3px;
}

.event-content .event-host {
    font-size: 11px;
    color: #777;
    margin-bottom: 20px;
}

/* ============================================
   FOOTER
   ============================================ */
.site-footer {
    background: #f5f5f5;
    padding: 60px 0 50px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.3fr 1fr 1fr 1.3fr;
    gap: 50px;
    max-width: 1150px;
    margin: 0 auto;
    padding: 0 20px;
}

.footer-logo h2 {
    font-family: 'Playfair Display', serif;
    font-size: 26px;
    font-weight: 700;
    letter-spacing: 3px;
    color: #1a1a1a;
    margin-bottom: 3px;
}

.footer-logo p.tagline {
    font-size: 8px;
    letter-spacing: 2px;
    color: #666;
    margin-bottom: 25px;
}

.footer-logo p.copyright {
    font-size: 12px;
    color: #666;
    line-height: 1.6;
}

.footer-section h4 {
    font-family: 'Lato', sans-serif;
    font-size: 15px;
    font-weight: 700;
    color: #444;
    margin-bottom: 18px;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 8px;
}

.footer-section ul li a {
    font-size: 13px;
    color: #555;
    transition: color 0.3s;
}

.footer-section ul li a:hover {
    color: #6b8e23;
}

.footer-contact p {
    font-size: 13px;
    color: #555;
    line-height: 1.7;
}

.footer-newsletter input[type="email"] {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid #ddd;
    font-size: 13px;
    margin-bottom: 10px;
    font-family: 'Lato', sans-serif;
}

.footer-newsletter input[type="email"]::placeholder {
    color: #999;
}

.footer-newsletter button {
    width: 100%;
    background: #6b8e23;
    color: #fff;
    border: none;
    padding: 10px 20px;
    font-size: 13px;
    font-family: 'Lato', sans-serif;
    cursor: pointer;
    transition: background 0.3s;
}

.footer-newsletter button:hover {
    background: #5a7a1e;
}

/* ============================================
   PAGE HERO (Interior Pages)
   ============================================ */
.page-hero {
    position: relative;
    height: 280px;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
}

.page-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.25);
}

.page-hero h1 {
    position: relative;
    z-index: 1;
    font-family: 'Playfair Display', serif;
    font-size: 44px;
    font-weight: 400;
    color: #fff;
}

/* ============================================
   CONTENT SECTIONS (Interior Pages)
   ============================================ */
.content-section {
    padding: 50px 0;
}

.content-section.alt-bg {
    background: #f9f9f7;
}

.container {
    max-width: 1150px;
    margin: 0 auto;
    padding: 0 20px;
}

.content-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}

.content-grid.reverse {
    direction: rtl;
}

.content-grid.reverse > * {
    direction: ltr;
}

.content-text h2 {
    font-family: 'Playfair Display', serif;
    font-size: 32px;
    margin-bottom: 20px;
    color: #1a1a1a;
}

.content-text h3 {
    font-family: 'Playfair Display', serif;
    font-size: 26px;
    margin-bottom: 18px;
    color: #1a1a1a;
}

.content-text p {
    font-size: 13px;
    color: #555;
    line-height: 1.7;
    margin-bottom: 12px;
}

.content-image {
    overflow: hidden;
    display: flex;
    justify-content: flex-end;
}

.content-grid.reverse .content-image {
    justify-content: flex-start;
}

.content-image img {
    height: 320px;
    width: auto;
    max-width: 100%;
    object-fit: cover;
    object-position: center;
}

/* ============================================
   GALLERY
   ============================================ */
.gallery-section {
    padding: 20px 0 70px;
}

.gallery-section h2 {
    font-family: 'Playfair Display', serif;
    font-size: 32px;
    text-align: center;
    margin-bottom: 35px;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    max-width: 1100px;
    margin: 0 auto;
}

.gallery-item img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    cursor: pointer;
    transition: opacity 0.3s;
}

.gallery-item img:hover {
    opacity: 0.85;
}

.gallery-item.tall img {
    height: 375px;
}

/* Gallery Collage */
.gallery-collage {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
}

.gallery-collage .gallery-item img {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    transition: transform 0.3s, opacity 0.3s;
}

.gallery-collage .gallery-item:hover img {
    transform: scale(1.03);
    opacity: 0.9;
}

/* ============================================
   CONTACT PAGE
   ============================================ */
.contact-section {
    padding: 70px 50px;
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    max-width: 1100px;
    margin: 0 auto 50px;
}

.contact-block h2 {
    font-family: 'Playfair Display', serif;
    font-size: 30px;
    margin-bottom: 22px;
}

.contact-block h4 {
    font-size: 17px;
    font-weight: 600;
    margin-bottom: 8px;
    color: #1a1a1a;
    font-family: 'Lato', sans-serif;
}

.contact-block p {
    font-size: 14px;
    color: #555;
    line-height: 1.7;
    margin-bottom: 12px;
}

.contact-block i {
    color: #6b8e23;
    margin-right: 8px;
}

.directions-section {
    max-width: 1150px;
    margin: 0 auto;
    padding: 0 20px;
}

.directions-section h2 {
    font-family: 'Playfair Display', serif;
    font-size: 30px;
    margin-bottom: 22px;
}

.map-container {
    width: 100%;
    border-radius: 4px;
    overflow: hidden;
}

.map-container iframe {
    display: block;
}

/* ============================================
   EVENTS PAGE
   ============================================ */
.event-detail {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 35px;
    align-items: start;
    margin-bottom: 40px;
}

.event-detail-image img {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
}

.event-detail-content h3 {
    font-family: 'Playfair Display', serif;
    font-size: 26px;
    margin-bottom: 12px;
}

.event-detail-content .date {
    font-size: 13px;
    color: #666;
    margin-bottom: 8px;
}

.event-detail-content .time-price {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 18px;
}

.event-detail-content p {
    font-size: 14px;
    color: #555;
    line-height: 1.7;
    margin-bottom: 10px;
}

.testimonials {
    margin-top: 50px;
    padding-top: 35px;
    border-top: 1px solid #e5e5e5;
}

.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
}

.testimonial {
    background: #e9efe0;
    padding: 25px;
    border-left: 3px solid #6b8e23;
}

.testimonial p {
    font-size: 13px;
    color: #555;
    line-height: 1.7;
    font-style: italic;
    margin-bottom: 10px;
}

.testimonial .author {
    font-style: normal;
    font-weight: 600;
    color: #333;
    display: block;
    margin-top: 15px;
    font-size: 13px;
}

/* ============================================
   GUTENBERG BLOCK STYLES
   ============================================ */
.page-content-wrapper {
    width: 100%;
}

/* Full width sections */
.page-content-wrapper > .wp-block-group {
    padding: 50px 0;
}

.page-content-wrapper > .wp-block-group.has-background {
    padding: 50px 0;
}

/* Container for content */
.page-content-wrapper .wp-block-group__inner-container,
.page-content-wrapper > .wp-block-columns {
    max-width: 1150px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Columns block - 50/50 layout */
.page-content-wrapper .wp-block-columns {
    gap: 50px;
    align-items: center;
    max-width: 1150px;
    margin: 0 auto;
    padding: 50px 20px;
}

.page-content-wrapper .wp-block-column {
    flex: 1;
}

/* Headings in content */
.page-content-wrapper h2 {
    font-family: 'Playfair Display', serif;
    font-size: 32px;
    margin-bottom: 20px;
    color: #1a1a1a;
}

.page-content-wrapper h3 {
    font-family: 'Playfair Display', serif;
    font-size: 26px;
    margin-bottom: 18px;
    color: #1a1a1a;
}

/* Paragraphs */
.page-content-wrapper p {
    font-size: 14px;
    color: #555;
    line-height: 1.7;
    margin-bottom: 12px;
}

/* Images in content */
.page-content-wrapper .wp-block-image img {
    height: 320px;
    width: auto;
    max-width: 100%;
    object-fit: cover;
    object-position: center;
}

.page-content-wrapper .wp-block-image.alignright img,
.page-content-wrapper .wp-block-column:last-child .wp-block-image img {
    margin-left: auto;
}

.page-content-wrapper .wp-block-image.alignleft img,
.page-content-wrapper .wp-block-column:first-child .wp-block-image img {
    margin-right: auto;
}

/* Green background for alternating sections */
.page-content-wrapper .wp-block-group.has-lexham-green-background-color {
    background-color: #e9efe0;
}

/* Links */
.page-content-wrapper a {
    color: #6b8e23;
}

.page-content-wrapper a:hover {
    text-decoration: underline;
}

/* Buttons in content */
.page-content-wrapper .wp-block-button__link {
    font-family: 'Lato', sans-serif;
    font-size: 12px;
    letter-spacing: 0.5px;
    padding: 10px 25px;
    border-radius: 2px;
    transition: all 0.3s;
}

.page-content-wrapper .wp-block-button.is-style-outline .wp-block-button__link {
    background: transparent;
    color: #333;
    border: 1px solid #444;
}

.page-content-wrapper .wp-block-button.is-style-outline .wp-block-button__link:hover {
    background: #333;
    color: #fff;
    text-decoration: none;
}

.page-content-wrapper .wp-block-button__link.has-olive-green-background-color {
    background: #6b8e23;
    color: #fff;
    border: none;
}

.page-content-wrapper .wp-block-button__link.has-olive-green-background-color:hover {
    background: #5a7a1e;
    text-decoration: none;
}

/* Card columns on homepage */
.page-content-wrapper .wp-block-column h3 {
    font-size: 26px;
    margin-bottom: 12px;
}

.page-content-wrapper .wp-block-column p {
    font-size: 13px;
    padding: 0 5px;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 1024px) {
    .header-inner {
        padding: 0 30px;
    }

    .nav-left, .nav-right {
        gap: 25px;
    }

    .cards-section,
    .welcome-section,
    .house-section,
    .events-section {
        padding: 45px 0;
    }

    .welcome-content {
        padding: 35px 30px 35px 0;
    }

    .house-content-box {
        padding: 35px 30px 35px 40px;
    }
}

@media (max-width: 900px) {
    .header-inner {
        flex-direction: column;
        gap: 15px;
    }

    .cards-container,
    .events-container {
        flex-direction: column;
        align-items: center;
    }

    .card,
    .event-card {
        max-width: 400px;
        width: 100%;
    }

    .welcome-container {
        flex-direction: column;
    }

    .welcome-content,
    .welcome-image {
        flex: none;
        width: 100%;
    }

    .welcome-content {
        padding: 35px 0;
    }

    .welcome-image img {
        height: 250px;
        min-height: auto;
    }

    .house-container {
        flex-direction: column;
    }

    .house-main-image,
    .house-content-box {
        flex: none;
        width: 100%;
    }

    .house-main-image img {
        height: 250px;
        min-height: auto;
    }

    .house-content-box {
        padding: 35px 0;
    }

    .content-grid,
    .contact-grid,
    .event-detail {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .testimonials-grid {
        grid-template-columns: 1fr;
    }

    .content-grid.reverse {
        direction: ltr;
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 35px;
    }

    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .gallery-collage {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    .hero-content h2 {
        font-size: 26px;
    }

    .footer-grid {
        grid-template-columns: 1fr;
    }

    .gallery-grid {
        grid-template-columns: 1fr;
    }

    .gallery-collage {
        grid-template-columns: 1fr;
    }

    .gallery-collage .gallery-item img {
        aspect-ratio: 1 / 1;
    }

    .gallery-item.tall img {
        height: 200px;
    }
}
