/* Turn.js */

#hero {
  overflow: hidden !important;
  position: relative;
}

#hero .flipbook-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 100;
  background: transparent;
  pointer-events: auto;
  touch-action: pan-y;
  -webkit-touch-callout: none;
  -webkit-user-select: none;
  user-select: none;
}

#benefits-big {
  position: relative;
}

#benefits-big .benefits-holder {
  position: relative;
}

#benefits-big .benefits-card-holder {
  position: relative;
}

#benefits-big .flipbook-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 100;
  background: transparent;
  pointer-events: auto;
  touch-action: pan-y;
  -webkit-touch-callout: none;
  -webkit-user-select: none;
  user-select: none;
}

/* Hide overlay on desktop */
@media (min-width: 992px) {
  #hero .flipbook-overlay {
    display: none;
  }

  #benefits-small .flipbook-overlay {
    display: none;
  }
}

.container-fluid {
  width: 100vw !important;
  height: 90vh !important;
  display: flex !important;
  justify-content: center !important;
  align-items: center !important;
  position: relative !important;
  margin: 0 !important;
  padding: 0 !important;
}

.turn-page-wrapper {
  margin: 0 auto !important;
  left: 50% !important;
  transform: translateX(-50%) !important;
}

/* Background Rectangle */
/* #background-rectangle {
    position: fixed;
    top: 47.5%;
    left: 50%;
    transform: translate(-50%, -226.5%);
    width: 342px;
    height: 300px;
    background-color: #f5c06e;
    z-index: 10;
} */

/* Flip Book Container */
.flipbook {
  width: 95vw;
  height: 95vh;
  max-width: 1459px;
  max-height: 821px;
  margin: 0;
  position: relative;
  overflow: visible !important;
  left: 0 !important;
  right: 0 !important;
  border-radius: 76px;
  z-index: 1;
  background-color: #20481c !important;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3), 0 10px 20px rgba(0, 0, 0, 0.2), 0 0 30px rgba(245, 192, 110, 0.1) !important;
}

.shadow {
  left: 0 !important;
  border-radius: 76px;
}

/* Individual Pages */
.page {
  width: 95vw;
  height: 95vh;
  max-width: 1459px;
  max-height: 821px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  border: none;
  margin: 0;
}

.page-content {
  padding: 30px;
  text-align: center;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 15px;
}

/* Cover and Back Cover */

#hero .cover {
  background-color: #20481c;
  /* color: white; */
  border-radius: 76px;
}

.cover {
  /* background-color: #20481c; */
  /* color: white; */
}

.cover .page-content {
  text-align: center;
}

.back-cover {
  /* background-color: #20481c; */
  /* color: white; */
}

.back-cover .page-content {
  text-align: center;
}

.cover-img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border-radius: 76px;
  box-shadow: none !important;
  border: 1px solid #143211;
}

/* Page Alternating Backgrounds */
.page:nth-child(odd) {
  /* background-color: #20481c; */
}

.page:nth-child(even) {
  /* background-color: #20481c; */
  background-image: url("../images/mask_jelkice-small-screen.png");
  object-fit: cover;
  border-radius: 76px;
}

/* Turn.js */

.benefits-card-holder {
  overflow: hidden !important;
}

.turn-page-wrapper {
  perspective: 2000px;
}

/* Fullscreen Design */
.page-content {
  padding: 40px;
  gap: 20px;
}

/* Vertical Flipbook Styles */
.vertical-flipbook {
  width: 100%;
  height: 100%;
  margin: 0;
  border-radius: 1rem;
  position: relative;
  overflow: visible !important;
  background-color: #20481c;
  z-index: 5;
  display: flex;
  justify-content: center;
  align-items: center;
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.25), 0 8px 15px rgba(0, 0, 0, 0.15), 0 0 20px rgba(245, 192, 110, 0.08);
}

.vertical-flipbook-big-screen {
  width: 100%;
  height: 100%;
  margin: 0;
  border-radius: 1rem;
  position: relative;
  overflow: visible !important;
  background-color: #20481c;
  z-index: 5;
  display: flex;
  justify-content: center;
  align-items: center;
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.25), 0 8px 15px rgba(0, 0, 0, 0.15), 0 0 20px rgba(245, 192, 110, 0.08);
}

/* When vertical flipbook is used as benefits-card */
.vertical-page {
  width: 448px;
  height: 646.4px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  border: none;
  margin: 0;
  border-radius: 10px;
}

