/* quote-request.css — أنماط خاصة بهذه الصفحة وحدها.
   المرحلة 3: كانت مكتوبة داخل <style> فى الـ View، تنزل مع كل
   طلب ولا يستطيع المتصفح تخزينها. الآن ملف مستقل قابل للتخزين. */

.quote-pro {
    --q-primary: #1a1a1a;
    --q-accent: #d4a017;
    --q-accent-bright: #f0c75e;
    --q-soft: #faf6ec;
    --q-border: #e8dfc4;
    direction: rtl;
}

/* ===== HERO ===== */
.quote-pro-hero {
    position: relative;
    overflow: hidden;
    background:
        radial-gradient(circle at 12% 20%, rgba(212,160,23,.18), transparent 28%),
        radial-gradient(circle at 88% 80%, rgba(212,160,23,.10), transparent 30%),
        linear-gradient(135deg, #0a0a0a 0%, #1a1a1a 55%, #0a0a0a 100%);
    color: #fff;
    padding: 80px 0 56px;
    text-align: center;
}

.quote-pro-kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 18px;
    border-radius: 999px;
    background: rgba(212,160,23,.12);
    border: 1px solid rgba(212,160,23,.32);
    color: #f4d693;
    font-weight: 800;
    margin-bottom: 18px;
    font-size: .92rem;
}

.quote-pro-hero h1 {
    font-size: clamp(1.9rem, 4vw, 3.2rem);
    font-weight: 900;
    margin-bottom: 14px;
    line-height: 1.2;
}

.quote-pro-hero p {
    max-width: 720px;
    margin: 0 auto;
    color: rgba(255,255,255,.85);
    font-size: 1.05rem;
    line-height: 1.9;
}

/* ===== MAIN ===== */
.quote-pro-main {
    padding: 60px 0 80px;
    background: linear-gradient(180deg, #fff 0%, var(--q-soft) 100%);
}

.quote-pro-grid {
    display: grid;
    grid-template-columns: 1.6fr 1fr;
    gap: 28px;
    align-items: start;
}

/* ===== FORM CARD ===== */
.quote-pro-form-card {
    background: #fff;
    border: 1px solid var(--q-border);
    border-radius: 24px;
    padding: 36px;
    box-shadow: 0 22px 55px rgba(26,26,26,.10);
    position: relative;
    overflow: hidden;
}

    .quote-pro-form-card::before {
        content: "";
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        height: 4px;
        background: linear-gradient(90deg, transparent, var(--q-accent), var(--q-accent-bright), var(--q-accent), transparent);
    }

.quote-pro-form-header {
    margin-bottom: 24px;
    padding-bottom: 20px;
    border-bottom: 1px dashed var(--q-border);
}

    .quote-pro-form-header span {
        display: inline-block;
        color: var(--q-accent);
        font-weight: 800;
        font-size: .85rem;
        letter-spacing: .5px;
        text-transform: uppercase;
        margin-bottom: 6px;
    }

    .quote-pro-form-header h2 {
        color: var(--q-primary);
        font-weight: 900;
        font-size: 1.6rem;
        margin: 0 0 8px;
    }

    .quote-pro-form-header p {
        color: #666;
        margin: 0;
        font-size: .95rem;
        line-height: 1.7;
    }

/* ===== Form rows ===== */
.quote-pro-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
    margin-bottom: 16px;
}

