/* @font-face {
  font-family: "Cinzel";
  src: url("fonts/Cinzel.ttf?#iefix") format("truetype");
}
@font-face {
  font-family: "CormorantGaramond";
  src: url("fonts/CormorantGaramond.ttf?#iefix") format("truetype");
} */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: Arial, sans-serif
}

html {
  scroll-behavior: smooth;
}

body {
  background: #F1EAE5;
  color: #1d1d1d;
}

/* Loader na pełny ekran */
#pageLoader {
  position: fixed;
  inset: 0;
  background: #f1eae5;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
}

/* Prosty spinner */
.spinner {
  width: 60px;
  height: 60px;
  border: 6px solid #ccc;
  border-top: 6px solid #1d1d1d;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}


/* ================= HEADER ================= */
header {
  position: fixed;
  top: 0;
  width: 100%;
  padding: 10px 5vw;
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 100;
  background: rgba(0,0,0,.4);
  backdrop-filter: blur(10px);
}

header .logo-container {
  display: flex;
  align-items: center;
  gap: 10vw; 
}

header .logo a {
  width: 150px;
  display: block;
}

header .logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

header nav a {
  color: #fff;
  text-decoration: none;
  margin-left: 60px;
  font-size: 20px;
  font-weight: 100;
  opacity: .85;
}

header nav a:hover {
  opacity: 1;
}

.burger, .mobile-nav {
  display: none;
}

/* ================= HERO / VIDEO================= */

.hero {
  height: 100vh;
  overflow: hidden;
}

.hero video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ================= SECTIONS ================= */

section {
  padding: 100px 5vw 50px 5vw;
}

section h2 {
  font-size: 3rem;
  margin-bottom: 40px;
  font-weight: 100;
  color: #102C57;
}

/* ================= GALLERIES ================= */

.gallery {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: 260px;
  gap: 20px;
}

.gallery img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  cursor: pointer;
  transition: transform .5s ease, filter .5s ease;
}

/* mosaic */
.gallery img:nth-child(1) {
  grid-column: span 2;
  grid-row: span 2;
}
.gallery img:nth-child(4) {
  grid-row: span 2;
}


.gallery img:hover {
  transform: scale(1.04);
  filter: brightness(1.1);
}

.gallery2 img:nth-child(6) {
  grid-column: span 2;
}

/* ===== INTERIORS (2–1–2 layout) ===== */
.gallery-interior {
  display: grid;
  grid-template-columns: 1fr 1.5fr 1fr;
  grid-template-rows: repeat(2, 280px);
  gap: 20px;
}

.gallery-interior img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* left */
.gallery-interior img:nth-child(1) { grid-column: 1; grid-row: 1; }
.gallery-interior img:nth-child(2) { grid-column: 1; grid-row: 2; }

/* center hero */
.gallery-interior img:nth-child(3) {
  grid-column: 2;
  grid-row: 1 / span 2;
}

/* right */
.gallery-interior img:nth-child(4) { grid-column: 3; grid-row: 1; }
.gallery-interior img:nth-child(5) { grid-column: 3; grid-row: 2; }

/* ================= LIGHTBOX ================= */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(15,15,15,.95);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 200;
  animation: fadeIn .4s ease;
}

.lightbox img {
  max-width: 92vw;
  max-height: 85vh;
  object-fit: contain;
  animation: zoomIn .4s ease;
}

@keyframes fadeIn {
  from { opacity: 0 }
  to { opacity: 1 }
}
@keyframes zoomIn {
  from { transform: scale(.95) }
  to { transform: scale(1) }
}

/* arrows */
.arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  font-size: 4.5rem;
  color: #fff;
  cursor: pointer;
  padding: 30px;
  opacity: .85;
  transition: opacity .3s, transform .3s;
}

.arrow:hover {
  opacity: 1;
  transform: translateY(-50%) scale(1.1);
}

.arrow.left { left: 40px; }
.arrow.right { right: 40px; }


.close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 40px;
  height: 40px;
  background: none;
  border: none;
  cursor: pointer;
  opacity: .85;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity .3s, transform .3s;
}

.close svg {
  width: 100%;
  height: 100%;
  stroke: white;
  stroke-width: 2.5;
  stroke-linecap: round;
}

.close:hover {
  opacity: 1;
  transform: scale(1.1);
}


/* ================= FOOTER ================= */
footer {
  background-color: #102C57;
  color: #fff;
  padding: 40px 5vw 10px;
  width: 100%;
  margin-top: 50px;
}


footer .client a {
  color: #fff;
  text-decoration: none;
  display: block;
  border-bottom: 1px solid transparent; 
  transition: border-color .7s linear;
    font-size: 17px;
}

footer .client a:hover {
  border-bottom-color: #fff; 
}

.client {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
}


.client .logo img {
  width: 250px;
  height: auto;
}

