/* =====================================================================
   site-enhance.css  —  تحسينات بصرية إضافية لموقع الأدهم
   ---------------------------------------------------------------------
   ملف منعزل تمامًا: كل القواعد هنا "إضافات" فوق الكلاسات الموجودة،
   لا يغيّر أى كلاس أصلى ولا يكسر أى تخطيط قائم.
   النظام اللونى المستخدم متطابق مع site.css:
     ذهبى #d4a017  |  ذهبى فاتح #f0c75e  |  حبر #1a1a1a  |  كريمى #faf6ec
   ===================================================================== */

/* ---------------------------------------------------------------------
   1) Scroll Reveal — ظهور تدريجى ناعم للعناصر أثناء التمرير
   --------------------------------------------------------------------- */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity .75s cubic-bezier(.2, .7, .2, 1),
                transform .75s cubic-bezier(.2, .7, .2, 1);
    will-change: opacity, transform;
}

    .reveal.is-in {
        opacity: 1;
        transform: none;
    }

/* اتجاهات بديلة للحركة (تُضاف عبر JS عند الحاجة) */
.reveal.reveal-right { transform: translateX(40px); }
.reveal.reveal-left  { transform: translateX(-40px); }
.reveal.reveal-zoom  { transform: scale(.94); }

.reveal.reveal-right.is-in,
.reveal.reveal-left.is-in,
.reveal.reveal-zoom.is-in {
    transform: none;
}

/* عناصر داخل شبكة تظهر بالتتابع — التأخير يُضبط من JS */
.reveal-stagger > * {
    opacity: 0;
    transform: translateY(26px);
    transition: opacity .6s cubic-bezier(.2, .7, .2, 1),
                transform .6s cubic-bezier(.2, .7, .2, 1);
    will-change: opacity, transform;
}

.reveal-stagger.is-in > * {
    opacity: 1;
    transform: none;
}

/* ---------------------------------------------------------------------
   2) العدّادات المتحركة — مظهر العدد أثناء التحريك
   --------------------------------------------------------------------- */
.count-anim {
    font-variant-numeric: tabular-nums;
    font-feature-settings: "tnum";
}

/* ---------------------------------------------------------------------
   3) خط ذهبى علوى + تعميق الـ hover على البطاقات (توحيد الإحساس مع
      product-card-pro الموجودة بالفعل)
      نستهدف: بطاقات الأقسام، الخدمات، الخطوط الداكنة، بطاقات «عن الشركة»،
      بطاقات معرض المعدات.
   --------------------------------------------------------------------- */
.category-card,
.service-card,
.dark-card,
.home-import-product-card {
    position: relative;
}

/* الخط الذهبى العلوى — يظهر تدريجيًا على hover */
.category-card::before,
.service-card::before,
.home-import-product-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent 0%, #d4a017 20%, #f0c75e 50%, #d4a017 80%, transparent 100%);
    opacity: 0;
    transform: scaleX(0);
    transform-origin: center;
    transition: opacity .35s ease, transform .35s ease;
    z-index: 3;
    pointer-events: none;
}

.category-card:hover::before,
.service-card:hover::before,
.home-import-product-card:hover::before {
    opacity: 1;
    transform: scaleX(1);
}

/* تعميق ظل وحركة الرفع (يكمّل القاعدة الأصلية دون كسرها) */
.category-card:hover,
.service-card:hover,
.home-import-product-card:hover {
    border-color: rgba(212, 160, 23, .35);
    box-shadow: 0 26px 55px rgba(26, 26, 26, .14), 0 0 0 1px rgba(212, 160, 23, .07);
}

/* تكبير لطيف للصورة داخل بطاقات الأقسام/الخدمات عند الـ hover */
.category-card img,
.service-card img {
    transition: transform .55s cubic-bezier(.2, .9, .3, 1.2);
}

.category-card:hover img,
.service-card:hover img {
    transform: scale(1.05);
}

/* بطاقات «عن الشركة» — لمسة رفع وظل ذهبى */
.about-card {
    transition: transform .35s cubic-bezier(.2, .9, .3, 1.2), box-shadow .35s ease;
}

    .about-card:hover {
        transform: translateY(-6px);
        box-shadow: 0 26px 55px rgba(212, 160, 23, .18);
    }

/* البطاقات الداكنة فى قسم خطوط الإنتاج — توهّج ذهبى على الحافة */
.dark-card {
    transition: transform .35s cubic-bezier(.2, .9, .3, 1.2), box-shadow .35s ease, border-color .25s ease;
}

    .dark-card:hover {
        transform: translateY(-6px);
        border-color: rgba(212, 160, 23, .45);
        box-shadow: 0 22px 48px rgba(0, 0, 0, .45), 0 0 0 1px rgba(212, 160, 23, .18);
    }

    .dark-card img {
        transition: transform .55s cubic-bezier(.2, .9, .3, 1.2);
    }

    .dark-card:hover img {
        transform: scale(1.04);
    }

/* ---------------------------------------------------------------------
   4) لمسات على عناوين الأقسام — شرطة ذهبية أمام الـ eyebrow + خط
      أسفل العنوان يظهر مع الـ reveal (مظهر مجلّات راقٍ)
   --------------------------------------------------------------------- */
