* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    scrollbar-width: thin;
    scrollbar-color: rgba(0, 0, 0, 0.35) transparent;
}



body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background: #FFF4EA;
    color: #333;
}

/* HEADER */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.8rem 2rem;
    background: #FFF4EA;
    border-bottom: 1px solid #e9ecef;
    position: sticky;
    top: 0;
    z-index: 100;
}


/* Logo wrapper */
.logo-container {
    display: flex;
    align-items: center;
}

/* Logo image */
.logo-container img {
    height: 38px;          /* visually perfect for header */
    width: auto;           /* keeps 180x52 ratio */
    display: block;
    object-fit: contain;
}

#cart-btn {
    background: #333;
    color: #fff;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    cursor: pointer;
}

/* MAIN */
main {
    max-width: 1200px;
    margin: auto;
    padding: 2rem;
}

.sticker-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1.5rem;
}

.sticker-card {
    background: #fff;
    border-radius: 12px;
    padding: 1rem;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, .06);
    transition: transform .2s, box-shadow .2s;
    cursor: pointer;
}

.sticker-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, .1);
}

.sticker-card img {
    width: 100%;
    aspect-ratio: 1 / 1;    /* Makes the box perfectly square */
    object-fit: cover;      /* Ensures image fills the box, cropping edges if needed */
    padding: 0;             /* Removes the space inside the box */
    border-radius: 8px;
    background-color: #fff; /* Changes grey background to white (optional, or remove line) */
    display: block;         /* Removes tiny gaps sometimes seen under images */
}

.sticker-card h3 {
    margin: .75rem 0 .25rem;
    font-size: 1rem;
}

.price {
    color: #666;
    margin-bottom: .75rem;
}

.sticker-card button {
    width: 100%;
    background: #4CAF50;
    color: #fff;
    border: none;
    padding: .6rem;
    border-radius: 6px;
    cursor: pointer;
}

/* --- DETAIL / PREVIEW MODAL --- */

.modal-content-detail {
    background: #fff;
    padding: 2rem;
    border-radius: 12px;
    width: 90%;
    max-width: 400px;
    
    /* FIX: Don't force 80vh height, let it grow with content */
    height: auto; 
    max-height: 85vh; /* Cap it so it doesn't go off screen */
    overflow-y: auto; /* Scroll if content is too tall */
    
    display: flex;
    flex-direction: column;
    position: relative;
}

.modal-content-detail h2 {
    margin-bottom: 0.5rem;
    font-size: 1.5rem;
    color: #333;
}

.modal-content-detail .price {
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    font-weight: 500;
}

/* Image specific styling for the modal */
#preview-img {
    width: 100%;
    height: auto;
    border-radius: 8px;
    margin-bottom: 1rem;
    object-fit: cover;
    aspect-ratio: 1/1; /* Keeps it square */
}

/* Actions area */
.modal-actions-detail {
    display: flex;
    gap: 0.75rem;
    margin-top: auto; /* Pushes buttons to bottom if there's extra space */
}

.modal-actions-detail button {
    flex: 1;
    padding: 0.75rem;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: transform 0.1s;
}

.modal-actions-detail button:active {
    transform: scale(0.98);
}

/* --- PREVIEW MODAL CLOSE BUTTON --- */
.close-preview-btn {
    position: absolute;
    top: 15px;    /* Pins to the top */
    right: 20px;  /* Pins to the right */
    font-size: 28px;
    font-weight: bold;
    color: #aaa;  /* Matches the cart 'X' color */
    cursor: pointer;
    line-height: 1;
    transition: color 0.2s;
    z-index: 10;
}

.close-preview-btn:hover {
    color: #333;  /* Darkens on hover like the cart 'X' */
}



/* Helper to center the text content since we removed it from the inline style */
.text-center-content {
    text-align: center;
}

/* --- MOBILE SPECIFIC ADJUSTMENTS --- */
@media (max-width: 600px) {
    .modal-content-detail {
        width: 95%;        /* Wider on mobile */
        padding: 1.25rem;  /* Less padding */
        max-height: 90vh;  /* Use more vertical space */
    }

    /* Prevent huge images from pushing buttons off-screen on small phones */
    #preview-img {
        max-height: 50vh; 
        width: auto;
        margin: 0 auto 1rem auto; /* Center image */
        display: block;
    }

    .modal-content-detail h2 {
        font-size: 1.3rem; /* Smaller title */
    }
}

