/* ============================================= */
/* PLIK CSS DLA KOW-BUD - OSTATECZNA POPRAWIONA WERSJA */
/* ============================================= */

/* --- 1. Style Globalne i Reset --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

body {
    font-family: 'Outfit', sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #ffffff;
}

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

h1, h2, h3, h4 {
    font-family: 'Lora', serif;
    font-weight: 500;
}

h1 {
    font-size: 3rem;
    line-height: 1.2;
    margin-bottom: 20px;
}

h2 {
    font-size: 2.5rem;
    margin-bottom: 40px;
}

p {
    font-size: 1.1rem;
    margin-bottom: 15px;
}

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

section {
    padding: 80px 0;
}

/* --- 2. Przyciski --- */
.btn {
    display: inline-block;
    padding: 12px 25px;
    background-color: #c5a47e;
    color: #fff;
    text-decoration: none;
    border-radius: 5px;
    font-weight: 500;
    transition: background-color 0.3s ease;
}

.btn:hover {
    background-color: #b39169;
}

.btn-secondary {
    background-color: transparent;
    color: #333;
    border: 2px solid #c5a47e;
}

.btn-secondary:hover {
    background-color: #c5a47e;
    color: #fff;
}

/* --- 3. Sekcja Hero --- */
#hero {
    padding-top: 150px;
    padding-bottom: 80px;
    background-color: #f9f9f9;
}

#hero .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
}

.hero-content {
    flex: 1;
}

.hero-image {
    flex: 1;
}

.hero-image img {
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

/* --- 4. Usługi --- */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    text-align: center;
}

.service-card {
    padding: 30px;
    border: 1px solid #eee;
    border-radius: 8px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.08);
}

.service-card i {
    font-size: 2.5rem;
    color: #c5a47e;
    margin-bottom: 15px;
}

/* --- 5. Sekcja "O nas" --- */
.split-section .container {
    display: flex;
    align-items: center;
    gap: 50px;
}

.split-section .content, .split-section .image-container {
    flex: 1;
}

.split-section .image-container img {
    border-radius: 8px;
}

/* --- 6. Portfolio --- */
.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
}

.portfolio-link {
    text-decoration: none; 
    color: inherit;       
    display: block;       
}

.portfolio-item {
    position: relative; 
    overflow: hidden;   
    border-radius: 8px; 
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.portfolio-item img {
    transition: transform 0.4s ease; 
    width: 100%;
    height: 250px;
    object-fit: cover;
}

.portfolio-item:hover img {
    transform: scale(1.05); 
}

.portfolio-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 250px;
    background: rgba(0, 0, 0, 0.6);
    color: white;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0; 
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.portfolio-item:hover .portfolio-overlay {
    opacity: 1; 
}

.portfolio-title {
    padding: 20px;
    text-align: center;
    font-weight: 500;
    background-color: #f9f9f9;
    margin-top: auto;
    margin-bottom: 0;
}

/* --- 7. Kontakt i Footer --- */
#contact {
    background-color: #f4f4f4;
}

footer {
    background-color: #333;
    color: #fff;
    text-align: center;
    padding: 20px 0;
}

/* --- 8. Style dla podstron projektów --- */
.project-header {
    padding: 120px 0 80px 0;
    background-color: #f9f9f9;
    text-align: center;
}

.project-details {
    padding: 50px 0;
    max-width: 900px;
    margin: 0 auto;
}

.project-details p {
    line-height: 1.8;
    margin-bottom: 20px;
}

.project-details ul {
    list-style-position: inside;
    padding-left: 20px;
    margin-bottom: 20px;
}

.project-details li {
    margin-bottom: 10px;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 40px;
}

.gallery-grid img {
    width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.back-link {
    display: inline-block;
    margin-top: 40px;
    padding: 10px 20px;
    text-decoration: none;
    font-weight: 500;
    color: #333;
    border: 2px solid #eee;
    border-radius: 5px;
    transition: all 0.3s ease;
}

.back-link:hover {
    background-color: #f4f4f4;
    border-color: #ddd;
}

.back-link i {
    margin-right: 8px;
}

/* --- 9. Sekcja Wyceny --- */
#quote {
    background-color: #f9f9f9;
}

.quote-form-wrapper {
    max-width: 800px;
    margin: 0 auto;
    background-color: #fff;
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.08);
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 25px;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group label {
    font-weight: 500;
    margin-bottom: 8px;
    font-size: 0.95rem;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-family: 'Outfit', sans-serif;
    font-size: 1rem;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: #c5a47e;
    box-shadow: 0 0 0 3px rgba(197, 164, 126, 0.2);
}

#quote button.btn {
    padding: 15px 40px;
    font-size: 1.1rem;
    width: 100%;
    max-width: 400px;
}


