/* rabeh.qa — hero layout, the how-it-works carousel, and the closing panel.
   Split out of site.css to keep each file legible. */

/* ── hero ── */
.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.75fr);
  gap: 2.5rem;
  align-items: center;
}
.hero-mark {
  display: grid;
  place-items: center;
}
.hero-mark img {
  width: min(100%, 340px);
  height: auto;
  /* The mark is a flat red logo; a soft halo stops it floating on the cream. */
  filter: drop-shadow(0 18px 40px rgba(192, 57, 43, 0.18));
}
@media (max-width: 860px) {
  .hero-grid {
    grid-template-columns: 1fr;
  }
  .hero-mark {
    order: -1;
    justify-items: start;
  }
  .hero-mark img {
    width: 132px;
  }
}

.statband {
  padding-block: 0 clamp(1rem, 3vw, 2rem);
  margin-top: -1.5rem;
}

/* ── callout ── */
.callout {
  border-inline-start: 3px solid var(--rabeh-gold);
  background: var(--bg-accent);
  padding: 1rem 1.2rem;
  border-radius: 0 8px 8px 0;
  font-size: 0.92rem;
  color: var(--ink-2);
  max-width: 62ch;
}
:root[dir="rtl"] .callout {
  border-radius: 8px 0 0 8px;
}

/* ── carousel ── */
.carousel-viewport {
  overflow: hidden;
  border: 1px solid var(--rule);
  border-radius: 14px;
  background: var(--bg-raised);
  box-shadow: var(--shadow-s);
}
.carousel-track {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  transition: transform 0.45s cubic-bezier(0.4, 0, 0.2, 1);
}
@media (prefers-reduced-motion: reduce) {
  .carousel-track {
    transition: none;
  }
}
.slide {
  flex: 0 0 100%;
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  gap: 2rem;
  align-items: center;
  padding: clamp(1.4rem, 3vw, 2.6rem);
}
@media (max-width: 720px) {
  .slide {
    grid-template-columns: 1fr;
    gap: 1.2rem;
  }
}
.slide-art {
  background: var(--bg-accent);
  border-radius: 10px;
  padding: 1.2rem;
}
.art {
  width: 100%;
  height: auto;
  display: block;
}
.art .a-line,
.art .a-thin,
.art .a-arrow,
.art .a-tick,
.art .a-dot {
  fill: none;
  stroke: var(--rabeh-red);
  stroke-linecap: round;
  stroke-linejoin: round;
}
.art .a-line {
  stroke-width: 2;
}
.art .a-thin {
  stroke-width: 1.4;
  opacity: 0.5;
}
.art .a-arrow {
  stroke-width: 2.2;
}
.art .a-tick {
  stroke-width: 2.2;
  stroke: var(--bg-raised);
}
.art .a-dot {
  stroke-width: 2;
  fill: var(--rabeh-gold-soft);
}
.art .a-fill {
  fill: var(--rabeh-red);
  stroke: none;
  opacity: 0.92;
}

.step-n {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--rabeh-gold);
  display: block;
  margin-bottom: 0.5rem;
}
.slide-copy h3 {
  font-size: clamp(1.25rem, 2.6vw, 1.7rem);
  margin-bottom: 0.6rem;
}
.slide-copy p {
  color: var(--ink-2);
  max-width: 46ch;
}

.carousel-controls {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-top: 1.2rem;
}
.cbtn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid var(--rule-strong);
  background: var(--bg-raised);
  color: var(--ink-2);
  display: grid;
  place-items: center;
  cursor: pointer;
  flex-shrink: 0;
}
.cbtn:hover {
  border-color: var(--rabeh-red);
  color: var(--rabeh-red);
}
.cbtn svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
/* One arrow symbol, mirrored for "previous" — and again for RTL, where the
   reading direction flips what forward looks like. */
.cbtn svg.flip {
  transform: scaleX(-1);
}
:root[dir="rtl"] .cbtn svg {
  transform: scaleX(-1);
}
:root[dir="rtl"] .cbtn svg.flip {
  transform: scaleX(1);
}

.dots {
  display: flex;
  gap: 0.45rem;
}
.dots button {
  width: 30px;
  height: 4px;
  border-radius: 2px;
  border: 0;
  padding: 0;
  background: var(--rule-strong);
  cursor: pointer;
  transition: background 0.2s;
}
.dots button[aria-selected="true"] {
  background: var(--rabeh-red);
}

/* ── closing panel ── */
.cta-panel {
  background: var(--bg-raised);
  border: 1px solid var(--rule);
  border-radius: 14px;
  padding: clamp(1.6rem, 3.5vw, 2.6rem);
  box-shadow: var(--shadow-m);
  display: flex;
  flex-wrap: wrap;
  gap: 1.6rem;
  align-items: center;
  justify-content: space-between;
}
.cta-panel > div {
  max-width: 56ch;
}
.cta-panel p {
  color: var(--ink-2);
}

/* ── citations (partner briefing) ── */
.cite {
  font-size: 0.68em;
  font-family: var(--font-mono);
  line-height: 1;
  white-space: nowrap;
  margin-inline-start: 1px;
}
.cite a {
  text-decoration: none;
  color: var(--rabeh-gold);
  font-weight: 600;
  padding: 0 1px;
}
.cite a:hover {
  color: var(--rabeh-red);
  text-decoration: underline;
}
th .cite a {
  color: inherit;
}

ol.sources {
  counter-reset: src;
  list-style: none;
  padding: 0;
  display: grid;
  gap: 0.55rem;
  max-width: 84ch;
}
ol.sources li {
  counter-increment: src;
  position: relative;
  padding-inline-start: 2.6rem;
  font-size: 0.89rem;
  line-height: 1.5;
}
ol.sources li::before {
  content: "[" counter(src) "]";
  position: absolute;
  inset-inline-start: 0;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--rabeh-gold);
}
ol.sources a {
  color: var(--ink);
  text-decoration: none;
  border-bottom: 1px solid var(--rule-strong);
}
ol.sources a:hover {
  color: var(--rabeh-red);
  border-bottom-color: var(--rabeh-red);
}
ol.sources .mono {
  display: block;
  font-size: 0.72rem;
  direction: ltr;
  text-align: start;
}

/* ── table of contents (partner briefing) ── */
nav.toc {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 0.35rem;
  max-width: 900px;
}
nav.toc a {
  text-decoration: none;
  color: var(--ink-2);
  font-size: 0.9rem;
  padding: 0.45rem 0.6rem;
  border-radius: 6px;
  border: 1px solid transparent;
}
nav.toc a:hover {
  color: var(--ink);
  background: var(--bg-raised);
  border-color: var(--rule);
}
nav.toc .mono {
  color: var(--rabeh-gold);
  font-size: 0.72rem;
  margin-inline-end: 0.3rem;
}

/* A "forward" arrow points the way the text reads, so it mirrors in Arabic. */
:root[dir="rtl"] .ico-inline {
  transform: scaleX(-1);
}
