/* RESET / BASE */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
}

body {
  font-family: Arial, Helvetica, sans-serif;
  line-height: 1.5;
  color: #222;
  background: #f5f5f5;
  scroll-behavior: smooth;
}

/* CONTAINER */

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* HEADER */

.site-header {
  background: #fff;
  border-bottom: 1px solid #ddd;
}

.header-inner {
  padding: 1.5rem 0 0.75rem;
  text-align: center;
}

.logo img {
  display: block;
  max-height: 60px;
  width: auto;
  margin: 0 auto 0.75rem;
}

/* MAIN NAV */

.main-nav {
  display: inline-flex;
  gap: 1.8rem;
}

.main-nav a {
  color: #000;
  text-decoration: none;
  font-size: 0.9rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.main-nav a:hover {
  text-decoration: underline;
}

/* PAGE */

.page {
  padding: 2.5rem 0 3.5rem;
}

/* HERO (wszystkie sekcje z obrazem + kartą) */

.hero-row {
  position: relative;
  margin-bottom: 3rem;
}

/* obraz – trochę szerszy niż karta, przesunięty w lewo; karta nachodzi na ~20% prawej części */

.hero-media {
  position: relative;
  width: 60%;
  margin-left: 5%;
  aspect-ratio: 16 / 9;
  background-size: cover;
  background-position: center;
  cursor: pointer;
}

/* konkretne obrazy */

.hero-media-home    { background-image: url("home.png"); }
.hero-media-scms    { background-image: url("scms.png"); }
.hero-media-service { background-image: url("service.png"); }
.hero-media-sales   { background-image: url("sales.png"); }
.hero-media-contact { background-image: url("contact.png"); }

/* biały blok – wspólny wygląd Home/SCMS/Service/Sales/Contact */

.hero-card {
  position: absolute;
  top: 12%;
  left: 50%;
  transform: translateX(0);
  width: 40%;
  min-height: 55%;
  background: rgba(255,255,255,0.95);
  padding: 2.3rem 3rem;
  box-shadow: 0 10px 30px rgba(0,0,0,0.15);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  justify-content: center;
  text-align: center;
}

.hero-card h1,
.hero-card h2 {
  margin: 0 0 1rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-card h1 {
  font-size: 1.7rem;
}

.hero-card h2 {
  font-size: 1.3rem;
}

.hero-card p {
  margin: 0 0 0.75rem;
  font-size: 1rem;
}

/* (opcjonalnie) jeżeli kiedyś zechcesz wrócić do kart „naprzemiennych”,
   poniższe klasy zostają do użycia – teraz ich nie używamy, ale nie przeszkadzają */

.card-row {
  display: flex;
  justify-content: center;
  margin-bottom: 2.5rem;
}

.card {
  position: relative;
  display: flex;
  align-items: center;
  background: transparent;
  border: none;
  box-shadow: none;
}

.card-left {
  flex-direction: row;
}

.card-right {
  flex-direction: row-reverse;
}

.card-media {
  width: 60vw;
  max-width: 720px;
  aspect-ratio: 16 / 9;
  flex-shrink: 0;
  background-size: cover;
  background-position: center;
}

.card-media-green { background: #2ecc71; }
.card-media-red   { background: #e74c3c; }
.card-media-blue  { background: #3498db; }

.card-content-overlay {
  position: absolute;
  top: 50%;
  right: 5%;
  transform: translateY(-50%);
  width: 40vw;
  max-width: 460px;
  background: rgba(255,255,255,0.9);
  padding: 2.3rem 3rem;
  box-shadow: 0 10px 30px rgba(0,0,0,0.10);
}

.card-content-overlay-left {
  left: 5%;
  right: auto;
}

.card-content-overlay h2,
.card-content-overlay p {
  text-align: center;
}

.card-content-overlay h2 {
  margin: 0 0 1rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 1.3rem;
}

.card-content-overlay p {
  margin: 0 0 0.75rem;
  font-size: 1rem;
}

/* FOOTER */

.site-footer {
  background: #fff;
  border-top: 1px solid #ddd;
  padding: 1.2rem 0 1.6rem;
  font-size: 0.8rem;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.footer-text {
  color: #666;
}

.footer-nav {
  display: inline-flex;
  gap: 1rem;
}

.footer-nav a {
  color: #000;
  text-decoration: none;
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.footer-nav a:hover {
  text-decoration: underline;
}

/* LIGHTBOX */

.lightbox {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 9999;
}

.lightbox.is-open {
  display: flex;
}

.lightbox-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.8);
}

.lightbox-inner {
  position: relative;
  max-width: 95vw;
  max-height: 95vh;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.lightbox-image {
  max-width: 100%;
  max-height: 85vh;
  border-radius: 4px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.4);
  background: #000;
}

.lightbox-close {
  position: absolute;
  top: -2.2rem;
  right: 0;
  background: none;
  border: none;
  color: #fff;
  font-size: 2rem;
  cursor: pointer;
}

.lightbox-controls {
  margin-top: 0.75rem;
  display: flex;
  gap: 0.5rem;
}

.lightbox-prev,
.lightbox-next {
  min-width: 2.2rem;
  min-height: 2.2rem;
  border-radius: 999px;
  border: none;
  background: rgba(255,255,255,0.9);
  cursor: pointer;
  font-size: 1.2rem;
}

/* RESPONSIVE */

@media (max-width: 900px) {
  .hero-row {
    margin-bottom: 2.5rem;
  }

  .hero-media {
    position: static;
    width: 100%;
    margin-left: 0;
    aspect-ratio: 16 / 9;
  }

  .hero-card {
    position: static;
    width: 100%;
    margin-top: 1rem;
    box-shadow: none;
  }

  .card-media {
    width: 100%;
    max-width: none;
  }

  .card-content-overlay,
  .card-content-overlay-left {
    position: static;
    transform: none;
    width: 100%;
    max-width: none;
    margin-top: 1rem;
    box-shadow: none;
    padding: 1.75rem 1.5rem;
    background: rgba(255,255,255,0.95);
  }
}

@media (max-width: 600px) {
  .main-nav,
  .footer-nav {
    gap: 0.75rem;
    flex-wrap: wrap;
    justify-content: center;
  }

  .card-row {
    margin-bottom: 2rem;
  }
}
