/* ==========================================================================
   جريدة كافيه — طبقة التخصيص فوق قالب Canvas الأساسي
   لوحة الألوان: مقصورة على لونين فقط (بيج/بني) + درجاتهما
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=El+Messiri:wght@400;500;600;700&family=IBM+Plex+Sans+Arabic:wght@400;500;600;700&family=IBM+Plex+Mono:wght@500;600&display=swap');

:root {
  /* اللونان المعتمدان فقط */
  --sand: #CDBEA8;
  --sand-rgb: 205, 190, 168;
  --brown: #473726;
  --brown-rgb: 71, 55, 38;

  /* درجات مشتقة من نفس اللونين (لا ألوان جديدة) */
  --sand-light: #E1D6C4;
  /* تينت أفتح — خلفيات مرفوعة */
  --sand-dark: #B9A98D;
  /* تظليل أغمق قليلاً — حدود */
  --brown-dark: #302518;
  /* تظليل أغمق — تباين عالٍ */
  --brown-soft: #6C5A44;
  /* تينت أفتح من البني — نص ثانوي وأيقونات */

  /* أدوار */
  --bg: var(--sand);
  --bg-raised: var(--sand-light);
  --ink: var(--brown);
  --ink-soft: var(--brown-soft);
  --ink-faint: rgba(var(--brown-rgb), .58);
  --line: rgba(var(--brown-rgb), .22);
  --line-strong: rgba(var(--brown-rgb), .38);

  --on-dark: var(--sand);
  --on-dark-soft: rgba(var(--sand-rgb), .78);
  --on-dark-line: rgba(var(--sand-rgb), .32);
}

/* ---------- أساسيات ---------- */
/* القالب الأصلي يخفي #wrapper وينتظر Preloader بـ jQuery؛ استبدلناه بسكربت خفيف فنُظهر المحتوى مباشرة */
#wrapper {
  opacity: 1 !important;
  background: var(--bg) !important;
  box-shadow: none !important;
  width: 100% !important;
  margin: 0 !important
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 66px;
}

body {
  background: var(--bg) !important;
  color: var(--ink) !important;
  font-family: "IBM Plex Sans Arabic", "Tajawal", sans-serif !important;
  direction: rtl;
  text-align: right;
  overflow-x: hidden;
}

/* القالب الأصلي (Bootstrap/Canvas) يفرض text-align:left على عناصر كثيرة
   حتى تحت dir="rtl" — نعيدها لليمين افتراضيًا؛ العناصر اللي تحتاج توسيط
   لها كلاس صريح (.jd-heading, .offer-card, إلخ) يبقى أقوى من هذا الإرث */
p, h1, h2, h3, h4, h5, h6, blockquote, .row, [class*="col-"] {
  text-align: right;
}

::selection {
  background: var(--brown);
  color: var(--sand)
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: "El Messiri", serif !important;
  color: var(--ink);
  font-weight: 700;
}

a {
  color: var(--ink-soft)
}

a:hover {
  color: var(--ink)
}

p {
  color: var(--ink-soft)
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: .6em;
  font-family: "IBM Plex Sans Arabic", sans-serif;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .06em;
  color: var(--ink);
  margin-bottom: 14px;
}

.eyebrow::before,
.eyebrow::after {
  content: "";
  width: 30px;
  height: 1px;
  background: var(--line-strong);
  flex: none;
}

/* ---------- عناصر بأيقونة + نص: النص دومًا يمين، والأيقونة يسار ---------- */
.icon-text-row {
  display: flex;
  flex-direction: row-reverse;
  align-items: center;
  gap: 10px
}

/* ---------- الترويسة العلوية ---------- */
#header {
  background: transparent;
  border-bottom: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  z-index: 500;
}

#header-wrap {
  background: linear-gradient(to bottom, rgba(48, 37, 24, .55) 0%, rgba(48, 37, 24, 0) 100%);
  height: auto !important;
  transition: background .35s ease, box-shadow .35s ease
}

#header.sticky-active #header-wrap,
#header.menu-open #header-wrap {
  background: var(--bg) !important;
  box-shadow: 0 4px 22px rgba(var(--brown-rgb), .16);
}

