/*
Theme Name: KupGrunty - Klasyczny Motyw
Description: Profesjonalny motyw dla portalu nieruchomości z działkami. Klasyczna wersja bez edytora blokowego.
Version: 2.0.0
Author: KupGrunty Team
Text Domain: kupgrunty
Domain Path: /languages
Tags: real-estate, business, responsive, custom-post-types
*/

/* Load Roboto Bold for navigation */
@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@700&display=swap');

/* ZMIENNE CSS - KOLORY MARKI */
:root {
    --green-900: #245D2A;
    --green-300: #9CCB7A;
    --lake-600: #4A90A4;
    --paper: #F6F5EF;
    --ink: #1F2E23;
    --muted: #6C6C6C;
    --white: #FFFFFF;
    
    /* Typography */
    --font-family: -apple-system, Inter, Roboto, Arial, sans-serif;
    
    /* Layout */
    --container-width: 1200px;
    --container-padding: 5px; /* reduced horizontal gutter (halved) */
    
    /* Spacing */
    --section-padding: 4rem 0;
    --card-padding: 1.5rem;
    --gap-small: 1rem;
    --gap-medium: 2rem;
    --gap-large: 3rem;
    
    /* Border radius */
    --radius-small: 8px;
    --radius-medium: 12px;
    --radius-large: 16px;
    
    /* Shadows */
    --shadow-light: 0 2px 8px rgba(0, 0, 0, 0.06);
    --shadow-medium: 0 4px 12px rgba(0, 0, 0, 0.1);
    --shadow-heavy: 0 8px 24px rgba(0, 0, 0, 0.15);
    
    /* Transitions */
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s ease;
    --transition-slow: 0.5s ease;
}

/* RESET I BASE STYLES */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
    height: 100%;
}

body {
    font-family: var(--font-family);
    line-height: 1.6;
    color: var(--ink);
    background-color: var(--paper);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    margin: 0; /* reset: centering controlled by .container */
    display: flex;
    flex-direction: column;
    min-height: 100vh; /* ensure full viewport height */
    padding: 0 5px; /* global left/right gutters halved */
    padding-bottom: 90px; /* reserve space for fixed cookie banner so footer isn't covered */
}

/* TYPOGRAPHY */
h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    line-height: 1.2;
    color: var (--green-900);
    margin-bottom: 1rem;
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }
h5 { font-size: 1.1rem; }
h6 { font-size: 1rem; }

p {
    margin-bottom: 1rem;
    color: var(--ink);
}

a {
    color: var(--lake-600);
    text-decoration: none;
    transition: color var(--transition-normal);
}

a:hover {
    color: var(--green-900);
}

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

/* LAYOUT CONTAINERS - POPRAWIONE MARGINESY */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 var(--container-padding); /* horizontal gutters applied site-wide (halved) */
    width: 100%;
}

.section {
    padding: var(--section-padding);
    margin: 0 var(--container-padding);
}

.section-alt {
    background-color: var(--white);
    border-radius: var(--radius-large);
    margin: var(--gap-medium) var(--container-padding);
}

/* BUTTONS */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: var(--green-900);
    color: var(--white);
    border: none;
    border-radius: var(--radius-medium);
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all var(--transition-normal);
    font-family: inherit;
    font-size: 1rem;
}

.btn:hover {
    background: var(--green-300);
    color: var(--white);
    transform: translateY(-1px);
    box-shadow: var(--shadow-medium);
}

.btn-secondary {
    background: var(--white);
    color: var(--green-900);
    border: 2px solid var(--green-900);
}

.btn-secondary:hover {
    background: var(--green-900);
    color: var(--white);
}

.btn-large {
    padding: 1rem 2rem;
    font-size: 1.1rem;
}

/* CARDS */
.card {
    background: var(--white);
    border-radius: var(--radius-large);
    overflow: hidden;
    box-shadow: var(--shadow-light);
    transition: all var(--transition-normal);
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-heavy);
}

.card-header {
    position: relative;
    overflow: hidden;
}

.card-body {
    padding: var(--card-padding);
}

.card-footer {
    padding: 1rem var(--card-padding);
    background: var(--paper);
    border-top: 1px solid #ECE8DD;
}