.vertical-page-content {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  position: relative;
  border-radius: 30px;
  overflow: hidden;
}

.vertical-cover-img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  /* object-fit: contain; */
}

.vertical-flipbook .page:nth-child(even) {
  background-color: #20481c;
  background-image: url("../images/mask_jelkice-small-screen.png");
  object-fit: cover;
  border-radius: 15px;
}

.big-screen {
  display: block !important;
}

.small-screen {
  display: none !important;
}

/* Small tablet media query (540px - 767px) */
@media (min-width: 540px) and (max-width: 767px) {
  #flipbook {
    width: 362px !important;
    height: 588px !important;
  }

  .cover-img {
    border-radius: 40px;
  }

  .page:nth-child(even) {
    border-radius: 29px;
  }

  .big-screen {
    display: none !important;
  }

  .small-screen {
    display: block !important;
  }

  .container-fluid {
    height: 78vh !important;
  }

  #benefits-small .vertical-flipbook {
    width: 362px !important;
    height: 588px !important;
    max-width: 362px !important;
    max-height: 588px !important;
  }

  #benefits-small .benefits-card {
    width: 362px !important;
    height: 588px !important;
  }

  #benefits-small .benefits-card.vertical-flipbook {
    width: 362px !important;
    height: 588px !important;
  }

  #benefits-small .benefits-card-holder {
    width: 362px !important;
    min-height: 588px !important;
  }

  #benefits-small .vertical-page {
    width: 362px !important;
    height: 588px !important;
  }

  #benefits-small .turn-page-wrapper {
    width: 362px !important;
    height: 588px !important;
  }
}

/* Medium tablet media query (768px - 991px) */
@media (min-width: 768px) and (max-width: 991px) {
  #flipbook {
    width: 522px !important;
    height: 846px !important;
  }

  .cover-img {
    border-radius: 58px;
  }

  .page:nth-child(even) {
    border-radius: 40px;
  }

  .big-screen {
    display: none !important;
  }

  .small-screen {
    display: block !important;
  }

  .container-fluid {
    height: 80vh !important;
  }

  #benefits-small .vertical-flipbook {
    width: 522px !important;
    height: 846px !important;
    max-width: 522px !important;
    max-height: 846px !important;
  }

  #benefits-small .benefits-card {
    width: 522px !important;
    height: 846px !important;
  }

  #benefits-small .benefits-card.vertical-flipbook {
    width: 522px !important;
    height: 846px !important;
  }

  #benefits-small .benefits-card-holder {
    width: 522px !important;
    min-height: 846px !important;
  }

  #benefits-small .vertical-page {
    width: 522px !important;
    height: 846px !important;
  }

  #benefits-small .turn-page-wrapper {
    width: 522px !important;
    height: 846px !important;
  }
}

/* Large tablet media query (992px - 1024px) */
@media (min-width: 992px) and (max-width: 1024px) {
  #flipbook {
    width: 748px !important;
    height: 1208px !important;
  }

  .cover-img {
    border-radius: 81px;
  }

  .page:nth-child(even) {
    border-radius: 58px;
  }

  .big-screen {
    display: none !important;
  }

  .small-screen {
    display: block !important;
  }

  .container-fluid {
    height: 82vh !important;
  }

  #benefits-small .vertical-flipbook {
    width: 748px !important;
    height: 1208px !important;
    max-width: 748px !important;
    max-height: 1208px !important;
  }

  #benefits-small .benefits-card {
    width: 748px !important;
    height: 1208px !important;
  }

  #benefits-small .benefits-card.vertical-flipbook {
    width: 748px !important;
    height: 1208px !important;
  }

  #benefits-small .benefits-card-holder {
    width: 748px !important;
    min-height: 1208px !important;
  }

  #benefits-small .vertical-page {
    width: 748px !important;
    height: 1208px !important;
  }

  #benefits-small .turn-page-wrapper {
    width: 748px !important;
    height: 1208px !important;
  }
}

