/* DL Section Shell (theme 3.86): see inc/section-shell.php and assets/js/section-shell.js.
   Logical properties only, so the same file serves Arabic RTL and English LTR (no -ltr twin).
   Colours come from the theme variables (green accent #41C48D = --nb-yellow, ink, cream, paper, line). */
:root { --dlsh-off: 0px; --dlsh-topH: 48px; }
.dlsh { display: contents; font-family: inherit; } /* contents: the sticky bar then lives in <main>, so it stays while the whole page scrolls */
.dlsh svg { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* 1. breadcrumb bar (sticky under the site header) */
.dlsh-top {
	position: sticky; top: var(--dlsh-off); z-index: 45; min-height: 48px; box-sizing: border-box;
	display: flex; align-items: center; gap: 8px; padding: 6px 14px;
	background: var(--nb-paper, #fff); color: var(--ink, #111); border-block-end: 3px solid var(--nb-b, #0D0D0D);
}
.dlsh-crumbs { display: flex; align-items: center; gap: 7px; min-width: 0; flex: 1; font-weight: 700; font-size: 13px; white-space: nowrap; overflow: hidden; }
.dlsh-crumbs a { display: inline-flex; align-items: center; gap: 5px; color: var(--muted, #5B5B52); text-decoration: none; }
.dlsh-crumbs a svg { width: 15px; height: 15px; }
.dlsh-sep { color: var(--muted, #5B5B52); opacity: .7; }
.dlsh-grp { display: inline-flex; align-items: center; gap: 5px; }
.dlsh-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--nb-yellow, #41C48D); border: 2px solid var(--nb-b, #0D0D0D); flex: none; }
.dlsh-cur { overflow: hidden; text-overflow: ellipsis; min-width: 0; font-weight: 800; }
.dlsh-compact { display: none; align-items: center; gap: 8px; min-width: 0; flex: 1; font-weight: 800; font-size: 14px; }
.dlsh-cname { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dlsh-top.is-compact .dlsh-crumbs { display: none; }
.dlsh-top.is-compact .dlsh-compact { display: flex; }
.dlsh-tb {
	flex: none; display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 32px; min-width: 32px; padding: 0 10px; box-sizing: border-box;
	font: 800 12px/1 inherit; font-family: inherit; color: var(--ink, #111); background: var(--nb-paper, #fff); text-decoration: none; cursor: pointer;
	border: 2px solid var(--nb-b, #0D0D0D); border-radius: 8px; box-shadow: 2px 2px 0 var(--nb-s, #0D0D0D);
}
.dlsh-tb svg { width: 15px; height: 15px; }
.dlsh-search { min-width: 130px; justify-content: flex-start; color: var(--muted, #5B5B52); font-weight: 600; }
.dlsh-tb:hover { background: var(--nb-yellow, #41C48D); color: #0D0D0D; }
.dlsh-tb:focus-visible, .dlsh-btn:focus-visible, .dlsh-fav:focus-visible, .dlsh-rc:focus-visible, .dlsh-pn-a:focus-visible { outline: 3px solid var(--nb-yellow, #41C48D); outline-offset: 2px; }

/* the icon tile (also used by related cards) */
.dlsh-ico { display: inline-grid; place-items: center; flex: none; width: 28px; height: 28px; border-radius: 6px; background: var(--nb-yellow, #41C48D); color: #0D0D0D; }
.dlsh-ico svg { width: 62%; height: 62%; stroke-width: 2; }
.dlsh-ico-big { width: 54px; height: 54px; border-radius: 12px; border: 3px solid #fff; box-shadow: 3px 3px 0 rgba(255, 255, 255, .35); }

/* 2. compact header: everything centred (3.87) */
.dlsh-hd { background: #0D0D0D; color: #fff; padding: 20px 16px 22px; }
.dlsh-hd-in { max-width: 860px; margin-inline: auto; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 8px; }
.dlsh-main { min-width: 0; display: flex; flex-direction: column; align-items: center; gap: 6px; }
.dlsh-title { margin: 0; font-size: 22px; line-height: 1.3; font-weight: 800; color: #fff; text-wrap: balance; text-align: center; }
.dlsh-stats { max-width: 860px; margin: 14px auto 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.dlsh-stats:empty { display: none; }
.dlsh-stat { display: inline-flex; align-items: baseline; gap: 6px; padding: 3px 12px; font-size: 12px; color: #d8d8d0; border: 2px solid rgba(255, 255, 255, .35); border-radius: 8px; }
.dlsh-stat b { font-size: 17px; color: #fff; font-variant-numeric: tabular-nums; }
.dlsh-cta { display: flex; justify-content: center; gap: 8px; flex-wrap: wrap; }
.dlsh-cta:not(:has(.dlsh-btn:not([hidden]))) { display: none; }
.dlsh-btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; padding: 6px 16px; font: 800 14px/1.5 inherit; font-family: inherit; text-decoration: none; border: 3px solid #0D0D0D; border-radius: 10px; cursor: pointer; }
.dlsh-hd .dlsh-s { background: transparent; color: #fff; border-color: rgba(255, 255, 255, .55); margin-block-start: 6px; }
.dlsh-hd .dlsh-btn[hidden] { display: none; }

/* 3. the plugin's own tab strip, attached under the shell (class set by JS) */
html body .dlsh-tabs.dlsh-tabs {
	position: sticky !important; top: calc(var(--dlsh-off, 0px) + var(--dlsh-topH, 48px)) !important; z-index: 40; box-sizing: border-box; margin-inline: 0 !important; padding-inline: 12px; padding-block: 8px;
	background: var(--nb-cream, #FAF4E6); border-block-start: 0; border-block-end: 3px solid var(--nb-b, #0D0D0D); box-shadow: none; margin-block: 0; border-radius: 0;
}
html body .dlsh-tabs-row.dlsh-tabs-row { flex-wrap: nowrap !important; overflow-x: auto !important; scrollbar-width: none; justify-content: flex-start !important; -webkit-overflow-scrolling: touch; }
html body .dlsh-tabs-row::-webkit-scrollbar { display: none; }
html body .dlsh-tabs-row.dlsh-tabs-row > * { flex: none; white-space: nowrap; }

/* plugin hero replaced by the shell header: hide everything in it except form controls (search boxes etc.) */
html body .dlsh-hero-x { display: none !important; }
html body .dlsh-hide { display: none !important; }
html body .dlsh-hero-slim { min-height: 0 !important; padding: 0 16px 20px !important; margin: 0 !important; background: #0D0D0D !important; color: #fff !important; border-radius: 0 !important; box-shadow: none !important; border: 0 !important; }
html body .dlsh-hero-slim input, html body .dlsh-hero-slim textarea, html body .dlsh-search-fix { unicode-bidi: plaintext; text-align: start; }
html body .dlsh-hero-slim::before, html body .dlsh-hero-slim::after { display: none; }

/* 5. footer */
.dlsh-ft { background: var(--nb-paper, #fff); color: var(--ink, #111); border-block: 3px solid var(--nb-b, #0D0D0D); padding: 18px 16px 22px; margin-block-start: 24px; }
.dlsh-ft > * { max-width: 1180px; margin-inline: auto; }
.dlsh-ft-h { margin-block: 0 10px; font-size: 15px; font-weight: 800; }
.dlsh-rel { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.dlsh-rc {
	display: flex; align-items: center; gap: 10px; min-width: 0; padding: 10px 12px; text-decoration: none; color: inherit;
	background: var(--nb-cream, #FAF4E6); border: 3px solid var(--nb-b, #0D0D0D); border-radius: 10px; box-shadow: 3px 3px 0 var(--nb-s, #0D0D0D);
}
.dlsh-rc .dlsh-ico { width: 36px; height: 36px; border-radius: 8px; border: 2px solid var(--nb-b, #0D0D0D); }
.dlsh-rc-t { min-width: 0; }
.dlsh-rc b { display: block; font-size: 13.5px; line-height: 1.35; }
.dlsh-rc small { color: var(--muted, #5B5B52); font-weight: 600; font-size: 11.5px; }
.dlsh-pn { display: flex; gap: 8px; margin-block-start: 14px; align-items: stretch; }
.dlsh-pn-a { flex: 1; min-width: 0; display: block; padding: 7px 12px; text-decoration: none; color: inherit; font: 700 13px/1.35 inherit; font-family: inherit; background: var(--nb-paper, #fff); border: 2px solid var(--nb-b, #0D0D0D); border-radius: 10px; }
.dlsh-pn-a small { display: block; color: var(--muted, #5B5B52); font-weight: 600; font-size: 11px; }
.dlsh-pn-a.is-off { opacity: .4; }
.dlsh-pn-a:hover { background: var(--nb-yellow, #41C48D); color: #0D0D0D; }
.dlsh-pn-a:hover small { color: #0D0D0D; }
.dlsh-favwrap { flex: none; display: flex; }
.dlsh-favwrap .drawer-item { display: none; }
.dlsh-fav { display: flex; align-items: center; gap: 6px; padding: 0 14px; font: 700 13px/1.35 inherit; font-family: inherit; color: var(--ink, #111); background: var(--nb-cream, #FAF4E6); border: 2px solid var(--nb-b, #0D0D0D); border-radius: 10px; cursor: pointer; }
.dlsh-fav svg { width: 17px; height: 17px; stroke: currentColor; fill: none; }
.dlsh-fav[aria-pressed="true"] { background: var(--nb-yellow, #41C48D); color: #0D0D0D; box-shadow: 3px 3px 0 var(--nb-s, #0D0D0D); }
.dlsh-fav[aria-pressed="true"] svg { fill: #0D0D0D; }

/* dark mode: the paper/cream variables already flip; keep the hero-style black blocks readable */
html[data-theme="dark"] .dlsh-hd { background: #050505; border-block-end: 3px solid var(--nb-yellow, #41C48D); }

/* phones */
@media (max-width: 700px) {
	.dlsh-title { font-size: 19px; }
	.dlsh-search span { display: none; }
	.dlsh-search { min-width: 32px; padding: 0; }
	.dlsh-grp, .dlsh-sep-g { display: none; }
	.dlsh-rel { grid-template-columns: minmax(0, 1fr); }
	.dlsh-pn { flex-wrap: wrap; }
	.dlsh-favwrap { order: -1; flex-basis: 100%; }
	.dlsh-fav { flex: 1; justify-content: center; padding-block: 7px; }
}
@media print { .dlsh-top, .dlsh-ft { display: none; } }

html body .dlsh .dlsh-desc { text-align: center !important; max-width: 720px !important; width: auto !important; margin-inline: auto !important; }

/* Arabic-safe search fields everywhere in a section (typed Arabic or English keeps its own direction) */
html body .has-dlsh input[type="search"], html body .has-dlsh input[type="text"][placeholder] { unicode-bidi: plaintext; text-align: start; }

/* the plugin's tab strip: the enhanced look (3.87). JS marks every tab with .dlsh-tab and the current one with .dlsh-tab-on */
html body .dlsh-tab { border: 2px solid var(--nb-b, #0D0D0D) !important; border-radius: 8px !important; background: var(--nb-paper, #fff) !important; color: var(--ink, #111) !important; box-shadow: none !important; font-weight: 700; text-decoration: none; }
html body .dlsh-tab.dlsh-tab-on { background: #0D0D0D !important; color: #fff !important; box-shadow: 3px 3px 0 var(--nb-yellow, #41C48D) !important; }
html body .dlsh-tab:hover:not(.dlsh-tab-on) { background: var(--nb-yellow, #41C48D) !important; color: #0D0D0D !important; }
html body .dlsh-tabs.dlsh-tabs { background: var(--nb-cream, #FAF4E6) !important; border-radius: 0 !important; border-inline: 0 !important; border-block-start: 0 !important; box-shadow: none !important; }

/* inner (second level) tab bars inside a section: same style */
html body .dlsh-sub { display: flex !important; flex-wrap: nowrap; gap: 6px; overflow-x: auto; scrollbar-width: none; padding: 8px !important; margin-block: 12px !important; background: var(--nb-paper, #fff) !important; border: 3px solid var(--nb-b, #0D0D0D) !important; border-radius: 10px !important; box-shadow: 4px 4px 0 var(--nb-s, #0D0D0D) !important; }
html body .dlsh-sub::-webkit-scrollbar { display: none; }
html body .dlsh-sub > * { flex: none; white-space: nowrap; }

/* 3.88: the current tab keeps readable text whatever the plugin set inside it; search sits under the strip */
html body .dlsh-tab.dlsh-tab-on, html body .dlsh-tab.dlsh-tab-on * { color: #fff !important; }
html body .dlsh-tab:hover:not(.dlsh-tab-on), html body .dlsh-tab:hover:not(.dlsh-tab-on) * { color: #0D0D0D !important; }
html body .dlsh-moved-search { display: flex; width: auto; max-width: 720px; margin: 12px auto !important; box-sizing: border-box; }

/* 3.89 animated header art (see dlar_shell_arts() in inc/section-shell.php). Colours: ink lines on the green tile, white accents. */
.dlsh-ico-big.dlsh-has-art { width: 96px; height: 96px; border-radius: 18px; background: var(--nb-yellow, #41C48D); }
.dlsh-ico-big.dlsh-has-art svg.dlsh-art { width: 86%; height: 86%; stroke: #0D0D0D; stroke-width: 2; overflow: visible; }
.dlsh-art .f { fill: #fff; } .dlsh-art .b, .dlsh-art .bk { fill: rgba(255, 255, 255, .55); }
/* no-code */
.dlsh-art-nc .l { stroke-dasharray: 3 3; animation: dlshFlow 1.2s linear infinite; }
.dlsh-art-nc .dot { fill: #0D0D0D; stroke: #fff; stroke-width: 1.5; offset-rotate: 0deg; opacity: 0; }
.dlsh-art-nc .d1 { offset-path: path("M26 15C33 15 31 32 38 32"); animation: dlshTravel 2.4s ease-in-out infinite; }
.dlsh-art-nc .d2 { offset-path: path("M26 49C33 49 31 32 38 32"); animation: dlshTravel 2.4s ease-in-out infinite .5s; }
.dlsh-art-nc .res { transform-box: fill-box; transform-origin: center; animation: dlshPop 2.4s ease-in-out infinite; }
.dlsh-art-nc .ck { stroke-dasharray: 20; animation: dlshDraw 2.4s ease-in-out infinite; }
.dlsh-art-nc .b1 { animation: dlshNudge 2.4s ease-in-out infinite; } .dlsh-art-nc .b3 { animation: dlshNudge 2.4s ease-in-out infinite .5s; }
/* frameworks */
.dlsh-art-fw .pull { transform-box: fill-box; transform-origin: bottom center; animation: dlshPull 3.2s ease-in-out infinite; }
.dlsh-art-fw .code { stroke-dasharray: 40; animation: dlshCode 3.2s ease-in-out infinite; }
/* architectures */
.dlsh-art-arch .l { stroke-width: 1; opacity: .35; }
.dlsh-art-arch .n circle { fill: rgba(255, 255, 255, .5); transform-box: fill-box; transform-origin: center; animation: dlshFire 2.4s ease-in-out infinite; }
.dlsh-art-arch .c2 circle { animation-delay: .6s; } .dlsh-art-arch .c3 circle { animation-delay: 1.2s; }
/* medical */
.dlsh-art-med .scan { fill: #fff; stroke: none; animation: dlshScan 3.2s ease-in-out infinite; }
.dlsh-art-med .seg { fill: #fff; stroke: #0D0D0D; animation: dlshSeg 3.2s ease-in-out infinite; }
@keyframes dlshFlow { to { stroke-dashoffset: -12; } }
@keyframes dlshTravel { 0% { offset-distance: 0%; opacity: 0; } 12% { opacity: 1; } 70% { offset-distance: 100%; opacity: 1; } 80%, 100% { offset-distance: 100%; opacity: 0; } }
@keyframes dlshPop { 0%, 60% { transform: scale(1); } 72% { transform: scale(1.12); } 88%, 100% { transform: scale(1); } }
@keyframes dlshDraw { 0%, 60% { stroke-dashoffset: 20; } 80%, 100% { stroke-dashoffset: 0; } }
@keyframes dlshNudge { 0%, 100% { transform: translateX(0); } 40% { transform: translateX(2px); } }
@keyframes dlshPull { 0%, 12%, 100% { transform: translateY(0) rotate(0); } 30%, 60% { transform: translateY(-7px) rotate(-14deg); } 78% { transform: translateY(0) rotate(0); } }
@keyframes dlshCode { 0%, 25% { stroke-dashoffset: 40; opacity: .4; } 50%, 85% { stroke-dashoffset: 0; opacity: 1; } 100% { stroke-dashoffset: 40; opacity: .4; } }
@keyframes dlshFire { 0%, 55%, 100% { fill: rgba(255, 255, 255, .5); transform: scale(1); } 25% { fill: #0D0D0D; transform: scale(1.18); } }
@keyframes dlshScan { 0% { transform: translateY(0); opacity: 0; } 10% { opacity: 1; } 80% { transform: translateY(44px); opacity: 1; } 100% { transform: translateY(44px); opacity: 0; } }
@keyframes dlshSeg { 0%, 30% { opacity: 0; } 55%, 85% { opacity: 1; } 100% { opacity: 0; } }
@media (prefers-reduced-motion: reduce) {
	.dlsh-art, .dlsh-art * { animation: none !important; }
	.dlsh-art-nc .dot { opacity: 0; } .dlsh-art-med .scan { opacity: 0; } .dlsh-art-med .seg { opacity: 1; }
}