#logo {
  margin: 0 !important;
  float: none !important;
  height: auto !important;
  display: flex !important;
}

.logo-badge {
  display: flex !important;
  align-items: center;
  justify-content: center;
  height: 40px !important;
  padding: 5px 14px;
  border-radius: 10px;
  background: var(--sand-light);
  border: 1px solid rgba(var(--sand-rgb), .5);
  flex: none;
  box-sizing: border-box;
}

#header.sticky-active .logo-badge,
#header.menu-open .logo-badge {
  border-color: var(--line)
}

.logo-badge img {
  height: 100% !important;
  width: auto !important;
  max-width: none !important;
  object-fit: contain;
  display: block !important;
  transition: none !important;
}

#primary-menu {
  display: flex;
  align-items: center;
  gap: 6px
}

#primary-menu ul {
  display: flex;
  align-items: center;
  gap: 6px;
  list-style: none;
  margin: 0;
  padding: 0
}

#primary-menu ul li a {    display: block;
    padding: 8px 16px;
    font-family: "IBM Plex Sans Arabic", sans-serif;
    font-weight: 600;
    font-size: .95rem;
    color: var(--on-dark);
    text-decoration: none;
    border-radius: 6px;
    transition: .25s;
    text-shadow: -7px 1px 7px rgb(0 0 0 / 96%);
  
  
  }

#header.sticky-active #primary-menu ul li a,
#header.menu-open #primary-menu ul li a {
  text-shadow: none;
}

#primary-menu ul li a:hover,
#primary-menu ul li.current a {
  color: var(--brown-soft) !important;
  background: rgba(var(--brown-rgb), .08)
}

/* تبديل لون روابط القائمة للون الغامق يصير فقط على سطح المكتب،
   لأن هذا الكلاس نفسه (menu-open) يُستخدم أيضًا لفتح القائمة الكاملة
   الداكنة على الهاتف، ولازم تبقى روابطها بلون فاتح هناك */
@media (min-width: 992px) {
  #header.sticky-active #primary-menu ul li a,
  #header.menu-open #primary-menu ul li a {
    color: var(--ink)
  }

  #header.sticky-active #primary-menu ul li a:hover,
  #header.menu-open #primary-menu ul li a:hover {
    background: rgba(var(--brown-rgb), .08)
  }
}


#primary-menu-trigger {
  display: none;
  cursor: pointer;
  font-size: 24px;
  color: var(--on-dark);
  line-height: 1;
  padding: 6px
}

#header.sticky-active #primary-menu-trigger,
#header.menu-open #primary-menu-trigger {
  color: var(--ink)
}

@media (max-width: 991px) {
  #primary-menu-trigger {
    display: block
  }

  #primary-menu {
    position: fixed;
    inset: 0;
    z-index: 200;
    background: var(--brown-dark);
    flex-direction: column;
    justify-content: center;
    display: none;
  }

  body.nav-open #primary-menu {
    display: flex
  }

  #primary-menu ul {
    flex-direction: column;
    text-align: center;
    gap: 4px
  }

  #primary-menu ul li a {
    color: var(--sand);
    font-size: 1.3rem;
    padding: 14px 20px
  }

  #primary-menu ul li a:hover,
  #primary-menu ul li.current a {
    color: var(--sand-dark) !important;
    background: transparent
  }

  body.nav-open {
    overflow: hidden
  }
}

/* ---------- Hero ---------- */
#hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  background: linear-gradient(160deg, var(--brown-dark) 0%, var(--brown) 60%);
  overflow: hidden;
  padding-top: 110px;
  padding-bottom: 70px;
}

#hero .hero-photo {
  position: absolute;
  inset-inline-end: 0;
  top: 0;
  bottom: 0;
  width: 52%;
  background-size: cover;
  background-position: center;
  filter: grayscale(.35) sepia(.25);
}

#hero .hero-photo::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to left, rgba(48, 37, 24, 0) 0%, rgba(48, 37, 24, .6) 30%, var(--brown-dark) 100%);
}