/* Vrlo mali mobilni ekrani */
@media (max-width: 320px) {
  #flipbook {
    width: 248px !important;
    height: 404px !important;
    transform: scale(1.15) !important;
    margin-top: 2rem;
    margin-bottom: 5rem;
  }

  .cover-img {
    border-radius: 27px;
  }

  .page:nth-child(even) {
    border-radius: 16px;
  }

  .big-screen {
    display: none !important;
  }

  .small-screen {
    display: block !important;
  }

  .container-fluid {
    height: 70vh !important;
  }

  #benefits-small .vertical-flipbook {
    width: 248px !important;
    height: 404px !important;
    max-width: 248px !important;
    max-height: 404px !important;
  }

  #benefits-small .benefits-card {
    width: 248px !important;
    height: 404px !important;
  }

  #benefits-small .benefits-card.vertical-flipbook {
    width: 248px !important;
    height: 404px !important;
  }

  #benefits-small .benefits-card-holder {
    width: 248px !important;
    min-height: 404px !important;
  }

  #benefits-small .vertical-page {
    width: 248px !important;
    height: 404px !important;
  }

  #benefits-small .turn-page-wrapper {
    width: 248px !important;
    height: 404px !important;
  }
}

/* Mali mobilni ekrani */
@media (min-width: 321px) and (max-width: 375px) {
  #flipbook {
    width: 285px !important;
    height: 464px !important;
    transform: scale(1.1) !important;
    margin-top: 1rem;
    margin-bottom: 4rem;
  }

  .cover-img {
    border-radius: 32px;
  }

  .page:nth-child(even) {
    border-radius: 20px;
  }

  .big-screen {
    display: none !important;
  }

  .small-screen {
    display: block !important;
  }

  .container-fluid {
    height: 72vh !important;
  }

  #benefits-small .vertical-flipbook {
    width: 285px !important;
    height: 464px !important;
    max-width: 285px !important;
    max-height: 464px !important;
  }

  #benefits-small .benefits-card {
    width: 285px !important;
    height: 464px !important;
  }

  #benefits-small .benefits-card.vertical-flipbook {
    width: 285px !important;
    height: 464px !important;
  }

  #benefits-small .benefits-card-holder {
    width: 285px !important;
    min-height: 464px !important;
  }

  #benefits-small .vertical-page {
    width: 285px !important;
    height: 464px !important;
  }

  #benefits-small .turn-page-wrapper {
    width: 285px !important;
    height: 464px !important;
  }
}

@media (min-width: 376px) and (max-width: 389px) {
  #flipbook {
    transform: scale(1.05) !important;
    margin-top: 1.5rem;
    margin-bottom: 4.5rem;
  }

  .cover-img {
    border-radius: 33px;
  }

  .page:nth-child(even) {
    border-radius: 21px;
  }

  #benefits-small .vertical-flipbook {
    width: 300px !important;
    height: 488px !important;
    max-width: 300px !important;
    max-height: 488px !important;
  }

  #benefits-small .benefits-card {
    width: 300px !important;
    height: 488px !important;
  }

  #benefits-small .benefits-card.vertical-flipbook {
    width: 300px !important;
    height: 488px !important;
  }

  #benefits-small .benefits-card-holder {
    width: 300px !important;
    min-height: 496px !important;
  }

  #benefits-small .vertical-page {
    width: 300px !important;
    height: 488px !important;
  }

  #benefits-small .turn-page-wrapper {
    width: 300px !important;
    height: 488px !important;
  }
}

/* Srednji mobilni ekrani */
@media (min-width: 390px) and (max-width: 412px) {
  #flipbook {
    width: 300px !important;
    height: 527px !important;
    transform: scale(1.15) !important;
    margin-top: 2rem;
    margin-bottom: 5rem;
  }

  .cover-img {
    border-radius: 35px;
  }

  .page:nth-child(even) {
    border-radius: 22px;
  }

  .big-screen {
    display: none !important;
  }

  .small-screen {
    display: block !important;
  }

  .container-fluid {
    height: 74vh !important;
  }

  #benefits-small .vertical-flipbook {
    width: 300px !important;
    height: 527px !important;
    max-width: 300px !important;
    max-height: 527px !important;
  }

  #benefits-small .benefits-card {
    width: 300px !important;
    height: 527px !important;
  }

  #benefits-small .benefits-card.vertical-flipbook {
    width: 300px !important;
    height: 527px !important;
  }

  #benefits-small .benefits-card-holder {
    width: 300px !important;
    min-height: 535px !important;
  }

  #benefits-small .vertical-page {
    width: 300px !important;
    height: 527px !important;
  }

  #benefits-small .turn-page-wrapper {
    width: 300px !important;
    height: 527px !important;
  }
}

