/* ==========================================================================
   التنسيقات العامة لحاوية الأداة
   ========================================================================== */
#eye-engraving-wrapper {
    background-color: #ffffff;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
    padding: 30px;
    border-radius: 12px;
    border: 1px solid #eaeaea;
    max-width: 600px;
    margin: 20px auto;
    font-family: inherit; /* يأخذ خط قالب ووردبريس الخاص بك تلقائياً */
    direction: rtl;
}

#eye-engraving-wrapper h3 {
    text-align: center;
    color: #2c3e50;
    margin-bottom: 25px;
    font-size: 1.4em;
    font-weight: bold;
}

/* ==========================================================================
   تنسيق حقل رفع الصورة
   ========================================================================== */
#imageUpload {
    display: block;
    width: 100%;
    max-width: 350px;
    margin: 0 auto 10px auto;
    padding: 12px;
    border: 2px dashed #cbd5e1;
    border-radius: 8px;
    background-color: #f8fafc;
    color: #64748b;
    cursor: pointer;
    transition: all 0.3s ease;
}

#imageUpload:hover {
    border-color: #94a3b8;
    background-color: #f1f5f9;
}

/* تنسيق الزر الداخلي لرفع الملفات (يعمل في أغلب المتصفحات الحديثة) */
#imageUpload::file-selector-button {
    background-color: #2c3e50;
    color: #ffffff;
    border: none;
    padding: 8px 20px;
    border-radius: 6px;
    cursor: pointer;
    margin-inline-end: 15px;
    font-family: inherit;
    transition: background 0.3s;
}

#imageUpload::file-selector-button:hover {
    background-color: #1a252f;
}

/* ==========================================================================
   تنسيق منطقة التحكم (أشرطة القياسات)
   ========================================================================== */
#eye-engraving-wrapper .controls {
    background: #f8f9fa;
    padding: 25px 20px;
    border-radius: 10px;
    margin-bottom: 25px;
    border: 1px solid #edf2f7;
}

#eye-engraving-wrapper .controls label {
    font-weight: 600;
    color: #334155;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    font-size: 0.95em;
}

/* تنسيق الأرقام التي تتغير عند تحريك السلايدر */
#eye-engraving-wrapper .controls span {
    color: #b8860b; /* لون ذهبي داكن */
    font-weight: bold;
    background: #ffffff;
    padding: 4px 12px;
    border-radius: 6px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

/* ==========================================================================
   تنسيق أشرطة التمرير (Sliders)
   ========================================================================== */
#eye-engraving-wrapper input[type=range] {
    -webkit-appearance: none;
    width: 100%;
    background: transparent;
    margin-bottom: 15px;
}

/* مسار السلايدر */
#eye-engraving-wrapper input[type=range]::-webkit-slider-runnable-track {
    width: 100%;
    height: 8px;
    cursor: pointer;
    background: #e2e8f0;
    border-radius: 4px;
}

/* زر السلايدر الدائري */
#eye-engraving-wrapper input[type=range]::-webkit-slider-thumb {
    -webkit-appearance: none;
    height: 22px;
    width: 22px;
    border-radius: 50%;
    background: #d4af37; /* لون ذهبي */
    cursor: pointer;
    margin-top: -7px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
    transition: transform 0.1s;
}

#eye-engraving-wrapper input[type=range]::-webkit-slider-thumb:hover {
    transform: scale(1.1);
}

#eye-engraving-wrapper input[type=range]:focus {
    outline: none;
}

/* ==========================================================================
   تنسيق منطقة عرض الصورة (الكانفاس)
   ========================================================================== */
#eye-engraving-wrapper canvas {
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    background-color: #e2e8f0; /* لون خلفية في حال كانت الصورة شفافة */
    display: block;
    margin: 0 auto;
}
/* تنسيق الزر عندما يكون غير مفعل */
#downloadBtn:disabled {
    background-color: #94a3b8 !important;
    cursor: not-allowed !important;
    opacity: 0.6;
    box-shadow: none !important;
}

#downloadBtn:not(:disabled):hover {
    background-color: #1a252f !important;
}