/* ============================================================
   خُيُوط — عرض تفاعلي عن التطريز اليدوي
   ============================================================ */

:root {
  --ivory: #f7f2e8;
  --paper: #fdfaf4;
  --beige: #e9dfcd;
  --rose: #cda9a2;
  --rose-soft: #ead6d0;
  --rose-text: #9c746c;
  --olive: #6f7550;
  --olive-dark: #565c3d;
  --gold: #b99a61;
  --gold-text: #7d6335;
  --ink: #403b33;
  --ink-soft: #6d665a;
  --line: rgba(111, 117, 80, 0.2);
  --shadow: 0 18px 45px rgba(82, 70, 48, 0.09);
  --radius: 18px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  height: 100%;
  overflow: hidden;
}

body {
  font-family: "Cairo", "Tajawal", "Segoe UI", Tahoma, sans-serif;
  color: var(--ink);
  background: var(--ivory);
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; }
button { font: inherit; cursor: pointer; }
svg { display: block; }

/* ---------- الخلفية النسيجية ---------- */
.fabric-bg {
  position: fixed;
  inset: 0;
  z-index: -3;
  background:
    radial-gradient(ellipse at 12% 8%, rgba(205, 169, 162, 0.2), transparent 46%),
    radial-gradient(ellipse at 88% 92%, rgba(111, 117, 80, 0.16), transparent 48%),
    repeating-linear-gradient(45deg, rgba(255, 255, 255, 0.24) 0 2px, transparent 2px 5px),
    repeating-linear-gradient(-45deg, rgba(120, 105, 80, 0.025) 0 2px, transparent 2px 6px),
    var(--ivory);
}

.thread-decor {
  position: fixed;
  width: 230px;
  height: 70vh;
  top: 12vh;
  z-index: -2;
  pointer-events: none;
  opacity: 0.35;
}
.thread-decor--one { right: -60px; }
.thread-decor--two { left: -60px; transform: scaleX(-1); }
.thread-decor svg { width: 100%; height: 100%; }
.thread-decor path {
  fill: none;
  stroke: var(--gold);
  stroke-width: 1.4;
  stroke-dasharray: 7 9;
  stroke-linecap: round;
}

/* ---------- الهيكل العام ---------- */
.app {
  position: relative;
  height: 100vh;
  height: 100dvh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.progress-track {
  flex: none;
  height: 4px;
  background: rgba(111, 117, 80, 0.13);
}
.progress-bar {
  height: 100%;
  width: 12.5%;
  border-radius: 0 4px 4px 0;
  background: linear-gradient(90deg, var(--olive), var(--gold));
  transition: width 0.55s cubic-bezier(0.4, 0, 0.2, 1);
}

.topbar {
  flex: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 10px clamp(16px, 4vw, 54px);
}

.brand { display: flex; align-items: center; gap: 10px; }
.brand-mark {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 1px solid var(--gold);
  background: rgba(255, 255, 255, 0.5);
}
.brand-mark svg { width: 20px; height: 20px; fill: none; stroke: var(--olive); stroke-width: 1.2; }
.brand-mark circle { fill: var(--rose-soft); }
.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-text strong { font-size: 1.05rem; font-weight: 800; letter-spacing: 0.02em; }
.brand-text small { font-size: 0.62rem; color: var(--ink-soft); letter-spacing: 0.04em; }

.top-actions { display: flex; align-items: center; gap: 8px; }

/* ---------- الأزرار ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.62);
  color: var(--ink);
  border-radius: 999px;
  padding: 0.5rem 0.95rem;
  font-size: 0.8rem;
  font-weight: 700;
  transition: transform 0.25s, background 0.25s, border-color 0.25s, box-shadow 0.25s;
}
.btn:hover { transform: translateY(-2px); background: var(--paper); border-color: var(--gold); }
.btn:active { transform: translateY(0); }
.btn:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }
.btn svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.btn--start { background: var(--olive); color: #fff; border-color: var(--olive); }
.btn--start:hover { background: var(--olive-dark); color: #fff; }
.btn--start svg { fill: currentColor; stroke: none; }
.btn--icon { width: 38px; height: 38px; padding: 0; border-radius: 50%; }
.btn--icon .icon-shrink { display: none; }
body.is-fullscreen .btn--icon .icon-expand { display: none; }
body.is-fullscreen .btn--icon .icon-shrink { display: block; }
.btn--cta {
  background: var(--olive);
  color: #fff;
  border-color: var(--olive);
  padding: 0.72rem 1.4rem;
  font-size: 0.9rem;
  box-shadow: 0 10px 26px rgba(86, 92, 61, 0.22);
}
.btn--cta:hover { background: var(--olive-dark); color: #fff; box-shadow: 0 14px 30px rgba(86, 92, 61, 0.28); }
.btn--restart { margin-top: 0.4rem; }

/* ---------- المسرح والشرائح ---------- */
.stage {
  position: relative;
  flex: 1;
  min-height: 0;
}

.slide {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(10px, 2.4vh, 30px) clamp(16px, 4vw, 64px);
  opacity: 0;
  visibility: hidden;
  transform: translateY(16px) scale(0.992);
  transition: opacity 0.55s ease, transform 0.55s ease, visibility 0.55s;
  overflow: hidden;
}
.slide.is-active {
  opacity: 1;
  visibility: visible;
  transform: none;
  z-index: 2;
}

.slide-shell {
  width: 100%;
  max-width: 1180px;
  max-height: 100%;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--beige) transparent;
}

