/*
Theme Name: Elite Single Company Theme
Theme URI: https://Ahmedshaban.net/
Author: Ahmed Shaban
Description: Single-company WordPress theme converted from a Next.js contractor marketing site. Includes homepage sections, Projects CPT, Testimonials CPT, before/after slider, and AJAX quote calculator.
Version: 1.0.0
Requires at least: 6.5
Tested up to: 6.8
Requires PHP: 8.1
Text Domain: elite-single
*/

/* ── Global RTL & Arabic Optimizations ── */
*, *::before, *::after {
    box-sizing: border-box;
}

html {
    direction: rtl;
    scroll-behavior: auto; /* Let Lenis handle smooth scrolling, not CSS */
    -webkit-text-size-adjust: 100%;
}

html {
    overflow-y: scroll;
}

body {
    direction: rtl;
    text-align: right;
    font-family: var(--font-body, 'Noto Sans Arabic', sans-serif);
    background-color: var(--bg-main, #09090b);
    color: #fff;
    overflow-x: hidden;
}

/* Force scroll enablement if no modal is open (fights external locks) */
body:not(.modal-open),
body:not(.modal-open).antigravity-scroll-lock {
    overflow-y: auto !important;
    overflow-x: hidden !important;
}

/* Arabic numerals and text alignment */
p, h1, h2, h3, h4, h5, h6, li, span, a, label, input, select, textarea, button {
    direction: rtl;
    unicode-bidi: embed;
}

/* Input fields RTL */
input[type="text"],
input[type="tel"],
input[type="email"],
input[type="number"],
textarea {
    text-align: right;
}

/* LTR exceptions (numbers, phone, prices) */
[dir="ltr"], .dir-ltr {
    direction: ltr;
    unicode-bidi: embed;
    text-align: left;
}

/* ── Font utility classes ── */
.font-kufi  { font-family: var(--font-heading, 'Noto Kufi Arabic', sans-serif); }
.font-body  { font-family: var(--font-body,    'Noto Sans Arabic',  sans-serif); }
.font-serif { font-family: 'Cinzel', serif; }

/* ── Reveal Animation ── */
.reveal {
    opacity: 0;
    transform: translateY(24px);
    will-change: transform, opacity;
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
}
.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }
.reveal-delay-4 { transition-delay: 0.4s; }

/* ── Animations ── */
@keyframes fade-in-up {
    from { opacity: 0; transform: translateY(20px); }
    to   { opacity: 1; transform: translateY(0);    }
}
.animate-fade-in-up {
    animation: fade-in-up 0.8s cubic-bezier(0.16, 1, 0.3, 1) both;
}
.animate-fade-in-up.delay-100 { animation-delay: 0.1s; }
.animate-fade-in-up.delay-200 { animation-delay: 0.2s; }
.animate-fade-in-up.delay-300 { animation-delay: 0.3s; }
.animate-fade-in-up.delay-400 { animation-delay: 0.4s; }
.animate-fade-in-up.delay-500 { animation-delay: 0.5s; }

@keyframes fade-in {
    from { opacity: 0; }
    to   { opacity: 1; }
}
.animate-fade-in { animation: fade-in 0.6s ease both; }

@keyframes slide-hint {
    0%   { transform: translateX(-100%); }
    100% { transform: translateX(200%); }
}
.animate-slide-hint { animation: slide-hint 2s linear infinite; }

/* ── Testimonial card stack transition ── */
.testimonial-card {
    will-change: transform, opacity;
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1),
                opacity  0.5s ease,
                z-index  0s 0.25s;
}

/* ── Scrollbar hide utility ── */
.no-scrollbar { scrollbar-width: none; -ms-overflow-style: none; }
.no-scrollbar::-webkit-scrollbar { display: none; }

/* ── Premium Scrollbar Styling ── */
#modal-chat-area::-webkit-scrollbar {
    width: 5px;
}
#modal-chat-area::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.02);
    border-radius: 10px;
}
#modal-chat-area::-webkit-scrollbar-thumb {
    background: rgba(202, 138, 4, 0.2);
    border-radius: 10px;
    transition: background 0.3s;
}
#modal-chat-area::-webkit-scrollbar-thumb:hover {
    background: rgba(202, 138, 4, 0.5);
}

/* For Firefox */
#modal-chat-area {
    scrollbar-width: thin;
    scrollbar-color: rgba(202, 138, 4, 0.2) transparent;
}

/* ── Mobile menu ── */
.mobile-menu-drawer        { display: none; }
.mobile-menu-drawer.is-open{ display: flex; }

/* ── Star fill for lucide ── */
.fill-current { --lucide-fill: currentColor; }