:root {
    --bg: #f8f8f6;
    --surface: #ffffff;
    --surface-2: #f1f0eb;
    --text: #1f2328;
    --muted: #565b63;
    --brand: #323028;
    --gold: #b79e72;
    --border: #dfddd4;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: "Segoe UI", Arial, Helvetica, sans-serif;
    color: var(--text);
    background: var(--bg);
    line-height: 1.7;
}

.container {
    width: min(1200px, 92%);
    margin: 0 auto;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 20;
    backdrop-filter: blur(8px);
    background: rgba(248, 248, 246, 0.93);
    border-bottom: 1px solid var(--border);
}

.header-inner {
    min-height: 78px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.logo {
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
    text-decoration: none;
    color: var(--text);
}

.logo-mark {
    width: 42px;
    height: 42px;
    border-radius: 10px;
    display: grid;
    place-items: center;
    font-weight: 700;
    color: #fff;
    background: linear-gradient(135deg, #2f2d27, #6d6659);
}

.logo-image {
    width: 112px;
    height: 52px;
    object-fit: contain;
    border-radius: 0;
    border: 0;
    background: transparent;
    display: block;
}

.logo-text {
    font-size: 1.1rem;
    font-weight: 700;
}

.site-nav {
    display: flex;
    gap: 0.35rem;
    flex-wrap: wrap;
}

.nav-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border: 1px solid var(--border);
    background: #fff;
    border-radius: 8px;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 4px;
    cursor: pointer;
}

.nav-toggle span {
    width: 20px;
    height: 2px;
    background: #3a352b;
    display: block;
}

.site-nav a {
    text-decoration: none;
    color: var(--brand);
    font-size: 0.92rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding: 0.5rem 0.72rem;
    border-radius: 999px;
    transition: all 0.2s ease;
}

.site-nav a:hover {
    background: #ece9df;
}

.hero {
    padding: 3.4rem 0 4rem;
}

.hero-layout {
    display: grid;
    grid-template-columns: 1fr 1.05fr;
    gap: 2rem;
    align-items: center;
}

.hero-copy h1 {
    margin: 0.4rem 0 1.1rem;
    line-height: 1.18;
    font-size: clamp(2.2rem, 5vw, 4rem);
}

.hero-media img {
    width: 100%;
    height: min(72vh, 560px);
    object-fit: cover;
    border-radius: 16px;
    display: block;
    border: 1px solid var(--border);
}

.eyebrow {
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-size: 0.78rem;
    font-weight: 700;
    color: #8a7755;
}

.lead {
    color: var(--muted);
    font-size: 1.06rem;
    max-width: 640px;
}

.hero-actions {
    display: flex;
    gap: 0.7rem;
    flex-wrap: wrap;
    margin-top: 1.4rem;
}

.button {
    display: inline-block;
    text-decoration: none;
    padding: 0.78rem 1.24rem;
    border-radius: 999px;
    background: linear-gradient(135deg, #3a372e, #746a56);
    color: #fff;
    font-weight: 600;
    font-size: 0.95rem;
}

.button-outline {
    background: transparent;
    color: var(--brand);
    border: 1px solid #b6ab96;
}

.section {
    padding: 4rem 0;
}

.section-accent {
    background: var(--surface-2);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.section-intro {
    margin-bottom: 1.4rem;
    max-width: 850px;
}

.section-intro h2 {
    margin: 0.4rem 0 0;
    line-height: 1.24;
    font-size: clamp(1.7rem, 3.2vw, 2.5rem);
}

.cards-2,
.cards-3 {
    display: grid;
    gap: 1rem;
}

.cards-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.cards-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.card,
.project-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 1.3rem;
}

.card h3,
.project-card h3 {
    margin-top: 0;
    margin-bottom: 0.55rem;
}

.offer-extra {
    margin-top: 1.1rem;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 1.2rem 1.3rem;
}

.offer-extra h3 {
    margin: 0 0 0.5rem;
}

.check-list {
    margin: 0;
    padding-left: 1.2rem;
}

.check-list li {
    margin-bottom: 0.35rem;
}

#o-firmie .cards-2,
#oferta .cards-3,
#kontakt .cards-2 {
    gap: 2rem;
}

#o-firmie .card,
#oferta .card,
#kontakt .card {
    background: transparent;
    border: 0;
    border-radius: 0;
    padding: 0;
}

#oferta .offer-extra {
    background: transparent;
    border: 0;
    border-radius: 0;
    padding: 0;
    margin-top: 2rem;
}

.project-card {
    margin-bottom: 1rem;
}

.realizations-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.2rem;
}

.project-preview {
    background: transparent;
    border: 0;
    border-radius: 0;
    overflow: visible;
}

.project-preview img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    display: block;
    border-radius: 16px;
    border: 1px solid var(--border);
}

.project-preview h2,
.project-preview h3,
.project-preview p,
.project-preview .project-link {
    margin-left: 0;
    margin-right: 0;
}

.project-preview h2,
.project-preview h3 {
    margin-top: 0.95rem;
    margin-bottom: 0.45rem;
}

.project-preview h2 a,
.project-preview h3 a {
    color: var(--text);
    text-decoration: none;
}

.project-preview h2 a:hover,
.project-preview h3 a:hover {
    text-decoration: underline;
}