/* حركات ظهور المحتوى */
.reveal { opacity: 0; transform: translateY(18px); }
.slide.is-active .reveal {
  animation: revealIn 0.72s cubic-bezier(0.2, 0.75, 0.25, 1) both;
  animation-delay: calc(var(--d, 0) * 65ms);
}
@keyframes revealIn {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: none; }
}

/* ---------- عناصر مشتركة ---------- */
.eyebrow {
  margin: 0 0 0.5rem;
  font-size: clamp(0.62rem, 1vw, 0.74rem);
  font-weight: 700;
  letter-spacing: 0.16em;
  color: var(--gold-text);
  text-transform: uppercase;
}
.slide-title {
  margin: 0 0 0.7rem;
  font-size: clamp(1.4rem, 3.2vw, 2.45rem);
  font-weight: 800;
  line-height: 1.28;
  letter-spacing: -0.02em;
  color: var(--ink);
}
.section-head { margin-bottom: clamp(12px, 2.2vh, 26px); }
.section-head--center { text-align: center; }
.section-intro {
  margin: 0;
  max-width: 620px;
  font-size: clamp(0.78rem, 1.2vw, 0.95rem);
  color: var(--ink-soft);
  line-height: 1.85;
}
.section-intro--wide { max-width: 800px; margin-inline: auto; }

img { object-fit: cover; }

/* ============================================================
   الشريحة ١ — الغلاف
   ============================================================ */
.cover-grid {
  width: 100%;
  max-width: 1160px;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  align-items: center;
  gap: clamp(24px, 5vw, 70px);
}
.cover-title {
  margin: 0 0 1rem;
  font-size: clamp(2.1rem, 5vw, 4.2rem);
  font-weight: 800;
  line-height: 1.22;
  letter-spacing: -0.035em;
}
.title-dots { color: var(--rose-text); }
.title-line {
  display: block;
  font-size: 0.62em;
  font-weight: 600;
  color: var(--olive);
  letter-spacing: -0.01em;
  margin-top: 0.25em;
}
.cover-sub {
  margin: 0 0 1.2rem;
  font-size: clamp(0.95rem, 1.8vw, 1.3rem);
  color: var(--ink-soft);
  font-weight: 500;
}
.cover-rule {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 190px;
  margin-bottom: 1.6rem;
  color: var(--gold-text);
}
.cover-rule span { height: 1px; flex: 1; background: var(--line); }
.cover-rule i { font-style: normal; font-size: 0.9rem; }
.cover-visual { position: relative; }
.portrait-frame {
  position: relative;
  width: 100%;
  max-width: 430px;
  height: clamp(260px, 52vh, 500px);
  margin-inline: auto;
  border-radius: 180px 180px 22px 22px;
  overflow: hidden;
  border: 6px solid var(--paper);
  box-shadow: var(--shadow);
}
.portrait-frame img { width: 100%; height: 100%; object-fit: cover; filter: saturate(0.86) sepia(0.06); }
.frame-corner {
  position: absolute;
  width: 46px;
  height: 46px;
  border: 2px solid var(--gold);
  opacity: 0.75;
}
.frame-corner--tl { top: 14px; right: 14px; border-left: 0; border-bottom: 0; border-radius: 0 24px 0 0; }
.frame-corner--br { bottom: 14px; left: 14px; border-right: 0; border-top: 0; border-radius: 24px 0 0 0; }
.cover-note {
  position: absolute;
  bottom: 8%;
  left: -10px;
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 10px 14px;
  box-shadow: var(--shadow);
}
.cover-note__num { font-size: 1.5rem; font-weight: 800; color: var(--rose-text); line-height: 1; }
.cover-note__text { font-size: 0.68rem; line-height: 1.6; color: var(--ink-soft); }

