.ns-product-card {
    --ns-dark: #101820;
    --ns-dark-2: #1f2933;
    --ns-text: #263241;
    --ns-muted: #6b7280;
    --ns-line: rgba(16, 24, 32, .09);
    --ns-accent: #00a046;
    --ns-accent-2: #21c063;
    --ns-accent-dark: #008a3d;
    --ns-accent-soft: rgba(0, 160, 70, .09);
    --ns-red: #ef4444;
    --ns-radius-lg: 22px;
    --ns-shadow-card: 0 12px 36px rgba(15, 23, 42, .07);
    --ns-shadow-hover: 0 22px 58px rgba(15, 23, 42, .12), 0 10px 26px rgba(0, 160, 70, .06);

    position: relative;
    display: flex;
    flex-direction: column;
    min-width: 0;
    height: 100%;
    overflow: hidden;
    border-radius: var(--ns-radius-lg);
    border: 1px solid var(--ns-line);
    background: #fff;
    box-shadow: var(--ns-shadow-card);
    transition: transform .24s ease, box-shadow .24s ease, border-color .24s ease;
}

.ns-product-card *,
.ns-product-card *::before,
.ns-product-card *::after {
    box-sizing: border-box;
}

.ns-product-card:hover {
    transform: translateY(-5px);
    border-color: rgba(0, 160, 70, .24);
    box-shadow: var(--ns-shadow-hover);
}

.ns-product-card__top {
    position: absolute;
    top: 14px;
    left: 14px;
    right: 14px;
    z-index: 5;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 8px;
    pointer-events: none;
}

.ns-product-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.ns-product-badge {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 0 11px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 950;
    line-height: 1;
    box-shadow: 0 10px 26px rgba(15, 23, 42, .10);
    pointer-events: auto;
}

.ns-product-badge--new {
    background: var(--ns-dark);
    color: #fff;
}

.ns-product-badge--sale {
    background: linear-gradient(135deg, var(--ns-accent), var(--ns-accent-2));
    color: #fff;
}

.ns-product-actions {
    display: flex;
    gap: 7px;
    pointer-events: auto;
}

.ns-product-action-btn {
    box-sizing: border-box !important;
    width: 42px !important;
    min-width: 42px !important;
    max-width: 42px !important;
    height: 42px !important;
    min-height: 42px !important;
    max-height: 42px !important;
    padding: 7px !important;
    flex: 0 0 42px !important;
    aspect-ratio: 1 / 1 !important;
    border-radius: 999px !important;
    line-height: 1 !important;
    text-decoration: none !important;
    white-space: nowrap !important;
}

.ns-product-action-btn svg {
    stroke: #101820;
}

.ns-product-action-btn:hover {
    transform: translateY(-2px);
    border-color: rgba(0, 160, 70, .22);
    background: var(--ns-dark);
    color: #fff;
}

.ns-product-action-btn:hover svg {
    stroke: #ffffff;
}