/* MODAL */
.modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, .5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 200;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}


.close-icon {
    font-size: 28px;
    font-weight: bold;
    color: #aaa;
    cursor: pointer;
    line-height: 1;
    transition: color 0.2s;
}

.close-icon:hover {
    color: #333;
}

.hidden {
    display: none;
}

/* --- MODAL EXPANSION ANIMATION --- */
.modal-content {
    background: #fff;  /* <--- ADD THIS LINE HERE */
    transition: max-width 0.5s cubic-bezier(0.25, 1, 0.5, 1), height 0.5s ease;
    
    /* Default State (Cart List) */
    max-width: 400px;
    width: 95%;
    overflow: hidden;
    border-radius: 12px; /* Optional: adds rounded corners to the white box */
}

/* Expanded State (Checkout Form) */
.modal-content.expanded {
    max-width: 1000px;
    /* Expands to fit 2 columns */
    height: 85vh;
}

/* --- CHECKOUT LAYOUT --- */
.checkout-header {
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
    margin-bottom: 15px;
}

.checkout-container {
    display: flex;
    gap: 30px;
    height: 100%;
    overflow-y: auto;
    /* Allow scrolling inside */
    padding-bottom: 20px;
}

.checkout-left {
    flex: 1.3;
    /* Wider column for forms */
    padding-right: 10px;
}

.checkout-right {
    flex: 0.8;
    /* Narrower column for summary */
    background: #fafafa;
    padding: 20px;
    border-radius: 8px;
    height: fit-content;
    border: 1px solid #eee;
}

/* Input Styling */
.checkout-input {
    width: 100%;
    padding: 12px;
    margin-bottom: 12px;
    border: 1px solid #d9d9d9;
    border-radius: 5px;
    font-size: 14px;
    font-family: inherit;
}

.checkout-input:focus {
    border-color: #333;
    outline: none;
}

.form-row {
    display: flex;
    gap: 10px;
}

.half {
    flex: 1;
}

.third {
    flex: 1;
}

/* Radio Boxes */
.radio-group {
    border: 1px solid #d9d9d9;
    border-radius: 5px;
    overflow: hidden;
    margin-bottom: 20px;
}

.radio-box {
    display: flex;
    justify-content: space-between;
    padding: 15px;
    border-bottom: 1px solid #d9d9d9;
    cursor: pointer;
    background: #fff;
    align-items: center;
}

.radio-box:last-child {
    border-bottom: none;
}

.radio-box.active {
    background: #f4fbfd;
}

.radio-content {
    display: flex;
    gap: 10px;
    align-items: center;
    font-size: 14px;
}

.radio-price {
    font-weight: 500;
    font-size: 14px;
}

.legal-text {
    font-size: 0.8rem;
    color: #6c757d;
    text-align: center;
    margin-top: 15px;
    
    /* ADD THIS TO FIX THE CUT-OFF */
    margin-bottom: 40px;  /* Pushes the bottom edge down */
    padding-bottom: 20px; /* Adds extra buffer inside the element */
    display: block;       /* Ensures the browser respects the margins */
}

.legal-text a {
    color: #333;            /* Darker color for links */
    text-decoration: underline;
    cursor: pointer;
}

.legal-text a:hover {
    color: #000;            /* darken on hover */
}

/* Summary Items */
.summary-item {
    display: flex;
    gap: 12px;
    margin-bottom: 12px;
    align-items: center;
}

.summary-img {
    width: 50px;
    height: 50px;
    border-radius: 5px;
    border: 1px solid #ddd;
    object-fit: cover;
    background: #fff;
}

.pricing-row {
    display: flex;
    justify-content: space-between;
    margin-top: 8px;
    font-size: 14px;
    color: #555;
}

.total-row {
    display: flex;
    justify-content: space-between;
    margin-top: 15px;
    font-size: 18px;
    font-weight: bold;
    border-top: 1px solid #ddd;
    padding-top: 10px;
}

/* --- COUPON STYLES --- */
.coupon-row {
    display: flex;
    gap: 8px;
}

.coupon-row input {
    margin-bottom: 0; /* Remove default margin to align with button */
    flex: 1;          /* Takes up available space */
}

#apply-coupon-btn {
    padding: 0 20px;
    background: #555;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    transition: background 0.2s;
}

#apply-coupon-btn:hover {
    background: #333;
}

