/* Tercet — kompletny styl v3.
   Zastępuje styles.css w całości. Jeden plik, brak konfliktów. */

/* ============ RESET / TYPOGRAFIA ============ */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
img { border: 0; max-width: 100%; height: auto; }
ul, li { list-style: none; margin: 0; padding: 0; }

html, body {
    height: 100%;
    background: #d6d6d6 url(../images/body-bg.jpg) center top repeat-x;
    font-family: arial, sans-serif;
    font-size: 12px;
    line-height: 17px;
    color: #472e08;
}
body.body-page {
    background: #d6d6d6 url(../images/top-bg.png) center 46px repeat-x;
}

a { color: #563a24; }
a:hover { color: #694e39; }

/* ============ KONTENER GŁÓWNY ============ */
#container {
    min-height: 100%;
    position: relative;
    padding-bottom: 98px;
}

/* ============ HEADER (menu + logo + flagi) ============ */
#header {
    width: 100%;
    height: 212px;
    position: relative;
    background: url(../images/top-bg.png) center 46px repeat-x;
}
#header > .content {
    width: 1000px;
    height: 212px;
    margin: 0 auto;
    position: relative;
}

#header .menu {
    width: 100%;
    height: 160px;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding-top: 30px;
}
#header ul#nav {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 25px;
    width: 100%;
    height: 100%;
}
#header ul#nav li {
    display: flex;
    align-items: center;
}
/* Fizyczny spacer w środku menu na logo */
#header ul#nav li.logo-gap {
    width: 360px;
    min-width: 360px;
    pointer-events: none;
    visibility: hidden;
}

#header ul#nav li a {
    display: block !important;
    height: 18px;
    text-indent: -9999px !important;
    overflow: hidden !important;
    background-repeat: no-repeat;
    background-position: 0 0;
    text-decoration: none;
}
#header ul#nav li a:hover { background-position: 0 -18px; }

a.button1.but { width: 41px;  background-image: url(../images/top-b1.png); }
a.button2.but { width: 75px;  background-image: url(../images/top-b2.png); }
a.button3.but { width: 47px;  background-image: url(../images/top-b3.png); }
a.button4.but { width: 53px;  background-image: url(../images/top-b4.png); }
a.button5.but { width: 119px; background-image: url(../images/top-b5.png); }
a.button6.but { width: 62px;  background-image: url(../images/top-b6.png); }

a.button1eng.but { width: 41px; background-image: url(../images/top-b1.png); }
a.button2eng.but { width: 69px; background-image: url(../images/topeng-b2.png); }
a.button3eng.but { width: 39px; background-image: url(../images/topeng-b3.png); }
a.button4eng.but { width: 54px; background-image: url(../images/topeng-b4.png); }
a.button5eng.but { width: 90px; background-image: url(../images/topeng-b5.png); }
a.button6eng.but { width: 58px; background-image: url(../images/topeng-b6.png); }

a.button1de.but { width: 41px;  background-image: url(../images/top-b1.png); }
a.button2de.but { width: 68px;  background-image: url(../images/topde-b2.png); }
a.button3de.but { width: 62px;  background-image: url(../images/topde-b3.png); }
a.button4de.but { width: 53px;  background-image: url(../images/topde-b4.png); }
a.button5de.but { width: 115px; background-image: url(../images/topde-b5.png); }
a.button6de.but { width: 62px;  background-image: url(../images/top-b6.png); }

.site-logo {
    display: block;
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 314px;
    height: 212px;
    z-index: 5;
    pointer-events: none;
}

.jezyki {
    position: absolute;
    top: 215px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 20;
}
.jezyki ul.lang-inline {
    display: flex;
    gap: 8px;
}
.jezyki .lang-flag {
    display: block;
    width: 22px;
    height: 22px;
    background-repeat: no-repeat;
    background-position: 0 0;
    text-indent: -9999px;
    overflow: hidden;
    opacity: 0.55;
    transition: opacity 0.2s;
}
.jezyki .lang-flag:hover,
.jezyki .lang-flag.lang-active { opacity: 1; }

/* ============ BODY (treść) ============ */
#body { width: 100%; }
#body > .content {
    width: 100%;
    margin: 0 auto;
    position: relative;
}
.home-slider { width: 920px; height: 0; margin: 0 auto; }

