/* بطاقات MAC ونافذة نتائجها فقط؛ لا تغيير لأبعاد الشبكة أو منطق الفحص. */
html[data-theme] body[data-tool=mac] :is(.device-tool[data-service-identity],#checker-dialog[data-service-identity]){
 --mac-surface:#fff;--mac-bottom:#fbf9f5;--mac-input:#ffffffed;--mac-ink:var(--ui-text);--mac-soft:var(--ui-soft);--mac-line:color-mix(in srgb,var(--mac-brand) 42%,var(--ui-line));--mac-wash:color-mix(in srgb,var(--mac-brand) 11%,transparent);--mac-watermark:.13;--mac-shadow:0 5px 12px #263a5015;
}
html[data-theme=dark] body[data-tool=mac] :is(.device-tool[data-service-identity],#checker-dialog[data-service-identity]){
 --mac-surface:#11161d;--mac-bottom:#0d1118;--mac-input:#1b2430ed;--mac-ink:#f2f4f7;--mac-soft:#bec8d3;--mac-line:color-mix(in srgb,var(--mac-brand) 76%,#3b414a);--mac-wash:color-mix(in srgb,var(--mac-brand) 18%,transparent);--mac-watermark:.27;--mac-shadow:0 5px 0 #080c1266,0 10px 24px #0004;
}
html[data-theme] body[data-tool=mac] :where(.device-tool,#checker-dialog,.mac-service-nav a)[data-service-identity=mango]{--mac-brand:#e7b965;--mac-button-start:#f8d37b;--mac-button-end:#e7af4c;--mac-on-brand:#2c200d;--mac-art:url('../images/mac-services/mango.png');--mac-art-aspect:88/75;--mac-art-position:left center;}
html[data-theme] body[data-tool=mac] :where(.device-tool,#checker-dialog,.mac-service-nav a)[data-service-identity=hot]{--mac-brand:#f08540;--mac-button-start:#ffa855;--mac-button-end:#f07b36;--mac-on-brand:#2b180e;--mac-art:url('../images/mac-services/hot-symbol.svg');--mac-art-aspect:1;--mac-art-position:center;}
html[data-theme] body[data-tool=mac] :where(.device-tool,#checker-dialog,.mac-service-nav a)[data-service-identity=ibo]{--mac-brand:#bf232e;--mac-button-start:#c82d38;--mac-button-end:#a51d29;--mac-on-brand:#fff;--mac-art:url('../images/mac-services/ibo-sol.png');--mac-art-aspect:1;--mac-art-position:center;}
html[data-theme] body[data-tool=mac] :where(.device-tool,#checker-dialog,.mac-service-nav a)[data-service-identity=ora]{--mac-brand:#ed2939;--mac-button-start:#d82738;--mac-button-end:#b41c2d;--mac-on-brand:#fff;--mac-art:url('../images/mac-services/ora.png');--mac-art-aspect:75/42;--mac-art-position:right center;}

html[data-theme] body[data-tool=mac] [data-tool-layout] .device-tool[data-service-identity],
html[data-theme] body[data-tool=mac] #checker-dialog[data-service-identity]{
 position:relative;isolation:isolate;border-color:var(--mac-line);background:radial-gradient(ellipse at 100% 18%,var(--mac-wash),transparent 66%),linear-gradient(155deg,var(--mac-surface),var(--mac-bottom));box-shadow:inset 0 1px 0 #ffffff50,inset 0 -2px 0 #0000000a,var(--mac-shadow);color:var(--mac-ink);
}
html[data-theme] body[data-tool=mac] [data-tool-layout] .device-tool[data-service-identity]{overflow:hidden;transition:border-color 180ms ease,box-shadow 180ms ease;}
html[data-theme] body[data-tool=mac] :where(.device-tool,#checker-dialog)[data-service-identity]::before{
 content:'';position:absolute;inset:0;z-index:-1;pointer-events:none;border-radius:inherit;background:linear-gradient(153deg,transparent 27%,var(--mac-wash) 57%,transparent 76%);box-shadow:inset 0 0 0 1px #ffffff08;
}
html[data-theme] body[data-tool=mac] :where(.device-tool,#checker-dialog)[data-service-identity]::after{
 content:'';position:absolute;z-index:-1;pointer-events:none;right:-8px;bottom:78px;width:min(68%,240px);aspect-ratio:var(--mac-art-aspect);opacity:var(--mac-watermark);background:linear-gradient(145deg,var(--mac-brand),transparent 88%);-webkit-mask-image:var(--mac-art);mask-image:var(--mac-art);-webkit-mask-size:auto 100%;mask-size:auto 100%;-webkit-mask-position:var(--mac-art-position);mask-position:var(--mac-art-position);-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;filter:drop-shadow(1px 1px 0 #0008);transform:rotate(-7deg);
}
/* الألوان الداخلية الأصلية تحفظ موجة Mango وتفاصيل شعلة HOT في النقش. */
html[data-theme] body[data-tool=mac] :where(.device-tool,#checker-dialog)[data-service-identity=mango]::after,
html[data-theme] body[data-tool=mac] :where(.device-tool,#checker-dialog)[data-service-identity=hot]::after{background-image:var(--mac-art);background-size:auto 100%;background-position:var(--mac-art-position);background-repeat:no-repeat;-webkit-mask-image:none;mask-image:none;}
html[data-theme] body[data-tool=mac] :where(.device-tool,#checker-dialog)[data-service-identity=mango]::after{filter:sepia(1) saturate(1.25) drop-shadow(1px 1px 0 #0008);}
/* طرح إضاءة PNG يزيل بياض الخلفية من العلامة المائية فقط، دون تعديل الأصل. */
html[data-theme] body[data-tool=mac] :where(.device-tool,#checker-dialog)[data-service-identity=ibo]::after{
 -webkit-mask-image:linear-gradient(#fff,#fff),var(--mac-art);mask-image:linear-gradient(#fff,#fff),var(--mac-art);mask-mode:alpha,luminance;-webkit-mask-size:100% 100%,100% 100%;mask-size:100% 100%,100% 100%;-webkit-mask-position:center;mask-position:center;-webkit-mask-composite:source-out;mask-composite:subtract;
}
html[data-theme] body[data-tool=mac] [data-tool-layout] .device-tool>h2{border-bottom-color:color-mix(in srgb,var(--mac-brand) 18%,var(--ui-line-soft));}
html[data-theme] body[data-tool=mac] .device-tool .mac-service-mark{
 width:44px;flex-basis:44px;height:36px;overflow:hidden;border-color:var(--mac-line);background:linear-gradient(145deg,var(--mac-wash),var(--mac-surface));box-shadow:inset 0 1px #ffffff35,0 2px 5px #0002;border-radius:9px;
}
html[data-theme] body[data-tool=mac] .mac-service-mark img{display:block;width:32px;height:32px;object-fit:contain;max-width:none;}
html[data-theme] body[data-tool=mac] [data-service-identity=mango] .mac-service-mark img{width:44px;height:36px;object-fit:cover;object-position:left;}
html[data-theme] body[data-tool=mac] [data-service-identity=ora] .mac-service-mark img{width:44px;height:24px;object-fit:cover;object-position:right;}
html[data-theme] body[data-tool=mac] [data-service-identity=ibo] .mac-service-mark{background:#f2e7e8;}
html[data-theme] body[data-tool=mac] [data-service-identity=ibo] .mac-service-mark img{mix-blend-mode:multiply;}
html[data-theme] body[data-tool=mac] .device-tool .mac-service-name{color:var(--mac-ink);}
html[data-theme] body[data-tool=mac] .device-tool .mac-input-type{border-color:var(--mac-line);color:var(--mac-soft);background:var(--mac-wash);}
html[data-theme] body[data-tool=mac] .device-tool :is(.mac-tool-description,.form-field,.hint){color:var(--mac-soft);}
html[data-theme] body[data-tool=mac] .device-tool :is(input,select){color:var(--mac-ink);background:var(--mac-input);border-color:color-mix(in srgb,var(--mac-brand) 26%,var(--ui-line));box-shadow:inset 0 2px 3px #00000018;}
html[data-theme] body[data-tool=mac] .device-tool :is(input,select):focus-visible{outline:2px solid var(--mac-brand);outline-offset:3px;border-color:var(--mac-brand);}
html[data-theme] body[data-tool=mac] :is(.device-tool .form-actions [type=submit],#checker-dialog #checker-close){
 color:var(--mac-on-brand);background:linear-gradient(125deg,var(--mac-button-start),var(--mac-button-end));border-color:color-mix(in srgb,var(--mac-button-start) 75%,#fff);box-shadow:inset 0 1px #ffffff45,0 2px 5px #0002;
}
html[data-theme] body[data-tool=mac] .device-tool .form-actions [type=reset]{color:var(--mac-ink);background:var(--mac-input);border-color:var(--ui-line);box-shadow:inset 0 1px #ffffff15,0 2px 4px #0001;}
html[data-theme] body[data-tool=mac] .device-tool .device-status{border-inline-start-color:var(--mac-line);background:color-mix(in srgb,var(--mac-surface) 87%,transparent);box-shadow:inset 0 1px color-mix(in srgb,var(--mac-brand) 23%,var(--ui-line-soft));color:var(--mac-soft);}
html[data-theme] body[data-tool=mac] .device-tool .device-status[data-mood=bad]{color:var(--ui-danger);border-inline-start-color:var(--ui-danger);}
html[data-theme] body[data-tool=mac] .device-tool .device-status[data-mood=ok]{color:var(--ui-success);border-inline-start-color:var(--ui-success);}
@media(hover:hover){
 html[data-theme] body[data-tool=mac] [data-tool-layout] .device-tool[data-service-identity]:hover{transform:none;border-color:var(--mac-brand);box-shadow:inset 0 1px #ffffff40,0 4px 13px #00000024;}
 html[data-theme] body[data-tool=mac] :is(.device-tool .form-actions .btn,#checker-close):not(:disabled):hover{filter:brightness(1.04);transform:translateY(-1px);}
}

/* النافذة الأصلية تحتفظ بكل البيانات والأزرار ومعالجة الفحص نفسها. */
html[data-theme] body[data-tool=mac] #checker-dialog[data-service-identity]{
 position:fixed;inset:0;margin:auto;overflow:auto;overscroll-behavior:contain;scrollbar-gutter:stable;opacity:0;transform:translateY(5px) scale(.99);transition:opacity 160ms ease,transform 160ms ease,display 160ms allow-discrete,overlay 160ms allow-discrete;
}
html[data-theme] body[data-tool=mac] #checker-dialog[data-service-identity][open]{opacity:1;transform:none;}
html[data-theme] body[data-tool=mac] #checker-dialog::backdrop{background:#07101bc2;opacity:0;transition:opacity 160ms ease,display 160ms allow-discrete,overlay 160ms allow-discrete;}
html[data-theme] body[data-tool=mac] #checker-dialog[open]::backdrop{opacity:1;}
@starting-style{
 html[data-theme] body[data-tool=mac] #checker-dialog[data-service-identity][open]{opacity:0;transform:translateY(5px) scale(.99);}
 html[data-theme] body[data-tool=mac] #checker-dialog[open]::backdrop{opacity:0;}
}
html[data-theme] body[data-tool=mac] #checker-dialog::after{bottom:70px;width:min(58%,260px);opacity:calc(var(--mac-watermark)*.45);}
html[data-theme] body[data-tool=mac] #checker-dialog-title{display:flex;align-items:center;gap:12px;padding-inline-end:30px;font-size:20px;line-height:1.6;color:var(--mac-ink);overflow-wrap:anywhere;}
html[data-theme] body[data-tool=mac] #checker-dialog-title::before{
 content:'';display:block;flex:0 0 44px;width:44px;height:36px;border:1px solid var(--mac-line);border-radius:8px;background-color:var(--mac-wash);background-image:var(--mac-art);background-size:32px 32px;background-repeat:no-repeat;background-position:center;box-shadow:inset 0 1px #ffffff25;
}
html[data-theme] body[data-tool=mac] #checker-dialog[data-service-identity=mango] #checker-dialog-title::before{background-size:auto 36px;background-position:left center;}
html[data-theme] body[data-tool=mac] #checker-dialog[data-service-identity=ora] #checker-dialog-title::before{background-size:auto 24px;background-position:right center;}
html[data-theme] body[data-tool=mac] #checker-dialog[data-service-identity=ibo] #checker-dialog-title::before{background-color:#f2e7e8;background-blend-mode:multiply;}
html[data-theme] body[data-tool=mac] #checker-dialog-dismiss{position:absolute;inset-block-start:12px;inset-inline-end:12px;z-index:2;width:36px;height:36px;min-width:36px;min-height:36px;padding:0;border:1px solid var(--ui-line);border-radius:8px;background:var(--mac-input);color:var(--mac-ink);cursor:pointer;}
html[data-theme] body[data-tool=mac] #checker-dialog-dismiss:is(:hover,:focus-visible){border-color:var(--mac-brand);outline-color:var(--mac-brand);}
html[data-theme] body[data-tool=mac] #checker-dialog-status{padding:10px 12px;border:1px solid var(--ui-line-soft);border-inline-start:3px solid var(--mac-line);border-radius:8px;background:var(--mac-input);color:var(--mac-soft);font-size:13px;line-height:1.85;overflow-wrap:anywhere;}
html[data-theme] body[data-tool=mac] #checker-dialog[data-result-mood=bad] #checker-dialog-status{color:var(--ui-danger);border-inline-start-color:var(--ui-danger);background:var(--ui-danger-bg);}
html[data-theme] body[data-tool=mac] #checker-dialog[data-result-mood=ok] #checker-dialog-status{color:var(--ui-success);border-inline-start-color:var(--ui-success);background:var(--ui-success-bg);}
html[data-theme] body[data-tool=mac] #checker-dialog .result-identity{padding:8px 10px;border:1px solid var(--ui-line-soft);border-radius:7px;background:var(--mac-input);font-variant-numeric:tabular-nums;}
html[data-theme] body[data-tool=mac] #checker-dialog .mac-result-body{color:var(--mac-ink);}
html[data-theme] body[data-tool=mac] #checker-dialog .device-result-table{background:var(--mac-input);border-color:var(--mac-line);}
html[data-theme] body[data-tool=mac] #checker-dialog .device-result-table th{color:var(--mac-soft);background:var(--mac-wash);}
html[data-theme] body[data-tool=mac] #checker-dialog .device-result-table td{color:var(--mac-ink);background:transparent;}
html[data-theme] body[data-tool=mac] #checker-dialog .mac-result-details{grid-template-columns:minmax(0,.7fr) minmax(0,1.3fr);gap:7px 12px;padding-block:8px;border-block:1px solid var(--ui-line-soft);}
html[data-theme] body[data-tool=mac] #checker-dialog .mac-result-details :is(dt,dd){min-width:0;overflow-wrap:anywhere;}
html[data-theme] body[data-tool=mac] :is(#checker-dialog,.mac-inline-result) .mac-badge[data-mood=ok]{color:var(--ui-success);background:var(--ui-success-bg);}
html[data-theme] body[data-tool=mac] :is(#checker-dialog,.mac-inline-result) .mac-badge[data-mood=bad]{color:var(--ui-danger);background:var(--ui-danger-bg);}
html[data-theme] body[data-tool=mac] :is(#checker-dialog,.mac-inline-result) .mac-badge[data-mood=warn]{color:var(--ui-warning);background:var(--ui-warning-bg);}
html[data-theme] body[data-tool=mac] #checker-dialog>.form-actions{gap:10px;padding-top:14px;margin-top:18px;border-top:1px solid var(--ui-line-soft);}
@media(max-width:600px){html[data-theme] body[data-tool=mac] #checker-dialog{padding:18px;}html[data-theme] body[data-tool=mac] #checker-dialog-title{font-size:18px;gap:8px;}html[data-theme] body[data-tool=mac] #checker-dialog>.form-actions .btn{flex:1;min-height:44px;}}
@media(prefers-reduced-motion:reduce){
 html[data-theme] body[data-tool=mac] :where(.device-tool,#checker-dialog),html[data-theme] body[data-tool=mac] #checker-dialog::backdrop{transition:none!important;animation:none!important;transform:none!important;}
}

/* شريط الخدمات: الشعارات والألوان فقط، مع الحفاظ على الروابط والأعمدة والأبعاد. */
html[data-theme] body[data-tool=mac] .mac-service-nav a{gap:8px;transition:background-color 160ms ease,border-color 160ms ease,color 160ms ease;}
html[data-theme] body[data-tool=mac] .mac-service-nav .mac-service-index{display:inline-flex;align-items:center;gap:5px;flex-shrink:0;font-variant-numeric:tabular-nums;}
html[data-theme] body[data-tool=mac] .mac-service-nav .mac-service-index img{display:block;width:22px;height:22px;max-width:none;object-fit:contain;}
html[data-theme] body[data-tool=mac] .mac-service-nav [data-service-identity=mango] img{width:24px;height:20px;object-fit:cover;object-position:left;}
html[data-theme] body[data-tool=mac] .mac-service-nav [data-service-identity=ibo] img{padding:2px;border-radius:5px;background:#f2e7e8;}
html[data-theme] body[data-tool=mac] .mac-service-nav [data-service-identity=ora] img{width:28px;height:16px;object-fit:cover;object-position:right;}
html[data-theme] body[data-tool=mac] .mac-service-nav a:is(:hover,[aria-current=location]){color:var(--mac-brand);background:color-mix(in srgb,var(--mac-brand) 12%,var(--ui-panel));border-color:color-mix(in srgb,var(--mac-brand) 40%,var(--ui-line));box-shadow:inset 0 1px #ffffff20;transform:none;}
html[data-theme=light] body[data-tool=mac] .mac-service-nav [data-service-identity=mango]:is(:hover,[aria-current=location]){color:#87601d;}
html[data-theme=light] body[data-tool=mac] .mac-service-nav [data-service-identity=hot]:is(:hover,[aria-current=location]){color:#a84a16;}
html[data-theme] body[data-tool=mac] .mac-service-nav a::after{background:var(--mac-brand);}
html[data-theme] body[data-tool=mac] .mac-service-nav a:focus-visible{outline:2px solid var(--mac-brand);outline-offset:2px;}
@media(prefers-reduced-motion:reduce){html[data-theme] body[data-tool=mac] .mac-service-nav a{transition:none;}}

html[data-theme=dark] body[data-tool=mac] .mac-service-nav a:is(:hover,[aria-current=location]){color:color-mix(in srgb,var(--mac-brand) 64%,#fff);}
html[data-theme=light] body[data-tool=mac] .mac-service-nav [data-service-identity=ora]:is(:hover,[aria-current=location]){color:#b61d2c;}