#coupon-message {
    display: block;
    margin-top: 5px;
    font-size: 12px;
    min-height: 18px; /* Prevents jumping when text appears */
}

.text-success { color: #27ae60; }
.text-error { color: #e74c3c; }

.btn-submit {
    width: 100%;
    background: #333;
    color: white;
    padding: 16px;
    border: none;
    border-radius: 5px;
    font-size: 16px;
    cursor: pointer;
    font-weight: 600;
}

.btn-submit:hover {
    background: #000;
}

/* Mobile Response */
@media (max-width: 768px) {
    .checkout-container {
        flex-direction: column-reverse;
    }

    .modal-content.expanded {
        height: 95vh;
        overflow-y: scroll;
    }

    .checkout-left {
        padding-right: 0;
    }
}



.modal-content h2 {
    margin-bottom: 1rem;
}

.modal-content ul {
    list-style: none;
    margin-bottom: 1rem;
}

.modal-content li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: .5rem 0;
    border-bottom: 1px solid #e9ecef;
}

#cart-total {
    font-weight: 600;
    margin-bottom: 0.75rem;
}

.modal-actions {
    margin-top: auto;
    /* 🔑 PUSH TO BOTTOM */
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}


.cart-buttons {
    display: flex;
    gap: 0.75rem;
}

.cart-buttons button {
    flex: 1;
    padding: .75rem;
    border: none;
    border-radius: 8px;
    cursor: pointer;
}


.modal-actions-order {
    display: flex;
    gap: .75rem;
}

.modal-actions-order button {
    flex: 1;
    padding: .75rem;
    border: none;
    border-radius: 8px;
    cursor: pointer;
}


#close-modal {
    background: #e9ecef;
}

/* ... existing styles ... */

/* NEW: Customer Input Styling */
.customer-inputs {
    margin: 1rem 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.customer-inputs input {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    outline: none;
    transition: border-color 0.2s;
}

.customer-inputs input:focus {
    border-color: #4CAF50;
    /* Highlights green when typing */
}

/* MOBILE */
@media (max-width: 600px) {
    header {
        gap: 1rem;
    }

    .sticker-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ... keep your existing CSS ... */

/* NEW STYLES FOR CART UPDATES */



/* Group the name and quantity */
.cart-item-info {
    flex-grow: 1;
    text-align: left;
    /* Use flexbox to align the image and text side-by-side */
    display: flex;
    align-items: center;
}

/* New style for the product image in the cart */
.cart-item-image {
    width: 50px;
    /* Set a fixed, small size */
    height: 50px;
    object-fit: cover;
    /* Ensure the image covers the area without distortion */
    border-radius: 6px;
    /* Optional: rounded corners */
    margin-right: 12px;
    /* Space between the image and the text */
    background-color: #f0f0f0;
    /* Optional placeholder color */
}

/* Group the price and remove button */
.cart-item-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

/* The small red 'x' button */
.remove-btn {
    background: #ff4444;
    color: white;
    border: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.remove-btn:hover {
    background: #cc0000;
}

/* The Clear Cart button styling */
.danger-btn {
    background: #ff4444 !important;
    /* Force red background */
    color: white;
}

.danger-btn:hover {
    background: #cc0000 !important;
}

/* Slider Logic */
.slider-wrapper {
    overflow: hidden;
    /* Hide the second panel until it slides in */
    padding: 0 !important;
    max-width: 420px;
}

.cart-slider {
    display: flex;
    width: 200%;
    /* Two panels side-by-side */
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.cart-panel {
    width: 50%;
    padding: 1.5rem;
    flex-shrink: 0;
    max-height: 90vh;
    min-height: 90vh;

    display: flex;
    /* 🔑 */
    flex-direction: column;
    /* 🔑 */
}

#cart-items {
    flex: 1;
    overflow-y: auto;

    padding-right: 12px;
    /* space for scrollbar */
    margin-right: -12px;
    /* pulls scrollbar to edge */

    scrollbar-gutter: stable;
}

#cart-items::-webkit-scrollbar {
    width: 6px;
}

#cart-items::-webkit-scrollbar-track {
    background: transparent;
}

#cart-items::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 10px;
}

#cart-items::-webkit-scrollbar-thumb:hover {
    background: #aaa;
}

/* Slide state */
.cart-slider.slide-active {
    transform: translateX(-50%);
}

