/*
 * Kufi Productions. Dark, cinematic, one loud color.
 *
 * Structure follows theummah.io (floating nav card, mega panels, right-hand
 * drawer on phones, generous spacing, pill buttons). The skin is Kufi's: warm
 * ink, Kufi yellow, paper for long reading, Archivo condensed for display
 * type like a screening poster, Inter for everything else. See brand/BRAND.md.
 */

:root {
  --ink: oklch(0.165 0.006 85);
  --ink-2: oklch(0.205 0.008 85);
  --ink-3: oklch(0.255 0.009 85);
  --line: oklch(0.97 0.01 90 / 0.11);
  --line-2: oklch(0.97 0.01 90 / 0.2);
  --text: oklch(0.965 0.008 90);
  --muted: oklch(0.79 0.01 88);
  --dim: oklch(0.66 0.01 88);
  --yellow: oklch(0.845 0.168 91);
  --yellow-2: oklch(0.89 0.15 94);
  --yellow-ink: oklch(0.21 0.02 85);
  --paper: oklch(0.975 0.011 90);
  --paper-2: oklch(0.935 0.016 88);
  --paper-line: oklch(0.2 0.01 85 / 0.12);
  --paper-text: oklch(0.21 0.01 85);
  --paper-muted: oklch(0.43 0.012 85);

  --display: 'Archivo', 'Inter', system-ui, sans-serif;
  --sans: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;

  --gutter: clamp(16px, 4vw, 40px);
  --wrap: 1240px;
  --pad: clamp(36px, 4.5vw, 68px);
  --r: 14px;
  --r-lg: 20px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --nav-h: 64px;

  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 96px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  background: var(--ink);
  color: var(--text);
  font: 400 1.0625rem/1.68 var(--sans);
  font-feature-settings: 'ss01', 'cv11';
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  /* Guests paste full URLs and emails into profiles; let them wrap. */
  overflow-wrap: break-word;
}
img, video, iframe { max-width: 100%; display: block; }
img { height: auto; }
a { color: inherit; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--yellow); outline-offset: 3px; border-radius: 6px; }
::selection { background: var(--yellow); color: var(--yellow-ink); }

.wrap { width: min(var(--wrap), 100% - 2 * var(--gutter)); margin-inline: auto; }
.wrap--narrow { width: min(760px, 100% - 2 * var(--gutter)); margin-inline: auto; }
.skip { position: absolute; left: -9999px; top: 8px; z-index: 100; background: var(--yellow); color: var(--yellow-ink); padding: 10px 16px; border-radius: 999px; font-weight: 600; text-decoration: none; }
.skip:focus { left: 12px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------------------------------------------------------------- type */

.display, .h1, .h2 {
  font-family: var(--display);
  font-stretch: 72%;
  font-weight: 800;
  letter-spacing: -0.01em;
  line-height: 0.95;
  margin: 0;
  text-wrap: balance;
}
.display { font-size: clamp(3.1rem, 1.6rem + 7vw, 8.25rem); text-transform: uppercase; line-height: 0.88; }
.h1 { font-size: clamp(2.75rem, 1.6rem + 5vw, 6rem); text-transform: uppercase; line-height: 0.9; }
.h2 { font-size: clamp(2.25rem, 1.5rem + 3.2vw, 4.25rem); }
.h3 { font-family: var(--sans); font-size: clamp(1.25rem, 1.1rem + 0.6vw, 1.55rem); font-weight: 700; letter-spacing: -0.015em; line-height: 1.2; margin: 0; }
.mark { color: var(--yellow); }
.t-paper .mark, .t-yellow .mark { color: inherit; text-decoration: underline; text-decoration-color: var(--yellow); text-decoration-thickness: 0.12em; text-underline-offset: 0.08em; }
.t-yellow .mark { text-decoration-color: var(--yellow-ink); }
.lede { font-size: clamp(1.125rem, 1.05rem + 0.4vw, 1.3rem); line-height: 1.6; color: var(--muted); max-width: 62ch; margin: 0; }
.kicker { display: inline-flex; align-items: center; gap: 10px; font-size: 0.8125rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--yellow); margin: 0 0 18px; }
.kicker::before { content: ''; width: 22px; height: 2px; background: currentColor; }
.t-paper .kicker { color: var(--paper-text); }
.t-paper .kicker::before { background: var(--yellow); height: 3px; }
.t-yellow .kicker { color: var(--yellow-ink); }
.muted { color: var(--muted); }

/* ------------------------------------------------------------- buttons */

.btn {
  --b: var(--yellow); --c: var(--yellow-ink);
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 48px; padding: 0 24px;
  border-radius: 999px; border: 1px solid var(--b);
  background: var(--b); color: var(--c);
  font-weight: 600; font-size: 0.98rem; line-height: 1; text-decoration: none; white-space: nowrap;
  cursor: pointer;
  transition: background 0.2s var(--ease), border-color 0.2s var(--ease), color 0.2s var(--ease), transform 0.2s var(--ease);
}
.btn:hover { --b: var(--yellow-2); }
.btn:active { transform: translateY(1px); }
.btn--line { background: transparent; --c: var(--text); --b: var(--line-2); }
.btn--line:hover { --b: var(--text); background: oklch(0.97 0.01 90 / 0.06); }
.btn--ink { --b: var(--paper-text); --c: var(--paper); }
.btn--ink:hover { --b: oklch(0.32 0.01 85); }
.t-paper .btn--line, .t-yellow .btn--line { --c: var(--paper-text); --b: var(--paper-line); }
.t-yellow .btn--line { --b: oklch(0.21 0.02 85 / 0.55); }
.t-paper .btn--line:hover, .t-yellow .btn--line:hover { --b: var(--paper-text); background: transparent; }
.btn--sm { min-height: 40px; padding: 0 18px; font-size: 0.9rem; }
.btn svg { width: 18px; height: 18px; flex: none; }
.btns { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.link { color: var(--yellow); font-weight: 600; text-decoration: none; display: inline-flex; align-items: center; gap: 8px; }
.link svg { width: 18px; height: 18px; flex: none; transition: transform 0.25s var(--ease); }
a:hover > .link svg, .link:hover svg { transform: translateX(3px); }
.link:hover { text-decoration: underline; text-underline-offset: 4px; }
.t-paper .link { color: var(--paper-text); text-decoration: underline; text-decoration-color: var(--yellow); text-decoration-thickness: 2px; text-underline-offset: 4px; }

/* ----------------------------------------------------------- floating nav */

.nav {
  position: fixed; top: calc(12px + var(--bar-push, 0px)); left: 50%; transform: translateX(-50%); z-index: 50;
  width: min(var(--wrap) + 32px, 100% - 24px);
}
.nav-bar {
  height: var(--nav-h);
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 0 10px 0 12px;
  border-radius: 18px;
  background: oklch(0.17 0.006 85 / 0.72);
  border: 1px solid var(--line);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  backdrop-filter: blur(16px) saturate(140%);
  transition: background 0.3s var(--ease), box-shadow 0.3s var(--ease);
}
.nav.is-scrolled .nav-bar, .nav.is-open .nav-bar { background: oklch(0.17 0.006 85 / 0.92); box-shadow: 0 18px 40px -18px oklch(0 0 0 / 0.7); }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; flex: none; }
.brand img { width: 42px; height: 42px; border-radius: 50%; }
.brand-name { font-family: var(--display); font-stretch: 72%; font-weight: 800; font-size: 1.32rem; letter-spacing: 0.01em; text-transform: uppercase; line-height: 1; }
.brand-name span { color: var(--yellow); }
.menu { display: none; align-items: center; gap: 2px; margin: 0; padding: 0; list-style: none; }
.menu > li { position: static; }
.menu-btn, .menu-link {
  display: inline-flex; align-items: center; gap: 6px;
  height: 40px; padding: 0 14px; border-radius: 999px; border: 0; background: none;
  font-size: 0.95rem; font-weight: 500; color: var(--muted); text-decoration: none; cursor: pointer;
  transition: color 0.2s, background 0.2s;
}
.menu-btn:hover, .menu-link:hover, .menu-btn[aria-expanded="true"], .menu-link[aria-current="page"] { color: var(--text); background: oklch(0.97 0.01 90 / 0.07); }
.menu-btn svg { width: 14px; height: 14px; transition: transform 0.25s var(--ease); }
.menu-btn[aria-expanded="true"] svg { transform: rotate(180deg); }
.nav-right { display: flex; align-items: center; gap: 8px; }
.nav-cta { display: none; }
.burger { width: 44px; height: 44px; border-radius: 12px; border: 0; background: none; display: grid; place-items: center; cursor: pointer; }
.burger span { display: block; width: 20px; height: 2px; background: var(--text); border-radius: 2px; box-shadow: 0 6px 0 var(--text), 0 -6px 0 var(--text); }

