:root { color-scheme: light; }
html.dark { color-scheme: dark; }

html { scroll-behavior: smooth; }

body {
  font-family: Tajawal, sans-serif;
  text-rendering: optimizeLegibility;
}

[data-theme-choice][aria-pressed="true"] {
  background: #ffffff;
  color: #0c3b34;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
}

html.dark [data-theme-choice][aria-pressed="true"] {
  background: #0f172a;
  color: #f3e6cc;
}

.nav-panel.is-open {
  display: flex;
}
@media (min-width: 1024px) {
  #navPanel.nav-panel {
    position: static;
    display: flex;
    flex: 1 1 auto;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    min-width: 0;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    backdrop-filter: none;
  }
  #navPanel.nav-panel > a {
    white-space: nowrap;
  }
  #navToggle { display: none; }
}

#lightbox.is-open {
  display: grid;
}

:root {
  --ysr-ticker-size: 2.15rem;
}
body.has-ticker {
  --ysr-ticker-font: var(--ysr-ticker-size);
  padding-bottom: calc(var(--ysr-ticker-font) * 2.5 + env(safe-area-inset-bottom, 0px));
}
.ysr-ticker {
  position: fixed;
  inset-inline: 0;
  bottom: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  gap: 16px;
  --ysr-ticker-font: var(--ysr-ticker-size);
  min-width: 0;
  height: calc(var(--ysr-ticker-font) * 2.5);
  padding: 0 1.25rem env(safe-area-inset-bottom, 0px);
  border: 0;
  border-top: 1px solid rgba(14, 165, 233, 0.22);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 -12px 32px rgba(15, 23, 42, 0.08);
  backdrop-filter: blur(16px);
}
.ysr-ticker[hidden] { display: none; }
html.dark .ysr-ticker {
  border-top-color: rgba(56, 189, 248, 0.28);
  background: rgba(9, 13, 22, 0.94);
  box-shadow: 0 -12px 32px rgba(0, 0, 0, 0.35);
}
.ysr-ticker__badge {
  flex: 0 0 auto;
  border-radius: 999px;
  background: transparent;
  color: #0ea5e9;
  font-size: calc(var(--ysr-ticker-font) * 0.56);
  font-weight: 800;
  line-height: 1;
  padding: 8px 4px;
  white-space: nowrap;
}
html.dark .ysr-ticker__badge {
  background: transparent;
  color: #38bdf8;
}
.ysr-ticker__view {
  min-width: 0;
  flex: 1;
  overflow: hidden;
  direction: ltr;
  font-size: var(--ysr-ticker-font);
}
.ysr-ticker__track {
  display: flex;
  direction: ltr;
  width: max-content;
  animation: ysr-ticker-move 36s linear infinite;
}
.ysr-ticker:hover .ysr-ticker__track { animation-play-state: paused; }
.ysr-ticker__item {
  display: inline-flex;
  align-items: center;
  gap: 28px;
  padding-inline: 22px;
  direction: rtl;
  white-space: nowrap;
  color: #0ea5e9;
  font-size: var(--ysr-ticker-font);
  font-weight: 800;
  line-height: calc(var(--ysr-ticker-font) * 2.5);
}
html.dark .ysr-ticker__item { color: #38bdf8; }
.ysr-ticker__ch {
  display: inline;
}
.ysr-ticker__link {
  color: inherit;
  text-decoration: none;
}
.ysr-ticker__link:hover { color: #0284c7; }
html.dark .ysr-ticker__link:hover { color: #7dd3fc; }
.ysr-ticker__mark {
  width: auto;
  height: calc(var(--ysr-ticker-font) * 1.47);
  flex: 0 0 auto;
  object-fit: contain;
}
@keyframes ysr-ticker-move {
  from { transform: translate3d(-50%, 0, 0); }
  to { transform: translate3d(0, 0, 0); }
}
@media (max-width: 639px) {
  body.has-ticker,
  .ysr-ticker { --ysr-ticker-font: calc(var(--ysr-ticker-size) * 0.72); }
  .ysr-ticker { gap: 10px; padding-inline: 12px; }
  .ysr-ticker__item { gap: 18px; }
}

.ysr-board {
  background: #ffffff;
}
.ysr-board__photo {
  position: absolute;
  z-index: 1;
  top: 0;
  left: 50%;
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  transform: translate(-50%, -50%);
  border-radius: 999px;
  object-fit: cover;
  box-shadow: 0 8px 18px rgba(14, 165, 233, 0.22), 0 0 0 3px #38bdf8;
}
.ysr-board-card--lead .ysr-board__photo {
  box-shadow: 0 10px 22px rgba(14, 165, 233, 0.28), 0 0 0 4px #38bdf8;
}
.ysr-board-card {
  position: relative;
  width: 100%;
  max-width: 15rem;
  margin-top: 8.25rem;
  padding: 0 0 0.9rem;
  border: 1px solid #38bdf8;
  background: #f3fbfe;
  box-shadow: none;
  transition: transform 0.3s ease, border-color 0.3s ease;
}
.ysr-board-card--lead {
  max-width: 19rem;
  margin-top: 10.25rem;
  border-color: #38bdf8;
}
.ysr-board-card::before {
  content: "";
  display: block;
  width: 100%;
  align-self: stretch;
  padding-top: 50%;
}
.ysr-board-card > p,
.ysr-board-card > h3 { padding-inline: 0.75rem; }
.ysr-board-card:hover {
  transform: translateY(-4px);
  border-color: #0ea5e9;
  box-shadow: none;
}
.ysr-swiper .swiper-slide { height: auto; }
.ysr-copy {
  text-align: justify;
  text-align-last: start;
  text-justify: inter-word;
}
@media (min-width: 1024px) {
  .ysr-copy > span {
    display: block;
    overflow: hidden;
    white-space: nowrap;
    line-height: 2rem;
    text-align: justify;
    text-align-last: justify;
  }
}
.ysr-pager .swiper-pagination-bullet {
  width: 8px;
  height: 8px;
  margin: 0 4px !important;
  border: 0;
  border-radius: 999px;
  background: #cbd5e1;
  opacity: 1;
  transition: width 0.35s ease, background 0.35s ease;
}
.ysr-pager .swiper-pagination-bullet-active { width: 28px; background: #0c3b34; }
html.dark .ysr-pager .swiper-pagination-bullet { background: rgba(255, 255, 255, 0.22); }
html.dark .ysr-pager .swiper-pagination-bullet-active { background: #c4a36a; }
.ysr-progress > span { transform: scaleX(0); }
@media (prefers-reduced-motion: no-preference) {
  .ysr-reveal { opacity: 0; transform: translateY(18px); }
  .swiper-slide-active .ysr-reveal { animation: ysr-rise 0.7s cubic-bezier(0.22, 1, 0.36, 1) forwards; }
  .swiper-slide-active .ysr-d2 { animation-delay: 0.08s; }
  .swiper-slide-active .ysr-d3 { animation-delay: 0.16s; }
  .swiper-slide-active .ysr-d4 { animation-delay: 0.24s; }
}
@keyframes ysr-rise {
  to { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation: none !important;
    transition: none !important;
  }
}