/* RESPONSIVE DESIGN */
@media (max-width: 768px) {
    :root {
        --container-padding: 1rem;
        --section-padding: 0.5rem 0;
        --card-padding: 1rem;
    }
    
    h1 { font-size: 2rem; }
    h2 { font-size: 1.75rem; }
    h3 { font-size: 1.25rem; }
    
    .btn {
        padding: 0.65rem 1.25rem;
        font-size: 0.95rem;
    }
    
    .posts-grid {
        grid-template-columns: 1fr;
        gap: var(--gap-small);
    }
    
    .section {
        margin: 0 var(--container-padding);
    }
    
    .section-alt {
        margin: var(--gap-small) var(--container-padding);
    }
}

@media (max-width: 480px) {
    :root {
        --container-padding: 0.1rem;
        --section-padding: 2rem 0;
    }
    
    h1 { font-size: 1.75rem; }
    h2 { font-size: 1.5rem; }
}

/* HEADER */
.site-header {
    background: var(--white);
    border-bottom: 1px solid #EAE7DE;
    padding: 0 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: var(--shadow-light);
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--gap-medium);
}

.site-branding img {
    max-height: 70px;
    width: auto;
}

.main-navigation {
    flex: 1;
    display: flex;
    justify-content: right;
    margin-right: 20px;
    margin-block-start: 20px;
}

.nav-menu {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: var(--gap-medium);
}

.nav-menu li {
    position: relative;
}

.nav-menu a {
    color: var(--ink);
    font-weight: 500;
    padding: 0.5rem 0.5rem;
    border-radius: var(--radius-small);
    transition: all var(--transition-normal);
}

.nav-menu a:hover,
.nav-menu a:focus {
    background: var(--green-300);
    color: var(--white);
}

.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    padding: 0.5rem;
    cursor: pointer;
}

.hamburger {
    display: flex;
    flex-direction: column;
    width: 24px;
    height: 18px;
    justify-content: space-between;
}

.hamburger span {
    display: block;
    height: 2px;
    background: var(--ink);
    transition: all var(--transition-normal);
}

/* HERO SECTION - POPRAWIONE */
.hero-section {
    position: relative;
    min-height: 70vh;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0; /* Hero bez marginesów */
}

.hero-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(36, 93, 42, 0.7), rgba(74, 144, 164, 0.5));
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    color: var(--white);
    max-width: 800px;
    padding: 0 var(--container-padding);
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.5);
    line-height: 1.1;
}

.hero-subtitle {
    font-size: 1.5rem;
    margin-bottom: 2.5rem;
    opacity: 0.95;
    text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.5);
}

.hero-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* SECTIONS */
.section-header {
    text-align: center;
    margin-bottom: var(--gap-large);
}

.section-header h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.section-header p {
    font-size: 1.2rem;
    color: var(--muted);
    max-width: 600px;
    margin: 0 auto;
}

.section-footer {
    text-align: center;
    margin-top: var(--gap-large);
}

/* GRIDS */
.plots-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: var(--gap-medium);
    margin: var(--gap-medium) 0;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var (--gap-medium);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: var(--gap-medium);
}

/* SEKCJA PORAD - NOWE STYLE */
.posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: var(--gap-medium);
    margin: var(--gap-medium) 0;
}

.post-card {
    background: var(--white);
    border-radius: var(--radius-large);
    overflow: hidden;
    box-shadow: var(--shadow-light);
    transition: all var(--transition-normal);
    display: flex;
    flex-direction: column;
}

.post-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-heavy);
}

.post-card .card-header {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16/9;
}

.post-card .card-header img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-normal);
}

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

.post-card .card-body {
    padding: var(--card-padding);
    flex: 1;
    display: flex;
    flex-direction: column;
}

.post-card .post-title {
    margin-bottom: 1rem;
}

.post-card .post-title a {
    color: var(--green-900);
    font-weight: 600;
    text-decoration: none;
    transition: color var(--transition-normal);
}

.post-card .post-title a:hover {
    color: var(--lake-600);
}

.post-card .post-excerpt {
    color: var(--muted);
    line-height: 1.6;
    margin-bottom: 1rem;
    flex: 1;
}

.post-card .read-more {
    color: var(--lake-600);
    font-weight: 500;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: auto;
    transition: all var(--transition-normal);
}

.post-card .read-more:hover {
    color: var(--green-900);
    transform: translateX(4px);
}

/* FEATURE CARDS */
.feature-card {
    text-align: center;
    padding: var(--card-padding);
    background: var(--white);
    border-radius: var(--radius-large);
    box-shadow: var(--shadow-light);
    transition: all var(--transition-normal);
}

.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-heavy);
}

.feature-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 1.5rem;
    background: var(--green-300);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-normal);
}