.mega {
  position: absolute; left: 0; right: 0; top: calc(var(--nav-h) + 10px);
  border-radius: 20px; background: var(--ink-2); border: 1px solid var(--line);
  box-shadow: 0 40px 80px -30px oklch(0 0 0 / 0.8);
  padding: 14px;
  display: grid; grid-template-columns: 1fr minmax(280px, 0.8fr); gap: 14px;
  opacity: 0; visibility: hidden; transform: translateY(-6px);
  transition: opacity 0.2s var(--ease), transform 0.25s var(--ease), visibility 0s linear 0.2s;
}
.mega.is-open { opacity: 1; visibility: visible; transform: none; transition-delay: 0s; }
.mega-links { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px; padding: 8px; align-content: start; }
.mega-links a { display: block; padding: 14px 16px; border-radius: 12px; text-decoration: none; transition: background 0.2s; }
.mega-links a:hover, .mega-links a:focus-visible { background: oklch(0.97 0.01 90 / 0.06); }
.mega-links strong { display: block; font-weight: 600; font-size: 1rem; color: var(--text); }
.mega-links span { display: block; color: var(--dim); font-size: 0.875rem; line-height: 1.45; margin-top: 2px; }
.mega-feature { position: relative; display: flex; flex-direction: column; justify-content: flex-end; min-height: 230px; border-radius: 14px; overflow: hidden; text-decoration: none; padding: 20px; isolation: isolate; }
.mega-feature img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; transition: transform 0.6s var(--ease); }
.mega-feature::after { content: ''; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, oklch(0.165 0.006 85 / 0) 25%, oklch(0.165 0.006 85 / 0.92)); }
.mega-feature:hover img { transform: scale(1.04); }
.mega-feature small { font-size: 0.75rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--yellow); }
.mega-feature b { display: block; margin-top: 6px; font-size: 1.05rem; line-height: 1.35; font-weight: 600; }

@media (min-width: 1100px) {
  .menu { display: flex; }
  .nav-cta { display: inline-flex; }
  .burger { display: none; }
}
@media (min-width: 560px) and (max-width: 1099px) { .nav-cta { display: inline-flex; } }

/* drawer (phones and tablets) */
.drawer { position: fixed; inset: 0; z-index: 60; visibility: hidden; }
.drawer.is-open { visibility: visible; }
.drawer-scrim { position: absolute; inset: 0; background: oklch(0 0 0 / 0.55); opacity: 0; transition: opacity 0.3s var(--ease); }
.drawer.is-open .drawer-scrim { opacity: 1; }
.drawer-panel {
  position: absolute; top: 0; right: 0; bottom: 0; width: min(400px, 92vw);
  background: var(--ink-2); border-left: 1px solid var(--line);
  padding: max(20px, env(safe-area-inset-top)) 22px max(24px, env(safe-area-inset-bottom));
  overflow-y: auto; transform: translateX(100%); transition: transform 0.35s var(--ease);
  display: flex; flex-direction: column;
}
.drawer.is-open .drawer-panel { transform: none; }
.drawer-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; }
.drawer-close { width: 44px; height: 44px; border-radius: 12px; border: 1px solid var(--line); background: none; cursor: pointer; display: grid; place-items: center; }
.drawer details { border-bottom: 1px solid var(--line); }
.drawer summary { list-style: none; display: flex; justify-content: space-between; align-items: center; padding: 18px 2px; font-size: 1.25rem; font-weight: 600; cursor: pointer; }
.drawer summary::-webkit-details-marker { display: none; }
.drawer summary svg { width: 18px; height: 18px; transition: transform 0.25s var(--ease); }
.drawer details[open] summary svg { transform: rotate(180deg); }
.drawer details a { display: block; padding: 10px 2px; color: var(--muted); text-decoration: none; font-size: 1.05rem; }
.drawer details div { padding-bottom: 12px; }
.drawer > .drawer-panel > a.drawer-top { display: block; padding: 18px 2px; border-bottom: 1px solid var(--line); font-size: 1.25rem; font-weight: 600; text-decoration: none; }
.drawer-foot { margin-top: auto; padding-top: 28px; display: grid; gap: 10px; }
.drawer-foot .btn { width: 100%; }

/* --------------------------------------------------------------- sections */

.s { position: relative; padding-block: var(--pad); }
.s + .s.t-same { padding-top: 0; }
.t-ink { background: var(--ink); color: var(--text); }
.t-coal { background: var(--ink-2); color: var(--text); }
.t-paper { background: var(--paper); color: var(--paper-text); color-scheme: light; }
.t-paper .lede, .t-paper .muted { color: var(--paper-muted); }
.t-yellow { background: var(--yellow); color: var(--yellow-ink); color-scheme: light; }
.t-yellow .lede { color: oklch(0.3 0.02 85); }
.sec-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px 40px; margin-bottom: clamp(20px, 2.6vw, 34px); }
.sec-head > div { max-width: 760px; }
.sec-head .lede { margin-top: 12px; }

/* reveal */
.rv { opacity: 0; transform: translateY(18px); transition: opacity 0.8s var(--ease), transform 0.8s var(--ease); }
.rv.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .rv { opacity: 1; transform: none; transition: none; } }

/* ------------------------------------------------------------------ hero */

.hero { position: relative; min-height: min(92svh, 900px); display: flex; align-items: center; padding: calc(var(--nav-h) + 40px) 0 clamp(36px, 5vw, 60px); overflow: hidden; isolation: isolate; }
.hero-media { position: absolute; inset: 0; z-index: -2; }
.hero-media video, .hero-media img { width: 100%; height: 100%; object-fit: cover; }
.hero::before { content: ''; position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(180deg, oklch(0.165 0.006 85 / 0.55) 0%, oklch(0.165 0.006 85 / 0.1) 30%, oklch(0.165 0.006 85 / 0.35) 60%, var(--ink) 100%),
    linear-gradient(90deg, oklch(0.165 0.006 85 / 0.75) 0%, oklch(0.165 0.006 85 / 0) 70%);
}
.hero .display { font-size: clamp(2.75rem, 1.5rem + 5.2vw, 6.25rem); max-width: 12ch; }
.hero .lede { margin-top: 26px; color: oklch(0.9 0.01 90); }
.hero-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px; margin-top: 32px; }
.hero-meta { display: flex; flex-wrap: wrap; gap: 8px; margin: 22px 0 0; padding: 0; list-style: none; }
.hero-meta li { padding: 7px 14px; border-radius: 999px; border: 1px solid var(--line-2); font-size: 0.875rem; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; }
.vid-toggle { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line-2); background: oklch(0.165 0.006 85 / 0.4); display: grid; place-items: center; cursor: pointer; }
.vid-toggle svg { width: 16px; height: 16px; }

/* page header: shorter, image optional */
.phead { padding: calc(var(--nav-h) + clamp(44px, 6vw, 84px)) 0 clamp(28px, 3.5vw, 48px); position: relative; overflow: hidden; isolation: isolate; }
.phead.has-img { min-height: min(58svh, 560px); display: flex; align-items: flex-end; }
.phead.has-img::before { content: ''; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, oklch(0.165 0.006 85 / 0.6) 0%, oklch(0.165 0.006 85 / 0.25) 40%, var(--ink) 100%), linear-gradient(90deg, oklch(0.165 0.006 85 / 0.7), transparent 75%); }
.phead .hero-media { position: absolute; inset: 0; z-index: -2; }
.phead .hero-media img { width: 100%; height: 100%; object-fit: cover; }
.phead .h1 { max-width: 16ch; }
.phead .lede { margin-top: 24px; }
.crumbs { display: flex; flex-wrap: wrap; gap: 8px; font-size: 0.875rem; color: var(--dim); margin: 0 0 22px; padding: 0; list-style: none; }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--text); }
.crumbs li + li::before { content: '/'; margin-right: 8px; color: var(--dim); }