.client .data p {
  margin: 5px 0;
  font-size: 17px;
}

.atelier {
  margin-top: 30px;
  text-align: center;
  margin-left: 50px;

}

.atelier p, .atelier a {
  font-size: 15px;
  color: white;
}



/* ==================================================
   MEDIA QUERIES 
   ================================================== */

@media (max-width: 1100px) {
    header nav a {
        font-size: 22px;
        margin-left: 40px;
    }

    header {
        background-color: #102C57;
    }

    section {
        padding: 100px 5vw 40px 5vw;
    }

    .hero {
        height: auto;
        margin-top: 80px;
    }

    .arrow {
        top: initial;
        bottom: 0px;
    }
}

@media (max-width: 900px) {
  header {
    padding: 10px 5vw;
    justify-content: space-between;

  }

  header .logo-container {
    gap: 0; 
    width: 100%;
    justify-content: space-between;
  }

  nav {
    display: none; 
  }

  .burger {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 22px;
    cursor: pointer;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 110;
  }

  .burger span {
    display: block;
    height: 1px;
    background: #fff;
    border-radius: 2px;
    transition: all 0.4s ease;
  }

  /* animacja burger → X */
  .burger.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
  }
  .burger.active span:nth-child(2) {
    opacity: 0;
  }
  .burger.active span:nth-child(3) {
        transform: rotate(-45deg) translate(10px, -9px);
  }

  .mobile-nav {
    display: flex;
    position: absolute;
    top: 100%; /* zaraz pod headerem */
    left: 0;
    width: 100%;
    max-height: 100px;
    background: rgba(16,44,87,0.95);
    justify-content: space-around; /* linki obok siebie */
    align-items: center;
    overflow: hidden;
    transition: max-height 0.4s ease, opacity 0.4s ease;
    opacity: 0;
    pointer-events: none;
    z-index: 100;
  }

  .mobile-nav a {
    color: #fff;
    font-size: 20px;
    text-decoration: none;
    padding: 10px 0;
  }

  /* menu aktywne */
  .mobile-nav.open {
    max-height: 100px;
    opacity: 1;
    pointer-events: all;
  }


    section {
        padding: 90px 5vw 45px;
    }

    section h2 {
        font-size: 2.2rem;
    }

    .hero {
      margin-top: 80px;
    }

  /* =======================
     STANDARD GALLERY (7)
     ======================= */

  .gallery {
    grid-template-columns: repeat(2, 1fr);
    grid-auto-rows: 180px;
    gap: 16px;
  }

  /* reset desktop mosaic */
  .gallery img {
    grid-column: auto !important;
    grid-row: auto !important;
    width: 100%;
    height: 100%;
    object-fit: cover;
  }

  /* 1 – BIG */
  .gallery img:nth-child(1) {
    grid-column: 1 / span 2;
    grid-row: span 2;
  }

  /* 4–5 slightly taller */
  .gallery img:nth-child(4),
  .gallery img:nth-child(5) {
    grid-row: span 2;
  }

  /* =======================
     INTERIOR GALLERY (5)
     ======================= */

  .gallery-interior {
    grid-template-columns: repeat(2, 1fr);
    grid-auto-rows: 180px;
    gap: 16px;
  }

  .gallery-interior img {
    grid-column: auto !important;
    grid-row: auto !important;
    width: 100%;
    height: 100%;
    object-fit: cover;
  }

  /* 3 – BIG CENTER */
  .gallery-interior img:nth-child(3) {
    grid-column: 1 / span 2;
    grid-row: span 2;
  }

  /* =======================
     LIGHTBOX CONTROLS
     ======================= */

  .arrow {
    font-size: 3rem;
    padding: 14px;
  }

  .arrow.left { left: 10px; }
  .arrow.right { right: 10px; }

  .close {
    width: 44px;
    height: 44px;
    top: 16px;
    right: 16px;
  }

  .close svg {
    stroke-width: 2;
  }

  footer .client {
    flex-wrap: wrap;
  }

  footer .client .logo {
    width: 100%;
    text-align: center;
    margin-bottom: 50px;
  }

  footer .client .data{
    width: 45%;
    text-align: center;
  }
}


@media (max-width: 600px) {

  .mobile-nav a {
    font-size: 16px;
  }

  .hero {
    height: auto;
    /* margin-top: 60px; */
  }

  section {
    padding: 60px 5vw 20px;
  }

  footer .client .data {
    width:100%;
     text-align: center;
     margin-bottom: 20px;
  }

  footer .atelier  {
    margin-left: 0;
  }

  footer .atelier a {
    display: block;
  }
}


@media (max-width: 400px) {
  header .logo a {
    width: 100px;
  } 

  .hero {
    margin-top: 60px;
  }

  .burger {
    top: 30px;
    height: 15px;
  }

  .burger.active span:nth-child(3) {
        transform: rotate(-45deg) translate(5px, -5px);
    }
}