.quote-pro-field {
    margin-bottom: 16px;
}

    .quote-pro-field label {
        display: block;
        font-weight: 800;
        color: var(--q-primary);
        margin-bottom: 8px;
        font-size: .92rem;
    }

        .quote-pro-field label .req {
            color: #d63838;
            margin-right: 4px;
        }

    .quote-pro-field .icon-input {
        position: relative;
    }

        .quote-pro-field .icon-input i {
            position: absolute;
            top: 50%;
            right: 16px;
            transform: translateY(-50%);
            color: var(--q-accent);
            font-size: 1rem;
            pointer-events: none;
            z-index: 2;
        }

    .quote-pro-field .form-control,
    .quote-pro-field textarea.form-control {
        width: 100%;
        padding: 12px 44px 12px 16px;
        border: 1.5px solid var(--q-border);
        border-radius: 12px;
        font-size: .98rem;
        font-family: inherit;
        background: #fdfcf7;
        color: var(--q-primary);
        transition: border-color .2s ease, box-shadow .2s ease, background .2s ease;
    }

    .quote-pro-field textarea.form-control {
        padding: 14px 16px;
        resize: vertical;
        min-height: 120px;
    }

        .quote-pro-field .form-control:focus,
        .quote-pro-field textarea.form-control:focus {
            outline: none;
            background: #fff;
            border-color: var(--q-accent);
            box-shadow: 0 0 0 4px rgba(212,160,23,.12);
        }

        .quote-pro-field .form-control::placeholder {
            color: #b5b1a8;
        }

    .quote-pro-field .field-error {
        display: block;
        color: #d63838;
        font-size: .82rem;
        margin-top: 6px;
        font-weight: 700;
    }

        /* الخانة السليمة لا تحجز مكانًا لرسالةٍ لا توجد: بدون هذا
           يفصل بين حقلين سليمين ضعفُ ما يفصل بين غيرهما، فتبدو
           المسافات عشوائية على الهاتف. */
        .quote-pro-field .field-error:empty {
            display: none;
        }

/* ===== Submit ===== */
.quote-pro-submit-row {
    display: flex;
    gap: 12px;
    align-items: center;
    margin-top: 24px;
    padding-top: 22px;
    border-top: 1px dashed var(--q-border);
    flex-wrap: wrap;
}

