/* ═══════════════════════════════════════════════════════════
   Nubicare Product Cards – Stylesheet
   ═══════════════════════════════════════════════════════════ */

/* ── Grid ── */
.npc-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    width: 100%;
}

/* ── Card ── */
.npc-card {
    background: #ffffff;
    border-radius: 16px;
    overflow: hidden;
    transition: box-shadow 0.25s ease, transform 0.25s ease;
    position: relative;
    cursor: pointer;
}

.npc-card:hover {
    box-shadow: 0 8px 32px rgba(0,0,0,0.12);
}

/* ── Image Wrap ── */
.npc-card__image-wrap {
    position: relative;
    overflow: hidden;
    height: 300px;
    background: #f5f5f5;
    border-radius: 16px;
}

.npc-card__img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}

.npc-card:hover .npc-card__img {
    transform: scale(1.03);
}

/* ── Wishlist Button ── */
.npc-card__wishlist {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 10;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: 1.5px solid rgba(0,0,0,0.25);
    background: rgba(255,255,255,0.92);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
    padding: 0;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.npc-card__wishlist:hover {
    transform: scale(1.1);
    background: #fff;
}

.npc-card__wishlist .heart-icon {
    width: 18px;
    height: 18px;
    color: #1a1a1a;
    transition: color 0.2s ease;
    display: block;
}

.npc-card__wishlist.is-active {
    border-color: #e03a3a;
    background: rgba(255,255,255,0.95);
}

.npc-card__wishlist.is-active .heart-icon {
    color: #e03a3a;
}

/* Heart pulse on add */
@keyframes npc-pulse {
    0%   { transform: scale(1); }
    40%  { transform: scale(1.35); }
    80%  { transform: scale(0.9); }
    100% { transform: scale(1); }
}
.npc-card__wishlist.npc-pulse .heart-icon {
    animation: npc-pulse 0.4s ease;
}

/* ── Add To Cart Overlay ── */
.npc-card__overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 14px 16px 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transform: translateY(12px);
    transition: opacity 0.28s ease, transform 0.28s ease;
    background: linear-gradient(to top, rgba(0,0,0,0.18) 0%, transparent 100%);
    border-radius: 0 0 16px 16px;
}

.npc-card:hover .npc-card__overlay {
    opacity: 1;
    transform: translateY(0);
}

.npc-card__add-to-cart {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: #1a1a1a;
    color: #ffffff;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.01em;
    padding: 13px 28px;
    border-radius: 50px;
    border: none;
    cursor: pointer;
    width: 100%;
    max-width: 320px;
    transition: background 0.2s ease, transform 0.15s ease;
    white-space: nowrap;
    font-family: inherit;
}

.npc-card__add-to-cart:hover {
    background: #333333;
    color: #ffffff;
    text-decoration: none;
    transform: scale(1.02);
}

.npc-btn-arrow {
    display: inline-flex;
    align-items: center;
    opacity: 0.75;
}

.npc-btn-arrow svg {
    width: 16px;
    height: 16px;
}

/* Divider in button */
.npc-card__add-to-cart::before {
    content: '';
    display: inline-block;
    width: 1px;
    height: 16px;
    background: rgba(255,255,255,0.4);
    margin: 0 6px 0 2px;
    order: 2;
}

.npc-card__add-to-cart .npc-btn-arrow {
    order: 3;
}

/* Re-order so text is first, divider second, arrow third */
.npc-card__add-to-cart > *:not(.npc-btn-arrow)::after {
    order: 1;
}

/* ── Body ── */
.npc-card__body {
    padding: 16px 16px 20px;
}

/* ── Category tag ── */
.npc-card__cat-wrap {
    margin-bottom: 10px;
    text-align: center;
}

.npc-card__cat {
    display: inline-block;
    border: 1px solid #d0d0d0;
    background: #ffffff;
    color: #1a1a1a;
    font-size: 12px;
    font-weight: 500;
    padding: 5px 14px;
    border-radius: 20px;
    line-height: 1.4;
    letter-spacing: 0.01em;
}

/* ── Title ── */
.npc-card__title {
    font-size: 17px;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 8px;
    line-height: 1.35;
    text-align: center;
}

.npc-card__title a {
    color: inherit;
    text-decoration: none;
    transition: color 0.15s;
}

.npc-card__title a:hover {
    color: #000;
}

/* ── Rating ── */
.npc-card__rating {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin-bottom: 10px;
}

.npc-card__stars {
    display: inline-flex;
    align-items: center;
    gap: 2px;
}

.npc-card__stars .star-icon {
    width: 16px;
    height: 16px;
}

.npc-card__stars .star-icon.filled {
    fill: #f5a623;
    color: #f5a623;
}

.npc-card__stars .star-icon.empty {
    fill: #e0e0e0;
    color: #e0e0e0;
}

.npc-card__review-count {
    font-size: 13px;
    color: #555555;
    font-weight: 400;
}

/* ── Price ── */
.npc-card__price {
    text-align: center;
    font-size: 20px;
    font-weight: 700;
    color: #1a1a1a;
    margin-top: 4px;
}

.npc-card__price .price {
    font-size: inherit;
    font-weight: inherit;
    color: inherit;
}

.npc-card__price del {
    font-size: 14px;
    color: #999;
    font-weight: 400;
    margin-right: 6px;
}

.npc-card__price ins {
    text-decoration: none;
}

/* ── No products ── */
.npc-no-products {
    padding: 20px;
    text-align: center;
    color: #888;
    font-style: italic;
}

/* ══════════════════════════════════
   RESPONSIVE
══════════════════════════════════ */
@media ( max-width: 1200px ) {
    .npc-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media ( max-width: 1024px ) {
    .npc-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media ( max-width: 768px ) {
    .npc-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }
    .npc-card__image-wrap {
        height: 220px;
    }
    .npc-card__title {
        font-size: 14px;
    }
    .npc-card__price {
        font-size: 17px;
    }
}

@media ( max-width: 480px ) {
    .npc-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    .npc-card__image-wrap {
        height: 280px;
    }
    .npc-card__overlay {
        opacity: 1;
        transform: translateY(0);
    }
    .npc-card__add-to-cart {
        font-size: 13px;
        padding: 11px 20px;
    }
}

/* ── Add To Cart: divider style ── */
.npc-card__add-to-cart {
    position: relative;
}

.npc-atc-inner {
    display: inline-flex;
    align-items: center;
    gap: 0;
    width: 100%;
    justify-content: center;
}

.npc-atc-text {
    font-weight: 600;
    font-size: 14px;
}

.npc-atc-divider {
    display: inline-block;
    width: 1px;
    height: 18px;
    background: rgba(255,255,255,0.35);
    margin: 0 12px;
}

.npc-atc-arrow {
    display: inline-flex;
    align-items: center;
}
