/* products-index.css — أنماط خاصة بهذه الصفحة وحدها.
   المرحلة 3: كانت مكتوبة داخل <style> فى الـ View، تنزل مع كل
   طلب ولا يستطيع المتصفح تخزينها. الآن ملف مستقل قابل للتخزين. */

.products-pro-page {
    --products-primary: #1a1a1a;
    --products-accent: #d4a017;
    --products-soft: #faf6ec;
    --products-border: #e8dfc4;
    direction: rtl;
}

.products-pro-hero {
    position: relative;
    overflow: hidden;
    background:
        radial-gradient(circle at 15% 20%, rgba(212,160,23,.18), transparent 28%),
        linear-gradient(135deg, #1a1a1a 0%, #1a1a1a 55%, #1a1a1a 100%);
    color: #fff;
    padding: 90px 0 70px;
}

.products-pro-hero::after {
    content: "";
    position: absolute;
    inset: auto -80px -180px auto;
    width: 420px;
    height: 420px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .06);
}

.products-pro-hero .container {
    position: relative;
    z-index: 2;
}

.products-pro-kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border: 1px solid rgba(255,255,255,.22);
    border-radius: 999px;
    background: rgba(255,255,255,.08);
    color: #f4d693;
    font-weight: 700;
    margin-bottom: 18px;
}

.products-pro-hero h1 {
    font-size: clamp(2.1rem, 4vw, 4.2rem);
    font-weight: 900;
    line-height: 1.15;
    margin-bottom: 18px;
}

.products-pro-hero p {
    max-width: 760px;
    color: rgba(255,255,255,.82);
    font-size: 1.15rem;
    line-height: 1.9;
    margin: 0 auto;
}

.products-pro-stats {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
    margin-top: 34px;
}

.products-pro-stat {
    padding: 18px;
    border-radius: 18px;
    background: rgba(255,255,255,.09);
    border: 1px solid rgba(255,255,255,.12);
    backdrop-filter: blur(8px);
}

.products-pro-stat strong {
    display: block;
    font-size: 1.55rem;
    color: #f4d693;
    margin-bottom: 4px;
}

.products-pro-section {
    padding: 70px 0;
    background: #fff;
}

.products-pro-section.alt {
    background: linear-gradient(180deg, #fff 0%, #faf6ec 100%);
}

.products-pro-title {
    text-align: center;
    margin-bottom: 36px;
}

.products-pro-title span {
    color: var(--products-accent);
    font-weight: 800;
}

.products-pro-title h2 {
    margin: 8px 0 0;
    font-weight: 900;
    color: var(--products-primary);
}

.products-category-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 22px;
}

.products-category-card {
    display: block;
    height: 100%;
    padding: 24px;
    text-decoration: none;
    color: inherit;
    background: #fff;
    border: 1px solid var(--products-border);
    border-radius: 24px;
    box-shadow: 0 16px 35px rgba(26,26,26,.08);
    transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}

.products-category-card:hover {
    transform: translateY(-8px);
    border-color: rgba(212,160,23,.35);
    box-shadow: 0 22px 46px rgba(26,26,26,.13);
}

.products-category-card img {
    height: 190px;
    width: 100%;
    object-fit: contain;
    margin-bottom: 18px;
}

.products-category-card h3 {
    color: var(--products-primary);
    font-weight: 900;
    margin-bottom: 10px;
}

.products-category-card p {
    color: #656873;
    line-height: 1.8;
    margin-bottom: 0;
}

.products-pro-filters {
    background: #fff;
    border: 1px solid var(--products-border);
    border-radius: 22px;
    padding: 18px;
    box-shadow: 0 12px 30px rgba(26,26,26,.06);
    display: grid;
    grid-template-columns: 1fr 260px;
    gap: 14px;
    align-items: center;
}

.products-pro-filters .search-wrap {
    position: relative;
}

.products-pro-filters .search-icon {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--products-accent);
    font-size: 1rem;
    pointer-events: none;
    z-index: 2;
    transition: color .2s ease;
}