.feature-card:hover .feature-icon {
    background: var(--green-900);
    transform: scale(1.1);
}

.feature-icon img {
    width: 48px;
    height: 48px;
}

/* SERVICE CARDS */
.service-card {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: var(--card-padding);
    background: var(--white);
    border: 2px solid #ECE8DD;
    border-radius: var(--radius-large);
    text-decoration: none;
    color: var(--ink);
    transition: all var(--transition-normal);
}

.service-card:hover {
    border-color: var(--green-300);
    box-shadow: var(--shadow-medium);
    transform: translateY(-2px);
}

.service-icon {
    width: 64px;
    height: 64px;
    background: var(--green-300);
    border-radius: var(--radius-medium);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.service-content {
    flex: 1;
}

.service-content h3 {
    margin-bottom: 0.5rem;
    color: var(--green-900);
}

.service-content p {
    margin: 0;
    color: var(--muted);
}

.service-arrow {
    font-size: 1.5rem;
    color: var(--green-900);
    transition: transform var(--transition-normal);
}

.service-card:hover .service-arrow {
    transform: translateX(4px);
}

/* PLOT CARDS */
.plot-card {
    position: relative;
}

.plot-status {
    position: absolute;
    top: 1rem;
    right: 1rem;
    padding: 0.5rem 1rem;
    border-radius: var(--radius-medium);
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--white);
    z-index: 2;
}

.status-available {
    background: #2e7d32;
}

.status-reserved {
    background: #f57c00;
}

.status-sold {
    background: #d32f2f;
}

.plot-location {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
    color: var(--muted);
}

.plot-meta {
    margin: 1rem 0;
    font-size: 0.9rem;
}

.plot-meta div {
    margin-bottom: 0.5rem;
}

.plot-price-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.plot-price {
    font-size: 1.25rem;
    font-weight: 700;
    color: var (--green-900);
}

/* POST CARDS */
.post-card {
    background: var(--white);
    border-radius: var(--radius-large);
    overflow: hidden;
    box-shadow: var(--shadow-light);
    transition: all var(--transition-normal);
}

.post-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-heavy);
}

.post-title a {
    color: var(--green-900);
}

.post-meta {
    color: var(--muted);
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.post-meta .separator {
    margin: 0 0.5rem;
}

.read-more {
    color: var(--lake-600);
    font-weight: 500;
    text-decoration: none;
}

.read-more:hover {
    color: var(--green-900);
}

/* FOOTER */
.site-footer {
    background: #1a1a1a;
    color: #ffffff;
    padding: 3rem 0 2rem;
    margin-top: auto;
    flex-shrink: 0;
    position: relative;
    z-index: 1100; /* sit above most fixed elements if needed */
}

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

.footer-column h4 {
    color: var(--green-300);
    margin-bottom: 1rem;
    border-bottom: 2px solid var(--green-300);
    padding-bottom: 0.5rem;
    display: inline-block;
}

.footer-logo img {
    max-width: 180px;
    height: auto;
    margin-bottom: 1rem;
    filter: brightness(1.2);
}

.company-info p {
    margin-bottom: 0.75rem;
    line-height: 1.6;
}

.company-details {
    font-size: 0.9rem;
    opacity: 0.8;
}

.footer-menu,
.services-menu {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-menu li,
.services-menu li {
    margin-bottom: 0.5rem;
}

.footer-menu a,
.services-menu a {
    color: #cccccc;
    transition: all var(--transition-normal);
}

.footer-menu a:hover,
.services-menu a:hover {
    color: var(--green-300);
    padding-left: 0.5rem;
}

.footer-separator {
    border: none;
    height: 1px;
    background: #333;
    margin: 2rem 0 1.5rem;
}

.footer-bottom-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.site-footer .container {
    padding: 2rem 0; /* vertical spacing inside footer */
}

.copyright {
    color: #999;
    margin: 0;
}

.footer-links {
    display: flex;
    gap: 1rem;
}

.footer-links a {
    color: var(--green-300);
    font-size: 0.9rem;
}

/* COOKIE BANNER */
#cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #111;
    color: var(--white);
    padding: 1rem;
    z-index: 1000;
    box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.3);
}

.cookie-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    max-width: var(--container-width);
    margin: 0 auto;
}

.cookie-actions {
    display: flex;
    gap: 0.75rem;
}

/* BREADCRUMBS */
.breadcrumbs {
    background: var(--paper);
    padding: 1rem 0;
    font-size: 0.9rem;
}