.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

    .eyebrow::before {
        content: "";
        width: 26px;
        height: 2px;
        background: linear-gradient(90deg, #d4a017, #f0c75e);
        border-radius: 2px;
        flex: 0 0 auto;
        display: inline-block;
    }

/* خط متدرّج يظهر أسفل عنوان القسم عند دخوله للشاشة */
.section-title h2 {
    position: relative;
    padding-bottom: 14px;
}

    .section-title h2::after {
        content: "";
        position: absolute;
        bottom: 0;
        right: 0;
        width: 0;
        height: 3px;
        background: linear-gradient(90deg, #d4a017, #f0c75e);
        border-radius: 3px;
        transition: width .8s cubic-bezier(.2, .7, .2, 1) .15s;
    }

    .section-title.is-in h2::after,
    .section-title h2.is-in::after {
        width: 64px;
    }

/* القسم الداكن: نجعل الخط أوضح قليلًا على الخلفية الداكنة */
.section.dark .section-title h2::after {
    background: linear-gradient(90deg, #f0c75e, #d4a017);
}

/* ---------------------------------------------------------------------
   5) توهّج خلفى خفيف للأقسام الكريمية — عمق بصرى بدون إزعاج
   --------------------------------------------------------------------- */
.section.soft {
    position: relative;
    overflow: hidden;
}

    .section.soft::before {
        content: "";
        position: absolute;
        top: -120px;
        inset-inline-start: -120px;
        width: 360px;
        height: 360px;
        background: radial-gradient(circle, rgba(212, 160, 23, .10), transparent 70%);
        pointer-events: none;
        z-index: 0;
    }

    .section.soft > .container {
        position: relative;
        z-index: 1;
    }

/* ---------------------------------------------------------------------
   6) 3D Tilt — يُفعّل بالـ JS على الأجهزة ذات المؤشّر الدقيق فقط
   --------------------------------------------------------------------- */
.tilt-card {
    transform-style: preserve-3d;
    transition: transform .25s cubic-bezier(.2, .9, .3, 1.2), box-shadow .25s ease;
    will-change: transform;
}

    .tilt-card.is-tilting {
        transition: box-shadow .25s ease;
    }

/* ---------------------------------------------------------------------
   7) معرض الأعمال — overlay ذهبى + caption عند الـ hover
      (الـ JS يلفّ كل صورة داخل .proj-figure ويضيف الكابشن)
   --------------------------------------------------------------------- */
.proj-figure {
    position: relative;
    margin: 0;
    overflow: hidden;
    border-radius: inherit;
    cursor: pointer;
}

    .proj-figure img {
        display: block;
        transition: transform .6s cubic-bezier(.2, .9, .3, 1.2);
    }

    .proj-figure:hover img {
        transform: scale(1.07);
    }

    .proj-figure::after {
        content: "";
        position: absolute;
        inset: 0;
        background: linear-gradient(180deg, transparent 35%, rgba(10, 10, 10, .82) 100%);
        opacity: 0;
        transition: opacity .35s ease;
        pointer-events: none;
    }

    .proj-figure:hover::after {
        opacity: 1;
    }

.proj-figure__caption {
    position: absolute;
    inset-inline: 16px;
    bottom: 14px;
    z-index: 2;
    color: #fff;
    font-weight: 800;
    font-size: 1rem;
    line-height: 1.5;
    transform: translateY(14px);
    opacity: 0;
    transition: transform .4s cubic-bezier(.2, .9, .3, 1.2), opacity .35s ease;
    text-shadow: 0 2px 8px rgba(0, 0, 0, .5);
    display: flex;
    align-items: center;
    gap: 9px;
}

    .proj-figure__caption::before {
        content: "";
        width: 22px;
        height: 2px;
        background: #f0c75e;
        border-radius: 2px;
        flex: 0 0 auto;
    }

.proj-figure:hover .proj-figure__caption {
    transform: translateY(0);
    opacity: 1;
}

/* ---------------------------------------------------------------------
   8) شريط تقدّم القراءة — يظهر أعلى صفحات المقالات فقط
   --------------------------------------------------------------------- */
.reading-progress {
    position: fixed;
    top: 0;
    inset-inline: 0;
    height: 3px;
    z-index: 2000;
    background: transparent;
    pointer-events: none;
}

    .reading-progress__bar {
        height: 100%;
        width: 0;
        background: linear-gradient(90deg, #d4a017, #f0c75e);
        box-shadow: 0 0 10px rgba(212, 160, 23, .55);
        transition: width .1s linear;
    }

/* ---------------------------------------------------------------------
   9) تأثير «لمعة» ذهبية تمرّ على زر عرض السعر (إحساس فاخر)
   --------------------------------------------------------------------- */
.quote-btn {
    position: relative;
    overflow: hidden;
}

    .quote-btn::after {
        content: "";
        position: absolute;
        top: 0;
        inset-inline-start: -120%;
        width: 60%;
        height: 100%;
        background: linear-gradient(120deg, transparent, rgba(255, 255, 255, .55), transparent);
        transform: skewX(-20deg);
        pointer-events: none;
    }

    .quote-btn:hover::after {
        animation: btnShine .85s ease;
    }

@keyframes btnShine {
    from { inset-inline-start: -120%; }
    to   { inset-inline-start: 140%; }
}

/* ---------------------------------------------------------------------
   احترام تفضيل تقليل الحركة — أمان كامل للحساسية الحركية
   --------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
    .reveal,
    .reveal-stagger > * {
        opacity: 1 !important;
        transform: none !important;
        transition: none !important;
    }

    .section-title h2::after { transition: none; }
    .tilt-card { transition: none !important; }
    .quote-btn:hover::after { animation: none; }
    .proj-figure img,
    .category-card img,
    .service-card img,
    .dark-card img { transition: none; }
}