@media (max-width:991px) {
  #hero {
    flex-direction: column;
    align-items: stretch;
    padding-top: 130px;
    padding-bottom: 0;
  }

  #hero .container {
    width: 100%;
  }

  #hero .hero-photo {
    position: relative;
    inset-inline-end: auto;
    width: 100%;
    flex: 1 1 auto;
    min-height: 280px;
    margin-top: 34px;
    order: 2;
  }

  #hero .hero-photo::before {
    background: linear-gradient(to bottom, var(--brown-dark) 0%, rgba(48, 37, 24, 0) 45%)
  }
}

#hero .container {
  position: relative;
  z-index: 2
}

#hero .eyebrow {
  color: var(--on-dark);
  font-size: 15px;
  letter-spacing: .1em;
  margin-bottom: 20px;
}

#hero .eyebrow::before,
#hero .eyebrow::after {
  background: var(--on-dark-line);
}

#hero h1 {
  color: var(--on-dark) !important;
  font-size: 3.1rem;
  line-height: 1.35;
  margin-bottom: 22px;
  max-width: 640px;
}

#hero .hero-sub {
  color: var(--on-dark-soft);
  font-size: 1.15rem;
  max-width: 520px;
  margin-bottom: 34px
}

@media (max-width:576px) {
  #hero h1 {
    font-size: 2.15rem
  }
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 16px
}

.btn-primary-jd {
  display: inline-flex;
  flex-direction: row-reverse;
  align-items: center;
  gap: 10px;
  background: var(--sand);
  color: var(--brown);
  padding: 15px 30px;
  border-radius: 6px;
  font-weight: 600;
  text-decoration: none;
  transition: .25s;
  font-family: "IBM Plex Sans Arabic", sans-serif;
}

.btn-primary-jd:hover {
  background: var(--sand-dark);
  color: var(--brown-dark)
}

.btn-ghost-jd {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: transparent;
  color: var(--on-dark);
  padding: 14px 28px;
  border: 1px solid var(--on-dark-line);
  border-radius: 6px;
  font-weight: 600;
  text-decoration: none;
  transition: .25s;
  font-family: "IBM Plex Sans Arabic", sans-serif;
}

.btn-ghost-jd:hover {
  border-color: var(--on-dark);
  background: rgba(var(--sand-rgb), .08);
  color: var(--on-dark)
}

/* ---------- أقسام عامة ---------- */
.jd-section {
  padding: 110px 0
}

@media (max-width:768px) {
  .jd-section {
    padding: 48px 0
  }
}

.jd-section.raised {
  background: var(--bg-raised)
}

.jd-heading {
  margin: 0 auto 50px;
  max-width: 680px;
  text-align: center;
}

.jd-heading .eyebrow {
  justify-content: center;
}

.jd-heading h2 {
  text-align: center;
  font-size: 2.2rem;
  margin-bottom: 14px
}

.jd-heading p {
  text-align: center;
  font-size: 1.08rem;
  max-width: 60ch;
  margin-left: auto;
  margin-right: auto;
}

/* فاصل كلاسيكي مزدوج بين الأقسام */
.jd-divider {
  border: none;
  border-top: 1px solid var(--line);
  position: relative;
  margin: 0
}

.jd-divider::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 1px;
  background: var(--line-strong);
}

/* ---------- الحكاية ---------- */
#story .story-photo {
  border-radius: 4px;
  overflow: hidden;
  position: relative;
  border: 1px solid var(--line);
}

/* بعرض الهاتف والتابلت: الصورة تمتد لحافة الشاشة بدون أي هامش أو حدود،
   بنفس أسلوب صورة الـ Hero تمامًا، وتمتد للأسفل لتغطي مسافة نهاية القسم
   (padding-bottom) بدل ما يبين لون الخلفية البيج تحتها */
@media (max-width: 991px) {
  #story .story-photo,
  #atmosphere .atmosphere-photo {
    width: 100vw;
    margin-left: calc(-50vw + 50%);
    margin-right: calc(-50vw + 50%);
    margin-bottom: -88px;
    border-radius: 0;
    border: none;
  }
}

@media (max-width: 768px) {
  #story .story-photo,
  #atmosphere .atmosphere-photo {
    margin-bottom: -48px;
  }
}

#story .story-photo img {
  filter: sepia(.3) saturate(.9) brightness(.92) grayscale(.15);
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover
}

