/* =============================================
   UNIFIED PRODUCT CARD STYLES (BEM)
   ============================================= */

/* Grid Container */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 1.75rem;
    padding: 2rem 0;
}

/* Card */
.product-card {
    background: #fff;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.07);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    min-width: 0;
    direction: rtl;
}

.product-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.13);
}

/* Image */
.product-card__image-wrap {
    position: relative;
    width: 100%;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: #f5f5f5;
}

.product-card__image-link {
    display: block;
    width: 100%;
    height: 100%;
}

.product-card__image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.35s ease;
    display: block;
}

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

/* Badges */
.product-card__badge {
    position: absolute;
    padding: 0.3rem 0.7rem;
    border-radius: 20px;
    font-weight: 700;
    font-size: 0.8rem;
    color: #fff;
    z-index: 2;
    line-height: 1.3;
}

.product-card__badge--discount {
    top: 12px;
    right: 12px;
    background: linear-gradient(135deg, #e53935, #ff6f61);
    box-shadow: 0 2px 6px rgba(229, 57, 53, 0.35);
}

.product-card__badge--hot {
    top: 12px;
    left: 12px;
    background: linear-gradient(135deg, #ff6b35, #ffb347);
    box-shadow: 0 2px 6px rgba(255, 107, 53, 0.35);
    font-size: 0.75rem;
    letter-spacing: 0.5px;
}

.product-card__badge--source {
    bottom: 12px;
    left: 12px;
    background: linear-gradient(135deg, #e53935, #c62828);
    box-shadow: 0 2px 6px rgba(229, 57, 53, 0.35);
    font-size: 0.7rem;
    letter-spacing: 0.3px;
    top: auto;
}

/* Body */
.product-card__body {
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

/* Title */
.product-card__title {
    margin: 0 0 0.6rem;
    font-size: 1.1rem;
    font-weight: 600;
    line-height: 1.45;
    height: 3.2em;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
}

.product-card__title a {
    color: #333;
    text-decoration: none;
    transition: color 0.2s ease;
}

.product-card__title a:hover {
    color: #ff6b35;
}

/* Rating */
.product-card__rating {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    margin-bottom: 0.6rem;
}

.product-card__stars {
    display: flex;
    gap: 1px;
}

.product-card__star {
    color: #ddd;
    font-size: 1rem;
    line-height: 1;
}

.product-card__star--filled {
    color: #ffc107;
}

.product-card__reviews {
    font-size: 0.82rem;
    color: #888;
}

/* Pricing */
.product-card__pricing {
    display: flex;
    align-items: baseline;
    gap: 0.6rem;
    margin-bottom: 0.7rem;
    direction: ltr;
    justify-content: flex-end;
}

.product-card__price--current {
    font-size: 1.35rem;
    font-weight: 700;
    color: #ff6b35;
}

.product-card__price--old {
    font-size: 0.95rem;
    color: #999;
    text-decoration: line-through;
    font-weight: 400;
}

/* Features */
.product-card__features {
    list-style: none;
    margin: 0 0 0.75rem;
    padding: 0;
}

.product-card__feature-item {
    font-size: 0.82rem;
    color: #555;
    line-height: 1.7;
    padding-right: 0.25rem;
}

.product-card__feature-item::first-letter {
    color: #28a745;
}

/* Actions */
.product-card__actions {
    display: flex;
    gap: 0.6rem;
    margin-top: auto;
    padding-top: 0.5rem;
}

.product-card__btn {
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.65rem 0.75rem;
    font-size: 0.9rem;
    font-weight: 600;
    font-family: inherit;
    border-radius: 10px;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.25s ease;
    text-align: center;
    line-height: 1.2;
}

.product-card__btn--details {
    background: transparent;
    color: #ff6b35;
    border: 2px solid #ff6b35;
}

.product-card__btn--details:hover {
    background: #ff6b35;
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 107, 53, 0.3);
}

.product-card__btn--buy {
    background: linear-gradient(135deg, #ff9a3d, #ff6b35);
    color: #fff;
    border: 2px solid transparent;
    box-shadow: 0 3px 10px rgba(255, 107, 53, 0.25);
}

.product-card__btn--buy:hover {
    background: linear-gradient(135deg, #ff8730, #e55a2b);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(255, 107, 53, 0.4);
}

/* =============================================
   CATEGORY GUIDE SECTION
   ============================================= */

.category-guide {
    max-width: 900px;
    margin: 0 auto;
    padding: 40px 20px 60px;
    direction: rtl;
}

.category-guide__block {
    background: #fff;
    border-radius: 16px;
    padding: 28px 32px;
    margin-bottom: 20px;
    box-shadow: 0 2px 14px rgba(0, 0, 0, 0.07);
    border: 1px solid #e8e8e8;
}

.category-guide__heading {
    font-size: 1.5rem;
    font-weight: 800;
    color: #1a1a1a;
    margin: 0 0 20px;
    padding-bottom: 12px;
    border-bottom: 3px solid #FF6B35;
    display: flex;
    align-items: center;
    gap: 10px;
    line-height: 1.3;
}

.category-guide__heading-icon {
    font-size: 1.3rem;
    flex-shrink: 0;
}

.category-guide__subheading {
    font-size: 1.1rem;
    font-weight: 700;
    color: #FF6B35;
    margin: 20px 0 10px;
    line-height: 1.4;
}

.category-guide__subheading--standalone {
    font-size: 1.15rem;
    margin: 0 0 16px;
    display: flex;
    align-items: center;
    gap: 8px;
    color: #1a1a1a;
    border-bottom: 2px solid #FF6B35;
    padding-bottom: 10px;
}

.category-guide__text {
    font-size: 0.97rem;
    color: #555;
    line-height: 1.85;
    margin: 0 0 12px;
}

/* Tips — styled card list */
.category-guide__tips {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.category-guide__tip {
    font-size: 0.95rem;
    color: #444;
    line-height: 1.6;
    padding: 12px 16px;
    background: #fff8f5;
    border-radius: 10px;
    border-right: 4px solid #FF6B35;
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.category-guide__tip::before {
    content: "✓";
    color: #FF6B35;
    font-weight: 800;
    flex-shrink: 0;
    margin-top: 1px;
}

/* FAQ */
.category-guide__faq {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.category-guide__faq-item {
    border: 1px solid #e8e8e8;
    border-radius: 10px;
    overflow: hidden;
}

.category-guide__faq-q {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 18px;
    font-weight: 700;
    font-size: 0.97rem;
    color: #1a1a1a;
    cursor: pointer;
    list-style: none;
    gap: 12px;
    user-select: none;
    transition: background 0.2s;
}

.category-guide__faq-q::-webkit-details-marker { display: none; }

.category-guide__faq-item[open] .category-guide__faq-q {
    background: #fff8f5;
}

.category-guide__faq-arrow {
    flex-shrink: 0;
    font-size: 0.7rem;
    color: #FF6B35;
    transition: transform 0.25s ease;
}

.category-guide__faq-item[open] .category-guide__faq-arrow {
    transform: rotate(180deg);
}

.category-guide__faq-answer {
    padding: 0 18px 16px;
    font-size: 0.92rem;
    color: #6b7280;
    line-height: 1.75;
    margin: 0;
    border-top: 1px solid #f0f0f0;
    padding-top: 14px;
}

/* =============================================
   RESPONSIVE
   ============================================= */

@media (max-width: 768px) {
    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
        gap: 1.25rem;
    }

    .product-card__body {
        padding: 1rem;
    }

    .product-card__title {
        font-size: 1rem;
    }

    .product-card__price--current {
        font-size: 1.2rem;
    }

    .category-guide__block {
        padding: 20px 18px;
    }

    .category-guide__heading {
        font-size: 1.25rem;
    }

    .category-guide__subheading {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
    }

    .product-card__body {
        padding: 0.75rem;
    }

    .product-card__title {
        font-size: 0.88rem;
        height: auto;
    }

    .product-card__actions {
        flex-direction: column;
        gap: 0.4rem;
    }

    .product-card__btn {
        font-size: 0.8rem;
        padding: 0.6rem 0.4rem;
    }

    .category-guide {
        padding: 24px 12px 48px;
    }

    .category-guide__block {
        padding: 16px 16px;
        border-radius: 12px;
    }
}