/* Extended Form Styles */
.extended input,
.extended textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 8px;
    margin-bottom: 8px;
    font-family: inherit;
}

@media (max-width: 768px) {
    ::-webkit-scrollbar {
        display: none;
    }

    * {
        scrollbar-width: none;
    }
}


/* Hide scrollbar when idle (WebKit only) */
body:not(:hover)::-webkit-scrollbar-thumb {
    background-color: transparent;
}

/* --- ORDER SUCCESS STYLES --- */
.success-container {
    text-align: center;
    padding: 40px 20px;
    animation: fadeIn 0.5s ease-in-out;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%; /* Centers it vertically in the panel */
}

.success-container h2 {
    color: #333;
    margin-top: 20px;
    font-size: 1.8rem;
}

.success-container p {
    color: #666;
    margin: 5px 0;
}

.order-id {
    font-weight: bold;
    color: #ff6600; /* Stikies Orange */
    font-size: 1.1rem;
    margin: 10px 0 !important;
}

.btn-continue {
    background-color: #333;
    color: #fff;
    padding: 12px 30px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    margin-top: 30px;
    font-size: 1rem;
    transition: background 0.3s;
}

.btn-continue:hover {
    background-color: #000;
}

/* Checkmark Animation */
/* REPLACE THE OLD CHECKMARK CSS WITH THIS */

.success-icon {
    width: 80px;
    height: 80px;
    background: #2ecc71;      /* Green background */
    border-radius: 50%;       /* Makes it a circle */
    display: flex;            /* Flexbox to center the icon */
    align-items: center;      /* Vertically center */
    justify-content: center;  /* Horizontally center */
    margin: 0 auto 20px auto; /* Center the circle itself */
    box-shadow: 0 4px 15px rgba(46, 204, 113, 0.4); /* Nice glow effect */
    animation: popIn 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.success-icon i {
    color: white;
    font-size: 48px;          /* Size of the tick */
    font-weight: bold;
    -webkit-text-stroke: 1px #2ecc71; /* Makes the tick look sharper */
}

/* Optional Pop Animation */
@keyframes popIn {
    0% { transform: scale(0); opacity: 0; }
    100% { transform: scale(1); opacity: 1; }
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}


/* ===== GLOBAL SCROLLBAR (DESKTOP) ===== */


/* Chrome / Edge / Brave */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background-color: rgba(0, 0, 0, 0.35);
    border-radius: 10px;
    transition: background-color 0.2s ease;
}

::-webkit-scrollbar-thumb:hover {
    background-color: rgba(0, 0, 0, 0.55);
}

/* --- CAROUSEL STYLES --- */
.carousel-container {
    max-width: 1584px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* Hide all slides by default */
.carousel-slide {
    display: none;
    width: 100%;
}

/* Force specific aspect ratio and fit */
.carousel-slide img {
    width: 100%;
    height: auto;
    aspect-ratio: 1584 / 280;
    object-fit: cover;
    vertical-align: middle;
}

/* Navigation Buttons (Prev/Next) */
.prev,
.next {
    cursor: pointer;
    position: absolute;
    top: 50%;
    width: auto;
    padding: 16px;
    margin-top: -22px;
    color: white;
    font-weight: bold;
    font-size: 18px;
    transition: 0.6s ease;
    border-radius: 0 3px 3px 0;
    user-select: none;
    background-color: rgba(0, 0, 0, 0.2);
}

.next {
    right: 0;
    border-radius: 3px 0 0 3px;
}

.prev:hover,
.next:hover {
    background-color: rgba(0, 0, 0, 0.8);
}

/* Caption Text */
.carousel-caption {
    color: #fff;
    font-size: 24px;
    font-weight: bold;
    position: absolute;
    bottom: 30px;
    width: 100%;
    text-align: center;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.7);
}

/* Dots/Bullets */
.dots-container {
    text-align: center;
    position: absolute;
    bottom: 5px;
    width: 100%;
}

.dot {
    cursor: pointer;
    height: 10px;
    width: 10px;
    margin: 0 4px;
    background-color: #bbb;
    border-radius: 50%;
    display: inline-block;
    transition: background-color 0.6s ease;
}

.dot.active,
.dot:hover {
    background-color: #ff6600;
}


/* Fading Animation */
.fade {
    animation-name: fade;
    animation-duration: 1.5s;
}

@keyframes fade {
    from {
        opacity: .4
    }

    to {
        opacity: 1
    }
}

