/* ---------- Tokens ---------- */
:root {
  --teal: #178F8D;
  --teal-strong: #10706F;
  --teal-deep: #0C4A4B;
  --teal-tint: #DCF0F2;
  --amber: #2FB3D6;
  --amber-soft: #D2EEF7;
  --ink: #123B3E;
  --ink-2: #3A6467;
  --ink-3: #4F7477;
  --paper: #EFF8FA;
  --card: #FFFFFF;
  --line: #D3E7EA;
  --chip-bg: #DCF0F2;
  --chip-fg: #10706F;
  --hero-grad-a: #178F8D;
  --hero-grad-b: #093E3F;
  --on-teal: #EAF6F6;
  --on-teal-dim: #A5CFD1;
  --shadow: 0 1px 2px rgba(12,74,75,.06), 0 8px 24px -12px rgba(12,74,75,.18);
}
@media (prefers-color-scheme: dark) {
  :root {
    --teal: #3AB5B2;
    --teal-strong: #45C4C1;
    --teal-deep: #093435;
    --teal-tint: #0F3436;
    --amber: #4CC3E0;
    --amber-soft: #123F4E;
    --ink: #E3F2F3;
    --ink-2: #A2C4C7;
    --ink-3: #77999D;
    --paper: #0A1D1F;
    --card: #10282B;
    --line: #1C3D40;
    --chip-bg: #143C40;
    --chip-fg: #7FCBD4;
    --hero-grad-a: #11595B;
    --hero-grad-b: #062223;
    --on-teal: #EAF6F6;
    --on-teal-dim: #93B5B1;
    --shadow: 0 1px 2px rgba(0,0,0,.3), 0 10px 28px -12px rgba(0,0,0,.5);
  }
}
:root[data-theme="dark"] {
  --teal: #3AB5B2;
  --teal-strong: #45C4C1;
  --teal-deep: #093435;
  --teal-tint: #0F3436;
  --amber: #4CC3E0;
  --amber-soft: #123F4E;
  --ink: #E3F2F3;
  --ink-2: #A2C4C7;
  --ink-3: #77999D;
  --paper: #0A1D1F;
  --card: #10282B;
  --line: #1C3D40;
  --chip-bg: #143C40;
  --chip-fg: #7FCBD4;
  --hero-grad-a: #11595B;
  --hero-grad-b: #062223;
  --on-teal: #EAF6F6;
  --on-teal-dim: #93B5B1;
  --shadow: 0 1px 2px rgba(0,0,0,.3), 0 10px 28px -12px rgba(0,0,0,.5);
}
:root[data-theme="light"] {
  --teal: #178F8D;
  --teal-strong: #10706F;
  --teal-deep: #0C4A4B;
  --teal-tint: #DCF0F2;
  --amber: #2FB3D6;
  --amber-soft: #D2EEF7;
  --ink: #123B3E;
  --ink-2: #3A6467;
  --ink-3: #4F7477;
  --paper: #EFF8FA;
  --card: #FFFFFF;
  --line: #D3E7EA;
  --chip-bg: #DCF0F2;
  --chip-fg: #10706F;
  --hero-grad-a: #178F8D;
  --hero-grad-b: #093E3F;
  --on-teal: #EAF6F6;
  --on-teal-dim: #A5CFD1;
  --shadow: 0 1px 2px rgba(12,74,75,.06), 0 8px 24px -12px rgba(12,74,75,.18);
}

/* ---------- Base ---------- */
html { direction: rtl; }
body {
  background: var(--paper);
  color: var(--ink);
  font-family: 'Almarai', 'Segoe UI', Tahoma, sans-serif;
  font-size: 16px;
  line-height: 1.85;
  margin: 0;
  -webkit-font-smoothing: antialiased;
}
* { box-sizing: border-box; }
a { color: inherit; text-decoration: none; }
img, svg { max-width: 100%; }
.wrap { max-width: 1140px; margin-inline: auto; padding-inline: 20px; }
h1,h2,h3,h4 {
  text-wrap: balance; margin: 0; line-height: 1.45;
  font-family: 'Cairo', 'Almarai', 'Segoe UI', Tahoma, sans-serif;
}
.brand-name, .btn-primary, .event .cta, .river-head, .date-block .d {
  font-family: 'Cairo', 'Almarai', 'Segoe UI', Tahoma, sans-serif;
}
a, button { transition: color .15s, background-color .15s, border-color .15s, box-shadow .15s; }
@media (prefers-reduced-motion: reduce) { a, button { transition: none; } }
:focus-visible { outline: 2px solid var(--amber); outline-offset: 2px; border-radius: 3px; }