/* ------------------------------------------------------------ video rails */

.rail { position: relative; }
.rail + .rail { margin-top: clamp(28px, 3.5vw, 40px); }
.rail-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; margin-bottom: 14px; }
.rail-head:not(:has(h3, p)) { display: none; }
.rail-head .h3 { font-family: var(--display); font-stretch: 72%; font-weight: 800; font-size: clamp(1.6rem, 1.2rem + 1.4vw, 2.25rem); text-transform: uppercase; letter-spacing: 0; }
.rail-head p { margin: 6px 0 0; color: var(--dim); font-size: 0.95rem; }
.rail-arrows { display: none; gap: 8px; }
.rail-arrows button { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line-2); background: none; cursor: pointer; display: grid; place-items: center; transition: background 0.2s, border-color 0.2s; }
.rail-arrows button:hover { border-color: var(--text); background: oklch(0.97 0.01 90 / 0.06); }
.rail-arrows button:disabled { opacity: 0.35; cursor: default; }
.rail-arrows svg { width: 18px; height: 18px; }
@media (min-width: 760px) and (hover: hover) {
  .rail-arrows { display: flex; }
  /* Arrows with no rail title: show them, and right under a section intro
     put them on the intro's row instead of a row of their own. */
  .rail-head:not(:has(h3, p)) { display: flex; }
  .sec-head + .rail > .rail-head:not(:has(h3, p)) { position: absolute; right: 0; bottom: calc(100% + clamp(20px, 2.6vw, 34px)); margin: 0; }
}
.rail-track {
  display: grid; grid-auto-flow: column; grid-auto-columns: min(78vw, 340px); gap: 16px;
  overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none;
  margin-inline: calc(-1 * var(--gutter)); padding: 4px var(--gutter) 12px; scroll-padding-inline: var(--gutter);
}
.rail-track::-webkit-scrollbar { display: none; }
.rail--wide .rail-track { grid-auto-columns: min(84vw, 460px); }
.rcard { display: flex; flex-direction: column; scroll-snap-align: start; text-align: left; border: 0; padding: 0; background: none; cursor: pointer; color: inherit; }
.rcard-img { position: relative; aspect-ratio: 16 / 9; border-radius: var(--r); overflow: hidden; background: var(--ink-3); }
.rcard-img img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s var(--ease), filter 0.4s; }
.rcard:hover .rcard-img img, .rcard:focus-visible .rcard-img img { transform: scale(1.05); }
.rcard-img::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 50%, oklch(0 0 0 / 0.45)); }
.play { position: absolute; left: 14px; bottom: 14px; z-index: 1; width: 46px; height: 46px; border-radius: 50%; background: var(--yellow); color: var(--yellow-ink); display: grid; place-items: center; transition: transform 0.3s var(--ease); }
.play svg { width: 18px; height: 18px; margin-left: 2px; }
.rcard:hover .play { transform: scale(1.08); }
.rcard-title { display: block; margin-top: 12px; font-weight: 600; font-size: 1rem; line-height: 1.4; }
.rcard-sub { display: block; color: var(--dim); font-size: 0.875rem; margin-top: 2px; }
.vgrid { display: grid; gap: 32px 20px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr)); }
.rail-empty { color: var(--dim); font-size: 0.95rem; padding: 18px 0; border-top: 1px dashed var(--line); }

/* -------------------------------------------------------- services list */

.svc-ctas { margin-top: 40px; }
.svc { border-top: 1px solid var(--line); counter-reset: svc; }
.svc-row { position: relative; display: grid; grid-template-columns: 56px 1fr auto; align-items: center; gap: 12px 24px; padding: 22px 0; border-bottom: 1px solid var(--line); text-decoration: none; counter-increment: svc; }
.svc-row::before { content: counter(svc, decimal-leading-zero); font-family: var(--display); font-stretch: 72%; font-weight: 800; font-size: 1.1rem; color: var(--dim); align-self: start; padding-top: 0.6em; }
.svc-row h3 { font-family: var(--display); font-stretch: 72%; font-weight: 800; text-transform: uppercase; font-size: clamp(2rem, 1.3rem + 3vw, 4rem); line-height: 0.95; margin: 0; transition: color 0.25s; }
.svc-row p { margin: 8px 0 0; color: var(--muted); max-width: 52ch; }
.svc-go { width: 52px; height: 52px; border-radius: 50%; border: 1px solid var(--line-2); display: grid; place-items: center; transition: background 0.25s, border-color 0.25s, transform 0.3s var(--ease); }
.svc-go svg { width: 20px; height: 20px; }
.svc-row:hover h3 { color: var(--yellow); }
.svc-row:hover .svc-go { background: var(--yellow); border-color: var(--yellow); color: var(--yellow-ink); transform: rotate(-45deg); }
.svc-img { display: none; }
@media (min-width: 1000px) {
  .svc-wrap { display: grid; grid-template-columns: 1fr 420px; gap: 56px; align-items: start; }
  .svc-stage { position: sticky; top: 110px; aspect-ratio: 4 / 5; border-radius: var(--r-lg); overflow: hidden; background: var(--ink-3); }
  .svc-stage img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transform: scale(1.04); transition: opacity 0.5s var(--ease), transform 0.8s var(--ease); }
  .svc-stage img.on { opacity: 1; transform: none; }
}
@media (max-width: 999px) {
  .svc-stage { display: none; }
  .svc-row { grid-template-columns: 1fr auto; }
  .svc-row::before { display: none; }
  .svc-img { display: block; grid-column: 1 / -1; aspect-ratio: 16 / 9; border-radius: var(--r); overflow: hidden; order: -1; }
  .svc-img img { width: 100%; height: 100%; object-fit: cover; }
}

/* ------------------------------------------------------- feature rows */

