/* =============================================================
   تنسيقات صفحة تفاصيل المنتج (Product Details Page Styles)
   ============================================================= */

/* فتات الخبز وسلسلة الأقسام متجاوبة */
.breadcrumbs-container {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    font-size: 12px;
    font-weight: bold;
    color: var(--text-muted);
    margin-bottom: 24px;
    background-color: #0c101d;
    padding: 12px 20px;
    border-radius: 16px;
    border: 2px solid rgba(56, 189, 248, 0.8);
    width: fit-content;
    box-shadow: 0 10px 15px -3px rgba(14, 165, 233, 0.2);
}
.breadcrumb-item {
    display: flex;
    align-items: center;
    gap: 6px;
}
.breadcrumb-item a {
    color: #cbd5e1;
    text-decoration: none;
    font-weight: 700;
    transition: color 0.2s;
}
.breadcrumb-item a:hover {
    color: #38bdf8;
}
.breadcrumb-separator {
    color: #475569;
    font-size: 12px;
    font-weight: normal;
}

/* شبكة المحتويات الرئيسية */
.product-body-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 40px;
    margin-bottom: 60px;
}
@media (min-width: 640px) {
    .product-body-grid {
        grid-template-columns: repeat(12, minmax(0, 1fr));
        gap: 40px;
        align-items: start;
    }
    .media-column {
        grid-column: span 5 / span 5;
    }
    .details-column {
        grid-column: span 7 / span 7;
    }
}

/* العمود الأيمن: صورة المنتج على الحجم المطلوب للشاشات الكبيرة */
.media-column {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
}
.image-wrapper {
    position: relative;
    width: 100%;
    max-width: 400px;
    background-color: #0c101d;
    border-radius: 24px;
    overflow: hidden;
    border: 1px solid var(--border);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.5), 0 0 30px rgba(56, 189, 248, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
}
.image-wrapper img {
    width: 100%;
    height: auto;
    max-height: 450px;
    object-fit: contain;
    border-radius: 16px;
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}
.image-wrapper:hover img {
    transform: scale(1.03);
}

/* أزرار الانتقال بين الصور الإضافية */
.slider-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    margin-top: 16px;
    width: 100%;
    max-width: 400px;
}
.slider-btn {
    background-color: #111625;
    border: 1px solid var(--border);
    color: var(--text-main);
    width: 46px;
    height: 46px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
    font-size: 16px;
}
.slider-btn:hover {
    background-color: var(--primary);
    border-color: var(--primary);
    color: #090d16;
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(56, 189, 248, 0.25);
}
.slider-btn:active {
    transform: scale(0.95);
}
.slider-indicator {
    font-size: 12px;
    font-weight: 800;
    color: var(--text-muted);
    background-color: rgba(17, 22, 37, 0.6);
    padding: 4px 12px;
    border-radius: 20px;
    border: 1px solid var(--border);
}

