/* Chanya Product Cards — Premium Flat UI */

.chanya-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1px;
    background: #d0c9c0;
    border: 1px solid #d0c9c0;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

.chanya-grid * {
    box-sizing: border-box;
}

.chanya-card {
    background: #faf9f7;
    position: relative;
    display: flex;
    flex-direction: column;
    min-width: 0;
    transition: background 0.2s ease;
}

.chanya-card:hover {
    background: #ffffff;
}

/* Wishlist */

.chanya-wishlist {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 2;
    font-size: 18px;
    color: #999;
    cursor: pointer;
    line-height: 1;
    background: rgba(250, 249, 247, 0.85);
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    padding: 0;
    border-radius: 0;
    font-family: inherit;
    transition: color 0.2s ease;
}

.chanya-wishlist:hover {
    color: #c0392b;
}

.chanya-wishlist.is-active {
    color: #c0392b;
}

.chanya-wishlist:focus-visible {
    outline: 2px solid #7a7455;
    outline-offset: 2px;
}

/* Image */

.chanya-image {
    width: 100%;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    background: #ede9e2;
}

.chanya-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease;
}

.chanya-card:hover .chanya-image img {
    transform: scale(1.04);
}

/* Content */

.chanya-content {
    padding: 14px 16px 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 1;
}

/* Title */

.chanya-content h3 {
    margin: 0;
    font-size: 10px;
    font-weight: 500;
    color: #777;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    line-height: 1.5;
}

/* Price */

.chanya-price {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 6px;
    line-height: 1;
}

/* WooCommerce price — sale price */

.chanya-price ins {
    text-decoration: none;
}

.chanya-price ins .woocommerce-Price-amount {
    font-size: 16px;
    font-weight: 500;
    color: #1a1a1a;
    letter-spacing: -0.01em;
    text-decoration: none;
}

/* WooCommerce price — regular/only price */

.chanya-price > .woocommerce-Price-amount {
    font-size: 16px;
    font-weight: 500;
    color: #1a1a1a;
    letter-spacing: -0.01em;
}

/* Strikethrough old price */

.chanya-price del {
    text-decoration: none;
    display: inline-flex;
    align-items: baseline;
}

.chanya-price del .woocommerce-Price-amount {
    font-size: 12px;
    font-weight: 400;
    color: #bbb;
    text-decoration: line-through;
    text-decoration-color: #999;
    text-decoration-thickness: 1px;
    -webkit-text-decoration-line: line-through;
    -webkit-text-decoration-color: #999;
}

/* Fallback plain text price */

.chanya-price bdi {
    font-size: 16px;
    font-weight: 500;
    color: #1a1a1a;
}

/* Actions */

.chanya-actions {
    display: flex;
    gap: 6px;
    margin-top: auto;
}

.chanya-view,
.chanya-cart {
    flex: 1;
    min-width: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 11px 8px;
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.09em;
    text-transform: uppercase;
    text-decoration: none;
    text-align: center;
    cursor: pointer;
    transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
    border-radius: 0;
    line-height: 1;
    white-space: nowrap;
}

.chanya-view {
    background: transparent;
    color: #1a1a1a;
    border: 1px solid #ccc;
}

.chanya-view:hover {
    border-color: #7a7455;
    color: #7a7455;
}

.chanya-cart {
    background: #7a7455;
    color: #faf9f7;
    border: 1px solid #7a7455;
}

.chanya-cart:hover {
    background: #656144;
    border-color: #656144;
    color: #fff;
}

/* Tablet */

@media (max-width: 900px) {
    .chanya-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

/* Mobile — 2 per row always */

@media (max-width: 640px) {
    .chanya-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 1px;
    }
    .chanya-content {
        padding: 10px 10px 12px;
        gap: 7px;
    }
    .chanya-content h3 {
        font-size: 9px;
        letter-spacing: 0.06em;
    }
    .chanya-price ins .woocommerce-Price-amount,
    .chanya-price > .woocommerce-Price-amount,
    .chanya-price bdi {
        font-size: 14px;
    }
    .chanya-price del .woocommerce-Price-amount {
        font-size: 11px;
    }
    .chanya-view,
    .chanya-cart {
        font-size: 8.5px;
        padding: 10px 3px;
        letter-spacing: 0.03em;
    }
}