/* ===== VENDOR DETAIL PAGE ===== */

/* ========================================
   HERO SECTION - Full Viewport
   ======================================== */
.vendor-hero-section {
    position: relative;
    height: 100vh;
    min-height: 600px;
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    display: flex;
    align-items: flex-end;
    padding-bottom: 80px;
}

.vendor-hero-overlay {
    position: absolute;
    inset: 0;
}

.vendor-hero-content {
    position: relative;
    z-index: 1;
    max-width: 700px;
}

.vendor-hero-logo {
    margin-bottom: 24px;
}

.vendor-hero-logo img {
    max-height: 50px;
    width: auto;
    filter: brightness(0) invert(1);
}

.vendor-hero-content h1 {
    font-size: 48px;
    font-weight: 800;
    color: var(--white);
    margin-bottom: 16px;
    line-height: 1.1;
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.hero-description {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.7;
    margin-bottom: 24px;
}

.partner-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 28px;
    background: #5b7fff;
    color: white;
    font-size: 15px;
    font-weight: 600;
    border-radius: 50px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.partner-btn:hover {
    background: #4169e1;
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(91, 127, 255, 0.3);
}

.partner-btn i {
    font-size: 14px;
    transition: transform 0.3s ease;
}

.partner-btn:hover i {
    transform: translateX(4px);
}

/* ========================================
   PRODUCTS OFFERED SECTION
   ======================================== */
.vendor-products-section {
    background: var(--white);
    padding: 100px 0;
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-header h2 {
    font-size: 42px;
    font-weight: 800;
    color: #1f2937;
    margin: 0;
    line-height: 1.2;
}

.vendor-categories {
    display: flex;
    flex-direction: column;
    gap: 80px;
}

/* Category Row */
.category-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.category-row.image-right {
    direction: ltr;
}

.category-row.image-right .category-image {
    order: 2;
}

.category-row.image-right .category-content {
    order: 1;
}

/* ========================================
   RTL (Arabic) FIXES
   ======================================== */

/* In RTL, image-left rows: image naturally goes to the right due to RTL flow,
   so we force image to the left by reversing order */
[dir="rtl"] .category-row.image-left .category-image {
    order: 2;
}

[dir="rtl"] .category-row.image-left .category-content {
    order: 1;
}

/* In RTL, image-right rows: we want image on the right,
   which in RTL means resetting the order override */
[dir="rtl"] .category-row.image-right {
    direction: rtl;
}

[dir="rtl"] .category-row.image-right .category-image {
    order: unset;
}

[dir="rtl"] .category-row.image-right .category-content {
    order: unset;
}

/* ========================================
   END RTL FIXES
   ======================================== */

.category-image {
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
}

.category-image img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.4s ease;
}

.category-row:hover .category-image img {
    transform: scale(1.05);
}

.category-content h3 {
    font-size: 32px;
    font-weight: 800;
    color: #1f2937;
    margin-bottom: 16px;
    line-height: 1.2;
}

.category-content p {
    font-size: 16px;
    color: #4b5563;
    line-height: 1.7;
    margin-bottom: 24px;
}

.view-products-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background: #5b7fff;
    color: white;
    font-size: 15px;
    font-weight: 600;
    border-radius: 8px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.view-products-btn:hover {
    background: #4169e1;
    transform: translateY(-2px);
}

/* ========================================
   FEATURED PRODUCTS SECTION
   ======================================== */
.vendor-featured-products {
    background: #f8f9fa;
    padding: 100px 0;
}

.featured-header {
    text-align: center;
    margin-bottom: 50px;
}

.featured-header h2 {
    font-size: 36px;
    font-weight: 800;
    color: #1f2937;
    margin: 0;
}

.featured-products-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-bottom: 50px;
}

.featured-product-card {
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    overflow: hidden;
    text-decoration: none;
    transition: all 0.3s ease;
}

.featured-product-card:hover {
    border-color: #5b7fff;
    transform: translateY(-4px);
    box-shadow: 0 10px 30px rgba(91, 127, 255, 0.15);
}

.featured-product-image {
    width: 100%;
    height: 240px;
    background: white;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border-bottom: 1px solid #e5e7eb;
}

.featured-product-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.product-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    color: #d1d5db;
}

.product-placeholder i {
    font-size: 48px;
}

.featured-product-info {
    padding: 20px;
}

.product-category {
    display: inline-block;
    padding: 0;
    background: none;
    color: #9ca3af;
    font-size: 10px;
    font-weight: 500;
    border-radius: 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
}

.product-description {
    font-size: 13px;
    color: #6b7280;
    margin: 0 0 4px 0;
    line-height: 1.4;
}

.featured-product-info h4 {
    font-size: 16px;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 8px;
    line-height: 1.4;
}

.product-application {
    font-size: 13px;
    color: #6b7280;
    margin: 0;
}

.view-all-cta {
    text-align: center;
}

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

/* Tablet - 992px and below */
@media (max-width: 992px) {
    .vendor-hero-content h1 {
        font-size: 42px;
    }

    .section-header h2 {
        font-size: 36px;
    }

    .category-row {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .category-row.image-right .category-image,
    .category-row.image-right .category-content {
        order: unset;
    }

    .category-row .category-image {
        order: -1;
    }

    /* RTL responsive: keep image on top for all rows */
    [dir="rtl"] .category-row.image-left .category-image,
    [dir="rtl"] .category-row.image-right .category-image {
        order: -1;
    }

    [dir="rtl"] .category-row.image-left .category-content,
    [dir="rtl"] .category-row.image-right .category-content {
        order: unset;
    }

    .category-content h3 {
        font-size: 28px;
    }

    .featured-products-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Mobile - 768px and below */
@media (max-width: 768px) {
    .vendor-hero-section {
        height: 80vh;
        min-height: 500px;
        padding-bottom: 60px;
    }

    .vendor-hero-logo img {
        max-height: 60px;
    }

    .vendor-hero-content h1 {
        font-size: 36px;
    }

    .hero-description {
        font-size: 16px;
    }

    .vendor-products-section,
    .vendor-featured-products {
        padding: 80px 0;
    }

    .section-header {
        margin-bottom: 40px;
    }

    .section-header h2 {
        font-size: 32px;
    }

    .vendor-categories {
        gap: 60px;
    }

    .category-content h3 {
        font-size: 24px;
    }

    .featured-header h2 {
        font-size: 28px;
    }

    .featured-products-grid {
        grid-template-columns: 1fr;
    }
}