#body .content .bottom {
    display: block;
    width: 100%;
    margin: 60px 0 30px 0;
    background: url(../images/content-bg.png) center 0 repeat-x;
}
body.body-home #body .content .bottom { margin-top: 80px; }
#body .content .bottom > .content {
    width: 100%;
    min-height: 300px;
    padding: 60px 0 0 0;
}
#body .content .bottom .main {
    width: 100%;
    color: #472e08;
    font-size: 12px;
    line-height: 17px;
}

/* ============ ITEM-PAGE ============ */
.item-page {
    display: block;
    width: 960px;
    max-width: 100%;
    margin: 0 auto;
    background: url(../images/content-titleline.png) no-repeat center 30px;
    position: relative;
}
.item-page h1 {
    display: block;
    height: 40px;
    margin: 0 auto 30px auto;
    text-indent: -9999px;
    overflow: hidden;
    background-repeat: no-repeat;
    background-position: center 0;
}

.item-page.nag1 h1, .item-page.nag1eng h1, .item-page.nag1de h1 {
    width: 82px; height: 25px; background-image: url(../images/content-title1.png);
}
.item-page.nag2 h1    { width: 150px; height: 37px; background-image: url(../images/content-title2.png); }
.item-page.nag2eng h1 { width: 140px; height: 27px; background-image: url(../images/contenteng-title2.png); }
.item-page.nag2de h1  { width: 141px; height: 28px; background-image: url(../images/contentde-title2.png); }
.item-page.nag3 h1    { width: 96px;  height: 37px; background-image: url(../images/content-title3.png); }
.item-page.nag3eng h1 { width: 80px;  height: 37px; background-image: url(../images/contenteng-title3.png); }
.item-page.nag3de h1  { width: 126px; height: 37px; background-image: url(../images/contentde-title3.png); }
.item-page.nag4 h1    { width: 108px; height: 35px; background-image: url(../images/content-title4.png); }
.item-page.nag4eng h1 { width: 107px; height: 37px; background-image: url(../images/contenteng-title4.png); }
.item-page.nag4de h1  { width: 105px; height: 35px; background-image: url(../images/contentde-title4.png); }
.item-page.nag5 h1    { width: 242px; height: 37px; background-image: url(../images/content-title5.png); }
.item-page.nag5eng h1 { width: 202px; height: 37px; background-image: url(../images/contenteng-title5.png); }
.item-page.nag5de h1  { width: 242px; height: 29px; background-image: url(../images/contentde-title5.png); }
.item-page.nag6 h1    { width: 127px; height: 33px; background-image: url(../images/content-title6.png); }
.item-page.nag6eng h1 { width: 117px; height: 23px; background-image: url(../images/contenteng-title6.png); }
.item-page.nag6de h1  { width: 127px; height: 33px; background-image: url(../images/content-title6.png); }

/* ============ HOME: 3 bloki flexbox + karuzela ============ */
.item-page.nag1,
.item-page.nag1eng,
.item-page.nag1de {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: stretch;   /* równa wysokość kafelków */
}
.item-page.nag1 > h1,
.item-page.nag1eng > h1,
.item-page.nag1de > h1 {
    flex-basis: 100%;
    width: 100%;
}

/* Karuzela trzech zdjęć na home — pod menu i flagami */
/* Karuzela na home — 3 zdjęcia widoczne, środkowe aktywne, infinite scroll, prev/next */
.home-carousel {
    width: 1065px;
    max-width: 100%;
    height: 330px;
    margin: 50px auto 20px;
    position: relative;
}
.hc-viewport {
    width: 100%;
    height: 100%;
    overflow: hidden;
}
.hc-slides {
    display: flex;
    align-items: center;
    height: 100%;
    margin: 0;
    padding: 0;
    list-style: none;
    width: max-content;
    will-change: transform;
}
.hc-slide {
    flex-shrink: 0;
    width: 350px;
    height: 290px;
    margin-right: 5px;
    list-style: none;
    box-sizing: border-box;
    background: transparent;
    border: 0;
    box-shadow: none;
    opacity: 0.55;
    transform: scale(0.85);
    transition: opacity 0.5s ease, transform 0.5s ease;
}
.hc-slide.hc-active {
    opacity: 1;
    transform: scale(1.0);
    z-index: 5;
}
.hc-slide img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
    border: 0;
}
.hc-prev, .hc-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    background: rgba(86, 58, 36, 0.7);
    color: #fff;
    border: 0;
    border-radius: 50%;
    cursor: pointer;
    font-size: 28px;
    line-height: 1;
    z-index: 10;
    transition: background 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}