/* ============================================================
   الشريحة ٢ — التعريف
   ============================================================ */
.definition-grid {
  width: 100%;
  max-width: 1120px;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  align-items: center;
  gap: clamp(30px, 6vw, 90px);
}
.quote-mark {
  font-family: Georgia, serif;
  font-size: 4rem;
  line-height: 0.5;
  color: var(--rose-soft);
  height: 26px;
}
.lead {
  margin: 0 0 1.4rem;
  font-size: clamp(0.92rem, 1.55vw, 1.18rem);
  line-height: 2.05;
  color: var(--ink-soft);
  font-weight: 500;
  max-width: 610px;
}
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.55);
  color: var(--olive);
  border-radius: 999px;
  padding: 0.35rem 0.85rem;
  font-size: 0.74rem;
  font-weight: 700;
}
.definition-visual { margin: 0; text-align: center; }
.arch-frame {
  width: 100%;
  max-width: 370px;
  height: clamp(240px, 48vh, 450px);
  margin-inline: auto;
  border-radius: 190px 190px 16px 16px;
  overflow: hidden;
  border: 1px solid var(--gold);
  box-shadow: var(--shadow);
  padding: 7px;
  background: var(--paper);
}
.arch-frame img { width: 100%; height: 100%; border-radius: 185px 185px 10px 10px; filter: saturate(0.88); }
.definition-visual figcaption {
  margin-top: 0.7rem;
  font-size: 0.72rem;
  color: var(--ink-soft);
  letter-spacing: 0.03em;
}

/* ============================================================
   الشريحة ٣ — الأنواع
   ============================================================ */
.types-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(8px, 1vw, 13px);
}
.type-card {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  background: rgba(255, 255, 255, 0.58);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 9px;
  min-width: 0;
  transition: transform 0.3s, box-shadow 0.3s, border-color 0.3s;
}
.type-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: var(--gold); }
.type-card__img {
  width: 78px;
  height: 82px;
  flex: none;
  border-radius: 10px;
  overflow: hidden;
  background: var(--beige);
}
.type-card__img img { width: 100%; height: 100%; filter: saturate(0.85); transition: transform 0.5s; }
.type-card:hover .type-card__img img { transform: scale(1.07); }
.type-card__body { min-width: 0; }
.type-card__body h3 {
  margin: 0.1rem 0 0.3rem;
  font-size: clamp(0.72rem, 1.05vw, 0.88rem);
  font-weight: 800;
  line-height: 1.4;
  color: var(--ink);
}
.type-card__body h3 span {
  display: block;
  font-family: "Tajawal", sans-serif;
  font-size: 0.68em;
  font-weight: 500;
  color: var(--gold-text);
  direction: ltr;
  text-align: right;
}
.type-card__body p {
  margin: 0;
  font-size: clamp(0.63rem, 0.85vw, 0.72rem);
  line-height: 1.65;
  color: var(--ink-soft);
}

/* ============================================================
   الشريحة ٤ — الأدوات
   ============================================================ */