#story blockquote {
  border: none;
  border-inline-start: 2px solid var(--brown-soft);
  padding: 0 0 0 20px;
  padding-inline-start: 20px;
  margin: 26px 0;
  font-family: "El Messiri", serif;
  font-size: 1.3rem;
  color: var(--ink);
  font-style: italic;
}

/* ---------- بطاقات التميّز: أُطر بدل التعبئة، والأيقونة يسار دومًا ---------- */
.diff-list {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--line);
  border-radius: 4px;
  overflow: hidden
}

.diff-item {
  display: flex;
  flex-direction: row-reverse;
  align-items: flex-start;
  gap: 22px;
  padding: 28px 30px;
  background: transparent;
}

.diff-item+.diff-item {
  border-top: 1px solid var(--line)
}

.diff-item .icon {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  color: var(--ink);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  flex: none;
}

.diff-item .diff-text {
  flex: 1;
  text-align: right
}

.diff-item h4 {
  margin: 0 0 6px;
  font-size: 1.2rem
}

.diff-item p {
  margin: 0
}

/* ---------- الفئات / ما نقدّمه ---------- */
.offer-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px
}

@media (max-width:768px) {
  .offer-grid {
    grid-template-columns: 1fr 1fr
  }
}

@media (max-width:480px) {
  .offer-grid {
    grid-template-columns: 1fr
  }
}

.offer-card {
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 32px 24px;
  text-align: center;
  transition: .25s;
}

.offer-card:hover {
  border-color: var(--line-strong);
  background: rgba(var(--brown-rgb), .03)
}

.offer-card .icon {
  font-size: 28px;
  color: var(--ink);
  margin-bottom: 14px
}

.offer-card h4 {
  font-size: 1.05rem;
  margin-bottom: 6px;
  text-align: center;
}

.offer-card p {
  font-size: .85rem;
  margin: 0;
  color: var(--ink-faint);
  direction: ltr;
  text-align: center;
}

/* ---------- الأجواء: النص يمين، الأيقونة يسار ---------- */
#atmosphere {
  background: var(--bg-raised)
}

/* بعرض الحاسوب (لمّا العمودين جنب بعض): نضيف مسافة فاضية بين عمود النص
   والصورة، وهذا نفس الوقت يخلي عرض النص/القائمة أضيق شوي فما تتجاوز
   الأيقونات حافة النص الفعلي فوقها */
@media (min-width: 992px) {
  #atmosphere .row > .col-lg-6:first-child {
    padding-inline-end: 82px;
  }
}

/* الفقرة العلوية وقائمة الأيقونات لازم تشتركان بنفس أقصى عرض ونفس المحاذاة
   بالضبط — نفس max-width ونفس margin، حتى تصطف حافتاهم (يمين/يسار) على
   نفس الخط تمامًا بدون أي فرق */
.atmosphere-lead,
.amenity-list {
  width: 100%;
  max-width: 100%;
  margin: 0 auto;
  box-sizing: border-box;
}

.amenity-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  justify-content: stretch;
  gap: 14px 24px;
}

@media (max-width:480px) {
  .amenity-list {
    grid-template-columns: 1fr
  }
}

.amenity {
  display: flex;
  flex-direction: row-reverse;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-weight: 600;
  color: var(--ink);
  text-align: right;
}

/* بعرض الحاسوب (شبكة عمودين): الأيقونات تلتزم بعمود ثابت العرض بدل ما
   يتغير مكانها حسب طول كل نص — عشان تصطف كلها بخط واحد بمظهر أفخم.
   التموضع صريح بالكامل (grid-row+grid-column) لكل من الأيقونة والنص
   تجنبًا لأي التباس بخوارزمية الترتيب التلقائي بين عنصرين بنفس الصف */
@media (min-width: 481px) {
  .amenity {
    display: grid;
    grid-template-columns: 1fr 22px;
    gap: 16px;
  }

  .amenity .icon {
    grid-row: 1;
    grid-column: 2;
    text-align: center;
  }

  .amenity span {
    grid-row: 1;
    grid-column: 1;
  }
}

.amenity .icon {
  color: var(--ink-soft);
  font-size: 18px;
  flex: none
}

#atmosphere .atmosphere-photo {
  border-radius: 4px;
  overflow: hidden;
  border: 1px solid var(--line)
}