.project-preview p {
    margin-top: 0;
    margin-bottom: 0.7rem;
    color: var(--muted);
}

.project-link {
    display: inline-block;
    margin-bottom: 1rem;
    color: var(--brand);
    font-weight: 600;
    text-decoration: none;
}

.project-link:hover {
    text-decoration: underline;
}

.realizations-more {
    margin-top: 1.2rem;
}

.article-content {
    max-width: 860px;
}

.article-back {
    margin-top: 1rem;
}

.article-back .button {
    width: auto;
}

.project-photos {
    margin-top: 1rem;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.65rem;
}

.project-photos figure {
    margin: 0;
    border-radius: 10px;
    border: 1px solid var(--border);
    overflow: hidden;
}

.project-photos img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    display: block;
}

.js-lightbox-image {
    cursor: zoom-in;
}

.lightbox {
    position: fixed;
    inset: 0;
    z-index: 120;
    display: none;
}

.lightbox.is-open {
    display: block;
}

.lightbox-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(10, 10, 10, 0.86);
}

.lightbox-content {
    position: relative;
    width: min(1100px, 94vw);
    margin: 3vh auto 0;
    z-index: 1;
}

.lightbox-close {
    position: absolute;
    top: -12px;
    right: -12px;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: 0;
    background: #fff;
    color: #222;
    font-size: 1.6rem;
    cursor: pointer;
}

#lightbox-image {
    width: 100%;
    max-height: 78vh;
    object-fit: contain;
    display: block;
    background: #fff;
    border-radius: 10px;
}

.lightbox-controls {
    margin-top: 0.8rem;
    display: flex;
    gap: 0.5rem;
    justify-content: center;
}

.lightbox-controls button {
    border: 1px solid #a79a82;
    background: #fff;
    color: #2a251c;
    border-radius: 999px;
    min-width: 44px;
    padding: 0.45rem 0.75rem;
    cursor: pointer;
}

.lightbox-counter {
    margin-top: 0.6rem;
    color: #f2efe9;
    text-align: center;
}

.video-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

.video-item iframe {
    width: 100%;
    aspect-ratio: 16 / 9;
    border: 0;
    border-radius: 10px;
    display: block;
}

.video-poster {
    position: relative;
    width: 100%;
    border: 0;
    padding: 0;
    cursor: pointer;
    background: transparent;
}

.video-poster img,
.video-frame {
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    border: 0;
    border-radius: 10px;
    display: block;
}

.video-play {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0, 0, 0, 0.72);
    color: #fff;
    padding: 0.45rem 0.75rem;
    border-radius: 999px;
    font-weight: 600;
    font-size: 0.9rem;
}

.site-footer {
    margin-top: 0;
    background: #1f1e1a;
    color: #ece8df;
}

.site-footer a {
    color: #fff;
}

.footer-grid {
    padding: 2.4rem 0;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
}

.footer-grid h2 {
    margin-top: 0;
    color: #fff;
    font-size: 1.04rem;
}

.footer-bottom {
    padding: 1rem 0 1.3rem;
    border-top: 1px solid #464238;
    font-size: 0.92rem;
}

@media (max-width: 980px) {
    .hero-layout,
    .cards-2,
    .cards-3,
    .realizations-grid,
    .video-grid,
    .project-photos,
    .footer-grid {
        grid-template-columns: 1fr;
    }

    .header-inner {
        min-height: auto;
        padding: 0.65rem 0 0.75rem;
        align-items: center;
        flex-wrap: wrap;
    }

    .logo {
        margin-right: auto;
    }

    .site-nav {
        display: none;
        width: 100%;
        padding-top: 0.5rem;
        border-top: 1px solid var(--border);
        margin-top: 0.45rem;
        gap: 0.4rem;
    }

    .site-nav.is-open {
        display: flex;
        flex-direction: column;
    }

    .site-nav a {
        font-size: 0.9rem;
        padding: 0.52rem 0.65rem;
        white-space: normal;
    }

    .nav-toggle {
        display: inline-flex;
    }

    .hero {
        padding-top: 2rem;
    }
}

@media (max-width: 640px) {
    .container {
        width: min(1200px, 94%);
    }

    .section {
        padding: 2.5rem 0;
    }

    .hero {
        padding: 1.2rem 0 2.2rem;
    }

    .hero-copy h1 {
        font-size: clamp(1.65rem, 8vw, 2.2rem);
        margin-bottom: 0.8rem;
    }

    .lead {
        font-size: 0.98rem;
        line-height: 1.6;
    }

    .button {
        width: 100%;
        text-align: center;
    }

    .article-back .button {
        width: auto;
        display: inline-block;
    }

    .hero-actions {
        gap: 0.5rem;
    }

    .project-preview img {
        height: 180px;
    }

    .project-photos {
        grid-template-columns: 1fr 1fr;
        gap: 0.5rem;
    }

    .footer-grid {
        gap: 0.2rem;
        padding: 1.8rem 0;
    }

    .lightbox-content {
        width: 96vw;
        margin-top: 2vh;
    }

    #lightbox-image {
        max-height: 70vh;
    }

    .lightbox-controls {
        flex-wrap: wrap;
        gap: 0.38rem;
    }

    .lightbox-controls button {
        min-width: 40px;
        padding: 0.38rem 0.62rem;
    }
}