/* Mobile Adjustment */
@media only screen and (max-width: 600px) {

    .prev,
    .next,
    .carousel-caption {
        font-size: 14px;
    }
}

/* --- CATEGORY SCROLL BAR (Add to bottom of style.css) --- */
.category-scroll-container {
    display: flex;
    /* This makes them sit side-by-side */
    overflow-x: auto;
    /* Enables horizontal scrolling */
    gap: 20px;
    padding: 20px;
    background: transparent;
    padding-bottom: 0;

    /* --- CENTERING MAGIC STARTS HERE --- */
    width: fit-content;
    /* Shrinks the box to fit the icons */
    max-width: 100%;
    /* Prevents it from going off-screen on mobile */
    margin: 0 auto;
    /* Centers the container horizontally */
    /* ----------------------------------- */

    /* Hide scrollbar for clean look */
    scrollbar-width: none;
    /* Firefox */
    -ms-overflow-style: none;
    /* IE/Edge */
}

/* Hide scrollbar for Chrome/Safari */
.category-scroll-container::-webkit-scrollbar {
    display: none;
}

.category-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    min-width: 80px;
    /* Prevents squishing */
    transition: transform 0.2s;
}

.category-item:hover {
    transform: translateY(-5px);
}

.cat-icon {
    width: 60px;
    /* Fixed width */
    height: 60px;
    /* Fixed height */
    border-radius: 50%;
    /* MAKES IT CIRCULAR */
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 24px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

.category-item span {
    font-size: 12px;
    font-weight: 500;
    color: #555;
    text-align: center;
    white-space: nowrap;
}

.category-scroll-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* arrows */
.cat-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.9);
    border: none;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
    width: 34px;
    height: 34px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 10;
    display: none;
    /* hidden by default */
}

.cat-arrow i {
    font-size: 18px;
    color: #333;
}

.cat-arrow.left {
    left: -10px;
}

.cat-arrow.right {
    right: -10px;
}

/* show arrows only on mobile */
@media (max-width: 768px) {
    .cat-arrow {
        display: flex;
        align-items: center;
        justify-content: center;
    }
}

/* Active category ring */
.category-item.active .cat-icon {
    box-shadow:
        0 0 0 3px #ff6600,
        0 0 0 9px rgba(255, 102, 0, 0.18);
}


/* Optional: smoother feel */
.category-item {
    transition: transform 0.2s ease;
}

/* --- DISCOUNT BADGE & OLD PRICE STYLES --- */

/* 1. Ensure the card can hold absolute elements */
.sticker-card {
    position: relative; 
}

/* 2. Style the % OFF badge */
.discount-badge {
    position: absolute;
    top: 10px;
    left: 10px; /* Change to right: 10px; if you prefer it on the right side */
    background-color: #ff4444; /* Bright red to catch attention */
    color: white;
    padding: 4px 8px;
    font-size: 0.75rem;
    font-weight: 800;
    border-radius: 6px;
    z-index: 10;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    letter-spacing: 0.5px;
}

/* 3. Style the old strikethrough price */
.old-price {
    text-decoration: line-through;
    text-decoration-color: #ff4444;
    color: #999;
    font-size: 0.85em;
    margin-right: 6px;
    font-weight: 400;
}

.new-price {
    font-weight: bold;
}

/* 4. Tweak the detail modal price to look good with the old price */
.modal-content-detail .price {
    display: flex;
    justify-content: center;
    align-items: baseline;
}


/* --- BACKGROUND SHAPES (Imported from Landing) --- */
.hero-bg-shapes {
    position: fixed;
    inset: 0;
    pointer-events: none; /* Ensures users can click through the shapes */
    z-index: 0;           /* Keeps shapes behind your content */
    overflow: hidden;
}

.shape {
    position: absolute;
    border-radius: 50%;
    opacity: 0.08;
}

.shape-1 {
    width: 400px;
    height: 400px;
    background: #ff6600;
    top: -100px;
    right: -100px;
}

.shape-2 {
    width: 300px;
    height: 300px;
    background: #ff6600;
    bottom: 10%;
    left: -80px;
}

.shape-3 {
    width: 200px;
    height: 200px;
    background: #333;
    top: 50%;
    right: 20%;
}

/* Ensure your main content sits above the background */
main, .carousel-container, .category-scroll-wrapper {
    position: relative;
    z-index: 1;
}