* {
    box-sizing: border-box;
  }
  
  body {
    margin: 0;
    display: flex;
    min-height: 100dvh;
    perspective: 1000px;
    font: 1em/1.4 "Poppins", sans-serif;
    overflow: hidden;
    color: hsl(180 68% 5%);
    background-image: radial-gradient(
        circle farthest-corner at 50% 50%,
        hsl(187 20% 88%) 30%,
        hsl(149 20% 94%) 100%
    );
  }
  
  .book {
    position: relative;
    display: flex;
    margin: auto;
    width: 30cqmin;
    pointer-events: none;
    transform-style: preserve-3d;
    transition: translate 1s;
    translate: calc(min(var(--c), 1) * 50%) 0%;
    rotate: 1 0 0 30deg;
  }
  
  .page {
    --thickness: 4;
    flex: none;
    display: flex;
    width: 140%;
    font-size: 2.2cqmin;
    pointer-events: all;
    user-select: none;
    transform-style: preserve-3d;
    transform-origin: left center;
    transition: transform 1s,
        rotate 1s ease-in calc((min(var(--i), var(--c)) - max(var(--i), var(--c))) * 50ms);
    translate: calc(var(--i) * -100%) 0px 0px;
    transform: translateZ(calc((var(--c) - var(--i) - 0.5) * calc(var(--thickness) * 0.23cqmin)));
    rotate: 0 1 0 calc(clamp(0, var(--c) - var(--i), 1) * -180deg);
  }
  
  .front,
  .back {
    position: relative;
    flex: none;
    width: 100%;
    backface-visibility: hidden;
    overflow: hidden;
    background-color: #fff;
    translate: 0px;
  }
  
  .back {
    translate: -100% 0;
    rotate: 0 1 0 180deg;
  }
  
  .book {
    counter-reset: page -1;
  }
  
  .book a {
    color: inherit;
  }
  
  .page {
    box-shadow: 0em 0.5em 1em -0.2em #00000020;
  }
  
  .front,
  .back {
    display: flex;
    flex-flow: column wrap;
    justify-content: space-between;
    padding: 2em;
    border: 1px solid #0002;
  }
  
  .front:has(img),
  .back:has(img) {
    padding: 0;
  }
  
  .front img,
  .back img {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }
  
  .front::after,
  .back::after {
    position: absolute;
    bottom: 1em;
    counter-increment: page;
    content: counter(page) ".";
    font-size: 0.8em;
  }
  
  .cover::after {
    content: "";
  }
  
  .front::after {
    right: 1em;
  }
  
  .front {
    background: linear-gradient(to left, #f7f7f7 80%, #eee 100%);
    border-radius: 0.1em 0.5em 0.5em 0.1em;
  }
  
  .back::after {
    left: 1em;
  }
  
  .back {
    background-image: linear-gradient(to right, #f7f7f7 80%, #eee 100%);
    border-radius: 0.5em 0.1em 0.1em 0.5em;
  }
  
  .cover {
    background: radial-gradient(
            circle farthest-corner at 80% 20%,
            hsl(150 80% 20% / 0.3) 0%,
            hsl(170 60% 10% / 0.1) 100%
        ),
        hsl(231, 32%, 29%) url("4.jpeg") 50% / cover;
    color: hsl(0, 100%, 30%);
  }
  
  h1,
  h2,
  h3 {
    margin-bottom: 1px;
    color:hsl(0, 100%, 30%); 
  }
  
  p {
    margin-top: 1px;
    margin-bottom: 8px;
    line-height: 1.4;
    color: hsl(0, 100%, 30%);
  }
  
  .front,
  .back {
    padding: 1.5em;
    color: hsl(0, 100%, 30%); 
  }
  
  .book {
    width: 40cqmin; 
  }
  
  .page {
    font-size: 2cqmin; 
  }
  
  p:last-child {
    margin-bottom: 0;
  }
  
  .front,
  .back {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    padding: 1.5em;
  }
  
  h2 {
    margin-bottom: 5px;
  }
  
  p {
    margin-top: 5px;
    line-height: 1.4;
  }
  
  
  body {
    margin: 0;
    display: flex;
    min-height: 100dvh;
    perspective: 1000px;
    font: 1em/1.4 "Poppins", sans-serif;
    overflow: hidden;
    color: hsl(180 68% 5%);
    background: linear-gradient(to right, #479ae8, #6598ff, #164cff);
    background-size: 400% 400%;
    animation: gradientAnimation 10s ease infinite;
  }
  
  @keyframes gradientAnimation {
    0% {
      background-position: 0% 50%;
    }
    50% {
      background-position: 100% 50%;
    }
    100% {
      background-position: 0% 50%;
    }
  }
  
  /* Emoji Animation */
  .emoji {
    position: absolute;
    font-size: 3rem;
    opacity: 0;
    animation: floatEmojis 6s ease-in-out infinite;
  }
  
  @keyframes floatEmojis {
    0% {
      transform: translateY(100px);
      opacity: 1;
    }
    50% {
      transform: translateY(-100px) rotate(20deg);
      opacity: 0.7;
    }
    100% {
      transform: translateY(100px);
      opacity: 1;
    }
  }
  
  /* random  emoji */
  .emoji:nth-child(1) {
    animation-delay: 0s;
    left: 10%;
  }
  .emoji:nth-child(2) {
    animation-delay: 1s;
    left: 20%;
  }
  .emoji:nth-child(3) {
    animation-delay: 2s;
    left: 30%;
  }
  .emoji:nth-child(4) {
    animation-delay: 3s;
    left: 40%;
  }
  .emoji:nth-child(5) {
    animation-delay: 4s;
    left: 50%;
  }
  .emoji:nth-child(6) {
    animation-delay: 5s;
    left: 60%;
  }
  .emoji:nth-child(7) {
    animation-delay: 6s;
    left: 70%;
  }
  .emoji:nth-child(8) {
    animation-delay: 7s;
    left: 80%;
  }
  .emoji:nth-child(9) {
    animation-delay: 8s;
    left: 90%;
  }
  
  