/* ======================================================== */
/* SEKCJA NAWIGACJI - POPRAWIONA SKŁADNIA                   */
/* ======================================================== */

/* --- Główny kontener nawigacji --- */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 20px 0;
    transition: background-color 0.4s ease, padding 0.4s ease, box-shadow 0.4s ease;
}

.navbar.scrolled {
    background-color: rgba(255, 255, 255, 0.95);
    padding: 15px 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    backdrop-filter: blur(5px);
}

/* --- Kontener wewnątrz nawigacji (POPRAWIONY) --- */
.navbar .container {
    display: flex;
    align-items: center;
}

/* --- Logo --- */
.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: #333;
    flex-shrink: 0;
}

.logo i {
    font-size: 2.2rem;
    color: #c5a47e;
}

.logo .logo-text {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
}

.logo .logo-text span {
    font-family: 'Lora', serif;
    font-size: 1.8rem;
    font-weight: 500;
}

.logo .logo-text small {
    font-family: 'Outfit', sans-serif;
    font-size: 0.7rem;
    font-weight: 400;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: #777;
}

/* --- Menu na dużym ekranie --- */
.nav-menu {
    display: flex;
    align-items: center;
    list-style: none;
    gap: 30px;
    margin-left: auto;
}

.nav-menu a {
    position: relative;
    padding: 5px 0;
    text-decoration: none;
    color: #333;
    font-weight: 400;
    font-size: 1rem;
    transition: color 0.3s ease;
}

.nav-menu a:hover {
    color: #c5a47e;
}

.nav-menu a:not(.btn)::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    background-color: #c5a47e;
    transition: width 0.3s ease;
}

.nav-menu a:not(.btn):hover::after {
    width: 100%;
}
/* ======================================================== */
/* OSTATECZNA WERSJA PRZYCISKU "KONTAKT" (nieruchomy)       */
/* ======================================================== */

.btn-nav-cta {
    position: relative;
    overflow: hidden;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 15px 55px;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 500;
    text-decoration: none;
    background-color: #c5a47e;
    color: #fff;
    border: none;
    transition: all 0.3s ease-in-out;
}

/* Efekt "połysku" */
.btn-nav-cta::before {
    content: '';
    position: absolute;
    top: 0;
    left: -150%;
    width: 75%;
    height: 100%;
    background: linear-gradient(120deg, rgba(255,255,255,0) 20%, rgba(255,255,255,0.3) 50%, rgba(255,255,255,0) 80%);
    transform: skewX(-25deg);
    transition: left 0.6s cubic-bezier(0.23, 1, 0.32, 1);
}

/* Zaktualizowany efekt po najechaniu (wyraźniejszy tekst) */
.btn-nav-cta:hover {
    /* ZMIANA TUTAJ: Znacznie ciemniejsze tło dla lepszego kontrastu */
    background-color: #8f6f49; 
    
    color: #fff;
    
    /* NOWOŚĆ: Subtelny cień pod tekstem dla "wybicia" go z tła */
    text-shadow: 0px 1px 2px rgba(0, 0, 0, 0.3);
}

.btn-nav-cta:hover::before {
    left: 150%;
}

/* Zabezpieczenie przed niechcianymi stylami */
.btn-nav-cta::after {
    display: none !important;
}



/* --- Menu mobilne (Hamburger) --- */
.menu-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    z-index: 1001;
    margin-left: 20px;
}

.menu-toggle span {
    display: block;
    width: 25px;
    height: 3px;
    background-color: #333;
    margin: 5px 0;
    transition: all 0.3s ease-in-out;
}

/* --- Media Queries --- */
@media (max-width: 992px) {
    .menu-toggle {
        display: block;
    }
    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        max-width: 300px;
        height: 100vh;
        padding-top: 100px;
        background-color: rgba(255, 255, 255, 0.98);
        box-shadow: -5px 0 15px rgba(0,0,0,0.1);
        backdrop-filter: blur(5px);
        flex-direction: column;
        align-items: center;
        gap: 20px;
        transition: right 0.4s ease-in-out;
        margin-left: 0;
    }
    .nav-menu.menu-open {
        right: 0;
    }
    .nav-menu li {
        margin: 0;
        width: 100%;
        text-align: center;
    }
    .nav-menu a {
        font-size: 1.2rem;
        padding: 15px 0;
        display: block;
        width: 100%;
    }
    .menu-toggle.menu-open span:nth-child(1) {
        transform: rotate(45deg) translate(6px, 6px);
    }
    .menu-toggle.menu-open span:nth-child(2) {
        opacity: 0;
    }
    .menu-toggle.menu-open span:nth-child(3) {
        transform: rotate(-45deg) translate(6px, -6px);
    }
}

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

    #hero .container, .split-section .container {
        flex-direction: column;
        text-align: center;
    }
    .hero-content {
        order: 2;
    }
    .hero-image {
        order: 1;
    }
    .portfolio-grid {
        grid-template-columns: 1fr;
    }
    .form-grid {
        grid-template-columns: 1fr;
    }
    .quote-form-wrapper {
        padding: 25px;
    }
}
/* ======================================================== */
/* NOWOCZESNA IKONA POWROTU DO STRONY GŁÓWNEJ               */
/* ======================================================== */