@media (min-width: 391px) and (max-width: 414px) {
  #flipbook {
    width: 300px !important;
    height: 527px !important;
    transform: scale(1.2) !important;
    margin-top: 3rem;
    margin-bottom: 6rem;
  }

  .cover-img {
    border-radius: 35px;
  }

  .page:nth-child(even) {
    border-radius: 22px;
  }

  .big-screen {
    display: none !important;
  }

  .small-screen {
    display: block !important;
  }

  .container-fluid {
    height: 74vh !important;
  }

  #benefits-small .vertical-flipbook {
    width: 300px !important;
    height: 527px !important;
    max-width: 300px !important;
    max-height: 527px !important;
  }

  #benefits-small .benefits-card {
    width: 300px !important;
    height: 527px !important;
  }

  #benefits-small .benefits-card.vertical-flipbook {
    width: 300px !important;
    height: 527px !important;
  }

  #benefits-small .benefits-card-holder {
    width: 300px !important;
    min-height: 535px !important;
  }

  #benefits-small .vertical-page {
    width: 300px !important;
    height: 527px !important;
  }

  #benefits-small .turn-page-wrapper {
    width: 300px !important;
    height: 527px !important;
  }
}

/* Veliki mobilni ekrani */
@media (min-width: 415px) and (max-width: 539px) {
  #flipbook {
    width: 381px !important;
    height: 620px !important;
    transform: scale(1) !important;
    margin-bottom: 3rem;
  }

  .cover-img {
    border-radius: 41px;
  }

  .page:nth-child(even) {
    border-radius: 26px;
  }

  .big-screen {
    display: none !important;
  }

  .small-screen {
    display: block !important;
  }

  .container-fluid {
    height: 75vh !important;
  }

  #benefits-small .vertical-flipbook {
    width: 381px !important;
    height: 620px !important;
    max-width: 381px !important;
    max-height: 620px !important;
  }

  #benefits-small .benefits-card {
    width: 381px !important;
    height: 620px !important;
  }

  #benefits-small .benefits-card.vertical-flipbook {
    width: 381px !important;
    height: 620px !important;
  }

  #benefits-small .benefits-card-holder {
    width: 381px !important;
    min-height: 620px !important;
  }

  #benefits-small .vertical-page {
    width: 381px !important;
    height: 620px !important;
  }

  #benefits-small .turn-page-wrapper {
    width: 381px !important;
    height: 620px !important;
  }
}

@media (min-width: 415px) and (max-width: 430px) {
  #benefits-small .benefits-card-holder {
    transform: scale(0.9) !important;
  }

  .benefits-holder {
    padding: 0.15rem;
  }

  .benefits-heading {
    font-size: 2rem;
    margin: 2rem 1rem 0.5rem 0.5rem;
  }
}

@media (min-width: 1200px) {
  .page:nth-child(even) {
    background-image: url("../images/mask_jelkice_big-screen-test.png");
    background-position: -50px 100px;
  }
}

@media (min-width: 1025px) {
  .flipbook {
    max-width: none;
    max-height: none;
  }

  .page {
    max-width: none;
    max-height: none;
  }
}

/* 2K Desktop Resolution (2560px i iznad) */
@media (min-width: 2560px) {
  .flipbook {
    max-width: 100%;
    max-height: 100%;
    border-radius: 90px;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.35),
                0 15px 30px rgba(0, 0, 0, 0.25),
                0 0 50px rgba(245, 192, 110, 0.15) !important;
  }

  .page {
    max-width: 100%;
    max-height: 100%;
  }

  .cover-img {
    border-radius: 90px;
  }

  .shadow {
    border-radius: 90px;
  }

  #hero .cover {
    border-radius: 90px;
  }

  .page:nth-child(even) {
    border-radius: 90px;
  }

  .page-content {
    padding: 50px;
    gap: 25px;
  }
}

/* 4K Desktop Resolution (3840px i iznad) */
@media (min-width: 3840px) {
  .flipbook {
    max-width: 100%;
    max-height: 100%;
    border-radius: 110px;
    box-shadow: 0 40px 80px rgba(0, 0, 0, 0.4),
                0 20px 40px rgba(0, 0, 0, 0.3),
                0 0 70px rgba(245, 192, 110, 0.2) !important;
  }

  .page {
    max-width: 100%;
    max-height: 100%;
  }

  .cover-img {
    border-radius: 110px;
  }

  .shadow {
    border-radius: 110px;
  }

  #hero .cover {
    border-radius: 110px;
  }

  .page:nth-child(even) {
    border-radius: 110px;
  }

  .page-content {
    padding: 60px;
    gap: 30px;
  }
}
