/* Cart Page Specific Styles */
.cart-page-content {
    margin-top: 100px;
    padding: 2rem;
    min-height: calc(100vh - 100px - 400px);
    /* Adjust for navbar and footer */
}

.cart-container {
    max-width: 1200px;
    margin: 0 auto;
}

.cart-header-row {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    padding: 1rem 0;
    border-bottom: 1px solid #e0e0e0;
    font-weight: bold;
    color: var(--text-color);
}

.cart-items-container {
    margin: 2rem 0;
}

.cart-item-row {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    align-items: center;
    padding: 1rem 0;
    border-bottom: 1px solid #e0e0e0;
}

.product-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.product-info img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 4px;
}

.product-details {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.product-name {
    font-weight: bold;
    color: var(--text-color);
}

.show-details {
    background: none;
    border: none;
    color: var(--primary-color);
    cursor: pointer;
    font-weight: bold;
    padding: 0;
}

.remove-item-cart {
    color: #999;
    cursor: pointer;
    font-size: 1.2rem;
    background: none;
    border: none;
    padding: 0;
    margin-right: 1rem;
}

.quantity-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    max-width: 120px;
}

.quantity-controls button {
    background: #f0f0f0;
    border: none;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.quantity-controls input {
    width: 60px;
    text-align: center;
    border: 1px solid #e0e0e0;
    padding: 0.3rem 0;
    padding-left: 0.8rem;
}

.price,
.total {
    font-weight: bold;
    color: var(--text-color);
}

.total {
    color: #8cc63f;
}

.add-more-btn {
    background: #f0f0f0;
    border: none;
    padding: 0.8rem 1.5rem;
    cursor: pointer;
    font-weight: bold;
    margin: 2rem 0;
}

.cart-totals {
    margin-top: 3rem;
    border-top: 2px solid #e0e0e0;
    padding-top: 2rem;
}

.cart-totals h2 {
    margin-bottom: 1.5rem;
    color: var(--text-color);
}

.totals-row {
    display: flex;
    justify-content: space-between;
    padding: 1rem 0;
    border-bottom: 1px solid #e0e0e0;
}

.total-row {
    font-weight: bold;
    font-size: 1.2rem;
}

.total-amount {
    color: #8cc63f;
}

.checkout-button {
    width: 100%;
    background: #8cc63f;
    color: white;
    border: none;
    padding: 1rem;
    margin-top: 2rem;
    cursor: pointer;
    font-weight: bold;
    text-transform: uppercase;
}

.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 1rem 2rem;
    background: #8cc63f;
    color: white;
    border-radius: 4px;
    display: none;
    z-index: 1000;
}


/* Specific for Business card css */
.business-card-images {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.card-side {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.card-side img {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 4px;
    border: 1px solid #e0e0e0;
}

.side-label {
    font-size: 0.8rem;
    color: #666;
    margin-bottom: 0.25rem;
}

.print-type {
    color: #8cc63f;
    font-weight: bold;
    font-size: 0.9rem;
}

.file-info {
    font-size: 0.9rem;
    color: #666;
    line-height: 1.4;
}

/* PDF Preview Styles */
.pdf-preview-container {
    width: 80px;
    height: 80px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.pdf-preview-container:hover {
    background: #f5f5f5;
}

.pdf-icon {
    color: #dc3545;
    font-size: 2rem;
    margin-bottom: 5px;
}

.pdf-label {
    font-size: 0.8rem;
    color: #666;
}

/* PDF Modal Styles */
.pdf-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    /* Semi-transparent background */
    z-index: 1000;
}

.pdf-modal-content {
    position: relative;
    background-color: transparent;
    /* Semi-transparent white */
    margin: 5% auto;
    padding: 20px;
    width: 80%;
    max-width: 900px;
    height: 80vh;
    border-radius: 8px;

    /* Shadow for depth */
}

.close-modal {
    position: absolute;
    right: 20px;
    top: 10px;
    font-size: 28px;
    font-weight: bold;
    color: #fff;
    cursor: pointer;
}

.close-modal:hover {
    color: #fff;
}

#pdfViewer {
    width: 100%;
    height: calc(100% - 40px);
    overflow: auto;
    display: flex;
}

#pdfViewer canvas {
    margin: 0 auto;
    max-width: 100%;
    height: auto !important;
}



.notification.show {
    display: block;
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }

    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@media (max-width: 768px) {

    .cart-header-row,
    .cart-item-row {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .cart-header-row>div:not(:first-child) {
        display: none;
    }

    .cart-item-row {
        padding: 1.5rem 0;
    }

    .product-info {
        margin-bottom: 1rem;
    }

    .price-col,
    .quantity-col,
    .total-col {
        display: flex;
        justify-content: space-between;
    }

    .price-col::before {
        content: "Price per print:";
        font-weight: bold;
    }

    .quantity-col::before {
        content: "Number of prints:";
        font-weight: bold;
    }

    .total-col::before {
        content: "Total cost:";
        font-weight: bold;
    }

    .business-card-images {
        flex-direction: row;
        justify-content: flex-start;
        margin-bottom: 1rem;
    }

    .card-side img {
        width: 50px;
        height: 50px;
    }

    .pdf-preview-container {
        width: 60px;
        height: 60px;
    }

    .pdf-icon {
        font-size: 1.5rem;
    }

    .pdf-label {
        font-size: 0.7rem;
    }

    .pdf-modal-content {
        width: 95%;
        margin: 2% auto;
        height: 90vh;
    }

}