.tools-grid {
  width: 100%;
  max-width: 1120px;
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  align-items: center;
  gap: clamp(24px, 5vw, 70px);
}
.tools-visual { margin: 0; }
.tools-photo {
  position: relative;
  width: 100%;
  height: clamp(230px, 52vh, 470px);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 7px solid var(--paper);
}
.tools-photo::after {
  content: "";
  position: absolute;
  inset: 10px;
  border: 1px dashed rgba(255, 255, 255, 0.75);
  border-radius: 12px;
  pointer-events: none;
}
.tools-photo img { width: 100%; height: 100%; filter: saturate(0.8) sepia(0.05); }
.tools-visual figcaption {
  margin-top: 0.7rem;
  text-align: center;
  font-size: 0.72rem;
  color: var(--ink-soft);
}
.tool-list { list-style: none; margin: 0; padding: 0; display: grid; gap: clamp(4px, 0.8vh, 9px); }
.tool-list li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 0.42rem 0.6rem;
  border-bottom: 1px dashed var(--line);
}
.tool-list li:last-child { border-bottom: 0; }
.tool-list .num {
  flex: none;
  width: 27px;
  height: 27px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--rose-soft);
  color: var(--olive-dark);
  font-size: 0.75rem;
  font-weight: 800;
}
.tool-list strong { display: block; font-size: clamp(0.8rem, 1.15vw, 0.95rem); font-weight: 800; }
.tool-list p { margin: 1px 0 0; font-size: clamp(0.68rem, 0.95vw, 0.79rem); color: var(--ink-soft); line-height: 1.6; }

/* ============================================================
   الشريحة ٥ — الاستخدامات
   ============================================================ */
.uses-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(9px, 1.2vw, 16px);
}
.use-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 8px 20px rgba(82, 70, 48, 0.05);
  transition: transform 0.3s, box-shadow 0.3s;
}
.use-card:hover { transform: translateY(-5px); box-shadow: var(--shadow); }
.use-card__img { height: clamp(90px, 17vh, 165px); overflow: hidden; }
.use-card__img img { width: 100%; height: 100%; filter: saturate(0.82); transition: transform 0.5s; }
.use-card:hover .use-card__img img { transform: scale(1.06); }
.use-card h3 {
  margin: 0.6rem 0.9rem 0.15rem;
  font-size: clamp(0.82rem, 1.2vw, 1rem);
  font-weight: 800;
}
.use-card p {
  margin: 0 0.9rem 0.75rem;
  font-size: clamp(0.66rem, 0.9vw, 0.78rem);
  color: var(--ink-soft);
  line-height: 1.6;
}

/* ============================================================
   الشريحة ٦ — التراث والحداثة
   ============================================================ */
.era-grid {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: clamp(12px, 2.5vw, 34px);
}
.era-card {
  background: rgba(255, 255, 255, 0.55);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.era-card img {
  width: 100%;
  height: clamp(110px, 21vh, 200px);
  filter: saturate(0.78) sepia(0.06);
}
.era-card--modern img { filter: saturate(0.9); }
.era-card__body { padding: 0.7rem 1rem 1rem; text-align: center; }
.era-card__body h3 { margin: 0 0 0.3rem; font-size: clamp(0.9rem, 1.4vw, 1.15rem); font-weight: 800; }
.era-card--heritage .era-card__body h3 { color: var(--olive-dark); }
.era-card--modern .era-card__body h3 { color: var(--rose); }
.era-card__body p { margin: 0; font-size: clamp(0.68rem, 0.95vw, 0.8rem); color: var(--ink-soft); line-height: 1.7; }
.era-bridge { display: flex; align-items: center; gap: 8px; color: var(--gold); }
.era-bridge__line { width: clamp(16px, 3vw, 48px); height: 1px; background: var(--gold); opacity: 0.6; }
.era-bridge__star { font-size: 1.1rem; }

/* ============================================================
   الشريحة ٧ — المشروع الإبداعي
   ============================================================ */
.project-grid {
  width: 100%;
  max-width: 1120px;
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  align-items: center;
  gap: clamp(24px, 5vw, 70px);
}
.project-visual { margin: 0; }
.project-photo {
  height: clamp(240px, 50vh, 450px);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--gold);
  box-shadow: var(--shadow);
  padding: 7px;
  background: var(--paper);
}
.project-photo img { width: 100%; height: 100%; border-radius: 12px; filter: saturate(0.85); }
.project-visual figcaption { margin-top: 0.7rem; text-align: center; font-size: 0.72rem; color: var(--ink-soft); }
.project-list { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(6px, 1vh, 12px); }
.project-item {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  background: rgba(255, 255, 255, 0.55);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.6rem 0.75rem;
}
.project-item span { color: var(--gold-text); font-size: 1rem; line-height: 1.2; }
.project-item p { margin: 0; font-size: clamp(0.7rem, 0.95vw, 0.82rem); line-height: 1.65; color: var(--ink-soft); }