.rows-group + .rows-group { margin-top: clamp(40px, 5vw, 64px); }
.rows-label { display: flex; align-items: baseline; gap: 18px; margin-bottom: clamp(20px, 2.6vw, 30px); padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.t-paper .rows-label { border-color: var(--paper-line); }
.rows-label .h2 { font-size: clamp(2rem, 1.4rem + 2.6vw, 3.5rem); text-transform: uppercase; }
.rows-label span { font-family: var(--display); font-stretch: 72%; font-weight: 800; color: var(--yellow); font-size: 1.2rem; }
.t-paper .rows-label span { color: var(--paper-muted); }
.row { display: grid; gap: 28px; align-items: center; }
.row + .row { margin-top: clamp(28px, 3.5vw, 48px); }
.row-img { border-radius: var(--r-lg); overflow: hidden; aspect-ratio: 4 / 3; background: var(--ink-3); }
.t-paper .row-img { background: var(--paper-2); }
.row-img img { width: 100%; height: 100%; object-fit: cover; }
.row-img.contain { aspect-ratio: auto; background: none; border: 1px solid var(--line); }
.row-img.contain img { height: auto; object-fit: contain; }
.row-body .h3 { font-family: var(--display); font-stretch: 72%; font-weight: 800; font-size: clamp(1.9rem, 1.4rem + 1.8vw, 2.9rem); text-transform: uppercase; line-height: 0.98; letter-spacing: 0; }
.row-body .rt { margin-top: 18px; }
@media (min-width: 900px) {
  .row { grid-template-columns: 1.05fr 1fr; gap: clamp(40px, 6vw, 96px); }
  .row:nth-child(even) .row-img { order: 2; }
  .row.no-img { grid-template-columns: 1fr; max-width: 820px; }
}

/* rich text inside sections */
.rt { color: var(--muted); max-width: 64ch; }
.rt > :first-child { margin-top: 0; }
.rt > :last-child { margin-bottom: 0; }
.rt p { margin: 0 0 1em; }
.rt a { overflow-wrap: anywhere; color: var(--text); text-decoration: underline; text-decoration-color: var(--yellow); text-underline-offset: 3px; }
.rt ul, .rt ol { padding-left: 1.2em; margin: 0 0 1em; }
.rt li { margin: 0.35em 0; }
.rt li::marker { color: var(--yellow); }
.rt h3, .rt h4 { color: var(--text); font-size: 1.15rem; margin: 1.6em 0 0.5em; }
.t-paper .rt { color: var(--paper-muted); }
.t-paper .rt a, .t-paper .rt h3, .t-paper .rt h4 { color: var(--paper-text); }
.t-paper .rt li::marker { color: var(--paper-text); }
.t-yellow .rt { color: var(--yellow-ink); }

/* --------------------------------------------------------------- prose */

.prose { font-size: 1.125rem; line-height: 1.75; color: var(--paper-text); }
.t-ink .prose, .t-coal .prose { color: oklch(0.9 0.01 90); }
.prose > * { max-width: 68ch; }
.prose > :first-child { margin-top: 0; }
.prose p { margin: 0 0 1.25em; }
.prose h2 { font-family: var(--display); font-stretch: 72%; font-weight: 800; font-size: clamp(1.9rem, 1.4rem + 1.6vw, 2.6rem); line-height: 1; text-transform: uppercase; margin: 2em 0 0.6em; }
.prose h3 { font-size: 1.35rem; font-weight: 700; letter-spacing: -0.01em; line-height: 1.3; margin: 1.8em 0 0.5em; }
.prose h4 { font-size: 1.1rem; font-weight: 700; margin: 1.6em 0 0.4em; }
.prose a { overflow-wrap: anywhere; color: inherit; text-decoration: underline; text-decoration-color: var(--yellow); text-decoration-thickness: 2px; text-underline-offset: 3px; }
.prose a:hover { text-decoration-color: currentColor; }
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1.25em; }
.prose li { margin: 0.45em 0; }
.prose li::marker { color: var(--paper-muted); }
.prose blockquote { margin: 1.8em 0; padding: 0 0 0 1.25em; font-size: 1.35rem; line-height: 1.5; font-weight: 500; border: 0; position: relative; }
.prose blockquote::before { content: '\201C'; position: absolute; left: -0.1em; top: -0.35em; font-family: var(--display); font-size: 3.4rem; color: var(--yellow); line-height: 1; }
.prose figure { margin: 2em 0; max-width: 100%; }
.prose figure img { border-radius: var(--r); width: 100%; }
.prose figcaption { font-size: 0.9rem; color: var(--paper-muted); margin-top: 10px; }
.prose img { border-radius: var(--r); }
.prose hr { border: 0; height: 1px; background: var(--paper-line); margin: 2.5em 0; }
.prose table { border-collapse: collapse; width: 100%; font-size: 0.95rem; }
.prose td, .prose th { border-bottom: 1px solid var(--paper-line); padding: 10px 8px; text-align: left; vertical-align: top; }
.prose .cta a { display: inline-flex; align-items: center; min-height: 46px; padding: 0 22px; border-radius: 999px; background: var(--paper-text); color: var(--paper); text-decoration: none; font-weight: 600; }
.embed { position: relative; aspect-ratio: 16 / 9; border-radius: var(--r); overflow: hidden; background: var(--ink-2); }
.embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.embed--doc { aspect-ratio: auto; height: min(80vh, 900px); background: var(--paper-2); }

/* ------------------------------------------------------------- split */

.split { display: grid; gap: clamp(32px, 5vw, 80px); align-items: center; }
.split-img { border-radius: var(--r-lg); overflow: hidden; background: var(--ink-3); }
.split-img img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 4 / 3; }
.split .rt { margin-top: 24px; }
/* A logo beside the section title (Kufi Circle's own mark), in a circle. */
.split-title { display: flex; align-items: center; gap: clamp(14px, 1.6vw, 22px); }
.split-logo { flex: none; width: clamp(64px, 6.5vw, 92px); aspect-ratio: 1; border-radius: 50%; overflow: hidden; box-shadow: 0 0 0 1px var(--line-2), 0 12px 28px -14px oklch(0 0 0 / 0.7); }
.split-logo img { width: 100%; height: 100%; object-fit: cover; display: block; }
/* Several photos: a staggered two-column collage (Kufi Circle on home). */
.split-collage { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; padding-bottom: 36px; }
.split-collage figure { margin: 0; border-radius: var(--r-lg); overflow: hidden; background: var(--ink-3); aspect-ratio: 4 / 5; }
.split-collage figure:nth-child(even) { transform: translateY(36px); }
.split-collage img { width: 100%; height: 100%; object-fit: cover; }
@media (min-width: 900px) {
  .split { grid-template-columns: 1fr 1fr; }
  .split.img-left .split-img, .split.img-left .split-collage { order: -1; }
}

/* ------------------------------------------------------------- values */

.values { display: grid; gap: 0; border-top: 1px solid var(--line); }
.t-paper .values { border-color: var(--paper-line); }
.value { padding: 22px 0; border-bottom: 1px solid var(--line); display: grid; gap: 8px 32px; }
.t-paper .value { border-color: var(--paper-line); }
.value b { font-family: var(--display); font-stretch: 72%; font-weight: 800; font-size: clamp(1.7rem, 1.3rem + 1.4vw, 2.4rem); text-transform: uppercase; line-height: 1; }
.value p { margin: 0; color: var(--muted); max-width: 56ch; }
.t-paper .value p { color: var(--paper-muted); }
@media (min-width: 800px) { .value { grid-template-columns: minmax(220px, 0.8fr) 1.2fr; align-items: baseline; } }

/* pillars: two or three large statements (mission, vision) */
.pillars { display: grid; gap: 16px; }
.pillar { padding: clamp(28px, 4vw, 44px); border-radius: var(--r-lg); background: var(--ink-2); border: 1px solid var(--line); }
.t-paper .pillar { background: oklch(1 0 0 / 0.6); border-color: var(--paper-line); }
.pillar .h3 { font-family: var(--display); font-stretch: 72%; font-weight: 800; text-transform: uppercase; font-size: clamp(1.7rem, 1.3rem + 1.4vw, 2.4rem); color: var(--yellow); letter-spacing: 0; }
.t-paper .pillar .h3 { color: var(--paper-text); }
.pillar p { margin: 14px 0 0; font-size: 1.125rem; line-height: 1.6; }
@media (min-width: 800px) { .pillars { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); } }

/* ------------------------------------------------------------- quotes */