.hc-prev:hover, .hc-next:hover { background: rgba(71, 46, 8, 0.9); }
.hc-prev { left: -20px; }
.hc-next { right: -20px; }

/* ============ BLOCK ============ */
.block {
    display: flex;
    flex-direction: column;
    width: 302px;
    margin: 15px 5px;
    text-align: center;
    line-height: 22px;
    flex-shrink: 0;
}
.block .first {
    width: 302px; height: 11px; display: block;
    background: url(../images/content-paper1-top.png) no-repeat;
    text-indent: -9999px; overflow: hidden;
    flex-shrink: 0;
}
.block .second {
    width: 302px;
    display: flex;
    flex-direction: column;
    flex: 1;          /* wypełnia dostępną wysokość — wyrównuje kafelki */
    background: url(../images/content-paper1-center.png) repeat-y;
    padding: 0 25px; box-sizing: border-box;
}
.block .second > p:last-of-type,
.block .second > a:last-of-type {
    margin-top: auto;   /* przycisk "Czytaj więcej" / ostatni paragraf przy dolnej krawędzi */
}
.block .third {
    width: 302px; height: 53px; display: block;
    background: url(../images/content-paper1-bottom.png) no-repeat;
    text-indent: -9999px; overflow: hidden;
    flex-shrink: 0;
}
.block hr {
    width: 256px; height: 5px; border: 0;
    background: url(../images/content-paper-line.png) no-repeat;
    margin: 6px auto 12px;
}
.block img { display: block; margin: 0 auto; max-width: 252px; }
.block .button,
.block .buttoneng,
.block .buttonde {
    display: block; width: 146px; height: 17px; margin: 10px auto;
    text-indent: -9999px; overflow: hidden; background-repeat: no-repeat;
}
.block .button    { background-image: url(../images/content-paper-button.png); }
.block .buttoneng { background-image: url(../images/content-papereng-button.png); }
.block .buttonde  { background-image: url(../images/content-paperde-button.png); }
.block .button:hover,
.block .buttoneng:hover,
.block .buttonde:hover { background-position: 0 -17px; }

.blocktit1, .blocktit2, .blocktit3,
.blockengtit1, .blockengtit2, .blockengtit3,
.blockdetit1, .blockdetit2, .blockdetit3 {
    display: block; height: 30px; margin: 0 auto;
    text-indent: -9999px; overflow: hidden; background-repeat: no-repeat;
}
.blocktit1    { width: 76px;  background-image: url(../images/content-paper-title1.png); }
.blocktit2    { width: 193px; background-image: url(../images/content-paper-title2.png); }
.blocktit3    { width: 153px; background-image: url(../images/content-paper-title3.png); }
.blockengtit1 { width: 76px;  background-image: url(../images/content-papereng-title1.png); }
.blockengtit2 { width: 158px; background-image: url(../images/content-papereng-title2.png); }
.blockengtit3 { width: 115px; background-image: url(../images/content-papereng-title3.png); }
.blockdetit1  { width: 100px; background-image: url(../images/content-paperde-title1.png); }
.blockdetit2  { width: 187px; background-image: url(../images/content-paperde-title2.png); }
.blockdetit3  { width: 111px; background-image: url(../images/content-paperde-title3.png); }

/* ============ BLOCK2 ============ */
.block2 {
    display: block; width: 964px; max-width: 100%; margin: 15px auto;
    text-align: left; line-height: 22px;
}
.block2 .first {
    width: 964px; height: 11px; display: block;
    background: url(../images/content-paper2-top.png) no-repeat;
    text-indent: -9999px; overflow: hidden;
}
.block2 .second {
    width: 964px;
    max-width: 100%;
    display: flow-root;
    background: url(../images/content-paper2-center.png) repeat-y;
    padding: 30px 80px;        /* solidny margines wewnętrzny od krawędzi tła PNG */
    box-sizing: border-box;
    text-align: justify;
    overflow: hidden;          /* obetnij wszystko co wystaje */
}
/* Wszystko wewnątrz musi zmieścić się w content area */
.block2 .second * {
    max-width: 100%;
    box-sizing: border-box;
}
.block2 .second p {
    margin: 8px 0;
}
.block2 .second img {
    height: auto !important;
}
.block2 .third {
    width: 964px; height: 53px; display: block;
    background: url(../images/content-paper2-bottom.png) no-repeat;
    text-indent: -9999px; overflow: hidden;
}
.block2 hr {
    width: 256px; height: 5px; border: 0;
    background: url(../images/content-paper-line.png) no-repeat;
    margin: 6px auto 12px;
}
.block2 img { margin: 5px; max-width: 100%; height: auto; }