#atmosphere .atmosphere-photo img {
  filter: sepia(.3) saturate(.9) brightness(.95) grayscale(.15);
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover
}

/* ---------- المعرض ---------- */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px
}

@media (max-width:768px) {
  .gallery-grid {
    grid-template-columns: repeat(2, 1fr)
  }
}

.gallery-grid a {
  display: block;
  border-radius: 4px;
  overflow: hidden;
  aspect-ratio: 1/1;
  position: relative;
  border: 1px solid var(--line)
}

.gallery-grid img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: sepia(.28) saturate(.9) brightness(.94) grayscale(.15);
  transition: transform .5s ease
}

.gallery-grid a:hover img {
  transform: scale(1.06)
}


/* ---------- الموقع والتواصل ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  max-width: 860px;
  margin: 0 auto;
}

@media (max-width: 760px) {
  .contact-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width:600px) {
  .contact-grid {
    grid-template-columns: 1fr
  }
}

.contact-card {
  display: block;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 28px;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: .25s;
}

.contact-card:hover {
  border-color: var(--line-strong);
  background: rgba(var(--brown-rgb), .04);
}

.contact-card .icon {
  font-size: 24px;
  color: var(--ink);
  margin-bottom: 12px
}

.contact-card h4 {
  font-size: 1rem;
  margin-bottom: 6px;
  text-align: center;
}

.contact-card .soon {
  font-size: .85rem;
  color: var(--ink-faint)
}

.contact-card .address-text {
  font-size: .85rem;
  color: var(--ink-faint);
  line-height: 1.8;
  text-align: center;
  margin: 0
}

/* ---------- الفوتر ---------- */
#footer {
  background: var(--brown-dark);
  color: var(--on-dark-soft)
}

.footer-logo-badge {
  display: flex !important;
  align-items: center;
  justify-content: center;
  height: 58px !important;
  width: fit-content;
  padding: 8px 18px;
  border-radius: 14px;
  background: var(--sand-light);
  margin: 0 auto 18px;
  border: 1px solid var(--on-dark-line);
  box-sizing: border-box;
}

.footer-logo-badge img {
  height: 100% !important;
  width: auto !important;
  max-width: none !important;
  object-fit: contain;
  display: block !important;
  transition: none !important;
}

#footer .tagline {
  font-family: "El Messiri", serif;
  color: var(--on-dark);
  font-size: 1.15rem;
  margin-bottom: 24px
}

#footer .social-row {
  display: flex;
  justify-content: center;
  gap: 14px;
  margin-bottom: 24px
}

#footer .social-row a {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1px solid var(--on-dark-line);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--on-dark);
  font-size: 17px;
}

#footer .social-row a:hover {
  background: var(--sand);
  border-color: var(--sand);
  color: var(--brown)
}

#footer .copyrights {
  border-top: 1px solid rgba(var(--sand-rgb), .14);
  padding-top: 22px;
  font-size: .85rem;
  color: rgba(var(--sand-rgb), .55);
  text-align: center
}

/* ---------- back to top ---------- */
#gotoTop {
  position: fixed;
  bottom: 26px;
  inset-inline-end: 26px;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--brown);
  color: var(--sand);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transition: .3s;
  z-index: 150;
  font-size: 18px;
}

#gotoTop.visible {
  opacity: 1;
  visibility: visible
}

#gotoTop:hover {
  background: var(--brown-dark)
}

/* ---------- ظهور تدريجي عند التمرير ---------- */
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity .7s ease, transform .7s ease
}

.reveal.in-view {
  opacity: 1;
  transform: none
}

@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    transition: none
  }

  html {
    scroll-behavior: auto
  }
}

/* ---------- lightbox بسيط ---------- */
.jd-lightbox {
  position: fixed;
  inset: 0;
  background: rgba(var(--brown-rgb), .94);
  z-index: 400;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 30px;
}

.jd-lightbox.open {
  display: flex
}

.jd-lightbox img {
  max-width: 100%;
  max-height: 100%;
  border-radius: 4px
}

.jd-lightbox .close {
  position: absolute;
  top: 22px;
  inset-inline-end: 26px;
  color: var(--sand);
  font-size: 30px;
  cursor: pointer
}