@charset "UTF-8";

/* مدينة الصفر v2 — واجهة محافظة على تخطيط المحرك القديم */
:root{--cz-bg:#f4f1e8;--cz-card:#fff;--cz-ink:#1d241f;--cz-muted:#767b73;--cz-green:#20392d;--cz-green2:#2f5140;--cz-gold:#c9a64b;--cz-line:#e1ded3;--cz-red:#a63d32}
html,body{background:var(--cz-bg)!important;color:var(--cz-ink);font-family:Tahoma,Arial,sans-serif}
body{direction:ltr}
.wrapper{background:#f4f1e8!important}
#dynamic_header{height:100px!important;background:linear-gradient(180deg,#dcebd8 0,#edf2e4 100%)!important;border-bottom:1px solid #ccd3c6;position:relative}
#dynamic_header:after{content:"مدينة الصفر";position:absolute;left:50%;top:25px;transform:translateX(-50%);font-size:30px;font-weight:700;color:var(--cz-green);letter-spacing:0}

/* Top navigation: keep original IDs so scripts continue working */
#header.cz-header{height:72px!important;background:var(--cz-green)!important;border-bottom:3px solid var(--cz-gold);box-shadow:0 4px 14px rgba(0,0,0,.14)}
#mtop.cz-topnav{height:72px!important;width:760px!important;margin-left:-380px!important;display:flex!important;align-items:center;justify-content:center;gap:4px;direction:rtl;font-size:14px!important}
#mtop.cz-topnav>a,#mtop.cz-topnav>#n5>a{float:none!important;display:flex!important;align-items:center;justify-content:center;height:44px!important;min-width:94px;padding:0 13px!important;margin:0!important;border-radius:9px;color:#fff!important;text-decoration:none!important;font-weight:700;box-sizing:border-box;background:transparent!important}
#mtop.cz-topnav>a:hover,#mtop.cz-topnav>#n5>a:hover{background:rgba(255,255,255,.10)!important;color:#fff!important}
#mtop.cz-topnav>a span,#mtop.cz-topnav>#n5>a span{display:inline!important;white-space:nowrap}
#mtop.cz-topnav>a>img,#mtop.cz-topnav>#n5>a>img{display:none!important;background-image:none!important;width:0!important;height:0!important}
#mtop.cz-topnav #n5{float:none!important;display:flex!important;height:44px!important;background:none!important;width:auto!important}
#mtop.cz-topnav #n5 a{min-width:86px}
#mtop.cz-topnav #plus{min-width:76px!important;border:1px solid rgba(201,166,75,.75);color:#f1d36e!important}
#mtop.cz-topnav #plus .cz-plus-label{display:inline!important}
#mtop.cz-topnav #plus #btn_plus{display:none!important}

/* Preserve the 3-column engine layout, modernize surfaces only */
#mid{width:980px!important;margin:0 auto!important;padding-top:30px}
#side_navi.cz-side-menu{float:left!important;width:155px!important;min-height:430px!important;margin-top:30px!important;padding:0 12px 14px!important;box-sizing:border-box;background:transparent!important;direction:rtl;text-align:right}
.cz-brand-small{background:var(--cz-card);border:1px solid var(--cz-line);border-radius:13px;padding:12px 10px;margin:0 0 12px;display:flex;align-items:center;gap:8px;box-shadow:0 4px 14px rgba(31,45,36,.07)}
.cz-brand-small .cz-brand-mark{width:34px;height:34px;border-radius:10px;background:var(--cz-gold);color:#1e281f;display:flex;align-items:center;justify-content:center;font-size:22px;font-weight:bold;flex:0 0 34px}
.cz-brand-small strong{display:block;font-size:12px;color:var(--cz-green)}
.cz-brand-small small{display:block;color:var(--cz-muted);font-size:10px;margin-top:3px}
#side_navi.cz-side-menu p{margin:0 0 12px!important;line-height:normal!important;background:var(--cz-card);border:1px solid var(--cz-line);border-radius:12px;padding:7px!important;box-shadow:0 3px 12px rgba(31,45,36,.045)}
#side_navi.cz-side-menu p a{display:block!important;padding:8px 9px!important;border-radius:8px;color:#27362d!important;text-decoration:none;font-size:12px}
#side_navi.cz-side-menu p a:hover{background:#edf1e9!important;color:var(--cz-green)!important}
#side_navi.cz-side-menu .cz-logout a{color:var(--cz-red)!important;font-weight:bold}

/* Main old content keeps exact width/position. Only make it feel like a card. */
#content.village1{background:var(--cz-card)!important;border:1px solid var(--cz-line);border-radius:16px;box-shadow:0 8px 28px rgba(31,45,36,.08);padding-top:12px!important;min-height:520px!important;overflow:visible}
#content.village1 h1{font-family:Tahoma,Arial,sans-serif!important;color:var(--cz-green)!important;font-size:25px!important;border-bottom:1px solid #eeeae0;padding-bottom:9px;margin-bottom:4px}
#content.village1 #cap{font-family:Tahoma,Arial,sans-serif!important}
#content.village1 #map_details{direction:rtl;text-align:right}
#content.village1 table{font-family:Tahoma,Arial,sans-serif}
#content.village1 table th,#content.village1 table td{text-align:right}

/* Resource bar: preserve its absolute engine coordinates */
#res{background:rgba(255,255,255,.94)!important;border-top:1px solid #ddd9cd;border-bottom:1px solid #ddd9cd;box-shadow:0 3px 10px rgba(0,0,0,.05)}
#resWrap{font-family:Tahoma,Arial,sans-serif}
#res table td{font-weight:700;color:#303b34}

/* Side info stays where engine expects it */
#side_info{background:transparent!important}
#side_info>div,#side_info table{font-family:Tahoma,Arial,sans-serif}
#qge img{border-radius:14px;box-shadow:0 5px 16px rgba(31,45,36,.12)}

/* Footer/time */
#ltimeWrap{font-family:Tahoma,Arial,sans-serif!important;color:#667168!important;text-align:right;direction:rtl}
#footer{background:#e9e7df!important;border-top:1px solid #d8d5cb}

/* Arabic text, without flipping map/image coordinates */
#side_navi,#map_details,#side_info{direction:rtl}
#village_map{direction:ltr!important}

/* Make common English leftovers less visually awkward */
#map_details .none{direction:rtl}

@media (max-width:1050px){
  #mid{width:940px!important}
  #mtop.cz-topnav{width:720px!important;margin-left:-360px!important}
}


/* =========================================================
   مدينة الصفر v3 — مدير المهام
   ========================================================= */

#mid{
    position:relative!important;
}

/* لوحة منفصلة على يمين الصفحة حتى لا تدفع المحتوى للأسفل */
#side_info.cz-task-panel{
    position:absolute!important;
    float:none!important;
    right:0!important;
    left:auto!important;
    top:30px!important;
    width:155px!important;
    min-height:0!important;
    margin:0!important;
    padding:0!important;
    background:transparent!important;
    direction:rtl!important;
    text-align:right!important;
    z-index:20!important;
}

#side_info.cz-task-panel #qge{
    position:static!important;
    width:100%!important;
    height:auto!important;
    padding:0!important;
    margin:0!important;
    background:none!important;
}

/* العنصر المخفي المطلوب لمحرك نافذة المهام */
#side_info.cz-task-panel #anm{
    position:absolute!important;
    z-index:1000!important;
    border:0!important;
    right:0;
    top:0;
}

/* زر المهام الجديد */
.cz-task-button{
    width:100%;
    min-height:82px;
    display:flex;
    align-items:center;
    gap:9px;
    position:relative;
    box-sizing:border-box;
    padding:12px 10px;
    border:1px solid var(--cz-line);
    border-radius:14px;
    background:var(--cz-card);
    color:var(--cz-green);
    font-family:Tahoma,Arial,sans-serif;
    text-align:right;
    cursor:pointer;
    box-shadow:0 5px 18px rgba(31,45,36,.08);
    transition:transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}

.cz-task-button:hover{
    transform:translateY(-1px);
    border-color:#c9b36e;
    box-shadow:0 8px 22px rgba(31,45,36,.13);
}

.cz-task-icon{
    width:38px;
    height:38px;
    border-radius:11px;
    flex:0 0 38px;
    display:flex;
    align-items:center;
    justify-content:center;
    background:var(--cz-gold);
    color:#203126;
    font-size:22px;
    font-weight:700;
}

.cz-task-copy{
    min-width:0;
    display:block;
    line-height:1.35;
}

.cz-task-copy strong{
    display:block;
    font-size:13px;
    color:var(--cz-green);
}

.cz-task-copy small{
    display:block;
    margin-top:4px;
    font-size:10px;
    color:var(--cz-muted);
    white-space:nowrap;
}

.cz-task-badge{
    position:absolute;
    top:-7px;
    left:-6px;
    padding:3px 6px;
    border-radius:10px;
    background:var(--cz-red);
    color:#fff;
    font-size:9px;
    font-weight:700;
}

/* نافذة المهام القديمة تبقى فوق كل عناصر الواجهة */
div.popup3.quest{
    z-index:5000!important;
}

@media (max-width:1050px){
    #side_info.cz-task-panel{
        right:4px!important;
        width:145px!important;
    }
}


/* =========================================================
   مدينة الصفر — المرحلة الثانية v6
   تحسين الصفحات العامة فقط
   لا تعديل على المباني أو القوات
   ========================================================= */

/* الألوان المشتركة */
:root{
    --cz-soft:#f8f6f0;
    --cz-soft2:#eef2ec;
    --cz-border:#ddd8cc;
    --cz-shadow:0 8px 24px rgba(31,45,36,.08);
}

/* المحتوى العام */
#content{
    font-family:Tahoma,Arial,sans-serif!important;
}

/* بطاقات الصفحات النصية */
#content.reports,
#content.messages,
#content.statistics,
#content.profile,
#content.alliance,
#content.map{
    background:var(--cz-card)!important;
    border:1px solid var(--cz-line)!important;
    border-radius:16px!important;
    box-shadow:var(--cz-shadow)!important;
    box-sizing:border-box!important;
}

/* عناوين الصفحات */
#content.reports h1,
#content.messages h1,
#content.statistics h1,
#content.profile h1,
#content.alliance h1,
#content.map h1{
    font-size:24px!important;
    color:var(--cz-green)!important;
    border-bottom:1px solid #ece7dc!important;
    padding-bottom:10px!important;
    margin-bottom:12px!important;
    font-family:Tahoma,Arial,sans-serif!important;
}

/* القوائم النصية العليا */
#textmenu{
    direction:rtl!important;
    text-align:right!important;
    line-height:2!important;
}
#textmenu a{
    display:inline-block!important;
    padding:5px 9px!important;
    margin:2px!important;
    border-radius:8px!important;
    color:var(--cz-green)!important;
    text-decoration:none!important;
    font-family:Tahoma,Arial,sans-serif!important;
}
#textmenu a:hover,
#textmenu a.selected{
    background:var(--cz-soft2)!important;
    color:#17392b!important;
}

/* الجداول العامة */
#content.reports table,
#content.messages table,
#content.statistics table,
#content.profile table,
#content.alliance table{
    width:100%!important;
    border-collapse:separate!important;
    border-spacing:0!important;
    border:1px solid var(--cz-border)!important;
    border-radius:10px!important;
    overflow:hidden!important;
    background:#fff!important;
}

#content.reports th,
#content.messages th,
#content.statistics th,
#content.profile th,
#content.alliance th{
    background:var(--cz-soft2)!important;
    color:var(--cz-green)!important;
    font-weight:700!important;
    font-family:Tahoma,Arial,sans-serif!important;
}

#content.reports td,
#content.messages td,
#content.statistics td,
#content.profile td,
#content.alliance td{
    background:#fff!important;
    border-color:#ebe6da!important;
    font-family:Tahoma,Arial,sans-serif!important;
}

#content.reports tr:hover td,
#content.messages tr:hover td,
#content.statistics tr:hover td,
#content.profile tr:hover td,
#content.alliance tr:hover td{
    background:#fbfaf6!important;
}

/* الرسائل */
#content.messages{
    direction:rtl!important;
    text-align:right!important;
}
#content.messages textarea{
    width:100%!important;
    min-height:160px!important;
    resize:vertical!important;
    border:1px solid var(--cz-border)!important;
    border-radius:10px!important;
    background:#fff!important;
    padding:10px!important;
    font-family:Tahoma,Arial,sans-serif!important;
    box-sizing:border-box!important;
}
#content.messages input[type="text"]{
    border:1px solid var(--cz-border)!important;
    border-radius:8px!important;
    padding:7px 9px!important;
    background:#fff!important;
    font-family:Tahoma,Arial,sans-serif!important;
}

/* التقارير */
#content.reports{
    direction:rtl!important;
    text-align:right!important;
}
#content.reports a{
    color:#365f49!important;
}

/* الإحصائيات */
#content.statistics{
    direction:rtl!important;
    text-align:right!important;
}
#content.statistics input[type="text"]{
    border:1px solid var(--cz-border)!important;
    border-radius:7px!important;
    padding:5px 8px!important;
}

/* الأزرار العامة داخل الصفحات النصية */
#content.reports input[type="submit"],
#content.messages input[type="submit"],
#content.statistics input[type="submit"],
#content.profile input[type="submit"],
#content.alliance input[type="submit"],
#content.reports button,
#content.messages button,
#content.statistics button,
#content.profile button,
#content.alliance button{
    border:1px solid #b99b4b!important;
    border-radius:8px!important;
    background:#fffaf0!important;
    color:var(--cz-green)!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-weight:700!important;
    padding:6px 12px!important;
    cursor:pointer!important;
    transition:.15s ease!important;
}
#content.reports input[type="submit"]:hover,
#content.messages input[type="submit"]:hover,
#content.statistics input[type="submit"]:hover,
#content.profile input[type="submit"]:hover,
#content.alliance input[type="submit"]:hover,
#content.reports button:hover,
#content.messages button:hover,
#content.statistics button:hover,
#content.profile button:hover,
#content.alliance button:hover{
    transform:translateY(-1px)!important;
    box-shadow:0 4px 12px rgba(31,45,36,.10)!important;
}

/* الملف الشخصي */
#content.profile{
    direction:rtl!important;
    text-align:right!important;
}
#content.profile input[type="text"],
#content.profile textarea,
#content.profile select{
    border:1px solid var(--cz-border)!important;
    border-radius:8px!important;
    background:#fff!important;
    font-family:Tahoma,Arial,sans-serif!important;
    padding:6px 8px!important;
}

/* التحالف */
#content.alliance{
    direction:rtl!important;
    text-align:right!important;
}
#content.alliance a{
    color:#345c47!important;
    text-decoration:none!important;
}
#content.alliance a:hover{
    text-decoration:underline!important;
}

/* الخريطة: تحسين الإطار فقط، بدون تغيير شبكة الخريطة أو إحداثياتها */
#content.map{
    background:#fff!important;
    border:1px solid var(--cz-line)!important;
    border-radius:16px!important;
    box-shadow:var(--cz-shadow)!important;
}
#map,
#map_container,
#map_details,
#village_map{
    font-family:Tahoma,Arial,sans-serif!important;
}
#map_details{
    direction:rtl!important;
    text-align:right!important;
}

/* تنبيه/صندوق معلومات عام */
.notice,
.error,
.success,
.warning{
    border-radius:9px!important;
    font-family:Tahoma,Arial,sans-serif!important;
}

/* شريط التمرير الأفقي للجداول على الشاشات الصغيرة */
@media (max-width:760px){
    #content.reports,
    #content.messages,
    #content.statistics,
    #content.profile,
    #content.alliance{
        overflow-x:auto!important;
    }

    #content.reports table,
    #content.messages table,
    #content.statistics table,
    #content.profile table,
    #content.alliance table{
        min-width:560px!important;
    }
}

/* مهم:
   لا توجد أي selectors خاصة بـ:
   build.php
   building
   troops
   barracks
   academy
   smithy
   stables
   لذلك المباني والقوات تبقى كما هي.
*/


/* =========================================================
   مدينة الصفر v6.1 — تأكيد تطبيق الهوية على كل الصفحات
   ========================================================= */

#content.messages,
#content.reports,
#content.statistics{
    padding:20px!important;
    min-height:430px!important;
}

#content.messages h1,
#content.reports h1,
#content.statistics h1{
    margin:0 0 14px!important;
    padding:0 0 12px!important;
    font-size:26px!important;
    border-bottom:2px solid var(--cz-gold)!important;
}

#content.messages table,
#content.reports table,
#content.statistics table{
    box-shadow:0 3px 12px rgba(31,45,36,.05)!important;
}

#content.messages table th,
#content.reports table th,
#content.statistics table th{
    height:34px!important;
    background:#20392d!important;
    color:#fff!important;
    text-align:right!important;
}

#content.messages table td,
#content.reports table td,
#content.statistics table td{
    padding-top:8px!important;
    padding-bottom:8px!important;
}

#content.messages a,
#content.reports a,
#content.statistics a{
    font-family:Tahoma,Arial,sans-serif!important;
}

#content.messages #textmenu,
#content.reports #textmenu,
#content.statistics #textmenu{
    margin-bottom:16px!important;
    padding:7px!important;
    background:#f4f1e8!important;
    border:1px solid #e1ded3!important;
    border-radius:10px!important;
}



/* =========================================================
   مدينة الصفر v6.2 — تعريب التقارير والرسائل
   ========================================================= */

#content.reports,
#content.messages{
    direction:rtl!important;
    text-align:right!important;
}

#content.reports h1,
#content.messages h1{
    text-align:right!important;
}

#content.reports #overview,
#content.messages #overview{
    direction:rtl!important;
}

#content.reports #overview th,
#content.reports #overview td,
#content.messages #overview th,
#content.messages #overview td{
    text-align:right!important;
}

#content.reports td.dat,
#content.messages td.dat{
    direction:ltr!important;
    text-align:center!important;
    white-space:nowrap!important;
}

#content.reports td.sel,
#content.messages td.sel{
    width:28px!important;
    text-align:center!important;
}

#content.reports td.none,
#content.messages td.none{
    text-align:center!important;
    padding:24px 10px!important;
    color:#7a817b!important;
    background:#faf9f5!important;
}

.cz-new-tag,
.cz-unread-tag{
    display:inline-block;
    margin-right:6px;
    padding:2px 6px;
    border-radius:8px;
    font-size:9px;
    line-height:1.4;
    font-family:Tahoma,Arial,sans-serif;
}

.cz-new-tag{
    background:#e7f4e8;
    color:#2c7041;
    border:1px solid #cce6d0;
}

.cz-unread-tag{
    background:#fff4d6;
    color:#856613;
    border:1px solid #ead9a2;
}

/* نافذة قراءة الرسالة */
#content.messages .msg_content{
    direction:rtl!important;
    text-align:right!important;
    background:#fff!important;
    border:1px solid var(--cz-line)!important;
    border-radius:12px!important;
    box-shadow:0 5px 18px rgba(31,45,36,.06)!important;
}

#content.messages .msg_content #heading{
    direction:rtl!important;
    text-align:right!important;
}

#content.messages .msg_content .message{
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:13px!important;
    line-height:1.9!important;
    color:#27352d!important;
    text-align:right!important;
}

/* أزرار الصور القديمة: نخليها أوضح مع tooltip عربي */
#content.reports .buttons input[type="image"],
#content.messages .buttons input[type="image"],
#content.messages input[type="image"]{
    border-radius:7px!important;
    filter:none!important;
}

/* روابط مواضيع الرسائل والتقارير */
#content.reports td.sub a,
#content.messages td.top a,
#content.messages td.send a{
    color:#244f39!important;
    font-weight:700!important;
    text-decoration:none!important;
}

#content.reports td.sub a:hover,
#content.messages td.top a:hover,
#content.messages td.send a:hover{
    text-decoration:underline!important;
}



/* =========================================================
   مدينة الصفر v6.3 — الرسائل العربية الكاملة
   ========================================================= */

#content.messages{
    font-size:13px!important;
}

#content.messages #textmenu{
    display:flex!important;
    flex-wrap:wrap!important;
    gap:6px!important;
    justify-content:flex-start!important;
    align-items:center!important;
    direction:rtl!important;
}

#content.messages #textmenu > a{
    margin:0!important;
    padding:8px 12px!important;
    border:1px solid transparent!important;
    background:#fff!important;
}

#content.messages #textmenu > a.selected{
    border-color:#d9cfac!important;
    background:#fffaf0!important;
    color:#17392b!important;
    box-shadow:0 2px 8px rgba(31,45,36,.06)!important;
}

/* أزرار الصور القديمة تبقى وظيفياً كما هي، والنص العربي يظهر بجانبها */
.cz-img-action{
    display:inline-flex!important;
    align-items:center!important;
    gap:4px!important;
    margin:2px 4px!important;
    padding:3px 8px!important;
    min-height:26px!important;
    border:1px solid #cbb56f!important;
    border-radius:8px!important;
    background:#fffaf0!important;
    color:#2c4939!important;
    vertical-align:middle!important;
    cursor:pointer!important;
}

.cz-img-action input[type="image"]{
    margin:0!important;
    vertical-align:middle!important;
}

.cz-img-action b{
    font-size:11px!important;
    font-family:Tahoma,Arial,sans-serif!important;
    pointer-events:none!important;
}

.cz-reply-action{
    float:right!important;
}

/* كتابة الرسالة */
#content.messages #write_content{
    direction:rtl!important;
    text-align:right!important;
}

#content.messages #write_content #heading{
    direction:rtl!important;
    text-align:right!important;
}

#content.messages #write_content input.text{
    width:330px!important;
    max-width:90%!important;
    padding:8px 10px!important;
    margin:4px 0!important;
    border:1px solid #d7d2c6!important;
    border-radius:8px!important;
    font-family:Tahoma,Arial,sans-serif!important;
}

#content.messages #message_container{
    direction:rtl!important;
}

#content.messages #message{
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:13px!important;
    line-height:1.8!important;
}

/* الملاحظات */
#content.messages #notice{
    width:100%!important;
    min-height:260px!important;
    box-sizing:border-box!important;
    padding:12px!important;
    border:1px solid #d7d2c6!important;
    border-radius:10px!important;
    font-family:Tahoma,Arial,sans-serif!important;
    line-height:1.8!important;
}



/* =========================================================
   مدينة الصفر v6.4 — صفحة قراءة الرسالة الحديثة
   ========================================================= */

#content.messages.cz-message-read{
    direction:rtl!important;
    text-align:right!important;
}

.cz-read-card{
    background:#fff!important;
    border:1px solid var(--cz-line)!important;
    border-radius:14px!important;
    box-shadow:0 7px 22px rgba(31,45,36,.07)!important;
    overflow:hidden!important;
    margin-top:14px!important;
}

.cz-read-meta{
    position:relative!important;
    padding:16px 18px!important;
    padding-left:130px!important;
    background:#f8f6f0!important;
}

.cz-read-meta-row{
    display:flex!important;
    align-items:center!important;
    gap:12px!important;
    min-height:30px!important;
    font-family:Tahoma,Arial,sans-serif!important;
}

.cz-read-label{
    min-width:62px!important;
    color:#7a817b!important;
    font-size:11px!important;
}

.cz-read-meta-row strong{
    color:#20392d!important;
    font-size:13px!important;
}

.cz-read-date{
    position:absolute!important;
    left:18px!important;
    top:18px!important;
    display:flex!important;
    flex-direction:column!important;
    align-items:flex-end!important;
    gap:4px!important;
    direction:rtl!important;
    color:#747d75!important;
    font-family:Tahoma,Arial,sans-serif!important;
}

.cz-read-date span{
    font-size:10px!important;
}

.cz-read-date strong{
    font-size:12px!important;
    color:#344b3d!important;
}

.cz-read-divider{
    height:2px!important;
    background:linear-gradient(90deg, transparent, #c9a64b, transparent)!important;
}

.cz-read-body{
    padding:22px!important;
    min-height:190px!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:13px!important;
    line-height:2!important;
    color:#26372e!important;
    text-align:right!important;
    direction:rtl!important;
}

.cz-read-body p{
    margin:0 0 13px!important;
}

.cz-system-hint{
    padding:10px 12px!important;
    background:#fff8e6!important;
    border:1px solid #ead8a3!important;
    border-radius:9px!important;
    color:#78621e!important;
}

.cz-support-list{
    margin:10px 22px 16px 0!important;
    padding:0!important;
}

.cz-support-list li{
    margin:6px 0!important;
}

.cz-read-actions{
    display:flex!important;
    justify-content:flex-start!important;
    padding:0 22px 20px!important;
}

.cz-primary-message-btn{
    appearance:none!important;
    border:1px solid #b99b4b!important;
    border-radius:9px!important;
    background:#20392d!important;
    color:#fff!important;
    padding:8px 16px!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-weight:700!important;
    font-size:12px!important;
    cursor:pointer!important;
}

.cz-primary-message-btn:hover{
    background:#2f5140!important;
    box-shadow:0 4px 12px rgba(31,45,36,.15)!important;
}

/* تعطيل المظهر الدفتري القديم داخل صفحة القراءة الجديدة */
#content.cz-message-read #read_head,
#content.cz-message-read #read_foot,
#content.cz-message-read #read_content,
#content.cz-message-read #label{
    background:none!important;
}

@media (max-width:760px){
    .cz-read-meta{
        padding-left:18px!important;
        padding-top:55px!important;
    }

    .cz-read-date{
        right:18px!important;
        left:auto!important;
        top:14px!important;
        align-items:flex-start!important;
    }

    .cz-read-body{
        padding:16px!important;
    }
}


/* =========================================================
   مدينة الصفر v6.4.1 — تنظيف الرسائل
   ========================================================= */

#content.messages{
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:13px!important;
    line-height:1.6!important;
}

/* تبويبات مرتبة بدون | */
#content.messages .cz-message-tabs{
    display:flex!important;
    flex-wrap:nowrap!important;
    gap:8px!important;
    align-items:center!important;
    justify-content:flex-start!important;
    direction:rtl!important;
    overflow-x:auto!important;
    padding:9px!important;
    margin:0 0 16px!important;
    background:#f5f2e9!important;
    border:1px solid #e2ddcf!important;
    border-radius:12px!important;
    white-space:nowrap!important;
}

#content.messages .cz-message-tabs a{
    flex:0 0 auto!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    min-height:34px!important;
    padding:0 13px!important;
    margin:0!important;
    border:1px solid transparent!important;
    border-radius:9px!important;
    background:#fff!important;
    color:#274536!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:12px!important;
    font-weight:700!important;
    text-decoration:none!important;
}

#content.messages .cz-message-tabs a.selected{
    background:#fff9ea!important;
    border-color:#d2b963!important;
    color:#18392b!important;
    box-shadow:0 2px 7px rgba(31,45,36,.06)!important;
}

/* الخطوط داخل الجدول */
#content.messages #overview th,
#content.messages #overview td{
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:12px!important;
    vertical-align:middle!important;
}

#content.messages #overview td.top a,
#content.messages #overview td.send a{
    font-size:12px!important;
    line-height:1.45!important;
}

/* أزرار عربية نظيفة: نخفي شكل sprite القديم ونترك input شفاف يغطي الزر */
#content.messages .cz-img-action{
    position:relative!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    min-width:72px!important;
    min-height:30px!important;
    margin:3px!important;
    padding:0 12px!important;
    border:1px solid #c5ad60!important;
    border-radius:8px!important;
    background:#fff9e8!important;
    color:#274536!important;
    box-sizing:border-box!important;
    overflow:hidden!important;
    cursor:pointer!important;
}

#content.messages .cz-img-action input[type="image"]{
    position:absolute!important;
    inset:0!important;
    width:100%!important;
    height:100%!important;
    opacity:0!important;
    z-index:2!important;
    cursor:pointer!important;
    margin:0!important;
    padding:0!important;
}

#content.messages .cz-img-action b{
    position:relative!important;
    z-index:1!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:11px!important;
    font-weight:700!important;
    pointer-events:none!important;
}

/* منع تراكب النص */
#content.messages #overview .buttons{
    text-align:center!important;
    white-space:nowrap!important;
}

#content.messages #overview td.dat{
    min-width:88px!important;
    font-size:11px!important;
}

/* عنوان الرسائل النظامية */
#content.messages #overview td.top{
    max-width:260px!important;
    word-break:normal!important;
    overflow-wrap:anywhere!important;
}

@media (max-width:760px){
    #content.messages .cz-message-tabs{
        justify-content:flex-start!important;
    }
}



/* =========================================================
   مدينة الصفر v6.5 — كتابة ورد الرسائل
   ========================================================= */

#content.messages #write_head,
#content.messages #write_foot{
    display:none!important;
}

#content.messages #write_content{
    background:#fff!important;
    border:1px solid var(--cz-line)!important;
    border-radius:14px!important;
    box-shadow:0 7px 22px rgba(31,45,36,.07)!important;
    padding:18px!important;
    box-sizing:border-box!important;
    direction:rtl!important;
    text-align:right!important;
}

#content.messages #write_content #label{
    display:none!important;
}

.cz-compose-heading{
    display:grid!important;
    grid-template-columns:78px minmax(0,1fr)!important;
    gap:9px 12px!important;
    align-items:center!important;
    margin-bottom:10px!important;
}

.cz-compose-label{
    font-family:Tahoma,Arial,sans-serif!important;
    color:#59685e!important;
    font-size:11px!important;
    font-weight:700!important;
    text-align:right!important;
}

#content.messages #write_content .cz-compose-input{
    width:100%!important;
    max-width:none!important;
    height:38px!important;
    margin:0!important;
    padding:7px 10px!important;
    box-sizing:border-box!important;
    border:1px solid #d8d2c5!important;
    border-radius:9px!important;
    background:#fff!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:12px!important;
    direction:rtl!important;
    text-align:right!important;
}

#content.messages #write_content input[readonly]{
    background:#f6f4ee!important;
    color:#385346!important;
    font-weight:700!important;
}

#content.messages #adbook{
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    width:34px!important;
    height:34px!important;
    margin:2px 0 8px!important;
    border:1px solid #d4c995!important;
    border-radius:8px!important;
    background:#fff9e8!important;
}

#content.messages #message_container{
    margin-top:8px!important;
}

#content.messages #message_toolbar{
    border:1px solid #ded8cb!important;
    border-radius:10px 10px 0 0!important;
    background:#f6f3eb!important;
    padding:7px!important;
}

#content.messages #message{
    width:100%!important;
    min-height:260px!important;
    box-sizing:border-box!important;
    border:1px solid #ded8cb!important;
    border-top:0!important;
    border-radius:0 0 10px 10px!important;
    padding:13px!important;
    background:#fff!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:13px!important;
    line-height:1.9!important;
    direction:rtl!important;
    text-align:right!important;
    resize:vertical!important;
}

.cz-compose-actions{
    display:flex!important;
    justify-content:flex-start!important;
    margin:14px 0 0!important;
}

.cz-compose-send{
    border:1px solid #17392b!important;
    border-radius:9px!important;
    background:#20392d!important;
    color:#fff!important;
    padding:9px 18px!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:12px!important;
    font-weight:700!important;
    cursor:pointer!important;
}

.cz-compose-send:hover{
    background:#2d5140!important;
    box-shadow:0 4px 12px rgba(31,45,36,.15)!important;
}

.cz-compose-warning{
    margin-top:14px!important;
    padding:10px 12px!important;
    border:1px solid #e1c991!important;
    border-radius:9px!important;
    background:#fff8e5!important;
    color:#755f20!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:11px!important;
    line-height:1.7!important;
    direction:rtl!important;
    text-align:right!important;
}

#content.messages #adressbook{
    direction:rtl!important;
    text-align:right!important;
    font-family:Tahoma,Arial,sans-serif!important;
}

#content.messages #adressbook h2{
    color:#20392d!important;
    font-family:Tahoma,Arial,sans-serif!important;
}

@media (max-width:760px){
    .cz-compose-heading{
        grid-template-columns:1fr!important;
    }
    .cz-compose-label{
        margin-top:4px!important;
    }
}



/* =========================================================
   مدينة الصفر — الرسائل v7
   إعادة تصميم كاملة بدون صور الدفتر القديمة
   ========================================================= */

#content.messages{
    width:540px!important;
    min-height:560px!important;
    padding:22px!important;
    background:#fff!important;
    border:1px solid var(--cz-line)!important;
    border-radius:18px!important;
    box-shadow:0 10px 32px rgba(31,45,36,.09)!important;
    direction:rtl!important;
    text-align:right!important;
    overflow:visible!important;
}

#content.messages h1{
    display:flex!important;
    align-items:center!important;
    gap:9px!important;
    margin:0 0 16px!important;
    padding:0 0 13px!important;
    border-bottom:2px solid var(--cz-gold)!important;
    color:var(--cz-green)!important;
    font-size:27px!important;
    font-family:Tahoma,Arial,sans-serif!important;
}

.cz-title-icon{
    width:34px!important;
    height:34px!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    border-radius:9px!important;
    background:#f6efd7!important;
    color:#806419!important;
    font-size:18px!important;
}

/* Message tabs */
#content.messages .cz-message-tabs{
    display:grid!important;
    grid-template-columns:repeat(5,minmax(0,1fr))!important;
    gap:7px!important;
    padding:8px!important;
    margin:0 0 18px!important;
    border:1px solid #e3ddcf!important;
    border-radius:12px!important;
    background:#f7f4ec!important;
    overflow:visible!important;
}

#content.messages .cz-message-tabs a{
    min-width:0!important;
    min-height:42px!important;
    padding:5px 7px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:6px!important;
    border:1px solid transparent!important;
    border-radius:9px!important;
    background:#fff!important;
    color:#29493a!important;
    font-size:11px!important;
    font-weight:700!important;
    text-decoration:none!important;
    white-space:nowrap!important;
}

#content.messages .cz-message-tabs a.selected{
    color:#fff!important;
    background:var(--cz-green)!important;
    border-color:#b59a47!important;
    box-shadow:0 3px 10px rgba(31,45,36,.13)!important;
}

.cz-tab-icon{
    font-size:14px!important;
    opacity:.9!important;
}

/* Hide all legacy notebook graphics in compose/notes */
#content.messages #write_head,
#content.messages #write_foot,
#content.messages #label,
#content.messages .msg_head,
#content.messages .msg_foot,
#content.messages #block:before,
#content.messages #block:after{
    display:none!important;
    background:none!important;
}

#content.messages #write_content,
#content.messages .cz-notes-card{
    margin:0!important;
    padding:18px!important;
    width:auto!important;
    height:auto!important;
    background:#fbfaf6!important;
    border:1px solid #e1dccf!important;
    border-radius:14px!important;
    box-shadow:none!important;
    box-sizing:border-box!important;
}

/* Compose heading */
.cz-compose-heading{
    display:grid!important;
    grid-template-columns:82px minmax(0,1fr)!important;
    gap:10px 12px!important;
    align-items:center!important;
    margin:0!important;
}

.cz-compose-label{
    color:#4b6254!important;
    font-size:11px!important;
    font-weight:700!important;
}

#content.messages #write_content .cz-compose-input{
    width:100%!important;
    height:40px!important;
    margin:0!important;
    padding:8px 11px!important;
    border:1px solid #d9d3c6!important;
    border-radius:9px!important;
    background:#fff!important;
    box-sizing:border-box!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:12px!important;
    direction:rtl!important;
    text-align:right!important;
}

.cz-addressbook-btn{
    width:38px!important;
    height:38px!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    margin:10px 0 4px!important;
    border:1px solid #d2c48f!important;
    border-radius:9px!important;
    background:#fff9e9!important;
    color:#284a39!important;
    text-decoration:none!important;
    font-size:18px!important;
}

/* Editor */
#content.messages #message_container{
    margin-top:12px!important;
    border:0!important;
    background:transparent!important;
}

#content.messages .cz-editor-toolbar,
#content.messages #message_toolbar{
    min-height:44px!important;
    padding:7px!important;
    display:flex!important;
    align-items:center!important;
    flex-wrap:wrap!important;
    gap:5px!important;
    border:1px solid #ddd7c9!important;
    border-radius:10px 10px 0 0!important;
    background:#f5f2ea!important;
    box-sizing:border-box!important;
}

#content.messages #message_toolbar>a{
    display:inline-flex!important;
    text-decoration:none!important;
}

#content.messages .cz-tool{
    width:31px!important;
    height:31px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    padding:0!important;
    margin:0!important;
    border:1px solid #ddd6c8!important;
    border-radius:7px!important;
    background:#fff!important;
    color:#243c30!important;
    font-family:Arial,Tahoma,sans-serif!important;
    font-size:15px!important;
    font-weight:700!important;
    line-height:1!important;
    background-image:none!important;
    cursor:pointer!important;
    box-sizing:border-box!important;
}

#content.messages .cz-tool:hover{
    background:#edf2ed!important;
    border-color:#bfcbbf!important;
}

.cz-tool-separator{
    width:1px!important;
    height:25px!important;
    background:#d9d3c5!important;
    margin:0 3px!important;
}

#content.messages #message{
    width:100%!important;
    min-height:245px!important;
    max-height:430px!important;
    margin:0!important;
    padding:14px!important;
    border:1px solid #ddd7c9!important;
    border-top:0!important;
    border-radius:0 0 10px 10px!important;
    background:#fff!important;
    box-sizing:border-box!important;
    direction:rtl!important;
    text-align:right!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:13px!important;
    line-height:1.9!important;
    resize:vertical!important;
}

/* Resource/smiley/troop popup rows */
#content.messages #message_toolbarWindows{
    width:100%!important;
}

#content.messages #message_resources,
#content.messages #message_smilies,
#content.messages #message_troops{
    margin-top:6px!important;
    padding:8px!important;
    border:1px solid #ded8ca!important;
    border-radius:8px!important;
    background:#fff!important;
}

/* Modern buttons */
.cz-form-actions,
.cz-compose-actions{
    display:flex!important;
    align-items:center!important;
    justify-content:flex-start!important;
    gap:10px!important;
    margin-top:14px!important;
}

.cz-primary-btn,
.cz-secondary-btn{
    min-height:40px!important;
    padding:0 18px!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:8px!important;
    border-radius:9px!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:12px!important;
    font-weight:700!important;
    cursor:pointer!important;
    box-sizing:border-box!important;
}

.cz-primary-btn{
    border:1px solid #173b2b!important;
    background:var(--cz-green)!important;
    color:#fff!important;
}

.cz-primary-btn:hover{
    background:#2e5140!important;
    box-shadow:0 5px 14px rgba(31,45,36,.16)!important;
}

.cz-secondary-btn{
    border:1px solid #d6cebd!important;
    background:#fff!important;
    color:#5b5c56!important;
}

.cz-secondary-btn:hover{
    background:#f5f2ea!important;
}

/* Warning */
.cz-compose-warning{
    margin-top:14px!important;
    padding:11px 13px!important;
    border:1px solid #ead291!important;
    border-radius:10px!important;
    background:#fff9e8!important;
    color:#715b20!important;
    font-size:11px!important;
    line-height:1.75!important;
}

/* Notes */
.cz-section-title{
    display:flex!important;
    align-items:center!important;
    gap:10px!important;
    margin-bottom:12px!important;
}

.cz-section-icon{
    width:36px!important;
    height:36px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    border-radius:9px!important;
    background:#eef2ec!important;
    color:#234334!important;
    font-size:17px!important;
}

.cz-section-title strong{
    display:block!important;
    color:#20392d!important;
    font-size:13px!important;
}

.cz-section-title small{
    display:block!important;
    margin-top:3px!important;
    color:#7b827d!important;
    font-size:10px!important;
}

#content.messages.cz-notes-page #notice{
    width:100%!important;
    min-height:300px!important;
    margin:0!important;
    padding:14px!important;
    border:1px solid #d9d3c6!important;
    border-radius:10px!important;
    background:#fff!important;
    box-sizing:border-box!important;
    direction:rtl!important;
    text-align:right!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:13px!important;
    line-height:1.9!important;
    resize:vertical!important;
}

/* Address book popup */
#content.messages #adressbook{
    position:relative!important;
    margin-top:14px!important;
    padding:16px!important;
    border:1px solid #ded8ca!important;
    border-radius:12px!important;
    background:#fff!important;
    box-shadow:0 8px 24px rgba(31,45,36,.10)!important;
}

.cz-adbook-close{
    position:absolute!important;
    top:10px!important;
    left:10px!important;
    width:30px!important;
    height:30px!important;
    border:1px solid #ddd6c7!important;
    border-radius:7px!important;
    background:#fff!important;
    color:#7b4039!important;
    font-size:18px!important;
    cursor:pointer!important;
}

/* Legacy visual buttons in inbox/sent/archive */
#content.messages .cz-img-action{
    min-width:76px!important;
    min-height:32px!important;
    border-radius:8px!important;
}

/* Responsive */
@media(max-width:760px){
    #content.messages{
        width:100%!important;
        padding:14px!important;
    }

    #content.messages .cz-message-tabs{
        grid-template-columns:repeat(2,minmax(0,1fr))!important;
    }

    .cz-compose-heading{
        grid-template-columns:1fr!important;
    }

    #content.messages .cz-editor-toolbar,
    #content.messages #message_toolbar{
        gap:4px!important;
    }

    #content.messages .cz-tool{
        width:29px!important;
        height:29px!important;
    }
}


/* =========================================================
   مدينة الصفر v8 — مطابق للصورة المرجعية قدر الإمكان
   ========================================================= */

:root{
    --cz8-green:#064c34;
    --cz8-green-2:#0d6848;
    --cz8-green-dark:#063d2c;
    --cz8-gold:#d2a12d;
    --cz8-gold-soft:#f4e5b8;
    --cz8-cream:#f7f2e8;
    --cz8-card:#fffdfa;
    --cz8-border:#e2d7c4;
    --cz8-text:#183629;
    --cz8-muted:#7f837e;
    --cz8-danger:#c63a29;
}

/* Header */
#header.cz-header-v8{
    height:104px!important;
    background:linear-gradient(180deg,var(--cz8-green) 0,var(--cz8-green-dark) 100%)!important;
    border-bottom:1px solid #cda64a!important;
    box-shadow:0 4px 18px rgba(14,53,38,.18)!important;
    position:relative!important;
    overflow:visible!important;
}

.cz-header-inner{
    width:1180px!important;
    max-width:calc(100% - 34px)!important;
    height:100%!important;
    margin:0 auto!important;
    display:grid!important;
    grid-template-columns:210px 1fr 120px!important;
    align-items:center!important;
    gap:18px!important;
    direction:rtl!important;
}

.cz-top-brand{
    direction:rtl!important;
    display:flex!important;
    align-items:center!important;
    gap:12px!important;
    justify-content:flex-end!important;
}

.cz-top-brand-mark{
    width:52px!important;
    height:58px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    border-radius:12px 12px 18px 18px!important;
    background:linear-gradient(180deg,#0d6848,#06432f)!important;
    border:2px solid #d3a72f!important;
    color:#f4c947!important;
    font-size:28px!important;
    font-weight:700!important;
    box-shadow:0 4px 12px rgba(0,0,0,.18)!important;
}

.cz-top-brand-copy{
    text-align:right!important;
}

.cz-top-brand-copy strong{
    display:block!important;
    color:#fff!important;
    font-size:20px!important;
    font-family:Tahoma,Arial,sans-serif!important;
}

.cz-top-brand-copy small{
    display:block!important;
    margin-top:5px!important;
    color:#f1df9d!important;
    font-size:11px!important;
}

.cz-gold-dot{
    color:#d8a72c!important;
}

#mtop.cz-topnav-v8{
    position:static!important;
    width:auto!important;
    height:auto!important;
    margin:0!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:5px!important;
    direction:rtl!important;
}

#mtop.cz-topnav-v8 .cz-nav-item{
    position:relative!important;
    min-width:88px!important;
    height:66px!important;
    padding:6px 10px!important;
    display:flex!important;
    flex-direction:column!important;
    align-items:center!important;
    justify-content:center!important;
    gap:4px!important;
    border:1px solid transparent!important;
    border-radius:10px!important;
    background:transparent!important;
    color:#fff!important;
    font-size:12px!important;
    font-weight:700!important;
    text-decoration:none!important;
    box-sizing:border-box!important;
    transition:.15s ease!important;
}

#mtop.cz-topnav-v8 .cz-nav-item:hover{
    background:rgba(255,255,255,.08)!important;
}

#mtop.cz-topnav-v8 .cz-nav-item.cz-active{
    background:#073f2f!important;
    border-color:#c79e2e!important;
    color:#f5c842!important;
    box-shadow:0 3px 12px rgba(0,0,0,.16)!important;
}

#mtop.cz-topnav-v8 .cz-nav-item>img{
    display:none!important;
}

.cz-nav-icon{
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    width:26px!important;
    height:24px!important;
    color:#f0cf6c!important;
    font-size:21px!important;
    line-height:1!important;
}

#mtop.cz-topnav-v8 #n5.cz-nav-split{
    display:flex!important;
    width:auto!important;
    height:auto!important;
    float:none!important;
    background:none!important;
}

#mtop.cz-topnav-v8 #n5.cz-nav-split>a{
    min-width:88px!important;
}

.cz-server-status{
    color:#fff!important;
    text-align:left!important;
    direction:rtl!important;
    font-family:Tahoma,Arial,sans-serif!important;
}

.cz-server-status strong{
    display:block!important;
    font-size:15px!important;
}

.cz-server-status small{
    display:block!important;
    margin-top:5px!important;
    color:#c7d3cc!important;
    font-size:10px!important;
}

/* Resource bar */
#res.cz-resbar-v8{
    position:relative!important;
    min-height:46px!important;
    height:46px!important;
    margin:0!important;
    background:#fffdf9!important;
    border-top:0!important;
    border-bottom:1px solid #e6ddcf!important;
    box-shadow:0 2px 8px rgba(63,54,36,.04)!important;
}

#resWrap.cz-reswrap-v8{
    width:760px!important;
    max-width:calc(100% - 40px)!important;
    height:46px!important;
    margin:0 auto!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:24px!important;
    direction:ltr!important;
}

.cz-resource-item{
    display:flex!important;
    align-items:center!important;
    gap:6px!important;
    white-space:nowrap!important;
    color:#26392f!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:12px!important;
}

.cz-resource-item img{
    flex:0 0 auto!important;
}

.cz-resource-item strong{
    font-size:13px!important;
}

.cz-gold-resource{
    color:#9a761b!important;
    direction:rtl!important;
}

.cz-gold-resource span{
    font-weight:700!important;
}

/* Main page width */
#mid{
    width:1040px!important;
    margin:0 auto!important;
    padding-top:26px!important;
}

/* Side menu */
#side_navi.cz-side-menu-v8{
    float:left!important;
    width:180px!important;
    min-height:0!important;
    margin-top:0!important;
    padding:0!important;
    background:transparent!important;
    direction:rtl!important;
    text-align:right!important;
}

.cz-profile-card,
.cz-side-card{
    background:rgba(255,255,255,.94)!important;
    border:1px solid var(--cz8-border)!important;
    border-radius:13px!important;
    box-shadow:0 4px 14px rgba(63,54,36,.06)!important;
}

.cz-profile-card{
    min-height:80px!important;
    margin-bottom:14px!important;
    padding:13px 14px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:space-between!important;
    gap:10px!important;
    box-sizing:border-box!important;
}

.cz-profile-copy strong{
    display:block!important;
    color:var(--cz8-text)!important;
    font-size:13px!important;
}

.cz-profile-copy small{
    display:block!important;
    margin-top:4px!important;
    color:#777d78!important;
    font-size:10px!important;
}

.cz-profile-mark{
    width:42px!important;
    height:48px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    border-radius:9px 9px 14px 14px!important;
    background:linear-gradient(180deg,#0d6547,#074431)!important;
    border:2px solid #cda337!important;
    color:#efc958!important;
    font-size:23px!important;
    font-weight:700!important;
}

.cz-side-card{
    padding:8px!important;
    margin-bottom:14px!important;
}

.cz-side-card a{
    min-height:36px!important;
    padding:5px 8px!important;
    display:flex!important;
    align-items:center!important;
    gap:9px!important;
    border-radius:8px!important;
    color:#263b30!important;
    text-decoration:none!important;
    font-size:12px!important;
    box-sizing:border-box!important;
}

.cz-side-card a:hover{
    background:#f3f6f1!important;
    color:#0d6547!important;
}

.cz-side-icon{
    width:22px!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    color:#0c5e43!important;
    font-size:17px!important;
}

.cz-side-secondary a:first-child{
    font-weight:700!important;
    color:#0c573e!important;
}

.cz-logout-card a{
    color:var(--cz8-danger)!important;
    font-weight:700!important;
}

/* Messages card */
#content.messages{
    width:620px!important;
    min-height:620px!important;
    margin-right:0!important;
    padding:22px!important;
    background:rgba(255,255,255,.97)!important;
    border:1px solid var(--cz8-border)!important;
    border-radius:16px!important;
    box-shadow:0 8px 24px rgba(65,55,37,.07)!important;
}

#content.messages h1{
    justify-content:center!important;
    color:#0a4a35!important;
    font-size:27px!important;
    border-bottom:1px solid #d2a02c!important;
    position:relative!important;
}

#content.messages h1:after{
    content:""!important;
    position:absolute!important;
    bottom:-4px!important;
    left:50%!important;
    width:8px!important;
    height:8px!important;
    transform:translateX(-50%) rotate(45deg)!important;
    background:#d2a02c!important;
}

/* Tabs exactly one row */
#content.messages .cz-message-tabs{
    grid-template-columns:repeat(5,1fr)!important;
    gap:0!important;
    padding:0!important;
    overflow:hidden!important;
    border:1px solid #ddd3c3!important;
    border-radius:9px!important;
    background:#fbf8f1!important;
}

#content.messages .cz-message-tabs a{
    min-height:48px!important;
    border-radius:0!important;
    border-left:1px solid #e1d9ca!important;
    background:#fbf8f1!important;
    color:#313b35!important;
    font-size:12px!important;
}

#content.messages .cz-message-tabs a:last-child{
    border-left:0!important;
}

#content.messages .cz-message-tabs a.selected{
    background:linear-gradient(180deg,#0d6547,#074931)!important;
    color:#fff!important;
    border-color:#c89d2d!important;
    box-shadow:none!important;
}

#content.messages .cz-message-tabs a.selected .cz-tab-icon{
    color:#f4cc55!important;
}

.cz-tab-icon{
    color:#4d534f!important;
}

/* Compose container */
#content.messages #write_content{
    margin-top:16px!important;
    padding:18px!important;
    background:#fbf8f1!important;
    border:1px solid #e1d7c8!important;
    border-radius:12px!important;
}

/* tighter recipient/subject */
.cz-compose-heading{
    display:grid!important;
    grid-template-columns:92px minmax(0,1fr)!important;
    row-gap:10px!important;
    column-gap:12px!important;
    margin:0!important;
}

.cz-compose-label{
    display:flex!important;
    align-items:center!important;
    justify-content:flex-start!important;
    gap:7px!important;
    height:42px!important;
    color:#22392e!important;
    font-size:12px!important;
    font-weight:700!important;
}

.cz-field-icon{
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    width:20px!important;
    color:#0d6547!important;
    font-size:15px!important;
}

#content.messages #write_content .cz-compose-input{
    height:42px!important;
    padding:8px 12px!important;
    border:1px solid #ddd2c1!important;
    border-radius:8px!important;
    background:#fff!important;
    box-shadow:inset 0 1px 2px rgba(63,54,36,.03)!important;
}

#content.messages #write_content .cz-compose-input:focus{
    outline:0!important;
    border-color:#ba9a45!important;
    box-shadow:0 0 0 2px rgba(210,161,45,.12)!important;
}

.cz-addressbook-row{
    display:flex!important;
    justify-content:flex-end!important;
    margin:10px 104px 0 0!important;
}

.cz-addressbook-btn{
    width:auto!important;
    min-width:110px!important;
    height:34px!important;
    margin:0!important;
    padding:0 10px!important;
    gap:7px!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    border:1px solid #d2c28c!important;
    border-radius:8px!important;
    background:#fff8e5!important;
    color:#0a5c40!important;
    font-size:11px!important;
}

.cz-addressbook-text{
    font-family:Tahoma,Arial,sans-serif!important;
    font-weight:700!important;
}

.cz-addressbook-icon{
    font-size:14px!important;
}

/* Toolbar stronger contrast */
#content.messages #message_container{
    margin-top:16px!important;
}

#content.messages .cz-editor-toolbar,
#content.messages #message_toolbar{
    min-height:46px!important;
    padding:7px 8px!important;
    gap:6px!important;
    border-color:#d8cdbc!important;
    background:#f2ede4!important;
}

#content.messages .cz-tool{
    width:32px!important;
    height:32px!important;
    border-color:#d9cfbf!important;
    background:#fff!important;
    color:#1d352a!important;
}

#content.messages .cz-tool:hover{
    background:#edf4ef!important;
    border-color:#9fb9a9!important;
    color:#075139!important;
}

#content.messages #message{
    min-height:285px!important;
    border-color:#d8cdbc!important;
    color:#26382f!important;
    background:#fff!important;
}

/* Buttons more saturated */
.cz-primary-btn{
    min-width:175px!important;
    min-height:42px!important;
    background:linear-gradient(180deg,#0f6a4a,#075037)!important;
    border-color:#06452f!important;
    color:#fff!important;
    box-shadow:0 3px 9px rgba(6,76,52,.18)!important;
}

.cz-primary-btn:hover{
    background:linear-gradient(180deg,#147b56,#096043)!important;
}

.cz-secondary-btn{
    min-width:105px!important;
    min-height:42px!important;
    border-color:#d7ccba!important;
    background:#fffaf1!important;
    color:#5e584d!important;
}

/* Notes */
#content.messages .cz-notes-card{
    margin-top:16px!important;
    background:#fbf8f1!important;
    border-color:#e1d7c8!important;
}

#content.messages.cz-notes-page #notice{
    min-height:340px!important;
    border-color:#d8cdbc!important;
}

/* Task card stronger */
#side_info.cz-task-panel{
    right:0!important;
    width:175px!important;
}

.cz-task-button{
    min-height:88px!important;
    border-color:#e0d5c5!important;
    background:#fff!important;
}

.cz-task-icon{
    background:linear-gradient(180deg,#0d6b4a,#07503a)!important;
    color:#fff!important;
    border:1px solid #d4a32f!important;
}

/* Warmer body */
html,body{
    background:#f6f1e7!important;
}

@media(max-width:1100px){
    .cz-header-inner{
        width:1000px!important;
    }
    #mid{
        width:980px!important;
    }
    #content.messages{
        width:590px!important;
    }
}

@media(max-width:760px){
    .cz-header-inner{
        display:flex!important;
        width:100%!important;
        max-width:none!important;
        overflow-x:auto!important;
    }
    .cz-top-brand,.cz-server-status{
        display:none!important;
    }
    #mtop.cz-topnav-v8{
        min-width:760px!important;
    }
    #mid{
        width:100%!important;
    }
    #side_navi.cz-side-menu-v8{
        width:100%!important;
        float:none!important;
    }
    #content.messages{
        width:100%!important;
    }
    .cz-compose-heading{
        grid-template-columns:1fr!important;
    }
    .cz-compose-label{
        height:auto!important;
    }
    .cz-addressbook-row{
        margin:8px 0 0!important;
    }
}


/* =========================================================
   مدينة الصفر v8.1 — تنظيف تعارضات Travian القديمة
   ========================================================= */

/* إلغاء الهيدر القديم بالكامل حتى لا يظهر عنوان مزدوج */
#dynamic_header{
    display:none!important;
    height:0!important;
    min-height:0!important;
    margin:0!important;
    padding:0!important;
    border:0!important;
    background:none!important;
}
#dynamic_header:after{
    display:none!important;
    content:none!important;
}

/* منع صور/سبرايت Travian القديمة من تخريب الناف الجديد */
#header.cz-header-v8 #mtop img,
#header.cz-header-v8 #mtop .l,
#header.cz-header-v8 #mtop .r,
#header.cz-header-v8 #mtop #btn_plus{
    display:none!important;
    width:0!important;
    height:0!important;
    margin:0!important;
    padding:0!important;
    background:none!important;
    background-image:none!important;
}

/* تنظيف أي خلفيات قديمة على الـIDs الأساسية */
#header.cz-header-v8 #n1,
#header.cz-header-v8 #n2,
#header.cz-header-v8 #n3,
#header.cz-header-v8 #n4,
#header.cz-header-v8 #n5,
#header.cz-header-v8 #plus{
    background-image:none!important;
}

/* الهيدر أقوى وأقل بهتان */
#header.cz-header-v8{
    height:98px!important;
    background:#074a34!important;
    border-bottom:2px solid #d2a12d!important;
    box-shadow:0 5px 20px rgba(4,48,33,.24)!important;
}

.cz-header-inner{
    width:1120px!important;
    max-width:calc(100% - 32px)!important;
    grid-template-columns:190px 1fr 118px!important;
    gap:12px!important;
}

.cz-top-brand-mark{
    background:#075c40!important;
    border-color:#d8aa31!important;
    color:#ffd45a!important;
}

.cz-top-brand-copy strong{
    color:#fff!important;
}
.cz-top-brand-copy small{
    color:#f0d77d!important;
}

#mtop.cz-topnav-v8{
    gap:3px!important;
}

#mtop.cz-topnav-v8 .cz-nav-item{
    min-width:80px!important;
    height:64px!important;
    padding:5px 8px!important;
    color:#fff!important;
    opacity:1!important;
}

#mtop.cz-topnav-v8 .cz-nav-item span{
    opacity:1!important;
}

#mtop.cz-topnav-v8 .cz-nav-item.cz-active{
    background:#063d2c!important;
    border-color:#d5a52c!important;
    color:#ffd253!important;
}

.cz-nav-icon{
    color:#f5c94b!important;
    opacity:1!important;
}

.cz-server-status{
    color:#fff!important;
    opacity:1!important;
}

/* الموارد أوضح */
#res.cz-resbar-v8{
    height:48px!important;
    min-height:48px!important;
    background:#fffaf1!important;
    border-bottom:1px solid #dfd2bc!important;
}

#resWrap.cz-reswrap-v8{
    height:48px!important;
    gap:18px!important;
}

.cz-resource-item{
    color:#18382a!important;
    opacity:1!important;
}

.cz-resource-item strong{
    color:#18382a!important;
    font-size:13px!important;
}

.cz-gold-resource{
    color:#9a6e08!important;
}
.cz-gold-resource strong,
.cz-gold-resource span{
    color:#9a6e08!important;
}

/* خلفية عامة أقل شحوباً */
html, body, .wrapper{
    background:#f3ecdf!important;
}

/* ضبط التخطيط */
#mid{
    width:1020px!important;
    padding-top:28px!important;
}

/* بطاقات الجانب أوضح */
.cz-profile-card,
.cz-side-card{
    background:#fffaf2!important;
    border-color:#d9cbb6!important;
    box-shadow:0 4px 14px rgba(71,55,30,.08)!important;
}

.cz-side-card a{
    color:#173b2b!important;
}
.cz-side-icon{
    color:#086044!important;
}

/* بطاقة الرسائل: تباين أعلى */
#content.messages{
    width:630px!important;
    background:#fffdf9!important;
    border-color:#d8c9b3!important;
    box-shadow:0 10px 28px rgba(72,56,31,.10)!important;
}

#content.messages h1{
    color:#074a34!important;
}

#content.messages .cz-message-tabs{
    background:#f3ecdf!important;
    border-color:#d7c8b2!important;
}

#content.messages .cz-message-tabs a{
    background:#fffaf2!important;
    color:#18382a!important;
    border-color:#e0d3c0!important;
    opacity:1!important;
}

#content.messages .cz-message-tabs a .cz-tab-icon{
    color:#8c6a17!important;
    opacity:1!important;
}

#content.messages .cz-message-tabs a.selected{
    background:#074a34!important;
    color:#fff!important;
    border-color:#cfa12f!important;
}
#content.messages .cz-message-tabs a.selected .cz-tab-icon{
    color:#ffd455!important;
}

/* جدول الوارد أوضح */
#content.messages #overview{
    border-color:#d6c8b3!important;
}
#content.messages #overview th{
    background:#123f2e!important;
    color:#fff!important;
}
#content.messages #overview td{
    background:#fffdf9!important;
    color:#24372e!important;
}
#content.messages #overview tr:hover td{
    background:#f8f1e5!important;
}

/* أزرار الحذف/الأرشفة */
#content.messages .cz-img-action{
    background:#fff6df!important;
    border-color:#d0ae50!important;
    color:#264334!important;
}

/* نموذج كتابة الرسالة */
#content.messages #write_content{
    background:#f8f1e5!important;
    border-color:#d8c8b2!important;
}

#content.messages #write_content .cz-compose-input{
    background:#fffdf9!important;
    border-color:#cfc0aa!important;
    color:#1d372a!important;
}

#content.messages #message_toolbar,
#content.messages .cz-editor-toolbar{
    background:#eee5d7!important;
    border-color:#cfc0aa!important;
}

#content.messages .cz-tool{
    background:#fffaf2!important;
    border-color:#d0c1ab!important;
    color:#173a2b!important;
    opacity:1!important;
}

#content.messages #message{
    background:#fffdf9!important;
    border-color:#cfc0aa!important;
    color:#1b3528!important;
}

/* أزرار أقوى */
.cz-primary-btn{
    background:#075b40!important;
    border-color:#064a35!important;
    color:#fff!important;
}
.cz-primary-btn:hover{
    background:#08704d!important;
}

.cz-secondary-btn{
    background:#fff8e9!important;
    border-color:#d5c6af!important;
    color:#4b473f!important;
}

/* مدير المهام */
#side_info.cz-task-panel{
    width:172px!important;
}
.cz-task-button{
    background:#fffaf2!important;
    border-color:#d8c9b3!important;
}
.cz-task-icon{
    background:#075b40!important;
    border-color:#d3a431!important;
}

/* إخفاء أي صور سبرايت قديمة غير مطلوبة داخل عناوين/تبويبات الرسائل */
#content.messages .cz-message-tabs img,
#content.messages h1 img{
    display:none!important;
}

/* إزالة scrollbar أفقي ناتج من قياسات قديمة */
body{
    overflow-x:hidden!important;
}

@media(max-width:1100px){
    #mid{
        width:960px!important;
    }
    #content.messages{
        width:590px!important;
    }
}



/* =========================================================
   مدينة الصفر v8.2 — تثبيت مدير المهام + تبويبات الرسائل
   ========================================================= */

/* ثلاث أعمدة ثابتة: يسار / محتوى / مدير المهام */
#mid{
    width:1060px!important;
    max-width:1060px!important;
    position:relative!important;
    margin:0 auto!important;
    padding-top:28px!important;
    min-height:650px!important;
}

/* القائمة اليسار */
#side_navi.cz-side-menu-v8{
    float:left!important;
    width:180px!important;
    margin:0!important;
}

/* الرسائل في المنتصف */
#content.messages{
    float:left!important;
    width:630px!important;
    margin:0 0 0 25px!important;
    box-sizing:border-box!important;
}

/* مدير المهام مثبت يمين الرسائل، لا يدخل بالدفق ولا ينزل */
#side_info.cz-task-panel{
    position:absolute!important;
    float:none!important;
    top:28px!important;
    right:0!important;
    left:auto!important;
    width:180px!important;
    min-height:0!important;
    margin:0!important;
    padding:0!important;
    z-index:30!important;
    background:transparent!important;
}

/* منع المحتوى الداخلي القديم من فرض قياسات عشوائية */
#side_info.cz-task-panel #qge{
    position:static!important;
    width:100%!important;
    height:auto!important;
    margin:0!important;
    padding:0!important;
    background:none!important;
}
#side_info.cz-task-panel #anm{
    position:absolute!important;
    top:0!important;
    right:0!important;
}

/* بطاقة مدير المهام أوضح وأعلى الصفحة */
#side_info.cz-task-panel .cz-task-button{
    min-height:100px!important;
    padding:14px 13px!important;
    background:#fffdf8!important;
    border:1px solid #dacdb8!important;
    border-radius:14px!important;
    box-shadow:0 7px 20px rgba(64,50,28,.08)!important;
}
#side_info.cz-task-panel .cz-task-icon{
    width:42px!important;
    height:42px!important;
    background:#075b40!important;
    color:#fff!important;
    border:1px solid #d2a12d!important;
    border-radius:10px!important;
}
#side_info.cz-task-panel .cz-task-title{
    color:#073f2e!important;
    font-weight:700!important;
    font-size:13px!important;
}
#side_info.cz-task-panel .cz-task-sub{
    color:#777b75!important;
    font-size:10px!important;
}

/* شريط تبويبات الرسائل — أقرب للمرجع */
#content.messages .cz-message-tabs{
    display:grid!important;
    grid-template-columns:repeat(5,minmax(0,1fr))!important;
    gap:7px!important;
    padding:7px!important;
    background:#f7f1e5!important;
    border:1px solid #d9cdb8!important;
    border-radius:12px!important;
    overflow:visible!important;
}

#content.messages .cz-message-tabs a{
    min-width:0!important;
    min-height:52px!important;
    padding:6px 8px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:7px!important;
    border:1px solid #e1d6c4!important;
    border-radius:9px!important;
    background:#fffdf8!important;
    color:#173a2b!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:12px!important;
    font-weight:700!important;
    line-height:1.2!important;
    text-decoration:none!important;
    box-shadow:0 2px 6px rgba(64,50,28,.03)!important;
    opacity:1!important;
}

#content.messages .cz-message-tabs a:hover{
    border-color:#cbb472!important;
    background:#fff9e9!important;
}

/* المربع الصغير للأيقونة */
#content.messages .cz-tab-icon-box{
    width:28px!important;
    height:28px!important;
    flex:0 0 28px!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    border-radius:7px!important;
    background:#f3ebd6!important;
    color:#866814!important;
    border:1px solid #e4d7b6!important;
    box-sizing:border-box!important;
}

#content.messages .cz-tab-icon{
    color:inherit!important;
    font-size:15px!important;
    line-height:1!important;
    opacity:1!important;
}

#content.messages .cz-tab-label{
    color:inherit!important;
    white-space:nowrap!important;
    opacity:1!important;
}

/* الصفحة الحالية: الأخضر الواضح المطلوب */
#content.messages .cz-message-tabs a.selected,
#content.messages .cz-message-tabs a.cz-current,
#content.messages .cz-message-tabs a.selected.cz-current{
    background:linear-gradient(180deg,#0a6043 0%,#064a34 100%)!important;
    border-color:#cfa22e!important;
    color:#fff!important;
    box-shadow:0 5px 13px rgba(6,74,52,.20)!important;
}

#content.messages .cz-message-tabs a.selected .cz-tab-icon-box,
#content.messages .cz-message-tabs a.cz-current .cz-tab-icon-box{
    background:#f4cf59!important;
    border-color:#e0b93f!important;
    color:#064a34!important;
}

#content.messages .cz-message-tabs a.selected .cz-tab-label,
#content.messages .cz-message-tabs a.cz-current .cz-tab-label{
    color:#fff!important;
    font-weight:700!important;
}

/* عنوان الرسائل أوضح */
#content.messages h1{
    color:#064a34!important;
    font-size:29px!important;
    font-weight:700!important;
    text-shadow:none!important;
}

/* الجدول يملأ البطاقة بصورة أجمل */
#content.messages #overview{
    width:100%!important;
    margin-top:16px!important;
    border-radius:12px!important;
    overflow:hidden!important;
}

/* الشاشات الأصغر: يبقى مدير المهام بجانب المحتوى لأطول وقت ممكن */
@media(max-width:1100px){
    #mid{
        width:980px!important;
        max-width:980px!important;
    }
    #side_navi.cz-side-menu-v8{
        width:165px!important;
    }
    #content.messages{
        width:590px!important;
        margin-left:20px!important;
    }
    #side_info.cz-task-panel{
        width:165px!important;
    }
}

@media(max-width:900px){
    #mid{
        width:100%!important;
        max-width:100%!important;
        padding:16px!important;
        box-sizing:border-box!important;
    }
    #side_navi.cz-side-menu-v8,
    #content.messages{
        float:none!important;
        width:100%!important;
        margin:0 0 14px!important;
    }
    #side_info.cz-task-panel{
        position:static!important;
        width:100%!important;
        margin:0 0 14px!important;
    }
}

/* City Zero v14.54 — orderly village/oasis detail view from the map. */
body.cz-map-body #mid > #content.map.cz-vilview-page{
    display:grid!important;
    grid-template-columns:300px minmax(0,1fr)!important;
    column-gap:18px!important;
    row-gap:14px!important;
    width:700px!important;
    max-width:700px!important;
    min-height:0!important;
    margin-left:auto!important;
    margin-right:auto!important;
    padding:18px 20px 24px!important;
    box-sizing:border-box!important;
    direction:ltr!important;
    overflow:visible!important;
}
body.cz-map-body #content.map.cz-vilview-page > h1{
    grid-column:1 / -1!important;
    width:100%!important;
    margin:0!important;
    padding:0 0 12px!important;
    box-sizing:border-box!important;
    direction:rtl!important;
    color:#07563d!important;
    font-size:23px!important;
    line-height:32px!important;
}
body.cz-map-body #content.map.cz-vilview-page > #dmain{
    grid-column:1 / -1!important;
    margin:-8px 0 0!important;
    direction:rtl!important;
    text-align:center!important;
}
body.cz-map-body #content.map.cz-vilview-page > #detailed_map{
    grid-column:1!important;
    align-self:start!important;
    float:none!important;
    display:block!important;
    width:300px!important;
    height:300px!important;
    margin:0!important;
    padding:0!important;
    box-sizing:border-box!important;
}
body.cz-map-body #content.map.cz-vilview-page > #map_details{
    grid-column:2!important;
    align-self:start!important;
    float:none!important;
    width:100%!important;
    min-width:0!important;
    min-height:300px!important;
    margin:0!important;
    padding:0!important;
    box-sizing:border-box!important;
    direction:rtl!important;
}
body.cz-map-body #content.map.cz-vilview-page #map_details table,
body.cz-map-body #content.map.cz-vilview-page #map_details table.tableNone,
body.cz-map-body #content.map.cz-vilview-page #map_details table#village_info,
body.cz-map-body #content.map.cz-vilview-page #map_details table#bonus,
body.cz-map-body #content.map.cz-vilview-page #map_details table#troop_info,
body.cz-map-body #content.map.cz-vilview-page #map_details table#distribution{
    display:table!important;
    float:none!important;
    width:100%!important;
    max-width:100%!important;
    margin:0 0 10px!important;
    border:1px solid #d5c5a5!important;
    border-radius:8px!important;
    border-collapse:separate!important;
    border-spacing:0!important;
    overflow:hidden!important;
    background:#fffdf8!important;
    direction:rtl!important;
}
body.cz-map-body #content.map.cz-vilview-page #map_details table thead th{
    padding:8px 10px!important;
    background:linear-gradient(180deg,#176048,#0b4e3a)!important;
    color:#fff!important;
    font-size:12px!important;
    line-height:18px!important;
    font-weight:700!important;
    text-align:right!important;
    opacity:1!important;
}
body.cz-map-body #content.map.cz-vilview-page #map_details table tbody th,
body.cz-map-body #content.map.cz-vilview-page #map_details table tbody td{
    height:34px!important;
    padding:6px 8px!important;
    border:0!important;
    border-bottom:1px solid #e5dbc8!important;
    background:#fffdf8!important;
    color:#303b33!important;
    font-size:11px!important;
    line-height:18px!important;
    text-align:right!important;
    vertical-align:middle!important;
    opacity:1!important;
}
body.cz-map-body #content.map.cz-vilview-page #map_details table tbody tr:nth-child(even) th,
body.cz-map-body #content.map.cz-vilview-page #map_details table tbody tr:nth-child(even) td{
    background:#f5eee1!important;
}
body.cz-map-body #content.map.cz-vilview-page #map_details table tbody tr:last-child th,
body.cz-map-body #content.map.cz-vilview-page #map_details table tbody tr:last-child td{
    border-bottom:0!important;
}
body.cz-map-body #content.map.cz-vilview-page #map_details td.ico{
    width:30px!important;
    text-align:center!important;
}
body.cz-map-body #content.map.cz-vilview-page #map_details td.val{
    width:48px!important;
    text-align:center!important;
    font-weight:700!important;
}
body.cz-map-body #content.map.cz-vilview-page > #options{
    grid-column:1 / -1!important;
    clear:none!important;
    width:100%!important;
    margin:0!important;
    direction:rtl!important;
}
body.cz-map-body #content.map.cz-vilview-page > #options thead th{
    padding:9px 12px!important;
    background:linear-gradient(180deg,#176048,#0b4e3a)!important;
    color:#fff!important;
    font-size:12px!important;
}
body.cz-map-body #content.map.cz-vilview-page > #options tbody td{
    padding:8px 12px!important;
    background:#fffdf8!important;
    color:#303b33!important;
    font-size:11px!important;
}
@media(max-width:900px){
    body.cz-map-body #mid > #content.map.cz-vilview-page{
        display:block!important;
        width:100%!important;
        max-width:100%!important;
    }
    body.cz-map-body #content.map.cz-vilview-page > #detailed_map{
        width:280px!important;
        height:280px!important;
        margin:0 auto 14px!important;
    }
    body.cz-map-body #content.map.cz-vilview-page > #map_details{
        min-height:0!important;
    }
}


/* =========================================================
   مدينة الصفر v8.3 — اللمسات النهائية للرسائل
   ========================================================= */

/* التبويب النشط: فرض اللون الأخضر مهما كانت قواعد Travian القديمة */
#content.messages .cz-message-tabs a.cz-tab-active,
#content.messages .cz-message-tabs a.selected,
#content.messages .cz-message-tabs a.cz-current{
    background:#064a34!important;
    background-image:none!important;
    border:1px solid #cfa22e!important;
    color:#fff!important;
    opacity:1!important;
    filter:none!important;
    text-shadow:none!important;
}

#content.messages .cz-message-tabs a.cz-tab-active .cz-tab-label,
#content.messages .cz-message-tabs a.cz-tab-active span,
#content.messages .cz-message-tabs a.selected .cz-tab-label,
#content.messages .cz-message-tabs a.selected span,
#content.messages .cz-message-tabs a.cz-current .cz-tab-label,
#content.messages .cz-message-tabs a.cz-current span{
    color:#fff!important;
    opacity:1!important;
}

#content.messages .cz-message-tabs a.cz-tab-active .cz-tab-icon-box,
#content.messages .cz-message-tabs a.selected .cz-tab-icon-box,
#content.messages .cz-message-tabs a.cz-current .cz-tab-icon-box{
    background:#f1c84b!important;
    border-color:#d7aa2f!important;
    color:#064a34!important;
}

#content.messages .cz-message-tabs a.cz-tab-active .cz-tab-icon,
#content.messages .cz-message-tabs a.selected .cz-tab-icon,
#content.messages .cz-message-tabs a.cz-current .cz-tab-icon{
    color:#064a34!important;
}

/* كل عناوين جدول الرسائل باللون الأبيض بوضوح */
#content.messages #overview thead th,
#content.messages #overview th,
#content.messages #overview th.dat,
#content.messages #overview th.sent,
#content.messages #overview th.sub,
#content.messages #overview th.send,
#content.messages table#overview tr:first-child th{
    background:#163f2f!important;
    background-image:none!important;
    color:#fff!important;
    opacity:1!important;
    text-shadow:none!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-weight:700!important;
}

/* التاريخ تحديداً */
#content.messages #overview th.dat,
#content.messages #overview th.sent{
    color:#fff!important;
    text-align:center!important;
}

/* جسم التاريخ أوضح كذلك */
#content.messages #overview td.dat{
    color:#24372e!important;
    font-weight:400!important;
    text-align:center!important;
}

/* زيادة بسيطة في وضوح النصوص */
#content.messages #overview td,
#content.messages #overview a{
    opacity:1!important;
}



/* =========================================================
   مدينة الصفر v8.4 — ضبط تنسيق الكتابة + تاريخ المرسلة/الأرشيف
   ========================================================= */

/* ---------- تبويبات الرسائل: صف واحد دائماً على الدسكتوب ---------- */
#content.messages .cz-message-tabs{
    display:flex!important;
    flex-wrap:nowrap!important;
    align-items:stretch!important;
    justify-content:stretch!important;
    gap:7px!important;
    padding:7px!important;
    overflow:visible!important;
}

#content.messages .cz-message-tabs > a{
    flex:1 1 0!important;
    width:auto!important;
    min-width:0!important;
    max-width:none!important;
    min-height:52px!important;
    padding:6px 7px!important;
}

#content.messages .cz-message-tabs .cz-tab-label{
    font-size:11px!important;
    white-space:nowrap!important;
}

/* ---------- صفحة كتابة الرسالة ---------- */
#content.messages #write_content{
    padding:20px!important;
}

/* حقول المستلم والموضوع بمحاذاة مرتبة */
.cz-compose-heading{
    display:grid!important;
    grid-template-columns:92px minmax(0,1fr)!important;
    align-items:center!important;
    gap:10px 14px!important;
    width:100%!important;
    margin:0!important;
}

.cz-compose-label{
    height:42px!important;
    margin:0!important;
    display:flex!important;
    align-items:center!important;
    justify-content:flex-start!important;
    gap:7px!important;
    font-size:12px!important;
    line-height:1!important;
}

#content.messages #write_content .cz-compose-input{
    width:100%!important;
    max-width:none!important;
    height:42px!important;
    margin:0!important;
    box-sizing:border-box!important;
}

/* دفتر العناوين تحت المستلم/الموضوع بشكل مرتب وليس عائم */
.cz-addressbook-row{
    width:100%!important;
    margin:10px 0 0!important;
    padding-right:106px!important;
    box-sizing:border-box!important;
    display:flex!important;
    justify-content:flex-start!important;
}

.cz-addressbook-btn{
    min-width:120px!important;
    height:34px!important;
    padding:0 11px!important;
}

/* فاصل نظيف قبل المحرر */
#content.messages #message_container{
    margin-top:16px!important;
    padding-top:0!important;
    border-top:1px solid #ded2bf!important;
}

/* شريط الأدوات متوازن */
#content.messages #message_toolbar,
#content.messages .cz-editor-toolbar{
    justify-content:flex-start!important;
    direction:rtl!important;
    gap:6px!important;
    padding:8px!important;
}

#content.messages .cz-tool{
    flex:0 0 32px!important;
    width:32px!important;
    height:32px!important;
}

/* مربع الكتابة */
#content.messages #message{
    min-height:280px!important;
    padding:14px 16px!important;
}

/* أزرار الإرسال والإلغاء بمحاذاة واضحة */
.cz-compose-actions{
    display:flex!important;
    align-items:center!important;
    justify-content:flex-start!important;
    gap:10px!important;
    margin-top:14px!important;
}

/* ---------- المرسلة + الأرشيف: التاريخ أبيض دائماً ---------- */

/* جميع رؤوس الجدول */
#content.messages table#overview th,
#content.messages #overview tr:first-child th,
#content.messages #overview thead th{
    background:#163f2f!important;
    color:#ffffff!important;
    opacity:1!important;
    text-shadow:none!important;
    font-weight:700!important;
}

/* التاريخ مهما كان class */
#content.messages #overview th.dat,
#content.messages #overview th.sent,
#content.messages #overview th.time,
#content.messages #overview th[class*="dat"],
#content.messages #overview th[class*="sent"],
#content.messages #overview th:last-child{
    color:#ffffff!important;
}

/* الروابط داخل رؤوس الجدول لو موجودة */
#content.messages #overview th a,
#content.messages #overview th.dat a,
#content.messages #overview th.sent a{
    color:#ffffff!important;
    opacity:1!important;
    text-decoration:none!important;
}

/* نص التاريخ داخل الصفوف */
#content.messages #overview td.dat,
#content.messages #overview td.sent,
#content.messages #overview td.time{
    color:#263a30!important;
    opacity:1!important;
    text-align:center!important;
    font-size:11px!important;
}

/* ---------- الشاشات الصغيرة ---------- */
@media(max-width:900px){
    #content.messages .cz-message-tabs{
        display:grid!important;
        grid-template-columns:repeat(2,minmax(0,1fr))!important;
    }

    .cz-compose-heading{
        grid-template-columns:1fr!important;
        gap:6px!important;
    }

    .cz-compose-label{
        height:auto!important;
        margin-top:6px!important;
    }

    .cz-addressbook-row{
        padding-right:0!important;
    }
}


/* =========================================================
   مدينة الصفر — التقارير v9
   نفس هوية الرسائل v8.4
   ========================================================= */

#content.reports{
    float:left!important;
    width:630px!important;
    min-height:620px!important;
    margin:0 0 0 25px!important;
    padding:22px!important;
    box-sizing:border-box!important;
    background:#fffdf9!important;
    border:1px solid #d8c9b3!important;
    border-radius:16px!important;
    box-shadow:0 10px 28px rgba(72,56,31,.10)!important;
    direction:rtl!important;
    text-align:right!important;
    font-family:Tahoma,Arial,sans-serif!important;
}

#content.reports h1{
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:9px!important;
    margin:0 0 16px!important;
    padding:0 0 13px!important;
    position:relative!important;
    border-bottom:1px solid #d2a02c!important;
    color:#064a34!important;
    font-size:29px!important;
    font-weight:700!important;
    font-family:Tahoma,Arial,sans-serif!important;
}

#content.reports h1:after{
    content:""!important;
    position:absolute!important;
    bottom:-4px!important;
    left:50%!important;
    width:8px!important;
    height:8px!important;
    transform:translateX(-50%) rotate(45deg)!important;
    background:#d2a02c!important;
}

/* تبويبات التقارير */
#content.reports .cz-report-tabs{
    display:flex!important;
    flex-wrap:nowrap!important;
    align-items:stretch!important;
    gap:7px!important;
    margin:0 0 18px!important;
    padding:7px!important;
    background:#f7f1e5!important;
    border:1px solid #d9cdb8!important;
    border-radius:12px!important;
    direction:rtl!important;
}

#content.reports .cz-report-tabs > a{
    flex:1 1 0!important;
    min-width:0!important;
    min-height:52px!important;
    padding:6px 6px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:6px!important;
    border:1px solid #e1d6c4!important;
    border-radius:9px!important;
    background:#fffdf8!important;
    color:#173a2b!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:10.5px!important;
    font-weight:700!important;
    text-decoration:none!important;
    box-shadow:0 2px 6px rgba(64,50,28,.03)!important;
}

#content.reports .cz-report-tabs > a:hover{
    background:#fff9e9!important;
    border-color:#cbb472!important;
}

#content.reports .cz-report-tabs .cz-tab-icon-box{
    width:27px!important;
    height:27px!important;
    flex:0 0 27px!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    border-radius:7px!important;
    background:#f3ebd6!important;
    border:1px solid #e4d7b6!important;
    color:#866814!important;
}

#content.reports .cz-report-tabs .cz-tab-label{
    white-space:nowrap!important;
    color:inherit!important;
}

#content.reports .cz-report-tabs a.selected,
#content.reports .cz-report-tabs a.cz-current,
#content.reports .cz-report-tabs a.cz-tab-active{
    background:#064a34!important;
    background-image:none!important;
    border-color:#cfa22e!important;
    color:#fff!important;
    box-shadow:0 5px 13px rgba(6,74,52,.20)!important;
}

#content.reports .cz-report-tabs a.selected .cz-tab-icon-box,
#content.reports .cz-report-tabs a.cz-current .cz-tab-icon-box,
#content.reports .cz-report-tabs a.cz-tab-active .cz-tab-icon-box{
    background:#f1c84b!important;
    border-color:#d7aa2f!important;
    color:#064a34!important;
}

/* قائمة التقارير */
#content.reports #overview{
    width:100%!important;
    margin-top:16px!important;
    border-collapse:separate!important;
    border-spacing:0!important;
    overflow:hidden!important;
    border:1px solid #d6c8b3!important;
    border-radius:12px!important;
    background:#fffdf9!important;
}

#content.reports #overview th{
    height:42px!important;
    padding:7px 10px!important;
    background:#163f2f!important;
    color:#fff!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:12px!important;
    font-weight:700!important;
    text-align:right!important;
}

#content.reports #overview th a{
    color:#fff!important;
    text-decoration:none!important;
}

#content.reports #overview td{
    padding:9px 9px!important;
    background:#fffdf9!important;
    color:#24372e!important;
    border-color:#ece1d1!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:11px!important;
}

#content.reports #overview tr:hover td{
    background:#f8f1e5!important;
}

#content.reports #overview td.dat{
    min-width:92px!important;
    direction:rtl!important;
    text-align:center!important;
    color:#263a30!important;
}

#content.reports #overview td.sub a{
    color:#0a533a!important;
    font-weight:700!important;
}

/* الأزرار القديمة تعمل لكن شكلها عربي حديث */
.cz-report-action{
    position:relative!important;
    min-width:76px!important;
    min-height:32px!important;
    margin:3px!important;
    padding:0 12px!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    border:1px solid #d0ae50!important;
    border-radius:8px!important;
    background:#fff6df!important;
    color:#264334!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
}

.cz-report-action input[type="image"]{
    position:absolute!important;
    inset:0!important;
    width:100%!important;
    height:100%!important;
    margin:0!important;
    opacity:0!important;
    cursor:pointer!important;
    z-index:2!important;
}

.cz-report-action b{
    position:relative!important;
    z-index:1!important;
    font-size:11px!important;
    pointer-events:none!important;
}

/* التقرير المفتوح */
#content.reports #report_surround,
#content.reports .report_surround,
#content.reports #report{
    direction:rtl!important;
    text-align:right!important;
    font-family:Tahoma,Arial,sans-serif!important;
}

#content.reports table#attacker,
#content.reports table#defender,
#content.reports table#details,
#content.reports table#trade,
#content.reports table#reinforcement{
    width:100%!important;
    border-collapse:separate!important;
    border-spacing:0!important;
    margin:10px 0!important;
    border:1px solid #d9cdb8!important;
    border-radius:10px!important;
    overflow:hidden!important;
    background:#fffdf9!important;
}

#content.reports table#attacker th,
#content.reports table#defender th,
#content.reports table#details th,
#content.reports table#trade th,
#content.reports table#reinforcement th{
    background:#f0e8da!important;
    color:#143b2b!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-weight:700!important;
}

#content.reports table#attacker td,
#content.reports table#defender td,
#content.reports table#details td,
#content.reports table#trade td,
#content.reports table#reinforcement td{
    background:#fffdf9!important;
    color:#26382f!important;
    font-family:Tahoma,Arial,sans-serif!important;
}

/* رؤوس المهاجم والمدافع */
#content.reports td.role,
#content.reports th.role{
    background:#163f2f!important;
    color:#fff!important;
    font-weight:700!important;
}

/* نفس تخطيط مدير المهام للرسائل */
#content.reports + #side_info.cz-task-panel,
body:has(#content.reports) #side_info.cz-task-panel{
    position:absolute!important;
    top:28px!important;
    right:0!important;
    width:180px!important;
    margin:0!important;
}

@media(max-width:1100px){
    #content.reports{
        width:590px!important;
        margin-left:20px!important;
    }

    #content.reports .cz-report-tabs > a{
        font-size:9.5px!important;
        padding-left:4px!important;
        padding-right:4px!important;
    }
}

@media(max-width:900px){
    #content.reports{
        float:none!important;
        width:100%!important;
        margin:0 0 14px!important;
    }

    #content.reports .cz-report-tabs{
        display:grid!important;
        grid-template-columns:repeat(2,minmax(0,1fr))!important;
    }
}


/* =========================================================
   مدينة الصفر — التقارير v9.1 FINAL
   مطابق لتنسيق الرسائل: سطر واحد + ألوان قوية + أزرار عربية
   ========================================================= */

/* ----- كل التبويبات، بما فيها الأرشيف، بسطر واحد ----- */
#content.reports .cz-report-tabs{
    display:grid!important;
    width:100%!important;
    gap:7px!important;
    padding:7px!important;
    margin:0 0 18px!important;
    box-sizing:border-box!important;
    background:#f7f1e5!important;
    border:1px solid #d9cdb8!important;
    border-radius:12px!important;
    overflow:visible!important;
    direction:rtl!important;
}

#content.reports .cz-report-tabs.cz-six-tabs{
    grid-template-columns:repeat(6,minmax(0,1fr))!important;
}

#content.reports .cz-report-tabs.cz-five-tabs{
    grid-template-columns:repeat(5,minmax(0,1fr))!important;
}

#content.reports .cz-report-tabs > a{
    float:none!important;
    display:flex!important;
    width:auto!important;
    min-width:0!important;
    max-width:none!important;
    min-height:52px!important;
    margin:0!important;
    padding:5px 4px!important;
    align-items:center!important;
    justify-content:center!important;
    gap:5px!important;
    box-sizing:border-box!important;
    border:1px solid #dacdb8!important;
    border-radius:9px!important;
    background:#fffaf2!important;
    background-image:none!important;
    color:#173a2b!important;
    opacity:1!important;
    filter:none!important;
    box-shadow:0 2px 6px rgba(64,50,28,.04)!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:10px!important;
    font-weight:700!important;
    line-height:1.15!important;
    text-decoration:none!important;
    white-space:nowrap!important;
}

#content.reports .cz-report-tabs > a .cz-tab-label{
    color:#173a2b!important;
    opacity:1!important;
}

#content.reports .cz-report-tabs > a .cz-tab-icon-box{
    width:25px!important;
    height:25px!important;
    flex:0 0 25px!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    border:1px solid #ddcfae!important;
    border-radius:6px!important;
    background:#f3e6c7!important;
    color:#7c5d0e!important;
    opacity:1!important;
}

#content.reports .cz-report-tabs > a:hover{
    background:#fff4d9!important;
    border-color:#c8a852!important;
    color:#064a34!important;
}

/* المحدد مطابق للرسائل: أخضر قوي، خط أبيض، أيقونة ذهبية */
#content.reports .cz-report-tabs > a.selected,
#content.reports .cz-report-tabs > a.cz-current,
#content.reports .cz-report-tabs > a.cz-tab-active{
    background:#064a34!important;
    background-image:none!important;
    border:1px solid #d0a22e!important;
    color:#fff!important;
    opacity:1!important;
    box-shadow:0 5px 13px rgba(6,74,52,.20)!important;
}

#content.reports .cz-report-tabs > a.selected .cz-tab-label,
#content.reports .cz-report-tabs > a.cz-current .cz-tab-label,
#content.reports .cz-report-tabs > a.cz-tab-active .cz-tab-label{
    color:#fff!important;
}

#content.reports .cz-report-tabs > a.selected .cz-tab-icon-box,
#content.reports .cz-report-tabs > a.cz-current .cz-tab-icon-box,
#content.reports .cz-report-tabs > a.cz-tab-active .cz-tab-icon-box{
    background:#f1c84b!important;
    border-color:#d6aa2f!important;
    color:#064a34!important;
}

/* ----- رأس الجدول: كل النص أبيض بما فيه التاريخ ----- */
#content.reports table#overview thead,
#content.reports table#overview thead tr,
#content.reports table#overview thead th{
    background:#163f2f!important;
    background-image:none!important;
}

#content.reports table#overview thead th,
#content.reports table#overview thead th.sent,
#content.reports table#overview thead th.dat,
#content.reports table#overview thead th a,
#content.reports table#overview thead th.sent a,
#content.reports table#overview thead th.dat a{
    color:#fff!important;
    opacity:1!important;
    filter:none!important;
    text-shadow:none!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-weight:700!important;
}

#content.reports table#overview thead th.sent,
#content.reports table#overview thead th.sent a{
    text-align:center!important;
}

/* تاريخ الصفوف أخضر غامق وواضح */
#content.reports table#overview td.dat{
    color:#0b5a40!important;
    opacity:1!important;
    font-weight:700!important;
    text-align:center!important;
    direction:rtl!important;
}

/* ----- أزرار أسفل التقارير: بدون صور English نهائياً ----- */
#content.reports table#overview tfoot th.buttons{
    text-align:center!important;
    white-space:nowrap!important;
}

#content.reports .cz-report-button{
    appearance:none!important;
    -webkit-appearance:none!important;
    min-width:90px!important;
    min-height:34px!important;
    margin:3px 5px!important;
    padding:0 13px!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:7px!important;
    border:1px solid #cba74d!important;
    border-radius:8px!important;
    background:#fff6df!important;
    background-image:none!important;
    color:#173a2b!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:11px!important;
    font-weight:700!important;
    line-height:1!important;
    cursor:pointer!important;
    box-sizing:border-box!important;
    box-shadow:none!important;
}

#content.reports .cz-report-button:hover{
    background:#f9e8bd!important;
    border-color:#b99131!important;
}

#content.reports .cz-report-button-icon{
    display:inline-flex!important;
    width:20px!important;
    height:20px!important;
    align-items:center!important;
    justify-content:center!important;
    border-radius:5px!important;
    color:#064a34!important;
    font-size:14px!important;
    font-weight:700!important;
}

#content.reports .cz-report-delete .cz-report-button-icon{
    color:#b92e22!important;
}

#content.reports .cz-report-archive .cz-report-button-icon{
    color:#80620e!important;
}

/* إلغاء أي قواعد قديمة لسبرایت delete/archive */
#content.reports input#btn_delete,
#content.reports input#btn_archiv,
#content.reports input#btn_back,
#content.reports .dynamic_img#btn_delete,
#content.reports .dynamic_img#btn_archiv,
#content.reports .dynamic_img#btn_back{
    display:none!important;
    background:none!important;
    background-image:none!important;
}

/* الجدول أقوى تبايناً مثل الرسائل */
#content.reports #overview{
    border-color:#cfc0aa!important;
    background:#fffdf9!important;
}

#content.reports #overview td{
    background:#fffdf9!important;
    color:#20372b!important;
    opacity:1!important;
}

#content.reports #overview tr:hover td{
    background:#f7eedf!important;
}

/* footer الأخضر */
#content.reports #overview tfoot th{
    background:#163f2f!important;
    color:#fff!important;
    border-color:#163f2f!important;
}

/* الأسهم */
#content.reports #overview tfoot th.navi,
#content.reports #overview tfoot th.navi a{
    color:#fff!important;
    font-weight:700!important;
    text-decoration:none!important;
}

/* قياس مناسب حتى 6 تبويبات ما تنزل */
@media(max-width:1100px){
    #content.reports{
        width:620px!important;
    }

    #content.reports .cz-report-tabs > a{
        font-size:9px!important;
        gap:3px!important;
        padding-left:2px!important;
        padding-right:2px!important;
    }

    #content.reports .cz-report-tabs > a .cz-tab-icon-box{
        width:23px!important;
        height:23px!important;
        flex-basis:23px!important;
    }
}

@media(max-width:900px){
    #content.reports .cz-report-tabs,
    #content.reports .cz-report-tabs.cz-six-tabs,
    #content.reports .cz-report-tabs.cz-five-tabs{
        grid-template-columns:repeat(2,minmax(0,1fr))!important;
    }
}


/* =========================================================
   مدينة الصفر v10 — القائمة يمين / مدير المهام يسار
   ========================================================= */

#mid{
    width:1080px!important;
    max-width:1080px!important;
    min-height:680px!important;
    margin:0 auto!important;
    padding-top:28px!important;
    position:relative!important;
    box-sizing:border-box!important;
    direction:rtl!important;
}

/* القائمة الجانبية الرئيسية على اليمين */
#side_navi.cz-side-menu-v8{
    position:absolute!important;
    top:28px!important;
    right:0!important;
    left:auto!important;
    float:none!important;
    width:185px!important;
    margin:0!important;
    padding:0!important;
    z-index:20!important;
}

/* المحتوى بالنص */
#content.messages,
#content.reports{
    float:none!important;
    width:630px!important;
    max-width:630px!important;
    margin:0 auto!important;
}

/* مدير المهام على اليسار */
#side_info,
#side_info.cz-task-panel{
    position:absolute!important;
    top:28px!important;
    left:0!important;
    right:auto!important;
    float:none!important;
    width:185px!important;
    margin:0!important;
    padding:0!important;
    z-index:25!important;
    background:transparent!important;
}

#side_info #qge,
#side_info.cz-task-panel #qge{
    position:static!important;
    width:100%!important;
    height:auto!important;
    min-height:0!important;
    margin:0!important;
    padding:0!important;
    background:none!important;
}

#side_info #anm,
#side_info.cz-task-panel #anm{
    right:auto!important;
    left:0!important;
}

#side_info .cz-task-button,
#side_info.cz-task-panel .cz-task-button{
    width:100%!important;
    min-height:98px!important;
    box-sizing:border-box!important;
}

/* اتجاه القائمة يمين الصفحة */
#side_navi.cz-side-menu-v8,
#side_navi.cz-side-menu-v8 .cz-profile-card,
#side_navi.cz-side-menu-v8 .cz-side-card{
    direction:rtl!important;
    text-align:right!important;
}

#side_navi.cz-side-menu-v8 .cz-side-card a{
    justify-content:flex-start!important;
}

/* إلغاء أي float قديم */
#side_navi,
#side_info{
    float:none!important;
}

/* الصفحات القديمة: لا نخلي المحتوى ينزاح خارج الوسط */
#content:not(.messages):not(.reports){
    position:relative!important;
    z-index:5!important;
    margin-left:auto!important;
    margin-right:auto!important;
}

/* شاشات متوسطة */
@media(max-width:1120px){
    #mid{
        width:1000px!important;
        max-width:1000px!important;
    }

    #side_navi.cz-side-menu-v8,
    #side_info,
    #side_info.cz-task-panel{
        width:170px!important;
    }

    #content.messages,
    #content.reports{
        width:610px!important;
        max-width:610px!important;
    }
}

/* شاشات صغيرة */
@media(max-width:900px){
    #mid{
        width:100%!important;
        max-width:100%!important;
        padding:16px!important;
        display:flex!important;
        flex-direction:column!important;
        gap:14px!important;
    }

    #side_navi.cz-side-menu-v8{
        position:static!important;
        width:100%!important;
        order:1!important;
    }

    #content.messages,
    #content.reports,
    #content{
        position:static!important;
        width:100%!important;
        max-width:100%!important;
        order:2!important;
        margin:0!important;
    }

    #side_info,
    #side_info.cz-task-panel{
        position:static!important;
        width:100%!important;
        order:3!important;
        margin:0!important;
    }
}


/* =========================================================
   مدينة الصفر v10.1 — إصلاح مدير المهام في التقارير فقط
   ========================================================= */

/*
   قالب التقارير كان يحتوي قاعدة أقدم ذات specificity أعلى
   ترجع side_info إلى اليمين. هذا override خاص بالتقارير فقط.
*/
body:has(#content.reports) #side_info.cz-task-panel,
body:has(#content.reports) #side_info{
    position:absolute!important;
    top:28px!important;
    left:0!important;
    right:auto!important;
    float:none!important;
    width:185px!important;
    margin:0!important;
    padding:0!important;
    z-index:30!important;
    background:transparent!important;
}

/* القائمة تبقى يمين صفحة التقارير */
body:has(#content.reports) #side_navi.cz-side-menu-v8{
    position:absolute!important;
    top:28px!important;
    right:0!important;
    left:auto!important;
    float:none!important;
    width:185px!important;
    margin:0!important;
}

/* محتوى التقارير ثابت في المنتصف */
body:has(#content.reports) #content.reports{
    float:none!important;
    width:630px!important;
    max-width:630px!important;
    margin-left:auto!important;
    margin-right:auto!important;
}

/* تثبيت جسم مدير المهام */
body:has(#content.reports) #side_info.cz-task-panel #qge{
    position:static!important;
    width:100%!important;
    height:auto!important;
    margin:0!important;
    padding:0!important;
}

@media(max-width:1120px){
    body:has(#content.reports) #side_info.cz-task-panel,
    body:has(#content.reports) #side_info,
    body:has(#content.reports) #side_navi.cz-side-menu-v8{
        width:170px!important;
    }

    body:has(#content.reports) #content.reports{
        width:610px!important;
        max-width:610px!important;
    }
}

@media(max-width:900px){
    body:has(#content.reports) #side_info.cz-task-panel,
    body:has(#content.reports) #side_info,
    body:has(#content.reports) #side_navi.cz-side-menu-v8{
        position:static!important;
        width:100%!important;
    }

    body:has(#content.reports) #content.reports{
        width:100%!important;
        max-width:100%!important;
    }
}

/* ========================= مدينة الصفر v11 — المزايا ========================= */
#content.plus,#content.cz-plus-page{float:none!important;width:630px!important;max-width:630px!important;min-height:620px!important;margin:0 auto!important;padding:22px!important;box-sizing:border-box!important;background:#fffdf9!important;border:1px solid #d8c9b3!important;border-radius:16px!important;box-shadow:0 10px 28px rgba(72,56,31,.10)!important;direction:rtl!important;text-align:right!important;font-family:Tahoma,Arial,sans-serif!important}
#content.plus h1{display:flex!important;align-items:center!important;justify-content:center!important;gap:9px!important;margin:0 0 16px!important;padding:0 0 13px!important;position:relative!important;border-bottom:1px solid #d2a02c!important;color:#064a34!important;font-size:29px!important;font-weight:700!important;font-family:Tahoma,Arial,sans-serif!important}
#content.plus h1:after{content:""!important;position:absolute!important;bottom:-4px!important;left:50%!important;width:8px!important;height:8px!important;transform:translateX(-50%) rotate(45deg)!important;background:#d2a02c!important}
#content.plus .cz-plus-tabs{display:grid!important;grid-template-columns:repeat(6,minmax(0,1fr))!important;gap:7px!important;width:100%!important;margin:0 0 18px!important;padding:7px!important;box-sizing:border-box!important;background:#f7f1e5!important;border:1px solid #d9cdb8!important;border-radius:12px!important;direction:rtl!important}
#content.plus .cz-plus-tabs>a{min-width:0!important;min-height:52px!important;padding:5px 4px!important;display:flex!important;align-items:center!important;justify-content:center!important;gap:5px!important;border:1px solid #dacdb8!important;border-radius:9px!important;background:#fffaf2!important;color:#173a2b!important;text-decoration:none!important;font-size:9.5px!important;font-weight:700!important;font-family:Tahoma,Arial,sans-serif!important}
#content.plus .cz-plus-tabs>a .cz-tab-icon-box{width:25px!important;height:25px!important;flex:0 0 25px!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;border:1px solid #ddcfae!important;border-radius:6px!important;background:#f3e6c7!important;color:#7c5d0e!important}
#content.plus .cz-plus-tabs>a.selected,#content.plus .cz-plus-tabs>a.cz-current,#content.plus .cz-plus-tabs>a.cz-tab-active{background:#064a34!important;border-color:#d0a22e!important;color:#fff!important;box-shadow:0 5px 13px rgba(6,74,52,.20)!important}
#content.plus .cz-plus-tabs>a.selected .cz-tab-icon-box,#content.plus .cz-plus-tabs>a.cz-current .cz-tab-icon-box,#content.plus .cz-plus-tabs>a.cz-tab-active .cz-tab-icon-box{background:#f1c84b!important;border-color:#d6aa2f!important;color:#064a34!important}
#content.plus table{direction:rtl!important;font-family:Tahoma,Arial,sans-serif!important}
#content.plus .rate_details,#content.plus .plusFunctions,#content.plus .features{width:100%!important;margin:16px 0!important;border:1px solid #d7c8b2!important;border-radius:12px!important;overflow:hidden!important;background:#fffdf9!important;border-collapse:separate!important;border-spacing:0!important}
#content.plus .rate_details thead th,#content.plus .plusFunctions thead th,#content.plus .features thead th{padding:11px 12px!important;background:#163f2f!important;color:#fff!important;font-size:12px!important;font-weight:700!important;text-align:right!important}
#content.plus .rate_details td,#content.plus .plusFunctions td,#content.plus .features td{padding:10px!important;background:#fffdf9!important;color:#25382f!important;border-color:#ece1d1!important;font-size:11px!important;line-height:1.7!important}
#content.plus .rate_details td.pic{width:135px!important;text-align:center!important}
#content.plus #products{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:12px!important;margin-top:16px!important;direction:rtl!important}
#content.plus #products table.product{float:none!important;width:100%!important;margin:0!important;border:1px solid #d7c8b2!important;border-radius:12px!important;overflow:hidden!important;background:#fffdf9!important;box-shadow:0 4px 12px rgba(65,50,28,.05)!important}
#content.plus #products table.product th{padding:9px!important;background:#163f2f!important;color:#fff!important;text-align:center!important}
#content.plus #products table.product td{padding:7px!important;text-align:center!important;color:#24372e!important}
#content.plus #products table.product a{color:#07583e!important;font-weight:700!important;text-decoration:none!important}
#content.plus .plusFunctions td.desc{text-align:right!important;line-height:1.75!important}
#content.plus .plusFunctions td.dur,#content.plus .plusFunctions td.cost,#content.plus .plusFunctions td.act{text-align:center!important;white-space:nowrap!important}
#content.plus .plusFunctions td.act a,#content.plus input[type="submit"],#content.plus input[type="button"]{display:inline-flex!important;align-items:center!important;justify-content:center!important;min-height:34px!important;padding:0 13px!important;border:1px solid #cba74d!important;border-radius:8px!important;background:#fff6df!important;color:#173a2b!important;font-family:Tahoma,Arial,sans-serif!important;font-size:11px!important;font-weight:700!important;text-decoration:none!important;cursor:pointer!important}
#content.plus input[type="text"],#content.plus input[type="email"],#content.plus textarea,#content.plus select{padding:8px 10px!important;border:1px solid #d3c5b2!important;border-radius:8px!important;background:#fffdf9!important;color:#24372e!important;font-family:Tahoma,Arial,sans-serif!important;direction:rtl!important}
body:has(#content.plus) #side_navi.cz-side-menu-v8{position:absolute!important;top:28px!important;right:0!important;left:auto!important;width:185px!important;float:none!important}
body:has(#content.plus) #side_info.cz-task-panel,body:has(#content.plus) #side_info{position:absolute!important;top:28px!important;left:0!important;right:auto!important;width:185px!important;float:none!important;margin:0!important}
@media(max-width:900px){#content.plus{width:100%!important;max-width:100%!important}#content.plus .cz-plus-tabs{grid-template-columns:repeat(2,minmax(0,1fr))!important}#content.plus #products{grid-template-columns:1fr!important}body:has(#content.plus) #side_navi.cz-side-menu-v8,body:has(#content.plus) #side_info.cz-task-panel,body:has(#content.plus) #side_info{position:static!important;width:100%!important}}

/* ================= مدينة الصفر v12 FINAL ================= */
#content.plus{line-height:1.75!important}
#content.plus .rate_details td,#content.plus .plusFunctions td,#content.plus .features td,#content.plus p,#content.plus li{color:#24372e!important;font-size:12px!important;line-height:1.8!important}
#content.plus .features tr:nth-child(even) td{background:#fbf7ef!important}
#content.plus h2,#content.plus h3{margin:16px 0 10px!important;color:#064a34!important}
.cz-account-statement{margin-top:16px!important;padding:18px!important;border:1px solid #d9cdb8!important;border-radius:12px!important;background:#fbf8f1!important}
.cz-account-statement h2{margin:0 0 14px!important;color:#064a34!important;font-size:22px!important}
.cz-account-intro{margin:0 0 16px!important;color:#667068!important;font-size:12px!important}
.cz-account-balance{display:flex!important;align-items:center!important;gap:12px!important;margin-bottom:16px!important;padding:14px!important;border:1px solid #d5c49e!important;border-radius:10px!important;background:#fff7df!important}
.cz-account-balance-icon{width:38px!important;height:38px!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;border-radius:50%!important;background:#f1c84b!important;color:#064a34!important;font-size:18px!important}
.cz-account-balance small{display:block!important;color:#746c5b!important;font-size:10px!important}.cz-account-balance strong{display:block!important;margin-top:3px!important;color:#064a34!important;font-size:17px!important}
.cz-account-info{border:1px solid #e0d4c3!important;border-radius:10px!important;overflow:hidden!important;background:#fff!important}
.cz-account-info h3{margin:0!important;padding:10px 12px!important;background:#163f2f!important;color:#fff!important;font-size:13px!important}
.cz-account-row{display:flex!important;align-items:center!important;justify-content:space-between!important;padding:10px 12px!important;border-top:1px solid #eee4d5!important;font-size:12px!important}
.cz-account-note{margin-top:14px!important;padding:11px 12px!important;border:1px solid #ead291!important;border-radius:9px!important;background:#fff9e8!important;color:#715b20!important;font-size:11px!important;line-height:1.7!important}


/* =========================================================
   مدينة الصفر v12.1 — تنسيق مميزات الذهب
   ========================================================= */

#content.plus .cz-gold-balance{
    margin:0 0 14px!important;
    padding:10px 13px!important;
    border:1px solid #e0c67d!important;
    border-radius:9px!important;
    background:#fff7df!important;
    color:#234435!important;
    font-size:12px!important;
    text-align:right!important;
}

#content.plus .cz-gold-balance b{
    color:#9a6a00!important;
    font-size:15px!important;
}

/* الجدول */
#content.plus table.plusFunctions.cz-gold-functions{
    width:100%!important;
    margin:14px 0 18px!important;
    border:1px solid #cfbea4!important;
    border-radius:12px!important;
    border-collapse:separate!important;
    border-spacing:0!important;
    overflow:hidden!important;
    background:#fffdf9!important;
    box-shadow:0 4px 12px rgba(62,48,28,.05)!important;
    direction:rtl!important;
    table-layout:fixed!important;
}

/* عنوان القسم */
#content.plus table.cz-gold-functions thead tr:first-child th{
    height:42px!important;
    padding:0 14px!important;
    background:#064a34!important;
    background-image:none!important;
    color:#fff!important;
    text-align:center!important;
    font-size:15px!important;
    font-weight:700!important;
    border:0!important;
}

#content.plus .cz-section-crown{
    color:#f2c54a!important;
    margin-left:7px!important;
    font-size:17px!important;
}

/* أسماء الأعمدة */
#content.plus table.cz-gold-functions thead tr:nth-child(2) td{
    height:38px!important;
    padding:7px 8px!important;
    background:#0b5940!important;
    color:#fff!important;
    border:0!important;
    border-left:1px solid rgba(255,255,255,.14)!important;
    text-align:center!important;
    font-size:11px!important;
    font-weight:700!important;
    opacity:1!important;
}

/* عرض الأعمدة */
#content.plus table.cz-gold-functions thead tr:nth-child(2) td:nth-child(1),
#content.plus table.cz-gold-functions tbody td.man{
    width:38px!important;
}

#content.plus table.cz-gold-functions thead tr:nth-child(2) td:nth-child(2),
#content.plus table.cz-gold-functions tbody td.desc{
    width:52%!important;
}

#content.plus table.cz-gold-functions thead tr:nth-child(2) td:nth-child(3),
#content.plus table.cz-gold-functions tbody td.dur{
    width:15%!important;
}

#content.plus table.cz-gold-functions thead tr:nth-child(2) td:nth-child(4),
#content.plus table.cz-gold-functions tbody td.cost{
    width:12%!important;
}

#content.plus table.cz-gold-functions thead tr:nth-child(2) td:nth-child(5),
#content.plus table.cz-gold-functions tbody td.act{
    width:15%!important;
}

/* الصفوف */
#content.plus table.cz-gold-functions tbody tr{
    height:58px!important;
}

#content.plus table.cz-gold-functions tbody td{
    padding:9px 10px!important;
    background:#fffdf9!important;
    color:#24382e!important;
    border:0!important;
    border-bottom:1px solid #e9dfcf!important;
    border-left:1px solid #eee4d6!important;
    vertical-align:middle!important;
    font-size:11px!important;
    line-height:1.55!important;
    opacity:1!important;
}

#content.plus table.cz-gold-functions tbody tr:nth-child(even) td{
    background:#fcf8f0!important;
}

#content.plus table.cz-gold-functions tbody tr:hover td{
    background:#fff6df!important;
}

/* إزالة صفوف الفصل البيضاء الكبيرة القديمة */
#content.plus table.cz-gold-functions tr:has(td.empty){
    display:none!important;
}

#content.plus table.cz-gold-functions td.empty{
    display:none!important;
    height:0!important;
    padding:0!important;
    border:0!important;
}

/* اسم الميزة */
#content.plus .cz-feature-name{
    display:inline-flex!important;
    align-items:center!important;
    gap:7px!important;
    color:#073f2e!important;
    font-size:12px!important;
    font-weight:700!important;
    opacity:1!important;
}

#content.plus .cz-feature-bonus{
    color:#a67300!important;
    font-size:13px!important;
    font-weight:700!important;
}

#content.plus .cz-feature-note{
    display:inline-block!important;
    margin-top:3px!important;
    color:#616e66!important;
    font-size:10px!important;
    font-weight:400!important;
}

/* النص المتبقي/المدة */
#content.plus table.cz-gold-functions .run,
#content.plus table.cz-gold-functions .run font{
    color:#728078!important;
    font-size:9.5px!important;
    opacity:1!important;
}

#content.plus table.cz-gold-functions td.dur{
    color:#24483a!important;
    text-align:center!important;
    font-weight:700!important;
}

/* الذهب: أقوى وأوضح */
#content.plus table.cz-gold-functions td.cost{
    color:#8d6100!important;
    text-align:center!important;
    font-size:14px!important;
    font-weight:700!important;
    opacity:1!important;
}

#content.plus table.cz-gold-functions td.cost img.gold{
    margin-left:4px!important;
    vertical-align:middle!important;
}

/* علامة المساعدة */
#content.plus table.cz-gold-functions td.man{
    text-align:center!important;
    border-left:0!important;
}

#content.plus table.cz-gold-functions td.man .help{
    opacity:.85!important;
}

/* أزرار الإجراء */
#content.plus table.cz-gold-functions td.act{
    text-align:center!important;
}

#content.plus table.cz-gold-functions td.act > span,
#content.plus table.cz-gold-functions td.act a{
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    min-width:84px!important;
    min-height:34px!important;
    padding:0!important;
    margin:0!important;
    border-radius:8px!important;
    text-decoration:none!important;
    font-size:11px!important;
    font-weight:700!important;
    box-sizing:border-box!important;
}

#content.plus table.cz-gold-functions td.act a{
    padding:0 12px!important;
    border:1px solid #caa548!important;
    background:#fff7e1!important;
    color:#074932!important;
}

#content.plus table.cz-gold-functions td.act a:hover{
    background:#f7e7b9!important;
    border-color:#b58924!important;
}

#content.plus table.cz-gold-functions td.act span.none{
    color:#c13b2d!important;
}

#content.plus table.cz-gold-functions td.act span.active{
    color:#07834d!important;
}

/* نادي الذهب أكثر وضوحاً */
#content.plus table.cz-gold-functions:last-of-type tbody td.desc .cz-feature-name{
    color:#795600!important;
}

#content.plus table.cz-gold-functions:last-of-type td.cost{
    color:#9a6800!important;
}

/* لا تجعل الكلمات باهتة بسبب CSS القديم */
#content.plus table.cz-gold-functions b,
#content.plus table.cz-gold-functions strong,
#content.plus table.cz-gold-functions span{
    opacity:1!important;
}

/* ضبط على الشاشة الحالية */
@media(max-width:1100px){
    #content.plus table.cz-gold-functions tbody td{
        padding-left:7px!important;
        padding-right:7px!important;
    }

    #content.plus table.cz-gold-functions td.act a{
        min-width:72px!important;
        padding:0 8px!important;
        font-size:10px!important;
    }
}


/* =========================================================
   مدينة الصفر v12.2 — إصلاحات المزايا النهائية
   1) صور المزايا يسار والنص يمين
   2) حالة إنتاج القمح داخل مربع مثل باقي الأزرار
   3) تبويبات Plus غير باهتة
   ========================================================= */

/* ---------- تبويبات المزايا: نص واضح وقوي ---------- */
#content.plus .cz-plus-tabs > a{
    color:#173f30!important;
    opacity:1!important;
    filter:none!important;
    text-shadow:none!important;
    background:#fffaf0!important;
    border-color:#d8c8ad!important;
}

#content.plus .cz-plus-tabs > a .cz-tab-label,
#content.plus .cz-plus-tabs > a span.cz-tab-label{
    color:#173f30!important;
    opacity:1!important;
    filter:none!important;
    font-weight:700!important;
    text-shadow:none!important;
}

#content.plus .cz-plus-tabs > a .cz-tab-icon-box{
    opacity:1!important;
    filter:none!important;
    background:#f1e5c8!important;
    color:#765a0d!important;
    border-color:#ddcca7!important;
}

/* المحدد يبقى أخضر بخط أبيض واضح */
#content.plus .cz-plus-tabs > a.selected,
#content.plus .cz-plus-tabs > a.cz-current,
#content.plus .cz-plus-tabs > a.cz-tab-active{
    background:#064a34!important;
    color:#ffffff!important;
    opacity:1!important;
}

#content.plus .cz-plus-tabs > a.selected .cz-tab-label,
#content.plus .cz-plus-tabs > a.cz-current .cz-tab-label,
#content.plus .cz-plus-tabs > a.cz-tab-active .cz-tab-label{
    color:#ffffff!important;
    opacity:1!important;
    font-weight:700!important;
}

#content.plus .cz-plus-tabs > a.selected .cz-tab-icon-box,
#content.plus .cz-plus-tabs > a.cz-current .cz-tab-icon-box,
#content.plus .cz-plus-tabs > a.cz-tab-active .cz-tab-icon-box{
    background:#f1c84b!important;
    color:#064a34!important;
    opacity:1!important;
}

/* ---------- صفحة المزايا id=2 ---------- */
/*
   القالب القديم مبني بجدول: صورة + وصف.
   نعكس اتجاه الصف نفسه إلى LTR حتى الصورة تصبح فعلياً يسار،
   ثم نرجع النص داخل خلية الوصف إلى RTL ومحاذاة يمين.
*/
#content.plus table.cz-advantages-table{
    width:100%!important;
    direction:ltr!important;
    table-layout:fixed!important;
    border-collapse:separate!important;
    border-spacing:0!important;
}

#content.plus table.cz-advantages-table tr{
    direction:ltr!important;
}

/* خلية الصورة: يسار */
#content.plus table.cz-advantages-table td.pic,
#content.plus table.cz-advantages-table td:first-child:has(img),
#content.plus table.cz-advantages-table td:has(> img){
    width:34%!important;
    text-align:center!important;
    vertical-align:middle!important;
    direction:ltr!important;
    padding:14px!important;
}

/* خلية الشرح: يمين */
#content.plus table.cz-advantages-table td.desc,
#content.plus table.cz-advantages-table td:not(.pic){
    direction:rtl!important;
    text-align:right!important;
    vertical-align:middle!important;
    color:#233a2f!important;
    opacity:1!important;
    line-height:1.85!important;
}

/* العنوان الخاص بكل ميزة يبقى فوق النص وواضح */
#content.plus table.cz-advantages-table th,
#content.plus table.cz-advantages-table td.title{
    direction:rtl!important;
    text-align:right!important;
    color:#073f2e!important;
    font-weight:700!important;
    opacity:1!important;
}

/* الصور لا تلتصق بالنص */
#content.plus table.cz-advantages-table img{
    display:block!important;
    max-width:190px!important;
    height:auto!important;
    margin:0 auto!important;
}

/* ---------- صفحة الذهب id=3: مربع الحالة النشطة ---------- */
#content.plus table.cz-gold-functions td.act .cz-action-box{
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    min-width:84px!important;
    min-height:34px!important;
    padding:0 12px!important;
    margin:0!important;
    box-sizing:border-box!important;
    border:1px solid #7db88d!important;
    border-radius:8px!important;
    background:#f4fff5!important;
    color:#087b43!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:11px!important;
    font-weight:700!important;
    line-height:1!important;
}

/* أي active قديم داخل عمود الإجراء يأخذ نفس الصندوق حتى لو القالب لم يضف hook */
#content.plus table.cz-gold-functions td.act > span.active{
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    min-width:84px!important;
    min-height:34px!important;
    padding:0 12px!important;
    box-sizing:border-box!important;
    border:1px solid #7db88d!important;
    border-radius:8px!important;
    background:#f4fff5!important;
    color:#087b43!important;
    font-weight:700!important;
}

/* لا تخلي القمح أو أي مورد يظهر كنص أخضر مجرد */
#content.plus table.cz-gold-functions td.act{
    min-width:105px!important;
    text-align:center!important;
    vertical-align:middle!important;
}

@media(max-width:900px){
    #content.plus table.cz-advantages-table,
    #content.plus table.cz-advantages-table tr{
        direction:rtl!important;
    }

    #content.plus table.cz-advantages-table td.pic,
    #content.plus table.cz-advantages-table td:has(> img){
        width:auto!important;
    }
}


/* =========================================================
   مدينة الصفر v12.3 — إصلاح دقيق حسب بنية القوالب الأصلية
   ========================================================= */

/* ---------------------------------------------------------
   صفحة المزايا id=2
   الجدول الحقيقي: #plus_features
   الصورة: td.preview
   النص: td.text
   --------------------------------------------------------- */

/* Force physical column order: image LEFT, text RIGHT */
#content.plus table#plus_features{
    width:100%!important;
    direction:ltr!important;
    table-layout:fixed!important;
    border-collapse:separate!important;
    border-spacing:0!important;
}

/* Feature title rows remain Arabic RTL */
#content.plus table#plus_features th{
    direction:rtl!important;
    text-align:center!important;
    color:#073f2e!important;
    font-weight:700!important;
    opacity:1!important;
}

/* IMAGE CELL = LEFT */
#content.plus table#plus_features td.preview{
    width:35%!important;
    direction:ltr!important;
    text-align:center!important;
    vertical-align:middle!important;
    padding:14px 16px!important;
    order:1!important;
}

/* TEXT CELL = RIGHT */
#content.plus table#plus_features td.text{
    width:65%!important;
    direction:rtl!important;
    text-align:right!important;
    vertical-align:middle!important;
    padding:14px 18px!important;
    color:#203a2e!important;
    font-size:12px!important;
    line-height:1.95!important;
    opacity:1!important;
    order:2!important;
}

/* Use flex on actual two-cell content rows so browser RTL cannot flip them */
#content.plus table#plus_features tbody tr:has(td.preview):has(td.text){
    display:flex!important;
    flex-direction:row!important;
    width:100%!important;
    direction:ltr!important;
}

#content.plus table#plus_features tbody tr:has(td.preview):has(td.text) td.preview{
    flex:0 0 35%!important;
    box-sizing:border-box!important;
}

#content.plus table#plus_features tbody tr:has(td.preview):has(td.text) td.text{
    flex:1 1 65%!important;
    box-sizing:border-box!important;
}

#content.plus table#plus_features td.preview img{
    display:block!important;
    max-width:190px!important;
    height:auto!important;
    margin:0 auto!important;
}

/* empty/title rows stay full width */
#content.plus table#plus_features tr:has(td.empty),
#content.plus table#plus_features tr:has(th[colspan="2"]){
    display:table-row!important;
}

/* ---------------------------------------------------------
   صفحة الذهب id=3
   Wheat row now has td.act; force same button presentation
   --------------------------------------------------------- */
#content.plus table.cz-gold-functions td.act{
    text-align:center!important;
    vertical-align:middle!important;
}

#content.plus table.cz-gold-functions td.act > a{
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    min-width:90px!important;
    min-height:36px!important;
    padding:0 12px!important;
    border:1px solid #caa548!important;
    border-radius:8px!important;
    background:#fff7e1!important;
    color:#074932!important;
    font-size:11px!important;
    font-weight:700!important;
    text-decoration:none!important;
    box-sizing:border-box!important;
}

#content.plus table.cz-gold-functions td.act > a > span{
    display:inline!important;
    min-width:0!important;
    min-height:0!important;
    padding:0!important;
    border:0!important;
    background:transparent!important;
    color:inherit!important;
}

/* active/plain state also boxed */
#content.plus table.cz-gold-functions td.act > span.active,
#content.plus table.cz-gold-functions td.act > span.cz-action-box{
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    min-width:90px!important;
    min-height:36px!important;
    padding:0 12px!important;
    border:1px solid #77b58a!important;
    border-radius:8px!important;
    background:#f2fff5!important;
    color:#087b43!important;
    font-size:11px!important;
    font-weight:700!important;
    box-sizing:border-box!important;
}

/* ---------------------------------------------------------
   Tabs — final strong contrast
   --------------------------------------------------------- */
#content.plus .cz-plus-tabs > a:not(.selected):not(.cz-current):not(.cz-tab-active),
#content.plus .cz-plus-tabs > a:not(.selected):not(.cz-current):not(.cz-tab-active) .cz-tab-label{
    color:#123b2a!important;
    opacity:1!important;
    font-weight:700!important;
    filter:none!important;
    text-shadow:none!important;
}



/* =========================================================
   مدينة الصفر v12.4 — إعادة ضبط صفحة المزايا
   صف كامل / نص يمين / صورة يسار / بدون انكماش
   ========================================================= */

/* ألغِ flex القديم الذي سبّب انهيار الجدول */
#content.plus table#plus_features tbody tr:has(td.preview):has(td.text){
    display:table-row!important;
    width:auto!important;
    direction:ltr!important;
}

/* الجدول بعرض كامل وثابت */
#content.plus table#plus_features{
    display:table!important;
    width:100%!important;
    min-width:100%!important;
    table-layout:fixed!important;
    border-collapse:collapse!important;
    border-spacing:0!important;
    direction:ltr!important;
    background:#fffdf9!important;
}

/* كل صف محتوى يأخذ عرض الجدول كامل */
#content.plus table#plus_features tbody{
    display:table-row-group!important;
    width:100%!important;
}

#content.plus table#plus_features tr{
    display:table-row!important;
    width:auto!important;
}

/* خلية الصورة: يسار وثابتة */
#content.plus table#plus_features td.preview{
    display:table-cell!important;
    width:34%!important;
    min-width:34%!important;
    max-width:34%!important;
    padding:18px 16px!important;
    box-sizing:border-box!important;
    direction:ltr!important;
    text-align:center!important;
    vertical-align:middle!important;
    background:#fbf8f1!important;
    border-bottom:1px solid #e7dccb!important;
}

/* خلية النص: يمين وتأخذ الباقي */
#content.plus table#plus_features td.text{
    display:table-cell!important;
    width:66%!important;
    min-width:66%!important;
    max-width:66%!important;
    padding:18px 22px!important;
    box-sizing:border-box!important;
    direction:rtl!important;
    text-align:right!important;
    vertical-align:middle!important;
    background:#fffdf9!important;
    color:#203a2e!important;
    font-size:12px!important;
    line-height:2!important;
    opacity:1!important;
    border-bottom:1px solid #e7dccb!important;
}

/* صورة الميزة */
#content.plus table#plus_features td.preview img{
    display:block!important;
    max-width:180px!important;
    width:auto!important;
    height:auto!important;
    max-height:135px!important;
    margin:0 auto!important;
    object-fit:contain!important;
}

/* بعض الصور القديمة عريضة؛ امنعها من قص الصف */
#content.plus table#plus_features td.preview img[width],
#content.plus table#plus_features td.preview img[height]{
    max-width:180px!important;
    max-height:135px!important;
}

/* عنوان كل ميزة بعرض كامل وواضح */
#content.plus table#plus_features th,
#content.plus table#plus_features tr > td[colspan="2"],
#content.plus table#plus_features tr > th[colspan="2"]{
    display:table-cell!important;
    width:auto!important;
    padding:10px 14px!important;
    direction:rtl!important;
    text-align:center!important;
    background:#f0f2ef!important;
    color:#073f2e!important;
    font-size:12px!important;
    font-weight:700!important;
    line-height:1.5!important;
    border-bottom:1px solid #e0e4df!important;
}

/* إزالة المسافات العمودية المبالغ بها */
#content.plus table#plus_features td.empty{
    height:12px!important;
    min-height:12px!important;
    padding:0!important;
    background:#f7f2e9!important;
    border:0!important;
}

#content.plus table#plus_features tr:has(td.empty){
    display:table-row!important;
    height:12px!important;
}

/* أول هيدر أخضر مضبوط */
#content.plus table#plus_features thead th,
#content.plus table#plus_features tr:first-child th{
    background:#163f2f!important;
    color:#fff!important;
    font-size:13px!important;
    text-align:center!important;
    padding:11px 14px!important;
}

/* كلمة Plus داخل العنوان لا تكون صارخة/منفصلة */
#content.plus table#plus_features thead th font,
#content.plus table#plus_features thead th span{
    color:#f1c84b!important;
    font-weight:700!important;
}

/* تحسين الفقرات */
#content.plus table#plus_features td.text p{
    margin:0!important;
    padding:0!important;
    color:#203a2e!important;
    text-align:right!important;
    line-height:2!important;
}

/* الشاشات الصغيرة */
@media(max-width:900px){
    #content.plus table#plus_features{
        table-layout:auto!important;
    }

    #content.plus table#plus_features td.preview{
        width:32%!important;
        min-width:32%!important;
        max-width:32%!important;
        padding:12px!important;
    }

    #content.plus table#plus_features td.text{
        width:68%!important;
        min-width:68%!important;
        max-width:68%!important;
        padding:14px!important;
    }

    #content.plus table#plus_features td.preview img{
        max-width:130px!important;
        max-height:100px!important;
    }
}


/* =========================================================
   مدينة الصفر v12.5 — استرجاع صور صفحة المزايا
   ========================================================= */

/*
   إلغاء التخطيط السابق الذي أخفى خلايا الصور.
   نستخدم ترتيب الجدول الطبيعي ونغيّر اتجاه الصف فقط.
*/
#content.plus table#plus_features{
    display:table!important;
    width:100%!important;
    table-layout:fixed!important;
    border-collapse:collapse!important;
    direction:ltr!important;
}

#content.plus table#plus_features tbody{
    display:table-row-group!important;
}

#content.plus table#plus_features tr{
    display:table-row!important;
}

/* الصورة تظهر فعلياً في العمود الأيسر */
#content.plus table#plus_features td.preview{
    display:table-cell!important;
    visibility:visible!important;
    opacity:1!important;
    width:34%!important;
    min-width:34%!important;
    max-width:34%!important;
    height:auto!important;
    padding:16px!important;
    direction:ltr!important;
    text-align:center!important;
    vertical-align:middle!important;
    background:#fbf8f1!important;
    overflow:visible!important;
}

/* النص على اليمين */
#content.plus table#plus_features td.text{
    display:table-cell!important;
    visibility:visible!important;
    opacity:1!important;
    width:66%!important;
    min-width:66%!important;
    max-width:66%!important;
    padding:16px 20px!important;
    direction:rtl!important;
    text-align:right!important;
    vertical-align:middle!important;
    background:#fffdf9!important;
    color:#203a2e!important;
    line-height:1.9!important;
}

/* إجبار جميع صور preview على الظهور */
#content.plus table#plus_features td.preview img{
    display:inline-block!important;
    visibility:visible!important;
    opacity:1!important;
    position:static!important;
    float:none!important;
    width:auto!important;
    height:auto!important;
    max-width:190px!important;
    max-height:140px!important;
    margin:0 auto!important;
    object-fit:contain!important;
}

/* بعض الصور القديمة تكون داخل div أو span */
#content.plus table#plus_features td.preview div,
#content.plus table#plus_features td.preview span{
    display:block!important;
    visibility:visible!important;
    opacity:1!important;
    position:static!important;
}

/* العناوين بعرض كامل */
#content.plus table#plus_features th,
#content.plus table#plus_features tr > td[colspan="2"],
#content.plus table#plus_features tr > th[colspan="2"]{
    display:table-cell!important;
    direction:rtl!important;
    text-align:center!important;
}

/* لا نخفي أي خلية preview بسبب قواعد :has السابقة */
#content.plus table#plus_features tr:has(td.preview):has(td.text){
    display:table-row!important;
    flex-direction:unset!important;
}

#content.plus table#plus_features tr:has(td.preview):has(td.text) td.preview,
#content.plus table#plus_features tr:has(td.preview):has(td.text) td.text{
    flex:none!important;
}

/* احتياط للصور التي قد تكون background-image */
#content.plus table#plus_features td.preview{
    background-repeat:no-repeat!important;
    background-position:center!important;
    background-size:contain!important;
}



/* =========================================================
   مدينة الصفر v12.6 — FINAL ADVANTAGES IMAGE FIX
   استرجاع صور الـ sprite + توحيد خلفية الصف
   ========================================================= */

/* التخطيط النهائي */
#content.plus table#plus_features{
    width:100%!important;
    table-layout:fixed!important;
    border-collapse:collapse!important;
    direction:ltr!important;
    background:#fffaf2!important;
}

#content.plus table#plus_features tr{
    display:table-row!important;
}

/* الصورة يسار */
#content.plus table#plus_features td.preview{
    display:table-cell!important;
    width:35%!important;
    min-width:35%!important;
    max-width:35%!important;
    padding:16px!important;
    direction:ltr!important;
    text-align:center!important;
    vertical-align:middle!important;
    background:#fffaf2!important;
    border-bottom:1px solid #eadfce!important;
    visibility:visible!important;
    opacity:1!important;
}

/* النص يمين وبنفس اللون، بدون الأبيض المختلف */
#content.plus table#plus_features td.text{
    display:table-cell!important;
    width:65%!important;
    min-width:65%!important;
    max-width:65%!important;
    padding:16px 20px!important;
    direction:rtl!important;
    text-align:right!important;
    vertical-align:middle!important;
    background:#fffaf2!important;
    color:#203a2e!important;
    border-bottom:1px solid #eadfce!important;
    font-size:12px!important;
    line-height:1.95!important;
    visibility:visible!important;
    opacity:1!important;
}

/* لا نغيّر أبعاد sprite إلى auto */
#content.plus table#plus_features td.preview img{
    display:inline-block!important;
    visibility:visible!important;
    opacity:1!important;
    position:static!important;
    float:none!important;
    margin:0 auto!important;
    padding:0!important;
    border:0!important;
    max-width:none!important;
    max-height:none!important;
    object-fit:initial!important;
    background-repeat:no-repeat!important;
    background-position:0 0!important;
}

/* تعريفات الصور الأصلية — المسار محسوب من modules/cityzero_v2.css */
#content.plus table#plus_features td.preview img.p1{
    width:179px!important;
    height:29px!important;
    background-image:url("../img/p/p1.gif")!important;
}

#content.plus table#plus_features td.preview img.xxl_map{
    width:146px!important;
    height:112px!important;
    background-image:url("../img/p/xxl_map.gif")!important;
}

#content.plus table#plus_features td.preview img.att_mark{
    width:200px!important;
    height:100px!important;
    background-image:url("../img/p/attack_marker.gif")!important;
}

#content.plus table#plus_features td.preview img.p5{
    width:132px!important;
    height:51px!important;
    background-image:url("../img/p/p5.gif")!important;
}

#content.plus table#plus_features td.preview img.sort{
    width:200px!important;
    height:38px!important;
    background-image:url("../img/p/sort.jpg")!important;
}

#content.plus table#plus_features td.preview img.p6{
    width:111px!important;
    height:29px!important;
    background-image:url("../img/p/p6.gif")!important;
}

#content.plus table#plus_features td.preview img.autovv{
    width:200px!important;
    height:56px!important;
    background-image:url("../img/p/autovv.gif")!important;
}

#content.plus table#plus_features td.preview img.bfilter{
    width:200px!important;
    height:45px!important;
    background-image:url("../img/p/bfilter.gif")!important;
}

#content.plus table#plus_features td.preview img.p7{
    width:61px!important;
    height:86px!important;
    background-image:url("../img/p/p7.gif")!important;
}

#content.plus table#plus_features td.preview img.st1{
    width:200px!important;
    height:90px!important;
    background-image:url("../img/p/st1.gif")!important;
}

#content.plus table#plus_features td.preview img.dorf3{
    width:200px!important;
    height:186px!important;
    background-image:url("../img/p/dorf3.jpg")!important;
}

#content.plus table#plus_features td.preview img.p8{
    width:117px!important;
    height:121px!important;
    background-image:url("../img/p/p8.gif")!important;
}

/* صور ميزات الذهب الموجودة أسفل صفحة المزايا */
#content.plus table#plus_features td.preview img.p1_25{
    width:150px!important;
    height:150px!important;
    background-image:url("../img/p/p1_25.jpg")!important;
}

#content.plus table#plus_features td.preview img.p2_25{
    width:150px!important;
    height:150px!important;
    background-image:url("../img/p/p2_25.jpg")!important;
}

#content.plus table#plus_features td.preview img.p3_25{
    width:150px!important;
    height:150px!important;
    background-image:url("../img/p/p3_25.jpg")!important;
}

#content.plus table#plus_features td.preview img.p4_25{
    width:150px!important;
    height:150px!important;
    background-image:url("../img/p/p4_25.jpg")!important;
}

#content.plus table#plus_features td.preview img.bau0{
    width:150px!important;
    height:150px!important;
    background-image:url("../img/p/bau0.jpg")!important;
}

#content.plus table#plus_features td.preview img.npc{
    width:150px!important;
    height:150px!important;
    background-image:url("../img/p/npc.jpg")!important;
}

/* عنوان كل ميزة */
#content.plus table#plus_features tbody th{
    background:#eef1ed!important;
    color:#073f2e!important;
    text-align:center!important;
    direction:rtl!important;
    padding:10px 14px!important;
    font-size:12px!important;
    font-weight:700!important;
    border-bottom:1px solid #dde3dc!important;
}

/* الفراغ الفاصل بين المزايا يكون بنفس لوحة الألوان */
#content.plus table#plus_features td.empty{
    height:12px!important;
    padding:0!important;
    background:#f5efe4!important;
    border:0!important;
}

/* إلغاء أي flex متراكم من النسخ السابقة */
#content.plus table#plus_features tr:has(td.preview):has(td.text){
    display:table-row!important;
    flex-direction:unset!important;
}

#content.plus table#plus_features tr:has(td.preview):has(td.text) td.preview,
#content.plus table#plus_features tr:has(td.preview):has(td.text) td.text{
    flex:none!important;
}

/* الهيدر */
#content.plus table#plus_features thead th,
#content.plus table#plus_features tr:first-child th{
    background:#163f2f!important;
    color:#fff!important;
    padding:11px 14px!important;
    text-align:center!important;
}



/* =========================================================
   مدينة الصفر v12.7 — جميع صور المزايا من مجلد محلي ثابت
   ========================================================= */

/*
   الصور القديمة موزعة بين lang/en/p و img/p.
   هذه النسخة تستخدم مجلداً واحداً داخل modules حتى لا تضيع أي صورة.
*/

#content.plus table#plus_features td.preview img{
    display:inline-block!important;
    visibility:visible!important;
    opacity:1!important;
    position:static!important;
    float:none!important;
    margin:0 auto!important;
    padding:0!important;
    border:0!important;
    background-repeat:no-repeat!important;
    background-position:center center!important;
    background-color:transparent!important;
}

/* حساب Plus / قائمة انتظار البناء */
#content.plus table#plus_features td.preview img.p1{
    width:179px!important;
    height:29px!important;
    background-image:url("cityzero_plus_images/p1.gif")!important;
}

/* الخريطة الكبيرة */
#content.plus table#plus_features td.preview img.xxl_map{
    width:146px!important;
    height:112px!important;
    background-image:url("cityzero_plus_images/xxl_map.gif")!important;
}

/* نقطة التجمع */
#content.plus table#plus_features td.preview img.att_mark{
    width:200px!important;
    height:100px!important;
    background-image:url("cityzero_plus_images/attack_marker.gif")!important;
}

/* أرشفة الرسائل والتقارير */
#content.plus table#plus_features td.preview img.p5{
    width:132px!important;
    height:51px!important;
    background-image:url("cityzero_plus_images/p5.gif")!important;
}

/* الفرز */
#content.plus table#plus_features td.preview img.sort{
    width:200px!important;
    height:38px!important;
    background-image:url("cityzero_plus_images/sort.jpg")!important;
}

/* السوق */
#content.plus table#plus_features td.preview img.p6{
    width:111px!important;
    height:29px!important;
    background-image:url("cityzero_plus_images/p6.gif")!important;
}

/* الإكمال التلقائي */
#content.plus table#plus_features td.preview img.autovv{
    width:200px!important;
    height:56px!important;
    background-image:url("cityzero_plus_images/autovv.gif")!important;
}

/* فلترة التقارير */
#content.plus table#plus_features td.preview img.bfilter{
    width:200px!important;
    height:45px!important;
    background-image:url("cityzero_plus_images/bfilter.gif")!important;
}

/* الروابط المباشرة */
#content.plus table#plus_features td.preview img.p7{
    width:61px!important;
    height:86px!important;
    background-image:url("cityzero_plus_images/p7.gif")!important;
}

/* الإحصائيات */
#content.plus table#plus_features td.preview img.st1{
    width:200px!important;
    height:90px!important;
    background-image:url("cityzero_plus_images/st1.gif")!important;
}

/* نظرة القرى */
#content.plus table#plus_features td.preview img.dorf3{
    width:200px!important;
    height:186px!important;
    background-image:url("cityzero_plus_images/dorf3.jpg")!important;
}

/* الملاحظات */
#content.plus table#plus_features td.preview img.p8{
    width:117px!important;
    height:121px!important;
    background-image:url("cityzero_plus_images/p8.gif")!important;
}

/* زيادة إنتاج الخشب */
#content.plus table#plus_features td.preview img.p1_25{
    width:150px!important;
    height:150px!important;
    background-image:url("cityzero_plus_images/p1_25.jpg")!important;
}

/* زيادة إنتاج الطين */
#content.plus table#plus_features td.preview img.p2_25{
    width:150px!important;
    height:150px!important;
    background-image:url("cityzero_plus_images/p2_25.jpg")!important;
}

/* زيادة إنتاج الحديد */
#content.plus table#plus_features td.preview img.p3_25{
    width:150px!important;
    height:150px!important;
    background-image:url("cityzero_plus_images/p3_25.jpg")!important;
}

/* زيادة إنتاج القمح */
#content.plus table#plus_features td.preview img.p4_25{
    width:150px!important;
    height:150px!important;
    background-image:url("cityzero_plus_images/p4_25.jpg")!important;
}

/* الإكمال الفوري */
#content.plus table#plus_features td.preview img.bau0{
    width:150px!important;
    height:150px!important;
    background-image:url("cityzero_plus_images/bau0.jpg")!important;
}

/* تاجر الموارد */
#content.plus table#plus_features td.preview img.npc{
    width:150px!important;
    height:150px!important;
    background-image:url("cityzero_plus_images/npc.jpg")!important;
}

/* توحيد لون العمودين */
#content.plus table#plus_features td.preview,
#content.plus table#plus_features td.text{
    background:#fffaf2!important;
}


/* =========================================================
   مدينة الصفر v13.5 CLEAN — الترتيب
   نسخة واحدة بدون أي تعارضات جانبية
   ========================================================= */

/*
   مهم:
   لا توجد هنا أي قواعد تحرك #side_navi أو #side_info.
   القائمة اليمنى ومدير المهام يستخدمان تخطيط اللعبة العام
   نفسه المستعمل في الرسائل والتقارير.
*/

/* بطاقة الترتيب */
#content.statistics,
#content.cz-ranking-page{
    float:none!important;
    width:630px!important;
    max-width:630px!important;
    min-height:540px!important;
    margin:0 auto!important;
    padding:22px!important;
    box-sizing:border-box!important;
    direction:rtl!important;
    text-align:right!important;
    background:#fffdf9!important;
    border:1px solid #d8c9b3!important;
    border-radius:16px!important;
    box-shadow:0 10px 28px rgba(72,56,31,.10)!important;
    font-family:Tahoma,Arial,sans-serif!important;
    overflow:visible!important;
}

/* عنوان الصفحة */
#content.statistics h1{
    position:relative!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:9px!important;
    margin:0 0 17px!important;
    padding:0 0 13px!important;
    border-bottom:1px solid #d2a02c!important;
    color:#064a34!important;
    font-size:29px!important;
    font-weight:700!important;
    line-height:1.2!important;
}

#content.statistics h1:after{
    content:""!important;
    position:absolute!important;
    bottom:-4px!important;
    left:50%!important;
    width:8px!important;
    height:8px!important;
    transform:translateX(-50%) rotate(45deg)!important;
    background:#d2a02c!important;
}

#content.statistics .cz-title-icon{
    width:36px!important;
    height:36px!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    border-radius:9px!important;
    background:#f3e8cb!important;
    color:#89670c!important;
    font-size:17px!important;
}

/* التبويبات الرئيسية */
#content.statistics .cz-ranking-tabs{
    display:grid!important;
    grid-template-columns:repeat(5,minmax(0,1fr))!important;
    gap:7px!important;
    width:100%!important;
    margin:0 0 18px!important;
    padding:7px!important;
    box-sizing:border-box!important;
    direction:rtl!important;
    background:#f7f1e5!important;
    border:1px solid #d9cdb8!important;
    border-radius:12px!important;
}

#content.statistics .cz-ranking-tabs > a{
    min-width:0!important;
    min-height:56px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:6px!important;
    padding:6px 5px!important;
    box-sizing:border-box!important;
    border:1px solid #dacdb8!important;
    border-radius:9px!important;
    background:#fffaf2!important;
    color:#173f30!important;
    text-decoration:none!important;
    font-size:11px!important;
    font-weight:700!important;
    opacity:1!important;
    overflow:hidden!important;
}

#content.statistics .cz-ranking-tabs > a:hover{
    background:#fff3d7!important;
    border-color:#c5a348!important;
}

#content.statistics .cz-ranking-tabs > a.selected,
#content.statistics .cz-ranking-tabs > a.cz-current{
    background:#064a34!important;
    border-color:#d0a22e!important;
    color:#fff!important;
    box-shadow:0 5px 13px rgba(6,74,52,.18)!important;
}

#content.statistics .cz-rank-tab-icon{
    width:27px!important;
    height:27px!important;
    flex:0 0 27px!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    border:1px solid #ddcfae!important;
    border-radius:6px!important;
    background:#f1e5c8!important;
    color:#775b0e!important;
    font-size:13px!important;
    line-height:1!important;
}

#content.statistics .cz-ranking-tabs > a.selected .cz-rank-tab-icon,
#content.statistics .cz-ranking-tabs > a.cz-current .cz-rank-tab-icon{
    background:#f1c84b!important;
    border-color:#d3a62e!important;
    color:#064a34!important;
}

/* ---------------- Top 10 toolbar ---------------- */
#content.statistics .cz-top10-panel{
    width:100%!important;
    margin:0 0 17px!important;
    border:1px solid #d7c8b1!important;
    border-radius:12px!important;
    overflow:hidden!important;
    direction:rtl!important;
    background:#fffaf2!important;
    box-shadow:0 4px 12px rgba(62,48,28,.05)!important;
}

#content.statistics .cz-top10-title{
    min-height:48px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:8px!important;
    padding:0 14px!important;
    background:#163f2f!important;
    color:#fff!important;
    font-size:14px!important;
    font-weight:700!important;
}

#content.statistics .cz-top10-title-icon{
    color:#f1c84b!important;
    font-size:17px!important;
}

#content.statistics .cz-top10-primary{
    display:grid!important;
    grid-template-columns:repeat(4,minmax(0,1fr))!important;
    gap:8px!important;
    padding:10px!important;
    background:#f7f1e5!important;
}

#content.statistics .cz-top10-tool{
    min-width:0!important;
    min-height:54px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:6px!important;
    padding:6px!important;
    box-sizing:border-box!important;
    border:1px solid #d8c8aa!important;
    border-radius:9px!important;
    background:#fffaf2!important;
    color:#173f30!important;
    font-size:10.5px!important;
    font-weight:700!important;
    text-decoration:none!important;
    text-align:center!important;
}

#content.statistics .cz-top10-tool.active{
    background:#064a34!important;
    color:#fff!important;
    border-color:#d0a22e!important;
}

#content.statistics .cz-top10-tool img{
    display:block!important;
    position:static!important;
    float:none!important;
    margin:0!important;
    opacity:1!important;
}

#content.statistics .cz-top10-tribe-row{
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    flex-wrap:wrap!important;
    gap:8px!important;
    padding:10px!important;
    border-top:1px solid #e2d6c4!important;
    background:#fffdf9!important;
}

#content.statistics .cz-top10-tribe-label{
    color:#53645b!important;
    font-size:10px!important;
    font-weight:700!important;
}

#content.statistics .cz-top10-tribe{
    min-height:38px!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:5px!important;
    padding:3px 10px!important;
    box-sizing:border-box!important;
    border:1px solid #d8c8aa!important;
    border-radius:8px!important;
    background:#fff8e7!important;
    color:#173f30!important;
    font-size:10px!important;
    font-weight:700!important;
    text-decoration:none!important;
}

#content.statistics .cz-top10-tribe img{
    display:block!important;
    position:static!important;
    float:none!important;
    margin:0!important;
}

/* ---------------- Tables ---------------- */
#content.statistics table.row_table_data,
#content.statistics table#player,
#content.statistics table#heroes,
#content.statistics table#villages,
#content.statistics table#alliance,
#content.statistics table.world,
#content.statistics table.top10,
#content.statistics table[id^="top10_"]{
    width:100%!important;
    margin:0 0 16px!important;
    border:1px solid #d6c7b0!important;
    border-radius:11px!important;
    border-collapse:separate!important;
    border-spacing:0!important;
    overflow:hidden!important;
    direction:rtl!important;
    background:#fffdf9!important;
    box-shadow:0 3px 10px rgba(61,48,29,.04)!important;
}

#content.statistics table thead tr:first-child th{
    min-height:44px!important;
    padding:11px 13px!important;
    border:0!important;
    background:#163f2f!important;
    background-image:none!important;
    color:#fff!important;
    text-align:center!important;
    font-size:13px!important;
    font-weight:700!important;
    opacity:1!important;
}

#content.statistics table thead tr:not(:first-child) td,
#content.statistics table thead tr:not(:first-child) th{
    padding:9px 8px!important;
    border:0!important;
    border-left:1px solid rgba(255,255,255,.12)!important;
    background:#0b5940!important;
    color:#fff!important;
    text-align:center!important;
    font-size:11px!important;
    font-weight:700!important;
    opacity:1!important;
}

#content.statistics table tbody td,
#content.statistics table tbody th{
    height:39px!important;
    padding:8px 9px!important;
    border:0!important;
    border-bottom:1px solid #e9dfcf!important;
    border-left:1px solid #eee4d6!important;
    background:#fffdf9!important;
    color:#263b30!important;
    text-align:center!important;
    vertical-align:middle!important;
    font-size:11px!important;
    line-height:1.5!important;
    opacity:1!important;
}

#content.statistics table tbody tr:nth-child(even) td,
#content.statistics table tbody tr:nth-child(even) th{
    background:#fcf8f0!important;
}

#content.statistics table tbody tr:hover td,
#content.statistics table tbody tr:hover th{
    background:#fff3d9!important;
}

#content.statistics table tbody tr.hl td,
#content.statistics table tbody tr.own td{
    background:#fff0c5!important;
}

#content.statistics table a{
    color:#07583e!important;
    font-weight:700!important;
    text-decoration:none!important;
}

#content.statistics td.ra{
    width:52px!important;
    color:#876516!important;
    font-weight:700!important;
}

#content.statistics td.pla,
#content.statistics td.al,
#content.statistics td.vil,
#content.statistics td.hero{
    text-align:right!important;
}

/* ---------------- Search ---------------- */
#content.statistics .cz-rank-search{
    width:100%!important;
    margin-top:16px!important;
    padding:12px!important;
    box-sizing:border-box!important;
    direction:rtl!important;
    border:1px solid #dbcfbd!important;
    border-radius:11px!important;
    background:#f8f3e9!important;
}

#content.statistics .cz-rank-search-fields{
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:10px!important;
    flex-wrap:nowrap!important;
}

#content.statistics .cz-rank-search-fields label{
    display:flex!important;
    align-items:center!important;
    gap:7px!important;
    color:#173f30!important;
    font-size:11px!important;
    font-weight:700!important;
}

#content.statistics .cz-rank-search-fields input.text{
    height:34px!important;
    padding:0 9px!important;
    box-sizing:border-box!important;
    border:1px solid #d3c4ae!important;
    border-radius:8px!important;
    background:#fff!important;
    color:#21372d!important;
    font-size:11px!important;
}

#content.statistics .cz-rank-search-fields input.ra{
    width:64px!important;
    text-align:center!important;
}

#content.statistics .cz-rank-search-fields input.name{
    width:160px!important;
    direction:rtl!important;
}

#content.statistics .cz-rank-submit{
    min-width:78px!important;
    height:34px!important;
    padding:0 14px!important;
    border:1px solid #c79f3f!important;
    border-radius:8px!important;
    background:#fff5db!important;
    color:#064a34!important;
    font-size:11px!important;
    font-weight:700!important;
    cursor:pointer!important;
}

#content.statistics .cz-rank-navi{
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:10px!important;
    margin-top:10px!important;
    padding-top:9px!important;
    border-top:1px solid #e5d9c8!important;
    font-size:11px!important;
}

#content.statistics .cz-rank-navi a{
    color:#07583e!important;
    font-weight:700!important;
    text-decoration:none!important;
}

#content.statistics .cz-rank-navi .disabled{
    color:#9aa09c!important;
}

/* الإحصائيات العامة */
#content.statistics table.world{
    width:48%!important;
    display:inline-table!important;
    vertical-align:top!important;
    margin-left:1%!important;
    margin-right:1%!important;
}

/* لا نسمح لأي submenu قديم بالطفو */
#content.statistics #submenu,
#content.statistics #submenu2,
#content.statistics .cz-rank-tools,
#content.statistics .cz-rank-tribes{
    float:none!important;
    position:static!important;
}

/* Responsive */
@media(max-width:1120px){
    #content.statistics{
        width:610px!important;
        max-width:610px!important;
    }
}

@media(max-width:900px){
    #content.statistics{
        width:100%!important;
        max-width:100%!important;
    }

    #content.statistics .cz-ranking-tabs{
        grid-template-columns:repeat(2,minmax(0,1fr))!important;
    }

    #content.statistics .cz-top10-primary{
        grid-template-columns:repeat(2,minmax(0,1fr))!important;
    }

    #content.statistics .cz-rank-search-fields{
        flex-wrap:wrap!important;
    }

    #content.statistics table.world{
        width:100%!important;
        margin:0 0 12px!important;
    }
}


/* =========================================================
   مدينة الصفر v13.6 — مدير المهام الموحد FINAL
   مدير المهام يسار | المحتوى وسط | القائمة يمين
   هذا البلوك هو المرجع النهائي ويُلغي تأثير القواعد القديمة.
   ========================================================= */

/* ---------- الهيكل العام ---------- */
#mid{
    width:1080px!important;
    max-width:1080px!important;
    min-height:680px!important;
    margin:0 auto!important;
    padding:28px 0 0!important;
    position:relative!important;
    box-sizing:border-box!important;
    direction:rtl!important;
}

/* القائمة الرئيسية دائماً يمين */
#side_navi,
#side_navi.cz-side-menu-v8,
#side_navi.cz-side-menu{
    position:absolute!important;
    top:28px!important;
    right:0!important;
    left:auto!important;
    float:none!important;
    width:185px!important;
    margin:0!important;
    padding:0!important;
    z-index:20!important;
    direction:rtl!important;
    text-align:right!important;
}

/* مدير المهام دائماً يسار */
#side_info,
#side_info.cz-task-panel{
    position:absolute!important;
    top:28px!important;
    left:0!important;
    right:auto!important;
    float:none!important;
    width:185px!important;
    min-width:185px!important;
    max-width:185px!important;
    min-height:0!important;
    margin:0!important;
    padding:0!important;
    box-sizing:border-box!important;
    z-index:30!important;
    direction:rtl!important;
    text-align:right!important;
    background:transparent!important;
    transform:none!important;
}

/* لا تسمح لأي قالب داخلي بإزاحة مدير المهام */
#side_info > *,
#side_info.cz-task-panel > *{
    box-sizing:border-box!important;
}

#side_info #qge,
#side_info.cz-task-panel #qge,
#side_info .cz-task-manager{
    position:static!important;
    display:block!important;
    float:none!important;
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    height:auto!important;
    min-height:0!important;
    margin:0!important;
    padding:0!important;
    left:auto!important;
    right:auto!important;
    top:auto!important;
    transform:none!important;
    background:transparent!important;
}

/* anchor الخاص بنافذة المهمات */
#side_info #anm,
#side_info.cz-task-panel #anm,
#side_info .cz-task-anchor{
    position:absolute!important;
    top:0!important;
    left:0!important;
    right:auto!important;
    width:1px!important;
    height:1px!important;
    margin:0!important;
    padding:0!important;
    visibility:hidden!important;
    z-index:1000!important;
}

/* ---------- بطاقة مدير المهام ---------- */
#side_info .cz-task-button,
#side_info.cz-task-panel .cz-task-button{
    appearance:none!important;
    -webkit-appearance:none!important;
    width:185px!important;
    min-width:185px!important;
    max-width:185px!important;
    height:104px!important;
    min-height:104px!important;
    margin:0!important;
    padding:14px 13px!important;
    display:flex!important;
    flex-direction:row!important;
    align-items:center!important;
    justify-content:space-between!important;
    gap:10px!important;
    box-sizing:border-box!important;
    border:1px solid #d8c9b3!important;
    border-radius:14px!important;
    outline:none!important;
    background:#fffdf8!important;
    color:#073f2e!important;
    font-family:Tahoma,Arial,sans-serif!important;
    text-align:right!important;
    cursor:pointer!important;
    box-shadow:0 7px 20px rgba(64,50,28,.08)!important;
    position:relative!important;
    left:auto!important;
    right:auto!important;
    top:auto!important;
    transform:none!important;
}

#side_info .cz-task-button:hover,
#side_info.cz-task-panel .cz-task-button:hover{
    border-color:#c9aa58!important;
    background:#fff9e9!important;
    box-shadow:0 9px 24px rgba(64,50,28,.12)!important;
}

#side_info .cz-task-copy,
#side_info.cz-task-panel .cz-task-copy{
    display:block!important;
    flex:1 1 auto!important;
    min-width:0!important;
    margin:0!important;
    padding:0!important;
    line-height:1.45!important;
    text-align:right!important;
}

#side_info .cz-task-title,
#side_info.cz-task-panel .cz-task-title{
    display:block!important;
    margin:0!important;
    padding:0!important;
    color:#073f2e!important;
    font-size:13px!important;
    font-weight:700!important;
    line-height:1.4!important;
    white-space:nowrap!important;
}

#side_info .cz-task-sub,
#side_info.cz-task-panel .cz-task-sub{
    display:block!important;
    margin:5px 0 0!important;
    padding:0!important;
    color:#777b75!important;
    font-size:10px!important;
    font-weight:400!important;
    line-height:1.3!important;
    white-space:nowrap!important;
}

#side_info .cz-task-icon,
#side_info.cz-task-panel .cz-task-icon{
    width:46px!important;
    min-width:46px!important;
    max-width:46px!important;
    height:46px!important;
    min-height:46px!important;
    max-height:46px!important;
    flex:0 0 46px!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    margin:0!important;
    padding:0!important;
    border:1px solid #d2a12d!important;
    border-radius:11px!important;
    background:#075b40!important;
    color:#fff!important;
    font-size:28px!important;
    font-weight:700!important;
    line-height:1!important;
    box-sizing:border-box!important;
}

/* إخفاء صورة مدير المهام القديمة إذا بقيت من cache/template سابق */
#side_info #qge > img,
#side_info.cz-task-panel #qge > img{
    display:none!important;
}

/* المحتوى يبقى في المنتصف ولا يدخل على الجانبين */
#content.messages,
#content.reports,
#content.statistics,
#content.plus,
#content.cz-ranking-page,
#content.cz-plus-page{
    float:none!important;
    margin-left:auto!important;
    margin-right:auto!important;
}

/* نافذة المهام الفعلية فوق الواجهة */
div.popup3.quest{
    z-index:9000!important;
}

/* ---------- الشاشات المتوسطة ---------- */
@media(max-width:1120px){
    #mid{
        width:1000px!important;
        max-width:1000px!important;
    }

    #side_navi,
    #side_navi.cz-side-menu-v8,
    #side_navi.cz-side-menu,
    #side_info,
    #side_info.cz-task-panel{
        width:170px!important;
        min-width:170px!important;
        max-width:170px!important;
    }

    #side_info .cz-task-button,
    #side_info.cz-task-panel .cz-task-button{
        width:170px!important;
        min-width:170px!important;
        max-width:170px!important;
    }
}

/* ---------- الموبايل ---------- */
@media(max-width:900px){
    #mid{
        width:100%!important;
        max-width:100%!important;
        min-height:0!important;
        padding:16px!important;
        display:flex!important;
        flex-direction:column!important;
        gap:14px!important;
    }

    #side_navi,
    #side_navi.cz-side-menu-v8,
    #side_navi.cz-side-menu,
    #side_info,
    #side_info.cz-task-panel{
        position:static!important;
        width:100%!important;
        min-width:0!important;
        max-width:none!important;
        margin:0!important;
    }

    #side_navi,
    #side_navi.cz-side-menu-v8,
    #side_navi.cz-side-menu{
        order:1!important;
    }

    #content{
        position:static!important;
        width:100%!important;
        max-width:100%!important;
        margin:0!important;
        order:2!important;
    }

    #side_info,
    #side_info.cz-task-panel{
        order:3!important;
    }

    #side_info .cz-task-button,
    #side_info.cz-task-panel .cz-task-button{
        width:100%!important;
        min-width:0!important;
        max-width:none!important;
        height:90px!important;
        min-height:90px!important;
    }
}


/* =========================================================
   مدينة الصفر v13.7 — GRID LOCK للترتيب
   يمنع مدير المهام من تغيير مكانه بين جميع تبويبات الترتيب
   ========================================================= */

/*
   statistiken.php يحتوي مباشرة داخل #mid على:
   #side_navi + #content.statistics + #side_info
   لذلك نستخدم Grid حقيقي بدل absolute.
*/
#mid:has(> #content.statistics){
    width:1080px!important;
    max-width:1080px!important;
    min-height:680px!important;
    margin:0 auto!important;
    padding:28px 0 0!important;

    display:grid!important;
    grid-template-columns:185px 630px 185px!important;
    grid-template-areas:"task content menu"!important;
    column-gap:40px!important;
    align-items:start!important;

    position:relative!important;
    box-sizing:border-box!important;
    direction:ltr!important;
}

/* مدير المهام — العمود الأيسر دائماً */
#mid:has(> #content.statistics) > #side_info,
#mid:has(> #content.statistics) > #side_info.cz-task-panel{
    grid-area:task!important;

    position:static!important;
    top:auto!important;
    left:auto!important;
    right:auto!important;
    bottom:auto!important;

    width:185px!important;
    min-width:185px!important;
    max-width:185px!important;
    height:auto!important;
    min-height:0!important;

    margin:0!important;
    padding:0!important;
    float:none!important;
    transform:none!important;

    align-self:start!important;
    justify-self:start!important;
    z-index:20!important;

    direction:rtl!important;
}

/* بطاقة مدير المهام نفسها */
#mid:has(> #content.statistics) > #side_info .cz-task-manager,
#mid:has(> #content.statistics) > #side_info #qge{
    position:static!important;
    width:185px!important;
    min-width:185px!important;
    max-width:185px!important;
    height:auto!important;
    margin:0!important;
    padding:0!important;
    float:none!important;
    transform:none!important;
}

#mid:has(> #content.statistics) > #side_info .cz-task-button{
    width:185px!important;
    min-width:185px!important;
    max-width:185px!important;
    height:104px!important;
    min-height:104px!important;
    margin:0!important;
    position:static!important;
    transform:none!important;
}

/* محتوى الترتيب — العمود الأوسط */
#mid:has(> #content.statistics) > #content.statistics,
#mid:has(> #content.statistics) > #content.cz-ranking-page{
    grid-area:content!important;

    position:static!important;
    top:auto!important;
    left:auto!important;
    right:auto!important;

    width:630px!important;
    min-width:630px!important;
    max-width:630px!important;

    margin:0!important;
    float:none!important;
    transform:none!important;

    align-self:start!important;
    justify-self:center!important;

    direction:rtl!important;
}

/* القائمة — العمود الأيمن دائماً */
#mid:has(> #content.statistics) > #side_navi,
#mid:has(> #content.statistics) > #side_navi.cz-side-menu-v8,
#mid:has(> #content.statistics) > #side_navi.cz-side-menu{
    grid-area:menu!important;

    position:static!important;
    top:auto!important;
    left:auto!important;
    right:auto!important;
    bottom:auto!important;

    width:185px!important;
    min-width:185px!important;
    max-width:185px!important;

    margin:0!important;
    padding:0!important;
    float:none!important;
    transform:none!important;

    align-self:start!important;
    justify-self:end!important;
    z-index:20!important;

    direction:rtl!important;
}

/* clear القديم لا يؤثر على Grid */
#mid:has(> #content.statistics) > .clear{
    display:none!important;
}

/*
   مهما اختلف طول Top10 أو القرى أو عام أو الأبطال،
   الجوانب تبقى مثبتة عند بداية نفس الصف.
*/
#mid:has(> #content.statistics) > #side_info,
#mid:has(> #content.statistics) > #side_navi,
#mid:has(> #content.statistics) > #content.statistics{
    grid-row:1!important;
}

/* شاشة متوسطة */
@media(max-width:1120px){
    #mid:has(> #content.statistics){
        width:1000px!important;
        max-width:1000px!important;
        grid-template-columns:170px 620px 170px!important;
        column-gap:20px!important;
    }

    #mid:has(> #content.statistics) > #side_info,
    #mid:has(> #content.statistics) > #side_info.cz-task-panel,
    #mid:has(> #content.statistics) > #side_navi,
    #mid:has(> #content.statistics) > #side_navi.cz-side-menu-v8,
    #mid:has(> #content.statistics) > #side_navi.cz-side-menu{
        width:170px!important;
        min-width:170px!important;
        max-width:170px!important;
    }

    #mid:has(> #content.statistics) > #side_info .cz-task-manager,
    #mid:has(> #content.statistics) > #side_info #qge,
    #mid:has(> #content.statistics) > #side_info .cz-task-button{
        width:170px!important;
        min-width:170px!important;
        max-width:170px!important;
    }

    #mid:has(> #content.statistics) > #content.statistics{
        width:620px!important;
        min-width:620px!important;
        max-width:620px!important;
    }
}

/* شاشة صغيرة */
@media(max-width:900px){
    #mid:has(> #content.statistics){
        width:100%!important;
        max-width:100%!important;
        min-height:0!important;
        padding:16px!important;

        display:flex!important;
        flex-direction:column!important;
        gap:14px!important;
    }

    #mid:has(> #content.statistics) > #side_navi,
    #mid:has(> #content.statistics) > #content.statistics,
    #mid:has(> #content.statistics) > #side_info{
        position:static!important;
        width:100%!important;
        min-width:0!important;
        max-width:none!important;
        margin:0!important;
    }

    #mid:has(> #content.statistics) > #side_navi{
        order:1!important;
    }

    #mid:has(> #content.statistics) > #content.statistics{
        order:2!important;
    }

    #mid:has(> #content.statistics) > #side_info{
        order:3!important;
    }

    #mid:has(> #content.statistics) > #side_info .cz-task-manager,
    #mid:has(> #content.statistics) > #side_info #qge,
    #mid:has(> #content.statistics) > #side_info .cz-task-button{
        width:100%!important;
        min-width:0!important;
        max-width:none!important;
    }
}


/* =========================================================
   مدينة الصفر v13.8 — شريط الموارد + إصلاح هيكل الترتيب
   ========================================================= */

/*
   res.tpl يتم تضمينه في نهاية الصفحة بعد footer.tpl.
   لذلك يجب إخراجه من document flow ووضعه تحت الهيدر مباشرة.
*/
#res,
#res.cz-resbar-v8{
    position:absolute!important;
    top:104px!important;
    left:0!important;
    right:auto!important;
    width:100%!important;
    min-width:980px!important;
    height:48px!important;
    min-height:48px!important;
    margin:0!important;
    padding:0!important;
    z-index:90!important;

    display:block!important;
    visibility:visible!important;
    opacity:1!important;

    background:#fffaf1!important;
    border-top:0!important;
    border-bottom:1px solid #dfd2bc!important;
    box-shadow:0 2px 8px rgba(63,54,36,.06)!important;
    box-sizing:border-box!important;
}

/* محتوى الموارد في منتصف الشاشة */
#resWrap,
#resWrap.cz-reswrap-v8{
    position:relative!important;
    left:auto!important;
    right:auto!important;
    top:auto!important;

    width:760px!important;
    max-width:calc(100% - 40px)!important;
    height:48px!important;
    margin:0 auto!important;

    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:18px!important;

    direction:ltr!important;
    box-sizing:border-box!important;
}

/* إذا كان res.tpl ما زال يستخدم جدول المحرك القديم */
#res table{
    width:auto!important;
    height:48px!important;
    margin:0 auto!important;
    background:transparent!important;
    border:0!important;
}

#res table td{
    height:48px!important;
    padding:0 6px!important;
    vertical-align:middle!important;
    background:transparent!important;
    color:#18382a!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:12px!important;
    font-weight:700!important;
    white-space:nowrap!important;
}

#res table img{
    margin:0 4px!important;
    vertical-align:middle!important;
}

/*
   الهيدر 104px + الموارد 48px.
   نخلي بداية المحتوى بعدهم بمسافة 28px.
*/
#mid{
    padding-top:76px!important;
}

/* Grid صفحة الترتيب يحتاج نفس المسافة بعد شريط الموارد */
#mid:has(> #content.statistics){
    padding-top:76px!important;
}

/* ---------- صفحة القرى ---------- */

/* لا يوجد فراغ صناعي بين البحث والجدول */
#content.statistics #villages{
    margin-top:0!important;
    margin-bottom:14px!important;
}

/* البحث بعد الجدول مباشرة */
#content.statistics #villages + .cz-rank-search,
#content.statistics .cz-rank-search{
    margin-top:14px!important;
}

/* منع ارتفاع/فراغ قديم داخل جدول القرى */
#content.statistics table#villages tbody{
    height:auto!important;
    min-height:0!important;
}

#content.statistics table#villages tbody tr{
    height:auto!important;
}

/* Footer لا يتداخل مع آخر جدول */
.footer-stopper{
    clear:both!important;
    min-height:24px!important;
}

/* Resource bar دائماً فوق المحتوى وتحت الهيدر */
#header.cz-header-v8{
    z-index:100!important;
}

@media(max-width:980px){
    #res,
    #res.cz-resbar-v8{
        min-width:0!important;
        width:100%!important;
    }

    #resWrap,
    #resWrap.cz-reswrap-v8{
        max-width:calc(100% - 20px)!important;
        gap:8px!important;
        overflow-x:auto!important;
        justify-content:flex-start!important;
    }
}


/* =========================================================
   مدينة الصفر v13.9 — أفضل التحالفات + شريط الموارد
   صفحة الترتيب فقط: resource bar داخل document flow
   ========================================================= */

/*
   في statistiken.php تم نقل res.tpl مباشرة بعد header.tpl.
   لذلك لا نستخدم absolute في صفحة الترتيب.
*/
body.cz-ranking-body #res,
body.cz-ranking-body #res.cz-resbar-v8{
    position:relative!important;
    top:auto!important;
    left:auto!important;
    right:auto!important;
    bottom:auto!important;

    width:100%!important;
    min-width:0!important;
    height:48px!important;
    min-height:48px!important;

    margin:0!important;
    padding:0!important;

    display:block!important;
    visibility:visible!important;
    opacity:1!important;

    z-index:40!important;
    box-sizing:border-box!important;

    background:#fffaf1!important;
    border-top:0!important;
    border-bottom:1px solid #dfd2bc!important;
    box-shadow:0 2px 8px rgba(63,54,36,.06)!important;
}

/* Center resource values without covering side columns */
body.cz-ranking-body #resWrap,
body.cz-ranking-body #resWrap.cz-reswrap-v8{
    position:static!important;

    width:760px!important;
    max-width:calc(100% - 40px)!important;
    height:48px!important;

    margin:0 auto!important;
    padding:0!important;

    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:18px!important;

    direction:ltr!important;
    box-sizing:border-box!important;
}

/*
   Resource bar now consumes its own 48px in normal flow.
   Reset the extra 76px top padding that v13.8 used for absolute res.
*/
body.cz-ranking-body #mid,
body.cz-ranking-body #mid:has(> #content.statistics){
    padding-top:28px!important;
}

/* Keep ranking grid aligned immediately below resource bar */
body.cz-ranking-body #mid:has(> #content.statistics){
    margin-top:0!important;
}

/* Prevent old resource absolute rules from winning inside ranking page */
body.cz-ranking-body #res table{
    margin:0 auto!important;
}

/* Alliance Top10 spacing */
#content.statistics .cz-top10-panel{
    margin-top:0!important;
}

#content.statistics table#top10_offs,
#content.statistics table#top10_defs,
#content.statistics table#top10_climbers,
#content.statistics table#top10_raiders{
    margin-top:0!important;
    margin-bottom:16px!important;
}


/* =========================================================
   مدينة الصفر v13.10 — إصلاح صفوف أفضل 10 والهجوم والدفاع
   ========================================================= */

#content.statistics .cz-clean-top10 tbody tr,
#content.statistics .cz-clean-ranking-table tbody tr{
    height:40px!important;
}

#content.statistics .cz-clean-top10 tbody td,
#content.statistics .cz-clean-ranking-table tbody td{
    height:40px!important;
    padding:8px 10px!important;
    vertical-align:middle!important;
}

/* لا صفوف فارغة صناعية داخل أفضل 10 */
#content.statistics .cz-clean-top10 td.empty{
    display:none!important;
}

/* شريط الهجوم/الدفاع النصي */
#content.statistics .cz-rank-section-tools{
    width:100%!important;
    display:grid!important;
    grid-template-columns:repeat(3,1fr)!important;
    gap:8px!important;
    margin:0 0 14px!important;
    padding:8px!important;
    box-sizing:border-box!important;
    background:#f7f1e5!important;
    border:1px solid #d9cdb8!important;
    border-radius:11px!important;
    direction:rtl!important;
}

#content.statistics .cz-rank-section-tools a{
    min-height:42px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    border:1px solid #d8c8aa!important;
    border-radius:8px!important;
    background:#fffaf2!important;
    color:#173f30!important;
    font-size:11px!important;
    font-weight:700!important;
    text-decoration:none!important;
}

#content.statistics .cz-rank-section-tools a.active{
    background:#064a34!important;
    color:#fff!important;
    border-color:#d0a22e!important;
}

/* ترتيب الأعمدة RTL بشكل ثابت */
#content.statistics .cz-clean-ranking-table thead tr:nth-child(2) td,
#content.statistics .cz-clean-top10 thead tr:nth-child(2) td{
    color:#fff!important;
    opacity:1!important;
}


/* =========================================================
   مدينة الصفر v14 — الخريطة
   تعريب + ترتيب + ربط حديث بقاعدة البيانات
   ========================================================= */

/* Resource bar on map is in normal flow directly after header */
body.cz-map-body #res,
body.cz-map-body #res.cz-resbar-v8{
    position:relative!important;
    top:auto!important;
    left:auto!important;
    right:auto!important;
    width:100%!important;
    min-width:0!important;
    height:48px!important;
    min-height:48px!important;
    margin:0!important;
    z-index:50!important;
    background:#fffaf1!important;
    border-bottom:1px solid #dfd2bc!important;
    box-shadow:0 2px 8px rgba(63,54,36,.06)!important;
}

body.cz-map-body #resWrap,
body.cz-map-body #resWrap.cz-reswrap-v8{
    position:static!important;
    width:760px!important;
    max-width:calc(100% - 40px)!important;
    height:48px!important;
    margin:0 auto!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:18px!important;
}

/* Same 3-column skeleton used by the modern pages */
body.cz-map-body #mid{
    width:1080px!important;
    max-width:1080px!important;
    min-height:650px!important;
    margin:0 auto!important;
    padding:28px 0 0!important;
    position:relative!important;
    box-sizing:border-box!important;
}

/* map card */
#content.map.cz-map-page,
#content.map{
    float:none!important;
    width:630px!important;
    max-width:630px!important;
    min-height:560px!important;
    margin:0 auto!important;
    padding:22px!important;
    box-sizing:border-box!important;
    background:#fffdf9!important;
    border:1px solid #d8c9b3!important;
    border-radius:16px!important;
    box-shadow:0 10px 28px rgba(72,56,31,.10)!important;
    direction:rtl!important;
    font-family:Tahoma,Arial,sans-serif!important;
    overflow:visible!important;
}

#content.map h1{
    position:relative!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:9px!important;
    margin:0 0 16px!important;
    padding:0 0 13px!important;
    border-bottom:1px solid #d2a02c!important;
    color:#064a34!important;
    font-size:28px!important;
    font-weight:700!important;
    line-height:1.2!important;
}

#content.map h1:after{
    content:""!important;
    position:absolute!important;
    left:50%!important;
    bottom:-4px!important;
    width:8px!important;
    height:8px!important;
    transform:translateX(-50%) rotate(45deg)!important;
    background:#d2a02c!important;
}

#content.map .cz-map-title-icon{
    width:36px!important;
    height:36px!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    border-radius:9px!important;
    background:#f3e8cb!important;
    color:#89670c!important;
    font-size:17px!important;
}

#content.map .cz-map-coor{
    color:#7f6a35!important;
    font-size:15px!important;
    font-weight:700!important;
    direction:ltr!important;
}

/*
  Important: keep original Travian map geometry intact.
  We style the outer shell only.
*/
#content.map #map{
    position:relative!important;
    width:540px!important;
    height:440px!important;
    margin:0 auto!important;
    direction:ltr!important;
    background:#fbf8f0!important;
    border:1px solid #e3d7c4!important;
    border-radius:13px!important;
    box-shadow:inset 0 0 0 1px rgba(255,255,255,.7)!important;
}

/* detail card */
#content.map #map_infobox.cz-map-infobox,
#content.map #map_infobox{
    position:absolute!important;
    top:10px!important;
    right:10px!important;
    left:auto!important;
    width:185px!important;
    margin:0!important;
    border:1px solid #d7c8b1!important;
    border-collapse:separate!important;
    border-spacing:0!important;
    border-radius:9px!important;
    overflow:hidden!important;
    background:#fffdf9!important;
    box-shadow:0 5px 16px rgba(62,48,28,.08)!important;
    direction:rtl!important;
    z-index:30!important;
}

#content.map #map_infobox thead th{
    padding:8px 10px!important;
    background:#163f2f!important;
    color:#fff!important;
    font-size:11px!important;
    text-align:right!important;
    font-weight:700!important;
}

#content.map #map_infobox tbody th,
#content.map #map_infobox tbody td{
    padding:7px 8px!important;
    border-bottom:1px solid #eee4d6!important;
    background:#fffdf9!important;
    color:#233a30!important;
    font-size:10px!important;
    line-height:1.4!important;
    opacity:1!important;
}

#content.map #map_infobox tbody th{
    width:70px!important;
    background:#faf4e9!important;
    color:#07583e!important;
    font-weight:700!important;
    text-align:right!important;
}

#content.map #map_infobox tbody td{
    text-align:right!important;
}

/* coordinates box */
#content.map #map_coords.cz-map-coords,
#content.map #map_coords{
    position:absolute!important;
    left:12px!important;
    bottom:10px!important;
    right:auto!important;
    width:250px!important;
    height:auto!important;
    margin:0!important;
    padding:9px!important;
    box-sizing:border-box!important;
    background:rgba(255,253,249,.97)!important;
    border:1px solid #d7c8b1!important;
    border-radius:9px!important;
    box-shadow:0 5px 16px rgba(62,48,28,.08)!important;
    z-index:31!important;
    direction:rtl!important;
}

#content.map #map_coords form{
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:7px!important;
    flex-wrap:wrap!important;
    margin:0!important;
}

#content.map #map_coords label{
    display:flex!important;
    align-items:center!important;
    gap:4px!important;
    color:#064a34!important;
    font-size:10px!important;
    font-weight:700!important;
}

#content.map #map_coords input.text{
    width:48px!important;
    height:29px!important;
    padding:0 5px!important;
    box-sizing:border-box!important;
    border:1px solid #d3c4ae!important;
    border-radius:6px!important;
    background:#fff!important;
    color:#233a30!important;
    text-align:center!important;
    font-size:10px!important;
}

#content.map .cz-map-go{
    height:29px!important;
    min-width:64px!important;
    padding:0 11px!important;
    border:1px solid #c79f3f!important;
    border-radius:6px!important;
    background:#fff5db!important;
    color:#064a34!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:10px!important;
    font-weight:700!important;
    cursor:pointer!important;
}

#content.map .cz-map-go:hover{
    background:#f3dfaa!important;
}

#content.map .cz-crop-finder{
    width:100%!important;
    margin-top:3px!important;
    color:#07583e!important;
    text-decoration:none!important;
    font-size:10px!important;
    font-weight:700!important;
    text-align:center!important;
}

/* Keep map layers above shell and preserve sprite positions */
#content.map #map_content,
#content.map #map_rulers,
#content.map #map_links,
#content.map #map_navibox{
    z-index:5!important;
}

/* the dynamic info box should be legible, not washed out */
#content.map #map_infobox *{
    opacity:1!important;
    filter:none!important;
}

/* Side columns: use global positions, no overlap */
body.cz-map-body #side_navi,
body.cz-map-body #side_navi.cz-side-menu-v8{
    position:absolute!important;
    top:28px!important;
    right:0!important;
    left:auto!important;
    width:185px!important;
}

body.cz-map-body #side_info,
body.cz-map-body #side_info.cz-task-panel{
    position:absolute!important;
    top:28px!important;
    left:0!important;
    right:auto!important;
    width:185px!important;
    margin:0!important;
}

/* Arabic visible map details when old constants are English */
body.cz-map-body #stime{
    direction:rtl!important;
}

/* Smaller screens */
@media(max-width:1120px){
    body.cz-map-body #mid{
        width:1000px!important;
        max-width:1000px!important;
    }

    #content.map.cz-map-page,
    #content.map{
        width:620px!important;
        max-width:620px!important;
    }

    body.cz-map-body #side_navi,
    body.cz-map-body #side_info{
        width:170px!important;
    }
}


/* =========================================================
   مدينة الصفر v14.4 — MAP LAYOUT FINAL
   الخريطة مستقلة، وأسفلها الإحداثيات + التفاصيل بدون تداخل
   ========================================================= */
body.cz-map-body #content.map.cz-map-page,
body.cz-map-body #content.map{
    width:680px!important;
    max-width:680px!important;
    padding:22px!important;
}

body.cz-map-body #content.map #map{
    width:540px!important;
    height:440px!important;
    margin:0 auto 14px!important;
    position:relative!important;
    overflow:visible!important;
}

/* لوحة سفلية موحدة */
body.cz-map-body #content.map .cz-map-bottom-panel{
    width:540px!important;
    margin:0 auto!important;
    display:grid!important;
    grid-template-columns:220px 1fr!important;
    gap:12px!important;
    align-items:stretch!important;
    direction:ltr!important;
}

body.cz-map-body #content.map .cz-map-coords-box,
body.cz-map-body #content.map .cz-map-details-dock{
    min-height:118px!important;
    box-sizing:border-box!important;
    direction:rtl!important;
}

/* الإحداثيات خرجت من #map، لذلك نلغي absolute نهائياً */
body.cz-map-body #content.map .cz-map-bottom-panel #map_coords,
body.cz-map-body #content.map .cz-map-bottom-panel #map_coords.cz-map-coords{
    position:static!important;
    inset:auto!important;
    width:100%!important;
    height:100%!important;
    min-height:118px!important;
    margin:0!important;
    padding:12px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    box-sizing:border-box!important;
    background:#fffaf2!important;
    border:1px solid #d7c8b1!important;
    border-radius:10px!important;
    box-shadow:0 4px 14px rgba(62,48,28,.06)!important;
}

body.cz-map-body #content.map .cz-map-bottom-panel #map_coords form{
    width:100%!important;
    display:grid!important;
    grid-template-columns:1fr 1fr!important;
    gap:9px!important;
    align-items:center!important;
    margin:0!important;
}

body.cz-map-body #content.map .cz-map-bottom-panel #map_coords label{
    display:grid!important;
    grid-template-columns:20px 1fr!important;
    align-items:center!important;
    gap:5px!important;
}

body.cz-map-body #content.map .cz-map-bottom-panel #map_coords input.text{
    width:100%!important;
    height:32px!important;
}

body.cz-map-body #content.map .cz-map-bottom-panel .cz-map-go{
    grid-column:1 / -1!important;
    width:100%!important;
    height:33px!important;
}

body.cz-map-body #content.map .cz-map-bottom-panel .cz-crop-finder{
    grid-column:1 / -1!important;
}

/* التفاصيل: inline style + هذا المحدد يقفل position نهائياً */
body.cz-map-body #content.map.cz-map-page .cz-map-bottom-panel .cz-map-details-dock #map_infobox,
body.cz-map-body #content.map .cz-map-bottom-panel .cz-map-details-dock #map_infobox{
    position:static!important;
    top:auto!important;
    right:auto!important;
    left:auto!important;
    bottom:auto!important;
    inset:auto!important;
    width:100%!important;
    height:100%!important;
    min-height:118px!important;
    margin:0!important;
    border:1px solid #d7c8b1!important;
    border-collapse:separate!important;
    border-spacing:0!important;
    border-radius:10px!important;
    overflow:hidden!important;
    background:#fffdf9!important;
    box-shadow:0 4px 14px rgba(62,48,28,.06)!important;
    direction:rtl!important;
    z-index:auto!important;
}

body.cz-map-body #content.map .cz-map-bottom-panel #map_infobox thead th{
    height:38px!important;
    padding:0 12px!important;
    background:#163f2f!important;
    color:#fff!important;
    text-align:right!important;
    font-size:12px!important;
    font-weight:700!important;
}

body.cz-map-body #content.map .cz-map-bottom-panel #map_infobox tbody th,
body.cz-map-body #content.map .cz-map-bottom-panel #map_infobox tbody td{
    height:26px!important;
    padding:6px 9px!important;
    border-bottom:1px solid #eee4d6!important;
    vertical-align:middle!important;
    font-size:11px!important;
    opacity:1!important;
}

body.cz-map-body #content.map .cz-map-bottom-panel #map_infobox tbody th{
    width:80px!important;
    background:#faf4e9!important;
    color:#07583e!important;
    font-weight:700!important;
    text-align:right!important;
}

body.cz-map-body #content.map .cz-map-bottom-panel #map_infobox tbody td{
    background:#fffdf9!important;
    color:#243b31!important;
    text-align:right!important;
}

body.cz-map-body #content.map .cz-map-bottom-panel #map_infobox tbody tr:last-child th,
body.cz-map-body #content.map .cz-map-bottom-panel #map_infobox tbody tr:last-child td{
    border-bottom:0!important;
}

/* الجوانب تبقى مستقرة مع زيادة عرض بطاقة الخريطة */
body.cz-map-body #mid{
    width:1120px!important;
    max-width:1120px!important;
}

@media(max-width:1160px){
    body.cz-map-body #mid{width:1040px!important;max-width:1040px!important;}
    body.cz-map-body #content.map{width:660px!important;max-width:660px!important;}
}


/* =========================================================
   مدينة الصفر v14.5 — تفاصيل الموقع تعمل + تخطيط أبسط
   ========================================================= */

/* old v14.4 split dock is no longer used */
#content.map .cz-map-bottom-panel,
#content.map .cz-map-details-dock,
#content.map .cz-map-coords-box{display:none!important;}

/* Details directly under the map; never overlay it */
#content.map .cz-map-details-strip{
    width:540px!important;
    margin:12px auto 0!important;
    padding:0!important;
    position:relative!important;
    z-index:10!important;
    direction:rtl!important;
}

/* Target ID only because old JS replaces className with village/oasis/etc. */
#content.map #map_infobox{
    position:static!important;
    top:auto!important;
    right:auto!important;
    left:auto!important;
    bottom:auto!important;
    width:100%!important;
    margin:0!important;
    border:1px solid #d6c7b0!important;
    border-collapse:separate!important;
    border-spacing:0!important;
    border-radius:10px!important;
    overflow:hidden!important;
    background:#fffdf9!important;
    box-shadow:0 4px 12px rgba(62,48,28,.06)!important;
    direction:rtl!important;
}
#content.map #map_infobox thead th{
    height:38px!important;
    padding:0 12px!important;
    background:#163f2f!important;
    color:#fff!important;
    text-align:center!important;
    vertical-align:middle!important;
    font-size:12px!important;
    font-weight:700!important;
    opacity:1!important;
}
#content.map #map_infobox tbody th,
#content.map #map_infobox tbody td{
    height:34px!important;
    padding:5px 12px!important;
    border:0!important;
    border-bottom:1px solid #ece2d3!important;
    vertical-align:middle!important;
    font-size:10px!important;
    opacity:1!important;
}
#content.map #map_infobox tbody tr:last-child th,
#content.map #map_infobox tbody tr:last-child td{border-bottom:0!important;}
#content.map #map_infobox tbody th{
    width:115px!important;
    background:#faf4e9!important;
    color:#07583e!important;
    text-align:right!important;
    font-weight:700!important;
}
#content.map #map_infobox tbody td{
    background:#fffdf9!important;
    color:#253a30!important;
    text-align:right!important;
    font-weight:700!important;
}

/* Coordinates below details in one compact line */
#content.map .cz-map-coords-row{
    width:540px!important;
    margin:9px auto 0!important;
    padding:0!important;
    direction:rtl!important;
}
#content.map .cz-map-coords-row #map_coords{
    position:static!important;
    top:auto!important;
    left:auto!important;
    right:auto!important;
    bottom:auto!important;
    width:100%!important;
    height:auto!important;
    margin:0!important;
    padding:8px 10px!important;
    box-sizing:border-box!important;
    border:1px solid #d7c8b1!important;
    border-radius:9px!important;
    background:#faf5eb!important;
    box-shadow:none!important;
}
#content.map .cz-map-coords-row #map_coords form{
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:9px!important;
    flex-wrap:nowrap!important;
}
#content.map .cz-map-coords-row .cz-crop-finder{
    width:auto!important;
    margin:0 0 0 8px!important;
    white-space:nowrap!important;
}

@media(max-width:900px){
    #content.map .cz-map-details-strip,
    #content.map .cz-map-coords-row{width:100%!important;}
}
\n\n/* =========================================================\n   مدينة الصفر v14.6 — تخطيط الخريطة بأسلوب ترافيان الأصلي\n   ========================================================= */\n\n/* disable the v14.5 under-map dock completely */\n#content.map .cz-map-details-strip,\n#content.map .cz-map-coords-row{display:none!important;}\n\n/* Keep original map geometry */\n#content.map #map{\n    position:relative!important;\n    width:540px!important;\n    height:440px!important;\n    margin:0 auto!important;\n    overflow:visible!important;\n}\n\n/* Original Travian-style detail box: compact, upper-right */\n#content.map #map #map_infobox{\n    position:absolute!important;\n    top:8px!important;\n    right:8px!important;\n    left:auto!important;\n    bottom:auto!important;\n    width:168px!important;\n    min-width:168px!important;\n    max-width:168px!important;\n    margin:0!important;\n    border:1px solid #d4c6ad!important;\n    border-collapse:separate!important;\n    border-spacing:0!important;\n    border-radius:7px!important;\n    overflow:hidden!important;\n    background:rgba(255,253,248,.97)!important;\n    box-shadow:0 3px 10px rgba(52,45,31,.10)!important;\n    z-index:45!important;\n    direction:rtl!important;\n}\n#content.map #map #map_infobox thead th{\n    height:30px!important;\n    padding:0 8px!important;\n    background:#163f2f!important;\n    color:#fff!important;\n    text-align:center!important;\n    vertical-align:middle!important;\n    font-size:10px!important;\n    font-weight:700!important;\n}\n#content.map #map #map_infobox tbody th,\n#content.map #map #map_infobox tbody td{\n    height:27px!important;\n    padding:3px 7px!important;\n    border:0!important;\n    border-bottom:1px solid #ece2d3!important;\n    vertical-align:middle!important;\n    font-size:9px!important;\n    line-height:1.25!important;\n    opacity:1!important;\n}\n#content.map #map #map_infobox tbody tr:last-child th,\n#content.map #map #map_infobox tbody tr:last-child td{border-bottom:0!important;}\n#content.map #map #map_infobox tbody th{\n    width:62px!important;\n    background:#f7f0e4!important;\n    color:#07583e!important;\n    text-align:right!important;\n    font-weight:700!important;\n}\n#content.map #map #map_infobox tbody td{\n    background:rgba(255,253,248,.97)!important;\n    color:#253a30!important;\n    text-align:right!important;\n    font-weight:600!important;\n}\n\n/* Coordinates back inside lower-left of map, like original Travian */\n#content.map #map #map_coords{\n    position:absolute!important;\n    left:12px!important;\n    bottom:10px!important;\n    right:auto!important;\n    top:auto!important;\n    width:250px!important;\n    height:auto!important;\n    margin:0!important;\n    padding:7px 8px!important;\n    box-sizing:border-box!important;\n    border:1px solid #d7c8b1!important;\n    border-radius:7px!important;\n    background:rgba(255,253,248,.96)!important;\n    box-shadow:0 3px 9px rgba(62,48,28,.08)!important;\n    z-index:44!important;\n    direction:rtl!important;\n}\n#content.map #map #map_coords form{\n    display:flex!important;\n    align-items:center!important;\n    justify-content:flex-start!important;\n    gap:6px!important;\n    flex-wrap:wrap!important;\n    margin:0!important;\n}\n#content.map #map #map_coords label{\n    display:flex!important;\n    align-items:center!important;\n    gap:3px!important;\n    color:#064a34!important;\n    font-size:9px!important;\n    font-weight:700!important;\n}\n#content.map #map #map_coords input.text{\n    width:44px!important;\n    height:26px!important;\n    padding:0 4px!important;\n    box-sizing:border-box!important;\n    border:1px solid #d3c4ae!important;\n    border-radius:5px!important;\n    background:#fff!important;\n    color:#233a30!important;\n    text-align:center!important;\n    font-size:9px!important;\n}\n#content.map #map .cz-map-go{\n    height:26px!important;\n    min-width:58px!important;\n    padding:0 9px!important;\n    border:1px solid #c79f3f!important;\n    border-radius:5px!important;\n    background:#fff5db!important;\n    color:#064a34!important;\n    font-size:9px!important;\n    font-weight:700!important;\n}\n#content.map #map .cz-crop-finder{\n    width:auto!important;\n    margin:2px 0 0!important;\n    color:#07583e!important;\n    font-size:9px!important;\n    font-weight:700!important;\n    white-space:nowrap!important;\n}\n\n/* Slightly tighter outer card measurements */\n#content.map.cz-map-page,\n#content.map{\n    width:620px!important;\n    max-width:620px!important;\n    padding:20px!important;\n}\n\n@media(max-width:900px){\n    #content.map #map{transform-origin:top center!important;}\n}\n

/* =========================================================
   مدينة الصفر v14.7 — الخريطة FINAL FLOATING DETAILS
   الخريطة تنزل | التفاصيل فوق بشكل شفاف ومتحرك مثل ترافيان
   ========================================================= */

/* بطاقة الخريطة الرئيسية */
body.cz-map-body #content.map,
body.cz-map-body #content.map.cz-map-page{
    width:650px!important;
    max-width:650px!important;
    min-height:650px!important;
    margin:0 auto!important;
    padding:22px 24px 24px!important;
    box-sizing:border-box!important;
    background:#fffdf9!important;
    border:1px solid #d8c9b3!important;
    border-radius:16px!important;
    box-shadow:0 10px 28px rgba(72,56,31,.10)!important;
    overflow:visible!important;
    position:relative!important;
}

/* عنوان الخريطة */
body.cz-map-body #content.map h1{
    margin:0 0 18px!important;
    padding-bottom:14px!important;
    min-height:40px!important;
}

/*
  منطقة الخريطة نفسها:
  ننزلها حتى يصير مكان مريح للوحة التفاصيل فوقها.
*/
body.cz-map-body #content.map #map{
    position:relative!important;
    width:570px!important;
    height:470px!important;
    margin:34px auto 0!important;
    padding:0!important;
    box-sizing:border-box!important;
    direction:ltr!important;

    background:#fffefb!important;
    border:1px solid #e0d4c1!important;
    border-radius:13px!important;
    box-shadow:
        inset 0 0 0 1px rgba(255,255,255,.85),
        0 7px 20px rgba(73,57,32,.07)!important;

    overflow:visible!important;
}

/*
  نحافظ على هندسة الخريطة الأصلية في الوسط.
  لا نكبّر sprites ولا نغيّر مواقع البلاطات.
*/
body.cz-map-body #content.map #map_content{
    position:relative!important;
    margin:28px auto 0!important;
}

/* ---------------------------------------------------------
   تفاصيل الموقع: Floating glass panel مثل ترافيان
   --------------------------------------------------------- */
body.cz-map-body #content.map #map_infobox,
body.cz-map-body #content.map #map_infobox.cz-map-infobox{
    position:absolute!important;

    /* أعلى الخريطة وأقرب للزاوية اليمنى */
    top:-8px!important;
    right:14px!important;
    left:auto!important;
    bottom:auto!important;

    width:190px!important;
    min-width:190px!important;
    max-width:190px!important;
    height:auto!important;

    margin:0!important;
    padding:0!important;

    z-index:60!important;

    border:1px solid rgba(178,158,117,.70)!important;
    border-radius:10px!important;
    border-collapse:separate!important;
    border-spacing:0!important;

    background:rgba(255,253,247,.84)!important;
    -webkit-backdrop-filter:blur(4px)!important;
    backdrop-filter:blur(4px)!important;

    box-shadow:0 8px 24px rgba(38,54,42,.16)!important;

    overflow:hidden!important;
    direction:rtl!important;

    transition:
        opacity .16s ease,
        transform .16s ease,
        box-shadow .16s ease!important;

    opacity:.94!important;
    transform:translateY(0)!important;
}

/* إحساس ترافيان عند المرور */
body.cz-map-body #content.map #map_infobox:hover{
    opacity:1!important;
    transform:translateY(-2px)!important;
    box-shadow:0 10px 28px rgba(38,54,42,.20)!important;
}

/* رأس التفاصيل */
body.cz-map-body #content.map #map_infobox thead th{
    height:34px!important;
    padding:0 10px!important;

    background:rgba(13,73,51,.92)!important;
    color:#fff!important;

    font-family:Tahoma,Arial,sans-serif!important;
    font-size:11px!important;
    font-weight:700!important;

    text-align:right!important;
    vertical-align:middle!important;
    line-height:34px!important;

    border:0!important;
}

/* صفوف التفاصيل */
body.cz-map-body #content.map #map_infobox tbody th,
body.cz-map-body #content.map #map_infobox tbody td{
    height:30px!important;
    min-height:30px!important;
    padding:5px 8px!important;

    border:0!important;
    border-bottom:1px solid rgba(218,207,187,.72)!important;

    font-family:Tahoma,Arial,sans-serif!important;
    font-size:10px!important;
    line-height:1.35!important;
    vertical-align:middle!important;

    opacity:1!important;
    filter:none!important;
}

/* اسم الحقل */
body.cz-map-body #content.map #map_infobox tbody th{
    width:68px!important;
    background:rgba(248,241,228,.76)!important;
    color:#07583e!important;
    font-weight:700!important;
    text-align:right!important;
}

/* القيمة */
body.cz-map-body #content.map #map_infobox tbody td{
    background:rgba(255,253,249,.74)!important;
    color:#253a31!important;
    font-weight:600!important;
    text-align:right!important;
}

/* إزالة حد آخر صف */
body.cz-map-body #content.map #map_infobox tbody tr:last-child th,
body.cz-map-body #content.map #map_infobox tbody tr:last-child td{
    border-bottom:0!important;
}

/* ---------------------------------------------------------
   الإحداثيات: أسفل الخريطة بشكل صغير ومرتب
   --------------------------------------------------------- */
body.cz-map-body #content.map #map_coords,
body.cz-map-body #content.map #map_coords.cz-map-coords{
    position:absolute!important;
    left:14px!important;
    bottom:12px!important;
    right:auto!important;
    top:auto!important;

    width:260px!important;
    min-width:260px!important;
    height:auto!important;

    margin:0!important;
    padding:8px 10px!important;
    box-sizing:border-box!important;

    z-index:55!important;

    background:rgba(255,253,248,.90)!important;
    border:1px solid rgba(207,187,147,.88)!important;
    border-radius:9px!important;
    box-shadow:0 5px 16px rgba(65,51,31,.10)!important;

    direction:rtl!important;
}

/* صف الإحداثيات */
body.cz-map-body #content.map #map_coords form{
    display:flex!important;
    align-items:center!important;
    justify-content:flex-start!important;
    gap:7px!important;
    flex-wrap:wrap!important;

    margin:0!important;
    padding:0!important;
}

/* مدخلات X/Y */
body.cz-map-body #content.map #map_coords input.text{
    width:50px!important;
    height:30px!important;
    margin:0!important;
    padding:0 5px!important;

    border:1px solid #d0c0a8!important;
    border-radius:6px!important;
    background:#fff!important;
    color:#21372d!important;

    font-size:10px!important;
    text-align:center!important;
    box-sizing:border-box!important;
}

/* زر انتقال */
body.cz-map-body #content.map .cz-map-go,
body.cz-map-body #content.map #map_coords button[type="submit"]{
    min-width:70px!important;
    height:30px!important;

    margin:0!important;
    padding:0 12px!important;

    border:1px solid #c89f3d!important;
    border-radius:6px!important;

    background:#fff4d5!important;
    color:#064a34!important;

    font-family:Tahoma,Arial,sans-serif!important;
    font-size:10px!important;
    font-weight:700!important;

    cursor:pointer!important;
}

/* باحث القمح */
body.cz-map-body #content.map .cz-crop-finder{
    flex:1 0 100%!important;
    margin-top:3px!important;
    text-align:center!important;
    color:#07583e!important;
    font-size:10px!important;
    font-weight:700!important;
    text-decoration:none!important;
}

/* ---------------------------------------------------------
   الأسهم: نفس روح الخريطة الأصلية لكن أوضح
   --------------------------------------------------------- */
body.cz-map-body #content.map #map a img{
    filter:drop-shadow(0 2px 2px rgba(31,72,39,.20))!important;
}

/* نمنع أي قواعد سابقة من إرسال التفاصيل أسفل الخريطة */
body.cz-map-body #content.map .cz-map-bottom-panel{
    display:contents!important;
}

/* تحسين بسيط للوحة الخارطة */
body.cz-map-body #content.map #map_content,
body.cz-map-body #content.map #map_rulers,
body.cz-map-body #content.map #map_links,
body.cz-map-body #content.map #map_navibox{
    z-index:5!important;
}

/* القائمة والمدير بدون تغيير */
body.cz-map-body #side_navi,
body.cz-map-body #side_info{
    top:28px!important;
}

/* شاشات أصغر */
@media(max-width:1120px){
    body.cz-map-body #content.map,
    body.cz-map-body #content.map.cz-map-page{
        width:630px!important;
        max-width:630px!important;
    }

    body.cz-map-body #content.map #map{
        width:555px!important;
    }

    body.cz-map-body #content.map #map_infobox{
        width:180px!important;
        min-width:180px!important;
        max-width:180px!important;
    }
}


/* =========================================================
   مدينة الصفر v14.8 — ضبط موضع الخريطة والتفاصيل
   ========================================================= */

/* البطاقة الخارجية */
body.cz-map-body #content.map,
body.cz-map-body #content.map.cz-map-page{
    width:650px!important;
    max-width:650px!important;
    min-height:680px!important;
    padding:22px 24px 26px!important;
    overflow:visible!important;
}

/* نترك مساحة واضحة بين العنوان والخريطة */
body.cz-map-body #content.map h1{
    margin-bottom:24px!important;
}

/* ننزل قالب الخريطة نفسه لجوه */
body.cz-map-body #content.map #map{
    width:570px!important;
    height:500px!important;
    margin:54px auto 0!important;
    position:relative!important;
    overflow:visible!important;
}

/* ننزل طبقة البلاطات داخل مربع الخريطة حتى ما تلامس التفاصيل */
body.cz-map-body #content.map #map_content{
    margin-top:48px!important;
}

/* تفاصيل الموقع تبقى فوق، شفافة، وبعيدة عن البلاطات */
body.cz-map-body #content.map #map_infobox,
body.cz-map-body #content.map #map_infobox.cz-map-infobox{
    top:-42px!important;
    right:14px!important;
    left:auto!important;
    bottom:auto!important;

    width:190px!important;
    min-width:190px!important;
    max-width:190px!important;

    background:rgba(255,253,247,.86)!important;
    border:1px solid rgba(178,158,117,.72)!important;
    border-radius:10px!important;

    box-shadow:0 8px 22px rgba(38,54,42,.15)!important;
    backdrop-filter:blur(4px)!important;
    -webkit-backdrop-filter:blur(4px)!important;

    z-index:80!important;
    opacity:.96!important;
    transform:none!important;
}

/* عند المرور فقط حركة بسيطة جداً */
body.cz-map-body #content.map #map_infobox:hover{
    opacity:1!important;
    transform:translateY(-2px)!important;
}

/* تصغير ارتفاع التفاصيل حتى تبقى خفيفة */
body.cz-map-body #content.map #map_infobox thead th{
    height:32px!important;
    line-height:32px!important;
    padding:0 9px!important;
}

body.cz-map-body #content.map #map_infobox tbody th,
body.cz-map-body #content.map #map_infobox tbody td{
    height:28px!important;
    min-height:28px!important;
    padding:4px 7px!important;
}

/* الإحداثيات تبقى أسفل الخريطة وبلا تداخل */
body.cz-map-body #content.map #map_coords,
body.cz-map-body #content.map #map_coords.cz-map-coords{
    left:14px!important;
    bottom:12px!important;
    top:auto!important;
    right:auto!important;
    width:265px!important;
    z-index:75!important;
}

/* الأسهم السفلية تبقى فوق الإحداثيات بصرياً */
body.cz-map-body #content.map #map_navibox{
    bottom:10px!important;
}

/* لا تسمح لأي قاعدة قديمة أن ترجع التفاصيل لجوه */
body.cz-map-body #content.map .cz-map-bottom-panel{
    display:contents!important;
}

@media(max-width:1120px){
    body.cz-map-body #content.map,
    body.cz-map-body #content.map.cz-map-page{
        width:630px!important;
        max-width:630px!important;
    }

    body.cz-map-body #content.map #map{
        width:555px!important;
    }
}


/* =========================================================
   مدينة الصفر v14.9 — تفاصيل أصغر + إحداثيات/اتجاهات صحيحة
   ========================================================= */

/* مربع التفاصيل: أصغر، ونزلة خفيفة فقط */
body.cz-map-body #content.map #map_infobox,
body.cz-map-body #content.map #map_infobox.cz-map-infobox{
    top:-28px!important;
    right:16px!important;

    width:170px!important;
    min-width:170px!important;
    max-width:170px!important;

    border-radius:9px!important;
    opacity:.94!important;
}

body.cz-map-body #content.map #map_infobox thead th{
    height:29px!important;
    line-height:29px!important;
    padding:0 8px!important;
    font-size:10px!important;
}

body.cz-map-body #content.map #map_infobox tbody th,
body.cz-map-body #content.map #map_infobox tbody td{
    height:25px!important;
    min-height:25px!important;
    padding:3px 6px!important;
    font-size:9.5px!important;
}

body.cz-map-body #content.map #map_infobox tbody th{
    width:59px!important;
}

/* حقول الإحداثيات: X ثم Y بصرياً وبقيم واضحة */
body.cz-map-body #content.map #map_coords form{
    direction:ltr!important;
    justify-content:flex-start!important;
}

body.cz-map-body #content.map #map_coords label{
    direction:ltr!important;
    display:inline-flex!important;
    align-items:center!important;
    gap:4px!important;
}

body.cz-map-body #content.map #map_coords #mcx,
body.cz-map-body #content.map #map_coords #mcy{
    direction:ltr!important;
    text-align:center!important;
    font-weight:700!important;
}

/* زر الانتقال يبقى واضحاً ولا يستخدم صورة sprite قديمة */
body.cz-map-body #content.map #btn_ok{
    background-image:none!important;
    text-indent:0!important;
    overflow:visible!important;
}


/* =========================================================
   مدينة الصفر v14.10 — MAP GEOMETRY LOCK
   يعيد تطابق البلاطات + الأرقام + مناطق hover بنسبة 100%
   ========================================================= */

/*
  IMPORTANT:
  لا نحرك أي طبقة داخلية منفردة.
  نستخدم هندسة Travian الأصلية بالضبط.
*/

/* Move the WHOLE map down as one unit */
body.cz-map-body #content.map #map{
    position:relative!important;
    width:552px!important;
    height:375px!important;

    top:auto!important;
    left:auto!important;
    right:auto!important;

    margin:58px auto 54px!important;
    padding:0!important;

    overflow:visible!important;
    direction:ltr!important;

    background:#fffefb!important;
    border:1px solid #e0d4c1!important;
    border-radius:12px!important;
    box-shadow:0 7px 20px rgba(73,57,32,.07)!important;
}

/* Original map tile geometry */
body.cz-map-body #content.map #map #map_content{
    position:relative!important;
    width:540px!important;
    height:316px!important;

    left:5px!important;
    top:33px!important;

    margin:0!important;
    padding:0!important;

    transform:none!important;
}

/* The clickable image-map MUST have exactly same box as tiles */
body.cz-map-body #content.map #map img#map_links{
    position:absolute!important;
    width:540px!important;
    height:316px!important;

    left:5px!important;
    top:33px!important;

    margin:0!important;
    padding:0!important;

    z-index:50!important;
    transform:none!important;
}

/* Coordinate rulers must share the exact same coordinate space */
body.cz-map-body #content.map #map #map_rulers{
    position:absolute!important;
    width:540px!important;
    height:316px!important;

    left:5px!important;
    top:34px!important;

    margin:0!important;
    padding:0!important;

    z-index:30!important;
    transform:none!important;
}

/* Restore original ruler positions explicitly */
body.cz-map-body #map_rulers #mx0{left:9px!important;top:172px!important;}
body.cz-map-body #map_rulers #mx1{left:45px!important;top:192px!important;}
body.cz-map-body #map_rulers #mx2{left:81px!important;top:212px!important;}
body.cz-map-body #map_rulers #mx3{left:117px!important;top:232px!important;}
body.cz-map-body #map_rulers #mx4{left:153px!important;top:252px!important;}
body.cz-map-body #map_rulers #mx5{left:189px!important;top:272px!important;}
body.cz-map-body #map_rulers #mx6{left:225px!important;top:292px!important;}

body.cz-map-body #map_rulers #my0{left:9px!important;top:128px!important;}
body.cz-map-body #map_rulers #my1{left:45px!important;top:108px!important;}
body.cz-map-body #map_rulers #my2{left:81px!important;top:88px!important;}
body.cz-map-body #map_rulers #my3{left:117px!important;top:68px!important;}
body.cz-map-body #map_rulers #my4{left:153px!important;top:48px!important;}
body.cz-map-body #map_rulers #my5{left:189px!important;top:28px!important;}
body.cz-map-body #map_rulers #my6{left:225px!important;top:8px!important;}

/* Ruler typography */
body.cz-map-body #map_rulers > div{
    position:absolute!important;
    width:35px!important;
    height:12px!important;
    margin:0!important;
    padding:0!important;

    color:#21352b!important;
    font-size:9px!important;
    font-weight:600!important;
    line-height:12px!important;
    text-align:center!important;
}

/* Main arrow hit areas are contained in map_links overlay; don't move them */

/* Original navibox position */
body.cz-map-body #content.map #map img#map_navibox{
    position:absolute!important;
    right:20px!important;
    bottom:0!important;
    top:auto!important;
    left:auto!important;
    z-index:50!important;
    transform:none!important;
}

/* Slightly smaller/lower floating detail box */
body.cz-map-body #content.map #map_infobox,
body.cz-map-body #content.map #map_infobox.cz-map-infobox{
    position:absolute!important;
    width:166px!important;
    min-width:166px!important;
    max-width:166px!important;

    right:20px!important;
    top:2px!important;
    left:auto!important;
    bottom:auto!important;

    z-index:70!important;

    background:rgba(255,253,247,.88)!important;
    border:1px solid rgba(178,158,117,.72)!important;
    border-radius:9px!important;

    opacity:.95!important;
    transform:none!important;
}

/* Coordinates: keep inside original map coordinate space */
body.cz-map-body #content.map #map_coords,
body.cz-map-body #content.map #map_coords.cz-map-coords{
    position:absolute!important;
    width:270px!important;
    height:auto!important;

    left:30px!important;
    bottom:26px!important;
    top:auto!important;
    right:auto!important;

    margin:0!important;
    z-index:60!important;
}

/* Main card height recalculated after restoring original map geometry */
body.cz-map-body #content.map,
body.cz-map-body #content.map.cz-map-page{
    width:650px!important;
    max-width:650px!important;
    min-height:610px!important;
    padding:22px 24px 26px!important;
    overflow:visible!important;
}

/* Absolutely prevent old v14.8/v14.9 rules from shifting inner geometry */
body.cz-map-body #content.map #map_content,
body.cz-map-body #content.map #map_links,
body.cz-map-body #content.map #map_rulers{
    translate:none!important;
    scale:none!important;
}


/* =========================================================
   مدينة الصفر v14.11 — ضبط المسافات فقط
   لا تغيير على هندسة البلاطات / hover / الأسهم
   ========================================================= */

/* تفاصيل الموقع: نرفعها شوية لفوك ونبعدها عن جسم الخريطة */
body.cz-map-body #content.map #map_infobox,
body.cz-map-body #content.map #map_infobox.cz-map-infobox{
    top:-16px!important;
    right:18px!important;

    width:164px!important;
    min-width:164px!important;
    max-width:164px!important;

    z-index:80!important;
}

/* مربع البحث والإحداثيات: ننزله شوية لجوه ونبعده عن البلاطات */
body.cz-map-body #content.map #map_coords,
body.cz-map-body #content.map #map_coords.cz-map-coords{
    left:30px!important;
    bottom:-8px!important;
    top:auto!important;
    right:auto!important;

    width:270px!important;
    z-index:70!important;
}

/* نزيد مساحة أسفل الخريطة حتى مربع البحث ما يطلع خارج البطاقة */
body.cz-map-body #content.map #map{
    margin-bottom:78px!important;
}

/* البطاقة الخارجية تاخذ الارتفاع الجديد */
body.cz-map-body #content.map,
body.cz-map-body #content.map.cz-map-page{
    min-height:650px!important;
    padding-bottom:34px!important;
}

/* باحث القمح يظل داخل مربع الإحداثيات */
body.cz-map-body #content.map .cz-crop-finder{
    margin-top:5px!important;
}

/* لا تغييرات على هذه الطبقات إطلاقاً */
body.cz-map-body #content.map #map_content{
    left:5px!important;
    top:33px!important;
    width:540px!important;
    height:316px!important;
    margin:0!important;
    transform:none!important;
}

body.cz-map-body #content.map #map img#map_links{
    left:5px!important;
    top:33px!important;
    width:540px!important;
    height:316px!important;
    transform:none!important;
}

body.cz-map-body #content.map #map #map_rulers{
    left:5px!important;
    top:34px!important;
    width:540px!important;
    height:316px!important;
    transform:none!important;
}


/* =========================================================
   مدينة الصفر v14.12 — ضبط نهائي لمواضع لوحات الخريطة
   فقط تحريك التفاصيل والبحث، بدون لمس هندسة الخريطة
   ========================================================= */

/* صعود تفاصيل الموقع أكثر */
body.cz-map-body #content.map #map_infobox,
body.cz-map-body #content.map #map_infobox.cz-map-infobox{
    top:-38px!important;
    right:18px!important;

    width:164px!important;
    min-width:164px!important;
    max-width:164px!important;

    z-index:90!important;
}

/* تنزيل مربع الإحداثيات والبحث أكثر */
body.cz-map-body #content.map #map_coords,
body.cz-map-body #content.map #map_coords.cz-map-coords{
    left:30px!important;
    bottom:-42px!important;
    top:auto!important;
    right:auto!important;

    width:270px!important;
    z-index:80!important;
}

/* زيادة المساحة السفلية حتى يبقى مربع البحث داخل البطاقة */
body.cz-map-body #content.map #map{
    margin-bottom:118px!important;
}

/* زيادة ارتفاع بطاقة الخريطة لاستيعاب النزول الجديد */
body.cz-map-body #content.map,
body.cz-map-body #content.map.cz-map-page{
    min-height:690px!important;
    padding-bottom:42px!important;
}

/* تأكيد عدم لمس هندسة البلاطات ومناطق hover */
body.cz-map-body #content.map #map_content{
    left:5px!important;
    top:33px!important;
    width:540px!important;
    height:316px!important;
    margin:0!important;
    transform:none!important;
}

body.cz-map-body #content.map #map img#map_links{
    left:5px!important;
    top:33px!important;
    width:540px!important;
    height:316px!important;
    transform:none!important;
}

body.cz-map-body #content.map #map #map_rulers{
    left:5px!important;
    top:34px!important;
    width:540px!important;
    height:316px!important;
    transform:none!important;
}


/* =========================================================
   مدينة الصفر v14.14 — باحث القمح / الواحات / إرسال القوات
   ========================================================= */

/* ----- Crop Finder ----- */
body.cz-crop-body #res{position:relative!important;top:auto!important;left:auto!important;right:auto!important;width:100%!important;margin:0!important;height:48px!important;min-height:48px!important;background:#fffaf1!important;border-bottom:1px solid #dfd2bc!important;}
body.cz-crop-body #mid{width:1080px!important;max-width:1080px!important;margin:0 auto!important;padding-top:28px!important;position:relative!important;}
body.cz-crop-body #content.cz-crop-page{float:none!important;width:650px!important;min-height:560px!important;margin:0 auto!important;padding:22px 24px 30px!important;box-sizing:border-box!important;background:#fffdf9!important;border:1px solid #d8c9b3!important;border-radius:16px!important;box-shadow:0 10px 28px rgba(72,56,31,.10)!important;direction:rtl!important;}
.cz-crop-page h1{margin:0 0 18px!important;padding:0 0 14px!important;text-align:center!important;color:#064a34!important;font-size:28px!important;border-bottom:1px solid #d2a02c!important;}
.cz-crop-hero{display:flex!important;justify-content:center!important;gap:16px!important;margin:8px 0 20px!important;}
.cz-crop-picture{width:190px!important;padding:8px!important;text-align:center!important;background:#faf4e9!important;border:1px solid #dfd2bc!important;border-radius:12px!important;}
.cz-crop-picture img{display:block!important;width:170px!important;height:170px!important;object-fit:cover!important;margin:0 auto 6px!important;border-radius:9px!important;}
.cz-crop-picture b{color:#07583e!important;font-size:12px!important;}
.cz-crop-form{padding:14px!important;background:#f8f2e7!important;border:1px solid #decfb7!important;border-radius:12px!important;margin-bottom:18px!important;}
.cz-crop-row{display:flex!important;align-items:center!important;justify-content:flex-start!important;gap:13px!important;min-height:42px!important;border-bottom:1px solid #eadfce!important;color:#203a30!important;font-size:12px!important;}
.cz-crop-row:last-child{border-bottom:0!important;}
.cz-crop-label{min-width:90px!important;font-weight:700!important;color:#064a34!important;}
.cz-crop-row label{display:inline-flex!important;align-items:center!important;gap:5px!important;}
.cz-crop-row input[type=text]{width:58px!important;height:31px!important;border:1px solid #d0c0a8!important;border-radius:6px!important;text-align:center!important;background:#fff!important;}
.cz-crop-row button{height:32px!important;padding:0 22px!important;border:1px solid #c79f3f!important;border-radius:7px!important;background:#fff4d8!important;color:#064a34!important;font-weight:700!important;cursor:pointer!important;}
.cz-crop-results-title{padding:10px 12px!important;background:#164b38!important;color:#fff!important;border-radius:10px 10px 0 0!important;font-weight:700!important;text-align:right!important;}
table.cz-crop-results{width:100%!important;border-collapse:separate!important;border-spacing:0!important;border:1px solid #dfd2bc!important;border-top:0!important;border-radius:0 0 10px 10px!important;overflow:hidden!important;}
.cz-crop-results th{padding:9px 7px!important;background:#0b684c!important;color:#fff!important;font-size:11px!important;text-align:center!important;}
.cz-crop-results td{padding:9px 7px!important;border-bottom:1px solid #eee4d6!important;color:#263c32!important;text-align:center!important;font-size:11px!important;background:#fffdf9!important;}
.cz-crop-results tr:last-child td{border-bottom:0!important;}
.cz-crop-results a{color:#07583e!important;font-weight:700!important;text-decoration:none!important;}
.cz-crop-type,.cz-status{display:inline-block!important;padding:4px 8px!important;border-radius:999px!important;font-weight:700!important;}
.cz-crop-type.c15{background:#fff0bd!important;color:#835c00!important}.cz-crop-type.c9{background:#e9f4e8!important;color:#19623e!important}
.cz-status.free{background:#e6f5e9!important;color:#17663a!important}.cz-status.occupied{background:#fbe8e3!important;color:#a13f2c!important}

/* ----- Oasis / village detail ----- */
#content.map.cz-vilview-page{float:none!important;width:650px!important;max-width:650px!important;min-height:560px!important;margin:0 auto!important;padding:22px 24px 28px!important;box-sizing:border-box!important;background:#fffdf9!important;border:1px solid #d8c9b3!important;border-radius:16px!important;box-shadow:0 10px 28px rgba(72,56,31,.10)!important;direction:rtl!important;overflow:hidden!important;}
.cz-vilview-page h1{margin:0 0 20px!important;padding:0 0 14px!important;text-align:center!important;color:#064a34!important;font-size:27px!important;border-bottom:1px solid #d2a02c!important;}
.cz-vilview-page #detailed_map{float:left!important;width:315px!important;height:315px!important;margin:8px 0 18px 22px!important;}
.cz-vilview-page #map_details{float:none!important;width:auto!important;min-height:315px!important;margin:0!important;padding:8px 0!important;direction:rtl!important;text-align:right!important;}
.cz-vilview-page #map_details table{width:250px!important;margin:0 0 10px auto!important;border:1px solid #dfd2bd!important;border-radius:9px!important;overflow:hidden!important;background:#fffdf9!important;border-collapse:separate!important;border-spacing:0!important;}
.cz-vilview-page #map_details thead th{padding:8px 10px!important;background:#164b38!important;color:#fff!important;font-size:11px!important;text-align:right!important;}
.cz-vilview-page #map_details tbody th,.cz-vilview-page #map_details tbody td{padding:7px 8px!important;border-bottom:1px solid #eee4d6!important;color:#233a30!important;font-size:11px!important;opacity:1!important;text-align:right!important;}
.cz-vilview-page #map_details tbody th{width:82px!important;background:#faf4e9!important;color:#07583e!important;font-weight:700!important;}
.cz-vilview-page #options{clear:both!important;width:100%!important;margin:14px 0 0!important;padding:0!important;border:1px solid #dfd2bd!important;border-radius:10px!important;background:#fffdf9!important;overflow:hidden!important;direction:rtl!important;}
.cz-vilview-page #options thead th{padding:9px 12px!important;background:#164b38!important;color:#fff!important;text-align:right!important;}
.cz-vilview-page #options tbody td{padding:8px 12px!important;border-bottom:1px solid #eee4d6!important;text-align:right!important;}
.cz-vilview-page #options a{color:#55b900!important;font-weight:700!important;text-decoration:none!important;}

/* ----- Send troops / attack ----- */
body.cz-a2b-body #res{position:relative!important;top:auto!important;left:auto!important;right:auto!important;width:100%!important;margin:0!important;height:48px!important;min-height:48px!important;background:#fffaf1!important;border-bottom:1px solid #dfd2bc!important;}
body.cz-a2b-body #mid{width:1080px!important;max-width:1080px!important;margin:0 auto!important;padding-top:28px!important;position:relative!important;}
body.cz-a2b-body #content.cz-a2b-page{float:none!important;width:650px!important;max-width:650px!important;min-height:540px!important;margin:0 auto!important;padding:22px 24px 30px!important;box-sizing:border-box!important;background:#fffdf9!important;border:1px solid #d8c9b3!important;border-radius:16px!important;box-shadow:0 10px 28px rgba(72,56,31,.10)!important;direction:rtl!important;}
.cz-a2b-page h1{margin:0 0 18px!important;padding:0 0 14px!important;text-align:center!important;color:#064a34!important;font-size:28px!important;border-bottom:1px solid #d2a02c!important;}
.cz-a2b-page #troops{width:100%!important;margin:0 0 16px!important;padding:10px!important;background:#f8f2e7!important;border:1px solid #decfb7!important;border-radius:10px!important;border-spacing:8px!important;}
.cz-a2b-page #troops td{padding:8px!important;background:#fffdf9!important;border:1px solid #eadfce!important;border-radius:8px!important;text-align:center!important;white-space:nowrap!important;}
.cz-a2b-page #troops input.text{width:54px!important;height:29px!important;border:1px solid #9edb45!important;border-radius:5px!important;text-align:center!important;background:#fff!important;}
.cz-a2b-page #coords{width:100%!important;margin:0!important;padding:12px!important;background:#f8f2e7!important;border:1px solid #decfb7!important;border-radius:10px!important;border-spacing:0!important;direction:rtl!important;}
.cz-a2b-page #coords td{padding:9px 10px!important;border-bottom:1px solid #e7dac7!important;background:transparent!important;color:#233a30!important;font-size:12px!important;}
.cz-a2b-page #coords tr:last-child td{border-bottom:0!important;}
.cz-a2b-page #coords .sel{width:44%!important}.cz-a2b-page #coords .vil,.cz-a2b-page #coords .target{width:56%!important}
.cz-a2b-page #coords input.text{height:31px!important;border:1px solid #d0c0a8!important;border-radius:6px!important;background:#fff!important;text-align:center!important;}
.cz-a2b-page .cz-a2b-send{display:block!important;min-width:110px!important;height:36px!important;margin:14px auto 0!important;border:1px solid #c79f3f!important;border-radius:7px!important;background:#fff4d8!important;color:#064a34!important;font-weight:700!important;cursor:pointer!important;}
.cz-a2b-page #short_info,.cz-a2b-page table.troop_details{width:100%!important;margin:0 0 14px!important;border:1px solid #dfd2bd!important;border-radius:9px!important;overflow:hidden!important;border-collapse:separate!important;border-spacing:0!important;}
.cz-a2b-page #short_info th,.cz-a2b-page #short_info td,.cz-a2b-page .troop_details th,.cz-a2b-page .troop_details td{padding:7px 8px!important;border-bottom:1px solid #eee4d6!important;color:#233a30!important;text-align:center!important;}
.cz-a2b-page #short_info th{background:#faf4e9!important;color:#07583e!important;text-align:right!important;}
.cz-a2b-page .troop_details thead td{background:#164b38!important;color:#fff!important;font-weight:700!important;}


/* =========================================================
   مدينة الصفر v14.15 — صفحة الموارد
   ========================================================= */

body.cz-resources-body #mid{
    width:1080px!important;
    max-width:1080px!important;
    margin:0 auto!important;
    padding-top:28px!important;
    position:relative!important;
}

body.cz-resources-body #content.village1.cz-resources-page{
    float:none!important;
    width:650px!important;
    max-width:650px!important;
    min-height:520px!important;
    margin:0 auto!important;
    padding:22px 24px 26px!important;
    box-sizing:border-box!important;
    background:#fffdf9!important;
    border:1px solid #d8c9b3!important;
    border-radius:16px!important;
    box-shadow:0 10px 28px rgba(72,56,31,.10)!important;
    direction:rtl!important;
    overflow:visible!important;
}

body.cz-resources-body #content.village1 h1{
    margin:0 0 8px!important;
    padding:0 0 14px!important;
    border-bottom:1px solid #d2a02c!important;
    color:#064a34!important;
    text-align:center!important;
    font:700 28px/1.25 Tahoma,Arial,sans-serif!important;
    position:relative!important;
}

body.cz-resources-body #content.village1 h1:after{
    content:""!important;
    width:8px!important;
    height:8px!important;
    background:#d2a02c!important;
    position:absolute!important;
    left:50%!important;
    bottom:-4px!important;
    transform:translateX(-50%) rotate(45deg)!important;
}

body.cz-resources-body #cap{
    height:30px!important;
    margin:4px 0 8px!important;
    text-align:center!important;
}

body.cz-resources-body .cz-capital-badge{
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    padding:5px 11px!important;
    border:1px solid #d7b45b!important;
    border-radius:999px!important;
    background:#fff3cf!important;
    color:#70540b!important;
    font:700 10px Tahoma,Arial,sans-serif!important;
}

/* Village map: preserve the exact image map geometry */
body.cz-resources-body #village_map.cz-village-map{
    float:left!important;
    position:relative!important;
    width:300px!important;
    height:300px!important;
    margin:12px 0 14px 0!important;
    padding:10px!important;
    box-sizing:content-box!important;
    background:#fbf7ef!important;
    border:1px solid #e2d5c1!important;
    border-radius:14px!important;
    box-shadow:0 7px 18px rgba(70,55,32,.08)!important;
}

body.cz-resources-body #village_map #resfeld{
    position:absolute!important;
    left:10px!important;
    top:10px!important;
}

/* details column */
body.cz-resources-body .cz-resource-details{
    float:right!important;
    width:250px!important;
    margin:12px 0 0!important;
    padding:0!important;
}

/* production and troops cards */
body.cz-resources-body .cz-production-card,
body.cz-resources-body .cz-troops-card{
    width:100%!important;
    margin:0 0 12px!important;
    background:#fffaf2!important;
    border:1px solid #d9cdb8!important;
    border-radius:12px!important;
    overflow:hidden!important;
    box-shadow:0 5px 15px rgba(61,48,29,.07)!important;
}

body.cz-resources-body .cz-card-title{
    padding:10px 12px!important;
    background:#164532!important;
    color:#fff!important;
    font:700 12px Tahoma,Arial,sans-serif!important;
    text-align:right!important;
}

body.cz-resources-body .cz-production-grid{
    padding:5px 0!important;
}

body.cz-resources-body .cz-prod-row{
    min-height:36px!important;
    display:grid!important;
    grid-template-columns:1fr 58px 52px!important;
    align-items:center!important;
    gap:6px!important;
    padding:4px 10px!important;
    border-bottom:1px solid #eee4d5!important;
    color:#244033!important;
    font:600 10.5px Tahoma,Arial,sans-serif!important;
}

body.cz-resources-body .cz-prod-row:last-child{
    border-bottom:0!important;
}

body.cz-resources-body .cz-prod-name{
    display:flex!important;
    align-items:center!important;
    gap:6px!important;
}

body.cz-resources-body .cz-prod-row strong{
    color:#a07000!important;
    font-size:12px!important;
    text-align:center!important;
}

body.cz-resources-body .cz-prod-row > span:last-child{
    color:#6e756f!important;
    font-weight:400!important;
}

/* troops */
body.cz-resources-body .cz-troops-list{
    padding:5px 0!important;
}

body.cz-resources-body .cz-troop-row{
    min-height:38px!important;
    display:grid!important;
    grid-template-columns:30px 42px 1fr!important;
    align-items:center!important;
    gap:6px!important;
    padding:4px 10px!important;
    border-bottom:1px solid #eee4d5!important;
    color:#244033!important;
    font:600 10.5px Tahoma,Arial,sans-serif!important;
}

body.cz-resources-body .cz-troop-row:last-child{
    border-bottom:0!important;
}

body.cz-resources-body .cz-troop-row strong{
    color:#9b6c00!important;
    text-align:center!important;
}

body.cz-resources-body .cz-empty-troops{
    padding:18px 12px!important;
    color:#68756d!important;
    text-align:center!important;
    font:600 10.5px Tahoma,Arial,sans-serif!important;
}

/* clear floats and eliminate old blank vertical space */
body.cz-resources-body #content.village1:after{
    content:""!important;
    display:block!important;
    clear:both!important;
}

body.cz-resources-body #content.village1 br{
    line-height:0!important;
}

/* side panels remain in their established columns */
body.cz-resources-body #side_navi{
    position:absolute!important;
    right:0!important;
    top:28px!important;
    width:185px!important;
}

body.cz-resources-body #side_info{
    position:absolute!important;
    left:0!important;
    top:28px!important;
    width:185px!important;
}

/* remove legacy table styling if cached */
body.cz-resources-body #production,
body.cz-resources-body #troops{
    border-collapse:separate!important;
}

/* responsive */
@media(max-width:1120px){
    body.cz-resources-body #mid{
        width:1000px!important;
        max-width:1000px!important;
    }

    body.cz-resources-body #content.village1.cz-resources-page{
        width:630px!important;
        max-width:630px!important;
    }

    body.cz-resources-body .cz-resource-details{
        width:235px!important;
    }
}


/* =========================================================
   مدينة الصفر v14.16 — استرجاع صورة حقول الموارد
   ========================================================= */

/*
  مهم:
  صورة الحقول الأصلية في Travian مرسومة كـ background-image
  على #village_map / classes المرتبطة به.
  لذلك نمنع أي background shorthand من تغطيتها.
*/
body.cz-resources-body #village_map.cz-village-map,
body.cz-resources-body #village_map{
    background-color:transparent!important;
    /* لا تستخدم background: ... هنا */
    background-repeat:no-repeat!important;

    /* رجوع هندسة ترافيان الأصلية حتى الصورة + مناطق النقر تتطابق */
    width:540px!important;
    height:300px!important;
    padding:0!important;
    margin:12px auto 18px!important;
    float:none!important;
    box-sizing:content-box!important;

    border:0!important;
    border-radius:0!important;
    box-shadow:none!important;
}

/* resfeld هو طبقة النقر/الأرقام فوق صورة الحقول */
body.cz-resources-body #village_map #resfeld{
    position:absolute!important;
    left:0!important;
    top:0!important;
    width:540px!important;
    height:300px!important;
    margin:0!important;
    padding:0!important;
}

/*
  نخلي الإنتاج والقوات تحت صورة الحقول بدل جنبها،
  حتى ما نضغط مساحة الخريطة ونكسر هندستها.
*/
body.cz-resources-body .cz-resource-details{
    float:none!important;
    width:100%!important;
    margin:14px 0 0!important;
    display:grid!important;
    grid-template-columns:1fr 1fr!important;
    gap:14px!important;
}

body.cz-resources-body .cz-production-card,
body.cz-resources-body .cz-troops-card{
    width:auto!important;
    margin:0!important;
}

/* البطاقة الرئيسية أوسع حتى تستوعب خريطة الحقول الأصلية */
body.cz-resources-body #content.village1.cz-resources-page{
    width:650px!important;
    max-width:650px!important;
    min-height:660px!important;
    padding:22px 24px 28px!important;
}

/* منع أي صورة داخلية من تمديد نفسها */
body.cz-resources-body #village_map img{
    max-width:none!important;
    height:auto!important;
}

/* الحفاظ على أرقام المستويات فوق الصورة */
body.cz-resources-body #village_map a,
body.cz-resources-body #village_map .level{
    z-index:5!important;
}

@media(max-width:1120px){
    body.cz-resources-body #village_map.cz-village-map,
    body.cz-resources-body #village_map{
        width:540px!important;
        height:300px!important;
    }
}


/* =========================================================
   مدينة الصفر v14.17 — موارد: صورة الحقول + التخطيط الجانبي
   ========================================================= */

/* البطاقة الرئيسية */
body.cz-resources-body #content.village1.cz-resources-page{
    width:650px!important;
    max-width:650px!important;
    min-height:500px!important;
    padding:22px 24px 26px!important;
}

/* صورة الحقول ترجع للقياس الأصلي لتطابق الـ image map */
body.cz-resources-body #village_map.cz-village-map,
body.cz-resources-body #village_map{
    float:left!important;
    position:relative!important;

    width:300px!important;
    height:264px!important;

    margin:18px 0 18px 0!important;
    padding:0!important;

    box-sizing:content-box!important;

    border:1px solid #dfd2bc!important;
    border-radius:14px!important;
    box-shadow:0 7px 18px rgba(70,55,32,.08)!important;

    background-color:transparent!important;
    background-repeat:no-repeat!important;
    background-position:0 0!important;
    background-size:300px 264px!important;

    overflow:hidden!important;
}

/* ربط نوع الحقول بالصورة الأصلية */
body.cz-resources-body #village_map.f1{background-image:url("../img/g/f1.jpg")!important;}
body.cz-resources-body #village_map.f2{background-image:url("../img/g/f2.jpg")!important;}
body.cz-resources-body #village_map.f3{background-image:url("../img/g/f3.jpg")!important;}
body.cz-resources-body #village_map.f4{background-image:url("../img/g/f4.jpg")!important;}
body.cz-resources-body #village_map.f5{background-image:url("../img/g/f5.jpg")!important;}
body.cz-resources-body #village_map.f6{background-image:url("../img/g/f6.jpg")!important;}
body.cz-resources-body #village_map.f7{background-image:url("../img/g/f7.jpg")!important;}
body.cz-resources-body #village_map.f8{background-image:url("../img/g/f8.jpg")!important;}
body.cz-resources-body #village_map.f9{background-image:url("../img/g/f9.jpg")!important;}
body.cz-resources-body #village_map.f10{background-image:url("../img/g/f10.jpg")!important;}
body.cz-resources-body #village_map.f11{background-image:url("../img/g/f11.jpg")!important;}
body.cz-resources-body #village_map.f12{background-image:url("../img/g/f12.jpg")!important;}

/* طبقة النقر الأصلية */
body.cz-resources-body #village_map #resfeld{
    position:absolute!important;
    left:0!important;
    top:0!important;
    width:300px!important;
    height:264px!important;
    margin:0!important;
    padding:0!important;
    z-index:20!important;
}

/* مستويات الحقول تبقى فوق الصورة */
body.cz-resources-body #village_map img.reslevel{
    position:absolute!important;
    z-index:30!important;
}

/* تفاصيل الموارد ترجع يمين الصورة */
body.cz-resources-body .cz-resource-details{
    float:right!important;
    display:block!important;

    width:250px!important;
    margin:18px 0 0!important;
    padding:0!important;
}

/* الإنتاج والقوات واحد تحت الثاني بالجانب */
body.cz-resources-body .cz-production-card,
body.cz-resources-body .cz-troops-card{
    width:250px!important;
    margin:0 0 12px!important;
}

/* تصغير بسيط حتى يكون التنسيق متوازن */
body.cz-resources-body .cz-prod-row{
    grid-template-columns:1fr 55px 48px!important;
    min-height:34px!important;
    padding:3px 9px!important;
}

body.cz-resources-body .cz-empty-troops{
    padding:16px 10px!important;
}

/* تنظيف الفراغ بعد العمودين */
body.cz-resources-body #content.village1:after{
    content:""!important;
    display:block!important;
    clear:both!important;
}

/* لا تسمح لقواعد v14.16 بإرجاع الموارد للأسفل */
body.cz-resources-body .cz-resource-details{
    grid-template-columns:none!important;
    gap:0!important;
}

/* الحفاظ على الشارة والعنوان */
body.cz-resources-body #cap{
    margin-bottom:4px!important;
}

/* شاشات أصغر */
@media(max-width:1120px){
    body.cz-resources-body #content.village1.cz-resources-page{
        width:630px!important;
        max-width:630px!important;
    }

    body.cz-resources-body .cz-resource-details{
        width:240px!important;
    }

    body.cz-resources-body .cz-production-card,
    body.cz-resources-body .cz-troops-card{
        width:240px!important;
    }
}


/* =========================================================
   مدينة الصفر v14.18 — تطوير حقول الموارد RTL
   ========================================================= */

body.cz-build-body #mid{
    width:1080px!important;
    max-width:1080px!important;
    margin:0 auto!important;
    padding-top:28px!important;
    position:relative!important;
}

body.cz-build-body #content.build.cz-build-page{
    float:none!important;
    width:650px!important;
    max-width:650px!important;
    min-height:520px!important;
    margin:0 auto!important;
    padding:22px 24px 28px!important;
    box-sizing:border-box!important;

    background:#fffdf9!important;
    border:1px solid #d8c9b3!important;
    border-radius:16px!important;
    box-shadow:0 10px 28px rgba(72,56,31,.10)!important;

    direction:rtl!important;
    text-align:right!important;
    font-family:Tahoma,Arial,sans-serif!important;
    color:#17382c!important;
    overflow:visible!important;
}

/* Resource build card only */
body.cz-build-body #content.build .cz-resource-build{
    width:100%!important;
    margin:0!important;
    padding:0!important;
    direction:rtl!important;
    text-align:right!important;
}

/* Header area */
body.cz-build-body .cz-resource-build-head{
    display:flex!important;
    flex-direction:row!important;
    align-items:center!important;
    gap:18px!important;
    min-height:108px!important;
    margin:0 0 16px!important;
    padding:14px 16px!important;

    background:#fbf7ef!important;
    border:1px solid #ded1bc!important;
    border-radius:13px!important;
    box-shadow:0 5px 14px rgba(64,49,28,.06)!important;
}

body.cz-build-body .cz-resource-logo{
    flex:0 0 82px!important;
    width:82px!important;
    height:82px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    margin:0!important;
    padding:0!important;
}

body.cz-build-body .cz-resource-logo img.building{
    position:static!important;
    margin:0!important;
    float:none!important;
}

body.cz-build-body .cz-resource-heading{
    flex:1!important;
    min-width:0!important;
}

body.cz-build-body .cz-resource-heading h1{
    margin:0 0 8px!important;
    padding:0 0 10px!important;
    border-bottom:1px solid #d3a234!important;

    color:#07563d!important;
    font-size:24px!important;
    line-height:1.3!important;
    font-weight:700!important;
    text-align:right!important;
}

body.cz-build-body .cz-resource-heading h1 .level{
    display:inline-block!important;
    margin-right:7px!important;
    padding:4px 9px!important;

    background:#fff1c9!important;
    border:1px solid #d9b85e!important;
    border-radius:999px!important;

    color:#795600!important;
    font-size:10px!important;
    font-weight:700!important;
    vertical-align:middle!important;
}

body.cz-build-body .cz-resource-heading .build_desc{
    margin:0!important;
    padding:0!important;
    color:#475a51!important;
    font-size:11px!important;
    line-height:1.9!important;
    text-align:right!important;
}

/* Production */
body.cz-build-body .cz-resource-production{
    margin:0 0 14px!important;
    border:1px solid #ded1bc!important;
    border-radius:12px!important;
    overflow:hidden!important;
    background:#fffaf2!important;
    box-shadow:0 5px 14px rgba(64,49,28,.05)!important;
}

body.cz-build-body .cz-section-title{
    padding:10px 13px!important;
    background:#164532!important;
    color:#fff!important;
    font-size:12px!important;
    font-weight:700!important;
    text-align:right!important;
}

body.cz-build-body #build_value{
    width:100%!important;
    margin:0!important;
    border-collapse:collapse!important;
    direction:rtl!important;
    background:transparent!important;
}

body.cz-build-body #build_value th,
body.cz-build-body #build_value td{
    height:42px!important;
    padding:8px 12px!important;
    border:0!important;
    border-bottom:1px solid #eee3d3!important;
    background:transparent!important;
    color:#294538!important;
    font-size:11px!important;
    text-align:right!important;
    vertical-align:middle!important;
}

body.cz-build-body #build_value th{
    width:54%!important;
    font-weight:700!important;
}

body.cz-build-body #build_value td{
    text-align:left!important;
    direction:rtl!important;
}

body.cz-build-body #build_value td strong{
    color:#a77300!important;
    font-size:14px!important;
    font-weight:700!important;
}

body.cz-build-body #build_value td span{
    color:#778079!important;
    font-size:10px!important;
}

body.cz-build-body #build_value tr:last-child th,
body.cz-build-body #build_value tr:last-child td{
    border-bottom:0!important;
}

/* Upgrade box */
body.cz-build-body .cz-resource-upgrade{
    margin:0!important;
    padding:14px 16px!important;

    background:#f8f3e9!important;
    border:1px solid #d9c9ae!important;
    border-radius:12px!important;

    direction:rtl!important;
    text-align:right!important;
}

body.cz-build-body .cz-resource-upgrade #contract{
    margin:0!important;
    padding:0!important;
    color:#294538!important;
    font-size:11px!important;
    line-height:2.15!important;
    direction:rtl!important;
    text-align:right!important;
}

body.cz-build-body .cz-upgrade-title{
    display:block!important;
    margin-bottom:7px!important;
    color:#07563d!important;
    font-size:12px!important;
    font-weight:700!important;
}

/* Keep icon/value sequence visually RTL-friendly */
body.cz-build-body .cz-resource-upgrade img.r1,
body.cz-build-body .cz-resource-upgrade img.r2,
body.cz-build-body .cz-resource-upgrade img.r3,
body.cz-build-body .cz-resource-upgrade img.r4,
body.cz-build-body .cz-resource-upgrade img.r5,
body.cz-build-body .cz-resource-upgrade img.clock,
body.cz-build-body .cz-resource-upgrade img.npc{
    vertical-align:middle!important;
    margin:0 3px!important;
}

body.cz-build-body .cz-resource-upgrade .little_res{
    display:inline-block!important;
    min-width:30px!important;
    color:#805c00!important;
    font-weight:700!important;
    text-align:center!important;
}

body.cz-build-body .cz-resource-upgrade a.build{
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    min-height:34px!important;
    margin-top:10px!important;
    padding:0 16px!important;

    background:#075b40!important;
    border:1px solid #c89e35!important;
    border-radius:7px!important;

    color:#fff!important;
    font-size:11px!important;
    font-weight:700!important;
    text-decoration:none!important;
}

body.cz-build-body .cz-resource-upgrade a.build:hover{
    background:#0a6b4c!important;
    color:#ffd761!important;
}

/* Disabled/status messages */
body.cz-build-body .cz-resource-upgrade span.none,
body.cz-build-body .cz-resource-upgrade font{
    color:#777f79!important;
    font-size:10px!important;
}

/* Building queue */
body.cz-build-body #building_contract{
    width:100%!important;
    margin:0 0 15px!important;
    direction:rtl!important;
    border-collapse:separate!important;
    border-spacing:0!important;
    border:1px solid #d8c9b3!important;
    border-radius:10px!important;
    overflow:hidden!important;
}

body.cz-build-body #building_contract thead th{
    padding:9px 12px!important;
    background:#164532!important;
    color:#fff!important;
    text-align:right!important;
}

body.cz-build-body #building_contract tbody td{
    padding:7px 9px!important;
    background:#fffaf2!important;
    border-bottom:1px solid #eee3d3!important;
    color:#294538!important;
    text-align:right!important;
    font-size:10px!important;
}

/* Do not let old LTR rules override resource pages */
body.cz-build-body .cz-resource-build,
body.cz-build-body .cz-resource-build *{
    unicode-bidi:normal!important;
}

body.cz-build-body #side_navi{
    position:absolute!important;
    right:0!important;
    top:28px!important;
    width:185px!important;
}

body.cz-build-body #side_info{
    position:absolute!important;
    left:0!important;
    top:28px!important;
    width:185px!important;
}

@media(max-width:1120px){
    body.cz-build-body #mid{
        width:1000px!important;
        max-width:1000px!important;
    }

    body.cz-build-body #content.build.cz-build-page{
        width:630px!important;
        max-width:630px!important;
    }
}


/* =========================================================
   مدينة الصفر v14.19
   إصلاح مكان صفحة التطوير + شريط الموارد + هندسة حقول القرية
   ========================================================= */

/* ---------- build.php: resource bar in normal document flow ---------- */
body.cz-build-body #res,
body.cz-build-body #res.cz-resbar-v8{
    position:relative!important;
    top:auto!important;
    left:auto!important;
    right:auto!important;

    width:100%!important;
    min-width:0!important;
    height:48px!important;
    min-height:48px!important;

    margin:0!important;
    padding:0!important;

    z-index:90!important;
    display:block!important;

    background:#fffaf1!important;
    border-bottom:1px solid #dfd2bc!important;
    box-shadow:0 2px 8px rgba(63,54,36,.06)!important;
}

/* resource contents remain centered and never cover content */
body.cz-build-body #resWrap,
body.cz-build-body #resWrap.cz-reswrap-v8{
    position:relative!important;
    top:auto!important;
    left:auto!important;
    right:auto!important;

    width:760px!important;
    max-width:calc(100% - 40px)!important;
    height:48px!important;

    margin:0 auto!important;
    padding:0!important;

    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:18px!important;

    direction:ltr!important;
}

/* Page starts immediately below resource bar */
body.cz-build-body #mid{
    width:1080px!important;
    max-width:1080px!important;
    margin:0 auto!important;
    padding-top:28px!important;
    position:relative!important;
}

/* Same central column position as dorf1 */
body.cz-build-body #content.build.cz-build-page{
    width:650px!important;
    max-width:650px!important;
    margin:0 auto!important;
    float:none!important;
    position:relative!important;
    top:auto!important;
    left:auto!important;
    right:auto!important;
}

/* Side panels locked to same columns as resources page */
body.cz-build-body #side_navi{
    position:absolute!important;
    right:0!important;
    left:auto!important;
    top:28px!important;
    width:185px!important;
    margin:0!important;
}

body.cz-build-body #side_info{
    position:absolute!important;
    left:0!important;
    right:auto!important;
    top:28px!important;
    width:185px!important;
    margin:0!important;
}

/* ---------- dorf1: exact Travian field geometry lock ---------- */
/*
   The clickable transparent image and the field background must be exactly
   300x264 with zero scaling. This is the same fix principle as the map page.
*/
body.cz-resources-body #village_map,
body.cz-resources-body #village_map.cz-village-map{
    position:relative!important;
    width:300px!important;
    min-width:300px!important;
    max-width:300px!important;
    height:264px!important;
    min-height:264px!important;
    max-height:264px!important;

    padding:0!important;
    margin:18px 0 18px 0!important;

    transform:none!important;
    scale:none!important;
    zoom:1!important;

    background-position:0 0!important;
    background-repeat:no-repeat!important;
    background-size:300px 264px!important;

    direction:ltr!important;
    overflow:visible!important;
    box-sizing:content-box!important;
}

/* Exact hit-map layer */
body.cz-resources-body #village_map #resfeld{
    position:absolute!important;
    left:0!important;
    top:0!important;

    width:300px!important;
    min-width:300px!important;
    max-width:300px!important;
    height:264px!important;
    min-height:264px!important;
    max-height:264px!important;

    margin:0!important;
    padding:0!important;

    display:block!important;
    transform:none!important;
    scale:none!important;
    zoom:1!important;

    z-index:20!important;
    opacity:1!important;
}

/* Level sprites keep original absolute coordinates */
body.cz-resources-body #village_map img.reslevel{
    position:absolute!important;
    width:17px!important;
    height:12px!important;
    max-width:none!important;
    transform:none!important;
    scale:none!important;
    zoom:1!important;
    z-index:30!important;
}

/* Never let generic responsive image rules resize the hit map */
body.cz-resources-body #village_map img#resfeld,
body.cz-resources-body #village_map img.reslevel{
    max-width:none!important;
}

/* Building queue card on resource/build pages */
body.cz-resources-body #building_contract,
body.cz-build-body #building_contract{
    direction:rtl!important;
    text-align:right!important;
}

@media(max-width:1120px){
    body.cz-build-body #mid{
        width:1000px!important;
        max-width:1000px!important;
    }

    body.cz-build-body #content.build.cz-build-page{
        width:630px!important;
        max-width:630px!important;
    }
}


/* =========================================================
   مدينة الصفر v14.20 — تطابق الحقول والضغط 100%
   نفس هندسة Travian الأصلية حرفياً
   ========================================================= */

/* الحاوية الأصلية بلا أي مؤثر بصري يغير نظام الإحداثيات */
body.cz-resources-body div.village1 div#village_map,
body.cz-resources-body #village_map{
    position:relative!important;
    float:left!important;

    width:300px!important;
    min-width:300px!important;
    max-width:300px!important;
    height:264px!important;
    min-height:264px!important;
    max-height:264px!important;

    margin:18px 0 15px 0!important;
    padding:0!important;

    border:0!important;
    border-radius:0!important;
    box-shadow:none!important;
    overflow:visible!important;

    transform:none!important;
    translate:none!important;
    scale:none!important;
    zoom:1!important;

    box-sizing:content-box!important;
    direction:ltr!important;

    background-position:0 0!important;
    background-repeat:no-repeat!important;
    background-size:auto!important;
}

/* صورة الحقول الأصلية — لا resize */
body.cz-resources-body #village_map.f1{background-image:url("../img/g/f1.jpg")!important;}
body.cz-resources-body #village_map.f2{background-image:url("../img/g/f2.jpg")!important;}
body.cz-resources-body #village_map.f3{background-image:url("../img/g/f3.jpg")!important;}
body.cz-resources-body #village_map.f4{background-image:url("../img/g/f4.jpg")!important;}
body.cz-resources-body #village_map.f5{background-image:url("../img/g/f5.jpg")!important;}
body.cz-resources-body #village_map.f6{background-image:url("../img/g/f6.jpg")!important;}
body.cz-resources-body #village_map.f7{background-image:url("../img/g/f7.jpg")!important;}
body.cz-resources-body #village_map.f8{background-image:url("../img/g/f8.jpg")!important;}
body.cz-resources-body #village_map.f9{background-image:url("../img/g/f9.jpg")!important;}
body.cz-resources-body #village_map.f10{background-image:url("../img/g/f10.jpg")!important;}
body.cz-resources-body #village_map.f11{background-image:url("../img/g/f11.jpg")!important;}
body.cz-resources-body #village_map.f12{background-image:url("../img/g/f12.jpg")!important;}
body.cz-resources-body #village_map.f99{background-image:url("../img/g/f99.jpg")!important;}

/* طبقة النقر الأصلية فوق الصورة */
body.cz-resources-body div.village1 img#resfeld,
body.cz-resources-body #village_map img#resfeld{
    position:absolute!important;
    left:0!important;
    top:0!important;

    width:300px!important;
    min-width:300px!important;
    max-width:300px!important;
    height:264px!important;
    min-height:264px!important;
    max-height:264px!important;

    margin:0!important;
    padding:0!important;

    z-index:50!important;
    opacity:1!important;

    transform:none!important;
    translate:none!important;
    scale:none!important;
    zoom:1!important;

    max-width:none!important;
    object-fit:fill!important;
}

/* أرقام المستويات فوق الصورة بصرياً، لكن لا تستقبل الضغط */
body.cz-resources-body div.village1 img.reslevel,
body.cz-resources-body #village_map img.reslevel{
    position:absolute!important;
    width:17px!important;
    height:12px!important;
    z-index:60!important;
    pointer-events:none!important;

    margin:0!important;
    padding:0!important;
    max-width:none!important;

    transform:none!important;
    translate:none!important;
    scale:none!important;
    zoom:1!important;
}

/* مواقع ترافيان الأصلية rf1..rf18 */
body.cz-resources-body #village_map img.rf1{left:93px!important;top:27px!important;}
body.cz-resources-body #village_map img.rf2{left:156px!important;top:26px!important;}
body.cz-resources-body #village_map img.rf3{left:216px!important;top:41px!important;}
body.cz-resources-body #village_map img.rf4{left:38px!important;top:59px!important;}
body.cz-resources-body #village_map img.rf5{left:130px!important;top:67px!important;}
body.cz-resources-body #village_map img.rf6{left:195px!important;top:87px!important;}
body.cz-resources-body #village_map img.rf7{left:253px!important;top:81px!important;}
body.cz-resources-body #village_map img.rf8{left:23px!important;top:111px!important;}
body.cz-resources-body #village_map img.rf9{left:74px!important;top:104px!important;}
body.cz-resources-body #village_map img.rf10{left:205px!important;top:136px!important;}
body.cz-resources-body #village_map img.rf11{left:260px!important;top:139px!important;}
body.cz-resources-body #village_map img.rf12{left:33px!important;top:165px!important;}
body.cz-resources-body #village_map img.rf13{left:84px!important;top:158px!important;}
body.cz-resources-body #village_map img.rf14{left:151px!important;top:178px!important;}
body.cz-resources-body #village_map img.rf15{left:230px!important;top:192px!important;}
body.cz-resources-body #village_map img.rf16{left:79px!important;top:211px!important;}
body.cz-resources-body #village_map img.rf17{left:132px!important;top:223px!important;}
body.cz-resources-body #village_map img.rf18{left:182px!important;top:227px!important;}

/* مهم: لا نسمح لأي قاعدة عامة للصور بتغيير resfeld */
body.cz-resources-body #village_map > img{
    box-sizing:content-box!important;
}

/* map area نفسه لا يتأثر باتجاه RTL للصفحة */
body.cz-resources-body map#rx,
body.cz-resources-body map#rx area{
    direction:ltr!important;
}


/* =========================================================
   مدينة الصفر v14.21 — تعريب قائمة البناء بالكامل
   ========================================================= */

#building_contract.cz-building-queue{
    width:100%!important;
    margin:14px 0 0!important;
    direction:rtl!important;
    border-collapse:separate!important;
    border-spacing:0!important;
    border:1px solid #dccdb6!important;
    border-radius:11px!important;
    overflow:hidden!important;
    background:#fffaf2!important;
}

#building_contract.cz-building-queue thead th{
    padding:9px 12px!important;
    background:#164532!important;
    color:#fff!important;
    text-align:right!important;
    font:700 11px Tahoma,Arial,sans-serif!important;
}

#building_contract.cz-building-queue .cz-queue-title{
    margin-left:7px!important;
}

#building_contract.cz-building-queue tbody td{
    padding:8px 9px!important;
    border:0!important;
    border-bottom:1px solid #eee3d3!important;
    background:#fffaf2!important;
    color:#294538!important;
    font:600 10px Tahoma,Arial,sans-serif!important;
    vertical-align:middle!important;
    text-align:right!important;
}

#building_contract.cz-building-queue tbody tr:last-child td{
    border-bottom:0!important;
}

#building_contract.cz-building-queue td.ico{
    width:30px!important;
    text-align:center!important;
}

#building_contract.cz-building-queue .cz-queue-building{
    min-width:170px!important;
}

#building_contract.cz-building-queue .cz-queue-building strong{
    color:#07563d!important;
}

#building_contract.cz-building-queue .none{
    color:#7c817e!important;
    font-weight:400!important;
}

#building_contract.cz-building-queue .cz-waiting{
    color:#927000!important;
    font-size:9px!important;
}

#building_contract.cz-building-queue .cz-master-builder{
    display:inline-block!important;
    margin-right:5px!important;
    padding:2px 6px!important;
    border-radius:8px!important;
    background:#fff0bc!important;
    color:#795600!important;
    font-size:9px!important;
}

#building_contract.cz-building-queue .cz-queue-time,
#building_contract.cz-building-queue .cz-queue-finish{
    white-space:nowrap!important;
    text-align:center!important;
}

#building_contract.cz-building-queue .cz-time-label{
    color:#68736d!important;
}

#building_contract.cz-building-queue .cz-queue-finish strong{
    color:#996c00!important;
}


/* =========================================================
   مدينة الصفر v14.32 — تنسيق كل المباني
   ========================================================= */
body.cz-build-body #content.build,
body.cz-build-body #content.build #build{
    direction:rtl!important;
    text-align:right!important;
    font-family:Tahoma,Arial,sans-serif!important;
}
body.cz-build-body #content.build #build > h1{
    margin:0 0 12px!important;
    padding:0 0 12px!important;
    border-bottom:1px solid #d2a02c!important;
    color:#07563d!important;
    font-size:25px!important;
    font-weight:700!important;
    text-align:right!important;
}
body.cz-build-body #content.build #build h1 .level{
    display:inline-block!important;
    margin-right:7px!important;
    padding:4px 9px!important;
    background:#fff1c9!important;
    border:1px solid #d7b459!important;
    border-radius:999px!important;
    color:#785700!important;
    font-size:10px!important;
}
body.cz-build-body #content.build .build_logo{
    float:left!important;
    margin:0 14px 10px 0!important;
}
body.cz-build-body #content.build .build_desc{
    margin:0 0 16px!important;
    padding:12px 14px!important;
    min-height:48px!important;
    background:#fbf7ef!important;
    border:1px solid #e0d3be!important;
    border-radius:10px!important;
    color:#41574c!important;
    line-height:1.9!important;
    text-align:right!important;
}
body.cz-build-body #content.build table{
    width:100%!important;
    direction:rtl!important;
    border-collapse:separate!important;
    border-spacing:0!important;
    border:1px solid #ddcfb9!important;
    border-radius:10px!important;
    overflow:hidden!important;
    background:#fffaf2!important;
}
body.cz-build-body #content.build table thead td,
body.cz-build-body #content.build table thead th{
    padding:9px 10px!important;
    background:#164532!important;
    color:#fff!important;
    border:0!important;
    font-weight:700!important;
    text-align:right!important;
}
body.cz-build-body #content.build table tbody td,
body.cz-build-body #content.build table tbody th,
body.cz-build-body #content.build #build_value td,
body.cz-build-body #content.build #build_value th{
    padding:8px 10px!important;
    background:#fffaf2!important;
    color:#274438!important;
    border:0!important;
    border-bottom:1px solid #eee3d3!important;
    text-align:right!important;
    vertical-align:middle!important;
}
body.cz-build-body #content.build .details{
    direction:rtl!important;
    text-align:right!important;
    margin-top:5px!important;
}
body.cz-build-body #content.build .details span{
    display:inline-block!important;
    margin:2px 4px!important;
}
body.cz-build-body #content.build input[type="text"],
body.cz-build-body #content.build input[type="number"],
body.cz-build-body #content.build select{
    min-height:30px!important;
    border:1px solid #d6c8b2!important;
    border-radius:6px!important;
    background:#fff!important;
    color:#17382c!important;
    text-align:center!important;
}


/* =========================================================
   مدينة الصفر v14.49 — رأس المبنى متوازن للواجهة العربية
   ========================================================= */
body.cz-build-body #content.build #build{
    position:relative!important;
}

body.cz-build-body #content.build #build > a.build_logo,
body.cz-build-body #content.build a.build_logo{
    position:absolute!important;
    top:18px!important;
    right:18px!important;
    left:auto!important;
    float:none!important;
    margin:0!important;
    padding:0!important;
    width:104px!important;
    height:96px!important;
    z-index:4!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    transform:none!important;
}

body.cz-build-body #content.build a.build_logo img,
body.cz-build-body #content.build a.build_logo img.building{
    display:block!important;
    float:none!important;
    position:relative!important;
    left:auto!important;
    right:auto!important;
    top:auto!important;
    margin:0 auto!important;
    max-width:100px!important;
    max-height:94px!important;
    transform:none!important;
}

/* اترك مساحة ثابتة للصورة على اليمين في اتجاه RTL. */
body.cz-build-body #content.build #build > h1,
body.cz-build-body #content.build #build > .build_desc,
body.cz-build-body #content.build #build > p.build_desc{
    margin-right:122px!important;
    margin-left:0!important;
    box-sizing:border-box!important;
}

body.cz-build-body #content.build #build > h1{
    text-align:right!important;
    direction:rtl!important;
    min-height:48px!important;
}

body.cz-build-body #content.build .build_desc{
    text-align:right!important;
    direction:rtl!important;
}

/* Training and research tables */
body.cz-build-body #content.build table.build_details,
body.cz-build-body #content.build table.under_progress{
    clear:both!important;
    margin-top:14px!important;
}


/* =========================================================
   مدينة الصفر v14.34 — السوق: تعريب كامل + تقليل المسافات
   ========================================================= */

body.cz-build-body #content.build #build.gid17{
    padding-bottom:18px!important;
}

body.cz-build-body #content.build #build.gid17 #textmenu{
    display:flex!important;
    flex-wrap:wrap!important;
    gap:6px!important;
    justify-content:flex-start!important;
    align-items:center!important;
    direction:rtl!important;
    margin:6px 0 12px!important;
    padding:8px 10px!important;
    background:#fbf7ef!important;
    border:1px solid #e0d3be!important;
    border-radius:9px!important;
    line-height:1.2!important;
}

body.cz-build-body #content.build #build.gid17 #textmenu > a{
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    min-height:32px!important;
    padding:0 12px!important;
    margin:0!important;
    border:1px solid #d8c8ae!important;
    border-radius:7px!important;
    background:#fffaf2!important;
    color:#164532!important;
    font-weight:700!important;
    text-decoration:none!important;
}

body.cz-build-body #content.build #build.gid17 #textmenu > a.selected{
    background:#075b40!important;
    color:#fff!important;
    border-color:#cda63c!important;
}

body.cz-build-body #content.build #build.gid17 form{
    margin:0!important;
    padding:0!important;
}

body.cz-build-body #content.build #build.gid17 table#send_select,
body.cz-build-body #content.build #build.gid17 table#target_select,
body.cz-build-body #content.build #build.gid17 table#target_validate{
    margin:8px 0!important;
}

body.cz-build-body #content.build #build.gid17 table#send_select td,
body.cz-build-body #content.build #build.gid17 table#target_select td,
body.cz-build-body #content.build #build.gid17 table#target_validate td,
body.cz-build-body #content.build #build.gid17 table#target_validate th{
    padding:7px 9px!important;
}

body.cz-build-body #content.build #build.gid17 table#target_select{
    width:100%!important;
}

body.cz-build-body #content.build #build.gid17 table#target_select td.mer{
    padding:8px 10px!important;
    font-weight:700!important;
    background:#f4ecdd!important;
}

body.cz-build-body #content.build #build.gid17 table#target_select td.vil,
body.cz-build-body #content.build #build.gid17 table#target_select td.coo,
body.cz-build-body #content.build #build.gid17 table#target_select td.or{
    height:auto!important;
    min-height:0!important;
    padding:8px 10px!important;
    vertical-align:middle!important;
}

body.cz-build-body #content.build #build.gid17 table#target_select td.or{
    text-align:center!important;
    font-weight:700!important;
    color:#8a6a20!important;
}

body.cz-build-body #content.build #build.gid17 table#target_select td.vil span,
body.cz-build-body #content.build #build.gid17 table#target_select td.coo span{
    display:inline-block!important;
    min-width:auto!important;
    margin:0 4px!important;
}

body.cz-build-body #content.build #build.gid17 table#target_select input.text{
    margin:0 4px!important;
}

body.cz-build-body #content.build #build.gid17 p{
    margin:8px 0!important;
}

body.cz-build-body #content.build #build.gid17 #btn_ok,
body.cz-build-body #content.build #build.gid17 #btn_save{
    margin:4px 0!important;
}

body.cz-build-body #content.build #build.gid17 table.traders{
    margin:8px 0!important;
}

body.cz-build-body #content.build #build.gid17 #sell,
body.cz-build-body #content.build #build.gid17 #sell_overview,
body.cz-build-body #content.build #build.gid17 #npc{
    margin:10px 0!important;
}

/* remove oversized blank vertical space caused by old market rules */
body.cz-build-body #content.build #build.gid17 .clear{
    height:0!important;
    min-height:0!important;
    margin:0!important;
    padding:0!important;
}

body.cz-build-body #content.build #build.gid17 br + br{
    display:none!important;
}

/* v14.37 - compact all buildings, Arabic text buttons */
body.cz-build-body #content.build #build { padding-bottom:14px!important; }
body.cz-build-body #content.build #build > h1 { margin-bottom:8px!important; padding-bottom:8px!important; }
body.cz-build-body #content.build .build_desc { margin-bottom:10px!important; }
body.cz-build-body #content.build table { margin-top:7px!important; margin-bottom:7px!important; }
body.cz-build-body #content.build p { margin-top:5px!important; margin-bottom:5px!important; }
body.cz-build-body #content.build button#btn_ok {
    min-width:82px!important; height:32px!important; padding:0 14px!important;
    border:1px solid #c99e34!important; border-radius:7px!important;
    background:#075b40!important; color:#fff!important; font-weight:700!important;
    cursor:pointer!important; font-family:Tahoma,Arial,sans-serif!important;
}


/* =========================================================
   مدينة الصفر v14.41 — قائمة إنشاء مبنى جديد
   ========================================================= */
body.cz-build-body #content.build #build .build_list,
body.cz-build-body #content.build #build .build_list_new,
body.cz-build-body #content.build #build .build_list_new li,
body.cz-build-body #content.build #build .buildingWrapper{
    direction:rtl!important;
    text-align:right!important;
}

body.cz-build-body #content.build #build h2{
    direction:rtl!important;
    text-align:right!important;
    color:#07563d!important;
    margin:10px 0 6px!important;
}

body.cz-build-body #content.build #build table.new_building,
body.cz-build-body #content.build #build table{
    direction:rtl!important;
}

body.cz-build-body #content.build #build td.desc{
    direction:rtl!important;
    text-align:right!important;
    line-height:1.7!important;
}

body.cz-build-body #content.build #build a.build{
    direction:rtl!important;
    display:inline-block!important;
    margin-top:4px!important;
}


/* =========================================================
   مدينة الصفر v14.42 — صفحة القرية dorf2
   مدير المهام يسار | القرية وسط | القائمة يمين
   ========================================================= */

/* البطاقة الوسطية للقرية */
#mid > #content.village2{
    position:relative!important;
    float:none!important;
    width:650px!important;
    min-width:650px!important;
    min-height:565px!important;
    margin:30px auto 42px!important;
    padding:20px 24px 28px!important;
    box-sizing:border-box!important;
    background:#fffdf9!important;
    border:1px solid #dfd2bd!important;
    border-radius:16px!important;
    box-shadow:0 8px 24px rgba(65,49,27,.08)!important;
    direction:rtl!important;
    text-align:right!important;
    overflow:visible!important;
}

/* اسم القرية - نلغي absolute القديم حتى لا يدخل على مدير المهام */
#content.village2 > h1{
    position:relative!important;
    left:auto!important;
    right:auto!important;
    top:auto!important;
    z-index:30!important;
    display:block!important;
    width:100%!important;
    min-height:38px!important;
    margin:0 0 10px!important;
    padding:0 0 10px!important;
    box-sizing:border-box!important;
    border-bottom:1px solid #d6a12c!important;
    color:#07563d!important;
    font:700 27px Tahoma,Arial,sans-serif!important;
    line-height:38px!important;
    text-align:center!important;
    direction:rtl!important;
}

#content.village2 > h1:after{
    content:""!important;
    position:absolute!important;
    bottom:-5px!important;
    left:50%!important;
    width:9px!important;
    height:9px!important;
    margin-left:-4px!important;
    background:#d6a12c!important;
    transform:rotate(45deg)!important;
}

/* الولاء يبقى صغيراً بجانب/أسفل الاسم بدون إزاحة العنوان */
#content.village2 #loyality{
    position:absolute!important;
    left:auto!important;
    right:10px!important;
    top:7px!important;
    margin:0!important;
    line-height:18px!important;
    direction:rtl!important;
}

/* مهم جداً: نحافظ على 540x448 الأصلية حتى مناطق الضغط تبقى مطابقة */
#content.village2 #village_map{
    position:relative!important;
    float:none!important;
    clear:both!important;
    width:540px!important;
    height:448px!important;
    margin:12px auto 0!important;
    padding:0!important;
    box-sizing:content-box!important;
    direction:ltr!important;
    transform:none!important;
}

/* لا نغير مواضع عناصر/مباني الخريطة الداخلية */
#content.village2 #village_map img,
#content.village2 #village_map #levels,
#content.village2 #village_map #levels div{
    transform:none!important;
}

/* زر إظهار مستويات المباني يوضع داخل البطاقة بمحاذاة يمين أسفل الخريطة */
#content.village2 > #lswitch{
    position:absolute!important;
    left:auto!important;
    right:47px!important;
    top:493px!important;
    margin:0!important;
    z-index:500!important;
}

/* إذا ظهر نموذج إنشاء مبنى تحت القرية */
#content.village2 > #build,
#content.village2 .build_list,
#content.village2 .build_list_new{
    direction:rtl!important;
    text-align:right!important;
}

/* حماية الأعمدة الجانبية: لا تسمح للقرية بدفعها أو التداخل معها */
#mid > #side_info.cz-task-panel{
    z-index:40!important;
}

@media (max-width:1100px){
    #mid > #content.village2{
        width:620px!important;
        min-width:620px!important;
        padding-left:14px!important;
        padding-right:14px!important;
    }
}


/* =========================================================
   مدينة الصفر v14.48 — تحركات القوات والهجوم في dorf1
   ========================================================= */

body.cz-resources-body #content.village1.cz-resources-page table#movements{
    width:250px!important;
    max-width:250px!important;
    margin:0 0 12px!important;
    border-collapse:separate!important;
    border-spacing:0!important;
    border:1px solid #dccdb6!important;
    border-radius:11px!important;
    overflow:hidden!important;
    background:#fffaf2!important;
    direction:rtl!important;
    table-layout:fixed!important;
    box-shadow:0 3px 10px rgba(70,55,32,.05)!important;
}

body.cz-resources-body #content.village1 table#movements thead th{
    padding:9px 11px!important;
    background:#164532!important;
    color:#fff!important;
    border:0!important;
    text-align:right!important;
    font:700 12px Tahoma,Arial,sans-serif!important;
}

body.cz-resources-body #content.village1 table#movements tbody td{
    height:auto!important;
    padding:7px!important;
    vertical-align:middle!important;
    background:#fffaf2!important;
    border-top:1px solid #eadfce!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:11px!important;
    line-height:1.5!important;
    direction:rtl!important;
    text-align:right!important;
}

body.cz-resources-body #content.village1 table#movements td.typ{
    width:42px!important;
    min-width:42px!important;
    padding:5px!important;
    text-align:center!important;
    direction:ltr!important;
}

body.cz-resources-body #content.village1 table#movements td.typ img,
body.cz-resources-body #content.village1 table#movements img.att1,
body.cz-resources-body #content.village1 table#movements img.att2,
body.cz-resources-body #content.village1 table#movements img.att3,
body.cz-resources-body #content.village1 table#movements img.def1,
body.cz-resources-body #content.village1 table#movements img.def2,
body.cz-resources-body #content.village1 table#movements img.def3{
    display:inline-block!important;
    visibility:visible!important;
    opacity:1!important;
    width:16px!important;
    height:16px!important;
    min-width:16px!important;
    min-height:16px!important;
    max-width:none!important;
    margin:0!important;
    padding:0!important;
    transform:none!important;
    zoom:1!important;
}

body.cz-resources-body #content.village1 table#movements .a1,
body.cz-resources-body #content.village1 table#movements .a2,
body.cz-resources-body #content.village1 table#movements .a3{
    color:#b42318!important;
    font-weight:700!important;
}

body.cz-resources-body #content.village1 table#movements .d1,
body.cz-resources-body #content.village1 table#movements .d2,
body.cz-resources-body #content.village1 table#movements .d3{
    color:#176b45!important;
    font-weight:700!important;
}

body.cz-resources-body #content.village1 table#movements div.mov{
    float:none!important;
    display:block!important;
    width:100%!important;
    box-sizing:border-box!important;
    margin:0!important;
    padding:0!important;
    text-align:right!important;
    white-space:nowrap!important;
}

body.cz-resources-body #content.village1 table#movements div.dur_r{
    float:none!important;
    display:block!important;
    width:100%!important;
    box-sizing:border-box!important;
    margin:2px 0 0!important;
    padding:0!important;
    color:#746b5f!important;
    text-align:right!important;
    font-size:10px!important;
    white-space:nowrap!important;
}
body.cz-resources-body #content.village1 table#movements div.dur_r span[id^="timer"]{
    display:inline-block!important;
    direction:ltr!important;
    unicode-bidi:isolate!important;
    text-align:left!important;
}

/* Resource bar stays in its normal CityZero top position during active movements. */
body.cz-resources-body #res,
body.cz-resources-body #res.cz-resbar-v8{
    position:absolute!important;
    top:104px!important;
    left:0!important;
    right:auto!important;
    width:100%!important;
    min-width:980px!important;
    height:48px!important;
    min-height:48px!important;
    margin:0!important;
    padding:0!important;
    z-index:90!important;
}

/* =========================================================
   مدينة الصفر v14.61 — توحيد المحاذاة العامة لكل الصفحات
   الهدف: مدير المهام يسار / المحتوى وسط / القائمة يمين
   مع توحيد شريط التنقل وشريط الموارد.
   ========================================================= */

/* 1) الهيدر وشريط التنقل: صف واحد ثابت بلا التفاف */
#header.cz-header-v8{
    height:104px!important;
    min-height:104px!important;
    overflow:visible!important;
}

#header.cz-header-v8 .cz-header-inner{
    width:1180px!important;
    max-width:calc(100% - 36px)!important;
    height:104px!important;
    margin:0 auto!important;
    display:grid!important;
    grid-template-columns:220px minmax(680px,1fr) 150px!important;
    align-items:center!important;
    column-gap:18px!important;
    direction:rtl!important;
    box-sizing:border-box!important;
}

#header.cz-header-v8 #mtop.cz-topnav-v8{
    position:static!important;
    width:100%!important;
    min-width:0!important;
    height:74px!important;
    margin:0!important;
    padding:0!important;
    display:flex!important;
    flex-flow:row nowrap!important;
    align-items:center!important;
    justify-content:center!important;
    gap:4px!important;
    direction:rtl!important;
    overflow:visible!important;
}

/* نخلي التقارير والرسائل عنصرين طبيعيين بنفس صف بقية القوائم */
#header.cz-header-v8 #mtop.cz-topnav-v8 #n5.cz-nav-split{
    display:contents!important;
    width:auto!important;
    height:auto!important;
    margin:0!important;
    padding:0!important;
    float:none!important;
    background:none!important;
}

#header.cz-header-v8 #mtop.cz-topnav-v8 .cz-nav-item,
#header.cz-header-v8 #mtop.cz-topnav-v8 #n5.cz-nav-split>a{
    flex:0 0 82px!important;
    width:82px!important;
    min-width:82px!important;
    max-width:82px!important;
    height:68px!important;
    min-height:68px!important;
    margin:0!important;
    padding:7px 4px!important;
    float:none!important;
    display:flex!important;
    flex-direction:column!important;
    align-items:center!important;
    justify-content:center!important;
    gap:5px!important;
    box-sizing:border-box!important;
    line-height:1.15!important;
    white-space:nowrap!important;
    vertical-align:top!important;
}

#header.cz-header-v8 #mtop.cz-topnav-v8 .cz-nav-icon{
    width:27px!important;
    height:24px!important;
    min-height:24px!important;
    margin:0!important;
    padding:0!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    line-height:24px!important;
    font-size:20px!important;
    position:static!important;
    transform:none!important;
}

#header.cz-header-v8 #mtop.cz-topnav-v8 .cz-nav-item>span:not(.cz-nav-icon){
    display:block!important;
    width:100%!important;
    margin:0!important;
    padding:0!important;
    text-align:center!important;
    line-height:18px!important;
    position:static!important;
}

#header.cz-header-v8 .cz-top-brand,
#header.cz-header-v8 .cz-server-status{
    align-self:center!important;
    margin:0!important;
}

/* 2) شريط الموارد يبقى دائماً تحت الهيدر وبنفس المركز */
#res.cz-resbar-v8,
body.cz-resources-body #res.cz-resbar-v8{
    position:relative!important;
    top:auto!important;
    left:auto!important;
    right:auto!important;
    clear:both!important;
    width:100%!important;
    min-width:980px!important;
    height:48px!important;
    min-height:48px!important;
    margin:0!important;
    padding:0!important;
    z-index:90!important;
}

#res.cz-resbar-v8 #resWrap.cz-reswrap-v8{
    width:760px!important;
    max-width:calc(100% - 40px)!important;
    height:48px!important;
    margin:0 auto!important;
    padding:0!important;
    display:flex!important;
    flex-flow:row nowrap!important;
    align-items:center!important;
    justify-content:center!important;
    gap:18px!important;
    box-sizing:border-box!important;
}

/* 3) التخطيط العام: ثلاثة أعمدة ثابتة ومتناظرة */
#mid{
    position:relative!important;
    float:none!important;
    clear:both!important;
    width:1180px!important;
    min-width:1180px!important;
    max-width:1180px!important;
    min-height:620px!important;
    margin:0 auto 24px!important;
    padding:30px 0 0!important;
    box-sizing:border-box!important;
    direction:ltr!important;
}

/* القائمة اليمنى */
#mid > #side_navi.cz-side-menu-v8{
    position:absolute!important;
    top:30px!important;
    right:0!important;
    left:auto!important;
    float:none!important;
    clear:none!important;
    width:180px!important;
    min-width:180px!important;
    max-width:180px!important;
    margin:0!important;
    padding:0!important;
    z-index:35!important;
    direction:rtl!important;
    box-sizing:border-box!important;
}

/* مدير المهام: اليسار */
#mid > #side_info.cz-task-panel,
#mid > #side_info{
    position:absolute!important;
    top:30px!important;
    left:0!important;
    right:auto!important;
    float:none!important;
    clear:none!important;
    width:180px!important;
    min-width:180px!important;
    max-width:180px!important;
    margin:0!important;
    padding:0!important;
    z-index:35!important;
    direction:rtl!important;
    box-sizing:border-box!important;
}

#mid > #side_info.cz-task-panel #qge,
#mid > #side_info #qge{
    width:100%!important;
    max-width:100%!important;
    margin:0!important;
    padding:0!important;
    box-sizing:border-box!important;
}

/* المحتوى دائماً بالنص ولا يدفع الأعمدة */
#mid > #content{
    position:relative!important;
    float:none!important;
    clear:none!important;
    left:auto!important;
    right:auto!important;
    top:auto!important;
    margin-left:auto!important;
    margin-right:auto!important;
    margin-top:0!important;
    box-sizing:border-box!important;
    z-index:10!important;
}

/* توحيد بداية الصفحات الشائعة */
#mid > #content.village1,
#mid > #content.village2,
#mid > #content.map,
#mid > #content.statistics,
#mid > #content.reports,
#mid > #content.messages,
#mid > #content.player,
#mid > #content.profile,
#mid > #content.plus,
#mid > #content.alliance,
#mid > #content.universal{
    margin-top:0!important;
    margin-bottom:0!important;
}

/* المحتوى الواسع يبقى داخل الحيز بين العمودين */
#mid > #content{
    max-width:760px!important;
}

#mid > #content.village2{
    max-width:700px!important;
}

#mid > #content.village1,
#mid > #content.map,
#mid > #content.statistics,
#mid > #content.reports,
#mid > #content.messages,
#mid > #content.player,
#mid > #content.profile,
#mid > #content.plus,
#mid > #content.alliance{
    width:min(700px, calc(100% - 420px))!important;
}

/* لا نسمح لهوامش قديمة بتحريك صفحات معينة يمين/يسار */
#mid > #content.messages,
#mid > #content.reports,
#mid > #content.statistics,
#mid > #content.player,
#mid > #content.profile,
#mid > #content.plus,
#mid > #content.alliance,
#mid > #content.map{
    margin-left:auto!important;
    margin-right:auto!important;
}

/* بطاقات الجانبين بنفس خط البداية والحجم البصري */
#mid > #side_navi .cz-profile-card,
#mid > #side_navi .cz-side-card,
#mid > #side_info .cz-task-button{
    width:100%!important;
    box-sizing:border-box!important;
}

#mid > #side_navi .cz-profile-card,
#mid > #side_info .cz-task-button{
    min-height:88px!important;
}

/* يمنع clear القديمة من إسقاط أعمدة الجانب */
#mid > .clear{
    clear:none!important;
    height:0!important;
    margin:0!important;
    padding:0!important;
}

/* 4) الشاشات المتوسطة: نفس الفكرة مع عرض أصغر */
@media (max-width:1250px){
    #header.cz-header-v8 .cz-header-inner{
        width:1080px!important;
        grid-template-columns:195px minmax(650px,1fr) 135px!important;
    }
    #header.cz-header-v8 #mtop.cz-topnav-v8 .cz-nav-item,
    #header.cz-header-v8 #mtop.cz-topnav-v8 #n5.cz-nav-split>a{
        flex-basis:78px!important;
        width:78px!important;
        min-width:78px!important;
        max-width:78px!important;
    }
    #mid{
        width:1080px!important;
        min-width:1080px!important;
        max-width:1080px!important;
    }
    #mid > #side_navi.cz-side-menu-v8,
    #mid > #side_info.cz-task-panel,
    #mid > #side_info{
        width:170px!important;
        min-width:170px!important;
        max-width:170px!important;
    }
    #mid > #content.village1,
    #mid > #content.map,
    #mid > #content.statistics,
    #mid > #content.reports,
    #mid > #content.messages,
    #mid > #content.player,
    #mid > #content.profile,
    #mid > #content.plus,
    #mid > #content.alliance{
        width:min(680px, calc(100% - 390px))!important;
    }
}

/* 5) لا نلمس مواضع الخرائط والصور الداخلية */
#village_map,
#map,
#map_content,
#content.village1 .cz-field-map-stage,
#content.village2 #village_map{
    direction:ltr!important;
}

/* =========================================================
   مدينة الصفر v14.68 — محاذاة صحيحة بدون لمس المحتوى أو الموارد
   ========================================================= */

/* نترك المحتوى وشريط الموارد في موضعهما الطبيعي */
#mid > #content{
    top:auto!important;
    transform:none!important;
}
#res,
#resWrap{
    transform:none!important;
}

/* بدل رفع المحتوى، ننزل العمودين الجانبيين إلى نفس خط بدايته */
#mid > #side_navi.cz-side-menu-v8{
    top:98px!important;
    transform:none!important;
}

#mid > #side_info.cz-task-panel,
#mid > #side_info{
    top:98px!important;
    transform:none!important;
}

/* لا تغيّر هذه القاعدة عرض أو مكان المحتوى */
#mid > #content.village1,
#mid > #content.village2,
#mid > #content.map,
#mid > #content.statistics,
#mid > #content.reports,
#mid > #content.messages,
#mid > #content.player,
#mid > #content.profile,
#mid > #content.plus,
#mid > #content.alliance,
#mid > #content.universal,
#mid > #content.build{
    margin-top:0!important;
}

/* =========================================================
   مدينة الصفر v14.69 — مطابقة التقارير والمزايا مع بقية الصفحات
   مبني فوق v14.68 بدون لمس الهيدر أو شريط الموارد
   ========================================================= */

/* نفس عرض ومحاذاة بطاقة المحتوى المستخدمة في الصفحات المستقرة */
#mid > #content.reports,
#mid > #content.plus{
    width:min(760px, calc(100% - 400px))!important;
    max-width:760px!important;
    min-width:0!important;
    margin-left:auto!important;
    margin-right:auto!important;
    margin-top:0!important;
    top:auto!important;
    left:auto!important;
    right:auto!important;
    transform:none!important;
    box-sizing:border-box!important;
}

/* منع الهوامش القديمة داخل هاتين الصفحتين من رفع أو إنزال البطاقة */
#mid > #content.reports > h1,
#mid > #content.plus > h1{
    margin-top:0!important;
}

/* نفس نقطة بداية الجانبين بالضبط عند وجود التقارير أو المزايا */
#mid:has(> #content.reports) > #side_navi.cz-side-menu-v8,
#mid:has(> #content.plus) > #side_navi.cz-side-menu-v8,
#mid:has(> #content.reports) > #side_info.cz-task-panel,
#mid:has(> #content.reports) > #side_info,
#mid:has(> #content.plus) > #side_info.cz-task-panel,
#mid:has(> #content.plus) > #side_info{
    top:98px!important;
    transform:none!important;
}

/* إزالة أي clear أو br قديم بصرياً من التأثير على محاذاة الأعمدة */
#mid:has(> #content.reports) > .clear,
#mid:has(> #content.plus) > .clear{
    clear:none!important;
    height:0!important;
    margin:0!important;
    padding:0!important;
}

/* الشاشات المتوسطة: نفس قاعدة العرض المستخدمة ببقية الواجهة */
@media (max-width:1250px){
    #mid > #content.reports,
    #mid > #content.plus{
        width:min(680px, calc(100% - 390px))!important;
        max-width:680px!important;
    }
}

/* =========================================================
   مدينة الصفر v14.70 — شريط الموارد عربي RTL
   الخشب ← الطين ← الحديد ← القمح ← السكان ← الذهب
   ========================================================= */
#res.cz-resbar-ar{
    position:absolute!important;
    top:104px!important;
    left:0!important;
    right:0!important;
    width:100%!important;
    min-width:980px!important;
    height:52px!important;
    min-height:52px!important;
    margin:0!important;
    padding:0!important;
    display:block!important;
    visibility:visible!important;
    opacity:1!important;
    z-index:90!important;
    background:#fffaf1!important;
    border-top:0!important;
    border-bottom:1px solid #dfd2bc!important;
    box-shadow:0 2px 8px rgba(63,54,36,.06)!important;
    box-sizing:border-box!important;
}

#res.cz-resbar-ar #resWrap.cz-reswrap-ar{
    position:relative!important;
    inset:auto!important;
    width:980px!important;
    max-width:calc(100% - 40px)!important;
    height:52px!important;
    margin:0 auto!important;
    padding:0 8px!important;
    display:flex!important;
    flex-direction:row!important;
    direction:rtl!important;
    align-items:center!important;
    justify-content:center!important;
    gap:0!important;
    box-sizing:border-box!important;
}

#res.cz-resbar-ar .cz-res-item{
    height:34px!important;
    min-width:135px!important;
    padding:0 15px!important;
    display:flex!important;
    flex-direction:row!important;
    direction:rtl!important;
    align-items:center!important;
    justify-content:center!important;
    gap:6px!important;
    border-left:1px solid #ded4c2!important;
    box-sizing:border-box!important;
    color:#173c2d!important;
    white-space:nowrap!important;
    font-family:Tahoma,Arial,sans-serif!important;
}

#res.cz-resbar-ar .cz-res-item:first-child{
    border-right:0!important;
}
#res.cz-resbar-ar .cz-res-item:last-child{
    border-left:0!important;
}

#res.cz-resbar-ar .cz-res-item img{
    flex:0 0 auto!important;
    margin:0!important;
    vertical-align:middle!important;
}

#res.cz-resbar-ar .cz-res-value{
    direction:ltr!important;
    unicode-bidi:isolate!important;
    display:inline-block!important;
    font-size:13px!important;
    font-weight:700!important;
    color:#173c2d!important;
    line-height:1!important;
}

#res.cz-resbar-ar .cz-res-name{
    display:inline-block!important;
    font-size:11px!important;
    font-weight:700!important;
    color:#7a5a14!important;
    line-height:1!important;
}

#res.cz-resbar-ar .cz-res-gold .cz-res-name,
#res.cz-resbar-ar .cz-res-gold .cz-res-value{
    color:#8c6500!important;
}

/* لا نسمح لقواعد الجداول القديمة بالتأثير على الشريط الجديد */
#res.cz-resbar-ar table{
    display:none!important;
}

/* نفس المسافة المستخدمة حالياً بعد الهيدر والموارد */
#mid{
    padding-top:80px!important;
}

@media (max-width:1250px){
    #res.cz-resbar-ar #resWrap.cz-reswrap-ar{
        width:900px!important;
    }
    #res.cz-resbar-ar .cz-res-item{
        min-width:120px!important;
        padding:0 10px!important;
    }
    #res.cz-resbar-ar .cz-res-name{
        font-size:10px!important;
    }
}


/* مدينة الصفر v14.71 — ترتيب أرقام الموارد داخل RTL
   بصرياً من اليمين: المتوفر ثم / ثم السعة.
   لذلك النص الداخلي محفوظ كـ capacity/current مع اتجاه LTR للأرقام. */
#res.cz-resbar-ar .cz-res-value{
    direction:ltr!important;
    unicode-bidi:isolate!important;
    text-align:center!important;
}

/* =========================================================
   مدينة الصفر v14.72 — محاذاة صفحة الموارد فقط
   dorf1.php: إنزال بطاقة المحتوى إلى نفس خط الأعمدة الجانبية
   بدون أي تغيير على شريط الموارد أو بقية الصفحات
   ========================================================= */
body.cz-resources-body #mid > #content.village1.cz-resources-page{
    margin-top:58px!important;
    top:auto!important;
    transform:none!important;
}

/* City Zero v14.57 — إبقاء اسم القرية فوق خط الفصل بمسافة واضحة. */
body.cz-resources-body #content.village1.cz-resources-page > h1{
    display:block!important;
    height:auto!important;
    min-height:38px!important;
    left:auto!important;
    right:auto!important;
    margin:0 0 10px!important;
    padding:0 8px 17px!important;
    box-sizing:border-box!important;
    line-height:38px!important;
    text-align:center!important;
    overflow:visible!important;
}

/* =========================================================
   City Zero v15 — نظام حقول الموارد ثلاثي الأبعاد المستقل
   ========================================================= */
body.cz-resources-body #content.village1 #village_map.cz-fields-3d{
    position:relative!important;
    float:left!important;
    width:330px!important;
    min-width:330px!important;
    max-width:330px!important;
    height:330px!important;
    min-height:330px!important;
    max-height:330px!important;
    margin:18px 0 16px!important;
    padding:0!important;
    overflow:hidden!important;
    border:2px solid #b88922!important;
    border-radius:18px!important;
    background:#071a13!important;
    box-shadow:0 9px 24px rgba(7,26,19,.25)!important;
    direction:ltr!important;
    isolation:isolate!important;
}
body.cz-resources-body #village_map.cz-fields-3d .cz-fields-3d-art{
    position:absolute!important;
    inset:0!important;
    display:block!important;
    width:100%!important;
    max-width:100%!important;
    height:100%!important;
    object-fit:cover!important;
    margin:0!important;
    padding:0!important;
    z-index:1!important;
    pointer-events:none!important;
}
body.cz-resources-body #village_map.cz-fields-3d .cz-field-node{
    position:absolute!important;
    width:34px!important;
    height:34px!important;
    margin:-17px 0 0 -17px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    border:2px solid #f5d36a!important;
    border-radius:50%!important;
    background:linear-gradient(180deg,#fff6cf 0%,#e8bd4f 100%)!important;
    color:#173d2d!important;
    box-shadow:0 2px 0 #765414,0 4px 10px rgba(0,0,0,.42)!important;
    text-decoration:none!important;
    font:800 13px/1 Tahoma,Arial,sans-serif!important;
    z-index:20!important;
    transition:transform .15s ease,filter .15s ease!important;
}
body.cz-resources-body #village_map.cz-fields-3d .cz-field-node:hover{
    transform:scale(1.16)!important;
    filter:brightness(1.12)!important;
    z-index:30!important;
}
body.cz-resources-body #village_map.cz-fields-3d .cz-field-type-1{border-color:#87ce68!important;background:linear-gradient(180deg,#e6f5c9,#83b95a)!important;}
body.cz-resources-body #village_map.cz-fields-3d .cz-field-type-2{border-color:#f1b070!important;background:linear-gradient(180deg,#ffe0ae,#d77a35)!important;}
body.cz-resources-body #village_map.cz-fields-3d .cz-field-type-3{border-color:#c9d0ce!important;background:linear-gradient(180deg,#f0f2ef,#929d99)!important;}
body.cz-resources-body #village_map.cz-fields-3d .cz-field-type-4{border-color:#ffe58a!important;background:linear-gradient(180deg,#fff8bb,#dfb52e)!important;}
body.cz-resources-body #village_map.cz-fields-3d .cz-field-level{direction:ltr!important;unicode-bidi:isolate!important;}
body.cz-resources-body #village_map.cz-fields-3d .cz-field-label{
    position:absolute!important;
    left:50%!important;
    bottom:39px!important;
    transform:translateX(-50%)!important;
    display:none!important;
    width:max-content!important;
    max-width:120px!important;
    padding:5px 8px!important;
    border:1px solid #d6b45c!important;
    border-radius:6px!important;
    background:#fffdf6!important;
    color:#173d2d!important;
    white-space:nowrap!important;
    font:700 11px/1.3 Tahoma,Arial,sans-serif!important;
    box-shadow:0 3px 10px rgba(0,0,0,.2)!important;
    direction:rtl!important;
}
body.cz-resources-body #village_map.cz-fields-3d .cz-field-node:hover .cz-field-label{display:block!important;}
body.cz-resources-body #village_map.cz-fields-3d .cz-fields-city{
    position:absolute!important;
    left:50%!important;
    top:49%!important;
    width:82px!important;
    height:82px!important;
    margin:-41px 0 0 -41px!important;
    display:flex!important;
    align-items:flex-end!important;
    justify-content:center!important;
    padding-bottom:5px!important;
    box-sizing:border-box!important;
    border:2px solid transparent!important;
    border-radius:50%!important;
    color:#fff4bd!important;
    text-decoration:none!important;
    text-shadow:0 2px 4px #000!important;
    font:800 11px/1.2 Tahoma,Arial,sans-serif!important;
    z-index:15!important;
}
body.cz-resources-body #village_map.cz-fields-3d .cz-fields-city:hover{
    border-color:#f1cd61!important;
    background:rgba(7,88,63,.22)!important;
}
body.cz-resources-body #content.village1.cz-resources-page{min-height:760px!important;}

/* لا نغيّر موضع خريطة الحقول أو مناطق الضغط داخلها */
body.cz-resources-body #content.village1.cz-resources-page .cz-field-map-stage,
body.cz-resources-body #content.village1.cz-resources-page #village_map,
body.cz-resources-body #content.village1.cz-resources-page #resfields{
    transform:none!important;
}


/* =========================================================
   v14.75 — Hero Mansion + Embassy + Alliance RTL
   ========================================================= */
#build.gid37, #build.gid18 {
    direction: rtl !important;
    text-align: right !important;
}
#build.gid37 h1, #build.gid18 h1,
#build.gid37 .build_desc, #build.gid18 .build_desc {
    text-align: right !important;
}
#build.gid37 table, #build.gid18 table {
    direction: rtl !important;
}
#build.gid37 th, #build.gid37 td,
#build.gid18 th, #build.gid18 td {
    text-align: right !important;
}

/* Alliance pages — same modern card/layout used in the rest of City Zero */
#content.alliance, #content.forum {
    direction: rtl !important;
    text-align: right !important;
}
#content.alliance h1, #content.forum h1,
#content.alliance h2, #content.forum h2,
#content.alliance h3, #content.forum h3,
#content.alliance h4, #content.forum h4 {
    text-align: right !important;
}
#content.alliance #textmenu,
#content.forum #textmenu {
    direction: rtl !important;
    text-align: center !important;
}
#content.alliance #textmenu a,
#content.forum #textmenu a {
    display: inline-block !important;
}
#content.alliance table,
#content.forum table {
    width: 100% !important;
    direction: rtl !important;
}
#content.alliance th, #content.alliance td,
#content.forum th, #content.forum td {
    text-align: right !important;
    vertical-align: middle !important;
}
#content.alliance input,
#content.alliance select,
#content.alliance textarea,
#content.forum input,
#content.forum select,
#content.forum textarea {
    direction: rtl !important;
    text-align: right !important;
    box-sizing: border-box !important;
}
#content.alliance .aligned_coords,
#content.forum .aligned_coords {
    direction: ltr !important;
    text-align: center !important;
}


/* =========================================================
   v14.78 — Alliance attacks DB fix + Arabic option alignment
   ========================================================= */
#content.alliance #textmenu{
    display:flex!important;
    flex-direction:row!important;
    direction:rtl!important;
    align-items:center!important;
    justify-content:center!important;
    flex-wrap:wrap!important;
    gap:8px!important;
    margin:14px 0 20px!important;
    padding:8px!important;
    border:1px solid #e1d5bf!important;
    border-radius:12px!important;
    background:#faf6ed!important;
}
#content.alliance #textmenu > a,
#content.alliance #textmenu > span{
    margin:0!important;
    padding:9px 14px!important;
    border:1px solid #dfd0b5!important;
    border-radius:9px!important;
    background:#fffaf1!important;
    color:#064f3a!important;
    text-decoration:none!important;
    line-height:1.2!important;
    white-space:nowrap!important;
}
#content.alliance #textmenu > a.selected{
    background:#07533d!important;
    color:#f2c94c!important;
    border-color:#d5a91f!important;
}
/* Hide the old literal separators now that flex gap handles spacing */
#content.alliance #textmenu{
    font-size:0!important;
}
#content.alliance #textmenu > a,
#content.alliance #textmenu > span{
    font-size:14px!important;
}

#content.alliance table#options.cz-alliance-options{
    width:100%!important;
    max-width:560px!important;
    margin:18px auto 10px!important;
    border-collapse:separate!important;
    border-spacing:0!important;
    overflow:hidden!important;
    border:1px solid #dfd0b5!important;
    border-radius:12px!important;
    background:#fff!important;
    direction:rtl!important;
}
#content.alliance table#options.cz-alliance-options th{
    background:#124f3b!important;
    color:#fff!important;
    text-align:right!important;
    padding:12px 16px!important;
    font-size:15px!important;
}
#content.alliance table#options.cz-alliance-options td{
    padding:11px 14px!important;
    border-top:1px solid #eee3d1!important;
    text-align:right!important;
}
#content.alliance table#options.cz-alliance-options td.sel{
    width:52px!important;
    text-align:center!important;
}
#content.alliance table#options.cz-alliance-options td.val{
    font-weight:700!important;
    color:#174f3d!important;
}
#content.alliance table#options.cz-alliance-options input.radio{
    margin:0!important;
}
#content.alliance #submenu{
    direction:rtl!important;
    display:flex!important;
    justify-content:flex-start!important;
    align-items:center!important;
    gap:8px!important;
    margin:8px 0 14px!important;
}
#content.alliance h4.chartHeadline{
    text-align:right!important;
    margin:12px 0 8px!important;
}
#content.alliance table#offs{
    margin-top:8px!important;
    border-radius:10px!important;
    overflow:hidden!important;
}


/* v14.79 ALLIANCE FORUM LAYOUT */
#content.alliance,
#content.forum {
    direction: rtl !important;
    text-align: right !important;
}

#content.forum {
    width: 100% !important;
    max-width: 720px !important;
    margin-left: auto !important;
    margin-right: auto !important;
    padding: 0 !important;
}

#content.forum > h1,
#content.alliance > h1 {
    text-align: right !important;
    margin: 0 0 16px 0 !important;
}

#content.forum #textmenu,
#content.alliance #textmenu {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 8px !important;
    align-items: center !important;
    justify-content: flex-start !important;
    direction: rtl !important;
    padding: 10px 12px !important;
    margin: 0 0 18px 0 !important;
    border: 1px solid #e2d3b8 !important;
    border-radius: 12px !important;
    background: #fbf7ee !important;
}

#content.forum #textmenu a,
#content.alliance #textmenu a {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    min-height: 38px !important;
    padding: 0 16px !important;
    margin: 0 !important;
    border: 1px solid #dfceb0 !important;
    border-radius: 9px !important;
    background: #fffaf1 !important;
    color: #064f39 !important;
    text-decoration: none !important;
    font-weight: 700 !important;
}

#content.forum #textmenu a.selected,
#content.alliance #textmenu a.selected {
    background: #006148 !important;
    color: #f5c43c !important;
    border-color: #d6aa25 !important;
}

#content.forum table {
    width: 100% !important;
    border-collapse: separate !important;
    border-spacing: 0 !important;
    overflow: hidden !important;
    border: 1px solid #e0d0b6 !important;
    border-radius: 10px !important;
    background: #fffdf8 !important;
    margin: 0 0 14px 0 !important;
}

#content.forum table th {
    background: #0f5138 !important;
    color: #fff !important;
    font-weight: 700 !important;
    padding: 10px 12px !important;
    text-align: right !important;
}

#content.forum table td {
    padding: 9px 12px !important;
    text-align: right !important;
    border-top: 1px solid #eee3d2 !important;
    vertical-align: middle !important;
}

#content.forum input[type="text"],
#content.forum textarea,
#content.forum select {
    direction: rtl !important;
    text-align: right !important;
    border: 1px solid #d9c7aa !important;
    border-radius: 8px !important;
    padding: 8px 10px !important;
    box-sizing: border-box !important;
}

#content.forum input[type="submit"],
#content.forum button,
#content.forum .button,
#content.forum .green {
    min-height: 36px !important;
    border-radius: 8px !important;
    padding: 0 16px !important;
    font-weight: 700 !important;
}

/* hide legacy separator pipes visually when textmenu is flex */
#content.forum #textmenu,
#content.alliance #textmenu {
    font-size: 0 !important;
}
#content.forum #textmenu a,
#content.alliance #textmenu a {
    font-size: 14px !important;
}


/* v14.80 ALLIANCE ATTACKS + REPORT */
#content.alliance .alliance_events,
#content.alliance .military_events,
#content.alliance table.alliance_events,
#content.alliance table {
    direction: rtl !important;
}

#content.alliance .military_events,
#content.alliance .alliance_events {
    margin-top: 14px !important;
}

#content.alliance table {
    width: 100% !important;
    border-collapse: separate !important;
    border-spacing: 0 !important;
    border: 1px solid #e1d3bb !important;
    border-radius: 10px !important;
    overflow: hidden !important;
    background: #fffdf8 !important;
}

#content.alliance table th {
    background: #0f5138 !important;
    color: #fff !important;
    padding: 9px 12px !important;
    text-align: right !important;
    font-weight: 700 !important;
}

#content.alliance table td {
    padding: 9px 12px !important;
    text-align: right !important;
    vertical-align: middle !important;
    border-top: 1px solid #eee3d2 !important;
}

#content.alliance table td a {
    color: #07583f !important;
    font-weight: 700 !important;
    text-decoration: none !important;
}

#content.reports #report_surround,
#content.reports table {
    direction: rtl !important;
    text-align: right !important;
}

#content.reports #report_surround th,
#content.reports #report_surround td {
    text-align: right !important;
    vertical-align: middle !important;
}


/* v14.81 ALLIANCE ATTACK ICONS + TEXT */
#content.alliance .attack_filter,
#content.alliance .attack-switch,
#content.alliance .attackSwitch,
#content.alliance .switch {
    direction: rtl !important;
}

/* Common Travian alliance attack filter icons */
#content.alliance #textmenu + a,
#content.alliance #textmenu + a + a {
    float: none !important;
    position: static !important;
}

#content.alliance .attack-icon-bar,
#content.alliance .attack-icons {
    display: flex !important;
    direction: rtl !important;
    gap: 8px !important;
    align-items: center !important;
    justify-content: flex-start !important;
    margin: 0 0 12px 0 !important;
}

/* The two square attacker/defender icon links often sit beside the tabs.
   Pull them into their own visual lane instead of over the Overview button. */
#content.alliance #textmenu a img[class*="att"],
#content.alliance #textmenu a img[class*="def"],
#content.alliance #textmenu img[class*="att"],
#content.alliance #textmenu img[class*="def"] {
    margin: 0 !important;
}

#content.alliance #textmenu > a:has(img) {
    width: 34px !important;
    min-width: 34px !important;
    height: 34px !important;
    min-height: 34px !important;
    padding: 0 !important;
    flex: 0 0 34px !important;
}

/* Keep attack rows readable in RTL */
#content.alliance table td,
#content.alliance table th {
    white-space: normal !important;
}

#content.alliance table td:first-child,
#content.alliance table th:first-child {
    min-width: 180px !important;
}

#content.alliance .attack-date,
#content.alliance td.date,
#content.alliance th.date {
    direction: rtl !important;
    white-space: nowrap !important;
}


/* v14.82 — direct alliance attacks layout fix */
#content.alliance .cz-alliance-military-head{
    display:flex!important;
    flex-direction:column!important;
    align-items:stretch!important;
    gap:10px!important;
    margin:14px 0 12px!important;
    direction:rtl!important;
}

#content.alliance .cz-alliance-military-head .chartHeadline{
    margin:0!important;
    padding:0!important;
    text-align:right!important;
    color:#173f31!important;
}

#content.alliance #submenu.cz-alliance-attack-filters{
    position:static!important;
    float:none!important;
    clear:both!important;
    width:auto!important;
    height:auto!important;
    min-height:0!important;
    margin:0!important;
    padding:8px!important;
    display:flex!important;
    flex-direction:row!important;
    align-items:center!important;
    justify-content:flex-start!important;
    gap:10px!important;
    background:#fbf7ee!important;
    border:1px solid #e2d3b8!important;
    border-radius:10px!important;
    overflow:visible!important;
    direction:rtl!important;
}

#content.alliance #submenu.cz-alliance-attack-filters a.cz-attack-filter{
    position:static!important;
    float:none!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:7px!important;
    width:auto!important;
    height:36px!important;
    min-width:105px!important;
    margin:0!important;
    padding:0 12px!important;
    box-sizing:border-box!important;
    border:1px solid #dbcba8!important;
    border-radius:8px!important;
    background:#fffaf1!important;
    color:#07583f!important;
    font-weight:700!important;
    text-decoration:none!important;
}

#content.alliance #submenu.cz-alliance-attack-filters a.cz-attack-filter:hover{
    background:#f2ead9!important;
}

#content.alliance #submenu.cz-alliance-attack-filters a.cz-attack-filter img{
    position:static!important;
    float:none!important;
    display:inline-block!important;
    margin:0!important;
    padding:0!important;
}

#content.alliance #submenu.cz-alliance-attack-filters a.cz-attack-filter span{
    display:inline-block!important;
    white-space:nowrap!important;
    font-size:13px!important;
}

#content.alliance #offs{
    margin-top:0!important;
}

#content.alliance #offs td.dat{
    direction:rtl!important;
    unicode-bidi:plaintext!important;
    white-space:nowrap!important;
}


/* v14.83 ALLIANCE OVERVIEW */
#content.alliance {
    direction: rtl !important;
    text-align: right !important;
}

/* overview main information table */
#content.alliance #alliance,
#content.alliance .cz-alliance-overview-info {
    width: 100% !important;
    table-layout: fixed !important;
    border-collapse: separate !important;
    border-spacing: 0 !important;
    border: 1px solid #dfd0b6 !important;
    border-radius: 10px !important;
    overflow: hidden !important;
    background: #fffdf8 !important;
    margin: 0 0 22px 0 !important;
    direction: rtl !important;
}

#content.alliance #alliance thead th,
#content.alliance .cz-alliance-overview-info thead th {
    background: #0f5138 !important;
    color: #fff !important;
    padding: 10px 14px !important;
    font-weight: 700 !important;
    text-align: right !important;
    border: 0 !important;
}

#content.alliance #alliance tbody th,
#content.alliance .cz-alliance-overview-info tbody th {
    width: 34% !important;
    background: #f7f1e5 !important;
    color: #174936 !important;
    padding: 9px 14px !important;
    text-align: right !important;
    font-weight: 700 !important;
    border-top: 1px solid #eadfcd !important;
    vertical-align: middle !important;
}

#content.alliance #alliance tbody td,
#content.alliance .cz-alliance-overview-info tbody td {
    width: 66% !important;
    padding: 9px 14px !important;
    text-align: right !important;
    border-top: 1px solid #eadfcd !important;
    background: #fffdf8 !important;
    vertical-align: middle !important;
}

/* force description area to use the available width instead of leaving a huge empty column */
#content.alliance #alliance td.desc,
#content.alliance #alliance td.description,
#content.alliance .cz-alliance-overview-info td.desc,
#content.alliance .cz-alliance-overview-info td.description {
    width: auto !important;
    min-height: 90px !important;
    white-space: normal !important;
    line-height: 1.7 !important;
}

/* member list */
#content.alliance #member,
#content.alliance #members,
#content.alliance .cz-alliance-members {
    width: 100% !important;
    table-layout: auto !important;
    border-collapse: separate !important;
    border-spacing: 0 !important;
    border: 1px solid #dfd0b6 !important;
    border-radius: 10px !important;
    overflow: hidden !important;
    background: #fffdf8 !important;
    margin-top: 0 !important;
    direction: rtl !important;
}

#content.alliance #member th,
#content.alliance #members th,
#content.alliance .cz-alliance-members th {
    background: #0f5138 !important;
    color: #fff !important;
    text-align: center !important;
    padding: 9px 10px !important;
    font-weight: 700 !important;
}

#content.alliance #member td,
#content.alliance #members td,
#content.alliance .cz-alliance-members td {
    background: #fffdf8 !important;
    color: #233 !important;
    text-align: center !important;
    padding: 9px 10px !important;
    border-top: 1px solid #eadfcd !important;
    vertical-align: middle !important;
}

#content.alliance #member td.pla,
#content.alliance #members td.pla,
#content.alliance .cz-alliance-members td.pla {
    text-align: right !important;
}

/* remove accidental narrow nested-table look from legacy overview */
#content.alliance #alliance table {
    width: 100% !important;
    margin: 0 !important;
}

/* ensure founder/labels don't remain LTR */
#content.alliance #alliance th,
#content.alliance #alliance td {
    direction: rtl !important;
    unicode-bidi: plaintext !important;
}


/* v14.83b ALLIANCE OVERVIEW INNER GRID */
#content.alliance #alliance td.details{
    width:42%!important;
    padding:16px!important;
    vertical-align:top!important;
    background:#fffdf8!important;
}

#content.alliance #alliance td.desc{
    width:58%!important;
    padding:16px!important;
    vertical-align:top!important;
    background:#fffdf8!important;
}

#content.alliance #alliance .cz-alliance-details-grid{
    width:100%!important;
    border-collapse:separate!important;
    border-spacing:0!important;
    border:1px solid #e1d3bb!important;
    border-radius:9px!important;
    overflow:hidden!important;
    background:#fff!important;
}

#content.alliance #alliance .cz-alliance-details-grid th{
    width:44%!important;
    background:#0f5138!important;
    color:#fff!important;
    padding:9px 12px!important;
    text-align:right!important;
    border-top:1px solid rgba(255,255,255,.12)!important;
}

#content.alliance #alliance .cz-alliance-details-grid td{
    width:56%!important;
    background:#fffdf8!important;
    color:#173f31!important;
    padding:9px 12px!important;
    text-align:right!important;
    border-top:1px solid #eadfcd!important;
}

#content.alliance #alliance .cz-alliance-details-grid td.empty,
#content.alliance #alliance .cz-alliance-details-grid td.emmty{
    height:6px!important;
    min-height:6px!important;
    padding:0!important;
    background:#f6f0e5!important;
    border:0!important;
}

#content.alliance #alliance .cz-alliance-description{
    min-height:150px!important;
    padding:14px!important;
    line-height:1.8!important;
    text-align:right!important;
    white-space:normal!important;
}

#content.alliance #alliance .cz-forum-link{
    text-align:center!important;
    background:#faf3e6!important;
}

#content.alliance #alliance .cz-forum-link a{
    color:#0a6b49!important;
    font-weight:700!important;
}

/* mobile-ish fallback */
@media (max-width: 900px){
    #content.alliance #alliance td.details,
    #content.alliance #alliance td.desc{
        width:100%!important;
        display:block!important;
        box-sizing:border-box!important;
    }
}


/* v14.84 — clean alliance overview, no nested legacy tables */
#content.alliance #profile.cz-alliance-profile{
    width:100%!important;
    margin:0 0 22px 0!important;
    padding:0!important;
    border:1px solid #dfcfb3!important;
    border-radius:12px!important;
    overflow:hidden!important;
    background:#fffdf8!important;
    direction:rtl!important;
    box-sizing:border-box!important;
}

#content.alliance #profile.cz-alliance-profile .cz-alliance-profile-title{
    background:#0d5a40!important;
    color:#fff!important;
    font-weight:700!important;
    font-size:16px!important;
    padding:11px 15px!important;
    text-align:right!important;
}

#content.alliance #profile.cz-alliance-profile .cz-alliance-profile-grid{
    display:grid!important;
    grid-template-columns:360px minmax(0,1fr)!important;
    gap:18px!important;
    padding:18px!important;
    align-items:stretch!important;
    direction:rtl!important;
}

#content.alliance #profile.cz-alliance-profile .cz-alliance-info-card,
#content.alliance #profile.cz-alliance-profile .cz-alliance-desc-card{
    border:1px solid #e0d0b5!important;
    border-radius:10px!important;
    background:#fffaf2!important;
    overflow:hidden!important;
    min-width:0!important;
    box-sizing:border-box!important;
}

#content.alliance #profile.cz-alliance-profile .cz-card-title{
    padding:10px 14px!important;
    background:#164f3b!important;
    color:#fff!important;
    font-weight:700!important;
    text-align:right!important;
}

#content.alliance #profile.cz-alliance-profile .cz-info-row{
    display:grid!important;
    grid-template-columns:44% 56%!important;
    direction:rtl!important;
    border-top:1px solid #eadfcd!important;
    min-height:42px!important;
}

#content.alliance #profile.cz-alliance-profile .cz-info-row span{
    display:flex!important;
    align-items:center!important;
    padding:9px 12px!important;
    background:#f2eadb!important;
    color:#164b37!important;
    font-weight:700!important;
    text-align:right!important;
    box-sizing:border-box!important;
}

#content.alliance #profile.cz-alliance-profile .cz-info-row strong{
    display:flex!important;
    align-items:center!important;
    padding:9px 12px!important;
    background:#fffdf8!important;
    color:#173d30!important;
    font-weight:600!important;
    text-align:right!important;
    box-sizing:border-box!important;
}

#content.alliance #profile.cz-alliance-profile .cz-info-row a{
    color:#08704d!important;
    font-weight:700!important;
    text-decoration:none!important;
}

#content.alliance #profile.cz-alliance-profile .cz-rank-row{
    margin-top:8px!important;
}

#content.alliance #profile.cz-alliance-profile .cz-forum-link{
    padding:10px 12px!important;
    border-top:1px solid #eadfcd!important;
    background:#faf2e4!important;
    text-align:center!important;
}

#content.alliance #profile.cz-alliance-profile .cz-forum-link a{
    color:#08704d!important;
    font-weight:700!important;
    text-decoration:none!important;
}

#content.alliance #profile.cz-alliance-profile .cz-description-section,
#content.alliance #profile.cz-alliance-profile .cz-description-secondary{
    padding:16px!important;
    min-height:110px!important;
    line-height:1.9!important;
    direction:rtl!important;
    text-align:right!important;
    color:#253b32!important;
    white-space:normal!important;
    overflow-wrap:anywhere!important;
}

#content.alliance #profile.cz-alliance-profile .cz-description-secondary{
    border-top:1px solid #eadfcd!important;
    min-height:70px!important;
    background:#fffdf8!important;
}

/* member table */
#content.alliance #member.cz-alliance-members{
    width:100%!important;
    margin:0!important;
    table-layout:fixed!important;
    border-collapse:separate!important;
    border-spacing:0!important;
    border:1px solid #dfcfb3!important;
    border-radius:10px!important;
    overflow:hidden!important;
    background:#fffdf8!important;
    direction:rtl!important;
}

#content.alliance #member.cz-alliance-members th{
    padding:10px 12px!important;
    background:#0f5138!important;
    color:#fff!important;
    text-align:center!important;
    font-weight:700!important;
}

#content.alliance #member.cz-alliance-members td{
    padding:10px 12px!important;
    background:#fffdf8!important;
    color:#263c33!important;
    text-align:center!important;
    border-top:1px solid #eadfcd!important;
    vertical-align:middle!important;
}

#content.alliance #member.cz-alliance-members td.pla{
    text-align:right!important;
}

@media (max-width:900px){
    #content.alliance #profile.cz-alliance-profile .cz-alliance-profile-grid{
        grid-template-columns:1fr!important;
    }
}


/* v14.85 ALLIANCE CHAT + NEWS */
#content.alliance .cz-alliance-chat-table,
#content.alliance table.chat,
#content.alliance #chat {
    width: 100% !important;
    direction: rtl !important;
    border-collapse: separate !important;
    border-spacing: 0 !important;
    border: 1px solid #dfcfb3 !important;
    border-radius: 10px !important;
    overflow: hidden !important;
    background: #fffdf8 !important;
    margin-top: 14px !important;
}

#content.alliance .cz-alliance-chat-table th,
#content.alliance table.chat th,
#content.alliance #chat th {
    background: #0f5138 !important;
    color: #fff !important;
    padding: 10px 12px !important;
    text-align: right !important;
    font-weight: 700 !important;
}

#content.alliance .cz-alliance-chat-table td,
#content.alliance table.chat td,
#content.alliance #chat td {
    padding: 9px 12px !important;
    text-align: right !important;
    vertical-align: top !important;
    border-top: 1px solid #eadfcd !important;
    background: #fffdf8 !important;
}

#content.alliance .cz-alliance-chat-form {
    display: grid !important;
    grid-template-columns: minmax(0,1fr) auto !important;
    gap: 10px !important;
    align-items: center !important;
    width: 100% !important;
    margin-top: 12px !important;
    direction: rtl !important;
}

#content.alliance .cz-alliance-chat-form input[type="text"],
#content.alliance .cz-alliance-chat-form textarea {
    width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
    direction: rtl !important;
    text-align: right !important;
    border: 1px solid #d9c7aa !important;
    border-radius: 8px !important;
    padding: 9px 11px !important;
    background: #fffdf8 !important;
}

#content.alliance .cz-alliance-chat-form input[type="submit"],
#content.alliance .cz-alliance-chat-form button {
    min-width: 86px !important;
    height: 38px !important;
    border-radius: 8px !important;
    font-weight: 700 !important;
}

#content.alliance table.news,
#content.alliance #news {
    width: 100% !important;
    direction: rtl !important;
    table-layout: auto !important;
    border-collapse: separate !important;
    border-spacing: 0 !important;
    border: 1px solid #dfcfb3 !important;
    border-radius: 10px !important;
    overflow: hidden !important;
    background: #fffdf8 !important;
    margin-top: 14px !important;
}

#content.alliance table.news th,
#content.alliance #news th {
    background: #0f5138 !important;
    color: #fff !important;
    padding: 10px 12px !important;
    text-align: right !important;
    font-weight: 700 !important;
}

#content.alliance table.news td,
#content.alliance #news td {
    padding: 10px 12px !important;
    text-align: right !important;
    border-top: 1px solid #eadfcd !important;
    vertical-align: middle !important;
}

#content.alliance table.news td.dat,
#content.alliance #news td.dat {
    white-space: nowrap !important;
    direction: rtl !important;
}

@media (max-width: 900px){
    #content.alliance .cz-alliance-chat-form {
        grid-template-columns: 1fr !important;
    }
}


/* v14.86 — direct chat/news fix */
#content.alliance .cz-alliance-chat-page{
    width:100%!important;
    direction:rtl!important;
    margin-top:16px!important;
}

#content.alliance .cz-alliance-chat-form{
    display:block!important;
    width:100%!important;
    margin:0!important;
}

#content.alliance .cz-alliance-chat-box{
    width:100%!important;
    border:1px solid #dfcfb3!important;
    border-radius:12px!important;
    overflow:hidden!important;
    background:#fffdf8!important;
    box-sizing:border-box!important;
}

#content.alliance .cz-alliance-chat-box .chatHeader{
    width:100%!important;
    box-sizing:border-box!important;
    background:#0f5138!important;
    color:#fff!important;
    font-size:15px!important;
    font-weight:700!important;
    text-align:right!important;
    padding:11px 14px!important;
    border:0!important;
}

#content.alliance .cz-chat-container{
    position:relative!important;
    top:auto!important;
    right:auto!important;
    left:auto!important;
    width:100%!important;
    height:300px!important;
    overflow:hidden!important;
    background:#fffdf8!important;
    border:0!important;
    box-sizing:border-box!important;
}

#content.alliance .cz-chat-messages{
    position:static!important;
    width:100%!important;
    height:258px!important;
    overflow-y:auto!important;
    overflow-x:hidden!important;
    padding:14px!important;
    box-sizing:border-box!important;
    background:#fffdf8!important;
    direction:rtl!important;
    text-align:right!important;
    line-height:1.7!important;
}

#content.alliance .cz-chat-legacy-scroll{
    display:none!important;
}

#content.alliance .cz-chat-autoscroll{
    position:absolute!important;
    right:14px!important;
    bottom:8px!important;
    left:auto!important;
    top:auto!important;
    display:inline-flex!important;
    align-items:center!important;
    gap:7px!important;
    font-size:12px!important;
    color:#6c675d!important;
    direction:rtl!important;
}

#content.alliance .cz-chat-autoscroll input{
    position:static!important;
    margin:0!important;
    width:auto!important;
    height:auto!important;
}

#content.alliance .cz-chat-compose{
    display:grid!important;
    grid-template-columns:minmax(0,1fr) 90px!important;
    gap:10px!important;
    align-items:center!important;
    padding:12px!important;
    border-top:1px solid #eadfcd!important;
    background:#faf5eb!important;
    direction:rtl!important;
    box-sizing:border-box!important;
}

#content.alliance .cz-chat-input{
    width:100%!important;
    height:40px!important;
    margin:0!important;
    padding:8px 12px!important;
    box-sizing:border-box!important;
    border:1px solid #d5c3a5!important;
    border-radius:8px!important;
    background:#fff!important;
    color:#173f31!important;
    direction:rtl!important;
    text-align:right!important;
    font-size:14px!important;
}

#content.alliance .cz-chat-send{
    width:90px!important;
    height:40px!important;
    margin:0!important;
    padding:0 12px!important;
    border:1px solid #d3a91e!important;
    border-radius:8px!important;
    background:#07583f!important;
    color:#f6c83f!important;
    font-weight:700!important;
    cursor:pointer!important;
}

#content.alliance .cz-chat-send:hover{
    background:#064a35!important;
}

/* Alliance news */
#content.alliance #events{
    width:100%!important;
    direction:rtl!important;
    table-layout:auto!important;
    border-collapse:separate!important;
    border-spacing:0!important;
    border:1px solid #dfcfb3!important;
    border-radius:10px!important;
    overflow:hidden!important;
    background:#fffdf8!important;
    margin-top:16px!important;
}

#content.alliance #events thead tr:first-child th{
    background:#0f5138!important;
    color:#fff!important;
    font-weight:700!important;
    padding:10px 14px!important;
    text-align:right!important;
}

#content.alliance #events thead td{
    background:#f5eee1!important;
    color:#173f31!important;
    font-weight:700!important;
    padding:9px 12px!important;
    text-align:right!important;
}

#content.alliance #events tbody td{
    background:#fffdf8!important;
    padding:10px 12px!important;
    border-top:1px solid #eadfcd!important;
    text-align:right!important;
    vertical-align:middle!important;
}

#content.alliance #events td.event{
    width:auto!important;
    direction:rtl!important;
}

#content.alliance #events td.dat{
    width:180px!important;
    white-space:nowrap!important;
    direction:rtl!important;
}


/* v14.87 — alliance chat engine + layout */
#content.alliance .cz-alliance-chat-box{
    position:relative!important;
}

#content.alliance .cz-chat-container{
    height:330px!important;
    background:#fffdf8!important;
}

#content.alliance .cz-chat-messages{
    position:relative!important;
    height:286px!important;
    min-height:286px!important;
    max-height:286px!important;
    overflow-y:auto!important;
    overflow-x:hidden!important;
    padding:12px 14px 16px!important;
    box-sizing:border-box!important;
    direction:rtl!important;
    text-align:right!important;
}

#content.alliance .cz-chat-line{
    display:block!important;
    width:100%!important;
    padding:7px 9px!important;
    margin:0 0 5px 0!important;
    box-sizing:border-box!important;
    border-bottom:1px solid #f0e6d5!important;
    direction:rtl!important;
    text-align:right!important;
    line-height:1.65!important;
    color:#293b33!important;
}

#content.alliance .cz-chat-time{
    display:inline-block!important;
    direction:ltr!important;
    color:#8a7d67!important;
    font-size:11px!important;
    margin-left:6px!important;
}

#content.alliance .cz-chat-user{
    color:#08704d!important;
    font-weight:700!important;
    text-decoration:none!important;
}

#content.alliance .cz-chat-text{
    color:#283a32!important;
    white-space:normal!important;
    overflow-wrap:anywhere!important;
}

#content.alliance .cz-chat-autoscroll{
    bottom:10px!important;
    right:14px!important;
    z-index:2!important;
    background:rgba(255,253,248,.92)!important;
    padding:3px 5px!important;
    border-radius:5px!important;
}

#content.alliance .cz-chat-compose{
    grid-template-columns:minmax(0,1fr) 96px!important;
    padding:12px 13px!important;
}

#content.alliance .cz-chat-send{
    width:96px!important;
}


/* v14.92 — support page RTL layout */
#content.plus .cz-support-page{
    width:100%!important;
    direction:rtl!important;
    text-align:right!important;
    box-sizing:border-box!important;
}

#content.plus .cz-support-heading h1{
    margin:0 0 16px!important;
    padding:0 0 14px!important;
    text-align:center!important;
    color:#07583f!important;
    font-size:30px!important;
    border-bottom:1px solid #d9ab2b!important;
    position:relative!important;
}

#content.plus .cz-support-heading h1:after{
    content:""!important;
    position:absolute!important;
    width:10px!important;
    height:10px!important;
    background:#d9ab2b!important;
    transform:rotate(45deg)!important;
    bottom:-5px!important;
    right:50%!important;
    margin-right:-5px!important;
}

#content.plus .cz-support-intro{
    padding:0 8px!important;
    margin-bottom:18px!important;
    color:#35443d!important;
    line-height:1.85!important;
    font-size:14px!important;
    text-align:right!important;
}

#content.plus .cz-support-intro p{
    margin:0 0 6px!important;
}

#content.plus .cz-support-note{
    color:#6a6256!important;
}

#content.plus .cz-support-types{
    margin:14px 0 16px!important;
    padding:10px 14px!important;
    background:#f6efe2!important;
    border:1px solid #e0d1b7!important;
    border-radius:9px!important;
    color:#174936!important;
    font-weight:700!important;
    text-align:right!important;
}

#content.plus .cz-support-form{
    display:flex!important;
    flex-direction:column!important;
    gap:12px!important;
    width:100%!important;
    margin:0!important;
    padding:0!important;
}

#content.plus .cz-support-field{
    display:grid!important;
    grid-template-columns:170px minmax(0,1fr)!important;
    gap:14px!important;
    align-items:center!important;
    width:100%!important;
    padding:0!important;
    margin:0!important;
    direction:rtl!important;
}

#content.plus .cz-support-field label{
    color:#174936!important;
    font-weight:700!important;
    text-align:right!important;
    padding:0 4px!important;
}

#content.plus .cz-support-field input,
#content.plus .cz-support-field select,
#content.plus .cz-support-field textarea{
    width:100%!important;
    box-sizing:border-box!important;
    border:1px solid #d6c5a8!important;
    border-radius:8px!important;
    background:#fffdf8!important;
    color:#263b32!important;
    direction:rtl!important;
    text-align:right!important;
    font-size:14px!important;
    outline:none!important;
}

#content.plus .cz-support-field input,
#content.plus .cz-support-field select{
    height:42px!important;
    padding:0 12px!important;
}

#content.plus .cz-support-field textarea{
    min-height:180px!important;
    resize:vertical!important;
    padding:12px!important;
    line-height:1.7!important;
}

#content.plus .cz-support-field input:focus,
#content.plus .cz-support-field select:focus,
#content.plus .cz-support-field textarea:focus{
    border-color:#c49a20!important;
    box-shadow:0 0 0 2px rgba(196,154,32,.12)!important;
}

#content.plus .cz-support-message-field{
    align-items:start!important;
}

#content.plus .cz-support-message-field label{
    padding-top:11px!important;
}

#content.plus .cz-support-actions{
    display:flex!important;
    flex-direction:row!important;
    justify-content:flex-start!important;
    gap:10px!important;
    padding-right:184px!important;
    margin-top:4px!important;
    direction:rtl!important;
}

#content.plus .cz-support-actions button{
    min-width:120px!important;
    height:40px!important;
    border-radius:8px!important;
    font-weight:700!important;
    cursor:pointer!important;
}

#content.plus .cz-support-submit{
    background:#07583f!important;
    color:#f6c83f!important;
    border:1px solid #d0a51d!important;
}

#content.plus .cz-support-reset{
    background:#fffaf1!important;
    color:#174936!important;
    border:1px solid #d8c7aa!important;
}

@media (max-width:900px){
    #content.plus .cz-support-field{
        grid-template-columns:1fr!important;
        gap:6px!important;
    }
    #content.plus .cz-support-actions{
        padding-right:0!important;
    }
}


/* v14.93 — final support form geometry */
#content.plus .cz-support-page{
    width:100%!important;
    max-width:none!important;
    box-sizing:border-box!important;
    padding:0 12px 24px!important;
}

#content.plus .cz-support-intro,
#content.plus .cz-support-types{
    width:100%!important;
    max-width:720px!important;
    margin-left:auto!important;
    margin-right:auto!important;
    box-sizing:border-box!important;
}

#content.plus .cz-support-form{
    display:block!important;
    width:700px!important;
    max-width:calc(100% - 20px)!important;
    min-width:0!important;
    margin:18px auto 0!important;
    padding:18px!important;
    box-sizing:border-box!important;
    border:1px solid #e0d1b7!important;
    border-radius:12px!important;
    background:#fffaf2!important;
    direction:rtl!important;
    float:none!important;
    clear:both!important;
}

#content.plus .cz-support-field{
    display:grid!important;
    grid-template-columns:150px minmax(0,1fr)!important;
    width:100%!important;
    max-width:none!important;
    min-width:0!important;
    gap:14px!important;
    align-items:center!important;
    margin:0 0 12px!important;
    padding:0!important;
    float:none!important;
    clear:both!important;
    box-sizing:border-box!important;
}

#content.plus .cz-support-field label{
    width:auto!important;
    max-width:none!important;
    margin:0!important;
    padding:0!important;
    text-align:right!important;
    white-space:nowrap!important;
    line-height:42px!important;
    color:#174936!important;
    font-weight:700!important;
    float:none!important;
}

#content.plus .cz-support-field input[type="text"],
#content.plus .cz-support-field input[type="email"],
#content.plus .cz-support-field select{
    display:block!important;
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    height:42px!important;
    margin:0!important;
    padding:0 12px!important;
    box-sizing:border-box!important;
    float:none!important;
}

#content.plus .cz-support-message-field{
    align-items:start!important;
}

#content.plus .cz-support-message-field label{
    line-height:normal!important;
    padding-top:12px!important;
}

#content.plus .cz-support-message-field textarea{
    display:block!important;
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    min-height:190px!important;
    height:190px!important;
    margin:0!important;
    padding:12px!important;
    box-sizing:border-box!important;
    resize:vertical!important;
    float:none!important;
}

#content.plus .cz-support-actions{
    display:flex!important;
    width:100%!important;
    max-width:none!important;
    flex-direction:row!important;
    justify-content:flex-start!important;
    align-items:center!important;
    gap:10px!important;
    margin:4px 0 0!important;
    padding:0 164px 0 0!important;
    box-sizing:border-box!important;
    float:none!important;
    clear:both!important;
    direction:rtl!important;
}

#content.plus .cz-support-actions button{
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    min-width:130px!important;
    width:auto!important;
    height:40px!important;
    margin:0!important;
    padding:0 18px!important;
    box-sizing:border-box!important;
    float:none!important;
}

@media (max-width:760px){
    #content.plus .cz-support-form{
        width:100%!important;
        max-width:100%!important;
        padding:14px!important;
    }

    #content.plus .cz-support-field{
        grid-template-columns:1fr!important;
        gap:6px!important;
    }

    #content.plus .cz-support-field label{
        line-height:normal!important;
    }

    #content.plus .cz-support-actions{
        padding:0!important;
        flex-wrap:wrap!important;
    }
}


/* =========================================================
   CITYZERO STEP 02D — FINAL RESOURCE GRID OVERRIDE
   مهم: selectors أعلى من قواعد ranking/map القديمة.
   ========================================================= */

/* نفس جسم الشريط في كل الصفحات، بما فيها صفحة الترتيب */
body #res.cz-resbar-ar,
body.cz-ranking-body #res.cz-resbar-ar,
body.cz-map-body #res.cz-resbar-ar{
    left:0!important;
    right:0!important;
    width:100%!important;
    max-width:none!important;
    min-width:0!important;
    padding:0!important;
    margin-left:0!important;
    margin-right:0!important;
    box-sizing:border-box!important;
}

/* نفس الشبكة حرفياً في جميع الصفحات */
body #res.cz-resbar-ar > #resWrap.cz-reswrap-ar,
body.cz-ranking-body #res.cz-resbar-ar > #resWrap.cz-reswrap-ar,
body.cz-map-body #res.cz-resbar-ar > #resWrap.cz-reswrap-ar{
    position:static!important;
    left:auto!important;
    right:auto!important;
    top:auto!important;
    width:100%!important;
    max-width:none!important;
    min-width:0!important;
    height:48px!important;
    margin:0!important;
    padding:0!important;
    transform:none!important;
    display:grid!important;
    grid-template-columns:repeat(6,minmax(0,1fr))!important;
    grid-template-rows:48px!important;
    gap:0!important;
    direction:rtl!important;
    overflow:visible!important;
    box-sizing:border-box!important;
}

/* كل مورد يحتل بالضبط سدس الشريط */
body #res.cz-resbar-ar > #resWrap.cz-reswrap-ar > .cz-res-item,
body.cz-ranking-body #res.cz-resbar-ar > #resWrap.cz-reswrap-ar > .cz-res-item,
body.cz-map-body #res.cz-resbar-ar > #resWrap.cz-reswrap-ar > .cz-res-item{
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    height:48px!important;
    min-height:48px!important;
    margin:0!important;
    padding:0 8px!important;
    border-left:1px solid #e3d7c2!important;
    border-right:0!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:7px!important;
    box-sizing:border-box!important;
    white-space:nowrap!important;
}

/* لا نخلي أي خانة خاصة تغيّر قياسها */
body #res.cz-resbar-ar .cz-res-item:first-child,
body #res.cz-resbar-ar .cz-res-item:last-child,
body #res.cz-resbar-ar .cz-res-gold,
body #res.cz-resbar-ar .cz-res-pop{
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    margin:0!important;
}

/* ترتيب داخلي موحد: أيقونة، اسم، قيمة */
body #res.cz-resbar-ar .cz-res-item img{
    flex:0 0 22px!important;
    width:22px!important;
    height:22px!important;
    max-width:22px!important;
    max-height:22px!important;
    margin:0!important;
    object-fit:contain!important;
}
body #res.cz-resbar-ar .cz-res-name{
    flex:0 0 44px!important;
    width:44px!important;
    min-width:44px!important;
    max-width:44px!important;
    margin:0!important;
    text-align:center!important;
}
body #res.cz-resbar-ar .cz-res-value{
    flex:0 0 76px!important;
    width:76px!important;
    min-width:76px!important;
    max-width:76px!important;
    margin:0!important;
    text-align:center!important;
    font-variant-numeric:tabular-nums!important;
}

/* يمنع قواعد responsive القديمة من تغيير المسافات */
@media(max-width:1250px){
    body #res.cz-resbar-ar > #resWrap.cz-reswrap-ar,
    body.cz-ranking-body #res.cz-resbar-ar > #resWrap.cz-reswrap-ar,
    body.cz-map-body #res.cz-resbar-ar > #resWrap.cz-reswrap-ar{
        width:100%!important;
        max-width:none!important;
        grid-template-columns:repeat(6,minmax(0,1fr))!important;
        gap:0!important;
        overflow:visible!important;
    }
}

/* =========================================================
   CITY ZERO V24 - clean public profile description boxes
   ========================================================= */
#content.player>table#profile>tbody>tr>td.desc1{
    padding:14px!important;
}

#content.player .cz-player-descriptions{
    display:flex!important;
    flex-direction:column!important;
    gap:12px!important;
    width:100%!important;
    min-height:0!important;
    padding:0!important;
    margin:0!important;
    background:transparent!important;
    border:0!important;
    box-sizing:border-box!important;
}

#content.player .cz-player-description-box{
    width:100%!important;
    min-height:112px!important;
    margin:0!important;
    padding:0!important;
    overflow:hidden!important;
    background:#fffdf8!important;
    border:1px solid #ddd0b9!important;
    border-radius:9px!important;
    box-sizing:border-box!important;
}

#content.player .cz-player-description-box h3{
    margin:0!important;
    padding:9px 12px!important;
    background:#edf4ed!important;
    color:#07583f!important;
    border:0!important;
    border-bottom:1px solid #ddd0b9!important;
    text-align:right!important;
    font:700 13px/1.4 Tahoma,Arial,sans-serif!important;
}

#content.player .cz-player-description-text{
    min-height:72px!important;
    padding:11px 12px!important;
    direction:rtl!important;
    text-align:right!important;
    color:#263d33!important;
    background:#fffdf8!important;
    border:0!important;
    box-sizing:border-box!important;
    overflow-wrap:anywhere!important;
    white-space:normal!important;
    font:500 13px/1.7 Tahoma,Arial,sans-serif!important;
}

#content.player .cz-empty-description{
    display:block!important;
    color:#8a8276!important;
    font-weight:400!important;
    text-align:center!important;
    padding-top:17px!important;
}

/* Disable the obsolete description box that used to appear inside details. */
#content.player>table#profile .desc2,
#content.player>table#profile .desc2div{
    display:none!important;
}


/* =========================================================
   CITYZERO STEP 03 — SIDEBAR CARDS ONLY
   القوائم الجانبية + مدير المهام فقط.
   ========================================================= */

/* العمود الأيمن */
body #side_navi{
    width:194px!important;
    direction:rtl!important;
    text-align:right!important;
}

/* كل بطاقات القائمة اليمنى بنفس القياس والشكل */
body #side_navi .cz-player-card,
body #side_navi .cz-menu-card,
body #side_navi .cz-extra-card,
body #side_navi .cz-logout-card,
body #side_navi > div:not(.clear){
    box-sizing:border-box!important;
    border-radius:13px!important;
}

/* بطاقة اللاعب الحالية */
body .cz-player-card{
    min-height:92px!important;
    padding:13px 14px!important;
    border:1px solid #dfcfaa!important;
    background:#fffaf1!important;
    box-shadow:0 5px 15px rgba(57,43,18,.07)!important;
    display:flex!important;
    align-items:center!important;
    justify-content:flex-start!important;
    gap:12px!important;
}

body .cz-player-card .cz-avatar{
    width:54px!important;
    height:54px!important;
    min-width:54px!important;
    border-radius:12px!important;
    background:#00684f!important;
    border:2px solid #d5a62b!important;
    color:#f6c53d!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    font-size:28px!important;
    font-weight:700!important;
    box-shadow:0 2px 7px rgba(0,0,0,.12)!important;
}

body .cz-player-card strong{
    display:block!important;
    color:#173b31!important;
    font-size:13px!important;
    line-height:19px!important;
    margin:0!important;
}
body .cz-player-card small{
    display:block!important;
    color:#837763!important;
    font-size:10px!important;
    margin-top:2px!important;
}

/* البطاقات القياسية في الجانب الأيمن */
body #side_navi .cz-menu-card,
body #side_navi .cz-extra-card{
    margin-top:14px!important;
    padding:12px 13px!important;
    background:#fffaf1!important;
    border:1px solid #dfcfaa!important;
    box-shadow:0 5px 15px rgba(57,43,18,.055)!important;
}

body #side_navi .cz-menu-card a,
body #side_navi .cz-extra-card a{
    min-height:35px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:flex-start!important;
    gap:9px!important;
    padding:5px 7px!important;
    margin:0!important;
    box-sizing:border-box!important;
    border-radius:7px!important;
    color:#173b31!important;
    text-decoration:none!important;
    font-weight:700!important;
    font-size:12px!important;
    line-height:20px!important;
}

body #side_navi .cz-menu-card a:hover,
body #side_navi .cz-extra-card a:hover{
    background:#f3ead7!important;
    color:#00684f!important;
}

/* تسجيل الخروج كبطاقة مستقلة ثابتة */
body #side_navi .cz-logout-card{
    margin-top:14px!important;
    min-height:58px!important;
    padding:0!important;
    overflow:hidden!important;
    border:1px solid #dfcfaa!important;
    background:#fffaf1!important;
    box-shadow:0 5px 15px rgba(57,43,18,.055)!important;
}
body #side_navi .cz-logout-card a{
    width:100%!important;
    min-height:58px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:9px!important;
    color:#174638!important;
    font-size:13px!important;
    font-weight:700!important;
    text-decoration:none!important;
}

/* العمود الأيسر — مدير المهام */
body #side_info{
    width:198px!important;
}

body #side_info #qge,
body #side_info .cz-task-card,
body .cz-taskmaster-card{
    box-sizing:border-box!important;
    border:1px solid #dfcfaa!important;
    border-radius:13px!important;
    background:#fffaf1!important;
    box-shadow:0 5px 15px rgba(57,43,18,.07)!important;
}

/* لا نغيّر وظيفة مدير المهام؛ فقط مظهر الحاوية */
body #side_info #qge{
    overflow:visible!important;
}

/* توحيد المسافة الرأسية للعمودين على كل الصفحات */
body #mid > #side_navi,
body #mid > #side_info{
    margin-top:0!important;
}

/* لا تسمح لقواعد صفحات محددة بتغيير عرض الكروت */
body.cz-ranking-body #side_navi,
body.cz-map-body #side_navi,
body.cz-ranking-body #side_info,
body.cz-map-body #side_info{
    transform:none!important;
}

/* شاشات أصغر: حافظ على القياس النسبي بدون تداخل */
@media(max-width:1250px){
    body #side_navi{width:184px!important;}
    body #side_info{width:188px!important;}
}


/* =========================================================
   CITYZERO STEP 04 — UNIFIED CENTER CONTENT SHELL
   توحيد منطقة المحتوى الوسطية فقط
   لا تعديل على دائرة القرية / المباني / الحفر
   ========================================================= */

/* تثبيت شبكة الصفحة الرئيسية: يسار + محتوى + يمين */
body #mid{
    box-sizing:border-box!important;
    align-items:flex-start!important;
}

/* توحيد الحاوية الوسطية في الصفحات */
body #content{
    box-sizing:border-box!important;
    margin-top:0!important;
}

/* الكارت الرئيسي: نفس العرض والحواف والمسافات */
body #content > .content,
body #content .cz-main-card,
body #content .cz-page-card{
    box-sizing:border-box!important;
    border-radius:15px!important;
    border:1px solid #dfcfaa!important;
    background:#fffdf8!important;
    box-shadow:0 8px 22px rgba(57,43,18,.07)!important;
}

/* منع صفحات التقارير/الترتيب/الخريطة من دفع المحتوى لأعلى أو أسفل */
body.cz-ranking-body #content,
body.cz-map-body #content,
body.cz-reports-body #content{
    margin-top:0!important;
    transform:none!important;
}

/* توحيد عناوين الصفحات داخل المنطقة الوسطية */
body #content h1,
body #content h2.cz-title,
body #content .cz-page-title{
    color:#006047!important;
    font-weight:700!important;
    text-align:center!important;
}

/* خط فاصل ذهبي موحد تحت العنوان */
body #content .cz-title-line,
body #content .cz-section-line{
    border-color:#d5a62b!important;
}

/* الجداول الداخلية تبقى ضمن حدود الكارت */
body #content table{
    max-width:100%!important;
    box-sizing:border-box!important;
}

/* يمنع العناصر الداخلية العامة من كسر عرض المحتوى */
body #content .cz-panel,
body #content .cz-tabs,
body #content .cz-table-wrap{
    max-width:100%!important;
    box-sizing:border-box!important;
}

/*
 مهم جداً:
 لا توجد هنا أي قواعد لـ:
 #village_map
 #map_details
 .buildingSlot
 .building
 #village_map img
 dorf2
 لذلك إحداثيات دائرة المباني تبقى كما هي.
*/


/* =========================================================
   MAP ONLY — RESTORE TASK MANAGER
   إصلاح مدير المهام في صفحة الخريطة فقط
   ========================================================= */
body.cz-map-body #mid{
    position:relative!important;
}

body.cz-map-body #side_info,
body.cz-map-body #side_info.cz-task-panel{
    display:block!important;
    visibility:visible!important;
    opacity:1!important;
    position:absolute!important;
    top:28px!important;
    left:0!important;
    right:auto!important;
    width:188px!important;
    min-width:188px!important;
    max-width:188px!important;
    height:auto!important;
    min-height:1px!important;
    margin:0!important;
    padding:0!important;
    float:none!important;
    z-index:60!important;
    transform:none!important;
    overflow:visible!important;
    pointer-events:auto!important;
}

body.cz-map-body #side_info > *,
body.cz-map-body #side_info #qge,
body.cz-map-body #side_info.cz-task-panel #qge,
body.cz-map-body #side_info .cz-task-manager{
    display:block!important;
    visibility:visible!important;
    opacity:1!important;
    width:100%!important;
    max-width:100%!important;
    position:static!important;
    float:none!important;
    margin:0!important;
    transform:none!important;
}

/* لا تأثير على باقي الصفحات */


/* =========================================================
   MAP TASK MANAGER FIX V2
   منع إظهار محتوى script/style كنص داخل صفحة الخريطة
   ========================================================= */

/* الإصلاح الأساسي: القاعدة السابقة جعلت كل أبناء side_info display:block
   وهذا شمل SCRIPT و STYLE فظهر الكود كنص في الصفحة. */
body.cz-map-body #side_info script,
body.cz-map-body #side_info style,
body.cz-map-body #side_info noscript{
    display:none!important;
    visibility:hidden!important;
    width:0!important;
    height:0!important;
    margin:0!important;
    padding:0!important;
    overflow:hidden!important;
}

/* أبقِ عناصر مدير المهام المرئية فقط ظاهرة */
body.cz-map-body #side_info #qge,
body.cz-map-body #side_info .cz-task-launcher,
body.cz-map-body #side_info .cz-task-button,
body.cz-map-body #side_info .cz-task-copy,
body.cz-map-body #side_info .cz-task-icon,
body.cz-map-body #side_info .cz-task-badge{
    visibility:visible!important;
    opacity:1!important;
}

/* لا نفرض display:block على كل طفل داخل side_info بعد الآن */
body.cz-map-body #side_info > script,
body.cz-map-body #side_info > style{
    position:absolute!important;
    left:-99999px!important;
    top:-99999px!important;
}


/* =========================================================
   CITYZERO STEP 08B — TASK MANAGER CSS ONLY
   تنسيق مدير المهام فقط بدون تعديل quest.tpl
   ========================================================= */

#qge.cz-task-launcher{
    width:100%!important;
    margin:0!important;
    padding:0!important;
    direction:rtl!important;
    text-align:right!important;
    box-sizing:border-box!important;
    background:transparent!important;
    border:0!important;
    box-shadow:none!important;
}

#qge.cz-task-launcher .cz-task-button{
    width:100%!important;
    min-height:96px!important;
    margin:0!important;
    padding:12px!important;
    box-sizing:border-box!important;

    display:grid!important;
    grid-template-columns:48px minmax(0,1fr)!important;
    grid-template-rows:auto auto!important;
    grid-template-areas:
        "icon copy"
        "icon badge"!important;
    column-gap:11px!important;
    row-gap:5px!important;

    border:1px solid #dfcfaa!important;
    border-radius:13px!important;
    background:#fffaf1!important;
    box-shadow:0 5px 15px rgba(57,43,18,.07)!important;
    cursor:pointer!important;

    font-family:Tahoma,Arial,sans-serif!important;
    color:#173b31!important;
    text-align:right!important;
    overflow:hidden!important;
}

#qge.cz-task-launcher .cz-task-button:hover{
    border-color:#c7aa68!important;
    background:#fff8e9!important;
    box-shadow:0 7px 18px rgba(57,43,18,.10)!important;
}

#qge.cz-task-launcher .cz-task-icon{
    grid-area:icon!important;
    width:48px!important;
    height:48px!important;
    min-width:48px!important;
    margin:0!important;

    display:flex!important;
    align-items:center!important;
    justify-content:center!important;

    border-radius:10px!important;
    border:1px solid #c99e34!important;
    background:#07563d!important;
    color:#f4ca51!important;
    font-size:28px!important;
    line-height:1!important;
    font-weight:700!important;
    box-shadow:inset 0 0 0 1px rgba(255,255,255,.05)!important;
}

#qge.cz-task-launcher .cz-task-copy{
    grid-area:copy!important;
    min-width:0!important;
    margin:0!important;
    padding:0!important;

    display:flex!important;
    flex-direction:column!important;
    align-items:flex-start!important;
    justify-content:center!important;
    gap:4px!important;
}

#qge.cz-task-launcher .cz-task-copy strong{
    display:block!important;
    margin:0!important;
    padding:0!important;
    color:#07563d!important;
    font-size:15px!important;
    line-height:20px!important;
    font-weight:700!important;
    white-space:nowrap!important;
}

#qge.cz-task-launcher .cz-task-copy small{
    display:block!important;
    margin:0!important;
    padding:0!important;
    color:#756d62!important;
    font-size:10px!important;
    line-height:16px!important;
    white-space:normal!important;
}

#qge.cz-task-launcher .cz-task-badge{
    grid-area:badge!important;
    justify-self:start!important;
    align-self:center!important;

    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;

    min-width:38px!important;
    height:20px!important;
    margin:0!important;
    padding:0 8px!important;
    box-sizing:border-box!important;

    border:1px solid #ead493!important;
    border-radius:10px!important;
    background:#f5e7b6!important;
    color:#856411!important;
    font-size:9px!important;
    line-height:18px!important;
    font-weight:700!important;
}

/* لما ماكو badge، يبقى الكرت مرتب وما يصير فراغ غريب */
#qge.cz-task-launcher .cz-task-button > .cz-task-copy:last-child{
    align-self:center!important;
}

/* حصر التعديل بمدير المهام فقط */
#side_info #qge.cz-task-launcher{
    max-width:100%!important;
}

/* ممنوع إظهار style/script كنص، خصوصاً بالخريطة */
#side_info #qge.cz-task-launcher ~ script,
#side_info #qge.cz-task-launcher ~ style{
    display:none!important;
}


/* =========================================================
   CITYZERO STEP 09 — BUTTONS / TABLES / INPUTS
   CSS ONLY — no PHP / JS / village-map changes
   ========================================================= */

/* ---------- Buttons ---------- */
#content input[type="submit"],
#content input[type="button"],
#content button,
#content .button,
#content a.button,
#content .btn,
#content a.btn{
    min-height:34px!important;
    padding:6px 14px!important;
    box-sizing:border-box!important;
    border:1px solid #d2a431!important;
    border-radius:8px!important;
    background:linear-gradient(180deg,#0b654a 0%,#07543e 100%)!important;
    color:#f4ce59!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:11px!important;
    font-weight:700!important;
    line-height:20px!important;
    text-decoration:none!important;
    text-align:center!important;
    cursor:pointer!important;
    box-shadow:0 3px 8px rgba(32,54,42,.10)!important;
}

#content input[type="submit"]:hover,
#content input[type="button"]:hover,
#content button:hover,
#content .button:hover,
#content a.button:hover,
#content .btn:hover,
#content a.btn:hover{
    background:linear-gradient(180deg,#0d7253 0%,#075b43 100%)!important;
    border-color:#e0b844!important;
    color:#ffe889!important;
}

/* secondary / cancel / delete buttons */
#content .cancel,
#content .secondary,
#content input.cancel,
#content button.cancel{
    background:#fffaf1!important;
    color:#765d21!important;
    border-color:#decda7!important;
    box-shadow:none!important;
}

#content .cancel:hover,
#content .secondary:hover,
#content input.cancel:hover,
#content button.cancel:hover{
    background:#f5ecd8!important;
    color:#5f4816!important;
}

/* destructive buttons */
#content .delete,
#content .danger,
#content input.delete,
#content button.delete{
    background:linear-gradient(180deg,#c34a34,#a93827)!important;
    border-color:#983120!important;
    color:#fff5e9!important;
}

/* ---------- Inputs ---------- */
#content input[type="text"],
#content input[type="password"],
#content input[type="email"],
#content input[type="number"],
#content select,
#content textarea{
    box-sizing:border-box!important;
    border:1px solid #d9cbaa!important;
    border-radius:8px!important;
    background:#fffdf8!important;
    color:#26382f!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:11px!important;
    outline:none!important;
    box-shadow:inset 0 1px 2px rgba(54,41,18,.04)!important;
}

#content input[type="text"],
#content input[type="password"],
#content input[type="email"],
#content input[type="number"],
#content select{
    min-height:32px!important;
    padding:5px 9px!important;
}

#content textarea{
    padding:9px 10px!important;
    line-height:1.7!important;
    resize:vertical!important;
}

#content input:focus,
#content select:focus,
#content textarea:focus{
    border-color:#c79b2a!important;
    box-shadow:0 0 0 2px rgba(207,165,46,.12)!important;
}

/* ---------- Tables ---------- */
#content table:not(.map_details):not(.build_details){
    border-collapse:separate!important;
    border-spacing:0!important;
    width:100%!important;
    max-width:100%!important;
    box-sizing:border-box!important;
    border:1px solid #ddd0b4!important;
    border-radius:10px!important;
    overflow:hidden!important;
    background:#fffdf8!important;
}

#content table:not(.map_details):not(.build_details) th,
#content table:not(.map_details):not(.build_details) thead td{
    background:#0b5540!important;
    color:#fff7dc!important;
    border-color:#0b5540!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:11px!important;
    font-weight:700!important;
    padding:9px 8px!important;
}

#content table:not(.map_details):not(.build_details) td{
    background:#fffdf8!important;
    color:#334039!important;
    border-color:#ebe1cc!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:11px!important;
    padding:8px!important;
    vertical-align:middle!important;
}

#content table:not(.map_details):not(.build_details) tr:nth-child(even) td{
    background:#fbf6eb!important;
}

#content table:not(.map_details):not(.build_details) tr:hover td{
    background:#f6eedc!important;
}

/* ---------- Section boxes ---------- */
#content .box,
#content .panel,
#content .section,
#content .contentBox{
    border-color:#ddd0b4!important;
    border-radius:10px!important;
}

/* ---------- Tabs / subnavigation ---------- */
#content #textmenu,
#content .tabs,
#content .subnav{
    font-family:Tahoma,Arial,sans-serif!important;
}

#content #textmenu a,
#content .tabs a,
#content .subnav a{
    border-radius:8px!important;
}

/* ---------- Links ---------- */
#content a{
    transition:background .12s ease,border-color .12s ease,color .12s ease!important;
}

/* ---------- Checkbox/radio alignment ---------- */
#content input[type="checkbox"],
#content input[type="radio"]{
    vertical-align:middle!important;
    margin:0 4px!important;
}

/*
  SAFETY:
  لا selectors لـ:
  #village_map
  .building
  .d1-.d20
  map1/map2
  لذلك دائرة القرية تبقى بدون أي تغيير.
*/


/* =========================================================
   CITYZERO STEP 10 — TITLES / TABS / SECTION HEADERS
   CSS ONLY
   ========================================================= */

/* ---------- Main page titles ---------- */
#content > h1,
#content .cz-page-title,
#content .pageTitle{
    position:relative!important;
    margin:0 0 16px!important;
    padding:4px 8px 13px!important;
    color:#07563d!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:26px!important;
    line-height:36px!important;
    font-weight:700!important;
    text-align:center!important;
    border-bottom:1px solid #d6aa39!important;
    box-sizing:border-box!important;
}

#content > h1:after,
#content .cz-page-title:after,
#content .pageTitle:after{
    content:""!important;
    position:absolute!important;
    left:50%!important;
    bottom:-5px!important;
    width:9px!important;
    height:9px!important;
    margin-left:-4px!important;
    background:#d6a428!important;
    transform:rotate(45deg)!important;
    border-radius:1px!important;
}

/* ---------- Sub headings ---------- */
#content h2,
#content h3,
#content .section-title,
#content .box-title{
    font-family:Tahoma,Arial,sans-serif!important;
    color:#174638!important;
}

#content h2{
    font-size:18px!important;
    line-height:28px!important;
}

#content h3{
    font-size:14px!important;
    line-height:22px!important;
}

/* ---------- Green section header bars ---------- */
#content .sectionHeader,
#content .boxHeader,
#content .tableHeader,
#content .cz-section-header{
    min-height:36px!important;
    padding:7px 12px!important;
    box-sizing:border-box!important;
    border-radius:9px 9px 0 0!important;
    background:#0b5540!important;
    color:#fff7dc!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:12px!important;
    font-weight:700!important;
    line-height:20px!important;
}

/* ---------- Tabs / text menu ---------- */
#content #textmenu,
#content .tabs,
#content .subnav,
#content .cz-tabs{
    width:100%!important;
    margin:0 0 16px!important;
    padding:7px!important;
    box-sizing:border-box!important;
    display:flex!important;
    align-items:stretch!important;
    justify-content:center!important;
    gap:7px!important;
    direction:rtl!important;
    border:1px solid #dfd2b7!important;
    border-radius:11px!important;
    background:#f8f1e3!important;
}

#content #textmenu > a,
#content .tabs > a,
#content .subnav > a,
#content .cz-tabs > a{
    flex:1 1 0!important;
    min-width:0!important;
    min-height:38px!important;
    margin:0!important;
    padding:7px 9px!important;
    box-sizing:border-box!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:6px!important;
    border:1px solid #e1d5bb!important;
    border-radius:8px!important;
    background:#fffaf1!important;
    color:#173b31!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:11px!important;
    line-height:20px!important;
    font-weight:700!important;
    text-decoration:none!important;
    text-align:center!important;
    white-space:nowrap!important;
}

#content #textmenu > a:hover,
#content .tabs > a:hover,
#content .subnav > a:hover,
#content .cz-tabs > a:hover{
    background:#f5ead2!important;
    border-color:#cdb16d!important;
    color:#07563d!important;
}

#content #textmenu > a.selected,
#content #textmenu > a.active,
#content .tabs > a.selected,
#content .tabs > a.active,
#content .subnav > a.selected,
#content .subnav > a.active,
#content .cz-tabs > a.selected,
#content .cz-tabs > a.active{
    background:#07563d!important;
    border-color:#d2a431!important;
    color:#f4ce59!important;
    box-shadow:0 3px 9px rgba(24,63,48,.12)!important;
}

/* ---------- Info/warning/success boxes ---------- */
#content .notice,
#content .info,
#content .success,
#content .warning,
#content .error{
    padding:10px 12px!important;
    border-radius:9px!important;
    font-family:Tahoma,Arial,sans-serif!important;
    line-height:1.7!important;
    box-sizing:border-box!important;
}

#content .info{
    background:#eef6f2!important;
    border:1px solid #bfd8cc!important;
    color:#315b4b!important;
}

#content .success{
    background:#eff7e9!important;
    border:1px solid #c8dda9!important;
    color:#46652a!important;
}

#content .warning{
    background:#fff7df!important;
    border:1px solid #e6cf87!important;
    color:#725c17!important;
}

#content .error{
    background:#fff0eb!important;
    border:1px solid #e4b5a8!important;
    color:#8d3c2e!important;
}

/* ---------- Small badges ---------- */
#content .badge,
#content .tag,
#content .cz-badge{
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    min-height:20px!important;
    padding:2px 8px!important;
    box-sizing:border-box!important;
    border-radius:10px!important;
    background:#f5e7b6!important;
    border:1px solid #ead493!important;
    color:#856411!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:9px!important;
    font-weight:700!important;
}

/*
 SAFETY:
 لا تعديل على #village_map / slots / dorf2 / building coordinates.
*/


/* =========================================================
   CITYZERO STEP 11 — TASK MANAGER FINAL REFERENCE STYLE
   CSS ONLY — NO quest.tpl changes
   ========================================================= */

#side_info #qge.cz-task-launcher{
    width:198px!important;
    max-width:198px!important;
    margin:0!important;
    padding:0!important;
    box-sizing:border-box!important;
    direction:rtl!important;
    text-align:right!important;
    background:transparent!important;
    border:0!important;
    box-shadow:none!important;
}

#side_info #qge.cz-task-launcher .cz-task-button{
    position:relative!important;
    width:198px!important;
    min-width:198px!important;
    max-width:198px!important;
    height:142px!important;
    min-height:142px!important;
    margin:0!important;
    padding:16px 74px 47px 14px!important;
    box-sizing:border-box!important;

    display:block!important;
    border:1px solid #dac9a7!important;
    border-radius:13px!important;
    background:
        linear-gradient(180deg,#fffdf7 0%,#fff9ed 100%)!important;
    box-shadow:
        0 6px 18px rgba(57,43,18,.08),
        inset 0 0 0 1px rgba(255,255,255,.65)!important;

    color:#173b31!important;
    font-family:Tahoma,Arial,sans-serif!important;
    text-align:right!important;
    cursor:pointer!important;
    overflow:visible!important;
}

/* الرمز الكبير — بديل الصورة */
#side_info #qge.cz-task-launcher .cz-task-icon{
    position:absolute!important;
    right:14px!important;
    top:18px!important;
    width:50px!important;
    height:58px!important;
    min-width:50px!important;
    margin:0!important;
    padding:0!important;

    display:flex!important;
    align-items:center!important;
    justify-content:center!important;

    background:linear-gradient(180deg,#0a684d 0%,#07543e 100%)!important;
    border:2px solid #d2a431!important;
    border-radius:12px 12px 17px 17px!important;
    color:#f4cb50!important;
    font-size:31px!important;
    line-height:1!important;
    font-weight:700!important;
    box-shadow:0 4px 10px rgba(26,59,45,.18)!important;
}

/* رأس الدرع الصغير */
#side_info #qge.cz-task-launcher .cz-task-icon:before{
    content:""!important;
    position:absolute!important;
    left:8px!important;
    right:8px!important;
    top:-5px!important;
    height:5px!important;
    background:#d2a431!important;
    border-radius:5px 5px 1px 1px!important;
}

/* النص */
#side_info #qge.cz-task-launcher .cz-task-copy{
    display:flex!important;
    flex-direction:column!important;
    align-items:flex-start!important;
    justify-content:flex-start!important;
    gap:5px!important;
    width:100%!important;
    min-width:0!important;
    margin:0!important;
    padding:0!important;
}

#side_info #qge.cz-task-launcher .cz-task-copy strong{
    display:block!important;
    margin:2px 0 0!important;
    padding:0!important;
    color:#173b31!important;
    font-size:16px!important;
    line-height:22px!important;
    font-weight:700!important;
    white-space:nowrap!important;
}

#side_info #qge.cz-task-launcher .cz-task-copy small{
    display:block!important;
    margin:0!important;
    padding:0!important;
    color:#766b58!important;
    font-size:10px!important;
    line-height:16px!important;
    font-weight:400!important;
    white-space:normal!important;
}

/* شارة جديد كعلامة صغيرة أعلى الكرت */
#side_info #qge.cz-task-launcher .cz-task-badge{
    position:absolute!important;
    left:-7px!important;
    top:-8px!important;
    width:auto!important;
    min-width:38px!important;
    height:20px!important;
    margin:0!important;
    padding:0 8px!important;
    box-sizing:border-box!important;

    display:flex!important;
    align-items:center!important;
    justify-content:center!important;

    background:#f5e7b6!important;
    border:1px solid #ead493!important;
    border-radius:11px!important;
    color:#8a6916!important;
    font-size:9px!important;
    line-height:18px!important;
    font-weight:700!important;
    box-shadow:0 2px 5px rgba(70,50,18,.08)!important;
}

/* زر عرض — pseudo element فقط، بدون تغيير القالب */
#side_info #qge.cz-task-launcher .cz-task-button:after{
    content:"عرض"!important;
    position:absolute!important;
    left:14px!important;
    right:14px!important;
    bottom:12px!important;
    height:31px!important;

    display:flex!important;
    align-items:center!important;
    justify-content:center!important;

    box-sizing:border-box!important;
    border:1px solid #d2a431!important;
    border-radius:7px!important;
    background:linear-gradient(180deg,#0a6349 0%,#07523d 100%)!important;
    color:#f4ce59!important;
    font-size:11px!important;
    line-height:29px!important;
    font-weight:700!important;
    text-align:center!important;
    box-shadow:0 3px 8px rgba(31,61,47,.12)!important;
}

#side_info #qge.cz-task-launcher .cz-task-button:hover{
    border-color:#c9ae6a!important;
    background:#fffaf0!important;
    box-shadow:
        0 8px 20px rgba(57,43,18,.10),
        inset 0 0 0 1px rgba(255,255,255,.7)!important;
}

#side_info #qge.cz-task-launcher .cz-task-button:hover:after{
    background:linear-gradient(180deg,#0c7052 0%,#075b43 100%)!important;
    color:#ffe68a!important;
}

/* مهم: لا نظهر script/style كنص */
#side_info #qge.cz-task-launcher ~ script,
#side_info #qge.cz-task-launcher ~ style{
    display:none!important;
}

/* الخريطة تحتفظ بنفس مدير المهام بدون تغيير موقع الصفحة */
body.cz-map-body #side_info #qge.cz-task-launcher{
    display:block!important;
    visibility:visible!important;
    opacity:1!important;
}

/* لا تعديلات خارج مدير المهام */


/* =========================================================
   CITYZERO STEP 11B — RANKING TASK MANAGER FIX ONLY
   يعيد رمز مدير المهام داخل الكرت في صفحة الترتيب.
   ========================================================= */

body.cz-ranking-body #side_info #qge.cz-task-launcher{
    position:relative!important;
    width:198px!important;
    max-width:198px!important;
    overflow:visible!important;
}

body.cz-ranking-body #side_info #qge.cz-task-launcher .cz-task-button{
    position:relative!important;
    width:198px!important;
    min-width:198px!important;
    max-width:198px!important;
    height:142px!important;
    min-height:142px!important;
    padding:16px 74px 47px 14px!important;
    display:block!important;
    overflow:visible!important;
}

/* أهم إصلاح: يلغي أي position خاص بصفحة الترتيب */
body.cz-ranking-body #side_info #qge.cz-task-launcher .cz-task-icon{
    position:absolute!important;
    right:14px!important;
    left:auto!important;
    top:18px!important;
    bottom:auto!important;
    transform:none!important;
    float:none!important;
    margin:0!important;

    width:50px!important;
    height:58px!important;
    min-width:50px!important;
    max-width:50px!important;

    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    z-index:2!important;
}

body.cz-ranking-body #side_info #qge.cz-task-launcher .cz-task-copy{
    position:static!important;
    float:none!important;
    transform:none!important;
    margin:0!important;
    width:100%!important;
}

body.cz-ranking-body #side_info #qge.cz-task-launcher .cz-task-badge{
    position:absolute!important;
    left:-7px!important;
    right:auto!important;
    top:-8px!important;
    transform:none!important;
    float:none!important;
}

body.cz-ranking-body #side_info #qge.cz-task-launcher .cz-task-button:after{
    left:14px!important;
    right:14px!important;
    bottom:12px!important;
    top:auto!important;
    transform:none!important;
}

/* يمنع أي selector قديم بصفحة الإحصائيات من سحب الرمز خارج side_info */
body.cz-ranking-body .cz-task-icon{
    margin-left:0!important;
    margin-right:0!important;
}



/* =========================================================
   CITYZERO STEP 11C — RANKING TASK MANAGER
   High-specificity override for old ranking grid rules.
   ========================================================= */

/* نفس selector القديم لكن أقوى بإضافة body + #qge */
body.cz-ranking-body #mid:has(> #content.statistics) > #side_info #qge.cz-task-launcher{
    position:relative!important;
    width:185px!important;
    min-width:185px!important;
    max-width:185px!important;
    height:auto!important;
    margin:0!important;
    padding:0!important;
    overflow:visible!important;
}

/* هذه هي القاعدة التي كانت تمنع التصميم السابق */
body.cz-ranking-body #mid:has(> #content.statistics) > #side_info #qge.cz-task-launcher .cz-task-button{
    position:relative!important;
    width:185px!important;
    min-width:185px!important;
    max-width:185px!important;
    height:142px!important;
    min-height:142px!important;
    margin:0!important;
    padding:16px 70px 47px 13px!important;
    display:block!important;
    float:none!important;
    transform:none!important;
    overflow:visible!important;
    box-sizing:border-box!important;

    border:1px solid #dac9a7!important;
    border-radius:13px!important;
    background:linear-gradient(180deg,#fffdf7 0%,#fff9ed 100%)!important;
    box-shadow:0 6px 18px rgba(57,43,18,.08)!important;
}

/* الرمز يرجع داخل البطاقة */
body.cz-ranking-body #mid:has(> #content.statistics) > #side_info #qge.cz-task-launcher .cz-task-icon{
    position:absolute!important;
    right:13px!important;
    left:auto!important;
    top:18px!important;
    bottom:auto!important;
    width:48px!important;
    min-width:48px!important;
    max-width:48px!important;
    height:56px!important;
    min-height:56px!important;
    max-height:56px!important;
    margin:0!important;
    padding:0!important;
    float:none!important;
    transform:none!important;
    z-index:5!important;

    display:flex!important;
    align-items:center!important;
    justify-content:center!important;

    background:linear-gradient(180deg,#0a684d 0%,#07543e 100%)!important;
    border:2px solid #d2a431!important;
    border-radius:12px 12px 16px 16px!important;
    color:#f4cb50!important;
    font-size:30px!important;
    line-height:1!important;
    font-weight:700!important;
    box-sizing:border-box!important;
}

body.cz-ranking-body #mid:has(> #content.statistics) > #side_info #qge.cz-task-launcher .cz-task-icon:before{
    content:""!important;
    position:absolute!important;
    left:8px!important;
    right:8px!important;
    top:-5px!important;
    height:5px!important;
    background:#d2a431!important;
    border-radius:5px 5px 1px 1px!important;
}

/* النص يبقى داخل الكرت */
body.cz-ranking-body #mid:has(> #content.statistics) > #side_info #qge.cz-task-launcher .cz-task-copy{
    position:static!important;
    width:100%!important;
    min-width:0!important;
    margin:0!important;
    padding:0!important;
    float:none!important;
    transform:none!important;
    display:flex!important;
    flex-direction:column!important;
    align-items:flex-start!important;
    gap:5px!important;
}

body.cz-ranking-body #mid:has(> #content.statistics) > #side_info #qge.cz-task-launcher .cz-task-copy strong{
    display:block!important;
    margin:2px 0 0!important;
    color:#173b31!important;
    font-size:16px!important;
    line-height:22px!important;
    font-weight:700!important;
    white-space:nowrap!important;
}

body.cz-ranking-body #mid:has(> #content.statistics) > #side_info #qge.cz-task-launcher .cz-task-copy small{
    display:block!important;
    margin:0!important;
    color:#766b58!important;
    font-size:10px!important;
    line-height:16px!important;
}

/* شارة جديد */
body.cz-ranking-body #mid:has(> #content.statistics) > #side_info #qge.cz-task-launcher .cz-task-badge{
    position:absolute!important;
    left:-6px!important;
    right:auto!important;
    top:-8px!important;
    width:auto!important;
    min-width:38px!important;
    height:20px!important;
    margin:0!important;
    padding:0 8px!important;
    float:none!important;
    transform:none!important;
    z-index:6!important;
}

/* زر عرض الوهمي بالأسفل */
body.cz-ranking-body #mid:has(> #content.statistics) > #side_info #qge.cz-task-launcher .cz-task-button:after{
    content:"عرض"!important;
    position:absolute!important;
    left:13px!important;
    right:13px!important;
    bottom:12px!important;
    top:auto!important;
    height:31px!important;
    transform:none!important;
    z-index:4!important;

    display:flex!important;
    align-items:center!important;
    justify-content:center!important;

    border:1px solid #d2a431!important;
    border-radius:7px!important;
    background:linear-gradient(180deg,#0a6349 0%,#07523d 100%)!important;
    color:#f4ce59!important;
    font-size:11px!important;
    font-weight:700!important;
    box-sizing:border-box!important;
}

/* يلغي قواعد responsive القديمة التي تصغر الكرت إلى 170 */
@media(max-width:1120px){
    body.cz-ranking-body #mid:has(> #content.statistics) > #side_info #qge.cz-task-launcher,
    body.cz-ranking-body #mid:has(> #content.statistics) > #side_info #qge.cz-task-launcher .cz-task-button{
        width:185px!important;
        min-width:185px!important;
        max-width:185px!important;
    }
}


/* =========================================================
   CITYZERO STEP 12 — REAL JPG SHIELD FOR TASK MANAGER
   Uses: /game/img/custom/task_manager_shield.jpg
   ========================================================= */

/* الصورة الحقيقية بدل علامة الصح */
#side_info #qge.cz-task-launcher .cz-task-icon,
body.cz-ranking-body #mid:has(> #content.statistics) > #side_info #qge.cz-task-launcher .cz-task-icon{
    position:absolute!important;
    right:12px!important;
    left:auto!important;
    top:14px!important;
    bottom:auto!important;

    width:66px!important;
    min-width:66px!important;
    max-width:66px!important;
    height:76px!important;
    min-height:76px!important;
    max-height:76px!important;

    margin:0!important;
    padding:0!important;
    float:none!important;
    transform:none!important;

    background-color:transparent!important;
    background-image:url("/game/img/custom/task_manager_shield.jpg")!important;
    background-repeat:no-repeat!important;
    background-position:center center!important;
    background-size:contain!important;

    border:0!important;
    border-radius:0!important;
    box-shadow:none!important;

    color:transparent!important;
    font-size:0!important;
    line-height:0!important;
    text-indent:-9999px!important;
    overflow:hidden!important;
    z-index:5!important;
}

/* إلغاء شكل الدرع المصنوع بالـCSS القديم */
#side_info #qge.cz-task-launcher .cz-task-icon:before,
body.cz-ranking-body #mid:has(> #content.statistics) > #side_info #qge.cz-task-launcher .cz-task-icon:before{
    content:none!important;
    display:none!important;
}

/* مساحة كافية للصورة داخل الكرت */
#side_info #qge.cz-task-launcher .cz-task-button{
    min-height:146px!important;
    height:146px!important;
    padding:17px 84px 48px 13px!important;
}

body.cz-ranking-body #mid:has(> #content.statistics) > #side_info #qge.cz-task-launcher .cz-task-button{
    min-height:146px!important;
    height:146px!important;
    padding:17px 78px 48px 12px!important;
}

/* النص أقرب للتصميم المرجعي */
#side_info #qge.cz-task-launcher .cz-task-copy strong{
    font-size:16px!important;
    line-height:22px!important;
    color:#173b31!important;
}

#side_info #qge.cz-task-launcher .cz-task-copy small{
    font-size:10px!important;
    line-height:16px!important;
    color:#756a58!important;
}

/* زر العرض */
#side_info #qge.cz-task-launcher .cz-task-button:after{
    left:13px!important;
    right:13px!important;
    bottom:11px!important;
    height:32px!important;
}

/* صفحة الترتيب تحديداً */
body.cz-ranking-body #mid:has(> #content.statistics) > #side_info #qge.cz-task-launcher .cz-task-button:after{
    left:12px!important;
    right:12px!important;
    bottom:11px!important;
}

/* لا تعرض أي خلفية قديمة خلف الصورة */
#side_info #qge.cz-task-launcher .cz-task-icon img{
    display:none!important;
}


/* =========================================================
   CITYZERO STEP 13 — DAILY TASKS CARD TEMPLATE
   NO IMAGE YET
   ========================================================= */

#side_info #czDailyTasks.cz-daily-card{
    width:198px!important;
    max-width:198px!important;
    margin:14px 0 0!important;
    padding:12px!important;
    box-sizing:border-box!important;

    background:linear-gradient(180deg,#fffdf7 0%,#fff9ed 100%)!important;
    border:1px solid #dac9a7!important;
    border-radius:13px!important;
    box-shadow:0 6px 18px rgba(57,43,18,.08)!important;

    direction:rtl!important;
    text-align:right!important;
    font-family:Tahoma,Arial,sans-serif!important;
    color:#173b31!important;
}

#side_info #czDailyTasks .cz-daily-head{
    display:flex!important;
    align-items:flex-start!important;
    justify-content:space-between!important;
    gap:8px!important;
    padding:0 0 9px!important;
    margin:0 0 10px!important;
    border-bottom:1px solid #eadfc8!important;
}

#side_info #czDailyTasks .cz-daily-title-wrap{
    min-width:0!important;
    flex:1!important;
}

#side_info #czDailyTasks .cz-daily-title{
    display:block!important;
    margin:0!important;
    padding:0!important;
    color:#173b31!important;
    font-size:15px!important;
    line-height:21px!important;
    font-weight:700!important;
    white-space:nowrap!important;
}

#side_info #czDailyTasks .cz-daily-subtitle{
    display:block!important;
    margin:3px 0 0!important;
    padding:0!important;
    color:#796e5d!important;
    font-size:9px!important;
    line-height:15px!important;
    font-weight:400!important;
}

#side_info #czDailyTasks .cz-daily-status{
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    min-width:35px!important;
    height:20px!important;
    padding:0 7px!important;
    box-sizing:border-box!important;
    border:1px solid #ead493!important;
    border-radius:10px!important;
    background:#f5e7b6!important;
    color:#856411!important;
    font-size:9px!important;
    font-weight:700!important;
    white-space:nowrap!important;
}

/* مكان الصورة فقط — يبقى فارغ في STEP 13 */
#side_info #czDailyTasks .cz-daily-art-slot{
    width:100%!important;
    height:68px!important;
    margin:0 0 10px!important;
    padding:0!important;
    box-sizing:border-box!important;
    border:1px dashed #ded0b1!important;
    border-radius:10px!important;
    background:
        linear-gradient(180deg,rgba(245,235,211,.50),rgba(255,250,241,.25))!important;
}

/* التقدم */
#side_info #czDailyTasks .cz-daily-progress-wrap{
    width:100%!important;
    margin:0 0 10px!important;
}

#side_info #czDailyTasks .cz-daily-progress-top{
    display:flex!important;
    align-items:center!important;
    justify-content:space-between!important;
    gap:8px!important;
    margin:0 0 5px!important;
    color:#6f6658!important;
    font-size:9px!important;
    line-height:14px!important;
}

#side_info #czDailyTasks .cz-daily-progress-top b{
    color:#07563d!important;
    font-size:10px!important;
    font-weight:700!important;
}

#side_info #czDailyTasks .cz-daily-progress{
    position:relative!important;
    width:100%!important;
    height:8px!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
    border:1px solid #ddd0b4!important;
    border-radius:5px!important;
    background:#eee5d3!important;
}

#side_info #czDailyTasks .cz-daily-progress > span{
    display:block!important;
    height:100%!important;
    margin:0!important;
    padding:0!important;
    border-radius:4px!important;
    background:linear-gradient(90deg,#0a684d,#0b7b56)!important;
}

/* زر عرض المهمات */
#side_info #czDailyTasks .cz-daily-button{
    width:100%!important;
    height:32px!important;
    min-height:32px!important;
    margin:0!important;
    padding:0 10px!important;
    box-sizing:border-box!important;

    display:flex!important;
    align-items:center!important;
    justify-content:center!important;

    border:1px solid #d2a431!important;
    border-radius:7px!important;
    background:linear-gradient(180deg,#0a6349 0%,#07523d 100%)!important;
    color:#f4ce59!important;

    font-family:Tahoma,Arial,sans-serif!important;
    font-size:11px!important;
    line-height:30px!important;
    font-weight:700!important;
    text-align:center!important;
    cursor:pointer!important;
    box-shadow:0 3px 8px rgba(31,61,47,.12)!important;
}

#side_info #czDailyTasks .cz-daily-button:hover{
    background:linear-gradient(180deg,#0c7052 0%,#075b43 100%)!important;
    color:#ffe68a!important;
}

/* صفحة الترتيب عمودها 185px */
body.cz-ranking-body #mid:has(> #content.statistics) > #side_info #czDailyTasks.cz-daily-card{
    width:185px!important;
    max-width:185px!important;
}

/* الشاشات الضيقة القديمة */
@media(max-width:1120px){
    #side_info #czDailyTasks.cz-daily-card{
        max-width:100%!important;
    }
}


/* =========================================================
   CITYZERO STEP 14 — DAILY QUEST DATABASE UI
   ========================================================= */
#side_info #czDailyTasks .cz-daily-list{
    width:100%!important;
    margin:0 0 10px!important;
    padding:0!important;
}
#side_info #czDailyTasks .cz-daily-quest{
    min-height:36px!important;
    padding:5px 7px!important;
    margin:0 0 5px!important;
    box-sizing:border-box!important;
    display:flex!important;
    align-items:center!important;
    justify-content:space-between!important;
    gap:6px!important;
    border:1px solid #e8dcc4!important;
    border-radius:8px!important;
    background:#fffdf8!important;
}
#side_info #czDailyTasks .cz-daily-quest-main{
    min-width:0!important;
    flex:1!important;
}
#side_info #czDailyTasks .cz-daily-quest-main strong{
    display:block!important;
    color:#244033!important;
    font-size:9.5px!important;
    line-height:14px!important;
    font-weight:700!important;
}
#side_info #czDailyTasks .cz-daily-quest-main small{
    display:block!important;
    margin-top:2px!important;
    color:#897d69!important;
    font-size:8.5px!important;
}
#side_info #czDailyTasks .cz-daily-check{
    width:18px!important;
    min-width:18px!important;
    height:18px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    border-radius:50%!important;
    background:#eee4d0!important;
    color:#9b895e!important;
    font-size:11px!important;
    font-weight:700!important;
}
#side_info #czDailyTasks .cz-daily-quest.is-done{
    border-color:#c8d8bd!important;
    background:#f4f8ef!important;
}
#side_info #czDailyTasks .cz-daily-quest.is-done .cz-daily-check{
    background:#1e8559!important;
    color:#fff!important;
}
#side_info #czDailyTasks .cz-daily-message{
    margin:0 0 9px!important;
    padding:6px 7px!important;
    border:1px solid #dccb9f!important;
    border-radius:7px!important;
    background:#fff5d8!important;
    color:#705817!important;
    font-size:8.5px!important;
    line-height:14px!important;
}
#side_info #czDailyTasks .cz-daily-form{
    margin:0!important;
    padding:0!important;
    width:100%!important;
}
#side_info #czDailyTasks .cz-daily-button.is-disabled,
#side_info #czDailyTasks .cz-daily-button.is-claimed{
    cursor:default!important;
    opacity:.72!important;
}
#side_info #czDailyTasks .cz-daily-button.is-claimed{
    background:#6b766f!important;
    border-color:#8f968f!important;
    color:#fff!important;
}


/* =========================================================
   CITYZERO STEP 18 — DAILY QUEST CHEST IMAGE
   Uses: /game/img/daily_quest_chest.jpg
   ========================================================= */

#side_info #czDailyTasks.cz-daily-card{
    overflow:hidden!important;
}

#side_info #czDailyTasks .cz-daily-art-slot{
    position:relative!important;
    width:100%!important;
    height:112px!important;
    margin:0 0 10px!important;
    padding:0!important;
    overflow:hidden!important;
    box-sizing:border-box!important;

    border:1px solid #d8c59e!important;
    border-radius:10px!important;
    background:#17160f!important;
    box-shadow:inset 0 0 0 1px rgba(255,255,255,.04)!important;
}

#side_info #czDailyTasks .cz-daily-chest-img{
    display:block!important;
    width:100%!important;
    height:100%!important;
    margin:0!important;
    padding:0!important;
    object-fit:cover!important;
    object-position:center 42%!important;
    border:0!important;
    border-radius:9px!important;
}

/* نخفي شريط النص الموجود داخل الصورة جزئياً حتى ما يتكرر العنوان */
#side_info #czDailyTasks .cz-daily-art-slot:after{
    content:""!important;
    position:absolute!important;
    left:0!important;
    right:0!important;
    bottom:0!important;
    height:25px!important;
    background:linear-gradient(180deg,rgba(23,22,15,0),#17160f 78%)!important;
    pointer-events:none!important;
}

/* الزر أقرب للتصميم المرجعي */
#side_info #czDailyTasks .cz-daily-button{
    height:34px!important;
    min-height:34px!important;
    border-radius:8px!important;
    font-size:11px!important;
    background:linear-gradient(180deg,#0a684d 0%,#07523d 100%)!important;
    border:1px solid #d2a431!important;
    color:#f5d367!important;
    box-shadow:0 3px 8px rgba(31,61,47,.14)!important;
}

#side_info #czDailyTasks .cz-daily-button:hover{
    background:linear-gradient(180deg,#0c7657 0%,#075c43 100%)!important;
    color:#ffe58b!important;
}

#side_info #czDailyTasks .cz-daily-button.is-disabled{
    background:#7c817b!important;
    border-color:#9a9c97!important;
    color:#f4f1e8!important;
    opacity:.72!important;
}

#side_info #czDailyTasks .cz-daily-button.is-claimed{
    background:#5f6c64!important;
    border-color:#8b918d!important;
    color:#fff!important;
}

/* صفحة الترتيب */
body.cz-ranking-body #mid:has(> #content.statistics) > #side_info #czDailyTasks .cz-daily-art-slot{
    height:104px!important;
}


/* =========================================================
   CITYZERO STEP 19 — DAILY CHEST SIZE ONLY
   قياسات فقط، بدون أي تعديل على المكافآت أو الموارد
   ========================================================= */

#side_info #czDailyTasks.cz-daily-card{
    padding:12px!important;
}

#side_info #czDailyTasks .cz-daily-art-slot{
    height:138px!important;
    margin:4px 0 10px!important;
    border-radius:11px!important;
}

#side_info #czDailyTasks .cz-daily-chest-img{
    width:100%!important;
    height:100%!important;
    object-fit:cover!important;
    object-position:center 39%!important;
    border-radius:10px!important;
}

/* تقليل الجزء المظلم أسفل الصورة حتى يبقى الصندوق أوضح */
#side_info #czDailyTasks .cz-daily-art-slot:after{
    height:18px!important;
}

/* ضبط عناصر المهمات حتى يبقى الكرت متناسق بعد تكبير الصورة */
#side_info #czDailyTasks .cz-daily-list{
    margin-top:5px!important;
}

#side_info #czDailyTasks .cz-daily-row{
    min-height:31px!important;
}

#side_info #czDailyTasks .cz-daily-progress{
    margin-top:7px!important;
}

#side_info #czDailyTasks .cz-daily-button{
    margin-top:7px!important;
    height:34px!important;
    min-height:34px!important;
}

/* صفحة الترتيب: نفس المظهر بدون اختلاف واضح بالحجم */
body.cz-ranking-body #mid:has(> #content.statistics) > #side_info #czDailyTasks .cz-daily-art-slot{
    height:132px!important;
}


/* =========================================================
   CITYZERO STEP 20D — HERO AVATAR ON STABLE STEP19 CSS
   فقط صورة البطل، بدون لمس مدير المهام أو المهمات اليومية
   ========================================================= */

#side_navi.cz-side-menu-v8 .cz-profile-card .cz-profile-mark{
    width:58px!important;
    height:58px!important;
    min-width:58px!important;
    max-width:58px!important;
    flex:0 0 58px!important;

    margin:0!important;
    padding:0!important;
    overflow:hidden!important;

    background-color:#07563d!important;
    background-image:url("/game/img/cityzero_hero_avatar.jpg")!important;
    background-repeat:no-repeat!important;
    background-position:center center!important;
    background-size:cover!important;

    border:2px solid #d2a431!important;
    border-radius:50%!important;
    box-sizing:border-box!important;

    box-shadow:
        0 0 0 2px #07563d,
        0 4px 12px rgba(31,45,36,.20)!important;

    color:transparent!important;
    font-size:0!important;
    line-height:0!important;
    text-indent:-9999px!important;
}

/* إبقاء بطاقة المستخدم نفسها بارتفاعها الطبيعي */
#side_navi.cz-side-menu-v8 .cz-profile-card{
    align-items:center!important;
}


/* =========================================================
   CITYZERO STEP 21C — REAL TEMPLATE PROFILE LAYOUT
   ========================================================= */
#side_navi.cz-side-menu-v8 .cz-hero-profile-card{
    display:flex!important;
    flex-direction:column!important;
    align-items:center!important;
    justify-content:center!important;
    gap:8px!important;
    min-height:220px!important;
    padding:12px 10px!important;
    text-align:center!important;
    box-sizing:border-box!important;
}

#side_navi.cz-side-menu-v8 .cz-hero-profile-image{
    order:1!important;
    width:150px!important;
    height:150px!important;
    min-width:150px!important;
    max-width:150px!important;
    flex:0 0 150px!important;
    margin:0 auto!important;
    padding:0!important;
    background:#07563d url("/game/img/cityzero_hero_avatar.jpg") center/cover no-repeat!important;
    border:3px solid #d2a431!important;
    border-radius:18px!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
    box-shadow:0 0 0 2px #07563d,0 5px 12px rgba(31,45,36,.18)!important;
    color:transparent!important;
    font-size:0!important;
    line-height:0!important;
    text-indent:-9999px!important;
}

#side_navi.cz-side-menu-v8 .cz-hero-profile-copy{
    order:2!important;
    display:block!important;
    width:150px!important;
    margin:0 auto!important;
    padding:0!important;
    text-align:center!important;
}

#side_navi.cz-side-menu-v8 .cz-hero-profile-copy small{
    display:block!important;
    width:100%!important;
    box-sizing:border-box!important;
    margin:0!important;
    padding:7px 8px!important;
    background:#07563d!important;
    border:2px solid #d2a431!important;
    border-radius:9px!important;
    color:#f2c84b!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:17px!important;
    font-weight:900!important;
    line-height:1.25!important;
    text-align:center!important;
}

/* City Zero v14.53 — classic Travian ranking page, clearer Arabic type. */
body.cz-ranking-body #mid > #content.statistics.cz-ranking-page{
    width:700px!important;
    max-width:700px!important;
    padding:18px 20px 24px!important;
    background:#fdfbf5!important;
    border:1px solid #cdbd9d!important;
    border-radius:12px!important;
    font-family:Tahoma,Arial,sans-serif!important;
    color:#2f382f!important;
}
body.cz-ranking-body #content.statistics h1{
    margin-bottom:14px!important;
    padding-bottom:11px!important;
    font-size:25px!important;
    line-height:34px!important;
    color:#07563d!important;
}
body.cz-ranking-body #content.statistics .cz-ranking-tabs{
    gap:4px!important;
    margin-bottom:15px!important;
    padding:5px!important;
    border-color:#cdbd9d!important;
    border-radius:8px!important;
    background:#eee5d3!important;
}
body.cz-ranking-body #content.statistics .cz-ranking-tabs > a{
    min-height:42px!important;
    padding:5px 4px!important;
    border-radius:6px!important;
    background:linear-gradient(180deg,#fffdf7,#f4ead8)!important;
    color:#3b443b!important;
    font-size:12px!important;
    line-height:18px!important;
    opacity:1!important;
}
body.cz-ranking-body #content.statistics .cz-ranking-tabs > a.selected,
body.cz-ranking-body #content.statistics .cz-ranking-tabs > a.cz-current{
    background:linear-gradient(180deg,#14704f,#07563d)!important;
    color:#fff8dc!important;
}
body.cz-ranking-body #content.statistics .cz-rank-tab-icon{
    width:23px!important;
    height:23px!important;
    flex-basis:23px!important;
    font-size:12px!important;
}
body.cz-ranking-body #content.statistics .cz-top10-panel{
    margin-bottom:13px!important;
    border-color:#c7b58f!important;
    border-radius:8px!important;
    box-shadow:none!important;
}
body.cz-ranking-body #content.statistics .cz-top10-title{
    min-height:40px!important;
    background:linear-gradient(180deg,#1a6048,#0b4937)!important;
    color:#fff8dc!important;
    font-size:15px!important;
}
body.cz-ranking-body #content.statistics .cz-top10-primary{
    gap:5px!important;
    padding:7px!important;
    background:#eee5d3!important;
}
body.cz-ranking-body #content.statistics .cz-top10-tool{
    min-height:40px!important;
    padding:4px 6px!important;
    border-radius:6px!important;
    font-size:11px!important;
    color:#303d34!important;
}
body.cz-ranking-body #content.statistics .cz-top10-tribe-row{
    gap:6px!important;
    padding:7px!important;
}
body.cz-ranking-body #content.statistics .cz-top10-tribe{
    min-height:31px!important;
    font-size:11px!important;
}
body.cz-ranking-body #content.statistics table.row_table_data,
body.cz-ranking-body #content.statistics table.top10,
body.cz-ranking-body #content.statistics table[id^="top10_"]{
    border-color:#cbbb99!important;
    border-radius:7px!important;
    box-shadow:none!important;
}
body.cz-ranking-body #content.statistics table thead tr:first-child th{
    padding:10px 9px!important;
    background:linear-gradient(180deg,#176048,#0c4b38)!important;
    color:#fff!important;
    font-size:14px!important;
    line-height:20px!important;
    text-shadow:0 1px 0 rgba(0,0,0,.25)!important;
}
body.cz-ranking-body #content.statistics table thead tr:not(:first-child) td,
body.cz-ranking-body #content.statistics table thead tr:not(:first-child) th{
    padding:8px 7px!important;
    background:#e7dcc5!important;
    border-left:1px solid #cdbc9b!important;
    border-bottom:1px solid #c5b38f!important;
    color:#35433a!important;
    font-size:12px!important;
    line-height:18px!important;
    font-weight:700!important;
    text-shadow:none!important;
    opacity:1!important;
}
body.cz-ranking-body #content.statistics table tbody td,
body.cz-ranking-body #content.statistics table tbody th{
    height:36px!important;
    padding:7px 8px!important;
    background:#fffdf8!important;
    color:#28352e!important;
    font-size:12px!important;
    line-height:19px!important;
    font-weight:500!important;
    opacity:1!important;
}
body.cz-ranking-body #content.statistics table tbody tr:nth-child(even) td,
body.cz-ranking-body #content.statistics table tbody tr:nth-child(even) th{
    background:#f4eddf!important;
}
body.cz-ranking-body #content.statistics table tbody tr:hover td,
body.cz-ranking-body #content.statistics table tbody tr:hover th{
    background:#fff0bd!important;
}
body.cz-ranking-body #content.statistics table a{
    color:#075b40!important;
    font-size:12px!important;
    font-weight:700!important;
}
body.cz-ranking-body #content.statistics td.ra,
body.cz-ranking-body #content.statistics td.val{
    font-weight:700!important;
}
/* Travian-style Top 10: four boards in a balanced two-column layout. */
body.cz-ranking-body #content.statistics .cz-top10-panel ~ table[id^="top10_"]{
    display:inline-table!important;
    width:49%!important;
    margin:0 0 12px 1%!important;
    vertical-align:top!important;
}
body.cz-ranking-body #content.statistics .cz-top10-panel ~ .clear{
    display:none!important;
}
body.cz-ranking-body #content.statistics .cz-rank-search{
    clear:both!important;
    margin-top:12px!important;
    border-color:#cbbb99!important;
    background:#f2eadc!important;
}
@media(max-width:900px){
    body.cz-ranking-body #mid > #content.statistics.cz-ranking-page{
        width:100%!important;
        max-width:100%!important;
    }
    body.cz-ranking-body #content.statistics .cz-top10-panel ~ table[id^="top10_"]{
        display:table!important;
        width:100%!important;
        margin:0 0 12px!important;
    }
}


/* =========================================================
   CITYZERO STEP 21E — REAL <img> HERO PROFILE
   menu.tpl + CSS
   ========================================================= */

#side_navi.cz-side-menu-v8 .cz-hero-profile-card{
    display:flex!important;
    flex-direction:column!important;
    align-items:center!important;
    justify-content:center!important;
    gap:9px!important;

    min-height:310px!important;
    padding:12px 8px!important;
    box-sizing:border-box!important;
    text-align:center!important;
}

/* العنصر الحقيقي للصورة */
#side_navi.cz-side-menu-v8 .cz-hero-profile-photo{
    display:block!important;

    width:200px!important;
    height:200px!important;
    min-width:200px!important;
    max-width:200px!important;

    margin:0 auto!important;
    padding:0!important;

    object-fit:cover!important;
    object-position:center!important;

    border:3px solid #d2a431!important;
    border-radius:14px!important;
    box-sizing:border-box!important;

    background:#07563d!important;

    box-shadow:
        0 0 0 2px #07563d,
        0 5px 14px rgba(31,45,36,.20)!important;
}

/* اسم اللاعب أسفل الصورة */
#side_navi.cz-side-menu-v8 .cz-hero-profile-copy{
    display:block!important;
    width:200px!important;
    margin:0 auto!important;
    padding:0!important;
    text-align:center!important;
}

#side_navi.cz-side-menu-v8 .cz-hero-profile-copy small{
    display:block!important;
    width:100%!important;
    margin:0!important;
    padding:8px 10px!important;
    box-sizing:border-box!important;

    background:#07563d!important;
    border:2px solid #d2a431!important;
    border-radius:9px!important;

    color:#f4ca4c!important;
    font-family:Tahoma,Arial,sans-serif!important;
    font-size:19px!important;
    font-weight:900!important;
    line-height:1.2!important;
    text-align:center!important;
}

/* إلغاء أي أثر قديم لدائرة ص داخل بطاقة البطل */
#side_navi.cz-side-menu-v8 .cz-hero-profile-card .cz-profile-mark{
    display:none!important;
}


/* =========================================================
   CITYZERO STEP 21F — PROFILE CARD ALIGNMENT FIX
   تصحيح خروج الصورة والاسم خارج الكرت الأبيض
   ========================================================= */

#side_navi.cz-side-menu-v8{
    overflow:visible!important;
}

/* الكرت نفسه يصير أعرض ويحتوي الصورة بالكامل */
#side_navi.cz-side-menu-v8 .cz-hero-profile-card{
    width:224px!important;
    max-width:224px!important;
    min-height:304px!important;

    margin:0 auto 14px!important;
    padding:10px!important;

    box-sizing:border-box!important;
    overflow:hidden!important;

    display:flex!important;
    flex-direction:column!important;
    align-items:center!important;
    justify-content:flex-start!important;
    gap:6px!important;
}

/* الصورة ضمن حدود الكرت */
#side_navi.cz-side-menu-v8 .cz-hero-profile-photo{
    width:198px!important;
    height:198px!important;
    min-width:198px!important;
    max-width:198px!important;

    margin:0 auto!important;
    box-sizing:border-box!important;
}

/* اسم اللاعب بنفس عرض الصورة */
#side_navi.cz-side-menu-v8 .cz-hero-profile-copy{
    width:198px!important;
    max-width:198px!important;
    margin:0 auto!important;
}

#side_navi.cz-side-menu-v8 .cz-hero-profile-copy small{
    width:100%!important;
    margin:0!important;
    padding:8px 10px!important;
    box-sizing:border-box!important;
}

/* توسيع العمود الأيمن حتى يبقى كل شيء بمحاذاة واحدة */
#mid > #side_navi.cz-side-menu-v8{
    width:224px!important;
    padding-left:0!important;
    padding-right:0!important;
}

/* بقية كروت القائمة تتبع نفس العرض */
#side_navi.cz-side-menu-v8 .cz-side-card{
    width:224px!important;
    max-width:224px!important;
    margin-left:auto!important;
    margin-right:auto!important;
    box-sizing:border-box!important;
}


/* =========================================================
   CITYZERO STEP 21G — PROFILE CARD MATCH REFERENCE
   تصغير الصورة والشريط داخل المربع الأبيض
   ========================================================= */

#mid > #side_navi.cz-side-menu-v8{
    width:196px!important;
    padding-left:0!important;
    padding-right:0!important;
}

#side_navi.cz-side-menu-v8 .cz-hero-profile-card{
    width:196px!important;
    max-width:196px!important;
    min-height:226px!important;

    margin:0 auto 14px!important;
    padding:10px 10px 11px!important;

    display:flex!important;
    flex-direction:column!important;
    align-items:center!important;
    justify-content:flex-start!important;
    gap:7px!important;

    box-sizing:border-box!important;
    overflow:hidden!important;
}

/* الصورة أصغر وتبقى كاملة داخل الكرت */
#side_navi.cz-side-menu-v8 .cz-hero-profile-photo{
    display:block!important;

    width:172px!important;
    height:172px!important;
    min-width:172px!important;
    max-width:172px!important;

    margin:0 auto!important;
    padding:0!important;

    object-fit:cover!important;
    object-position:center!important;

    border:2px solid #d2a431!important;
    border-radius:10px!important;
    box-sizing:border-box!important;

    box-shadow:
        0 0 0 1px #07563d,
        0 3px 9px rgba(31,45,36,.16)!important;
}

/* شريط اسم اللاعب أصغر وداخل نفس حدود الكرت */
#side_navi.cz-side-menu-v8 .cz-hero-profile-copy{
    width:172px!important;
    max-width:172px!important;
    margin:0 auto!important;
    padding:0!important;
}

#side_navi.cz-side-menu-v8 .cz-hero-profile-copy small{
    width:100%!important;
    margin:0!important;
    padding:7px 8px!important;

    background:#07563d!important;
    border:1px solid #d2a431!important;
    border-radius:8px!important;

    color:#f4ca4c!important;
    font-size:18px!important;
    font-weight:900!important;
    line-height:1.2!important;
    text-align:center!important;
    box-sizing:border-box!important;
}

/* بقية كروت القائمة تبقى بمحاذاة نفس العمود */
#side_navi.cz-side-menu-v8 .cz-side-card{
    width:196px!important;
    max-width:196px!important;
    margin-left:auto!important;
    margin-right:auto!important;
    box-sizing:border-box!important;
}


/* =========================================================
   CITYZERO STEP 21H — TIGHTER PROFILE SPACING
   تقليل المسافات فقط بدون تغيير الشكل
   ========================================================= */

#side_navi.cz-side-menu-v8 .cz-hero-profile-card{
    width:196px!important;
    max-width:196px!important;
    min-height:0!important;
    height:auto!important;

    padding:7px 9px 8px!important;
    gap:4px!important;
    margin:0 auto 11px!important;
}

/* تصغير بسيط جداً حتى يبقى هامش متساوي حول الصورة */
#side_navi.cz-side-menu-v8 .cz-hero-profile-photo{
    width:168px!important;
    height:168px!important;
    min-width:168px!important;
    max-width:168px!important;
    margin:0 auto!important;
}

/* الشريط بنفس عرض الصورة وأقرب إلها */
#side_navi.cz-side-menu-v8 .cz-hero-profile-copy{
    width:168px!important;
    max-width:168px!important;
    margin:0 auto!important;
}

#side_navi.cz-side-menu-v8 .cz-hero-profile-copy small{
    padding:6px 8px!important;
    font-size:18px!important;
    line-height:1.15!important;
}

/* تقليل الفراغ بين بطاقة البطل والقائمة التالية */
#side_navi.cz-side-menu-v8 .cz-hero-profile-card + .cz-side-card{
    margin-top:0!important;
}


/* =========================================================
   CITYZERO STEP 21I — REMOVE PROFILE INNER GAPS
   إزالة الفراغات الظاهرة داخل بطاقة البطل
   ========================================================= */

#side_navi.cz-side-menu-v8 .cz-hero-profile-card{
    width:196px!important;
    max-width:196px!important;
    min-height:0!important;
    height:auto!important;

    margin:0 auto 12px!important;
    padding:5px!important;
    gap:3px!important;

    display:flex!important;
    flex-direction:column!important;
    align-items:center!important;
    justify-content:flex-start!important;

    box-sizing:border-box!important;
    overflow:hidden!important;
}

/* الصورة تملأ عرض البطاقة تقريباً مع هامش 5px فقط */
#side_navi.cz-side-menu-v8 .cz-hero-profile-photo{
    display:block!important;
    width:184px!important;
    height:184px!important;
    min-width:184px!important;
    max-width:184px!important;

    margin:0!important;
    padding:0!important;

    object-fit:cover!important;
    object-position:center!important;

    border:2px solid #d2a431!important;
    border-radius:9px!important;
    box-sizing:border-box!important;
}

/* شريط الاسم ملاصق تقريباً للصورة وبنفس العرض */
#side_navi.cz-side-menu-v8 .cz-hero-profile-copy{
    display:block!important;
    width:184px!important;
    max-width:184px!important;
    margin:0!important;
    padding:0!important;
}

#side_navi.cz-side-menu-v8 .cz-hero-profile-copy small{
    display:block!important;
    width:184px!important;
    margin:0!important;
    padding:6px 8px!important;

    box-sizing:border-box!important;
    border-radius:8px!important;

    font-size:18px!important;
    font-weight:900!important;
    line-height:1.15!important;
    text-align:center!important;
}

/* منع أي قواعد قديمة من إضافة فراغات للصورة أو النص */
#side_navi.cz-side-menu-v8 .cz-hero-profile-card > *{
    margin-left:0!important;
    margin-right:0!important;
}


/* =========================================================
   CITYZERO STEP 24B — GLOBAL BACKGROUND REAL FIX
   السبب الحقيقي: .wrapper كانت تغطي خلفية body بلون صلب
   ========================================================= */

html{
    min-height:100%!important;
    background:#dfe9e1 url('/game/img/cityzero_bg.jpg?v=24b') center center / cover fixed no-repeat!important;
}

body{
    min-height:100vh!important;
    background:transparent!important;
}

/* هذه الطبقة كانت تحجب صورة الخلفية بالكامل */
.wrapper,
body > .wrapper{
    background:transparent!important;
    background-color:transparent!important;
    background-image:none!important;
}

/* مساحة اللعبة الرئيسية تبقى شفافة بين الكروت */
#mid{
    background:transparent!important;
}

/* أي أغلفة عامة قديمة نجعلها شفافة، بدون لمس الكروت نفسها */
#background,
#body,
#contentWrapper,
#contentContainer,
#page,
#main{
    background-color:transparent!important;
}

/* تثبيت الخلفية حتى لا تتحرك مع الصفحة */
html:before{
    content:""!important;
    position:fixed!important;
    inset:0!important;
    z-index:-9999!important;
    pointer-events:none!important;
    background:url('/game/img/cityzero_bg.jpg?v=24b') center center / cover no-repeat!important;
}

/* نتأكد أن الصفحة لا ترسم لوناً صلباً فوق الخلفية */
body,
.wrapper{
    background-attachment:fixed!important;
}


/* =========================================================
   CITYZERO STEP 25 — HEADER OFFICIAL LOGO
   استبدال كتابة مدينة الصفر والعلامة القديمة باللوغو
   ========================================================= */

#header.cz-header-v8 .cz-top-brand{
    width:195px!important;
    min-width:195px!important;
    height:92px!important;
    padding:0!important;
    margin:0!important;
    display:block!important;
    position:relative!important;
    overflow:visible!important;
    background:transparent url('/game/img/cityzero_logo.jpg?v=25') center center / contain no-repeat!important;
}

/* إخفاء النص والعلامة القديمة فقط، مع إبقاء مكان الهيدر نفسه */
#header.cz-header-v8 .cz-top-brand .cz-top-brand-mark,
#header.cz-header-v8 .cz-top-brand .cz-top-brand-copy{
    display:none!important;
}

/* اللوغو يبقى داخل الهيدر بدون التأثير على القوائم */
#header.cz-header-v8 .cz-header-inner{
    overflow:visible!important;
}


/* =========================================================
   CITYZERO STEP 26 — TRANSPARENT HEADER LOGO
   ========================================================= */

#header.cz-header-v8 .cz-top-brand{
    width:230px!important;
    min-width:230px!important;
    height:105px!important;
    padding:0!important;
    margin:0!important;
    background:transparent url('/game/img/cityzero_logo.png?v=26') center center / contain no-repeat!important;
}

#header.cz-header-v8 .cz-top-brand .cz-top-brand-mark,
#header.cz-header-v8 .cz-top-brand .cz-top-brand-copy{
    display:none!important;
}


/* =========================================================
   CITYZERO STEP 27 — LOGO LARGER + LEFT
   تكبير اللوغو وتحريكه لليسار فقط
   ========================================================= */

#header.cz-header-v8 .cz-top-brand{
    width:285px!important;
    min-width:285px!important;
    height:112px!important;
    position:absolute!important;
    left:55px!important;
    right:auto!important;
    top:2px!important;
    margin:0!important;
    padding:0!important;
    background:transparent url('/game/img/cityzero_logo.png?v=27') center center / contain no-repeat!important;
    z-index:20!important;
}

/* مساحة الهيدر للّوغو الجديد بدون تغيير بقية العناصر */
#header.cz-header-v8 .cz-header-inner{
    position:relative!important;
    overflow:visible!important;
}

#header.cz-header-v8 .cz-top-brand .cz-top-brand-mark,
#header.cz-header-v8 .cz-top-brand .cz-top-brand-copy{
    display:none!important;
}

@media (max-width:1100px){
    #header.cz-header-v8 .cz-top-brand{
        width:235px!important;
        min-width:235px!important;
        height:100px!important;
        left:18px!important;
    }
}


/* =========================================================
   CITYZERO STEP 28 — BIG LEFT LOGO / NAV POSITION FIX
   ========================================================= */

/* اللوغو كبير ويسار، ولا يحجز أي مساحة من شريط الأيقونات */
#header.cz-header-v8 .cz-top-brand{
    position:absolute!important;
    left:145px!important;
    right:auto!important;
    top:3px!important;
    width:330px!important;
    min-width:0!important;
    max-width:none!important;
    height:108px!important;
    margin:0!important;
    padding:0!important;
    flex:none!important;
    background:transparent url('/game/img/cityzero_logo.png?v=28') center center / contain no-repeat!important;
    z-index:30!important;
    pointer-events:auto!important;
}

/* إخفاء محتوى البراند القديم */
#header.cz-header-v8 .cz-top-brand .cz-top-brand-mark,
#header.cz-header-v8 .cz-top-brand .cz-top-brand-copy{
    display:none!important;
}

/* إرجاع الهيدر لتوزيع الأيقونات الطبيعي */
#header.cz-header-v8 .cz-header-inner{
    position:relative!important;
    overflow:visible!important;
}

/* مهم: اللوغو المطلق لا يدخل بحساب توزيع القائمة */
#header.cz-header-v8 .cz-top-nav{
    margin-left:auto!important;
    margin-right:auto!important;
    transform:none!important;
    position:relative!important;
    left:auto!important;
    right:auto!important;
}

/* عدم السماح لتعديل STEP27 بدفع عناصر القائمة */
#header.cz-header-v8 .cz-header-inner > .cz-top-brand{
    flex-basis:0!important;
}

/* شاشات أصغر */
@media (max-width:1300px){
    #header.cz-header-v8 .cz-top-brand{
        left:55px!important;
        width:285px!important;
        height:104px!important;
    }
}

@media (max-width:1050px){
    #header.cz-header-v8 .cz-top-brand{
        left:12px!important;
        width:220px!important;
        height:96px!important;
    }
}


/* =========================================================
   CITYZERO STEP 29 — HEADER GRID FIX
   تكبير اللوغو + تثبيت الأيقونات بدون تداخل
   ========================================================= */

/* نلغي التموضع المطلق القديم لأنه هو الذي كان يخرب توزيع الأيقونات */
#header.cz-header-v8 .cz-header-inner{
    width:1420px!important;
    max-width:calc(100% - 36px)!important;
    height:104px!important;
    margin:0 auto!important;
    display:grid!important;
    grid-template-columns:330px 135px minmax(650px,1fr)!important;
    column-gap:18px!important;
    align-items:center!important;
    direction:ltr!important;
    position:relative!important;
    overflow:visible!important;
    box-sizing:border-box!important;
}

/* اللوغو: كبير وثابت في أقصى اليسار ضمن الهيدر */
#header.cz-header-v8 .cz-top-brand{
    grid-column:1!important;
    position:relative!important;
    left:auto!important;
    right:auto!important;
    top:auto!important;
    width:330px!important;
    min-width:330px!important;
    max-width:330px!important;
    height:100px!important;
    margin:0!important;
    padding:0!important;
    align-self:center!important;
    justify-self:start!important;
    background:transparent url('/game/img/cityzero_logo.png?v=29') left center / contain no-repeat!important;
    z-index:2!important;
}

#header.cz-header-v8 .cz-top-brand .cz-top-brand-mark,
#header.cz-header-v8 .cz-top-brand .cz-top-brand-copy{
    display:none!important;
}

/* وقت السيرفر يكون مباشرة بعد اللوغو */
#header.cz-header-v8 .cz-server-status{
    grid-column:2!important;
    position:relative!important;
    left:auto!important;
    right:auto!important;
    top:auto!important;
    width:135px!important;
    min-width:135px!important;
    max-width:135px!important;
    margin:0!important;
    justify-self:center!important;
    align-self:center!important;
    direction:rtl!important;
    text-align:center!important;
}

/* شريط الأيقونات له عمود مستقل كامل؛ لا يتأثر بحجم اللوغو */
#header.cz-header-v8 #mtop.cz-topnav-v8{
    grid-column:3!important;
    position:relative!important;
    left:auto!important;
    right:auto!important;
    top:auto!important;
    width:100%!important;
    min-width:650px!important;
    max-width:none!important;
    margin:0!important;
    padding:0!important;
    display:flex!important;
    flex-wrap:nowrap!important;
    align-items:center!important;
    justify-content:flex-end!important;
    gap:4px!important;
    direction:rtl!important;
    transform:none!important;
    overflow:visible!important;
}

#header.cz-header-v8 #mtop.cz-topnav-v8 .cz-nav-item,
#header.cz-header-v8 #mtop.cz-topnav-v8 #n5.cz-nav-split>a{
    flex:0 0 82px!important;
    width:82px!important;
    min-width:82px!important;
    max-width:82px!important;
    height:68px!important;
    margin:0!important;
    padding:7px 4px!important;
    box-sizing:border-box!important;
}

/* يمنع n5 من أخذ مساحة أو محاذاة غير طبيعية */
#header.cz-header-v8 #mtop.cz-topnav-v8 #n5.cz-nav-split{
    display:flex!important;
    flex:0 0 auto!important;
    width:auto!important;
    min-width:0!important;
    margin:0!important;
    padding:0!important;
    gap:4px!important;
}

@media (max-width:1350px){
    #header.cz-header-v8 .cz-header-inner{
        width:1220px!important;
        grid-template-columns:285px 120px minmax(600px,1fr)!important;
        column-gap:12px!important;
    }
    #header.cz-header-v8 .cz-top-brand{
        width:285px!important;
        min-width:285px!important;
        max-width:285px!important;
        height:96px!important;
    }
    #header.cz-header-v8 .cz-server-status{
        width:120px!important;
        min-width:120px!important;
        max-width:120px!important;
    }
    #header.cz-header-v8 #mtop.cz-topnav-v8 .cz-nav-item,
    #header.cz-header-v8 #mtop.cz-topnav-v8 #n5.cz-nav-split>a{
        flex-basis:78px!important;
        width:78px!important;
        min-width:78px!important;
        max-width:78px!important;
    }
}

/* CITYZERO STEP30 — logo larger + server time fixed */
#header.cz-header-v8 .cz-header-inner{height:112px!important;min-height:112px!important;display:flex!important;align-items:center!important;position:relative!important;direction:ltr!important;}
#header.cz-header-v8 .cz-top-brand{position:absolute!important;left:115px!important;right:auto!important;top:2px!important;width:380px!important;height:106px!important;min-width:380px!important;max-width:380px!important;margin:0!important;background:transparent url('/game/img/cityzero_logo.png?v=30') left center/contain no-repeat!important;}
#header.cz-header-v8 .cz-server-status{position:absolute!important;left:505px!important;right:auto!important;top:24px!important;width:145px!important;height:64px!important;margin:0!important;z-index:20!important;display:flex!important;flex-direction:column!important;align-items:center!important;justify-content:center!important;}
#header.cz-header-v8 #mtop.cz-topnav-v8{position:absolute!important;right:20px!important;left:auto!important;top:10px!important;height:92px!important;width:auto!important;min-width:0!important;margin:0!important;display:flex!important;flex-wrap:nowrap!important;align-items:center!important;justify-content:flex-end!important;gap:3px!important;direction:rtl!important;}
.cz-resourcebar-v8{position:relative!important;clear:both!important;z-index:15!important;}


/* =========================================================
   CITYZERO STEP 31 — VILLAGE NAV IMAGE ICON
   ========================================================= */

/* استبدال أيقونة القرية فقط بالصورة الجديدة */
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="dorf2.php"] .cz-nav-icon,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href="dorf2.php"] .cz-nav-icon{
    width:42px!important;
    height:42px!important;
    min-width:42px!important;
    display:block!important;
    margin:0 auto 2px!important;
    background:url('../../../img/cityzero_nav_village.png?v=44') center center / cover no-repeat!important;
    border:2px solid #d6a51d!important;
    border-radius:9px!important;
    box-sizing:border-box!important;
    font-size:0!important;
    line-height:0!important;
    overflow:hidden!important;
}

/* إخفاء رمز البيت القديم داخل أيقونة القرية فقط */
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="dorf2.php"] .cz-nav-icon::before,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="dorf2.php"] .cz-nav-icon::after{
    content:none!important;
    display:none!important;
}

/* إذا كان الرمز القديم صورة مباشرة داخل زر القرية */
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="dorf2.php"] > img{
    display:none!important;
}


/* CITYZERO STEP 32 — transparent PNG village icon */
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="dorf2.php"] .cz-nav-icon,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href="dorf2.php"] .cz-nav-icon{
    background-image:url('../../../img/cityzero_nav_village.png?v=44')!important;
    background-size:contain!important;
    background-position:center!important;
    background-repeat:no-repeat!important;
    background-color:transparent!important;
    border:0!important;
}


/* =========================================================
   CITYZERO STEP 33 — VILLAGE TOP ICON ONLY
   فقط أيقونة القرية في الهيدر
   ========================================================= */

/* تكبير صورة أيقونة القرية الشفافة */
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="dorf2.php"] .cz-nav-icon,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href="dorf2.php"] .cz-nav-icon{
    width:58px!important;
    height:58px!important;
    min-width:58px!important;
    max-width:58px!important;
    margin:0 auto!important;
    background:url('../../../img/cityzero_nav_village.png?v=44') center center / contain no-repeat!important;
    background-color:transparent!important;
    border:0!important;
    border-radius:0!important;
}

/* حذف كلمة القرية الموجودة تحت الأيقونة فقط */
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="dorf2.php"] .cz-nav-label,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href="dorf2.php"] .cz-nav-label{
    display:none!important;
}

/* إبقاء زر القرية مضبوط بعد حذف النص */
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="dorf2.php"],
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href="dorf2.php"]{
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    padding:4px!important;
}


/* =========================================================
   CITYZERO STEP 34 — TOP VILLAGE ICON ONLY
   80x80 + remove village text
   ========================================================= */

#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="dorf2.php"] .cz-nav-icon,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href="dorf2.php"] .cz-nav-icon{
    width:80px!important;
    height:80px!important;
    min-width:80px!important;
    max-width:80px!important;
    margin:0 auto!important;
    background:url('../../../img/cityzero_nav_village.png?v=44') center center / contain no-repeat!important;
    background-color:transparent!important;
    border:0!important;
    border-radius:0!important;
}

/* hide every text element inside the village nav button, keep only icon */
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="dorf2.php"] .cz-nav-label,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="dorf2.php"] .label,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="dorf2.php"] .text,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="dorf2.php"] span:not(.cz-nav-icon){
    display:none!important;
}

/* button sized for 80x80 icon */
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="dorf2.php"],
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href="dorf2.php"]{
    height:88px!important;
    min-height:88px!important;
    padding:4px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    overflow:visible!important;
    font-size:0!important;
    line-height:0!important;
}


/* CITYZERO STEP 35 — village top icon 100x100 only */
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="dorf2.php"] .cz-nav-icon,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href="dorf2.php"] .cz-nav-icon{
    width:100px!important;
    height:100px!important;
    min-width:100px!important;
    max-width:100px!important;
    background-size:contain!important;
}

/* enough room for the 100x100 icon */
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="dorf2.php"],
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href="dorf2.php"]{
    height:108px!important;
    min-height:108px!important;
    padding:4px!important;
}

/* village text remains hidden */
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="dorf2.php"] .cz-nav-label,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="dorf2.php"] .label,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="dorf2.php"] .text,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="dorf2.php"] span:not(.cz-nav-icon){
    display:none!important;
}


/* =========================================================
   CITYZERO STEP 36 — RESOURCES TOP ICON ONLY
   PNG 100x100 + hide old Resources text
   ========================================================= */

#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="dorf1.php"] .cz-nav-icon,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href="dorf1.php"] .cz-nav-icon{
    width:100px!important;
    height:100px!important;
    min-width:100px!important;
    max-width:100px!important;
    margin:0 auto!important;
    background:url('../../../img/cityzero_nav_resources.png?v=44') center center / contain no-repeat!important;
    background-color:transparent!important;
    border:0!important;
    border-radius:0!important;
    font-size:0!important;
    line-height:0!important;
}

/* حذف كلمة الموارد القديمة لأن الكلمة موجودة داخل صورة الأيقونة */
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="dorf1.php"] .cz-nav-label,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="dorf1.php"] .label,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="dorf1.php"] .text,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="dorf1.php"] span:not(.cz-nav-icon){
    display:none!important;
}

#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="dorf1.php"],
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href="dorf1.php"]{
    height:108px!important;
    min-height:108px!important;
    padding:4px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    overflow:visible!important;
    font-size:0!important;
    line-height:0!important;
}


/* =========================================================
   CITYZERO STEP 37 — MAP TOP ICON ONLY
   PNG 100x100 + hide old map text
   ========================================================= */

#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="karte.php"] .cz-nav-icon,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href="karte.php"] .cz-nav-icon{
    width:100px!important;
    height:100px!important;
    min-width:100px!important;
    max-width:100px!important;
    margin:0 auto!important;
    background:url('../../../img/cityzero_nav_map.png?v=44') center center / contain no-repeat!important;
    background-color:transparent!important;
    border:0!important;
    border-radius:0!important;
    font-size:0!important;
    line-height:0!important;
}

/* حذف كلمة الخريطة القديمة لأن الكلمة موجودة داخل الصورة */
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="karte.php"] .cz-nav-label,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="karte.php"] .label,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="karte.php"] .text,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="karte.php"] span:not(.cz-nav-icon){
    display:none!important;
}

#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="karte.php"],
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href="karte.php"]{
    height:108px!important;
    min-height:108px!important;
    padding:4px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    overflow:visible!important;
    font-size:0!important;
    line-height:0!important;
}


/* =========================================================
   CITYZERO STEP 38 — RANKING TOP ICON ONLY
   PNG 100x100 + hide old ranking text
   ========================================================= */

#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="statistiken.php"] .cz-nav-icon,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href="statistiken.php"] .cz-nav-icon{
    width:100px!important;
    height:100px!important;
    min-width:100px!important;
    max-width:100px!important;
    margin:0 auto!important;
    background:url('../../../img/cityzero_nav_ranking.png?v=44') center center / contain no-repeat!important;
    background-color:transparent!important;
    border:0!important;
    border-radius:0!important;
    font-size:0!important;
    line-height:0!important;
}

/* حذف كلمة الترتيب القديمة لأن الكلمة موجودة داخل الصورة */
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="statistiken.php"] .cz-nav-label,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="statistiken.php"] .label,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="statistiken.php"] .text,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="statistiken.php"] span:not(.cz-nav-icon){
    display:none!important;
}

#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="statistiken.php"],
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href="statistiken.php"]{
    height:108px!important;
    min-height:108px!important;
    padding:4px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    overflow:visible!important;
    font-size:0!important;
    line-height:0!important;
}


/* =========================================================
   CITYZERO STEP 39 — REPORTS TOP ICON ONLY
   PNG 100x100 + hide old reports text
   ========================================================= */

#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="berichte.php"] .cz-nav-icon,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href="berichte.php"] .cz-nav-icon{
    width:100px!important;
    height:100px!important;
    min-width:100px!important;
    max-width:100px!important;
    margin:0 auto!important;
    background:url('../../../img/cityzero_nav_reports.png?v=44') center center / contain no-repeat!important;
    background-color:transparent!important;
    border:0!important;
    border-radius:0!important;
    font-size:0!important;
    line-height:0!important;
}

/* حذف كلمة التقارير القديمة لأن الكلمة موجودة داخل الصورة */
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="berichte.php"] .cz-nav-label,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="berichte.php"] .label,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="berichte.php"] .text,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="berichte.php"] span:not(.cz-nav-icon){
    display:none!important;
}

#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="berichte.php"],
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href="berichte.php"]{
    height:108px!important;
    min-height:108px!important;
    padding:4px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    overflow:visible!important;
    font-size:0!important;
    line-height:0!important;
}


/* =========================================================
   CITYZERO STEP 40 — MESSAGES TOP ICON ONLY
   PNG 100x100 + hide old messages text
   ========================================================= */

#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="nachrichten.php"] .cz-nav-icon,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href="nachrichten.php"] .cz-nav-icon{
    width:100px!important;
    height:100px!important;
    min-width:100px!important;
    max-width:100px!important;
    margin:0 auto!important;
    background:url('../../../img/cityzero_nav_messages.png?v=44') center center / contain no-repeat!important;
    background-color:transparent!important;
    border:0!important;
    border-radius:0!important;
    font-size:0!important;
    line-height:0!important;
}

/* حذف كلمة الرسائل القديمة لأن الكلمة موجودة داخل الصورة */
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="nachrichten.php"] .cz-nav-label,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="nachrichten.php"] .label,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="nachrichten.php"] .text,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="nachrichten.php"] span:not(.cz-nav-icon){
    display:none!important;
}

#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="nachrichten.php"],
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href="nachrichten.php"]{
    height:108px!important;
    min-height:108px!important;
    padding:4px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    overflow:visible!important;
    font-size:0!important;
    line-height:0!important;
}


/* =========================================================
   CITYZERO STEP 41 — FEATURES / المزايا TOP ICON ONLY
   PNG 100x100 + hide old text
   ========================================================= */

/* زر المزايا في الهيدر */
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="plus.php"] .cz-nav-icon,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href="plus.php"] .cz-nav-icon{
    width:100px!important;
    height:100px!important;
    min-width:100px!important;
    max-width:100px!important;
    margin:0 auto!important;
    background:url('../../../img/cityzero_nav_features.png?v=44') center center / contain no-repeat!important;
    background-color:transparent!important;
    border:0!important;
    border-radius:0!important;
    font-size:0!important;
    line-height:0!important;
}

/* حذف كلمة المزايا القديمة لأن الكلمة موجودة داخل الصورة */
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="plus.php"] .cz-nav-label,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="plus.php"] .label,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="plus.php"] .text,
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="plus.php"] span:not(.cz-nav-icon){
    display:none!important;
}

#header.cz-header-v8 #mtop.cz-topnav-v8 a[href*="plus.php"],
#header.cz-header-v8 #mtop.cz-topnav-v8 a[href="plus.php"]{
    height:108px!important;
    min-height:108px!important;
    padding:4px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    overflow:visible!important;
    font-size:0!important;
    line-height:0!important;
}


/* =========================================================
   CITYZERO STEP 42 — HERO ADVENTURES TOP ICON
   مغامرات البطل بجانب المزايا — 100x100 PNG
   ========================================================= */

#header.cz-header-v8 #mtop.cz-topnav-v8 .cz-hero-adventures{
    width:108px!important;
    height:108px!important;
    min-width:108px!important;
    padding:4px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    box-sizing:border-box!important;
    text-decoration:none!important;
    overflow:visible!important;
}

#header.cz-header-v8 #mtop.cz-topnav-v8 .cz-hero-adventures .cz-nav-icon{
    width:100px!important;
    height:100px!important;
    min-width:100px!important;
    max-width:100px!important;
    margin:0 auto!important;
    background:url('../../../img/cityzero_nav_hero_adventures.png?v=44') center center / contain no-repeat!important;
    background-color:transparent!important;
    border:0!important;
    border-radius:0!important;
    font-size:0!important;
    line-height:0!important;
}

#header.cz-header-v8 #mtop.cz-topnav-v8 .cz-hero-adventures .cz-nav-label,
#header.cz-header-v8 #mtop.cz-topnav-v8 .cz-hero-adventures .label,
#header.cz-header-v8 #mtop.cz-topnav-v8 .cz-hero-adventures .text{
    display:none!important;
}


/* =========================================================
   CITYZERO STEP 43 — HERO ADVENTURES IN REAL HEADER
   130x130 PNG — beside Features
   ========================================================= */

#header.cz-header-v8{
    overflow:visible!important;
}

#header.cz-header-v8 .cz-header-inner{
    overflow:visible!important;
}

/* Give the top navigation enough horizontal room for the new button */
#header.cz-header-v8 #mtop.cz-topnav-v8{
    width:auto!important;
    min-width:900px!important;
    overflow:visible!important;
}

/* Hero Adventures button */
#header.cz-header-v8 #mtop.cz-topnav-v8 #hero_adventures.cz-hero-adventures{
    width:138px!important;
    min-width:138px!important;
    height:138px!important;
    min-height:138px!important;
    padding:4px!important;
    margin:0!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    box-sizing:border-box!important;
    overflow:visible!important;
    background:transparent!important;
    border:0!important;
    text-decoration:none!important;
}

/* Hero Adventures image — 130x130 */
#header.cz-header-v8 #mtop.cz-topnav-v8 #hero_adventures .cz-nav-icon{
    display:block!important;
    width:130px!important;
    height:130px!important;
    min-width:130px!important;
    min-height:130px!important;
    max-width:130px!important;
    max-height:130px!important;
    margin:0!important;
    padding:0!important;
    background:url('../../../img/cityzero_nav_hero_adventures.png?v=44') center center / contain no-repeat!important;
    background-color:transparent!important;
    border:0!important;
    border-radius:0!important;
    font-size:0!important;
    line-height:0!important;
}

/* No duplicate text: the title is inside the PNG */
#header.cz-header-v8 #mtop.cz-topnav-v8 #hero_adventures span:not(.cz-nav-icon){
    display:none!important;
}


/* =========================================================
   CITYZERO STEP 44
   ALL TOP ICONS 130x130
   REMOVE GREEN HEADER STRIP
   REMOVE SERVER TIME
   ========================================================= */

/* إزالة الشريط الأخضر بالكامل */
#header.cz-header-v8,
#header.cz-header{
    background:transparent!important;
    background-image:none!important;
    border:0!important;
    border-bottom:0!important;
    box-shadow:none!important;
    overflow:visible!important;
    height:148px!important;
    min-height:148px!important;
}

/* الهيدر نفسه يبقى فقط كحاوية للأيقونات واللوغو */
#header.cz-header-v8 .cz-header-inner,
#header.cz-header .cz-header-inner{
    background:transparent!important;
    border:0!important;
    box-shadow:none!important;
    height:148px!important;
    min-height:148px!important;
    overflow:visible!important;
}

/* حذف وقت السيرفر بالكامل */
#header.cz-header-v8 .cz-server-status,
#header.cz-header .cz-server-status,
.cz-server-status{
    display:none!important;
    visibility:hidden!important;
    width:0!important;
    height:0!important;
    overflow:hidden!important;
}

/* تكبير كل صور الأيقونات العلوية إلى 130x130 */
#header.cz-header-v8 #mtop.cz-topnav-v8 .cz-nav-icon,
#header.cz-header #mtop.cz-topnav .cz-nav-icon{
    width:130px!important;
    height:130px!important;
    min-width:130px!important;
    min-height:130px!important;
    max-width:130px!important;
    max-height:130px!important;
    margin:0!important;
    padding:0!important;
    background-size:contain!important;
    background-position:center center!important;
    background-repeat:no-repeat!important;
    background-color:transparent!important;
    border:0!important;
    border-radius:0!important;
}

/* كل زر يأخذ مساحة مناسبة للأيقونة الجديدة */
#header.cz-header-v8 #mtop.cz-topnav-v8 > a,
#header.cz-header-v8 #mtop.cz-topnav-v8 #n5 > a,
#header.cz-header-v8 #mtop.cz-topnav-v8 .cz-nav-item,
#header.cz-header-v8 #mtop.cz-topnav-v8 .cz-hero-adventures{
    width:138px!important;
    min-width:138px!important;
    max-width:138px!important;
    height:138px!important;
    min-height:138px!important;
    max-height:138px!important;
    padding:4px!important;
    margin:0 2px!important;
    box-sizing:border-box!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    background:transparent!important;
    border:0!important;
    box-shadow:none!important;
    overflow:visible!important;
}

/* القائمة نفسها بلا شريط أو خلفية */
#header.cz-header-v8 #mtop.cz-topnav-v8,
#header.cz-header #mtop.cz-topnav{
    background:transparent!important;
    background-image:none!important;
    border:0!important;
    box-shadow:none!important;
    height:148px!important;
    min-height:148px!important;
    width:auto!important;
    min-width:0!important;
    overflow:visible!important;
    gap:0!important;
}

/* إزالة أي خلفية تظهر عند التحديد أو المرور */
#header.cz-header-v8 #mtop.cz-topnav-v8 a,
#header.cz-header-v8 #mtop.cz-topnav-v8 a:hover,
#header.cz-header-v8 #mtop.cz-topnav-v8 a.active,
#header.cz-header-v8 #mtop.cz-topnav-v8 a.selected{
    background-color:transparent!important;
    background-image:none!important;
    box-shadow:none!important;
    border-color:transparent!important;
}


/* =========================================================
   CITYZERO STEP 45
   TOP ICONS: SAME LEVEL + EXACT EQUAL SPACING
   NO IMAGE DESIGN
   ========================================================= */

/* القائمة: صف واحد، محاذاة واحدة، ومسافات متساوية */
#header.cz-header-v8 #mtop.cz-topnav-v8{
    display:flex!important;
    flex-direction:row!important;
    flex-wrap:nowrap!important;
    align-items:center!important;
    justify-content:center!important;
    gap:12px!important;
    column-gap:12px!important;
    row-gap:0!important;
    height:146px!important;
    min-height:146px!important;
    padding:0!important;
    margin-top:0!important;
    margin-bottom:0!important;
    overflow:visible!important;
}

/* n5 إذا كان موجوداً لا يغيّر مستوى الأيقونة */
#header.cz-header-v8 #mtop.cz-topnav-v8 #n5{
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    width:138px!important;
    min-width:138px!important;
    max-width:138px!important;
    height:138px!important;
    min-height:138px!important;
    max-height:138px!important;
    padding:0!important;
    margin:0!important;
    float:none!important;
    position:static!important;
    top:auto!important;
    bottom:auto!important;
}

/* كل الأزرار بنفس الصندوق تماماً */
#header.cz-header-v8 #mtop.cz-topnav-v8 > a,
#header.cz-header-v8 #mtop.cz-topnav-v8 > #n5 > a,
#header.cz-header-v8 #mtop.cz-topnav-v8 .cz-nav-item,
#header.cz-header-v8 #mtop.cz-topnav-v8 #hero_adventures{
    flex:0 0 138px!important;
    width:138px!important;
    min-width:138px!important;
    max-width:138px!important;
    height:138px!important;
    min-height:138px!important;
    max-height:138px!important;
    padding:4px!important;
    margin:0!important;
    float:none!important;
    position:relative!important;
    top:0!important;
    bottom:auto!important;
    left:auto!important;
    right:auto!important;
    transform:none!important;
    vertical-align:middle!important;
    align-self:center!important;
    box-sizing:border-box!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
}

/* كل الصور 130x130 وعلى نفس المركز */
#header.cz-header-v8 #mtop.cz-topnav-v8 .cz-nav-icon{
    display:block!important;
    flex:0 0 130px!important;
    width:130px!important;
    min-width:130px!important;
    max-width:130px!important;
    height:130px!important;
    min-height:130px!important;
    max-height:130px!important;
    margin:0!important;
    padding:0!important;
    position:static!important;
    top:auto!important;
    bottom:auto!important;
    left:auto!important;
    right:auto!important;
    transform:none!important;
    align-self:center!important;
    background-position:center center!important;
    background-size:contain!important;
    background-repeat:no-repeat!important;
}

/* إلغاء أي إزاحات قديمة خاصة بزر بعينه */
#header.cz-header-v8 #mtop.cz-topnav-v8 #plus,
#header.cz-header-v8 #mtop.cz-topnav-v8 #hero_adventures{
    margin:0!important;
    top:0!important;
    bottom:auto!important;
    transform:none!important;
}


/* =========================================================
   CITYZERO STEP 46 — REAL HEADER ALIGNMENT
   Header template + CSS only
   ========================================================= */

/* كل روابط الهيدر الفعلية بنفس القياس والمستوى */
#header.cz-header-v8 #mtop.cz-topnav-v8 .cz-header-nav-button{
    flex:0 0 138px!important;
    width:138px!important;
    min-width:138px!important;
    max-width:138px!important;
    height:138px!important;
    min-height:138px!important;
    max-height:138px!important;
    margin:0!important;
    padding:4px!important;
    position:relative!important;
    top:0!important;
    bottom:auto!important;
    left:auto!important;
    right:auto!important;
    float:none!important;
    transform:none!important;
    align-self:center!important;
    vertical-align:middle!important;
    box-sizing:border-box!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
}

/* القائمة الفعلية: صف واحد ومسافة ثابتة */
#header.cz-header-v8 #mtop.cz-topnav-v8{
    display:flex!important;
    flex-flow:row nowrap!important;
    align-items:center!important;
    justify-content:center!important;
    gap:12px!important;
    padding:0!important;
    margin:0!important;
}

/* الصورة داخل كل زر */
#header.cz-header-v8 #mtop.cz-topnav-v8 .cz-header-nav-button .cz-nav-icon{
    width:130px!important;
    height:130px!important;
    min-width:130px!important;
    min-height:130px!important;
    max-width:130px!important;
    max-height:130px!important;
    margin:0!important;
    padding:0!important;
    position:static!important;
    transform:none!important;
    align-self:center!important;
    background-position:center!important;
    background-size:contain!important;
    background-repeat:no-repeat!important;
}


/* =========================================================
   CITYZERO STEP 47 — FINAL FLAT HEADER ROW FIX
   السبب الحقيقي كان #n5 يجمع التقارير والرسائل داخل عنصر واحد
   ========================================================= */

#header.cz-header-v8 .cz-header-inner{
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    position:relative!important;
}

/* القائمة كلها صف واحد حقيقي */
#header.cz-header-v8 #mtop.cz-topnav-v8{
    position:static!important;
    float:none!important;
    display:flex!important;
    flex-direction:row!important;
    flex-wrap:nowrap!important;
    align-items:center!important;
    justify-content:center!important;
    gap:14px!important;
    width:auto!important;
    min-width:0!important;
    height:138px!important;
    min-height:138px!important;
    margin:0 auto!important;
    padding:0!important;
    transform:none!important;
    overflow:visible!important;
}

/* جميع الأزرار أصبحت أبناء مباشرين للقائمة */
#header.cz-header-v8 #mtop.cz-topnav-v8 > a{
    flex:0 0 130px!important;
    width:130px!important;
    min-width:130px!important;
    max-width:130px!important;
    height:130px!important;
    min-height:130px!important;
    max-height:130px!important;
    margin:0!important;
    padding:0!important;
    top:auto!important;
    bottom:auto!important;
    left:auto!important;
    right:auto!important;
    position:relative!important;
    float:none!important;
    transform:none!important;
    align-self:center!important;
    vertical-align:middle!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    box-sizing:border-box!important;
}

/* كل صورة بنفس القياس والمركز */
#header.cz-header-v8 #mtop.cz-topnav-v8 > a > .cz-nav-icon{
    display:block!important;
    flex:0 0 130px!important;
    width:130px!important;
    min-width:130px!important;
    max-width:130px!important;
    height:130px!important;
    min-height:130px!important;
    max-height:130px!important;
    margin:0!important;
    padding:0!important;
    position:static!important;
    transform:none!important;
    background-position:center center!important;
    background-size:contain!important;
    background-repeat:no-repeat!important;
}

/* احتياط: إذا بقي n5 من كاش/نسخة قديمة لا يؤثر على الصف */
#header.cz-header-v8 #mtop.cz-topnav-v8 #n5{
    display:contents!important;
}

/* وقت السيرفر محذوف من الهيدر نفسه */
#header.cz-header-v8 .cz-server-status{
    display:none!important;
}


/* CITYZERO STEP 48 — المسافة بين الأيقونات 10px */
#header.cz-header-v8 #mtop.cz-topnav-v8{
    gap:10px!important;
    column-gap:10px!important;
}


/* CITYZERO STEP 49 — المسافة بين الأيقونات 4px */
#header.cz-header-v8 #mtop.cz-topnav-v8{
    gap:4px!important;
    column-gap:4px!important;
}


/* CITYZERO STEP 50 — المسافة بين الأيقونات 1px */
#header.cz-header-v8 #mtop.cz-topnav-v8{
    gap:1px!important;
    column-gap:1px!important;
}


/* =========================================================
   CITYZERO STEP 51
   تقارب الأيقونات فعلياً + تصغير شريط الموارد
   ========================================================= */

/*
   الصور نفسها 130x130 لكن ملفات PNG بيها فراغ شفاف حول الرسم،
   لذلك تقليل gap وحده ما كان يبين فرق.
   هنا نقلل عرض كل خانة إلى 108px مع إبقاء الصورة 130px،
   فتتقارب الرسومات فعلياً من بعضها.
*/
#header.cz-header-v8 #mtop.cz-topnav-v8{
    gap:0!important;
    column-gap:0!important;
    justify-content:center!important;
}

#header.cz-header-v8 #mtop.cz-topnav-v8 > a{
    flex:0 0 108px!important;
    width:108px!important;
    min-width:108px!important;
    max-width:108px!important;
    height:130px!important;
    min-height:130px!important;
    max-height:130px!important;
    margin:0!important;
    padding:0!important;
    overflow:visible!important;
    position:relative!important;
}

/* الصورة تبقى 130 × 130 وتخرج قليلاً من صندوق الزر حتى تتقارب بصرياً */
#header.cz-header-v8 #mtop.cz-topnav-v8 > a > .cz-nav-icon{
    width:130px!important;
    min-width:130px!important;
    max-width:130px!important;
    height:130px!important;
    min-height:130px!important;
    max-height:130px!important;
    position:absolute!important;
    left:50%!important;
    top:50%!important;
    transform:translate(-50%,-50%)!important;
    margin:0!important;
}


/* =========================================================
   CITYZERO STEP 54 — BALANCED TIGHT ICONS
   تقارب مرتب بدون تداخل بين الصور
   ========================================================= */
#header.cz-header-v8 #mtop.cz-topnav-v8{
    gap:2px!important;
    column-gap:2px!important;
    justify-content:center!important;
    align-items:center!important;
}

#header.cz-header-v8 #mtop.cz-topnav-v8 .cz-header-nav-button{
    flex:0 0 102px!important;
    width:102px!important;
    min-width:102px!important;
    max-width:102px!important;
    height:124px!important;
    min-height:124px!important;
    max-height:124px!important;
    margin:0!important;
    padding:0!important;
    overflow:visible!important;
}

#header.cz-header-v8 #mtop.cz-topnav-v8 .cz-header-nav-button .cz-nav-icon{
    width:120px!important;
    min-width:120px!important;
    max-width:120px!important;
    height:120px!important;
    min-height:120px!important;
    max-height:120px!important;
    left:50%!important;
    top:50%!important;
    transform:translate(-50%,-50%)!important;
}

/* صورة المغامرات أعرض بصرياً من بقية الصور، لذلك توحّد بهذا القياس */
#header.cz-header-v8 #mtop.cz-topnav-v8 #hero_adventures.cz-header-nav-button .cz-nav-icon{
    width:112px!important;
    min-width:112px!important;
    max-width:112px!important;
    height:112px!important;
    min-height:112px!important;
    max-height:112px!important;
}

/* =========================================================
   شريط الموارد — أصغر عرضاً وارتفاعاً ومرتب بالوسط
   ========================================================= */

#res{
    width:1180px!important;
    max-width:calc(100% - 80px)!important;
    height:48px!important;
    min-height:48px!important;
    margin-left:auto!important;
    margin-right:auto!important;
    padding:0!important;
    border-radius:9px!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
}

#resWrap{
    width:100%!important;
    max-width:100%!important;
    height:48px!important;
    min-height:48px!important;
    margin:0 auto!important;
    padding:0!important;
    box-sizing:border-box!important;
}

#resWrap table{
    width:100%!important;
    height:48px!important;
    table-layout:fixed!important;
    margin:0!important;
    border-collapse:collapse!important;
}

#resWrap table td{
    height:48px!important;
    padding:3px 8px!important;
    font-size:13px!important;
    line-height:1.15!important;
    vertical-align:middle!important;
    white-space:nowrap!important;
    box-sizing:border-box!important;
}

/* تصغير أيقونات الموارد داخل الشريط فقط */
#resWrap table td img{
    max-width:22px!important;
    max-height:22px!important;
    width:auto!important;
    height:auto!important;
    vertical-align:middle!important;
}


/* =========================================================
   CITYZERO STEP 52 — VERY TIGHT TOP ICONS
   الصورة تبقى 130x130 لكن المساحة المحجوزة لكل زر 82px فقط
   ========================================================= */
#header.cz-header-v8 #mtop.cz-topnav-v8{
    gap:0!important;
    column-gap:0!important;
    justify-content:center!important;
    width:max-content!important;
    min-width:0!important;
    margin-left:auto!important;
    margin-right:auto!important;
}

#header.cz-header-v8 #mtop.cz-topnav-v8 > a{
    flex:0 0 82px!important;
    width:82px!important;
    min-width:82px!important;
    max-width:82px!important;
    height:130px!important;
    min-height:130px!important;
    max-height:130px!important;
    padding:0!important;
    margin:0!important;
    overflow:visible!important;
}

/* كل صورة تبقى 130×130 ومتمركزة داخل خانة أضيق */
#header.cz-header-v8 #mtop.cz-topnav-v8 > a > .cz-nav-icon{
    width:130px!important;
    height:130px!important;
    min-width:130px!important;
    min-height:130px!important;
    max-width:130px!important;
    max-height:130px!important;
    left:50%!important;
    top:50%!important;
    position:absolute!important;
    transform:translate(-50%,-50%)!important;
}

/* شريط الموارد أضيق أكثر */
#res{
    width:980px!important;
    max-width:calc(100% - 120px)!important;
    height:44px!important;
    min-height:44px!important;
    margin:0 auto!important;
}

#resWrap,
#resWrap table{
    height:44px!important;
    min-height:44px!important;
}

#resWrap table td{
    height:44px!important;
    padding:2px 5px!important;
    font-size:12px!important;
}


/* =========================================================
   CITYZERO STEP 53 — FINAL TIGHT ICONS SPECIFICITY FIX
   يتغلب على قياس 138px القديم في STEP 46
   ========================================================= */
#header.cz-header-v8 #mtop.cz-topnav-v8{
    display:flex!important;
    flex-flow:row nowrap!important;
    justify-content:center!important;
    align-items:center!important;
    gap:0!important;
    column-gap:0!important;
    width:max-content!important;
    min-width:0!important;
    margin-left:auto!important;
    margin-right:auto!important;
}

#header.cz-header-v8 #mtop.cz-topnav-v8 .cz-header-nav-button{
    flex:0 0 82px!important;
    width:82px!important;
    min-width:82px!important;
    max-width:82px!important;
    height:130px!important;
    min-height:130px!important;
    max-height:130px!important;
    margin:0!important;
    padding:0!important;
    overflow:visible!important;
    position:relative!important;
}

#header.cz-header-v8 #mtop.cz-topnav-v8 .cz-header-nav-button .cz-nav-icon{
    width:130px!important;
    min-width:130px!important;
    max-width:130px!important;
    height:130px!important;
    min-height:130px!important;
    max-height:130px!important;
    position:absolute!important;
    left:50%!important;
    top:50%!important;
    transform:translate(-50%,-50%)!important;
    margin:0!important;
}
/* City Zero STEP 71 — purple hero-adventure movement on resource page */
#content.village1 table#movements tr.cz-hero-adventure-movement td{
    background:#fbf7ff!important;
    border-bottom-color:#eadcf2!important;
    height:43px!important;
}
#content.village1 table#movements tr.cz-hero-adventure-movement td:not(.typ){
    direction:rtl!important;
    text-align:right!important;
}
#content.village1 table#movements .cz-adventure-balloon{
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    width:16px!important;
    height:16px!important;
    margin:0!important;
    border:1px solid #75408f!important;
    border-radius:50% 50% 50% 5px!important;
    background:linear-gradient(145deg,#b76ad0,#71358c)!important;
    color:#fff4b8!important;
    box-shadow:0 2px 5px rgba(83,37,104,.28)!important;
    transform:rotate(-8deg)!important;
    font-size:8px!important;
    line-height:1!important;
}
#content.village1 table#movements .cz-adventure-movement-title{
    display:block!important;
    color:#8b3fa5!important;
    font-weight:700!important;
    text-decoration:none!important;
    white-space:nowrap!important;
    font-size:10px!important;
}
#content.village1 table#movements .cz-adventure-arrow{
    color:#8b3fa5!important;
    font-weight:700!important;
    margin-left:3px!important;
}
/* City Zero STEP 74 — Travian-style coloured movement balloons */
#content.village1 table#movements .cz-movement-balloon{
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    width:17px!important;
    height:17px!important;
    margin:0!important;
    border:1px solid transparent!important;
    border-radius:50% 50% 50% 5px!important;
    color:#fff!important;
    font-size:9px!important;
    font-weight:700!important;
    line-height:1!important;
    box-shadow:0 2px 4px rgba(40,30,20,.22)!important;
    transform:rotate(-7deg)!important;
}
#content.village1 table#movements .cz-balloon-yellow{
    border-color:#b48708!important;
    background:linear-gradient(145deg,#f4cf42,#c79308)!important;
    color:#5f4400!important;
}
#content.village1 table#movements .cz-balloon-red{
    border-color:#9d261e!important;
    background:linear-gradient(145deg,#e45d50,#ad281f)!important;
}
#content.village1 table#movements .cz-balloon-arrow{
    margin-left:3px!important;
    font-weight:700!important;
}
#content.village1 table#movements .cz-arrow-yellow,
#content.village1 table#movements tr.cz-outgoing-attack-row .mov span{color:#ad7b00!important;}
#content.village1 table#movements .cz-arrow-red,
#content.village1 table#movements tr.cz-incoming-attack-row .mov span{color:#b3261e!important;}

/* City Zero STEP 76 — keep the original sword icon; colour only its bubble. */
#content.village1 table#movements a.cz-original-attack-bubble{
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    width:22px!important;
    height:22px!important;
    margin:0!important;
    border:1px solid transparent!important;
    border-radius:50%!important;
    box-sizing:border-box!important;
    box-shadow:0 1px 3px rgba(40,30,20,.18)!important;
    vertical-align:middle!important;
}
#content.village1 table#movements a.cz-original-attack-bubble img{
    display:block!important;
    float:none!important;
    width:16px!important;
    height:16px!important;
    margin:0!important;
    padding:0!important;
    transform:none!important;
}
#content.village1 table#movements a.cz-yellow-bubble{
    background:#efc62e!important;
    border-color:#bf9508!important;
}
#content.village1 table#movements a.cz-red-bubble{
    background:#d8463b!important;
    border-color:#a92b23!important;
}

/* City Zero v14.50 — keep every building card clear of the resource bar. */
body.cz-build-body #mid > #content.build.cz-build-page{
    margin-top:20px!important;
}

/* City Zero v14.56 — منع صورة حقل الموارد من التداخل مع العنوان والوصف. */
body.cz-build-body #content.build #build.cz-resource-build .cz-resource-build-head{
    display:flex!important;
    flex-direction:row!important;
    align-items:center!important;
    gap:20px!important;
    min-height:112px!important;
    padding:14px 18px!important;
}
body.cz-build-body #content.build #build.cz-resource-build .cz-resource-build-head > a.cz-resource-logo{
    position:static!important;
    top:auto!important;
    right:auto!important;
    left:auto!important;
    float:none!important;
    flex:0 0 92px!important;
    width:92px!important;
    height:92px!important;
    margin:0!important;
    padding:0!important;
    z-index:auto!important;
}
body.cz-build-body #content.build #build.cz-resource-build .cz-resource-heading{
    flex:1 1 auto!important;
    min-width:0!important;
}
body.cz-build-body #content.build #build.cz-resource-build .cz-resource-heading h1{
    margin:0 0 9px!important;
    min-height:0!important;
}
body.cz-build-body #content.build #build.cz-resource-build .cz-resource-heading .build_desc{
    margin:0!important;
    padding:0!important;
    min-height:0!important;
    background:transparent!important;
    border:0!important;
    border-radius:0!important;
    color:#214c3a!important;
    font-size:13px!important;
    line-height:1.9!important;
    font-weight:700!important;
    text-align:right!important;
}

/* City Zero v14.51 — centred daily-missions heading and notice. */
#side_info #czDailyTasks .cz-daily-head{
    display:block!important;
}
#side_info #czDailyTasks .cz-daily-title-wrap{
    width:100%!important;
}
#side_info #czDailyTasks .cz-daily-title{
    width:100%!important;
    padding:6px 8px!important;
    box-sizing:border-box!important;
    border:1px solid #d2a431!important;
    border-radius:7px!important;
    background:linear-gradient(180deg,#0a684d 0%,#07523d 100%)!important;
    color:#f7d66b!important;
    text-align:center!important;
}
#side_info #czDailyTasks .cz-daily-subtitle{
    width:100%!important;
    margin:6px 0 0!important;
    color:#c83228!important;
    font-weight:700!important;
    text-align:center!important;
}

/* City Zero v14.55 — high-contrast ranking typography. */
body.cz-ranking-body #content.statistics,
body.cz-ranking-body #content.statistics *{
    text-rendering:optimizeLegibility!important;
    -webkit-font-smoothing:antialiased!important;
}
body.cz-ranking-body #content.statistics .cz-ranking-tabs > a:not(.selected):not(.cz-current){
    color:#244535!important;
    opacity:1!important;
    text-shadow:none!important;
}
body.cz-ranking-body #content.statistics .cz-ranking-tabs > a:not(.selected):not(.cz-current) > span:not(.cz-rank-tab-icon){
    color:#244535!important;
    font-weight:700!important;
    opacity:1!important;
}
body.cz-ranking-body #content.statistics .cz-ranking-tabs > a:not(.selected):not(.cz-current) .cz-rank-tab-icon{
    color:#674d09!important;
    background:#eadcb9!important;
    border-color:#cdbb8d!important;
    opacity:1!important;
}
body.cz-ranking-body #content.statistics .cz-ranking-tabs > a.selected,
body.cz-ranking-body #content.statistics .cz-ranking-tabs > a.cz-current,
body.cz-ranking-body #content.statistics .cz-ranking-tabs > a.selected > span,
body.cz-ranking-body #content.statistics .cz-ranking-tabs > a.cz-current > span{
    color:#ffffff!important;
    opacity:1!important;
}
body.cz-ranking-body #content.statistics table thead th{
    color:#ffffff!important;
    opacity:1!important;
}
body.cz-ranking-body #content.statistics table thead td,
body.cz-ranking-body #content.statistics table thead td a{
    color:#263c31!important;
    font-weight:700!important;
    opacity:1!important;
}
body.cz-ranking-body #content.statistics table tbody td,
body.cz-ranking-body #content.statistics table tbody th{
    color:#202d26!important;
    font-weight:600!important;
    opacity:1!important;
}
body.cz-ranking-body #content.statistics table tbody td a{
    color:#006344!important;
    font-weight:800!important;
    opacity:1!important;
}
body.cz-ranking-body #content.statistics table tbody td.ra,
body.cz-ranking-body #content.statistics table tbody td.val{
    color:#352f1f!important;
    font-weight:800!important;
}
body.cz-ranking-body #content.statistics .cz-rank-search,
body.cz-ranking-body #content.statistics .cz-rank-search label,
body.cz-ranking-body #content.statistics .cz-rank-search-fields label{
    color:#263c31!important;
    font-weight:700!important;
    opacity:1!important;
}
body.cz-ranking-body #content.statistics .cz-rank-search input{
    color:#17251e!important;
    font-weight:700!important;
    opacity:1!important;
}
body.cz-ranking-body #content.statistics .cz-rank-navi,
body.cz-ranking-body #content.statistics .cz-rank-navi a{
    color:#075b40!important;
    font-weight:700!important;
    opacity:1!important;
}
body.cz-ranking-body #content.statistics .cz-rank-navi .disabled{
    color:#68756e!important;
    font-weight:600!important;
    opacity:1!important;
}

/* City Zero v14.56 — balanced RTL building queue on fields and village pages. */
body.cz-resources-body #building_contract.cz-building-queue,
body.cz-village-body #building_contract.cz-building-queue,
body.cz-build-body #building_contract.cz-building-queue,
#building_contract.cz-building-queue{
    table-layout:fixed!important;
    width:100%!important;
    direction:rtl!important;
}
#building_contract.cz-building-queue thead th{
    position:relative!important;
    height:44px!important;
    padding:0 12px!important;
    box-sizing:border-box!important;
    text-align:right!important;
    vertical-align:middle!important;
}
#building_contract.cz-building-queue .cz-queue-title{
    display:inline-flex!important;
    align-items:center!important;
    height:44px!important;
    margin:0!important;
    color:#fff!important;
    font-size:13px!important;
    font-weight:700!important;
}
#building_contract.cz-building-queue thead th > a{
    position:absolute!important;
    left:10px!important;
    right:auto!important;
    top:50%!important;
    transform:translateY(-50%)!important;
}
#building_contract.cz-building-queue tbody td{
    height:46px!important;
    padding:7px 9px!important;
    box-sizing:border-box!important;
    text-align:center!important;
    vertical-align:middle!important;
    color:#27382f!important;
    font-size:11px!important;
    line-height:18px!important;
}
#building_contract.cz-building-queue td.cz-queue-building{
    width:36%!important;
    text-align:right!important;
    white-space:normal!important;
}
#building_contract.cz-building-queue td.cz-queue-building strong{
    display:inline!important;
    color:#075b40!important;
    font-size:12px!important;
    font-weight:800!important;
}
#building_contract.cz-building-queue td.cz-queue-time{
    width:25%!important;
    white-space:nowrap!important;
}
#building_contract.cz-building-queue td.cz-queue-finish{
    width:29%!important;
    white-space:nowrap!important;
}
#building_contract.cz-building-queue td.cz-queue-cancel{
    width:10%!important;
    text-align:center!important;
}
#building_contract.cz-building-queue .cz-time-label{
    display:block!important;
    margin-bottom:1px!important;
    color:#657069!important;
    font-size:9px!important;
    line-height:13px!important;
    font-weight:600!important;
}
#building_contract.cz-building-queue .cz-queue-time strong,
#building_contract.cz-building-queue .cz-queue-finish strong{
    color:#263a30!important;
    font-size:11px!important;
    font-weight:800!important;
}
#building_contract.cz-building-queue .cz-queue-cancel a{
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    width:28px!important;
    height:28px!important;
    border:1px solid #e2b9ad!important;
    border-radius:7px!important;
    background:#fff3ef!important;
}

/* City Zero v14.57 — clear Alliance Top 10 labels; obsolete help icons removed. */
body.cz-ranking-body #content.statistics .cz-top10-tool:not(.active),
body.cz-ranking-body #content.statistics .cz-top10-tool:not(.active) span{
    color:#263f33!important;
    font-weight:700!important;
    opacity:1!important;
    text-shadow:none!important;
}
body.cz-ranking-body #content.statistics .cz-top10-tool.active,
body.cz-ranking-body #content.statistics .cz-top10-tool.active span{
    color:#ffffff!important;
    font-weight:800!important;
    opacity:1!important;
    text-shadow:0 1px 0 rgba(0,0,0,.20)!important;
}
body.cz-ranking-body #content.statistics table[id^="top10_"] thead tr:first-child th{
    color:#ffffff!important;
    font-size:14px!important;
    font-weight:800!important;
    text-align:center!important;
    opacity:1!important;
}
body.cz-ranking-body #content.statistics table[id^="top10_"] thead tr:nth-child(2) td{
    color:#263a30!important;
    font-size:11px!important;
    font-weight:800!important;
    opacity:1!important;
}

/* City Zero v14.58 — requested City Zero logo display size. */
#header.cz-header-v8 .cz-top-brand,
#header.cz-header .cz-top-brand{
    width:680px!important;
    min-width:680px!important;
    max-width:680px!important;
    height:145px!important;
    min-height:145px!important;
    max-height:145px!important;
    background-size:contain!important;
    background-repeat:no-repeat!important;
}

#header.cz-header-v8,
#header.cz-header,
#header.cz-header-v8 .cz-header-inner,
#header.cz-header .cz-header-inner{
    height:158px!important;
    min-height:158px!important;
}

/* City Zero v14.52 — player name matches the daily-missions title. */
#side_navi.cz-side-menu-v8 .cz-hero-profile-copy small{
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    width:100%!important;
    min-height:35px!important;
    margin:0!important;
    padding:6px 8px!important;
    box-sizing:border-box!important;
    border:1px solid #d2a431!important;
    border-radius:7px!important;
    background:linear-gradient(180deg,#0a684d 0%,#07523d 100%)!important;
    color:#f7d66b!important;
    font-size:15px!important;
    line-height:21px!important;
    font-weight:700!important;
    text-align:center!important;
}
/* =========================================================
   CITY ZERO V22 - public player profile RTL layout
   ========================================================= */
#content.player{
    width:min(730px,calc(100% - 400px))!important;
    max-width:730px!important;
    min-width:0!important;
    margin:0 auto 36px!important;
    padding:16px!important;
    direction:rtl!important;
    text-align:right!important;
    color:#20372e!important;
    background:#fffaf1!important;
    border:1px solid #d8c7a8!important;
    border-radius:15px!important;
    box-shadow:0 8px 22px rgba(39,53,44,.12)!important;
    box-sizing:border-box!important;
    font-family:Tahoma,Arial,sans-serif!important;
}

#content.player>h1{
    margin:0 0 16px!important;
    padding:3px 0 14px!important;
    color:#07583f!important;
    font:700 27px/1.25 Tahoma,Arial,sans-serif!important;
    text-align:center!important;
    border-bottom:2px solid #d3a52e!important;
}

/* Main player card */
#content.player>table#profile{
    width:100%!important;
    margin:0 0 18px!important;
    direction:rtl!important;
    table-layout:fixed!important;
    border-collapse:separate!important;
    border-spacing:0!important;
    overflow:hidden!important;
    background:#fff!important;
    border:1px solid #d9c9ad!important;
    border-radius:12px!important;
    box-sizing:border-box!important;
}

#content.player>table#profile>thead>tr:first-child>th{
    padding:13px 16px!important;
    background:#07583f!important;
    color:#fff!important;
    font:700 15px/1.4 Tahoma,Arial,sans-serif!important;
    text-align:center!important;
    border:0!important;
}

#content.player>table#profile>thead>tr:not(:first-child)>td{
    width:50%!important;
    padding:11px 14px!important;
    background:#164f3b!important;
    color:#fff!important;
    font:700 14px/1.4 Tahoma,Arial,sans-serif!important;
    text-align:center!important;
    border-color:#2d6d57!important;
}

#content.player>table#profile>tbody>tr:first-child{
    display:none!important;
}

#content.player>table#profile>tbody>tr>td.details,
#content.player>table#profile>tbody>tr>td.desc1{
    width:50%!important;
    padding:14px!important;
    vertical-align:top!important;
    color:#24382f!important;
    background:#fffdf8!important;
    border:0!important;
    box-sizing:border-box!important;
    font:500 13px/1.7 Tahoma,Arial,sans-serif!important;
    overflow-wrap:anywhere!important;
}

#content.player>table#profile>tbody>tr>td.details{
    border-left:1px solid #e1d5c2!important;
}

#content.player>table#profile>tbody>tr>td.desc1>div,
#content.player>table#profile .desc2div{
    min-height:220px!important;
    padding:10px!important;
    direction:rtl!important;
    text-align:right!important;
    color:#263d33!important;
    background:#fbf7ee!important;
    border:1px solid #e4d9c6!important;
    border-radius:9px!important;
    box-sizing:border-box!important;
    font:500 13px/1.75 Tahoma,Arial,sans-serif!important;
}

/* Details rows */
#content.player>table#profile td.details>table{
    width:100%!important;
    margin:0!important;
    direction:rtl!important;
    table-layout:fixed!important;
    border-collapse:separate!important;
    border-spacing:0!important;
    background:#fff!important;
    border:1px solid #ddd0b9!important;
    border-radius:9px!important;
    overflow:hidden!important;
}

#content.player>table#profile td.details>table tr th,
#content.player>table#profile td.details>table tr td{
    min-height:38px!important;
    padding:9px 11px!important;
    text-align:right!important;
    vertical-align:middle!important;
    border:0!important;
    border-bottom:1px solid #e8dfd1!important;
    color:#263a31!important;
    background:#fff!important;
    font:600 13px/1.45 Tahoma,Arial,sans-serif!important;
    box-sizing:border-box!important;
}

#content.player>table#profile td.details>table tr th{
    width:43%!important;
    background:#edf4ed!important;
    color:#07583f!important;
    font-weight:700!important;
}

#content.player>table#profile td.details>table tr:last-child td,
#content.player>table#profile td.details>table tr:last-child th{
    border-bottom:0!important;
}

#content.player>table#profile td.details>table td.empty{
    display:none!important;
}

#content.player>table#profile td.details>table td[colspan="2"]{
    width:100%!important;
    padding:10px 12px!important;
    text-align:center!important;
    background:#fffaf0!important;
}

#content.player a{
    color:#167000!important;
    font-weight:700!important;
    text-decoration:none!important;
}
#content.player a:hover{
    color:#0b5635!important;
    text-decoration:underline!important;
}

/* Villages card */
#content.player>table#villages{
    width:100%!important;
    margin:0!important;
    direction:rtl!important;
    table-layout:fixed!important;
    border-collapse:separate!important;
    border-spacing:0!important;
    overflow:hidden!important;
    background:#fff!important;
    border:1px solid #d9c9ad!important;
    border-radius:12px!important;
}

#content.player>table#villages thead tr:first-child th{
    padding:11px 14px!important;
    background:#07583f!important;
    color:#fff!important;
    text-align:center!important;
    font:700 14px/1.4 Tahoma,Arial,sans-serif!important;
    border:0!important;
}

#content.player>table#villages thead tr:nth-child(2) td{
    padding:9px 12px!important;
    background:#edf4ed!important;
    color:#07583f!important;
    text-align:center!important;
    font:700 13px/1.4 Tahoma,Arial,sans-serif!important;
    border-color:#ded3c1!important;
}

#content.player>table#villages tbody td{
    padding:10px 12px!important;
    color:#263a31!important;
    background:#fffdf8!important;
    text-align:center!important;
    border-color:#e8dfd1!important;
    font:600 13px/1.45 Tahoma,Arial,sans-serif!important;
}

#content.player>table#villages td.nam{
    width:52%!important;
    text-align:right!important;
}
#content.player>table#villages td.hab{width:20%!important;}
#content.player>table#villages td.aligned_coords{
    width:28%!important;
    direction:ltr!important;
    text-align:center!important;
}

@media(max-width:1250px){
    #content.player{
        width:min(680px,calc(100% - 390px))!important;
        padding:14px!important;
    }
}

/* =========================================================
   CITYZERO — ARABIC ARTEFACT ANNOUNCEMENT
   صفحة مستقلة باتجاه عربي ومسافة آمنة تحت شريط الموارد
   ========================================================= */
#mid > #content.cz-announcement-page{
    direction:rtl!important;
    text-align:right!important;
    box-sizing:border-box!important;
    margin-top:34px!important;
    padding:22px 28px 34px!important;
    overflow:visible!important;
    line-height:1.85!important;
    font-family:Tahoma,Arial,sans-serif!important;
}

#content.cz-announcement-page > h1{
    position:relative!important;
    top:auto!important;
    right:auto!important;
    left:auto!important;
    margin:0 0 18px!important;
    padding:0 0 10px!important;
    text-align:center!important;
    line-height:1.25!important;
    clear:both!important;
}

#content.cz-announcement-page .cz-announcement-welcome{
    margin:0 0 18px!important;
    text-align:right!important;
    direction:rtl!important;
    line-height:1.6!important;
}

#content.cz-announcement-page .cz-announcement-copy{
    width:100%!important;
    max-width:100%!important;
    margin:0!important;
    padding:18px 20px!important;
    box-sizing:border-box!important;
    direction:rtl!important;
    unicode-bidi:plaintext!important;
    text-align:right!important;
    white-space:normal!important;
    overflow-wrap:anywhere!important;
    line-height:1.9!important;
    border:1px solid rgba(180,137,36,.28)!important;
    border-radius:12px!important;
    background:rgba(255,253,248,.72)!important;
}

#content.cz-announcement-page .cz-announcement-action{
    margin:24px 0 0!important;
    text-align:center!important;
    direction:rtl!important;
}

#content.cz-announcement-page .cz-announcement-action a{
    display:inline-block!important;
    padding:10px 24px!important;
    border-radius:9px!important;
    background:#08704f!important;
    color:#f5cf55!important;
    font:700 16px/1.4 Tahoma,Arial,sans-serif!important;
}

@media(max-width:1250px){
    #mid > #content.cz-announcement-page{
        margin-top:42px!important;
        padding:18px 20px 28px!important;
    }
}

/* صفحة التحف داخل الإحصائيات */
#content.statistics .cz-artefacts-ranking{
    direction:rtl!important;
    text-align:right!important;
    font-family:Tahoma,Arial,sans-serif!important;
}
#content.statistics .cz-artefacts-heading{
    display:flex!important;
    align-items:center!important;
    justify-content:space-between!important;
    gap:15px!important;
    margin:14px 0!important;
    padding:12px 16px!important;
    border-radius:10px!important;
    background:#f7f1e5!important;
    border:1px solid #dfcfab!important;
}
#content.statistics .cz-artefacts-heading h2{margin:0!important;color:#07583f!important;}
#content.statistics .cz-artefacts-empty{
    padding:22px!important;
    border-radius:10px!important;
    color:#8a2e20!important;
    background:#fff4ef!important;
    border:1px solid #e7b9aa!important;
    line-height:1.8!important;
}
#content.statistics table.cz-artefacts-table{width:100%!important;table-layout:auto!important;}
#content.statistics table.cz-artefacts-table th,
#content.statistics table.cz-artefacts-table td{
    padding:9px 8px!important;
    text-align:right!important;
    vertical-align:middle!important;
}
#content.statistics table.cz-artefacts-table td.aligned_coords{
    direction:ltr!important;
    text-align:center!important;
    white-space:nowrap!important;
}

/* =========================================================
   City Zero v15.1 — تنسيق واجهة الحقول ثلاثية الأبعاد
   ========================================================= */
body.cz-resources-body #content.village1.cz-resources-page{
    min-height:1050px!important;
}

body.cz-resources-body #content.village1 #village_map.cz-fields-3d{
    float:none!important;
    width:520px!important;
    min-width:520px!important;
    max-width:520px!important;
    height:520px!important;
    min-height:520px!important;
    max-height:520px!important;
    margin:18px auto 24px!important;
    border:0!important;
    border-radius:0!important;
    background:transparent!important;
    box-shadow:none!important;
    overflow:visible!important;
}

body.cz-resources-body #village_map.cz-fields-3d .cz-fields-3d-art{
    object-fit:contain!important;
    filter:drop-shadow(0 14px 16px rgba(6,30,22,.28))!important;
}

body.cz-resources-body #village_map.cz-fields-3d .cz-field-node,
body.cz-resources-body #village_map.cz-fields-3d .cz-field-type-1,
body.cz-resources-body #village_map.cz-fields-3d .cz-field-type-2,
body.cz-resources-body #village_map.cz-fields-3d .cz-field-type-3,
body.cz-resources-body #village_map.cz-fields-3d .cz-field-type-4{
    width:24px!important;
    height:24px!important;
    margin:-12px 0 0 -12px!important;
    border:1px solid #f2d067!important;
    background:rgba(5,76,54,.9)!important;
    color:#fff2b1!important;
    box-shadow:0 1px 0 #3b2a08,0 3px 7px rgba(0,0,0,.4)!important;
    font-size:11px!important;
}

body.cz-resources-body #village_map.cz-fields-3d .cz-field-node:hover{
    transform:scale(1.18)!important;
    background:#08704f!important;
}

body.cz-resources-body #village_map.cz-fields-3d .cz-field-label{
    bottom:29px!important;
}

body.cz-resources-body #village_map.cz-fields-3d .cz-fields-city{
    left:50%!important;
    top:49%!important;
    width:112px!important;
    height:112px!important;
    margin:-56px 0 0 -56px!important;
    padding:0!important;
    border:1px solid transparent!important;
    background:transparent!important;
    color:transparent!important;
    font-size:0!important;
}

body.cz-resources-body #village_map.cz-fields-3d .cz-fields-city:hover{
    border-color:rgba(242,208,103,.65)!important;
    background:rgba(7,88,63,.1)!important;
}

body.cz-resources-body .cz-resource-details{
    float:none!important;
    clear:both!important;
    display:grid!important;
    width:100%!important;
    margin:4px 0 0!important;
    padding:0!important;
    grid-template-columns:1fr 1fr!important;
    gap:14px!important;
}

body.cz-resources-body .cz-production-card,
body.cz-resources-body .cz-troops-card{
    width:auto!important;
    margin:0!important;
}

@media(max-width:720px){
    body.cz-resources-body #content.village1 #village_map.cz-fields-3d{
        width:440px!important;
        min-width:440px!important;
        max-width:440px!important;
        height:440px!important;
        min-height:440px!important;
        max-height:440px!important;
    }
}

/* =========================================================
   City Zero v15.2 — إعادة التخطيط الجانبي وتنظيف الأشجار
   ========================================================= */
body.cz-resources-body #content.village1.cz-resources-page{
    min-height:650px!important;
}

body.cz-resources-body #content.village1 #village_map.cz-fields-3d{
    float:left!important;
    width:330px!important;
    min-width:330px!important;
    max-width:330px!important;
    height:330px!important;
    min-height:330px!important;
    max-height:330px!important;
    margin:18px 0 18px!important;
}

body.cz-resources-body #village_map.cz-fields-3d .cz-field-node,
body.cz-resources-body #village_map.cz-fields-3d .cz-field-type-1,
body.cz-resources-body #village_map.cz-fields-3d .cz-field-type-2,
body.cz-resources-body #village_map.cz-fields-3d .cz-field-type-3,
body.cz-resources-body #village_map.cz-fields-3d .cz-field-type-4{
    width:22px!important;
    height:22px!important;
    margin:-11px 0 0 -11px!important;
    font-size:10px!important;
}

/* لون شارة المستوى حسب نوع المورد */
body.cz-resources-body #village_map.cz-fields-3d .cz-field-type-1{
    border-color:#b9e77b!important;
    background:linear-gradient(180deg,#4f9f3c 0%,#23752f 100%)!important;
    color:#fff!important;
}

body.cz-resources-body #village_map.cz-fields-3d .cz-field-type-2{
    border-color:#ffd09a!important;
    background:linear-gradient(180deg,#dc843b 0%,#a84c21 100%)!important;
    color:#fff!important;
}

body.cz-resources-body #village_map.cz-fields-3d .cz-field-type-3{
    border-color:#e8eeec!important;
    background:linear-gradient(180deg,#aeb9b6 0%,#687571 100%)!important;
    color:#fff!important;
}

body.cz-resources-body #village_map.cz-fields-3d .cz-field-type-4{
    border-color:#fff0a3!important;
    background:linear-gradient(180deg,#f5d949 0%,#c79a16 100%)!important;
    color:#3b2b00!important;
}

body.cz-resources-body #village_map.cz-fields-3d .cz-field-label{
    bottom:27px!important;
}

body.cz-resources-body #village_map.cz-fields-3d .cz-fields-city{
    width:74px!important;
    height:74px!important;
    margin:-37px 0 0 -37px!important;
}

body.cz-resources-body .cz-resource-details{
    float:right!important;
    clear:none!important;
    display:block!important;
    width:250px!important;
    margin:18px 0 0!important;
    grid-template-columns:none!important;
    gap:0!important;
}

body.cz-resources-body .cz-production-card,
body.cz-resources-body .cz-troops-card{
    width:250px!important;
    margin:0 0 12px!important;
}

body.cz-resources-body #content.village1.cz-resources-page:after{
    content:""!important;
    display:block!important;
    clear:both!important;
}

/* =========================================================
   City Zero v16.2 — صفحة تسجيل الخروج العربية
   ========================================================= */
html:has(body.cz-logout-body){
    direction:rtl!important;
    min-height:100%!important;
}

body.cz-logout-body{
    min-width:900px!important;
    min-height:100vh!important;
    margin:0!important;
    padding:0!important;
    direction:rtl!important;
    color:#173c2c!important;
    background:#102b21 url("../../../img/cityzero_bg.jpg") center/cover fixed no-repeat!important;
    font-family:Tahoma,Arial,sans-serif!important;
}

body.cz-logout-body:before{
    content:"";
    position:fixed;
    inset:0;
    z-index:0;
    background:linear-gradient(180deg,rgba(5,30,23,.26),rgba(4,24,18,.62));
    pointer-events:none;
}

.cz-logout-page{
    position:relative;
    z-index:1;
    min-height:100vh;
}

.cz-logout-header{
    height:150px;
    border-bottom:1px solid rgba(235,196,77,.55);
    background:linear-gradient(180deg,rgba(5,54,39,.97),rgba(4,38,29,.94));
    box-shadow:0 10px 30px rgba(0,0,0,.3);
}

.cz-logout-header-inner{
    width:1120px;
    height:100%;
    margin:0 auto;
    display:flex;
    align-items:center;
    justify-content:space-between;
    direction:rtl;
}

.cz-logout-brand{
    display:flex;
    width:390px;
    height:132px;
    align-items:center;
    justify-content:flex-start;
}

.cz-logout-brand img{
    display:block;
    width:380px;
    max-height:126px;
    object-fit:contain;
    filter:drop-shadow(0 5px 7px rgba(0,0,0,.42));
}

.cz-logout-nav{
    display:flex;
    align-items:center;
    gap:12px;
}

.cz-logout-nav a{
    min-width:130px;
    padding:12px 20px;
    box-sizing:border-box;
    border:1px solid rgba(238,205,105,.48);
    border-radius:10px;
    color:#fff8dc!important;
    background:rgba(255,255,255,.06);
    text-align:center;
    text-decoration:none!important;
    font:700 14px/1.3 Tahoma,Arial,sans-serif;
}

.cz-logout-nav a.is-primary,
.cz-logout-nav a:hover{
    border-color:#e8c34f;
    color:#173c2c!important;
    background:linear-gradient(180deg,#f5d76f,#dcae2f);
}

.cz-logout-main{
    min-height:650px;
    display:flex;
    align-items:flex-start;
    justify-content:center;
    padding:70px 20px 110px;
    box-sizing:border-box;
}

.cz-logout-card{
    width:600px;
    padding:38px 46px 42px;
    box-sizing:border-box;
    border:1px solid rgba(224,191,94,.72);
    border-radius:22px;
    background:rgba(255,253,247,.97);
    box-shadow:0 22px 55px rgba(0,0,0,.32);
    text-align:center;
}

.cz-logout-success-icon{
    width:72px;
    height:72px;
    margin:0 auto 16px;
    display:flex;
    align-items:center;
    justify-content:center;
    border:3px solid #e8c65b;
    border-radius:50%;
    color:#fff;
    background:linear-gradient(180deg,#13835e,#07583f);
    box-shadow:0 7px 17px rgba(7,88,63,.26);
    font:800 40px/1 Arial,sans-serif;
}

.cz-logout-eyebrow{
    margin:0 0 7px!important;
    color:#9a761d!important;
    font:700 13px/1.5 Tahoma,Arial,sans-serif!important;
}

.cz-logout-card h1{
    margin:0 0 13px!important;
    padding:0!important;
    color:#07583f!important;
    text-align:center!important;
    font:800 30px/1.35 Tahoma,Arial,sans-serif!important;
}

.cz-logout-thanks{
    margin:0 0 25px!important;
    color:#4e6258!important;
    font:600 15px/1.8 Tahoma,Arial,sans-serif!important;
}

.cz-logout-security{
    padding:16px 19px;
    border:1px solid #ead8a2;
    border-radius:12px;
    background:#fff8df;
    text-align:right;
}

.cz-logout-security strong{color:#805f12;font-size:14px;}
.cz-logout-security p{margin:5px 0 0!important;color:#5d5844!important;font:600 13px/1.75 Tahoma,Arial,sans-serif!important;}

.cz-logout-actions{
    margin-top:25px;
    display:flex;
    justify-content:center;
    gap:12px;
}

.cz-logout-actions a{
    min-width:190px;
    padding:12px 18px;
    border-radius:10px;
    text-align:center;
    text-decoration:none!important;
    font:700 14px/1.35 Tahoma,Arial,sans-serif;
}

.cz-logout-login{color:#fff!important;background:linear-gradient(180deg,#0b7452,#064a36);box-shadow:0 5px 12px rgba(7,88,63,.22);}
.cz-logout-cookies{border:1px solid #d8bd69;color:#755814!important;background:#fffaf0;}

.cz-logout-server-time{
    position:fixed;
    left:18px;
    bottom:14px;
    z-index:2;
    padding:7px 11px;
    border-radius:8px;
    color:#fff3c4;
    background:rgba(4,38,29,.8);
    font:600 11px/1.3 Tahoma,Arial,sans-serif;
}

body.cz-logout-body > .footer,
body.cz-logout-body #footer,
body.cz-logout-body .footer-stopper,
body.cz-logout-body #stime{
    display:none!important;
}

/* =========================================================
   City Zero v16.3 — صفحة تسجيل الدخول العربية
   ========================================================= */
html:has(body.cz-login-body){direction:rtl!important;min-height:100%!important;}

body.cz-login-body{
    min-width:900px!important;
    min-height:100vh!important;
    margin:0!important;
    padding:0!important;
    direction:rtl!important;
    color:#173c2c!important;
    background:#102b21 url("../../../img/cityzero_bg.jpg") center/cover fixed no-repeat!important;
    font-family:Tahoma,Arial,sans-serif!important;
}

body.cz-login-body:before{
    content:"";
    position:fixed;
    inset:0;
    z-index:0;
    background:linear-gradient(180deg,rgba(5,30,23,.26),rgba(4,24,18,.62));
    pointer-events:none;
}

.cz-login-page{position:relative;z-index:1;min-height:100vh;}

.cz-login-main{
    min-height:650px;
    display:flex;
    align-items:flex-start;
    justify-content:center;
    padding:55px 20px 100px;
    box-sizing:border-box;
}

body.cz-login-body #content.login.cz-login-card{
    position:relative!important;
    float:none!important;
    left:auto!important;
    right:auto!important;
    top:auto!important;
    width:600px!important;
    min-height:0!important;
    margin:0!important;
    padding:34px 46px 38px!important;
    box-sizing:border-box!important;
    border:1px solid rgba(224,191,94,.72)!important;
    border-radius:22px!important;
    background:rgba(255,253,247,.97)!important;
    box-shadow:0 22px 55px rgba(0,0,0,.32)!important;
    direction:rtl!important;
    text-align:right!important;
}

.cz-login-lock{
    width:64px;
    height:64px;
    margin:0 auto 13px;
    display:flex;
    align-items:center;
    justify-content:center;
    border:3px solid #e8c65b;
    border-radius:50%;
    color:#f7d967;
    background:linear-gradient(180deg,#13835e,#07583f);
    box-shadow:0 7px 17px rgba(7,88,63,.26);
    font:800 26px/1 Arial,sans-serif;
}

.cz-login-eyebrow{
    margin:0 0 5px!important;
    color:#9a761d!important;
    text-align:center!important;
    font:700 13px/1.5 Tahoma,Arial,sans-serif!important;
}

body.cz-login-body #content.login.cz-login-card h1{
    position:static!important;
    width:auto!important;
    height:auto!important;
    margin:0 0 10px!important;
    padding:0!important;
    color:#07583f!important;
    text-align:center!important;
    font:800 28px/1.4 Tahoma,Arial,sans-serif!important;
}

.cz-login-intro{
    margin:0 auto 22px!important;
    color:#52645a!important;
    text-align:center!important;
    font:600 14px/1.8 Tahoma,Arial,sans-serif!important;
}

body.cz-login-body table#login_form{
    width:100%!important;
    margin:0!important;
    border:0!important;
    border-collapse:separate!important;
    border-spacing:0 12px!important;
    background:transparent!important;
    direction:rtl!important;
}

body.cz-login-body table#login_form tr,
body.cz-login-body table#login_form th,
body.cz-login-body table#login_form td{
    border:0!important;
    background:transparent!important;
}

body.cz-login-body table#login_form th{
    width:135px!important;
    padding:0 0 0 14px!important;
    color:#174633!important;
    text-align:right!important;
    font:700 14px/1.4 Tahoma,Arial,sans-serif!important;
}

body.cz-login-body table#login_form td{padding:0!important;text-align:right!important;}

body.cz-login-body table#login_form input.text{
    width:100%!important;
    height:44px!important;
    margin:0!important;
    padding:0 13px!important;
    box-sizing:border-box!important;
    border:1px solid #d9c58b!important;
    border-radius:9px!important;
    outline:0!important;
    background:#fff!important;
    color:#243c31!important;
    direction:rtl!important;
    text-align:right!important;
    font:600 14px/1.4 Tahoma,Arial,sans-serif!important;
}

body.cz-login-body table#login_form input.text:focus{
    border-color:#0b7654!important;
    box-shadow:0 0 0 3px rgba(11,118,84,.12)!important;
}

body.cz-login-body #content.login p.btn{margin:17px 0 0!important;text-align:center!important;}

body.cz-login-body #btn_login.cz-login-submit{
    width:250px!important;
    height:46px!important;
    margin:0!important;
    padding:0 20px!important;
    border:1px solid #d2aa34!important;
    border-radius:10px!important;
    color:#fff!important;
    background:linear-gradient(180deg,#0c7956,#054a36)!important;
    box-shadow:0 7px 15px rgba(7,88,63,.23)!important;
    cursor:pointer!important;
    text-indent:0!important;
    font:800 15px/1 Tahoma,Arial,sans-serif!important;
}

body.cz-login-body #btn_login.cz-login-submit:hover{filter:brightness(1.08);}

body.cz-login-body #content.login .error_box{
    margin:17px 0 0!important;
    padding:13px 15px!important;
    border:1px solid #e7b19f!important;
    border-radius:10px!important;
    background:#fff1eb!important;
    color:#8a2d1f!important;
    text-align:right!important;
    line-height:1.7!important;
}

.cz-login-links{
    margin-top:23px;
    padding-top:18px;
    display:flex;
    justify-content:space-between;
    gap:14px;
    border-top:1px solid #e9debf;
}

.cz-login-links a{color:#087052!important;font:700 12px/1.5 Tahoma,Arial,sans-serif;text-decoration:none!important;}
.cz-login-links a:hover{text-decoration:underline!important;}

.cz-login-countdown-title{text-align:center;color:#805f12;font:700 16px/1.5 Tahoma,Arial,sans-serif;}
body.cz-login-body .activation_time{text-align:center;color:#07583f;font:800 28px/1.5 Tahoma,Arial,sans-serif;direction:ltr;}

/* =========================================================
   City Zero v16.4 — صفحة إنشاء الحساب العربية
   ========================================================= */
html:has(body.cz-signup-body){direction:rtl!important;min-height:100%!important;}

body.cz-signup-body{
    min-width:900px!important;
    min-height:100vh!important;
    margin:0!important;
    padding:0!important;
    direction:rtl!important;
    color:#173c2c!important;
    background:#102b21 url("../../../img/cityzero_bg.jpg") center/cover fixed no-repeat!important;
    font-family:Tahoma,Arial,sans-serif!important;
}

body.cz-signup-body:before{
    content:"";
    position:fixed;
    inset:0;
    z-index:0;
    background:linear-gradient(180deg,rgba(5,30,23,.26),rgba(4,24,18,.62));
    pointer-events:none;
}

.cz-signup-page{position:relative;z-index:1;min-height:100vh;}
.cz-signup-main{display:flex;justify-content:center;padding:38px 20px 80px;box-sizing:border-box;}

body.cz-signup-body #content.signup.cz-signup-card{
    position:relative!important;
    float:none!important;
    left:auto!important;
    right:auto!important;
    top:auto!important;
    width:720px!important;
    min-height:0!important;
    margin:0!important;
    padding:30px 46px 36px!important;
    box-sizing:border-box!important;
    border:1px solid rgba(224,191,94,.72)!important;
    border-radius:22px!important;
    background:rgba(255,253,247,.98)!important;
    box-shadow:0 22px 55px rgba(0,0,0,.32)!important;
    direction:rtl!important;
    text-align:right!important;
}

.cz-signup-icon{
    width:58px;height:58px;margin:0 auto 10px;display:flex;align-items:center;justify-content:center;
    border:3px solid #e8c65b;border-radius:50%;color:#f7d967;background:linear-gradient(180deg,#13835e,#07583f);
    box-shadow:0 7px 17px rgba(7,88,63,.26);font:800 27px/1 Arial,sans-serif;
}

.cz-signup-eyebrow{margin:0 0 3px!important;color:#9a761d!important;text-align:center!important;font:700 13px/1.5 Tahoma,Arial,sans-serif!important;}

body.cz-signup-body #content.signup.cz-signup-card h1{
    position:static!important;width:auto!important;height:auto!important;margin:0 0 7px!important;padding:0!important;
    color:#07583f!important;text-align:center!important;font:800 28px/1.4 Tahoma,Arial,sans-serif!important;
}

.cz-signup-intro{margin:0 auto 16px!important;color:#52645a!important;text-align:center!important;font:600 13px/1.8 Tahoma,Arial,sans-serif!important;}

body.cz-signup-body table#sign_input,
body.cz-signup-body table#sign_select{
    width:100%!important;margin:0 0 13px!important;border:0!important;border-collapse:separate!important;
    border-spacing:0 9px!important;background:transparent!important;direction:rtl!important;
}

body.cz-signup-body table#sign_input tr,
body.cz-signup-body table#sign_input th,
body.cz-signup-body table#sign_input td,
body.cz-signup-body table#sign_select tr,
body.cz-signup-body table#sign_select th,
body.cz-signup-body table#sign_select td{border:0!important;background:transparent!important;}

body.cz-signup-body table#sign_input th{width:150px!important;padding:0 0 0 14px!important;color:#174633!important;text-align:right!important;font:700 13px/1.4 Tahoma,Arial,sans-serif!important;}
body.cz-signup-body table#sign_input td{padding:0!important;}

body.cz-signup-body table#sign_input input.text{
    width:100%!important;height:42px!important;margin:0!important;padding:0 13px!important;box-sizing:border-box!important;
    border:1px solid #d9c58b!important;border-radius:9px!important;outline:0!important;background:#fff!important;color:#243c31!important;
    direction:rtl!important;text-align:right!important;font:600 14px/1.4 Tahoma,Arial,sans-serif!important;
}

body.cz-signup-body table#sign_input input.text:focus{border-color:#0b7654!important;box-shadow:0 0 0 3px rgba(11,118,84,.12)!important;}

body.cz-signup-body table#sign_select{
    padding:10px 14px 12px!important;border:1px solid #e2d3aa!important;border-radius:12px!important;background:#fffaf0!important;
}

body.cz-signup-body table#sign_select th{padding:5px 8px 8px!important;color:#07583f!important;text-align:right!important;font:800 14px/1.4 Tahoma,Arial,sans-serif!important;}
body.cz-signup-body table#sign_select td{padding:7px 9px!important;color:#354c40!important;text-align:right!important;font:600 12px/1.5 Tahoma,Arial,sans-serif!important;}
body.cz-signup-body table#sign_select label{display:flex!important;align-items:center!important;gap:6px!important;cursor:pointer!important;}
body.cz-signup-body input.radio,body.cz-signup-body input.check{accent-color:#087052!important;}

.cz-signup-agreement{margin:13px 0!important;padding:12px 14px!important;border:1px solid #e4d3a0!important;border-radius:10px!important;background:#fff9e8!important;color:#4f503d!important;font:700 12px/1.6 Tahoma,Arial,sans-serif!important;}
.cz-signup-agreement label{display:flex;align-items:center;gap:8px;cursor:pointer;}

body.cz-signup-body #content.signup p.btn{margin:15px 0 0!important;text-align:center!important;}
body.cz-signup-body #btn_signup.cz-signup-submit{
    width:260px!important;height:46px!important;margin:0!important;padding:0 20px!important;border:1px solid #d2aa34!important;border-radius:10px!important;
    color:#fff!important;background:linear-gradient(180deg,#0c7956,#054a36)!important;box-shadow:0 7px 15px rgba(7,88,63,.23)!important;
    cursor:pointer!important;text-indent:0!important;font:800 15px/1 Tahoma,Arial,sans-serif!important;
}

.cz-signup-notice{margin:15px 0 0!important;color:#a33a24!important;text-align:center!important;font:700 12px/1.6 Tahoma,Arial,sans-serif!important;}
.cz-signup-links{margin-top:17px;padding-top:15px;display:flex;justify-content:space-between;gap:15px;border-top:1px solid #e9debf;}
.cz-signup-links a{color:#087052!important;font:700 12px/1.5 Tahoma,Arial,sans-serif;text-decoration:none!important;}
.cz-signup-links a:hover{text-decoration:underline!important;}

body.cz-signup-body #content.signup ul.important{margin:5px 0!important;padding:0!important;list-style:none!important;color:#9a281c!important;text-align:right!important;}
.cz-signup-closed{text-align:center!important;min-height:260px!important;}

/* =========================================================
   City Zero v17 — الواجهة الرئيسية
   ========================================================= */
html:has(body.cz-home-body){scroll-behavior:smooth;direction:rtl!important;}

body.cz-home-body{
    min-width:1050px!important;margin:0!important;padding:0!important;color:#193b2d!important;background:#f4f0e5!important;
    font-family:Tahoma,Arial,sans-serif!important;direction:rtl!important;
}

.cz-home-page{min-height:100vh;overflow:hidden;}
.cz-home-header{position:relative;z-index:20;height:116px;border-bottom:1px solid rgba(226,188,66,.65);background:linear-gradient(180deg,#064934,#043527);box-shadow:0 8px 24px rgba(0,0,0,.23);}
.cz-home-header-inner{width:1200px;height:100%;margin:0 auto;display:flex;align-items:center;gap:28px;}
.cz-home-logo{width:300px;height:105px;display:flex;align-items:center;flex:0 0 300px;}
.cz-home-logo img{width:292px;max-height:100px;object-fit:contain;filter:drop-shadow(0 5px 6px rgba(0,0,0,.38));}
.cz-home-nav{display:flex;align-items:center;justify-content:center;gap:5px;flex:1;}
.cz-home-nav a{padding:11px 13px;border-radius:8px;color:#f8efd1!important;text-decoration:none!important;font:700 13px/1.3 Tahoma,Arial,sans-serif;}
.cz-home-nav a:hover{color:#f0ce5e!important;background:rgba(255,255,255,.07);}
.cz-home-account-actions{display:flex;align-items:center;gap:9px;}
.cz-home-account-actions a{min-width:105px;padding:11px 14px;box-sizing:border-box;border-radius:9px;text-align:center;text-decoration:none!important;font:800 13px/1.3 Tahoma,Arial,sans-serif;}
.cz-home-login{border:1px solid rgba(238,207,105,.58);color:#fff4ce!important;background:rgba(255,255,255,.05);}
.cz-home-signup{border:1px solid #f2d676;color:#193b2d!important;background:linear-gradient(180deg,#f4d86f,#d8a92b);box-shadow:0 4px 10px rgba(0,0,0,.22);}

.cz-home-hero{position:relative;min-height:665px;background:#173b2d url("../../../img/cityzero_bg.jpg") center/cover no-repeat;}
.cz-home-hero-overlay{position:absolute;inset:0;background:linear-gradient(90deg,rgba(5,31,23,.52),rgba(5,31,23,.3) 45%,rgba(4,29,22,.78));}
.cz-home-hero-inner{position:relative;z-index:2;width:1200px;margin:0 auto;padding:100px 0 90px;box-sizing:border-box;display:grid;grid-template-columns:1.35fr .65fr;gap:65px;align-items:center;}
.cz-home-hero-copy{color:#fff;text-shadow:0 2px 4px rgba(0,0,0,.32);}
.cz-home-kicker,.cz-home-section-heading>span,.cz-home-journey-copy>span{display:inline-block;margin-bottom:11px;color:#f3ce58;font:800 14px/1.5 Tahoma,Arial,sans-serif;}
.cz-home-hero h1{max-width:720px;margin:0 0 20px;color:#fff;font:900 47px/1.35 Tahoma,Arial,sans-serif;letter-spacing:-1px;}
.cz-home-hero-copy>p{max-width:700px;margin:0 0 29px;color:#e9eee8;font:600 17px/1.95 Tahoma,Arial,sans-serif;}
.cz-home-hero-actions{display:flex;gap:12px;margin-bottom:26px;}
.cz-home-hero-actions a{min-width:190px;padding:14px 22px;border-radius:10px;text-align:center;text-decoration:none!important;font:800 15px/1.4 Tahoma,Arial,sans-serif;}
.cz-home-cta{border:1px solid #f3d469;color:#173b2d!important;background:linear-gradient(180deg,#f8dc72,#d9aa2d);box-shadow:0 7px 16px rgba(0,0,0,.28);}
.cz-home-secondary{border:1px solid rgba(255,242,198,.55);color:#fff8dc!important;background:rgba(3,39,29,.58);}
.cz-home-hero-notes{display:flex;gap:21px;color:#e7f0e9;font:700 12px/1.5 Tahoma,Arial,sans-serif;}

.cz-home-server-card{padding:25px 27px 27px;border:1px solid rgba(237,206,105,.72);border-radius:18px;background:rgba(255,253,246,.96);box-shadow:0 20px 45px rgba(0,0,0,.32);}
.cz-home-live{display:flex;align-items:center;gap:8px;color:#087052;font:800 12px/1.4 Tahoma,Arial,sans-serif;}
.cz-home-live i{width:9px;height:9px;border-radius:50%;background:#2fc87f;box-shadow:0 0 0 5px rgba(47,200,127,.14);}
.cz-home-server-card h2{margin:13px 0 17px;color:#143e2e;font:800 19px/1.5 Tahoma,Arial,sans-serif;}
.cz-home-stat-list{border-top:1px solid #eadfbe;}
.cz-home-stat-list>div{min-height:53px;display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid #eadfbe;}
.cz-home-stat-list span{color:#607066;font:700 12px/1.4 Tahoma,Arial,sans-serif;}
.cz-home-stat-list strong{color:#a57613;font:900 21px/1 Arial,sans-serif;direction:ltr;}
.cz-home-server-card>a{display:block;margin-top:19px;padding:12px;border-radius:9px;color:#fff!important;background:linear-gradient(180deg,#0b7553,#064b37);text-align:center;text-decoration:none!important;font:800 14px/1.4 Tahoma,Arial,sans-serif;}

.cz-home-features{padding:76px 20px 84px;background:linear-gradient(180deg,#fffdf7,#f3eddd);}
.cz-home-section-heading{max-width:760px;margin:0 auto 38px;text-align:center;}
.cz-home-section-heading h2{margin:0 0 12px;color:#10442f;font:900 30px/1.45 Tahoma,Arial,sans-serif;}
.cz-home-section-heading p{margin:0;color:#69766e;font:600 14px/1.8 Tahoma,Arial,sans-serif;}
.cz-home-feature-grid{width:1200px;margin:0 auto;display:grid;grid-template-columns:repeat(4,1fr);gap:17px;}
.cz-home-feature-grid article{padding:25px 22px 27px;border:1px solid #dfd1aa;border-radius:15px;background:#fff;box-shadow:0 8px 21px rgba(47,58,42,.08);text-align:right;transition:transform .18s ease,box-shadow .18s ease;}
.cz-home-feature-grid article:hover{transform:translateY(-5px);box-shadow:0 14px 28px rgba(30,65,47,.14);}
.cz-home-feature-icon{width:50px;height:50px;margin-bottom:16px;display:flex;align-items:center;justify-content:center;border:1px solid #e0be51;border-radius:13px;color:#f2cf5c;background:linear-gradient(180deg,#0d6d4e,#064632);font:800 25px/1 Arial,sans-serif;}
.cz-home-feature-grid h3{margin:0 0 8px;color:#114832;font:800 17px/1.4 Tahoma,Arial,sans-serif;}
.cz-home-feature-grid p{margin:0;color:#67736c;font:600 12px/1.8 Tahoma,Arial,sans-serif;}

.cz-home-journey{width:1200px;margin:70px auto;display:grid;grid-template-columns:1fr 1fr;gap:70px;align-items:center;padding:48px 58px;box-sizing:border-box;border:1px solid #d9bd64;border-radius:20px;background:linear-gradient(135deg,#0b5c43,#063d2e);box-shadow:0 17px 38px rgba(26,57,42,.18);}
.cz-home-journey-copy h2{margin:0 0 13px;color:#fff;font:900 29px/1.45 Tahoma,Arial,sans-serif;}
.cz-home-journey-copy p{margin:0 0 23px;color:#dce8e1;font:600 14px/1.9 Tahoma,Arial,sans-serif;}
.cz-home-journey-copy a{display:inline-block;padding:12px 21px;border-radius:9px;color:#173b2d!important;background:linear-gradient(180deg,#f4d86f,#d8aa2c);text-decoration:none!important;font:800 13px/1.4 Tahoma,Arial,sans-serif;}
.cz-home-steps{display:grid;gap:12px;}
.cz-home-steps>div{display:flex;align-items:center;gap:15px;padding:13px 15px;border:1px solid rgba(236,207,111,.25);border-radius:11px;background:rgba(255,255,255,.06);}
.cz-home-steps b{width:42px;color:#f0cc58;font:900 20px/1 Arial,sans-serif;direction:ltr;}
.cz-home-steps span{display:flex;flex-direction:column;gap:4px;}
.cz-home-steps strong{color:#fff;font:800 13px/1.4 Tahoma,Arial,sans-serif;}
.cz-home-steps small{color:#cbdad2;font:600 11px/1.4 Tahoma,Arial,sans-serif;}

.cz-home-footer{border-top:1px solid #c99e31;background:#052f24;color:#dae5df;}
.cz-home-footer-inner{width:1200px;min-height:175px;margin:0 auto;display:grid;grid-template-columns:1fr 1fr 1fr;align-items:center;gap:30px;}
.cz-home-footer img{width:235px;height:82px;object-fit:contain;filter:drop-shadow(0 4px 5px rgba(0,0,0,.32));}
.cz-home-footer p{margin:3px 0 0;color:#aebfb6;font:600 11px/1.6 Tahoma,Arial,sans-serif;}
.cz-home-footer nav{display:flex;flex-wrap:wrap;justify-content:center;gap:11px 19px;}
.cz-home-footer nav a{color:#f0ddb0!important;text-decoration:none!important;font:700 12px/1.5 Tahoma,Arial,sans-serif;}
.cz-home-copyright{text-align:left!important;line-height:1.9!important;}