/* ============ GALERIE — siatka miniatur ============ */
.gallery-grid,
.gallery-grid-5 {
    display: grid;
    gap: 6px;
    margin: 20px auto;
    width: 100%;
}
.gallery-grid   { grid-template-columns: repeat(4, 1fr); }
.gallery-grid-5 { grid-template-columns: repeat(5, 1fr); }

.gallery-grid .gallery-item,
.gallery-grid-5 .gallery-item {
    display: block;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: #f5f5f5;
    border: 2px solid #563a24;
    text-decoration: none;
    cursor: zoom-in;
}
.gallery-grid .gallery-item img,
.gallery-grid-5 .gallery-item img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover;
    display: block; margin: 0; border: 0;
    transition: transform 0.3s;
}
.gallery-grid .gallery-item:hover img,
.gallery-grid-5 .gallery-item:hover img {
    transform: scale(1.05);
}

/* ============ LIGHTBOX JS ============ */
.lb-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.93);
    z-index: 99999;
    flex-direction: column;
}
.lb-overlay.lb-open { display: flex; }

.lb-stage {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    padding: 60px 80px 20px;
    min-height: 0;
}
.lb-img {
    max-width: 100%;
    max-height: 100%;
    width: auto !important;
    height: auto !important;
    object-fit: contain;
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.6);
    border: 0;
}

.lb-overlay .lb-close,
.lb-overlay .lb-prev,
.lb-overlay .lb-next {
    background: rgba(255, 255, 255, 0.15);
    border: 0;
    color: #fff;
    cursor: pointer;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
    font-family: arial, sans-serif;
    line-height: 1;
    padding: 0;
}
.lb-overlay .lb-close:hover,
.lb-overlay .lb-prev:hover,
.lb-overlay .lb-next:hover { background: rgba(255, 255, 255, 0.35); }

.lb-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 44px;
    height: 44px;
    font-size: 28px;
    z-index: 2;
}
.lb-prev, .lb-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 54px;
    height: 54px;
    font-size: 40px;
    z-index: 2;
}
.lb-prev { left: 20px; }
.lb-next { right: 20px; }

.lb-counter {
    position: absolute;
    top: 25px;
    left: 25px;
    color: #fff;
    font-size: 13px;
    background: rgba(0, 0, 0, 0.4);
    padding: 5px 12px;
    border-radius: 12px;
    z-index: 2;
}

.lb-thumbs-wrap {
    flex-shrink: 0;
    overflow: hidden;
    padding: 8px 0 14px;
    background: rgba(0, 0, 0, 0.35);
}
.lb-thumbs {
    display: flex;
    gap: 6px;
    padding: 0 20px;
    overflow-x: auto;
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,0.3) transparent;
}
.lb-thumbs::-webkit-scrollbar { height: 6px; }
.lb-thumbs::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.3); border-radius: 3px; }
.lb-thumb {
    flex-shrink: 0;
    width: 60px;
    height: 60px;
    background-size: cover;
    background-position: center;
    border: 2px solid transparent;
    border-radius: 3px;
    cursor: pointer;
    opacity: 0.55;
    transition: opacity 0.2s, border-color 0.2s;
}
.lb-thumb:hover { opacity: 1; }
.lb-thumb.lb-thumb-active { opacity: 1; border-color: #fff; }

/* ============ GOOGLE MAPS ============ */
.google-map { margin: 20px auto; text-align: center; }
.google-map iframe { display: inline-block; max-width: 100%; border: 0; }

/* ============ KLIKALNE LINKI ============ */
.main a[href^="tel:"],
.main a[href^="mailto:"] {
    color: #563a24;
    text-decoration: none;
    border-bottom: 1px dotted #694e39;
}
.main a[href^="tel:"]:hover,
.main a[href^="mailto:"]:hover {
    color: #472e08; border-bottom-style: solid;
}

/* ============ FOOTER ============ */
#footer {
    position: absolute;
    bottom: 0; left: 0;
    width: 100%;
    height: 98px;
    background: url(../images/foot-bg.jpg) center top repeat-x;
}
#footer .content {
    width: 920px;
    height: 98px;
    margin: 0 auto;
    background: url(../images/foot-bottom.png) center top no-repeat;
    color: #563a24;
    font-size: 10px;
    text-align: center;
    text-transform: uppercase;
}
#footer .content span { display: block; padding: 75px 0 0 0; }