.breadcrumbs a {
    color: var(--lake-600);
}

.breadcrumbs .separator {
    margin: 0 0.5rem;
    color: var(--muted);
}

.breadcrumbs .current {
    color: var(--ink);
    font-weight: 500;
}

/* PAGINATION */
.pagination {
    margin-top: var(--gap-large);
    text-align: center;
}

.pagination .page-numbers {
    display: inline-block;
    padding: 0.5rem 1rem;
    margin: 0 0.25rem;
    background: var(--white);
    border: 1px solid #ddd;
    border-radius: var(--radius-small);
    color: var(--ink);
    text-decoration: none;
    transition: all var(--transition-normal);
}

.pagination .page-numbers:hover,
.pagination .page-numbers.current {
    background: var(--green-900);
    color: var(--white);
    border-color: var(--green-900);
}

/* MOBILE RESPONSIVE */
@media (max-width: 768px) {
    .main-navigation {
        display: none;
    }
    
    .mobile-menu-toggle {
        display: block;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1.2rem;
    }
    
    .hero-actions {
        flex-direction: column;
        align-items: center;
    }
    
    .service-card {
        flex-direction: column;
        text-align: center;
    }
    
    .service-arrow {
        transform: rotate(90deg);
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .footer-bottom-content {
        flex-direction: column;
        text-align: center;
    }
    
    .cookie-content {
        flex-direction: column;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .plots-grid,
    .features-grid,
    .services-grid,
    .posts-grid {
        grid-template-columns: 1fr;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .section-header h2 {
        font-size: 2rem;
    }
}

/* DODATKOWE STYLE DLA KLASYCZNEGO MOTYWU */

/* Content wrapper dla layout z sidebar */
.content-wrapper {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: var(--gap-large);
    margin-top: var(--gap-medium);
    flex: 1 0 auto;
}

.content-area {
    min-width: 0; /* Prevent grid overflow */
}

/* Page content styles */
.page-content {
    background: var(--white);
    padding: var(--gap-large);
    border-radius: var(--radius-large);
    box-shadow: var(--shadow-light);
}

.page-header {
    margin-bottom: var(--gap-large);
    padding-bottom: 1rem;
    border-bottom: 2px solid var(--green-300);
}

.page-title {
    color: var(--green-900);
    margin-bottom: 0;
}

/* Single post styles */
.single-post {
    background: var(--white);
    padding: var(--gap-large);
    border-radius: var(--radius-large);
    box-shadow: var(--shadow-light);
    margin-bottom: var(--gap-large);
    flex: 1 0 auto;
}

.post-header {
    margin-bottom: var(--gap-medium);
    padding-bottom: 1.5rem;
    border-bottom: 1px solid #ECE8DD;
}

.post-thumbnail {
    margin: var(--gap-medium) 0;
    border-radius: var(--radius-medium);
    overflow: hidden;
}

.post-content {
    margin: var(--gap-medium) 0;
    line-height: 1.8;
}

.post-content h2,
.post-content h3,
.post-content h4 {
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.post-content p {
    margin-bottom: 1.2rem;
}

.post-content ul,
.post-content ol {
    margin: 1rem 0 1rem 2rem;
}

.post-content blockquote {
    background: var(--paper);
    border-left: 4px solid var(--green-300);
    padding: 1rem 1.5rem;
    margin: 1.5rem 0;
    font-style: italic;
}

/* Post navigation */
.post-navigation {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-top: var(--gap-medium);
    padding-top: var(--gap-medium);
    border-top: 1px solid #ECE8DD;
}

.nav-previous {
    text-align: left;
}

.nav-next {
    text-align: right;
}

.post-navigation a {
    display: block;
    padding: 1rem;
    background: var(--paper);
    border-radius: var(--radius-medium);
    color: var(--green-900);
    font-weight: 500;
    transition: all var(--transition-normal);
}

.post-navigation a:hover {
    background: var(--green-300);
    color: var(--white);
    transform: translateY(-2px);
}

/* Related posts */
.related-posts {
    margin-top: var(--gap-large);
    padding-top: var(--gap-large);
    border-top: 2px solid var(--green-300);
}

.related-posts h3 {
    text-align: center;
    margin-bottom: var(--gap-medium);
    color: var(--green-900);
}

.related-posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--gap-medium);
}

/* Sidebar styles */
.sidebar {
    background: var(--white);
    padding: var(--card-padding);
    border-radius: var(--radius-large);
    box-shadow: var(--shadow-light);
    height: fit-content;
    position: sticky;
    top: 120px;
}

.widget {
    margin-bottom: var(--gap-medium);
    padding-bottom: var(--gap-medium);
    border-bottom: 1px solid #ECE8DD;
}

.widget:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.widget-title {
    color: var(--green-900);
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

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

.widget li {
    margin-bottom: 0.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #f0f0f0;
}

.widget li:last-child {
    border-bottom: none;
}

.widget a {
    color: var(--ink);
    font-size: 0.9rem;
    transition: color var(--transition-normal);
}

.widget a:hover {
    color: var(--green-900);
}

/* Mobile menu styles */
@media (max-width: 768px) {
    .main-navigation {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--white);
        box-shadow: var(--shadow-medium);
        transform: translateY(-100%);
        opacity: 0;
        visibility: hidden;
        transition: all var(--transition-normal);
    }
    
    .main-navigation.mobile-menu-open {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }
    
    .nav-menu {
        flex-direction: column;
        padding: 1rem;
        gap: 0;
    }
    
    .nav-menu a {
        display: block;
        padding: 1rem;
        border-bottom: 1px solid #ECE8DD;
    }
    
    .nav-menu li:last-child a {
        border-bottom: none;
    }
}

/* Hamburger animation */
.hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

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

/* Sticky header states */
.site-header.scrolled {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    transition: all var(--transition-normal);
}

.site-header.header-hidden {
    transform: translateY(-100%);
}

/* Back to top button */
.back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 50px;
    height: 50px;
    background: var (--green-900);
    color: var(--white);
    border: none;
    border-radius: 50%;
    font-size: 1.2rem;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all var(--transition-normal);
    z-index: 99;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top:hover {
    background: var(--green-300);
    transform: translateY(-2px);
}

/* Form styles */
.contact-form,
.plot-filters-form {
    background: var(--white);
    padding: var(--card-padding);
    border-radius: var(--radius-large);
    box-shadow: var(--shadow-light);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--green-900);
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 2px solid #ECE8DD;
    border-radius: var(--radius-medium);
    font-family: inherit;
    font-size: 1rem;
    transition: border-color var(--transition-normal);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--green-300);
    box-shadow: 0 0 0 3px rgba(156, 203, 122, 0.1);
}