.products-pro-filters .search-wrap input.form-control {
    padding-right: 44px;
    height: 46px;
    border: 1.5px solid var(--products-border);
    border-radius: 12px;
    font-weight: 600;
    transition: border-color .2s ease, box-shadow .2s ease;
}

    .products-pro-filters .search-wrap input.form-control:focus {
        border-color: var(--products-accent);
        box-shadow: 0 0 0 .2rem rgba(212, 160, 23, .18);
    }

.products-pro-filters .form-select {
    height: 46px;
    border: 1.5px solid var(--products-border);
    border-radius: 12px;
    font-weight: 700;
    cursor: pointer;
}

    .products-pro-filters .form-select:focus {
        border-color: var(--products-accent);
        box-shadow: 0 0 0 .2rem rgba(212, 160, 23, .18);
    }

.products-pro-filters .search-wrap input.form-control::-webkit-search-cancel-button {
    cursor: pointer;
}

.products-pro-grid .product-card {
    height: 100%;
}

@media (max-width: 991px) {
    .products-category-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .products-pro-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .products-pro-hero { padding: 70px 0 52px; }
}

@media (max-width: 575px) {
    .products-pro-filters { grid-template-columns: 1fr; gap: 10px; }
    .products-pro-hero h1 { font-size: 1.8rem; }
    .products-pro-hero p { font-size: .98rem; line-height: 1.85; }
    .products-pro-hero { padding: 56px 0 42px; }
    .products-pro-title h2 { font-size: 1.5rem; }
    .products-pro-section { padding: 48px 0; }
    .products-category-grid { grid-template-columns: 1fr; }
    .products-pro-stats { grid-template-columns: 1fr; }
}

/* ===== Pagination احترافى بألوان الموقع (أسود/ذهبى) ===== */
.products-pro-page .pagination {
    gap: 8px;
    margin-top: 36px;
    padding: 0;
    flex-wrap: wrap;
}

    .products-pro-page .pagination .page-item .page-link {
        min-width: 44px;
        height: 44px;
        border-radius: 12px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        padding: 0 14px;
        background: #fff;
        border: 1.5px solid #e8dfc4;
        color: #1a1a1a;
        font-weight: 800;
        font-size: 1rem;
        box-shadow: 0 4px 12px rgba(26,26,26,.05);
        transition: all .2s ease;
        margin: 0;
    }

        .products-pro-page .pagination .page-item .page-link:hover {
            background: linear-gradient(135deg, #faf6ec, #fff);
            border-color: #d4a017;
            color: #1a1a1a;
            transform: translateY(-2px);
            box-shadow: 0 8px 18px rgba(212,160,23,.18);
            z-index: 1;
        }

        .products-pro-page .pagination .page-item .page-link:focus {
            box-shadow: 0 0 0 3px rgba(212,160,23,.25);
            outline: none;
        }

    /* الصفحة الحالية */
    .products-pro-page .pagination .page-item.active .page-link {
        background: linear-gradient(135deg, #1a1a1a 0%, #0a0a0a 100%);
        border-color: #d4a017;
        color: #f0c75e;
        box-shadow:
            0 0 0 1px rgba(212,160,23,.6) inset,
            0 8px 20px rgba(26,26,26,.25);
        transform: translateY(-1px);
    }

    .products-pro-page .pagination .page-item.disabled .page-link {
        background: #f5f5f5;
        border-color: #e8dfc4;
        color: #b5b1a8;
        cursor: not-allowed;
        box-shadow: none;
    }

    /* أزرار السابق/التالى */
    .products-pro-page .pagination .page-item .page-link[aria-label] i {
        font-size: .85rem;
    }

@media (max-width: 575px) {
    .products-pro-page .pagination { gap: 5px; }
    .products-pro-page .pagination .page-item .page-link {
        min-width: 38px;
        height: 38px;
        padding: 0 10px;
        font-size: .92rem;
    }
}

.products-pro-page #products-list {
    scroll-margin-top: 90px;
}