.quote-pro-submit {
    background: linear-gradient(135deg, var(--q-accent) 0%, var(--q-accent-bright) 50%, var(--q-accent) 100%);
    background-size: 200% 100%;
    background-position: 0% 0%;
    color: #0a0a0a;
    border: 0;
    border-radius: 999px;
    padding: 14px 32px;
    font-weight: 900;
    font-size: 1rem;
    cursor: pointer;
    box-shadow: 0 10px 22px rgba(212,160,23,.32);
    transition: transform .2s ease, box-shadow .25s ease, background-position .45s ease;
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

    .quote-pro-submit:hover {
        background-position: 100% 0%;
        transform: translateY(-2px);
        box-shadow: 0 14px 30px rgba(212,160,23,.45);
    }

.quote-pro-back {
    color: var(--q-primary);
    font-weight: 700;
    text-decoration: none;
    padding: 12px 18px;
    border-radius: 999px;
    border: 1.5px solid var(--q-border);
    transition: border-color .2s ease, background .2s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

    .quote-pro-back:hover {
        border-color: var(--q-accent);
        background: var(--q-soft);
        color: var(--q-primary);
    }

/* ===== Success Alert ===== */
.quote-pro-success {
    background: linear-gradient(135deg, rgba(212,160,23,.10), rgba(240,199,94,.10));
    border: 1.5px solid rgba(212,160,23,.4);
    border-radius: 16px;
    padding: 18px 22px;
    margin-bottom: 24px;
    display: flex;
    align-items: flex-start;
    gap: 14px;
    color: var(--q-primary);
}

    .quote-pro-success .icon {
        width: 44px;
        height: 44px;
        background: linear-gradient(135deg, #25d366, #1ebe5d);
        color: #fff;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 1.2rem;
        flex-shrink: 0;
        box-shadow: 0 4px 12px rgba(37,211,102,.35);
    }

    .quote-pro-success h4 {
        margin: 0 0 4px;
        font-weight: 900;
        font-size: 1.1rem;
        color: var(--q-primary);
    }

    .quote-pro-success p {
        margin: 0;
        font-size: .95rem;
        line-height: 1.7;
        color: #555;
    }

/* ===== Sidebar ===== */
.quote-pro-sidebar {
    position: sticky;
    top: 100px;
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.quote-pro-side-card {
    background: linear-gradient(135deg, #0a0a0a 0%, #1a1a1a 100%);
    border: 1px solid rgba(212,160,23,.25);
    border-radius: 22px;
    padding: 28px;
    color: #fff;
    position: relative;
    overflow: hidden;
}

    .quote-pro-side-card::before {
        content: "";
        position: absolute;
        inset: 0;
        background: radial-gradient(circle at 80% 0%, rgba(212,160,23,.18), transparent 50%);
        pointer-events: none;
    }

    .quote-pro-side-card > * { position: relative; z-index: 2; }

    .quote-pro-side-card h3 {
        color: #f4d693;
        font-weight: 900;
        font-size: 1.15rem;
        margin: 0 0 16px;
        display: flex;
        align-items: center;
        gap: 10px;
    }

    .quote-pro-side-card h3 i {
        width: 32px;
        height: 32px;
        background: rgba(212,160,23,.18);
        border-radius: 8px;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: .95rem;
        color: var(--q-accent-bright);
    }

.quote-pro-side-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

    .quote-pro-side-list li {
        display: flex;
        align-items: flex-start;
        gap: 12px;
        padding: 12px 0;
        border-bottom: 1px solid rgba(212,160,23,.12);
        color: #e8dfc4;
    }

        .quote-pro-side-list li:last-child { border-bottom: 0; }

        .quote-pro-side-list li > i {
            color: var(--q-accent);
            margin-top: 4px;
            flex-shrink: 0;
            font-size: .95rem;
        }

        .quote-pro-side-list li .label {
            display: block;
            font-size: .75rem;
            color: #8a8265;
            font-weight: 700;
            margin-bottom: 2px;
            letter-spacing: .3px;
        }

        .quote-pro-side-list li .value {
            color: #fff;
            font-weight: 700;
            font-size: .95rem;
            line-height: 1.5;
        }

        .quote-pro-side-list li .value a {
            color: #f0c75e;
            text-decoration: none;
            direction: ltr;
            unicode-bidi: isolate;
            display: inline-block;
        }

            .quote-pro-side-list li .value a:hover { text-decoration: underline; }

.quote-pro-side-actions {
    display: grid;
    gap: 10px;
    margin-top: 18px;
}

.quote-pro-side-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 16px;
    border-radius: 999px;
    font-weight: 800;
    font-size: .92rem;
    text-decoration: none;
    transition: transform .2s ease, box-shadow .2s ease;
}

    .quote-pro-side-btn:hover { transform: translateY(-2px); }

    .quote-pro-side-btn-wa {
        background: linear-gradient(135deg, #25d366, #1ebe5d);
        color: #fff;
        box-shadow: 0 6px 14px rgba(37,211,102,.3);
    }

        .quote-pro-side-btn-wa:hover {
            color: #fff;
            box-shadow: 0 10px 22px rgba(37,211,102,.45);
        }

    .quote-pro-side-btn-tel {
        background: rgba(212,160,23,.15);
        color: #f0c75e;
        border: 1.5px solid rgba(212,160,23,.35);
    }

        .quote-pro-side-btn-tel:hover {
            background: rgba(212,160,23,.25);
            color: #f0c75e;
        }

/* ===== Why us mini card ===== */
.quote-pro-why {
    background: #fff;
    border: 1px solid var(--q-border);
    border-radius: 22px;
    padding: 26px;
    box-shadow: 0 12px 30px rgba(26,26,26,.06);
}

    .quote-pro-why h3 {
        color: var(--q-primary);
        font-weight: 900;
        font-size: 1.05rem;
        margin: 0 0 14px;
        display: flex;
        align-items: center;
        gap: 8px;
    }

        .quote-pro-why h3 i { color: var(--q-accent); }

    .quote-pro-why ul {
        list-style: none;
        padding: 0;
        margin: 0;
        display: flex;
        flex-direction: column;
        gap: 10px;
    }

        .quote-pro-why ul li {
            display: flex;
            align-items: flex-start;
            gap: 10px;
            color: #444956;
            font-size: .92rem;
            line-height: 1.6;
            font-weight: 600;
        }

            .quote-pro-why ul li i {
                color: var(--q-accent);
                margin-top: 4px;
                flex-shrink: 0;
            }

/* ═══════════════════════════════════════════════════════════════
   عناوين مجموعات النموذج
   خطٌّ رفيع يمتدّ بعد الكلمة: يفصل بلا أن يشغل سطرًا كاملًا، فيبقى
   النموذج قصيرًا ويُقرأ قسمين لا سبعة حقول متتابعة.
   ═══════════════════════════════════════════════════════════════ */
.qp-group {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 4px 0 14px;
    font-size: .78rem;
    font-weight: 800;
    letter-spacing: .3px;
    color: var(--q-accent);
    text-transform: none;
}

    .qp-group::after {
        content: "";
        flex: 1;
        height: 1px;
        background: linear-gradient(to left, var(--q-border), transparent);
    }

    /* الأول لا يحتاج فراغًا فوقه: ترويسة البطاقة فوقه مباشرة */
    .qp-group:first-of-type { margin-top: 0; }

    /* والثانى يحتاج: قبله حقلٌ لا ترويسة */
    .qp-group + * { margin-top: 0; }

.quote-pro-field + .qp-group { margin-top: 18px; }

/* ═══════════════════════════════════════════════════════════════
   قائمة المنتج
   السهم مرسوم هنا لا متروكًا للمتصفح: السهم الأصلى يقف يسارًا فى
   الصفحة العربية فيصطدم بالنص، ويختلف شكله بين متصفح وآخر فتبدو
   القائمة غريبةً بين بقية الحقول.
   ═══════════════════════════════════════════════════════════════ */
.quote-pro-field select.form-control {
    appearance: none;
    -webkit-appearance: none;
    padding-left: 42px;
    background-color: #fdfcf7;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23d4a017' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: left 16px center;
    cursor: pointer;
}

.quote-pro-field select.form-control option[value=""] { color: #b5b1a8; }

/* تلميح تحت الحقل — أصغر من رسالة الخطأ وأهدأ لونًا */
.qp-hint {
    display: block;
    margin-top: 6px;
    font-size: .78rem;
    color: #8c8578;
}

/* ═══════════════════════════════════════════════════════════════
   اقتراح الدولة
   ═══════════════════════════════════════════════════════════════ */
.qp-combo { position: relative; }

.qp-combo__list {
    position: absolute;
    z-index: 30;
    top: calc(100% - 22px);
    inset-inline: 0;
    margin: 6px 0 0;
    padding: 6px;
    list-style: none;
    background: #fff;
    border: 1.5px solid var(--q-border);
    border-radius: 12px;
    box-shadow: 0 12px 32px rgba(0,0,0,.14);
    max-height: 260px;
    overflow-y: auto;
}

    .qp-combo__list li {
        display: flex;
        align-items: baseline;
        justify-content: space-between;
        gap: 10px;
        padding: 10px 12px;
        border-radius: 8px;
        cursor: pointer;
        font-size: .95rem;
        color: var(--q-primary);
    }

        .qp-combo__list li:hover,
        .qp-combo__list li.is-active {
            background: rgba(212,160,23,.14);
        }

/* خانة المحافظة قبل اختيار الدولة: مطفأةٌ لا مخفيّة — الزائر يرى
   أن لها مكانًا ويعرف لِمَ لا تعمل من التلميح تحتها. */
.qp-combo.is-locked .form-control {
    background: #f4f2ec;
    color: #a8a298;
    cursor: not-allowed;
}

.qp-combo.is-locked .icon-input i { opacity: .45; }

.qp-combo__name { font-weight: 700; }

/* الاسم الآخر باهتٌ بجانبه: يطمئن من كتب بالإنجليزية أنه وجد بلده،
   ولا يزاحم الاسم الذى سيُكتب فى الخانة. */
.qp-combo__alt {
    font-size: .8rem;
    color: #9a948a;
    direction: ltr;
}

/* ═══════════════════════════════════════════════════════════════
   الخانة الناقصة: رسالةٌ، ثم خطٌّ يلفّها ويختفى
   ═══════════════════════════════════════════════════════════════ */
.qp-summary {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 18px;
    padding: 14px 16px;
    border-radius: 12px;
    background: rgba(214,56,56,.08);
    border: 1.5px solid rgba(214,56,56,.35);
    color: #b62828;
    font-weight: 800;
    font-size: .95rem;
}

    .qp-summary::before {
        content: "\f06a";                 /* دائرة تعجّب — Font Awesome */
        font-family: "Font Awesome 6 Free", "Font Awesome 5 Free";
        font-weight: 900;
        flex: 0 0 auto;
    }

.quote-pro-field.is-invalid .form-control,
.quote-pro-field.is-invalid textarea.form-control {
    border-color: #d63838;
    background: #fff8f8;
}

.quote-pro-field.is-invalid label { color: #b62828; }

/* الخطّ يلفّ الخانة مرتين ثم يذوب. حلقةٌ خارجية لا حدٌّ للحقل:
   الحدّ يزحزح ما حوله بكسلًا فتهتزّ الصفحة، والظلّ لا يزحزح شيئًا. */
.qp-ring {
    border-radius: 14px;
    animation: qpRing 1.6s ease-out 1;
}

@keyframes qpRing {
    0%   { box-shadow: 0 0 0 0 rgba(214,56,56,.55); }
    35%  { box-shadow: 0 0 0 7px rgba(214,56,56,.16); }
    70%  { box-shadow: 0 0 0 3px rgba(214,56,56,.34); }
    100% { box-shadow: 0 0 0 10px rgba(214,56,56,0); }
}

/* من طلب تقليل الحركة يرى لونًا ثابتًا لا نبضًا */
@media (prefers-reduced-motion: reduce) {
    .qp-ring { animation: none; box-shadow: 0 0 0 3px rgba(214,56,56,.45); }
}

/* ===== Responsive ===== */
@media (max-width: 991px) {
    .quote-pro-grid { grid-template-columns: 1fr; }
    .quote-pro-sidebar { position: static; }
    .quote-pro-form-card { padding: 28px; }
}

/* اللوح والهاتف الكبير: عمودان فى عرضٍ كهذا يضغطان الحقل حتى يختفى
   نصفُ ما فيه تحت أيقونته. عمودٌ واحد أوضح. */
@media (max-width: 767px) {
    .quote-pro-row { grid-template-columns: 1fr; gap: 0; }
}

@media (max-width: 575px) {
    /* الهيرو كان يأكل ثلث الشاشة الأولى قبل أن يرى الزائر حقلًا
       واحدًا، وهو جاء ليملأ النموذج لا ليقرأ. */
    .quote-pro-hero { padding: 40px 0 30px; }
    .quote-pro-hero h1 { font-size: 1.55rem; text-wrap: balance; }
    .quote-pro-hero p { font-size: .9rem; }
    .quote-pro-main { padding-top: 28px; }
    .quote-pro-main { padding: 44px 0 60px; }
    .quote-pro-form-card { padding: 20px; }
    .quote-pro-form-header h2 { font-size: 1.3rem; }
    .quote-pro-row { grid-template-columns: 1fr; gap: 0; }
    .quote-pro-side-card,
    .quote-pro-why { padding: 20px; }
    .quote-pro-submit-row { flex-direction: column-reverse; align-items: stretch; }
    .quote-pro-submit { width: 100%; justify-content: center; }
    .quote-pro-back { width: 100%; justify-content: center; }

    /* ١٦ بكسل لا أقل: سفارى على الأيفون يكبّر الصفحة تلقائيًا عند
       التركيز على حقلٍ خطُّه أصغر، فتخرج بقية النموذج خارج الشاشة
       ويضيع الزائر. ليست زينةً بل سببُ أكثر شكاوى النماذج على الهاتف. */
    .quote-pro-field .form-control,
    .quote-pro-field textarea.form-control,
    .quote-pro-field select.form-control {
        font-size: 16px;
        padding-top: 13px;
        padding-bottom: 13px;
    }

    /* ═══ تقريب الخانات ═══
       على الهاتف تصير الخانات عمودًا واحدًا، فيجتمع هامشُ الصفّ
       (16) وهامشُ الخانة (16) بين كل حقلين — اثنان وثلاثون بكسلًا
       من الفراغ تجعل النموذج يبدو مبعثرًا ويطول بلا داعٍ.
       الصفّ يفقد هامشه، والخانة تُضيّقه. */
    .quote-pro-row { margin-bottom: 0; }
    .quote-pro-field { margin-bottom: 12px; }
    .quote-pro-field label { margin-bottom: 5px; font-size: .88rem; }
    .qp-hint { margin-top: 4px; font-size: .74rem; }
    .quote-pro-field .field-error { margin-top: 4px; }

    /* الإصبع لا المؤشّر: صفٌّ أطول يسهل إصابته */
    .qp-combo__list li { padding: 13px 12px; }

    /* الاسم الآخر يُطوى تحت الأصلى بدل أن يزاحمه فى عرضٍ ضيّق */
    .qp-combo__list li {
        flex-direction: column;
        align-items: flex-start;
        gap: 2px;
    }

    .quote-pro-field textarea.form-control {
        min-height: 104px;

        /* مقبض التكبير لا يُسحب بإصبع، ويظهر نقطةً غريبة فى الركن.
           والمربّع يكبر وحده مع النصّ على الهاتف. */
        resize: none;
    }
}