.skip-link {
  position: absolute; inset-inline-start: 12px; top: -60px; z-index: 100;
  background: var(--teal); color: #fff; font-weight: 700; font-size: 14px;
  padding: 10px 18px; border-radius: 0 0 10px 10px; transition: top .15s;
}
.skip-link:focus { top: 0; }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* Tatreez-inspired stitch pattern (X motif) */
.stitch {
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='28' height='28' viewBox='0 0 28 28'><g stroke='%23FFFFFF' stroke-width='1.6' stroke-linecap='round' opacity='.55'><path d='M6 6 L12 12 M12 6 L6 12'/><path d='M20 20 L26 26 M26 20 L20 26'/></g></svg>");
}

/* ---------- Top bar ---------- */
.topbar { background: var(--teal-deep); color: var(--on-teal-dim); font-size: 13px; }
.topbar .wrap { display: flex; align-items: center; justify-content: space-between; min-height: 34px; gap: 16px; }
.topbar .social { display: flex; gap: 4px; }
.topbar .social a { display: grid; place-items: center; width: 26px; height: 26px; border-radius: 6px; }
.topbar .social a:hover { background: rgba(255,255,255,.12); color: var(--on-teal); }
.topbar svg { width: 15px; height: 15px; fill: currentColor; }

/* ---------- Header ---------- */
header.site { background: var(--card); border-bottom: 1px solid var(--line); }
header.site .wrap { display: flex; align-items: center; gap: 28px; padding-block: 18px; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 12px; }
.brand .mark { width: 46px; height: 46px; flex: none; }
.brand .logo-img, .brand img.custom-logo { height: 92px; width: 92px; flex: none; border-radius: 16px; display: block; object-fit: cover; }
.brand-name { font-size: 24px; font-weight: 700; color: var(--ink); line-height: 1.2; }
.brand-tag { font-size: 12.5px; color: var(--ink-3); }
nav.main { display: flex; gap: 2px; margin-inline-start: auto; flex-wrap: wrap; }
nav.main a {
  font-size: 15px; font-weight: 600; color: var(--ink-2);
  padding: 8px 13px; border-radius: 8px;
}
nav.main a:hover { color: var(--teal); background: var(--teal-tint); }
nav.main a.active { color: var(--teal-strong); box-shadow: inset 0 -3px 0 var(--amber); border-radius: 8px 8px 0 0; }
.search-btn {
  display: grid; place-items: center; width: 38px; height: 38px;
  border: 1px solid var(--line); border-radius: 10px; background: none; color: var(--ink-2); cursor: pointer;
}
.search-btn:hover { border-color: var(--teal); color: var(--teal); }
.search-btn svg { width: 17px; height: 17px; }