.back-to-home-icon {
    position: fixed; /* Kluczowe: sprawia, że ikona "pływa" na ekranie */
    bottom: 30px;
    right: 30px;
    z-index: 999; /* Zapewnia, że ikona jest nad innymi elementami */

    /* Wygląd przycisku */
    width: 50px;
    height: 50px;
    background-color: #c5a47e; /* Kolor firmowy */
    color: #fff;
    border-radius: 50%; /* Tworzy idealne koło */
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);

    /* Wyśrodkowanie ikony wewnątrz przycisku */
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;

    /* Efekt pojawiania się i znikania */
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s ease-in-out;
}

/* Stan :hover - lekkie powiększenie */
.back-to-home-icon:hover {
    transform: scale(1.1);
    background-color: #b39169; /* Przyciemnienie tła */
}

/* Klasa .visible, którą będziemy dodawać za pomocą JavaScript */
.back-to-home-icon.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}
/* ======================================================== */
/* STYL DLA PRZYCISKU POWROTU NA PODSTRONACH                */
/* ======================================================== */

.back-to-portfolio-link {
    display: flex;
    align-items: center;
    gap: 12px; /* Odstęp między strzałką a tekstem */
    text-decoration: none;
    color: #333;
    font-family: 'Outfit', sans-serif;
    font-size: 1.1rem;
    font-weight: 500;
    transition: color 0.3s ease;
}

.back-to-portfolio-link i {
    font-size: 1.3rem; /* Lekko większa ikona */
    transition: transform 0.3s ease;
}

.back-to-portfolio-link:hover {
    color: #c5a47e; /* Zmiana koloru po najechaniu */
}

/* Dodatkowy efekt "ruchu" strzałki po najechaniu */
.back-to-portfolio-link:hover i {
    transform: translateX(-5px); 
}
/* ======================================================== */
/* NOWOCZESNY WYGLĄD PODSTRONY PROJEKTU                     */
/* ======================================================== */

.project-page-main {
    padding-top: 120px; /* Dodajemy padding, żeby treść nie chowała się pod nawigacją */
}

.project-layout-grid {
    display: grid;
    grid-template-columns: 1fr 2fr; /* Podział na 2 kolumny w proporcji 1:2 */
    gap: 50px; /* Odstęp między kolumnami */
    align-items: start; /* Wyrównuje kolumny do góry */
}

.project-info-sticky {
    position: sticky; /* KLUCZOWE: "Przykleja" lewą kolumnę */
    top: 120px;       /* Zaczyna się przyklejać 120px od góry ekranu */
}

.project-info-sticky h1 {
    font-size: 2.8rem;
    margin-bottom: 5px;
}

.project-location {
    font-size: 1.1rem;
    color: #888;
    margin-bottom: 30px;
}

.project-description {
    line-height: 1.7;
    margin-bottom: 30px;
}

.project-meta-list {
    list-style: none;
    padding: 0;
    border-top: 1px solid #eee;
    padding-top: 20px;
}

.project-meta-list li {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
    font-size: 1rem;
}

.project-meta-list li i {
    color: #c5a47e;
    font-size: 1.2rem;
}

/* Ulepszenie galerii */
.gallery-grid {
    columns: 2; /* Tworzy layout w stylu Pinterest/Masonry */
    gap: 15px;
}

.gallery-grid a {
    display: block;
    margin-bottom: 15px;
    overflow: hidden;
    border-radius: 8px;
}

.gallery-grid img {
    width: 100%;
    height: auto;
    transition: transform 0.4s ease;
}

.gallery-grid a:hover img {
    transform: scale(1.05); /* Efekt lekkiego powiększenia */
}

/* Responsywność dla nowego layoutu */
@media (max-width: 992px) {
    .project-layout-grid {
        grid-template-columns: 1fr; /* Na mniejszych ekranach układ jednokolumnowy */
    }
    .project-info-sticky {
        position: static; /* Wyłączamy "przyklejanie" na mobile */
        margin-bottom: 40px;
    }
}
@media (max-width: 576px) {
    .gallery-grid {
        columns: 1; /* Jedna kolumna zdjęć na najmniejszych ekranach */
    }
}