/* العمود الأيسر: تفاصيل المنتج خفيفة ومندمجة مثل React */
.details-column {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

/* المظهر الأنيق للعنوان الثاني الفرعي */
.product-subtitle-badge {
    background-color: rgba(56, 189, 248, 0.06);
    border: 1px solid rgba(56, 189, 248, 0.15);
    padding: 12px 18px;
    border-radius: 14px;
    color: var(--primary);
    font-size: 13px;
    font-weight: 800;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    width: fit-content;
}

/* قسم وصف المادة */
.product-desc-section {
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.product-desc-section .section-title {
    font-size: 12px;
    font-weight: 900;
    color: #94a3b8;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 6px;
}

/* صندوق الوصف القابل للتمرير */
.scrollable-description-box {
    max-height: 250px;
    overflow-y: auto;
    font-size: 13.5px;
    line-height: 1.8;
    border-radius: 16px;
    background-color: rgba(9, 13, 22, 0.7);
    border: 1px solid rgba(30, 41, 59, 0.8);
    padding: 24px;
}

/* تصميم شريط التمرير مخصص ليتناسب مع الواجهة المظلمة */
.scrollable-description-box::-webkit-scrollbar {
    width: 6px;
}
.scrollable-description-box::-webkit-scrollbar-track {
    background: #090d16;
    border-radius: 10px;
}
.scrollable-description-box::-webkit-scrollbar-thumb {
    background: #1e293b;
    border-radius: 10px;
}
.scrollable-description-box::-webkit-scrollbar-thumb:hover {
    background: var(--primary);
}

/* حاوية الأسعار والتخفيض */
.price-box {
    background-color: rgba(9, 13, 22, 0.5);
    border: 1px solid rgba(30, 41, 59, 0.8);
    border-radius: 16px;
    padding: 16px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}
.price-value-container {
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.original-price-slashed {
    text-decoration: line-through;
    color: #64748b;
    font-size: 11px;
    font-family: monospace;
}
.active-price-value {
    color: #f59e0b;
    font-size: 24px;
    font-weight: 900;
    display: flex;
    align-items: baseline;
    gap: 4px;
}
.active-price-value span {
    font-size: 13px;
    font-weight: 700;
    color: #f59e0b;
}

/* أزرار الشراء والاضافة الى السلة */
.actions-container {
    display: grid;
    grid-template-columns: 1fr;
    gap: 14px;
}
@media(min-width: 576px) {
    .actions-container {
        grid-template-columns: 1fr 1fr;
    }
}
.detail-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 15px 28px;
    font-size: 13px;
    font-weight: 900;
    border-radius: 14px;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    text-align: center;
    border: none;
    outline: none;
}
.btn-instant-buy {
    background-color: #10b981;
    color: white;
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.2);
}
.btn-instant-buy:hover {
    background-color: #059669;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.3);
}
.btn-add-cart {
    background-color: #111625;
    color: #cbd5e1;
    border: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}
.btn-add-cart:hover {
    background-color: #1e293b;
    color: white;
    border-color: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}
.detail-btn:active {
    transform: translateY(0);
}

/* التنبيه المنبثق للإضافة للسلة */
.cart-toast {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background-color: #10b981;
    color: white;
    padding: 14px 28px;
    border-radius: 16px;
    font-weight: 800;
    font-size: 13px;
    box-shadow: 0 15px 30px rgba(16, 185, 129, 0.3);
    display: flex;
    align-items: center;
    gap: 10px;
    z-index: 5000;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.3s;
    opacity: 0;
    pointer-events: none;
}
.cart-toast.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

/* زر الرجوع المتناسق للخلف */
.back-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #94a3b8;
    text-decoration: none;
    font-size: 13px;
    font-weight: 700;
    transition: all 0.2s ease;
    margin-bottom: 24px;
    padding: 10px 20px;
    background-color: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 9999px;
    width: fit-content;
}
.back-btn:hover {
    color: white;
    background-color: rgba(255, 255, 255, 0.08);
    transform: translateX(4px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}
.back-btn span {
    font-size: 16px;
    line-height: 1;
}

/* كارد تفاصيل المنتج المحسن والتفاعلي */
.product-detail-card {
    background-color: rgba(17, 22, 37, 0.45);
    border: 1px solid rgba(148, 163, 184, 0.1);
    border-radius: 24px;
    padding: 40px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5), 0 0 30px rgba(56, 189, 248, 0.03);
    position: relative;
    margin-bottom: 40px;
}
@media (max-width: 768px) {
    .product-detail-card {
        padding: 24px;
    }
}

/* ترويسة تفاصيل المنتج */
.product-header {
    margin-bottom: 24px;
    padding-bottom: 4px;
}
.product-title-h1 {
    font-size: 28px;
    font-weight: 900;
    color: #ffffff;
    margin: 0;
    line-height: 1.4;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    border-right: 4px solid #f59e0b; /* amber-500 */
    padding-right: 12px;
}
@media (max-width: 768px) {
    .product-title-h1 {
        font-size: 22px;
    }
}

