/* Custom animations and utilities */

.hero-float {
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-12px); }
}

html {
    scroll-behavior: smooth;
}

.no-scrollbar::-webkit-scrollbar {
    display: none;
}
.no-scrollbar {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.scroll-mt-32 {
    scroll-margin-top: 8rem;
}

/* ========== Pagination ========== */
.pagination-area {
    margin-top: 2.5rem;
    display: flex;
    justify-content: center;
}

.page-number,
.pagination-area {
    width: 100%;
}

ul.pagination-nav,
.page-number ul {
    list-style: none;
    padding: 8px;
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 4px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(234, 88, 12, 0.1);
    border: 1px solid #ffedd5;
}

ul.pagination-nav li,
.page-number ul li {
    margin: 0;
}

ul.pagination-nav li a,
ul.pagination-nav li span,
.page-number ul li a,
.page-number ul li span {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 8px 12px;
    text-decoration: none;
    color: #555;
    border-radius: 8px;
    font-weight: 500;
    font-size: 14px;
    transition: all 0.3s ease;
    background: transparent;
}

ul.pagination-nav li a:hover,
.page-number ul li a:hover {
    background: linear-gradient(135deg, #f97316, #ea580c);
    color: #fff;
}

ul.pagination-nav li.active span,
ul.pagination-nav li span.current,
.page-number ul li.active span,
.page-number ul li strong {
    background: linear-gradient(135deg, #f97316, #ea580c);
    color: #fff !important;
    font-weight: 600;
}

/* Content pages */
.prose-content h2,
.prose-content h3 {
    color: #0f172a;
    font-weight: 700;
    margin-top: 1.75rem;
    margin-bottom: 0.75rem;
}

.prose-content p,
.prose-content li {
    color: #475569;
    line-height: 1.75;
    margin-bottom: 0.75rem;
}

.prose-content ul {
    list-style: disc;
    padding-left: 1.25rem;
    margin-bottom: 1rem;
}

.prose-content a {
    color: #ea580c;
    text-decoration: underline;
}

/* Side cart transition helpers */
#sideCartPanel.translate-x-full {
    transform: translateX(100%);
}

/* ========== Image Placeholder ========== */
.image-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 11rem; /* h-44 */
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border: 1px dashed #e2e8f0;
    color: #94a3b8;
    font-size: 2.75rem;
    transition: background 0.3s ease, color 0.3s ease;
}

@media (min-width: 640px) {
    .image-placeholder {
        height: 13rem; /* sm:h-52 */
        font-size: 3rem;
    }
}

.image-placeholder--lg {
    height: 18rem;
    font-size: 3.5rem;
    border-radius: 1rem;
}

@media (min-width: 640px) {
    .image-placeholder--lg {
        height: 24rem;
        font-size: 4rem;
    }
}

.image-placeholder--sm {
    height: 4rem;
    width: 4rem;
    font-size: 1.25rem;
    border-radius: 0.75rem;
    border-style: solid;
}

.product-card:hover .image-placeholder,
.image-placeholder:hover {
    background: linear-gradient(135deg, #fff7ed 0%, #ffedd5 100%);
    color: #fb923c;
}

.image-placeholder i {
    opacity: 0.85;
}

/* ========== Uniform Product Card Images ========== */
.product-card-media {
    display: block;
    width: 100%;
    aspect-ratio: 1 / 1;
    height: auto;
    background: #f8fafc;
    position: relative;
    overflow: hidden;
}

.product-card-img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
    display: block;
    transition: transform 0.5s ease;
}

.product-card:hover .product-card-img {
    transform: scale(1.05);
}

.product-card-media .image-placeholder {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: none;
    border-radius: 0;
    font-size: 2.5rem;
}

/* Floating basket button */
#floatingBasketBtn {
    animation: floatingBasketIn 0.3s ease-out;
}

@keyframes floatingBasketIn {
    from {
        opacity: 0;
        transform: translateY(12px) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}


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

@media (min-width: 640px) {
    .product-card-media .image-placeholder {
        font-size: 3rem;
    }
}
