/* ==========================================================================
   Mawzena — طبقة تحسين الواجهة (أيقونات + ألوان الأزرار + تلميحات)
   تُطبَّق على كل الصفحات مع mawzena-ui-enhance.js. آمنة وقابلة للإلغاء:
   احذف رابطَي هذا الملف والـ JS من head-assets.php للرجوع للأصل.
   ========================================================================== */

/* ---------- أيقونة داخل الزر (يُحقن نصها عبر JS في .mw-bi) ---------- */
.mw-bi {
    font-size: 1.05em;
    line-height: 1;
    display: inline-flex;
    margin-inline-end: 6px;
    vertical-align: -1px;
}

/* ---------- أزرار الإلغاء والحذف: نص وأيقونة حمراء ---------- */
.main-content .modal-cancel,
.main-content .modal-btn.modal-cancel,
.mw-btn-cancel,
.mw-btn-delete {
    background: rgba(225, 29, 72, .08) !important;
    color: #e11d48 !important;
    border: 1px solid rgba(225, 29, 72, .22) !important;
}
.main-content .modal-cancel:hover,
.mw-btn-cancel:hover,
.mw-btn-delete:hover {
    background: rgba(225, 29, 72, .14) !important;
}

/* ---------- أزرار التعديل/الحذف كأيقونة دائرية مع تلميح ---------- */
.mw-iconbtn {
    position: relative;
    width: 40px;
    height: 40px;
    min-height: 40px;
    padding: 0 !important;
    border-radius: 12px !important;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    line-height: 1;
    border: 1px solid #e8e6dd !important;
    background: #fff !important;
    cursor: pointer;
    text-decoration: none !important;
    transition: transform .1s ease, background .15s ease, border-color .15s ease;
}
.mw-iconbtn:hover { transform: translateY(-1px); }
.mw-iconbtn.mw-edit:hover { background: rgba(15, 118, 110, .08) !important; border-color: rgba(15, 118, 110, .32) !important; }
.mw-iconbtn.mw-delete { color: #e11d48; }
.mw-iconbtn.mw-delete:hover { background: rgba(225, 29, 72, .08) !important; border-color: rgba(225, 29, 72, .32) !important; }

/* التلميح */
.mw-iconbtn[data-tip]::after {
    content: attr(data-tip);
    position: absolute;
    bottom: calc(100% + 8px);
    inset-inline-start: 50%;
    transform: translateX(50%) scale(.9);
    background: #1f2937;
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    padding: 5px 9px;
    border-radius: 8px;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity .15s ease, transform .15s ease;
    z-index: 50;
}
.mw-iconbtn[data-tip]:hover::after {
    opacity: 1;
    transform: translateX(50%) scale(1);
}

/* ---------- أيقونة داخل الحقل (غلاف طبقتنا الخاص) ---------- */
.mw-field {
    position: relative;
    display: block;
}
.mw-field > .mw-fi {
    position: absolute;
    inset-inline-start: 13px;
    top: 21px;
    font-size: 16px;
    opacity: .7;
    pointer-events: none;
    z-index: 2;
}
.mw-field.mw-field-ta > .mw-fi { top: 16px; }
.mw-field > input,
.mw-field > select,
.mw-field > textarea {
    padding-inline-start: 42px !important;
}