.quotes { display: grid; gap: 20px; }
.quote { margin: 0; padding: clamp(26px, 3vw, 36px); border-radius: var(--r-lg); background: var(--ink-2); border: 1px solid var(--line); display: flex; flex-direction: column; gap: 22px; }
.t-paper .quote { background: #fff0; background: oklch(1 0 0 / 0.65); border-color: var(--paper-line); }
.quote blockquote { margin: 0; font-size: 1.08rem; line-height: 1.65; }
.quote blockquote::before { content: '\201C'; display: block; font-family: var(--display); font-size: 3.5rem; line-height: 0.6; color: var(--yellow); margin-bottom: 10px; height: 0.45em; }
.quote figcaption { display: flex; align-items: center; gap: 14px; margin-top: auto; }
.quote figcaption img { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; background: #fff; flex: none; }
.quote figcaption b { display: block; font-weight: 600; }
.quote figcaption span { display: block; color: var(--dim); font-size: 0.9rem; }
.t-paper .quote figcaption span { color: var(--paper-muted); }
.quote-cta { margin-top: -6px; }
@media (min-width: 900px) { .quotes { grid-template-columns: repeat(3, 1fr); } .quotes--feature { grid-template-columns: repeat(2, 1fr); } .quotes--feature .quote:first-child { grid-column: 1 / -1; } .quotes--feature .quote:first-child blockquote { font-size: clamp(1.2rem, 1rem + 0.7vw, 1.5rem); line-height: 1.55; max-width: 72ch; } }

/* -------------------------------------------------------------- logos */

.logos-group + .logos-group { margin-top: 48px; }
.logos-group h3 { font-size: 0.875rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--dim); margin: 0 0 18px; }
.t-paper .logos-group h3 { color: var(--paper-muted); }
.logos { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.logo-tile { aspect-ratio: 3 / 2; border-radius: var(--r); background: oklch(0.98 0.005 90); display: grid; place-items: center; padding: 18px; }
.logo-tile img { max-height: 100%; width: auto; max-width: 100%; object-fit: contain; }

/* -------------------------------------------------------- logo strip */
/* Partners and sponsors sliding past, fading in and out at the edges, like
   the trust strip on theummah.io. Logos keep their own colours on a light chip
   so a logo drawn on white and one drawn on navy both read on the ink page. */
.s.marquee-sec { padding-block: clamp(32px, 4vw, 52px); }
.marquee-cap { text-align: center; font-size: 0.8125rem; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--dim); margin: 0 0 20px; }
.marquee { overflow: hidden; -webkit-mask-image: linear-gradient(90deg, transparent, #000 9%, #000 91%, transparent); mask-image: linear-gradient(90deg, transparent, #000 9%, #000 91%, transparent); }
.marquee-track { display: flex; width: max-content; animation: marquee-x var(--dur, 55s) linear infinite; }
.marquee:hover .marquee-track, .marquee:focus-within .marquee-track { animation-play-state: paused; }
@keyframes marquee-x { to { transform: translateX(-50%); } }
.mq-logo { flex: none; display: grid; place-items: center; height: 76px; padding: 0 28px; border-radius: 12px; text-decoration: none; }
.mq-logo img { height: var(--h, 52px); width: auto; max-width: 220px; object-fit: contain; border-radius: 10px; }
@media (max-width: 640px) {
  .mq-logo { height: 60px; padding: 0 18px; }
  .mq-logo img { height: calc(var(--h, 52px) * 0.8); }
}
.marquee-more { text-align: center; margin-top: 18px; }
/* Announcement bar above the floating nav (KufiCon until the day). */
.topbar { position: relative; z-index: 51; display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 4px 14px; min-height: 40px; padding: 8px 52px; background: oklch(0.845 0.168 91 / 0.16); color: var(--text); font-size: 0.9rem; font-weight: 600; text-align: center; }
.topbar a { display: inline-flex; align-items: center; gap: 6px; color: var(--yellow); font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }
.topbar a svg { width: 15px; height: 15px; }
.topbar-x { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); width: 36px; height: 36px; border: 0; border-radius: 50%; background: none; color: var(--muted); cursor: pointer; display: grid; place-items: center; }
.topbar-x svg { width: 14px; height: 14px; }
.tb-short { display: none; }
@media (max-width: 640px) {
  .topbar { gap: 4px 10px; padding: 8px 44px 8px 16px; font-size: 0.82rem; }
  .topbar-x { right: 4px; }
  .tb-long { display: none; } .tb-short { display: inline; }
}
@media (prefers-reduced-motion: reduce) {
  .marquee { -webkit-mask-image: none; mask-image: none; }
  .marquee-track { animation: none; width: auto; flex-wrap: wrap; justify-content: center; gap: 12px; }
  .mq-logo { margin: 0; }
  .mq-logo[aria-hidden="true"] { display: none; }
}

/* ------------------------------------------------------- post cards */

.pgrid { display: grid; gap: clamp(28px, 3vw, 40px) 24px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); }
.pcard { display: flex; flex-direction: column; text-decoration: none; }
.pcard-img { aspect-ratio: 4 / 3; border-radius: var(--r); overflow: hidden; background: var(--ink-3); }
.t-paper .pcard-img { background: var(--paper-2); }
.pcard-img img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s var(--ease); }
.pcard:hover .pcard-img img { transform: scale(1.04); }
.pcard-meta { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 16px; font-size: 0.8125rem; color: var(--dim); }
.pcard-meta b { color: var(--yellow); font-weight: 600; }
.t-paper .pcard-meta { color: var(--paper-muted); }
.t-paper .pcard-meta b { color: var(--paper-text); }
.pcard h3 { font-size: 1.2rem; line-height: 1.3; font-weight: 700; letter-spacing: -0.01em; margin: 8px 0 0; text-wrap: pretty; }
.pcard:hover h3 { text-decoration: underline; text-decoration-color: var(--yellow); text-decoration-thickness: 2px; text-underline-offset: 4px; }
.pcard p { margin: 8px 0 0; font-size: 0.95rem; line-height: 1.55; color: var(--muted); }
.t-paper .pcard p { color: var(--paper-muted); }
.pgrid--lead .pcard:first-child { grid-column: 1 / -1; }
@media (min-width: 900px) {
  .pgrid--lead .pcard:first-child { display: grid; grid-template-columns: 1.3fr 1fr; gap: 40px; align-items: center; }
  .pgrid--lead .pcard:first-child h3 { font-family: var(--display); font-stretch: 72%; font-weight: 800; text-transform: uppercase; font-size: clamp(2rem, 1.4rem + 2vw, 3.2rem); line-height: 0.98; letter-spacing: 0; }
  .pgrid--lead .pcard:first-child .pcard-meta { margin-top: 0; }
  .pgrid--lead .pcard:first-child p { font-size: 1.05rem; }
}
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 36px; padding: 0; list-style: none; }
.chip { display: inline-flex; align-items: center; min-height: 40px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--line-2); color: var(--muted); text-decoration: none; font-size: 0.92rem; font-weight: 500; background: none; cursor: pointer; }
.chip:hover { color: var(--text); border-color: var(--text); }
.chip[aria-current="page"], .chip.is-on { background: var(--yellow); border-color: var(--yellow); color: var(--yellow-ink); }
.t-paper .chip { border-color: var(--paper-line); color: var(--paper-muted); }
.t-paper .chip:hover { color: var(--paper-text); border-color: var(--paper-text); }
.t-paper .chip[aria-current="page"], .t-paper .chip.is-on { background: var(--paper-text); border-color: var(--paper-text); color: var(--paper); }

/* ------------------------------------------------------ people / team */

.people { display: grid; gap: 28px 20px; grid-template-columns: repeat(auto-fill, minmax(min(46%, 210px), 1fr)); }
.person { text-decoration: none; display: block; }
.person-img { aspect-ratio: 4 / 5; border-radius: var(--r); overflow: hidden; background: var(--ink-3); }
.t-paper .person-img { background: var(--paper-2); }
.person-img img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s var(--ease), filter 0.5s; filter: grayscale(0.25); }
a.person:hover .person-img img { transform: scale(1.04); filter: none; }
.person b { display: block; margin-top: 14px; font-size: 1.05rem; font-weight: 700; }
.person span { display: block; color: var(--dim); font-size: 0.9rem; line-height: 1.45; margin-top: 3px; }
.t-paper .person span { color: var(--paper-muted); }
.team-group + .team-group { margin-top: clamp(32px, 4vw, 52px); }
.team-group > h2 { margin-bottom: 20px; }

/* ----------------------------------------------------------- cities */

.cities { display: grid; gap: 16px; }
@media (min-width: 800px) { .cities { grid-template-columns: repeat(2, 1fr); } }
.city { position: relative; min-height: clamp(320px, 42vw, 520px); border-radius: var(--r-lg); overflow: hidden; display: flex; flex-direction: column; justify-content: flex-end; padding: clamp(24px, 3vw, 40px); text-decoration: none; isolation: isolate; }
.city img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; transition: transform 0.8s var(--ease); }
.city::after { content: ''; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, transparent 30%, oklch(0.165 0.006 85 / 0.9)); }
.city:hover img { transform: scale(1.04); }
.city .h2 { text-transform: uppercase; }
.city p { margin: 10px 0 0; color: oklch(0.9 0.01 90); max-width: 46ch; }
.city .link { margin-top: 16px; }

/* curator note + organisation grid (city pages) */
.curator { display: grid; gap: 28px; align-items: center; padding: clamp(24px, 4vw, 48px); border-radius: var(--r-lg); background: var(--ink-2); border: 1px solid var(--line); }
.t-paper .curator { background: oklch(1 0 0 / 0.6); border-color: var(--paper-line); }
.curator-img { width: 140px; aspect-ratio: 1; border-radius: 50%; overflow: hidden; }
.curator-img img { width: 100%; height: 100%; object-fit: cover; }
@media (min-width: 800px) { .curator { grid-template-columns: 180px 1fr; } .curator-img { width: 180px; } }
.orgs { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr)); margin-top: 40px; }
.org { display: flex; flex-direction: column; text-decoration: none; border-radius: var(--r-lg); overflow: hidden; background: var(--ink-2); border: 1px solid var(--line); transition: border-color 0.25s, transform 0.3s var(--ease); }
.org:hover { border-color: var(--line-2); transform: translateY(-2px); }
.org-img { aspect-ratio: 1; background: oklch(0.97 0.006 90); display: grid; place-items: center; overflow: hidden; }
.org-img img { width: 100%; height: 100%; object-fit: cover; }
.org-img.contain img { object-fit: contain; padding: 14%; }
.org-body { padding: 18px 20px 22px; }
.org-body b { display: block; font-size: 1.08rem; font-weight: 700; line-height: 1.3; }
.org-body span { display: block; font-size: 0.9rem; color: var(--dim); margin-top: 6px; line-height: 1.5; }

