    

        .magbg{
           background-image: url("../img/magbg.jpg");
           background-size: cover;
           background-position: center;
           background-repeat: no-repeat;
           /* padding: 20px; */

       
        } 


        .hover-shadow {
        transition: transform 0.3s ease, box-shadow 0.3s ease;
    }
    .hover-shadow:hover {
        transform: translateY(-5px);
        box-shadow: 0 10px 20px rgba(0,0,0,0.15) !important;
    }

   .magcard {
  margin: 0;
  transition: 0.6s;
  position: relative;
  z-index: 1;
}
.magcard .eb_icon {
  display: flex;
  width: 42px;
  height: 42px;
  justify-content: center;
  align-items: center;
  font-size: 24px;
  border-radius: 8px;
  color: #f1f900;
  position: absolute;
  right: 32px;
  top: 32px;
  box-shadow: 0 0.225rem 0.25rem rgba(43, 45, 66, 0.075);
  z-index: 1;
}
.magcard img {
  /* height: 600px; */
  object-fit: contain;
  width: 100%;
  box-shadow: 0 0.225rem 0.25rem rgba(43, 45, 66, 0.075);
  border-radius: 6px;
}
.magcard card-body {
  padding: 32px;
  border-radius: 6px;
  position: absolute;
  inset: 0;
  display: flex;
  align-items: start;
  justify-content: end;
  flex-direction: column;
  transition: 0.5s;
  transform: translateY(10px);
  opacity: 0;
}
.magcard  p {
  margin-bottom: 8px;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 4px;
}
.magcard p i {
  flex-shrink: 0;
  border-radius: 100px;
  width: 32px;
  height: 32px;
  margin-right: 8px;
  display: flex;
  color: #000355;
  background-color: #fcf5f7;
  align-items: center;
  justify-content: center;
}
.magcard  h3 {
  color: #fff;
  margin-bottom: 0;
}
.magcard::after {
  content: "";
  background-color: #000a65;
  height: 100%;
  width: 100%;
  position: absolute;
  z-index: -1;
  left: -16px;
  bottom: -16px;
  border-radius: 6px;
  opacity: 0;
  transition: 0.3s;
}
.magcard:hover {
  transform: scale(0.96);
}
.magcard:hover::after {
  opacity: 1;
}
.magcard:hover card-body {
  transform: translateY(0);
  opacity: 1;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0) 0%, rgba(23, 24, 35, 0.9) 70%);
}



        .magazine-viewport, #flipbook {
        
            touch-action: auto;
        }

        @media (max-width: 768px) {
           
            #flipbook canvas,
            #flipbook .st-page-flip-page {
                pointer-events: none !important;
            }
        }


        .magazine-viewport {
            overflow: hidden;

             width: 87vw;

            height: 100vh;

            display: flex;

            justify-content: center;

            align-items: center;

            

            /* margin: 250px;

            padding: 200px; */

            /* margin: 50px; */

            /* background-color: #00ff1a; */

        }

            @media (max-width: 768px) {
            .magazine-viewport {
                width: 100%;
                height: 100vh;
                height: 100dvh;
            }
        }



        .page {

            background-color: white;

            box-shadow: inset 0 0 20px rgba(0, 0, 0, 0.1);

            overflow: hidden;

            /* 1. Ensure padding doesn't expand the total width/height of the page */
            box-sizing: border-box;

            /* 2. Add safe margin around the edge of every page */
            padding: 16px;

        }



        .page img {

            width: 100%;

            height: 100%;

            /* 3. Switch to 'contain' so images scale down completely without cropping text */
            object-fit: contain;

            /* Centers the image nicely inside the padded page */
            object-position: center;

        }

        /* Spine Fold Effect: Directional shadows for left vs right pages */
        #flipbook .page.--left,
        #flipbook .page:nth-child(even) {
            padding-right: 16px;
            /* Extra gutter padding at the center fold */
            box-shadow: inset -18px 0 20px -10px rgba(0, 0, 0, 0.2);
            /* Inset shadow on right edge */
        }

        #flipbook .page.--right,
        #flipbook .page:nth-child(odd) {
            padding-left: 16px;
            /* Extra gutter padding at the center fold */
            box-shadow: inset 18px 0 20px -10px rgba(0, 0, 0, 0.2);
            /* Inset shadow on left edge */
        }

      
        .magazine-nav {
            position: fixed;
            bottom: 28px;
            left: 50%;
            transform: translateX(-50%);
            display: flex;
            align-items: center;
            gap: 10px;
            padding: 8px 10px;

            /* Frosted Glass Effect */
            background: rgba(22, 23, 26, 0.75);
            backdrop-filter: blur(16px);
            -webkit-backdrop-filter: blur(16px);
            border: 1px solid rgba(255, 255, 255, 0.12);
            border-radius: 40px;
            box-shadow: 0 12px 32px rgba(0, 0, 0, 0.45);

            z-index: 1000;
            user-select: none;
        }

        .magazine-nav button {
            display: inline-flex;
            align-items: center;
            justify-content: center;
            height: 30px;
            padding: 0 10px;
            background: rgba(255, 255, 255, 0.08);
            color: #f0f0f0;
            border: 1px solid rgba(255, 255, 255, 0.08);
            border-radius: 20px;
            cursor: pointer;
            font-size: 10px;
            font-weight: 500;
            letter-spacing: 0.3px;
            transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
        }

        .magazine-nav button:hover:not(:disabled) {
            background: rgba(255, 255, 255, 0.22);
            color: #ffffff;
            transform: translateY(-1px);
            box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
        }

        .magazine-nav button:active:not(:disabled) {
            transform: translateY(0);
        }

        .magazine-nav button:disabled {
            background: rgba(255, 255, 255, 0.02);
            color: rgba(255, 255, 255, 0.25);
            border-color: transparent;
            cursor: not-allowed;
        }

        #page-counter {
            font-size: 10px;
            font-weight: 600;
            letter-spacing: 0.5px;
            color: rgba(255, 255, 255, 0.85);
            padding: 0 10px;
            min-width: 110px;
            text-align: center;
            text-transform: uppercase;
        }




          #loading-overlay {
        position: fixed;
        inset: 0;
        background: rgb(255, 255, 255);
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        z-index: 9999;
    }

    .spinner {
        width: 50px;
        height: 50px;
        border: 5px solid #ddd;
        border-top-color: #2563eb;
        border-radius: 50%;
        animation: spin .8s linear infinite;
    }

    @keyframes spin {
        to {
            transform: rotate(360deg);
        }
    }

    #loading-overlay.hidden {
        display: none;
    }
    .flipbook-scroll-wrapper {
        width: 100%;
        height: 100vh;
        overflow: auto; 
        position: relative;
        justify-content: center;
        align-items: center;
        display: flex;
    }

        #zoom-container {
        display: inline-block;
        transform-origin: 0 0;
        
    }

    .magazine-viewport {
        transform-origin: 0 0; /* Scale from top-left, expanding right & down */
        transition: transform 0.2s ease;
    }


.zoom-controls {
    position: fixed;
    top: 28px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;

    /* Frosted Glass Effect */
    background: rgba(22, 23, 26, 0.75);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 40px;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.45);

    z-index: 1000;
    user-select: none;
}

.zoom-controls button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 30px;
    padding: 0 10px;
    background: rgba(255, 255, 255, 0.08);
    color: #f0f0f0;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    cursor: pointer;
    font-size: 10px;
    font-weight: 500;
    letter-spacing: 0.3px;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.zoom-controls button:hover:not(:disabled) {
    background: rgba(255, 255, 255, 0.22);
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.zoom-controls button:active:not(:disabled) {
    transform: translateY(0);
}

.zoom-controls button:disabled {
    background: rgba(255, 255, 255, 0.02);
    color: rgba(255, 255, 255, 0.25);
    border-color: transparent;
    cursor: not-allowed;
}





