/* Shafak × CARE — North Aleppo assessments portal
   One system for hub, dashboards, reports and the key-findings brief. */

@font-face { font-family: "Sentient"; src: url("../fonts/sentient-400.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Sentient"; src: url("../fonts/sentient-400i.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "Sentient"; src: url("../fonts/sentient-500.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: "Sentient"; src: url("../fonts/sentient-500i.woff2") format("woff2"); font-weight: 500; font-style: italic; font-display: swap; }
@font-face { font-family: "Sentient"; src: url("../fonts/sentient-700.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: swap; }

:root {
  /* brand */
  --shafak: #f7911c;
  --zest: #e36f1e;
  --russian: #a84d14;          /* deep CARE orange: accent surfaces, 5.6:1 with white */
  --care90: #fcf1e9; --care80: #f9e2d2; --care70: #f7d4bc; --care60: #f4c5a5;
  /* Shafak tints */
  --t10: #f89c33; --t30: #f9b260; --t50: #fbc88e; --t60: #fcd3a4; --t70: #fddebb; --t80: #fde9d2; --t90: #fef4e8;
  /* tonal steps derived from the two brand anchors */
  --zest-deep: #9a4410;       /* orange as text on light: 6.6:1 */
  --ink: #3a3a3c;             /* Shafak logo charcoal: text only */
  --ink-2: #48484b;
  --ink-3: #66666a;           /* secondary text, 5.7:1 on white */
  --ink-4: #8e8e93;
  --paper: #ffffff;
  --wash: #fef4e8;            /* Shafak 90% tint */
  --line: rgba(168, 77, 20, .14);
  --line-2: rgba(168, 77, 20, .24);
  /* former dark surfaces, now light brand tints */
  --night: #fef4e8;
  --night-2: #fcf1e9;
  --night-line: rgba(168, 77, 20, .18);
  --night-ink: #3a3a3c;
  --night-ink-2: #5d5d61;

  --display: "Sentient", Georgia, "Times New Roman", serif;
  --body: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, Roboto, "Helvetica Neue", Arial, sans-serif;
  --ar: "Readex Pro", "Segoe UI", Tahoma, sans-serif;

  --cut: 14px;                /* the portal's signature chamfer */
  --ease: cubic-bezier(.22, .8, .24, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--body); color: var(--ink-2); background: var(--paper); line-height: 1.55; font-size: 15px; }
html[dir="rtl"] body, [lang="ar"] { font-family: var(--ar); }
html[dir="rtl"] body { font-size: 15px; line-height: 1.75; }
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3, h4 { color: var(--ink); margin: 0; font-weight: 500; }
.display, h1, h2 { font-family: var(--display); letter-spacing: -.01em; }
html[dir="rtl"] .display, html[dir="rtl"] h1, html[dir="rtl"] h2, html[dir="rtl"] h3 { font-family: var(--ar); letter-spacing: 0; }
p { margin: 0 0 .8em; }
.num { font-variant-numeric: tabular-nums; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
:focus-visible { outline: 2px solid var(--zest); outline-offset: 2px; }

/* ── the chamfer: one bespoke silhouette, used everywhere a panel needs presence ── */
.cut { clip-path: polygon(0 0, calc(100% - var(--cut)) 0, 100% var(--cut), 100% 100%, 0 100%); }
html[dir="rtl"] .cut { clip-path: polygon(var(--cut) 0, 100% 0, 100% 100%, 0 100%, 0 var(--cut)); }

/* ── brand bar (shared top navigation) ── */
.bar { background: #fff; border-bottom: 1px solid var(--line); color: var(--night-ink); position: sticky; top: 0; z-index: 40; }
.bar-in { max-width: 1440px; margin: 0 auto; padding: 0 28px; height: 64px; display: flex; align-items: center; gap: 22px; }
.bar-logos { display: flex; align-items: center; gap: 16px; text-decoration: none; flex-shrink: 0; }
.bar-logos img.sh { height: 30px; width: auto; }
.bar-logos img.ca { height: 22px; width: auto; }
.bar-logos .x { width: 1px; height: 26px; background: var(--night-line); }
.bar-title { font-size: 13px; color: var(--night-ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.bar-title b { color: var(--night-ink); font-weight: 600; }
.bar-nav { margin-inline-start: auto; display: flex; align-items: center; gap: 4px; flex-shrink: 0; }
.bar-nav a, .bar-nav button {
  font: inherit; font-size: 13px; color: var(--night-ink-2); text-decoration: none; background: none; border: 0;
  padding: 8px 12px; cursor: pointer; transition: color .2s;
}
.bar-nav a:hover, .bar-nav button:hover { color: var(--zest-deep); }
.bar-nav a[aria-current="page"] { color: var(--night-ink); font-weight: 600; }
.bar-nav .lang { border: 1px solid var(--night-line); padding: 6px 12px; margin-inline-start: 6px; }
.bar-nav .lang:hover { border-color: var(--zest); color: var(--zest-deep); }
.bar-nav .up::after { content: " ↗"; }
html[dir="rtl"] .bar-nav .up::after { content: " ↖"; }

@media screen and (max-width: 860px) {
  .bar-in { padding: 0 16px; gap: 12px; height: 56px; }
  .bar-title { display: none; }
  .bar-logos img.sh { height: 24px; }
  .bar-logos img.ca { height: 17px; }
  .bar-nav a:not(.lang):not(.keep) { display: none; }
}

/* ── bars (the data mark used across every product) ── */
.hb { display: grid; gap: 9px; }
.hb-row { display: grid; grid-template-columns: minmax(120px, 38%) 1fr 58px; align-items: center; gap: 12px; font-size: 13.5px; }
.hb-row .l { color: var(--ink-2); line-height: 1.3; }
.hb-row .t { height: 12px; background: var(--t90); position: relative; }
.hb-row .f { position: absolute; inset-block: 0; inset-inline-start: 0; background: var(--zest); transition: width .8s var(--ease); }
@starting-style { .hb-row .f { width: 0 !important; } }
.hb-row .v { text-align: end; font-variant-numeric: tabular-nums; color: var(--ink); font-weight: 600; }
.hb-row .v small { font-weight: 400; color: var(--ink-3); font-size: 11.5px; }
.hb-row.hl .f { background: var(--russian); }
.hb-row.mute .f { background: var(--t50); }
.hb-row[data-click] { cursor: pointer; }
.hb-row[data-click]:hover .l { color: var(--zest-deep); }
.hb-row.on .l { color: var(--zest-deep); font-weight: 600; }
.base { font-size: 12px; color: var(--ink-3); margin-top: 10px; }

/* heat matrix */
.mx { width: 100%; border-collapse: collapse; font-size: 13px; }
.mx th, .mx td { padding: 8px 10px; text-align: center; border-bottom: 1px solid var(--line); }
.mx th { font-weight: 600; color: var(--ink-3); font-size: 12px; vertical-align: bottom; }
.mx th:first-child, .mx td:first-child { text-align: start; color: var(--ink-2); font-weight: 500; }
.mx td.c { font-variant-numeric: tabular-nums; font-weight: 600; }

/* split bar (composition) */
.split { display: flex; height: 26px; overflow: hidden; }
.split span { display: block; height: 100%; transition: flex-basis .8s var(--ease); }
.legend { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 12.5px; color: var(--ink-3); margin-top: 10px; }
.legend i { display: inline-block; width: 10px; height: 10px; margin-inline-end: 6px; vertical-align: -1px; }

/* dumbbell */
.db { display: grid; gap: 4px; margin-top: 18px; }
.db-row { display: grid; grid-template-columns: minmax(110px, 30%) 1fr; align-items: center; gap: 14px; font-size: 13.5px; min-height: 34px; }
.db-t { position: relative; height: 34px; background: linear-gradient(var(--line), var(--line)) center / 100% 1px no-repeat; margin-inline-end: 18px; }
.db-link { position: absolute; top: 50%; height: 4px; margin-top: -2px; background: var(--t60); }
.db-dot { position: absolute; top: 50%; width: 14px; height: 14px; margin: -7px 0 0 -7px; border: 2px solid #fff; }
html[dir="rtl"] .db-dot { margin: -7px -7px 0 0; }
.db-dot.az { background: var(--russian); }
.db-dot.tr { background: var(--zest); border-radius: 50%; }
.db-dot em { position: absolute; bottom: 15px; left: 50%; transform: translateX(-50%); font-style: normal; font-size: 11px; font-weight: 700; color: var(--ink-2); font-variant-numeric: tabular-nums; }
.legend i.dot { width: 12px; height: 12px; }
.legend i.dot.az { background: var(--russian); }
.legend i.dot.tr { background: var(--zest); border-radius: 50%; }


/* ── print / report paper ── */
@page { size: A4; margin: 0; }
@media print {
  body { background: #fff !important; }
  .no-print { display: none !important; }
  * { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}
