/* Preview Book Page Specific Styles */

/* Page Background */
.preview-book-page {
    background: #FFFFFF;
}

.preview-book-page .top-bar {
    background-color: var(--primary-blue) !important;
}

/* Preview Book Main Section (White background, 20px border-radius, padding 40px 150px 80px) */
.preview-book-section {
    background: #FFFFFF;
    padding: 60px 0 100px;
    min-height: calc(100vh - 200px);
    border-radius: 20px;
    margin: 0;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.04);
}

.preview-book-section .container {
    max-width: 1920px;
    padding-left: 0;
    padding-right: 0;
}

.preview-book-content {
    max-width: 100%;
    margin: 0 auto;
    width: 100%;
    padding: 0 150px;
}


/* Book Preview Header */
.book-preview-header {
    border-bottom: 1px solid #D3D3D3;
    padding-bottom: 26px;
    margin-bottom: 48px;
    gap: 16px;
}

.book-preview-title {
    font-family: 'Satoshi', sans-serif;
    font-weight: 700;
    font-size: 40px;
    line-height: 1.3;
    color: #000000;
    margin-bottom: 13.55px;
    letter-spacing: -0.5px;
}

.book-preview-author {
    font-family: 'Satoshi', sans-serif;
    font-weight: 400;
    font-size: 30px;
    line-height: 0.87;
    color: #787878;
    letter-spacing: 0.3px;
}

/* Purchase Book Button (Figma: Poppins 700, 18.5px, uppercase) */
.btn-purchase-book {
    font-family: 'Poppins', sans-serif;
    font-weight: 700;
    font-size: 18.5px;
    line-height: 1.25;
    padding: 19.42px 37.92px;
    border-radius: 5.55px;
    border-width: 2px;
    background-color: #FAD30C;
    border-color: #FAD30C;
    color: #333333;
    text-decoration: none;
    display: inline-block;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 12px rgba(250, 211, 12, 0.3);
    white-space: nowrap;
}

.btn-purchase-book:hover {
    background-color: #e5c00b;
    border-color: #e5c00b;
    color: #333333;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(250, 211, 12, 0.4);
}

.btn-purchase-book:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(250, 211, 12, 0.3);
}

/* Book Viewer - 2 pages per row */
.book-viewer {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 40px 0;
    position: relative;
}

.book-pages-container {
    width: 100%;
    max-width: 1600px;
    position: relative;
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: flex-start;
    gap: 0;
    padding: 0;
}

/* Book Pages - 2 pages per row: Scaled down from 777.17px width, 986.27px height */
.book-page {
    width: 50%;
    max-width: 600px;
    height: 760px;
    overflow: hidden;
    position: relative;
    flex-shrink: 0;
    background: #FFFFFF;
}

/* Border between pages in same row (vertical border) - only for pages without overlay */
.book-page-1 {
    border-right: 1.5px solid #B2B2B2;
}

/* Border between rows (horizontal border) - only for pages without overlay */
.book-page-1,
.book-page-2 {
    border-bottom: 1.5px solid #B2B2B2;
}

/* No borders for overlay pages */
.book-page-3,
.book-page-4 {
    border: none;
}

/* Hover scale feature removed */

/* First two pages - no overlay */
/* Last two pages - with overlay */

.book-page-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Hover scale feature removed */

/* Dark Overlay on Pages (Figma: rgba(0, 0, 0, 0.4)) */
.book-page-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    transition: background 0.3s ease;
    backdrop-filter: blur(2px);
    cursor: pointer;
    z-index: 5;
}

.book-page-overlay:hover {
    background: rgba(0, 0, 0, 0.6);
}

/* Hover scale feature removed from unlock content */

/* Unlock Content (Figma: Lato 400, 44px, gap 6.86px) */
.unlock-content {
    display: flex;
    align-items: center;
    gap: 6.86px;
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.8;
    }
}