/* ------------------------------------------------------------ widgets */

.widget-wrap { display: grid; gap: clamp(28px, 4vw, 56px); }
/* Ummah widgets draw their own rounded white card on a transparent page.
   color-scheme must match the widget's own (light), or the browser paints the
   whole frame white behind it. */
.widget-frame iframe { width: 100%; border: 0; background: transparent; color-scheme: light; display: block; }
/* The events widget pads its own card by 16px; on a phone that doubles the gutter. */
@media (max-width: 640px) { .widget-frame { margin-inline: -16px; } }
/* The events widget cannot tell the page its height, and an event opened
   inside it is a page of its own: about 1,020px tall where it lays out side
   by side (940px and wider), about 1,650-1,740px once it stacks. Wide screens
   get the whole event (1,220px with the widget's own header and footer);
   narrower ones get a frame that fills the screen, and the event scrolls
   inside it. Extra room under a short list is fine (Hamza, 2026-10-20).
   Measured 2026-10-20 with tools/measure-events-widget.js. */
.widget-frame--events iframe { height: var(--h, max(600px, calc(100svh - 110px))); }
@media (min-width: 940px) { .widget-frame--events iframe { height: var(--h, 1220px); } }
/* With a mouse, the frame starts sized to the event list (its card's bottom
   plus the widget's own 24px and 3px spare, measured 2026-10-21) and site.js
   adds .is-open, back to the full height above, the moment someone clicks
   inside it. Touch screens keep the full height: a tap into a cross-origin
   frame is not reliably detectable there. */
@media (min-width: 940px) and (hover: hover) and (pointer: fine) {
  .widget-frame--events:not(.is-open) iframe { height: var(--h, calc(31vw + 258px)); }
}
@media (min-width: 1104px) and (hover: hover) and (pointer: fine) {
  .widget-frame--events:not(.is-open) iframe { height: var(--h, calc(25vw + 244px)); }
}
@media (min-width: 1280px) and (hover: hover) and (pointer: fine) {
  .widget-frame--events:not(.is-open) iframe { height: var(--h, 560px); }
}
.widget-note { font-size: 0.9rem; color: var(--dim); margin-top: 14px; }
.t-yellow .widget-note { color: oklch(0.3 0.02 85); }

/* the join band: Kufi yellow, the one place the color carries the whole surface */
.join { display: grid; gap: 36px; align-items: center; }
.join .display { font-size: clamp(3rem, 1.6rem + 6vw, 7rem); }
/* Without a perks list the band is one centred column: the page's last word. */
.join.join--solo { grid-template-columns: 1fr; justify-items: center; text-align: center; }
.join--solo .lede { margin-inline: auto; max-width: 40ch; }
.join--solo .btns { justify-content: center; }
.join-perks { margin: 0; padding: 0; list-style: none; display: grid; gap: 0; border-top: 1px solid oklch(0.21 0.02 85 / 0.2); }
.join-perks li { padding: 16px 0; border-bottom: 1px solid oklch(0.21 0.02 85 / 0.2); font-weight: 500; display: flex; gap: 14px; }
.join-perks li::before { content: ''; flex: none; width: 10px; height: 10px; margin-top: 0.5em; border-radius: 50%; background: var(--yellow-ink); }
@media (min-width: 900px) { .join { grid-template-columns: 1.2fr 1fr; gap: 80px; } }

/* -------------------------------------------------------------- embeds */

