@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@300;400;700&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;700&display=swap');

:root {
  --primary-color: white;
  --secondary-color: #2b2a29;
  --accent-color: #fcbb0a;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

* {
  scrollbar-width: thin;
  scrollbar-color: #fcbb0a transparent;
}

::-webkit-scrollbar {
  width: 0.5rem;
}

::-webkit-scrollbar-track {
  border-radius: 100vw;
  margin-block: 0.1rem;
  background-color: transparent;
}

::-webkit-scrollbar-thumb {
  background-color: var(--accent-color);
  border-radius: 100vw;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

.loader {
  position: fixed;
  background-color: var(--secondary-color);
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100vh;
  width: 100vw;
  top: 0;
  left: 0;
  z-index: 99999;
}

.loader-hidden {
  animation: loader 0.3s forwards;
}

@keyframes loader {
  0% {
    opacity: 1;
  }
  100% {
    opacity: 0;
  }
}

.loader::after,
.img-loader-active::after {
  content: '';
  width: 48px;
  height: 48px;
  border: 5px solid var(--primary-color);
  border-bottom-color: var(--accent-color);
  border-radius: 100vw;
  animation: rotation 1s linear infinite;
}

@keyframes rotation {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

body {
  margin: 0;
  font-family: 'Poppins', sans-serif;
  overflow: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  margin: 0;
  padding: 0;
  color: var(--secondary-color);
}

h2 {
  font-size: clamp(1.5rem, 1.2717rem + 1.3043vw, 2.25rem);
}

h3 {
  font-size: clamp(1.2rem, 1.1087rem + 0.5217vw, 1.5rem);
}

p {
  color: var(--secondary-color);
  line-height: 1.7;
  font-size: clamp(0.9rem, 0.8696rem + 0.1739vw, 1rem);
}

a {
  text-decoration: none;
}

img {
  max-width: 100%;
}

ul {
  padding: 0;
}

.container {
  max-width: 1200px;
  margin-inline: auto;
  padding: 0 1rem;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
  justify-content: center;
  align-items: start;
  padding: 2rem 0;
}

.text-center {
  text-align: center;
}

/* header */
.flex {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

header {
  box-shadow: 0px 1px 10px -5px rgb(58, 58, 58);
  padding: 0.5rem 0;
  position: sticky;
  top: 0;
  background-color: var(--primary-color);
  z-index: 2;
  /* height: 8vh; */
}

header img {
  height: auto;
  max-width: 8em;
}

header a {
  color: var(--secondary-color);
}

.navigation ul {
  list-style: none;
  white-space: nowrap;
  margin: 0;
  gap: 2rem;
}

.navigation ul a {
  color: var(--secondary-color);
  text-transform: uppercase;
  padding: 0.5rem 1.5rem;
  border-radius: 100vw;
  transition: all 0.3s;
}

.navigation ul a:is(:hover, :focus) {
  background-color: var(--secondary-color);
  color: var(--accent-color);
  outline: none;
}

.facebook {
  font-size: 1.5rem;
}

.navigation .facebook:hover {
  transform: translateY(-5px);
}

.navigation .facebook:is(:hover, :focus) {
  color: blue;
  background-color: transparent;
}

.logo-hamburger a {
  display: flex;
}

.hamburger {
  display: none;
  cursor: pointer;
  background: transparent;
  border: none;
  padding: 1rem;
  margin: 0;
}

.hamburger__box {
  height: 1.2rem;
  width: 2rem;
  display: grid;
  place-items: center;
  position: relative;
}

.hamburger__inner {
  height: 0.2rem;
  width: 100%;
  background-color: var(--secondary-color);
  border-radius: 100vw;
  transition: all 0.3s;
}

.hamburger__inner::after,
.hamburger__inner::before {
  content: '';
  height: inherit;
  width: inherit;
  background-color: var(--secondary-color);
  position: absolute;
  border-radius: inherit;
  left: 0;
  transition: all 0.3s;
}

.hamburger__inner::before {
  transform: translateY(-0.5rem);
}

.hamburger__inner::after {
  transform: translateY(0.5rem);
}

.hamburger-active .hamburger__inner {
  background-color: transparent;
}

.hamburger-active .hamburger__inner::before {
  transform: translateY(0) rotate(45deg);
}

.hamburger-active .hamburger__inner::after {
  transform: translateY(0) rotate(-45deg);
}

/* HERO SECTION */
.hero {
  height: 95vh;
  height: 95svh;
  background-image: url('images/realizacje/20221004_154802.webp');
  background-image: -webkit-image-set(
    url('images/realizacje/20221004_154802.webp') 1x,
    url('images/realizacje/20221004_154802_downsized.webp') 2x
  );
  background-image: image-set(
    url('images/realizacje/20221004_154802.webp') 1x,
    url('images/realizacje/20221004_154802_downsized.webp') 2x
  );
  background-size: cover;
  background-position: center;
  display: grid;
  position: relative;
  place-items: center;
  animation: heroAnimation 1s;
  animation-play-state: paused;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
}

@keyframes heroAnimation {
  0% {
    opacity: 0;
    transform: translateY(-100%);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero-info {
  z-index: 1;
}

.hero-info h1 {
  color: var(--primary-color);
  font-size: clamp(0.9rem, 0.8087rem + 0.5217vw, 1.2rem);
  /* color: var(--accent-color); */
  margin: 0.5rem 0;
}

.hero img {
  height: auto;
  max-width: 100%;
}

.hero-info p {
  font-size: clamp(1rem, 4vw, 1.5rem);
  margin: 0;
  color: white;
}

.hero-info .btns {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 1rem;
}

.btn {
  width: 15rem;
  white-space: nowrap;
  padding: 0.8rem 1.6rem;
  border-radius: 0.5rem;
}

.cta-1 {
  background-color: var(--accent-color);
  color: var(--secondary-color);
  font-weight: bold;
}

.cta-2 {
  background-color: var(--secondary-color);
  font-weight: bold;
  color: white;
}

.btn::after {
  content: '\f061';
  font-family: 'Font Awesome 6 Free';
  font-weight: 900;
  opacity: 0;
  position: relative;
  left: 0;
  transition: all 0.3s;
}

.btn:hover::after {
  left: 0.5rem;
  opacity: 1;
}

/* offer */

.offer,
.work-range,
.showcase {
  padding: 1rem 0;
}

.offer,
.showcase {
  position: relative;
}

.offer::before,
.showcase::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: url('./images/background_downsized.webp');
  background-size: cover;
  filter: grayscale(1);
  z-index: -1;
}

.offer .icon-wrapper {
  border: 2px solid var(--secondary-color);
  width: 5rem;
  aspect-ratio: 1 / 1;
  margin-inline: auto;
  border-radius: 100vw;
  margin-bottom: 1rem;
}

.icon-wrapper.flex {
  justify-content: center;
}

.offer .icon {
  font-size: 2.5rem;
  color: var(--accent-color);
}

/* work-range */
.work-range {
  color: var(--secondary-color);
  z-index: 1;
  background-color: var(--primary-color);
}

/* why-choose-us */
.work-range {
  background-color: var(--primary-color);
}

/* showcase */
.showcase .card-icon {
  font-size: 5rem;
}

.showcase p {
  font-weight: bold;
  font-size: 1.2rem;
}

/* location */
.location {
  line-height: 0;
  z-index: 100;
}

.map {
  width: 100%;
  height: 30rem;
  border: none;
  margin: 0;
}

/* grid-item */

.grid-item {
  opacity: 0;
}

.grid-item.show:first-child {
  opacity: 1;
  transition: opacity 0.5s;
}

.grid-item.show:nth-child(2) {
  opacity: 1;
  transition: opacity 0.5s 0.5s;
}

.grid-item.show:last-child {
  opacity: 1;
  transition: opacity 0.5s 1s;
}

/* footer */
footer {
  background-color: var(--secondary-color);
  color: white;
}

footer .grid {
  padding: 2rem 0;
}

footer img {
  height: auto;
  max-width: 10rem;
}

footer h2 {
  margin-bottom: 1rem;
  font-size: 1.2rem;
  color: white;
}

footer a {
  color: white;
}

footer a:hover {
  color: var(--accent-color);
}

footer .icon {
  margin-right: 0.5rem;
}

.bold {
  font-weight: bold;
}

.copyright {
  background-color: var(--accent-color);
  display: block;
  color: var(--secondary-color);
}

.wrapper {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

main {
  flex-grow: 1;
}

/* O Nas */
.about_us,
.offer-page,
.gallery {
  padding: 2rem 0;
}

.about_us img {
  border-radius: 1rem;
  /* height: 80%; */
  width: 80%;
}

.about_us p {
  margin-top: 0;
}

.about_us .cities {
  margin-top: 0.5rem;
}

/* Oferta */
.option {
  box-shadow: 0px 0px 15px -5px;
  border-radius: 1rem;
  height: 100%;
}

.option img {
  width: 15rem;
  display: block;
  margin-inline: auto;
  border-top-left-radius: 1rem;
  border-top-right-radius: 1rem;
}

.option-info {
  padding: 1rem;
}

.offer-page h3 {
  font-size: 1.3rem;
}

.offer-page ol ul {
  padding-left: 1.5rem;
}

.img-container {
  height: 100%;
  overflow: hidden;
  border-radius: 0.5rem;
  cursor: pointer;
}

.image {
  width: 100%;
  height: 100%;
  border-radius: inherit;
  object-fit: cover;
  transform: scale(1);
  transition: transform 0.3s;
}

.image:hover {
  transform: scale(1.1);
}

.gallery-container {
  opacity: 0;
  visibility: hidden;
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0);
  z-index: 10000;
  transition: all 0.3s;
  transform-origin: center center;
}

.gallery-container img {
  max-height: 90vh;
  max-width: 95vw;
}

.gallery-container-open {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, -50%) scale(1);
}

.gallery-container .close {
  position: absolute;
  cursor: pointer;
  top: 0.5rem;
  right: 0.5rem;
  font-size: 1.5rem;
  color: var(--accent-color);
}

.overlay {
  opacity: 0;
  visibility: hidden;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.8);
  z-index: 9999;
  transition: all 0.3s;
}

.overlay_active {
  opacity: 1;
  visibility: visible;
}

.img-loader-active {
  position: fixed;
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100vh;
  width: 100vw;
  top: 0;
  left: 0;
}

@media (max-width: 768px) {
  /* header */
  header .flex {
    flex-direction: column;
    gap: 0;
  }

  header img {
    width: 6rem;
  }

  .logo-hamburger {
    display: flex;
    width: 100%;
    justify-content: space-between;
    align-items: center;
  }

  .hamburger {
    display: block;
  }

  .navigation {
    width: 100%;
    display: grid;
    grid-template-rows: 0fr;
    transition: grid-template-rows 0.5s;
  }

  .navigation ul {
    overflow: hidden;
  }

  .navigation ul li {
    width: 100%;
    text-align: center;
    margin: 1rem;
  }

  .navigation a {
    display: block;
  }

  .navigation-active {
    grid-template-rows: 1fr;
  }

  .about_us img {
    width: 100%;
  }

  .navigation .facebook {
    display: none;
  }
}

@media (max-width: 550px) {
  .about_us img {
    width: 100%;
    max-height: 15rem;
    object-fit: cover;
    object-position: 0 45%;
  }

  .about_us .grid {
    grid-template-columns: 1fr;
  }
}