.unlock-icon {
    font-size: 64px;
    color: #FFFFFF;
    width: 64px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: center;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

.unlock-text {
    font-family: 'Lato', sans-serif;
    font-weight: 400;
    font-size: 44px;
    line-height: 1.2;
    color: #FFFFFF;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
    letter-spacing: 1px;
}

/* Responsive Styles */
@media (max-width: 1600px) {
    .preview-book-section {
        padding: 50px 0 90px;
        margin: 0;
    }
    
    .preview-book-content {
        max-width: 100%;
        padding: 0 80px;
    }

    .book-page {
        width: 50%;
        max-width: 600px;
        min-width: 300px;
    }
}

@media (max-width: 991px) {
    .preview-book-section {
        margin: 0;
        padding: 30px 0 60px;
    }
    
    .preview-book-content {
        padding: 0 40px;
    }

    .book-preview-header {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 20px !important;
    }

    .book-preview-title {
        font-size: 32px;
    }

    .book-preview-author {
        font-size: 24px;
    }

    .btn-purchase-book {
        font-size: 16px;
        padding: 15px 30px;
        width: 100%;
    }

    .book-pages-container {
        gap: 0;
        padding: 0;
    }

    .book-page {
        width: 50%;
        max-width: 100%;
        height: auto;
        aspect-ratio: 777.17 / 986.27;
    }

    /* Maintain borders on tablet - only for pages without overlay */
    .book-page-1 {
        border-right: 1.5px solid #B2B2B2;
    }

    .book-page-1,
    .book-page-2 {
        border-bottom: 1.5px solid #B2B2B2;
    }

    /* No borders for overlay pages */
    .book-page-3,
    .book-page-4 {
        border: none;
    }

    .unlock-icon {
        font-size: 48px;
    }

    .unlock-text {
        font-size: 32px;
    }
}

@media (max-width: 768px) {
    .preview-book-section {
        margin: 0;
        padding: 40px 0 70px;
        border-radius: 12px;
    }
    
    .preview-book-section .container {
        padding-left: 16px;
        padding-right: 16px;
    }
    
    .preview-book-content {
        padding: 0 20px;
    }

    .book-preview-header {
        margin-bottom: 32px;
        padding-bottom: 20px;
    }

    .book-preview-title {
        font-size: 28px;
    }

    .book-preview-author {
        font-size: 20px;
    }

    .btn-purchase-book {
        font-size: 14px;
        padding: 12px 24px;
    }

    .book-viewer {
        padding: 20px 0;
    }

    .book-pages-container {
        gap: 0;
    }

    .book-page {
        width: 100%;
    }

    /* Remove vertical borders on mobile, keep horizontal borders between rows - only for pages without overlay */
    .book-page-1 {
        border-right: none;
    }

    .book-page-1,
    .book-page-2 {
        border-bottom: 1.5px solid #B2B2B2;
    }

    /* No borders for overlay pages */
    .book-page-3,
    .book-page-4 {
        border: none;
    }

    .unlock-icon {
        font-size: 36px;
    }

    .unlock-text {
        font-size: 24px;
    }
}

@media (max-width: 576px) {
    .preview-book-section {
        margin: 0;
        padding: 30px 0 50px;
    }
    
    .preview-book-section .container {
        padding-left: 12px;
        padding-right: 12px;
    }
    
    .preview-book-content {
        padding: 0 15px;
    }

    .book-preview-header {
        margin-bottom: 24px;
        padding-bottom: 16px;
    }

    .book-preview-title {
        font-size: 24px;
        margin-bottom: 8px;
    }

    .book-preview-author {
        font-size: 18px;
    }

    .book-viewer {
        padding: 15px 0;
    }

    .book-pages-container {
        gap: 0;
        padding: 0;
    }

    .book-page {
        width: 100%;
    }

    /* Remove vertical borders on mobile, keep horizontal borders between rows - only for pages without overlay */
    .book-page-1 {
        border-right: none;
    }

    .book-page-1,
    .book-page-2 {
        border-bottom: 1.5px solid #B2B2B2;
    }

    /* No borders for overlay pages */
    .book-page-3,
    .book-page-4 {
        border: none;
    }

    .unlock-icon {
        font-size: 28px;
        width: 28px;
        height: 28px;
    }

    .unlock-text {
        font-size: 20px;
    }
}

/* Purchase Modal Styles */
.purchase-modal-content {
    border-radius: 12px;
    border: none;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    max-width: 500px;
    margin: 0 auto;
}

.purchase-modal-body {
    padding: 40px 30px;
    text-align: center;
}

/* Alert Icon */
.purchase-modal-icon {
    margin-bottom: 24px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.alert-icon-circle {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: #FFFFFF;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    box-shadow: 0 0 0 8px rgba(255, 0, 0, 0.1), 0 0 0 16px rgba(255, 0, 0, 0.05);
}

.alert-icon-circle::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 0, 0, 0.2) 0%, rgba(255, 0, 0, 0) 70%);
    animation: pulse-ring 2s ease-out infinite;
}

@keyframes pulse-ring {
    0% {
        transform: scale(1);
        opacity: 1;
    }
    100% {
        transform: scale(1.5);
        opacity: 0;
    }
}

.alert-icon-circle i {
    font-size: 40px;
    color: #FF0000;
    font-weight: 900;
    position: relative;
    z-index: 1;
}

/* Modal Message */
.purchase-modal-message {
    font-family: 'Satoshi', sans-serif;
    font-weight: 400;
    font-size: 18px;
    line-height: 1.5;
    color: #2D2D2D;
    margin-bottom: 32px;
    padding: 0 10px;
}

/* Modal Buttons */
.purchase-modal-buttons {
    display: flex;
    gap: 16px;
    justify-content: center;
}

.btn-cancel {
    font-family: 'Poppins', sans-serif;
    font-weight: 600;
    font-size: 16px;
    padding: 12px 32px;
    border-radius: 6px;
    background: #FFFFFF;
    border: 1.5px solid #FAD30C;
    color: #333333;
    transition: all 0.3s ease;
    min-width: 120px;
}

.btn-cancel:hover {
    background: #F9F9F9;
    border-color: #FAD30C;
    color: #333333;
}

.btn-buy-now {
    font-family: 'Poppins', sans-serif;
    font-weight: 700;
    font-size: 16px;
    padding: 12px 32px;
    border-radius: 6px;
    background: #FAD30C;
    border: 1.5px solid #FAD30C;
    color: #333333;
    text-decoration: none;
    display: inline-block;
    transition: all 0.3s ease;
    min-width: 120px;
    text-align: center;
}

.btn-buy-now:hover {
    background: #e5c00b;
    border-color: #e5c00b;
    color: #333333;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(250, 211, 12, 0.4);
}

/* Responsive Modal */
@media (max-width: 576px) {
    .purchase-modal-body {
        padding: 30px 20px;
    }

    .alert-icon-circle {
        width: 60px;
        height: 60px;
    }

    .alert-icon-circle i {
        font-size: 30px;
    }

    .purchase-modal-message {
        font-size: 16px;
        margin-bottom: 24px;
    }

    .purchase-modal-buttons {
        flex-direction: column;
        gap: 12px;
    }

    .btn-cancel,
    .btn-buy-now {
        width: 100%;
        padding: 14px 24px;
    }
}