.form-group input.error,
.form-group select.error,
.form-group textarea.error {
    border-color: #d32f2f;
}

.contact-status {
    padding: 1rem;
    border-radius: var(--radius-medium);
    margin-bottom: 1rem;
    display: none;
}

.contact-status.success {
    background: #e8f5e8;
    color: #2e7d32;
    border: 1px solid #4caf50;
}

.contact-status.error {
    background: #ffebee;
    color: #c62828;
    border: 1px solid #f44336;
}

/* Loading states */
.loading {
    text-align: center;
    padding: 2rem;
    color: var(--muted);
}

.loading::after {
    content: '';
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid var(--green-300);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-left: 0.5rem;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Page links */
.page-links {
    margin: 2rem 0;
    text-align: center;
}

.page-links a {
    display: inline-block;
    padding: 0.5rem 1rem;
    margin: 0 0.25rem;
    background: var(--white);
    border: 1px solid #ddd;
    border-radius: var(--radius-small);
    color: var(--ink);
    text-decoration: none;
    transition: all var(--transition-normal);
}

.page-links a:hover {
    background: var(--green-900);
    color: var(--white);
    border-color: var(--green-900);
}

/* No results state */
.no-results {
    text-align: center;
    padding: 3rem 1rem;
    background: var(--white);
    border-radius: var(--radius-large);
    box-shadow: var(--shadow-light);
}

.no-results h1 {
    color: var(--muted);
    margin-bottom: 1rem;
}

/* Screen reader only content */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Responsive adjustments */
@media (max-width: 1024px) {
    .content-wrapper {
        grid-template-columns: 1fr;
        gap: var(--gap-medium);
    }
    
    .sidebar {
        position: static;
        order: -1;
    }
    
    .section {
        margin: 0 var(--container-padding);
    }
    
    .section-alt {
        margin: var(--gap-medium) var(--container-padding);
    }
}

@media (max-width: 768px) {
    .page-content,
    .single-post {
        padding: var(--gap-medium);
    }
    
    .post-navigation {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }
    
    .nav-previous,
    .nav-next {
        text-align: center;
    }
    
    .back-to-top {
        bottom: 1rem;
        right: 1rem;
        width: 45px;
        height: 45px;
    }
}

@media (max-width: 480px) {
    .related-posts-grid {
        grid-template-columns: 1fr;
    }
    
    .hero-actions .btn {
        width: 100%;
        justify-content: center;
    }
}

/* PLOT FILTERS STYLES */
.plot-filters {
    background: var(--white);
    padding: var(--card-padding);
    border-radius: var(--radius-large);
    box-shadow: var(--shadow-light);
    margin-bottom: var(--gap-medium);
}

.filters-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.filters-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

.results-info {
    margin-bottom: 1rem;
    color: var(--muted);
}

/* SINGLE PLOT STYLES */
.single-plot {
    background: var(--white);
    border-radius: var(--radius-large);
    overflow: hidden;
    box-shadow: var(--shadow-light);
    flex: 1 0 auto;
}

.single-plot-container {
    flex: 1 0 auto;
}

.plot-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 2rem;
    padding: var(--gap-large);
    background: linear-gradient(135deg, var(--paper), var(--white));
    border-bottom: 1px solid #ECE8DD;
}

