/* THE WHY OSCE — تخصيص متقدم (CSS)
   النسخة الكحلية الذهبية التفاعلية — تعمل مع ملف osce-custom.js
   تُطبَّق على الصفحة الرئيسية فقط (html.wy-home) */

:root {
  --wy-navy: #103B59;
  --wy-navy-deep: #0B2A40;
  --wy-navy-card: #16476B;
  --wy-line: #24557A;
  --wy-gold: #D6A84B;
  --wy-gold-light: #EBD39A;
  --wy-ivory: #F7F4ED;
  --wy-mist: #C9D5E0;
  --wy-ease: cubic-bezier(.2, .8, .2, 1);
}

/* ===== الخلفية العامة للصفحة الرئيسية ===== */
html.wy-home main#main-content {
  background: var(--wy-navy-deep);
  color: var(--wy-ivory);
  font-family: "Noto Sans Arabic", sans-serif;
  overflow-x: hidden;
}
html.wy-home .s-block--photos-slider { display: none !important; }

/* ===== البطل (Hero) ===== */
.wy-hero {
  max-width: 1200px; margin: 0 auto;
  padding: 64px 20px 96px;
  display: flex; flex-wrap: wrap; align-items: center; gap: 48px;
}
.wy-hero__text { flex: 999 1 480px; min-width: 0; display: flex; flex-direction: column; gap: 20px; }
.wy-hero__art { flex: 1 1 280px; display: flex; justify-content: center; perspective: 1400px; padding: 20px 0; }
.wy-pill {
  align-self: flex-start;
  border: 1px solid rgba(214, 168, 75, .55); color: var(--wy-gold-light);
  padding: 6px 16px; border-radius: 999px; font-size: 14px;
}
.wy-hero h1 {
  margin: 0; font-family: "Noto Kufi Arabic", sans-serif; font-weight: 700;
  font-size: clamp(38px, 6vw, 72px); line-height: 1.2; color: var(--wy-ivory);
}
.wy-goldtxt {
  background: linear-gradient(90deg, var(--wy-gold), #F6E7BF, var(--wy-gold), #F6E7BF);
  background-size: 200% 100%;
  -webkit-background-clip: text; background-clip: text; color: transparent;
  animation: wy-shine 6s linear infinite;
}
@keyframes wy-shine { from { background-position: 200% 0; } to { background-position: -200% 0; } }
.wy-hero p { margin: 0; font-size: 18px; line-height: 1.9; color: var(--wy-mist); max-width: 560px; }

.wy-stats { display: flex; flex-wrap: wrap; gap: 0; border-top: 1px solid var(--wy-line); border-bottom: 1px solid var(--wy-line); margin-top: 6px; }
.wy-stat { flex: 1 1 110px; padding: 14px 10px; text-align: center; border-inline-start: 1px solid var(--wy-line); }
.wy-stat:first-child { border-inline-start: 0; }
.wy-stat b { display: block; font-family: "GFS Didot", serif; font-size: 26px; color: var(--wy-gold); font-weight: 400; }
.wy-stat span { font-size: 13px; color: var(--wy-mist); }

.wy-cta-row { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; margin-top: 6px; }
.wy-btn {
  display: inline-block; background: var(--wy-gold); color: var(--wy-navy-deep) !important;
  padding: 16px 32px; border-radius: 999px; font-weight: 600; font-size: 17px; text-decoration: none;
  transition: transform .3s var(--wy-ease), background .3s;
}
.wy-btn:hover { transform: translateY(-3px); background: var(--wy-gold-light); }
.wy-btn-ghost {
  display: inline-block; background: transparent; color: var(--wy-gold-light) !important;
  border: 1px solid var(--wy-gold); padding: 15px 26px; border-radius: 999px; font-size: 16px; text-decoration: none;
  transition: background .3s, color .3s, transform .3s var(--wy-ease);
}
.wy-btn-ghost:hover { background: rgba(214, 168, 75, .14); transform: translateY(-3px); }
.wy-price { display: flex; flex-direction: column; line-height: 1.3; }
.wy-price b { font-size: 22px; color: var(--wy-ivory); }
.wy-price s { font-size: 14px; color: var(--wy-mist); }
.wy-note { font-size: 13px; color: var(--wy-mist); }

/* كتاب ثلاثي الأبعاد يطفو */
.wy-book {
  position: relative; width: 260px; height: 360px;
  transform-style: preserve-3d;
  animation: wy-float 6s ease-in-out infinite;
}
@keyframes wy-float {
  0%, 100% { transform: rotateY(-24deg) rotateX(6deg) translateY(0); }
  50%      { transform: rotateY(-16deg) rotateX(4deg) translateY(-14px); }
}
.wy-book__cover {
  position: absolute; inset: 0; border-radius: 4px 14px 14px 4px;
  background: var(--wy-ivory); border: 1px solid rgba(214, 168, 75, .5);
  box-shadow: 30px 40px 60px rgba(0, 0, 0, .45);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  direction: ltr; text-align: center; padding: 24px; box-sizing: border-box;
}
.wy-book__cover .t1 { font-family: "GFS Didot", serif; font-size: 22px; color: var(--wy-navy); letter-spacing: 2px; }
.wy-book__cover .t2 { font-family: "GFS Didot", serif; font-size: 64px; color: var(--wy-gold); line-height: 1; }
.wy-book__cover .t3 { font-family: "GFS Didot", serif; font-size: 48px; color: var(--wy-navy); line-height: 1; }
.wy-book__cover .rule { width: 70%; height: 1px; background: var(--wy-gold); margin: 12px 0 8px; }
.wy-book__cover .t4 { font-family: "GFS Didot", serif; font-size: 17px; color: var(--wy-navy); }
.wy-book__cover .t5 { font-size: 11px; color: #53636D; margin-top: 26px; letter-spacing: 1px; }
.wy-book__spine {
  position: absolute; top: 6px; bottom: 6px; left: -14px; width: 14px;
  background: var(--wy-gold); border-radius: 3px 0 0 3px;
}

/* ===== شريط متحرك ===== */
.wy-marquee {
  border-top: 1px solid rgba(214, 168, 75, .3); border-bottom: 1px solid rgba(214, 168, 75, .3);
  padding: 16px 0; overflow: hidden; direction: ltr;
}
.wy-marquee__track {
  display: flex; gap: 44px; width: max-content; white-space: nowrap;
  font-family: "Noto Kufi Arabic", sans-serif; font-size: 19px; color: var(--wy-gold-light);
  animation: wy-marquee 32s linear infinite;
}
.wy-marquee__track i { color: var(--wy-gold); font-style: normal; }
@keyframes wy-marquee { from { transform: translateX(0); } to { transform: translateX(50%); } }

/* ===== الفصول (محدّد تفاعلي) ===== */
.wy-chapters { background: var(--wy-ivory); color: var(--wy-navy); }
.wy-chapters__in {
  max-width: 1200px; margin: 0 auto; padding: 88px 20px;
  display: flex; flex-wrap: wrap; gap: 40px;
}
.wy-chapters__side { flex: 1 1 340px; min-width: 0; }
.wy-chapters h2, .wy-flow h2 {
  margin: 0 0 10px; font-family: "Noto Kufi Arabic", sans-serif; font-size: clamp(28px, 4vw, 42px);
}
.wy-chapters__side p { margin: 0 0 24px; color: #53636D; font-size: 17px; }
.wy-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.wy-chip {
  font-family: inherit; font-size: 14px; padding: 10px 16px; border-radius: 999px; cursor: pointer;
  border: 1px solid #CDBB8C; background: transparent; color: var(--wy-navy);
  transition: background .25s, color .25s, border-color .25s;
}
.wy-chip:hover { border-color: var(--wy-gold); }
.wy-chip.is-on { background: var(--wy-navy); color: var(--wy-gold-light); border-color: var(--wy-navy); }
.wy-panel {
  flex: 999 1 480px; min-width: 0; background: var(--wy-navy); color: var(--wy-ivory);
  border-radius: 24px; padding: 36px; box-sizing: border-box; min-height: 300px;
}
.wy-panel__num { font-family: "GFS Didot", serif; font-size: 60px; color: var(--wy-gold); line-height: 1; }
.wy-panel__en { direction: ltr; text-align: right; font-size: 15px; color: var(--wy-gold-light); letter-spacing: .5px; margin-top: 6px; }
.wy-panel h3 { margin: 10px 0 18px; font-family: "Noto Kufi Arabic", sans-serif; font-size: 28px; color: var(--wy-ivory); }
.wy-panel ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.wy-panel li {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 16px;
  padding: 12px 0; border-bottom: 1px solid var(--wy-line); font-size: 16px;
  animation: wy-rise .5s var(--wy-ease) both;
}
.wy-panel li em { font-style: normal; direction: ltr; color: var(--wy-mist); font-size: 14px; }
@keyframes wy-rise { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }

/* ===== كيف بُني كل موضوع (خطوات متحركة) ===== */
.wy-flow { max-width: 1200px; margin: 0 auto; padding: 88px 20px; }
.wy-flow > p { margin: 0 0 32px; color: var(--wy-mist); font-size: 17px; }
.wy-steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; }
.wy-step {
  font-family: inherit; text-align: right; cursor: pointer;
  background: transparent; border: 1px solid var(--wy-line); border-radius: 16px; color: var(--wy-ivory);
  padding: 20px; display: flex; flex-direction: column; gap: 8px;
  transition: border-color .4s, background .4s, transform .4s var(--wy-ease);
}
.wy-step b { font-family: "GFS Didot", serif; font-size: 28px; color: var(--wy-gold); font-weight: 400; }
.wy-step span { font-size: 16px; }
.wy-step small { font-size: 13px; color: var(--wy-gold-light); opacity: 0; transition: opacity .4s; }
.wy-step.is-on { border-color: var(--wy-gold); background: var(--wy-navy-card); transform: translateY(-6px); }
.wy-step.is-on small { opacity: 1; }
.wy-step.is-red.is-on { border-color: #C94C4C; }

/* ===== جرّب الكتاب: أسئلة WHY ===== */
html.wy-home .wy-hidden { display: none !important; }
.wy-why { max-width: 1200px; margin: 0 auto; padding: 88px 20px; }
.wy-why h2 { margin: 0 0 10px; font-family: "Noto Kufi Arabic", sans-serif; font-size: clamp(28px, 4vw, 42px); }
.wy-why__sub { margin: 0 0 32px; color: var(--wy-mist); font-size: 17px; }
.wy-qs { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 16px; }
.wy-q {
  background: var(--wy-navy); border: 1px solid var(--wy-line); border-radius: 18px;
  padding: 22px; display: flex; flex-direction: column; gap: 10px;
  transition: border-color .35s, transform .35s var(--wy-ease);
}
.wy-q:hover { transform: translateY(-4px); }
.wy-q.is-open { border-color: var(--wy-gold); }
.wy-q__top { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.wy-q__tag { font-size: 12px; color: var(--wy-gold-light); border: 1px solid rgba(214, 168, 75, .4); padding: 4px 12px; border-radius: 999px; }
.wy-q__num { font-family: "GFS Didot", serif; font-size: 26px; color: var(--wy-gold); }
.wy-q__en { margin: 4px 0 0; font-family: "GFS Didot", Georgia, serif; font-size: 19px; line-height: 1.5; color: var(--wy-ivory); text-align: left; }
.wy-q__ar { margin: 0; font-size: 16px; line-height: 1.8; color: var(--wy-mist); }
.wy-q__btn {
  align-self: flex-start; margin-top: 4px; cursor: pointer;
  font-family: "GFS Didot", serif; font-size: 18px; letter-spacing: .5px;
  background: transparent; color: var(--wy-gold); border: 1px solid var(--wy-gold);
  padding: 8px 22px; border-radius: 999px; transition: background .25s, color .25s;
}
.wy-q__btn:hover, .wy-q.is-open .wy-q__btn { background: var(--wy-gold); color: var(--wy-navy-deep); }
.wy-q__ans { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .45s var(--wy-ease); }
.wy-q__ans > div { overflow: hidden; }
.wy-q.is-open .wy-q__ans { grid-template-rows: 1fr; }
.wy-q__a-ar { margin: 12px 0 6px; padding-top: 14px; border-top: 1px solid rgba(214, 168, 75, .35); font-size: 16px; line-height: 1.9; color: var(--wy-ivory); }
.wy-q__a-en { margin: 0; font-size: 14px; line-height: 1.7; color: var(--wy-gold-light); text-align: left; }
.wy-why__cta { margin-top: 36px; display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; align-items: center; }

/* ===== الأقسام الأصلية في الثيم الكحلي ===== */
html.wy-home .lp-title__main,
html.wy-home .s-block__title h2,
html.wy-home main h2 { color: var(--wy-ivory) !important; font-family: "Noto Kufi Arabic", sans-serif; }
html.wy-home .wy-chapters h2 { color: var(--wy-navy) !important; }
html.wy-home .lp-title__sub,
html.wy-home .lp-title__overline { color: var(--wy-mist) !important; }

/* جدول المقارنة */
html.wy-home .s-block--comparison,
html.wy-home .s-block--bundle-comparison { background: transparent !important; }
html.wy-home .s-block--comparison table { border-color: var(--wy-line) !important; }
html.wy-home .s-block--comparison thead th { background: var(--wy-navy) !important; color: var(--wy-gold-light) !important; border-color: var(--wy-line) !important; }
html.wy-home .s-block--comparison tbody tr,
html.wy-home .s-block--comparison tbody td { background: var(--wy-navy-deep) !important; color: var(--wy-ivory) !important; border-color: var(--wy-line) !important; }
html.wy-home .s-block--comparison tbody tr:hover td { background: var(--wy-navy) !important; }

/* الإحصائيات: شريط عاجي للتباين */
html.wy-home .s-block--bundle-statistics { background: var(--wy-ivory) !important; }

/* الأسئلة والفهرس: بطاقات كحلية بحد ذهبي */
html.wy-home .s-block--faqs,
html.wy-home .s-block--full-bg { background: transparent !important; }
html.wy-home .faq-item {
  background: var(--wy-navy) !important; color: var(--wy-ivory) !important;
  border: 1px solid var(--wy-line) !important; border-radius: 16px !important;
  transition: border-color .35s, transform .35s var(--wy-ease);
}
html.wy-home .faq-item * { color: inherit; }
html.wy-home .faq-item__inner,
html.wy-home .faq-answer { background: transparent !important; }
html.wy-home .faq-item:hover { border-color: var(--wy-gold) !important; transform: translateY(-3px); }
html.wy-home .faq-answer__content { color: var(--wy-mist) !important; line-height: 1.9; }

/* المميزات */
html.wy-home .s-block--features__item {
  background: var(--wy-navy) !important; color: var(--wy-ivory) !important;
  border: 1px solid var(--wy-line); border-radius: 18px;
  transition: transform .4s var(--wy-ease), border-color .4s;
}
html.wy-home .s-block--features__item * { color: inherit; }
html.wy-home .s-block--features__item:hover { transform: translateY(-6px); border-color: var(--wy-gold); }
html.wy-home .feature-icon { color: var(--wy-gold) !important; }

/* ظهور الأقسام مع التمرير */
html.wy-js main#main-content > section:not(.wy-in):not(.wy-hero-wrap) {
  opacity: 0; transform: translateY(36px);
}
html.wy-js main#main-content > section {
  transition: opacity .9s var(--wy-ease), transform .9s var(--wy-ease);
}

/* شريط تقدّم ذهبي ورأس الصفحة */
.wy-progress { position: fixed; top: 0; right: 0; height: 3px; width: 0; background: var(--wy-gold); z-index: 9999; }
.store-header { border-bottom: 1px solid rgba(214, 168, 75, .45); }
.store-footer { border-top: 2px solid var(--wy-gold); }

/* ===== أزرار التواصل العائمة (كل الصفحات) ===== */
.wy-contact { position: fixed; left: 18px; bottom: 22px; z-index: 9990; display: flex; flex-direction: column; gap: 10px; }
.wy-contact__btn {
  position: relative; width: 54px; height: 54px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: #fff !important; text-decoration: none;
  box-shadow: 0 8px 22px rgba(11, 42, 64, .28);
  transition: transform .3s var(--wy-ease), box-shadow .3s;
}
.wy-contact__btn:hover { transform: translateY(-3px) scale(1.05); box-shadow: 0 12px 28px rgba(11, 42, 64, .34); }
.wy-contact__wa { background: #25D366; }
.wy-contact__wa::after {
  content: ""; position: absolute; inset: 0; border-radius: 50%; border: 2px solid #25D366;
  animation: wy-pulse 2.4s ease-out infinite;
}
@keyframes wy-pulse { 0% { transform: scale(1); opacity: .7; } 100% { transform: scale(1.55); opacity: 0; } }
.wy-contact__ph { background: var(--wy-navy); border: 1.5px solid var(--wy-gold); color: var(--wy-gold) !important; width: 46px; height: 46px; align-self: center; }
.wy-contact__tip {
  position: absolute; left: calc(100% + 10px); top: 50%; transform: translateY(-50%) translateX(-6px);
  background: var(--wy-navy); color: var(--wy-ivory); font-size: 13px; white-space: nowrap;
  padding: 6px 12px; border-radius: 8px; opacity: 0; pointer-events: none;
  transition: opacity .25s, transform .25s;
  font-family: "Noto Sans Arabic", sans-serif;
}
.wy-contact__btn:hover .wy-contact__tip { opacity: 1; transform: translateY(-50%) translateX(0); }

@media (max-width: 640px) {
  .wy-contact { left: 12px; bottom: 84px; }
  .wy-contact__btn { width: 50px; height: 50px; }
  .wy-contact__ph { width: 42px; height: 42px; }
  .wy-hero { padding: 40px 16px 64px; gap: 28px; }
  .wy-book { width: 200px; height: 280px; }
  .wy-book__cover .t2 { font-size: 48px; } .wy-book__cover .t3 { font-size: 36px; }
  .wy-panel { padding: 24px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html.wy-js main#main-content > section { opacity: 1 !important; transform: none !important; }
}