.doc-embed { border-radius: var(--r-lg); overflow: hidden; background: #fff; }
.doc-embed iframe { width: 100%; height: var(--h, 900px); border: 0; }
.map { border-radius: var(--r-lg); overflow: hidden; aspect-ratio: 16 / 9; background: var(--ink-2); }
.map iframe { width: 100%; height: 100%; border: 0; filter: grayscale(0.3) contrast(1.05); }

/* -------------------------------------------------------------- forms */

.formwrap { display: grid; gap: clamp(32px, 5vw, 72px); align-items: start; }
@media (min-width: 960px) { .formwrap { grid-template-columns: 1fr 1.15fr; } }
.form { display: grid; gap: 18px; padding: clamp(24px, 3.5vw, 40px); border-radius: var(--r-lg); background: var(--ink-2); border: 1px solid var(--line); }
.t-paper .form { background: #fff; border-color: var(--paper-line); box-shadow: 0 30px 60px -40px oklch(0.2 0.01 85 / 0.35); }
.field { display: grid; gap: 8px; }
.field label { font-weight: 600; font-size: 0.95rem; }
.field label i { font-style: normal; color: var(--dim); font-weight: 400; }
.field input, .field textarea, .field select {
  width: 100%; min-height: 50px; padding: 12px 16px; border-radius: 12px;
  border: 1px solid var(--line-2); background: var(--ink); color: var(--text); font: inherit; font-size: 1rem;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.t-paper .field input, .t-paper .field textarea, .t-paper .field select { background: var(--paper); border-color: var(--paper-line); color: var(--paper-text); }
.field textarea { min-height: 150px; resize: vertical; }
.field input:focus, .field textarea:focus, .field select:focus { outline: none; border-color: var(--yellow); box-shadow: 0 0 0 3px oklch(0.845 0.168 91 / 0.3); }
.form > * { grid-column: 1 / -1; }
@media (min-width: 640px) { .form { grid-template-columns: 1fr 1fr; } .form > .field.half { grid-column: auto; } }
.form-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 20px; }
.hp { position: absolute; left: -9999px; }
.form-status { margin: 0; font-size: 0.95rem; min-height: 1.5em; }
.form-status.ok { color: oklch(0.8 0.15 150); }
.t-paper .form-status.ok { color: oklch(0.45 0.13 150); }
.form-status.err { color: oklch(0.75 0.15 30); }
.t-paper .form-status.err { color: oklch(0.5 0.17 30); }
.contact-list { display: grid; gap: 0; margin: 28px 0 0; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.t-paper .contact-list { border-color: var(--paper-line); }
.contact-list li { padding: 18px 0; border-bottom: 1px solid var(--line); display: grid; gap: 2px; }
.t-paper .contact-list li { border-color: var(--paper-line); }
.contact-list small { font-size: 0.8125rem; font-weight: 600; letter-spacing: 0.05em; text-transform: uppercase; color: var(--dim); }
.t-paper .contact-list small { color: var(--paper-muted); }
.contact-list a, .contact-list span { font-size: 1.15rem; font-weight: 600; text-decoration: none; }

/* -------------------------------------------------------------- plans */

.plans { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); align-items: stretch; }
.plan { display: flex; flex-direction: column; padding: 28px; border-radius: var(--r-lg); background: var(--ink-2); border: 1px solid var(--line); }
.plan.is-featured { background: var(--yellow); color: var(--yellow-ink); border-color: var(--yellow); }
.plan-name { font-family: var(--display); font-stretch: 72%; font-weight: 800; font-size: 1.9rem; text-transform: uppercase; line-height: 1; }
.plan-price { margin: 18px 0 4px; font-size: 2.6rem; font-weight: 800; letter-spacing: -0.03em; line-height: 1; }
.plan-price small { font-size: 1rem; font-weight: 500; letter-spacing: 0; color: var(--dim); }
.plan.is-featured .plan-price small { color: oklch(0.3 0.02 85); }
.plan ul { margin: 22px 0 26px; padding: 0; list-style: none; display: grid; gap: 10px; font-size: 0.95rem; }
.plan li { display: flex; gap: 10px; line-height: 1.45; }
.plan li::before { content: ''; flex: none; width: 16px; height: 16px; margin-top: 3px; border-radius: 50%; background: var(--yellow) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4.5 8.2l2.2 2.2 4.8-4.8' fill='none' stroke='%23231f17' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 100% no-repeat; }
.plan.is-featured li::before { background-color: var(--yellow-ink); background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4.5 8.2l2.2 2.2 4.8-4.8' fill='none' stroke='%23f1c40f' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); }
.plan .btns { margin-top: auto; flex-direction: column; }
.plan .btn { width: 100%; }
.plan.is-featured .btn { --b: var(--yellow-ink); --c: var(--yellow); }
.plan.is-featured .btn--line { --b: oklch(0.21 0.02 85 / 0.3); --c: var(--yellow-ink); background: transparent; }

/* --------------------------------------------------------------- steps */

.steps { counter-reset: st; display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); margin: 0; padding: 0; list-style: none; }
.step { counter-increment: st; padding: 26px; border-radius: var(--r-lg); border: 1px solid var(--line); }
.t-paper .step { border-color: var(--paper-line); background: oklch(1 0 0 / 0.5); }
.step::before { content: counter(st, decimal-leading-zero); display: block; font-family: var(--display); font-stretch: 72%; font-weight: 800; font-size: 2.4rem; line-height: 1; color: var(--yellow); margin-bottom: 18px; }
.t-paper .step::before { color: var(--paper-text); }
.step b { display: block; font-size: 1.1rem; }
.step p { margin: 8px 0 0; color: var(--muted); font-size: 0.97rem; }
.t-paper .step p { color: var(--paper-muted); }

/* ---------------------------------------------------- CTA band */

.cta-band { display: grid; gap: 28px; align-items: end; }
.cta-band .h2 { font-size: clamp(2.5rem, 1.5rem + 4vw, 5.5rem); text-transform: uppercase; max-width: 14ch; }
@media (min-width: 900px) { .cta-band { grid-template-columns: 1.4fr 1fr; } .cta-band .btns { justify-content: flex-end; } }

/* ------------------------------------------------ treaded path archive */

.tp-tools { display: grid; gap: 12px; margin-bottom: 32px; }
.tp-filters { display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 180px), 1fr)); }
.tp-filters select, .tp-search { width: 100%; min-height: 48px; padding: 0 40px 0 16px; border-radius: 12px; border: 1px solid var(--paper-line); background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4 6l4 4 4-4' fill='none' stroke='%23423e35' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") right 14px center / 14px no-repeat; color: var(--paper-text); font: inherit; font-size: 0.95rem; appearance: none; }
.tp-search { background-image: none; padding-right: 16px; }
.tp-count { display: flex; justify-content: space-between; align-items: center; gap: 12px; font-size: 0.95rem; color: var(--paper-muted); }
.tp-count button { border: 0; background: none; text-decoration: underline; cursor: pointer; color: var(--paper-text); font-weight: 600; }
.tp-list { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr)); }
.tp-card { display: grid; grid-template-columns: 112px 1fr; gap: 18px; padding: 14px; border-radius: var(--r-lg); background: #fff; border: 1px solid var(--paper-line); text-decoration: none; transition: border-color 0.2s, transform 0.3s var(--ease), box-shadow 0.3s; }
.tp-card:hover { border-color: var(--paper-text); transform: translateY(-2px); box-shadow: 0 24px 40px -30px oklch(0.2 0.01 85 / 0.5); }
.tp-thumb { aspect-ratio: 1; border-radius: 10px; overflow: hidden; background: var(--paper-text); display: grid; place-items: center; }
.tp-thumb img { width: 100%; height: 100%; object-fit: cover; }
.tp-thumb span { font-family: var(--display); font-stretch: 72%; font-weight: 800; color: var(--yellow); font-size: 2.2rem; }
.tp-card b { display: block; font-size: 1.08rem; line-height: 1.3; }
.tp-card .tp-role { display: block; color: var(--paper-muted); font-size: 0.92rem; line-height: 1.45; margin-top: 4px; }
.tp-tags { display: flex; flex-wrap: wrap; gap: 6px; margin: 12px 0 0; padding: 0; list-style: none; }
.tp-tags li { font-size: 0.78rem; font-weight: 600; padding: 4px 10px; border-radius: 999px; background: var(--paper-2); color: var(--paper-text); }
.tp-empty { padding: 40px; text-align: center; border: 1px dashed var(--paper-line); border-radius: var(--r-lg); color: var(--paper-muted); }

/* ------------------------------------------------------------- jobs */

.jobs { display: grid; gap: 0; border-top: 1px solid var(--line); }
.job { display: grid; grid-template-columns: 1fr auto; gap: 8px 24px; align-items: center; padding: 24px 0; border-bottom: 1px solid var(--line); text-decoration: none; }
.job b { font-size: 1.25rem; font-weight: 700; }
.job span { color: var(--dim); font-size: 0.92rem; }
.job:hover b { color: var(--yellow); }
.job .svc-go { width: 44px; height: 44px; }
.job:hover .svc-go { background: var(--yellow); border-color: var(--yellow); color: var(--yellow-ink); }

/* ---------------------------------------------------------- article */

.article-head { position: relative; isolation: isolate; overflow: hidden; padding: calc(var(--nav-h) + clamp(40px, 6vw, 80px)) 0 clamp(24px, 3vw, 40px); }
.article-head > .hero-media { position: absolute; inset: 0; z-index: -2; }
.article-head > .hero-media img { width: 100%; height: 100%; object-fit: cover; }
.article-head.has-img::before { content: ''; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, oklch(0.165 0.006 85 / 0.72), oklch(0.165 0.006 85 / 0.55) 45%, var(--ink)), linear-gradient(90deg, oklch(0.165 0.006 85 / 0.6), transparent 80%); }
.article-head .h1 { font-size: clamp(2.4rem, 1.5rem + 4vw, 4.75rem); max-width: 20ch; text-transform: none; line-height: 0.98; }
.article-meta { display: flex; flex-wrap: wrap; gap: 8px 18px; align-items: center; margin-top: 26px; font-size: 0.95rem; color: var(--muted); }
.article-meta a { color: var(--yellow); text-decoration: none; font-weight: 600; }
.article-cover { margin-top: clamp(32px, 5vw, 56px); border-radius: var(--r-lg); overflow: hidden; background: var(--ink-2); }
.article-cover img { width: 100%; max-height: 78vh; object-fit: cover; }
/* A cover or episode video opening the article body sits below the header
   with clear space, never over its edge (Hamza, 2026-10-21). */
.article-body .article-cover:first-child { margin-top: 0; margin-bottom: clamp(28px, 4vw, 48px); }
.article-body { padding-top: clamp(28px, 4vw, 48px); }
.article-body .prose { margin-inline: auto; max-width: 720px; }
.article-aside { max-width: 720px; margin: 36px auto 0; padding-top: 28px; border-top: 1px solid var(--paper-line); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px; align-items: center; font-size: 0.95rem; color: var(--paper-muted); }
.share { display: flex; gap: 8px; }
.share a, .share button { width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--paper-line); display: grid; place-items: center; color: var(--paper-text); background: none; cursor: pointer; text-decoration: none; }
.share a:hover, .share button:hover { border-color: var(--paper-text); }
.share svg { width: 17px; height: 17px; }

/* treaded path profile */
.profile-tags { display: flex; flex-wrap: wrap; gap: 8px; margin: 24px 0 0; padding: 0; list-style: none; }
.profile-tags li { padding: 7px 14px; border-radius: 999px; border: 1px solid var(--line-2); font-size: 0.875rem; font-weight: 500; color: var(--muted); }
.profile-tags b { color: var(--text); font-weight: 600; }

/* team member */
.member { display: grid; gap: clamp(32px, 5vw, 72px); align-items: start; }
.member-photo { border-radius: var(--r-lg); overflow: hidden; aspect-ratio: 4 / 5; background: var(--ink-2); }
.member-photo img { width: 100%; height: 100%; object-fit: cover; }
@media (min-width: 900px) { .member { grid-template-columns: 0.8fr 1.2fr; } .member-photo { position: sticky; top: 110px; } }

/* --------------------------------------------------------- gallery */

.gallery { display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(min(46%, 220px), 1fr)); }
.gallery button { padding: 0; border: 0; background: var(--ink-3); border-radius: 12px; overflow: hidden; aspect-ratio: 1; cursor: zoom-in; }
.gallery img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s var(--ease); }
.gallery button:hover img { transform: scale(1.05); }
.gallery--lead button:first-child { grid-column: span 2; grid-row: span 2; }