.plot-title-section h1 {
    margin-bottom: 1rem;
    color: var(--green-900);
}

.plot-location {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
    color: var(--muted);
    font-size: 1.1rem;
}

.plot-status {
    display: inline-block;
    padding: 0.5rem 1rem;
    border-radius: var(--radius-medium);
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--white);
}

.plot-price-section {
    text-align: right;
}

.plot-price {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--green-900);
    margin-bottom: 0.5rem;
}

.price-per-m2 {
    font-size: 1.1rem;
    color: var(--muted);
}

.plot-content-wrapper {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: var(--gap-large);
    padding: var(--gap-large);
}

.plot-main-content {
    min-width: 0;
}

.plot-gallery {
    margin-bottom: var(--gap-medium);
    border-radius: var(--radius-medium);
    overflow: hidden;
}

.plot-description {
    margin-bottom: var(--gap-medium);
}

.plot-description h2 {
    color: var (--green-900);
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--green-300);
}

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

.plot-map {
    margin-top: var(--gap-medium);
}

.map-container {
    height: 400px;
    border-radius: var(--radius-medium);
    overflow: hidden;
    background: var(--paper);
    border: 1px solid #ECE8DD;
}

#plot-map {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--muted);
}

/* PLOT SIDEBAR */
.plot-sidebar {
    display: flex;
    flex-direction: column;
    gap: var(--gap-medium);
}

.plot-details-card,
.contact-card {
    background: var(--paper);
    padding: var(--card-padding);
    border-radius: var(--radius-large);
    border: 1px solid #ECE8DD;
}

.plot-details-card h3,
.contact-card h3 {
    color: var(--green-900);
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--green-300);
}

.details-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.detail-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: 1px solid #f0f0f0;
}

.detail-item:last-child {
    border-bottom: none;
}

.detail-item strong {
    color: var(--green-900);
    min-width: 120px;
}

.plot-actions {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.plot-actions .btn {
    justify-content: center;
}

/* SIMILAR PLOTS */
.similar-plots {
    margin-top: var(--gap-large);
    padding-top: var(--gap-large);
    border-top: 2px solid var(--green-300);
}

.similar-plots h2 {
    text-align: center;
    margin-bottom: var(--gap-medium);
    color: var (--green-900);
}

/* RESPONSIVE DLA PLOT PAGES */
@media (max-width: 1024px) {
    .plot-content-wrapper {
        grid-template-columns: 1fr;
        gap: var(--gap-medium);
    }
    
    .plot-sidebar {
        order: -1;
    }
    
    .filters-grid {
        grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    }
}

@media (max-width: 768px) {
    .plot-header {
        flex-direction: column;
        gap: 1.5rem;
        text-align: center;
    }
    
    .plot-price-section {
        text-align: center;
    }
    
    .plot-price {
        font-size: 2rem;
    }
    
    .filters-grid {
        grid-template-columns: 1fr;
    }
    
    .filters-actions {
        flex-direction: column;
    }
    
    .map-container {
        height: 300px;
    }
}

@media (max-width: 480px) {
    .plot-header,
    .plot-content-wrapper {
        padding: var(--gap-medium);
    }
    
    .plot-price {
        font-size: 1.75rem;
    }
    
    .detail-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
}

/* Layout: sticky footer + global side gutters */
main, .site-main, #main, .kg-main, .single-plot-container, .content-wrapper, .estimax-page, .estimax-form-page {
    flex: 1 0 auto;
}