.ns-product-image {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    aspect-ratio: 1 / .82;
    overflow: hidden;
    background:
        radial-gradient(circle at center, rgba(0, 160, 70, .045), transparent 44%),
        linear-gradient(180deg, #ffffff 0%, #f7f8fa 100%);
    text-decoration: none;
}

.ns-product-image::after {
    content: "";
    position: absolute;
    left: 18px;
    right: 18px;
    bottom: 0;
    height: 1px;
    background: rgba(16, 24, 32, .07);
}

.ns-product-image img {
    display: block;
    width: 100%;
    height: auto;
    object-fit: contain;
    transition: transform .32s ease;
}

.ns-product-card:hover .ns-product-image img {
    transform: scale(1.035);
}

.ns-product-content {
    display: flex;
    flex: 1;
    flex-direction: column;
    padding: 18px;
}

.ns-product-category {
    min-height: 18px;
    margin-bottom: 8px;
    color: var(--ns-muted);
    font-size: 12px;
    font-weight: 850;
    line-height: 1.4;
}

.ns-product-category a {
    color: inherit;
    text-decoration: none;
}

.ns-product-category a:hover {
    color: var(--ns-accent-dark);
}

.ns-product-title {
    margin: 0 0 10px;
    color: var(--ns-dark);
    font-size: 17px;
    line-height: 1.35;
    font-weight: 900;
    letter-spacing: -.015em;
}

.ns-product-title a {
    display: -webkit-box;
    min-height: 46px;
    overflow: hidden;
    color: inherit;
    text-decoration: none;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.ns-product-title a:hover {
    color: var(--ns-accent-dark);
}

.ns-product-short {
    display: -webkit-box;
    min-height: 44px;
    margin-bottom: 14px;
    overflow: hidden;
    color: var(--ns-muted);
    font-size: 13px;
    line-height: 1.55;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.ns-product-meta {
    margin-bottom: 14px;
}

.ns-stock {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    min-height: 30px;
    padding: 0 10px;
    border-radius: 999px;
    background: #f3f4f6;
    font-size: 12px;
    font-weight: 950;
}

.ns-stock::before {
    content: "";
    width: 7px;
    height: 7px;
    border-radius: 50%;
}

.ns-stock--in {
    background: rgba(0, 160, 70, .09);
    color: var(--ns-accent-dark);
}

.ns-stock--in::before {
    background: var(--ns-accent);
    box-shadow: 0 0 0 5px rgba(0, 160, 70, .12);
}

.ns-stock--out {
    background: rgba(239, 68, 68, .09);
    color: var(--ns-red);
}

.ns-stock--out::before {
    background: var(--ns-red);
    box-shadow: 0 0 0 5px rgba(239, 68, 68, .12);
}

.ns-product-footer {
    margin-top: auto;
    padding-top: 14px;
    border-top: 1px solid rgba(16, 24, 32, .07);
}

.ns-product-price {
    margin-bottom: 14px;
}

.ns-product-price del {
    display: block;
    margin-bottom: 3px;
    color: var(--ns-muted);
    font-size: 13px;
    font-weight: 700;
}

.ns-product-price ins {
    text-decoration: none;
}

.ns-product-price .amount,
.ns-product-price > .amount,
.ns-product-price strong {
    color: var(--ns-dark);
    font-size: 25px;
    line-height: 1.1;
    font-weight: 950;
    letter-spacing: -.035em;
}

.ns-product-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}
.ns-product-buttons .added_to_cart {
    display: none;
}

.ns-product-more,
.ns-add-to-cart-btn {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    gap: 9px;
    min-height: 48px;
    padding: 0 14px;
    border: 0 !important;
    border-radius: 15px;
    font-size: 13px;
    font-weight: 950;
    line-height: 1;
    text-decoration: none !important;
    cursor: pointer;
    transition: transform .22s ease, box-shadow .22s ease, background .22s ease, color .22s ease;
}

.ns-product-more {
    background: var(--ns-dark);
    color: #fff;
}

.ns-product-more:hover {
    transform: translateY(-2px);
    background: var(--ns-dark-2);
    color: #fff;
}

.ns-add-to-cart-btn {
    background: linear-gradient(135deg, var(--ns-accent), var(--ns-accent-2)) !important;
    color: #fff !important;
    box-shadow: 0 12px 28px rgba(0, 160, 70, .22);
}

.ns-add-to-cart-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 18px 38px rgba(0, 160, 70, .30);
    color: #fff !important;
}

.ns-add-to-cart-btn .ns-cart-icon {
    width: 20px;
    height: 20px;
    flex: 0 0 auto;
    color: #fff;
    transition: transform .22s ease;
}

.ns-add-to-cart-btn:hover .ns-cart-icon {
    transform: translateX(2px) scale(1.04);
}

.ns-products-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

@media (max-width: 1180px) {
    .ns-products-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 720px) {
    .ns-products-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .ns-product-card {
        border-radius: 20px;
    }

    .ns-product-image {
        aspect-ratio: 1 / .76;
    }

    .ns-product-buttons {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 420px) {
    .ns-product-price .amount,
    .ns-product-price > .amount,
    .ns-product-price strong {
        font-size: 23px;
    }
}