/* ============================================================
   الشريحة ٨ — الخاتمة
   ============================================================ */
.slide--ending { text-align: center; }
.ending-bg { position: absolute; inset: 0; z-index: -1; }
.ending-bg img { width: 100%; height: 100%; opacity: 0.16; filter: saturate(0.5) sepia(0.2); }
.ending-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at center, rgba(247, 242, 232, 0.62) 0%, rgba(247, 242, 232, 0.94) 75%);
}
.ending-inner { max-width: 720px; position: relative; }
.ending-emblem { width: 62px; height: 62px; margin: 0 auto 0.9rem; }
.ending-emblem svg { width: 100%; height: 100%; fill: none; stroke: var(--gold); stroke-width: 1; opacity: 0.8; }
.ending-emblem circle:last-child { fill: var(--rose-soft); stroke: none; }
.ending-title {
  margin: 0 0 1rem;
  font-size: clamp(1.9rem, 5vw, 3.6rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.2;
}
.ending-text {
  margin: 0 auto 1.2rem;
  max-width: 600px;
  font-size: clamp(0.88rem, 1.5vw, 1.12rem);
  line-height: 2;
  color: var(--ink-soft);
}
.ending-quote {
  margin: 0 auto 1.4rem;
  padding: 0.75rem 1.2rem;
  max-width: 610px;
  border-right: 3px solid var(--gold);
  background: rgba(255, 255, 255, 0.5);
  font-size: clamp(0.95rem, 1.7vw, 1.3rem);
  font-weight: 700;
  line-height: 1.9;
  color: var(--olive-dark);
  text-align: right;
}

/* ---------- شريط التنقل ---------- */
.bottombar {
  flex: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 8px clamp(16px, 4vw, 54px) 14px;
}
.nav-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 110px;
  justify-content: center;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.55);
  color: var(--ink);
  border-radius: 999px;
  padding: 0.5rem 1rem;
  font-size: 0.82rem;
  font-weight: 700;
  transition: background 0.25s, border-color 0.25s, transform 0.25s, opacity 0.25s;
}
.nav-btn svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.nav-btn:hover:not(:disabled) { background: var(--paper); border-color: var(--gold); transform: translateY(-2px); }
.nav-btn:disabled { opacity: 0.32; cursor: not-allowed; }
.nav-btn--next { background: var(--rose-soft); border-color: var(--rose); color: var(--ink); }
.nav-btn--next:hover:not(:disabled) { background: var(--rose); color: #fff; border-color: var(--rose); }

.counter {
  display: flex;
  align-items: baseline;
  gap: 7px;
  color: var(--ink-soft);
  font-size: 0.8rem;
}
.counter__label { font-size: 0.7rem; margin-left: 3px; }
.counter__current { font-size: 1.35rem; font-weight: 800; color: var(--olive); line-height: 1; }
.counter__sep { opacity: 0.4; }
.counter__total { font-size: 0.95rem; font-weight: 700; }

/* ---------- طبقة البداية ---------- */
.intro-overlay {
  position: absolute;
  inset: 66px 0 0;
  z-index: 30;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(247, 242, 232, 0.86);
  backdrop-filter: blur(9px);
  -webkit-backdrop-filter: blur(9px);
  transition: opacity 0.6s ease, visibility 0.6s;
}
.intro-overlay.is-hidden { opacity: 0; visibility: hidden; pointer-events: none; }
.intro-card {
  width: 100%;
  max-width: 480px;
  text-align: center;
  background: var(--paper);
  border: 1px solid var(--gold);
  border-radius: 26px;
  padding: clamp(26px, 5vh, 48px) clamp(22px, 4vw, 44px);
  box-shadow: 0 30px 70px rgba(82, 70, 48, 0.14);
}
.intro-ornament { font-size: 1.6rem; color: var(--gold); margin-bottom: 0.6rem; }
.intro-card h2 { margin: 0.2rem 0 0.2rem; font-size: clamp(1.8rem, 5vw, 2.7rem); font-weight: 800; letter-spacing: -0.03em; }
.intro-sub { margin: 0 0 1rem; font-size: clamp(1rem, 2.2vw, 1.3rem); color: var(--olive); font-weight: 600; }
.intro-rule { width: 80px; height: 1px; background: var(--gold); margin: 0 auto 1rem; position: relative; }
.intro-rule::after { content: "✦"; position: absolute; top: -10px; right: 35px; background: var(--paper); padding: 0 6px; color: var(--gold); font-size: 0.8rem; }
.intro-note { margin: 0 0 1.5rem; font-size: 0.83rem; line-height: 1.9; color: var(--ink-soft); }
.intro-hint { margin: 1.1rem 0 0; font-size: 0.68rem; color: var(--ink-soft); opacity: 0.8; }

/* ============================================================
   الاستجابة للشاشات
   ============================================================ */
@media (max-width: 1000px) {
  .types-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .type-card { align-items: flex-start; }
  .cover-grid, .definition-grid, .tools-grid, .project-grid { gap: 24px; }
}

@media (max-width: 720px) {
  .topbar { padding: 8px 14px; }
  .intro-overlay { inset: 58px 0 0; }
  .brand-text small { display: none; }
  .brand-text strong { font-size: 0.95rem; }
  .btn--start span { display: none; }
  .btn--start { width: 38px; height: 38px; padding: 0; border-radius: 50%; }
  .slide { padding: 10px 14px; }
  .bottombar { padding: 6px 14px 10px; }
  .nav-btn { min-width: 84px; padding: 0.45rem 0.7rem; font-size: 0.75rem; }
  .counter__label { display: none; }

  .cover-grid, .definition-grid, .tools-grid, .project-grid { grid-template-columns: 1fr; }
  .cover-copy { text-align: center; }
  .cover-rule { margin-inline: auto; }
  .portrait-frame { height: clamp(170px, 30vh, 280px); max-width: 300px; border-radius: 130px 130px 18px 18px; }
  .cover-note { left: 50%; transform: translateX(-50%); bottom: -12px; }
  .cover-visual { margin-bottom: 12px; }
  .definition-visual, .tools-visual, .project-visual { display: block; }
  .arch-frame { max-width: 220px; height: 150px; border-radius: 112px 112px 12px 12px; padding: 4px; margin-top: 10px; }
  .arch-frame img { border-radius: 108px 108px 8px 8px; }
  .tools-photo { height: 150px; border-width: 4px; }
  .project-photo { height: 160px; padding: 4px; }
  .definition-visual figcaption, .tools-visual figcaption, .project-visual figcaption { margin-top: 0.35rem; font-size: 0.62rem; }

  .section-head { margin-bottom: 12px; }
  .section-intro { line-height: 1.7; }
  .type-card { flex-direction: column; gap: 6px; padding: 7px; }
  .type-card__img { width: 100%; height: 54px; }
  .type-card__body h3 span { text-align: right; }
  .uses-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .use-card__img { height: 66px; }
  .use-card h3 { margin: 0.4rem 0.6rem 0.1rem; font-size: 0.78rem; }
  .use-card p { margin: 0 0.6rem 0.5rem; font-size: 0.63rem; line-height: 1.5; }
  .era-grid { grid-template-columns: 1fr; gap: 8px; }
  .era-bridge { flex-direction: column; }
  .era-bridge__line { width: 1px; height: 14px; }
  .era-card { display: grid; grid-template-columns: 105px 1fr; align-items: center; }
  .era-card img { height: 80px; }
  .era-card__body { text-align: right; padding: 0.5rem 0.7rem; }
  .project-list { grid-template-columns: 1fr; gap: 5px; }
  .ending-quote { text-align: center; border-right: 0; border-top: 2px solid var(--gold); }
  .ending-text { line-height: 1.85; }
  .thread-decor { display: none; }
}

@media (max-width: 400px) {
  .type-card__body p { font-size: 0.6rem; }
  .uses-grid { grid-template-columns: 1fr 1fr; }
  .use-card__img { height: 64px; }
  .tool-list p { font-size: 0.65rem; }
}

@media (max-height: 620px) and (min-width: 721px) {
  .portrait-frame, .arch-frame, .tools-photo, .project-photo { height: 46vh; }
  .use-card__img { height: 120px; }
  .era-card img { height: 130px; }
  .type-card__img { height: 70px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
  .reveal { opacity: 1; transform: none; }
}