/* ---------- Ticker ---------- */
.ticker { background: var(--amber); color: #083540; overflow: hidden; }
.ticker .wrap { display: flex; align-items: stretch; gap: 0; padding-inline: 20px; }
.ticker .label {
  font-size: 13px; font-weight: 700; padding: 7px 0; padding-inline-end: 16px;
  display: flex; align-items: center; gap: 7px; flex: none;
}
.ticker .label .dot { width: 7px; height: 7px; border-radius: 50%; background: #083540; animation: pulse 1.6s infinite; }
@keyframes pulse { 50% { opacity: .25; } }
.ticker .items { display: flex; gap: 44px; align-items: center; white-space: nowrap; overflow: hidden; mask-image: linear-gradient(to left, transparent, #000 4%, #000 96%, transparent); }
.ticker .track { display: flex; gap: 44px; animation: slide 38s linear infinite; font-size: 13.5px; font-weight: 500; }
@keyframes slide { to { transform: translateX(50%); } }
@media (prefers-reduced-motion: reduce) {
  .ticker .track { animation: none; }
  .ticker .label .dot { animation: none; }
}

/* ---------- Section scaffolding ---------- */
section { padding-block: 40px 8px; }
.section-head { display: flex; align-items: baseline; gap: 14px; margin-bottom: 22px; }
.section-head .sq { width: 12px; height: 12px; background: var(--amber); border-radius: 3px; flex: none; align-self: center; }
.section-head h2 { font-size: 25px; font-weight: 800; }
.section-head .all { margin-inline-start: auto; font-size: 14px; font-weight: 600; color: var(--teal-strong); display: flex; align-items: center; gap: 6px; }
.section-head .all:hover { color: var(--teal-strong); }
.section-head .all svg { width: 15px; height: 15px; }

.chip {
  display: inline-block; font-size: 12px; font-weight: 600;
  background: var(--chip-bg); color: var(--chip-fg);
  padding: 2px 11px; border-radius: 99px;
}
.meta { font-size: 12.5px; color: var(--ink-3); display: flex; align-items: center; gap: 8px; }
.meta .sep { width: 3px; height: 3px; background: var(--ink-3); border-radius: 50%; }

/* ---------- Hero ---------- */
.hero { padding-block: 34px 10px; }
.hero-grid { display: grid; grid-template-columns: 7fr 5fr; gap: 26px; align-items: stretch; }
.feature {
  position: relative; border-radius: 18px; overflow: hidden; display: flex; flex-direction: column;
  justify-content: flex-end; min-height: 430px; padding: 30px;
  background:
    radial-gradient(120% 90% at 85% 10%, rgba(76,195,224,.30), transparent 55%),
    linear-gradient(210deg, var(--hero-grad-a), var(--hero-grad-b));
  color: var(--on-teal); box-shadow: var(--shadow);
}
.feature .photo { position: absolute; inset: 0; background-size: cover; background-position: center; }
.feature .shade {
  position: absolute; inset: 0;
  /* Migrated featured photos are often pre-designed graphics with their own
     baked-in text (podcast cards, social tiles) — the scrim has to hold up
     against that, not just a plain photo, so it stays dark over a much
     larger share of the card, not just a thin band at the very bottom. */
  background: linear-gradient(to top, rgba(4,30,31,.97) 0%, rgba(4,30,31,.90) 40%, rgba(7,48,49,.62) 68%, rgba(23,143,141,.22) 100%);
}
.feature .pattern { position: absolute; inset: 0; opacity: .12; }
.feature > * { position: relative; }
.feature .chip { background: var(--amber); color: #083540; }
.feature h1 { font-size: 32px; font-weight: 800; margin-block: 14px 10px; line-height: 1.6; text-shadow: 0 2px 12px rgba(0,0,0,.35); }
.feature p { margin: 0 0 16px; color: var(--on-teal-dim); font-size: 15.5px; max-width: 58ch; }
.feature .meta { color: var(--on-teal-dim); }
.feature .meta .sep { background: var(--on-teal-dim); }

.river { display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--line); border-radius: 18px; overflow: hidden; }
.river-head {
  display: flex; align-items: center; gap: 10px; padding: 15px 22px;
  font-weight: 700; font-size: 16.5px; border-bottom: 1px solid var(--line);
}
.river-head .sq { width: 10px; height: 10px; background: var(--amber); border-radius: 3px; }
.river a.river-item { display: flex; gap: 14px; padding: 13px 22px; border-bottom: 1px solid var(--line); align-items: center; }
.river a.river-item:last-child { border-bottom: 0; }
.river a.river-item:hover { background: var(--teal-tint); }
.river .rthumb { flex: none; width: 58px; height: 58px; border-radius: 11px; overflow: hidden; position: relative; }
.river .rthumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.river .rthumb::after { content: ""; position: absolute; inset: 0; background: rgba(23,143,141,.12); }
.river .t { font-size: 14.5px; font-weight: 700; line-height: 1.55; }
.river time { font-size: 12px; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.river .cat { font-size: 12px; color: var(--teal-strong); font-weight: 700; }
.river .m { display: flex; gap: 8px; align-items: center; margin-top: 3px; }
.river .m .sep { width: 3px; height: 3px; background: var(--ink-3); border-radius: 50%; }

/* ---------- Digest band ---------- */
.digest { background: var(--teal-deep); color: var(--on-teal); margin-block: 44px 12px; padding-block: 42px; position: relative; overflow: hidden; }
.digest .pattern { position: absolute; inset: 0; opacity: .07; }
.digest .wrap { position: relative; display: grid; grid-template-columns: 4fr 7fr; gap: 40px; align-items: center; }
.digest .kicker { color: var(--amber); font-weight: 700; font-size: 14px; display: flex; align-items: center; gap: 9px; }
.digest .kicker .sq { width: 10px; height: 10px; background: var(--amber); border-radius: 3px; }
.digest h2 { font-size: 28px; font-weight: 800; margin-block: 10px 8px; color: #fff; }
.digest .lead { color: var(--on-teal-dim); font-size: 15px; margin: 0 0 20px; }
.btn-primary {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--amber); color: #083540; font-weight: 700; font-size: 14.5px;
  padding: 10px 22px; border-radius: 11px;
}
.btn-primary:hover { filter: brightness(1.06); }
.btn-primary svg { width: 15px; height: 15px; }
.digest-items { display: grid; gap: 12px; }
.digest-items .d-item {
  background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.1);
  border-radius: 13px; padding: 14px 18px; display: flex; gap: 14px; align-items: baseline;
}
.digest-items .d-item:hover { background: rgba(255,255,255,.11); }
.digest-items .n { font-weight: 700; color: var(--amber); font-variant-numeric: tabular-nums; flex: none; }
.digest-items .t { font-size: 15px; font-weight: 600; color: #ECF4F2; line-height: 1.6; }

/* ---------- Cards / thumbs ---------- */
.thumb { border-radius: 13px; position: relative; overflow: hidden; flex: none; }
.thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.thumb .tint { position: absolute; inset: 0; background: linear-gradient(200deg, rgba(23,143,141,.18), rgba(12,74,75,.42)); }
.thumb .glyph { position: absolute; inset: 0; display: grid; place-items: center; font-weight: 700; color: rgba(255,255,255,.9); }
.thumb.v1 { background: linear-gradient(200deg, #189A98, #0C4A4B); }
.thumb.v2 { background: linear-gradient(200deg, #2FA9CC, #0E5B70); }
.thumb.v3 { background: linear-gradient(200deg, #10706F, #0A4E52); }

/* Focus split: profession + opinions */
.split { display: grid; grid-template-columns: 7fr 5fr; gap: 26px; }
.prof-card {
  background: var(--card); border: 1px solid var(--line); border-radius: 18px;
  overflow: hidden; display: flex; flex-direction: column; box-shadow: var(--shadow);
}
.prof-card:hover { border-color: var(--teal); }
.prof-card:hover h3 { color: var(--teal); }
.prof-card .thumb { height: 210px; border-radius: 0; }
.prof-card .thumb .glyph svg { width: 64px; height: 64px; opacity: .9; }
.prof-card .body { padding: 22px 26px 26px; display: flex; flex-direction: column; gap: 10px; }
.prof-card h3 { font-size: 21px; font-weight: 700; }
.prof-card p { margin: 0; color: var(--ink-2); font-size: 15px; max-width: 65ch; }
.more-link { color: var(--teal-strong); font-weight: 700; font-size: 14px; display: inline-flex; align-items: center; gap: 6px; }
.more-link svg { width: 14px; height: 14px; }
.more-link:hover { color: var(--teal-strong); }

.opinions { display: flex; flex-direction: column; gap: 14px; }
.op {
  background: var(--card); border: 1px solid var(--line); border-radius: 15px;
  padding: 16px 20px; display: flex; gap: 14px; align-items: flex-start;
}
.op:hover { border-color: var(--teal); }
.op .avatar {
  flex: none; width: 44px; height: 44px; border-radius: 50%;
  display: grid; place-items: center; font-weight: 700; font-size: 15px; color: #fff;
}
.op .avatar svg { width: 21px; height: 21px; }
.op .t { font-size: 15px; font-weight: 600; line-height: 1.55; }
.op .by { font-size: 12.5px; color: var(--ink-3); margin-top: 3px; }

/* ---------- People ---------- */
.people-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.person {
  background: var(--card); border: 1px solid var(--line); border-radius: 18px;
  padding: 26px 24px 24px; text-align: center; display: flex; flex-direction: column; gap: 10px; align-items: center;
  box-shadow: var(--shadow);
}
.person:hover { border-color: var(--teal); transform: translateY(-2px); transition: .18s; }
@media (prefers-reduced-motion: reduce) { .person:hover { transform: none; } }
.person .avatar {
  width: 76px; height: 76px; border-radius: 50%; display: grid; place-items: center;
  font-size: 26px; font-weight: 700; color: #fff; box-shadow: 0 0 0 4px var(--paper), 0 0 0 6px var(--amber);
}
.person img.avatar { object-fit: cover; }
.person h3 { font-size: 17.5px; font-weight: 700; margin-top: 6px; }
.person p { margin: 0; font-size: 14px; color: var(--ink-2); }

/* ---------- Events ---------- */
.events { display: grid; gap: 14px; }
.event {
  background: var(--card); border: 1px solid var(--line); border-radius: 15px;
  padding: 16px 20px; display: flex; gap: 20px; align-items: center; flex-wrap: wrap;
}
.event:hover { border-color: var(--teal); }
.date-block {
  flex: none; width: 64px; text-align: center; background: var(--teal-tint); color: var(--teal-strong);
  border-radius: 12px; padding: 8px 4px; line-height: 1.15;
}
.date-block .d { font-size: 23px; font-weight: 700; font-variant-numeric: tabular-nums; }
.date-block .m { font-size: 12px; font-weight: 600; }
.event .info { flex: 1; min-width: 220px; }
.event h3 { font-size: 16.5px; font-weight: 700; }
.event .meta { margin-top: 4px; }
.event .cta { font-size: 13.5px; font-weight: 700; color: var(--teal); border: 1.5px solid var(--teal); padding: 7px 18px; border-radius: 10px; }
.event .cta:hover { background: var(--teal); color: #fff; }

/* ---------- Unions ---------- */
.unions-band { background: var(--teal-tint); margin-top: 44px; padding-block: 40px 46px; }
.unions-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 14px; }
.union {
  background: var(--card); border: 1px solid var(--line); border-radius: 14px;
  padding: 18px 12px; text-align: center; display: flex; flex-direction: column; gap: 8px; align-items: center;
  font-size: 13.5px; font-weight: 600; color: var(--ink-2);
}
.union:hover { border-color: var(--teal); color: var(--teal); }
.union .ic { width: 40px; height: 40px; border-radius: 11px; background: var(--teal-tint); display: grid; place-items: center; color: var(--teal); }
.union .ic svg { width: 21px; height: 21px; }

/* ---------- Footer ---------- */
footer.site { background: var(--teal-deep); color: #E5E1D3; margin-top: 0; }
footer.site .cols { display: grid; grid-template-columns: 1.6fr 1fr 1fr; gap: 32px; padding-block: 36px 28px; }
footer.site h4, footer.site h2 { color: #fff; font-size: 16px; margin-bottom: 14px; }
footer.site .about p { margin: 10px 0 0; font-size: 14px; max-width: 42ch; }
footer.site ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 9px; font-size: 14px; }
footer.site ul a { color: #E5E1D3; }
footer.site ul a:hover { color: #fff; }
footer.site .footbar { color: #E5E1D3; }
footer.site .fbrand { display: flex; align-items: center; gap: 10px; color: #fff; font-weight: 700; font-size: 19px; }
footer.site .fbrand .mark { width: 36px; height: 36px; }
footer.site .fbrand .logo-img { height: 64px; width: 64px; border-radius: 12px; display: block; object-fit: cover; }
footer.site .social { display: flex; gap: 8px; margin-top: 16px; }
footer.site .social a { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 9px; background: rgba(255,255,255,.08); }
footer.site .social a:hover { background: var(--amber); color: #083540; }
footer.site .social svg { width: 16px; height: 16px; fill: currentColor; }
.footbar { border-top: 1px solid rgba(255,255,255,.1); }
.footbar .wrap { display: flex; justify-content: space-between; gap: 14px; padding-block: 16px; font-size: 12.5px; flex-wrap: wrap; }

/* ---------- Responsive ---------- */
@media (max-width: 920px) {
  .hero-grid, .split, .digest .wrap { grid-template-columns: 1fr; }
  .people-grid { grid-template-columns: 1fr; }
  .unions-grid { grid-template-columns: repeat(3, 1fr); }
  footer.site .cols { grid-template-columns: 1fr; gap: 28px; }
  .feature { min-height: 340px; }
  .feature h1 { font-size: 25px; }
  nav.main { margin-inline-start: 0; }
}
@media (max-width: 560px) {
  .unions-grid { grid-template-columns: repeat(2, 1fr); }
  .topbar .date { display: none; }
}

/* ---------- Header search panel (WordPress-specific: header.php toggles this with assets/site.js) ---------- */
/* header.site .wrap sets display:flex, which — because author rules always
   beat the browser's own [hidden] default — was silently defeating the
   hidden attribute and showing this panel open on every page load. */
#voc-search-panel[hidden] { display: none; }
#voc-search-panel { padding-block: 0 16px; }
.voc-search-form { display: flex; gap: 10px; align-items: center; }
.voc-search-form .field { margin-bottom: 0; }
.voc-search-form .btn-primary { flex: none; padding-inline: 20px; }