/* --------------------------------------------------------- dialogs */

.dlg { border: 0; padding: 0; background: transparent; color: var(--text); max-width: none; max-height: none; width: 100%; height: 100%; }
.dlg::backdrop { background: oklch(0.1 0.005 85 / 0.88); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); }
.dlg-in { position: fixed; inset: 0; display: grid; place-items: center; padding: max(16px, env(safe-area-inset-top)) 16px max(16px, env(safe-area-inset-bottom)); }
.dlg-close { position: fixed; top: max(14px, env(safe-area-inset-top)); right: 14px; z-index: 2; width: 48px; height: 48px; border-radius: 50%; border: 1px solid var(--line-2); background: var(--ink-2); display: grid; place-items: center; cursor: pointer; }
.dlg-close svg { width: 18px; height: 18px; }
.player-wrap { width: min(1280px, 100%, (100dvh - 150px) * 16 / 9); }
.player-frame { width: 100%; aspect-ratio: 16 / 9; border-radius: var(--r); overflow: hidden; background: #000; }
.player-frame iframe, .player-frame video { width: 100%; height: 100%; border: 0; }
.player-title { margin-top: 14px; text-align: center; font-weight: 600; color: var(--muted); }
.join-box { width: min(480px, 100%); display: flex; flex-direction: column; gap: 14px; }
.join-head b { display: block; font-size: 1.35rem; font-weight: 700; letter-spacing: -0.01em; }
.join-head small { display: block; margin-top: 2px; color: var(--muted); font-size: 0.95rem; }
/* With a mouse: tall enough for the whole member form so the dialog scrolls,
   not the form (Hamza, 2026-10-21). The form's length is set by Kufi's
   community questions in the Ummah portal and changes with them: 636px on
   10-21, 1,576px (1,628px at 448px wide) on 10-23, measured with a short
   frame. Re-measure after they edit the questions. The frame's corners follow
   the widget card's 16px radius. Touch screens: see below. */
.join-box iframe { width: 100%; height: 1600px; border: 0; border-radius: 16px; background: transparent; color-scheme: light; display: block; }
@media (max-width: 479px) { .join-box iframe { height: 1660px; } }
#join .dlg-in { display: flex; flex-direction: column; align-items: center; overflow-y: auto; overscroll-behavior: contain; }
#join .join-box { margin-block: auto; padding-block: 56px 24px; }
/* Touch screens: a finger on the cross-origin form scrolls the form, and iOS
   never hands that scroll out to the dialog around it, so a form taller than
   the screen left its Submit button out of reach (Hamza, 2026-10-23). There
   the form fills the space under the heading and scrolls inside itself. */
@media (hover: none), (pointer: coarse) {
  #join .dlg-in { overflow: hidden; }
  #join .join-box { flex: 1; min-height: 0; margin: 0; padding-block: 56px 4px; }
  #join .join-frame { flex: 1; min-height: 0; }
  #join .join-box iframe { height: 100%; }
}
/* Hidden until the widget has its data (site.js adds .is-ready); a quiet
   spinner holds the space meanwhile. */
.join-frame { position: relative; }
.join-frame iframe { opacity: 0; transition: opacity 0.3s cubic-bezier(0.25, 1, 0.5, 1); }
#join.is-ready .join-frame iframe { opacity: 1; }
.join-frame::before { content: ''; position: absolute; left: 50%; top: 38%; width: 28px; height: 28px; margin: -14px 0 0 -14px; border-radius: 50%;
  border: 2px solid var(--line-2); border-top-color: var(--yellow); animation: join-spin 0.8s linear infinite; transition: opacity 0.2s; }
#join.is-ready .join-frame::before { opacity: 0; animation: none; }
@keyframes join-spin { to { transform: rotate(1turn); } }
@media (prefers-reduced-motion: reduce) { .join-frame::before { animation: none; } }
.lb-img { max-width: min(1400px, 100%); max-height: calc(100vh - 120px); width: auto; height: auto; border-radius: 10px; }
.lb-nav { position: fixed; top: 50%; transform: translateY(-50%); width: 52px; height: 52px; border-radius: 50%; border: 1px solid var(--line-2); background: var(--ink-2); display: grid; place-items: center; cursor: pointer; z-index: 2; }
.lb-nav svg { width: 20px; height: 20px; }
.lb-prev { left: 14px; }
.lb-next { right: 14px; }
.lb-count { position: fixed; bottom: max(16px, env(safe-area-inset-bottom)); left: 50%; transform: translateX(-50%); color: var(--muted); font-size: 0.9rem; }

/* Kufi Circle popup: a centred card in a dialog (Kufi's call, 2026-10-20). */
.nudge { position: relative; width: min(420px, 100%); padding: 30px 26px 26px; border-radius: 22px; background: var(--yellow); color: var(--yellow-ink); box-shadow: 0 30px 60px -20px oklch(0 0 0 / 0.6); }
.nudge-dlg[open] .nudge { animation: nudge-in 0.45s var(--ease); }
@keyframes nudge-in { from { opacity: 0; transform: translateY(18px) scale(0.98); } }
.nudge b { display: block; padding-right: 36px; font-family: var(--display); font-stretch: 72%; font-weight: 800; font-size: 2.1rem; text-transform: uppercase; line-height: 0.95; }
.nudge p { margin: 12px 0 20px; font-size: 1rem; line-height: 1.5; }
.nudge .btns { margin: 0; }
.nudge .btn { --b: var(--yellow-ink); --c: var(--yellow); }
.nudge .btn--line { --b: oklch(0.21 0.02 85 / 0.3); --c: var(--yellow-ink); background: transparent; }
.nudge-x { position: absolute; top: 12px; right: 12px; width: 40px; height: 40px; border: 0; background: none; border-radius: 50%; cursor: pointer; display: grid; place-items: center; color: var(--yellow-ink); }
.nudge-x svg { width: 16px; height: 16px; }
@media (prefers-reduced-motion: reduce) { .nudge-dlg[open] .nudge { animation: none; } }

/* ------------------------------------------------------------- footer */

.foot { background: oklch(0.13 0.005 85); padding: clamp(40px, 5vw, 64px) 0 28px; border-top: 1px solid var(--line); }
.foot-top { display: grid; gap: 48px; }
.foot-brand img { width: 112px; height: auto; }
.foot-brand p { color: var(--muted); max-width: 38ch; margin: 22px 0 0; }
.foot-social { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 24px; }
.foot-social a { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line-2); display: grid; place-items: center; transition: background 0.2s, border-color 0.2s, color 0.2s; }
.foot-social a:hover { background: var(--yellow); border-color: var(--yellow); color: var(--yellow-ink); }
.foot-social svg { width: 18px; height: 18px; }
.foot-cols { display: grid; gap: 36px 24px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.foot-cols h2 { font-size: 0.8125rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--dim); margin: 0 0 16px; }
.foot-cols ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.foot-cols a { color: var(--muted); text-decoration: none; font-size: 0.95rem; }
.foot-cols a:hover { color: var(--text); }
@media (min-width: 1000px) { .foot-top { grid-template-columns: 0.9fr 2fr; gap: 64px; } .foot-cols { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.foot-contact { margin-top: 36px; padding-top: 28px; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: 14px 32px; color: var(--muted); font-size: 0.95rem; }
.foot-contact a { color: var(--muted); text-decoration: none; }
.foot-contact a:hover { color: var(--text); }
.foot-base { margin-top: 28px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 24px; color: var(--dim); font-size: 0.875rem; }
.foot-base a { color: var(--muted); }
.foot-meta { display: flex; flex-wrap: wrap; gap: 6px 18px; }
.foot-meta a { color: var(--dim); text-decoration: none; }
.foot-meta a:hover { color: var(--text); }
.credit a { color: var(--text); font-weight: 600; text-decoration: underline; text-decoration-color: var(--yellow); text-underline-offset: 3px; }

/* --------------------------------------------- admin preview edit chrome */
/* Only the admin's preview build carries data-k / data-section; these rules
   never match anything on the public site. */
[data-section] { position: relative; }
