/* ============================================================
   دار الإقامة — نظام حجز الفنادق
   تصميم فاخر هادئ | يدعم العربية (RTL)
   ============================================================ */

:root {
  /* لوحة ألوان: أخضر زمردي داكن + ذهبي دافئ + كريمي */
  --ink:        #14201c;   /* لون النص الداكن */
  --forest:     #1f4037;   /* الأخضر الأساسي */
  --forest-2:   #2c5a4c;
  --gold:       #c9a24b;   /* الذهبي */
  --gold-soft:  #e2c785;
  --cream:      #f7f3ea;   /* خلفية كريمية */
  --paper:      #fffdf8;   /* خلفية البطاقات */
  --line:       #e6ddcb;
  --muted:      #6f7d76;
  --danger:     #b3402f;
  --ok:         #2f7d52;
  --shadow:     0 14px 40px -18px rgba(20, 40, 30, .35);
  --radius:     16px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Tajawal', system-ui, sans-serif;
  background: var(--cream);
  color: var(--ink);
  line-height: 1.7;
  direction: rtl;
  /* نسيج خفيف في الخلفية */
  background-image:
    radial-gradient(circle at 12% 8%, rgba(201,162,75,.06), transparent 45%),
    radial-gradient(circle at 88% 0%, rgba(31,64,55,.05), transparent 40%);
}

h1, h2, h3, h4, .display {
  font-family: 'El Messiri', 'Tajawal', sans-serif;
  font-weight: 700;
  color: var(--forest);
  line-height: 1.35;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

.container { width: min(1180px, 92%); margin-inline: auto; }

/* ---------- الترويسة ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 253, 248, .85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.site-header .bar {
  display: flex; align-items: center; justify-content: space-between;
  padding-block: 1rem;
}
.brand { display: flex; align-items: center; gap: .6rem; }
.brand .mark {
  width: 42px; height: 42px; border-radius: 12px;
  background: linear-gradient(135deg, var(--forest), var(--forest-2));
  display: grid; place-items: center;
  color: var(--gold-soft); font-size: 1.4rem;
  box-shadow: var(--shadow);
}
.brand b { font-family: 'El Messiri', sans-serif; font-size: 1.4rem; color: var(--forest); }
.brand span { display: block; font-size: .72rem; color: var(--muted); letter-spacing: .12em; }

.nav { display: flex; align-items: center; gap: 1.6rem; }
.nav a { font-weight: 500; color: var(--ink); transition: color .2s; position: relative; }
.nav a:hover { color: var(--gold); }
.nav a::after {
  content: ''; position: absolute; bottom: -6px; right: 0; height: 2px; width: 0;
  background: var(--gold); transition: width .25s;
}
.nav a:hover::after { width: 100%; }

/* ---------- الأزرار ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .8rem 1.6rem; border-radius: 999px; border: none;
  font-family: inherit; font-size: 1rem; font-weight: 700; cursor: pointer;
  transition: transform .18s, box-shadow .18s, background .2s; white-space: nowrap;
}
.btn-gold {
  background: linear-gradient(135deg, var(--gold), var(--gold-soft));
  color: #2a2110; box-shadow: 0 10px 24px -10px rgba(201,162,75,.7);
}
.btn-gold:hover { transform: translateY(-2px); box-shadow: 0 16px 30px -12px rgba(201,162,75,.8); }
.btn-forest { background: var(--forest); color: #fff; }
.btn-forest:hover { background: var(--forest-2); transform: translateY(-2px); }
.btn-ghost { background: transparent; border: 1.5px solid var(--line); color: var(--forest); }
.btn-ghost:hover { border-color: var(--gold); color: var(--gold); }
.btn-sm { padding: .5rem 1rem; font-size: .85rem; }
.btn-block { width: 100%; justify-content: center; }

/* ---------- الواجهة الرئيسية (Hero) ---------- */
.hero {
  position: relative; overflow: hidden;
  border-radius: 0 0 36px 36px;
  background:
    linear-gradient(120deg, rgba(20,32,28,.82), rgba(31,64,55,.55)),
    url('https://images.unsplash.com/photo-1542314831-068cd1dbfeeb?w=1600&q=80') center/cover;
  color: #fff;
  padding-block: 6rem 7rem;
}
.hero h1 { color: #fff; font-size: clamp(2.2rem, 5vw, 4rem); max-width: 16ch; }
.hero .lead { max-width: 52ch; margin-top: 1rem; font-size: 1.15rem; opacity: .92; }
.hero .pill {
  display: inline-block; padding: .4rem 1rem; border-radius: 999px;
  background: rgba(201,162,75,.2); border: 1px solid rgba(226,199,133,.5);
  color: var(--gold-soft); font-weight: 700; font-size: .85rem; margin-bottom: 1.2rem;
  letter-spacing: .08em;
}

/* ---------- صندوق البحث ---------- */
.search-card {
  background: var(--paper); border-radius: 20px; box-shadow: var(--shadow);
  padding: 1.4rem; margin-top: -3.6rem; position: relative; z-index: 5;
  border: 1px solid var(--line);
}
.search-grid {
  display: grid; gap: 1rem; align-items: end;
  grid-template-columns: 1.4fr 1fr 1fr auto;
}
.field label { display: block; font-size: .82rem; color: var(--muted); margin-bottom: .35rem; font-weight: 700; }
.field input, .field select {
  width: 100%; padding: .8rem 1rem; border: 1.5px solid var(--line); border-radius: 12px;
  font-family: inherit; font-size: .98rem; background: #fff; color: var(--ink);
  transition: border-color .2s, box-shadow .2s;
}
.field input:focus, .field select:focus {
  outline: none; border-color: var(--gold);
  box-shadow: 0 0 0 4px rgba(201,162,75,.15);
}

/* ---------- العناوين القسمية ---------- */
.section { padding-block: 4rem; }
.section-head { text-align: center; max-width: 60ch; margin: 0 auto 2.5rem; }
.section-head .kicker {
  color: var(--gold); font-weight: 700; letter-spacing: .14em; font-size: .85rem;
  text-transform: uppercase;
}
.section-head h2 { font-size: clamp(1.8rem, 3.5vw, 2.6rem); margin-top: .4rem; }
.section-head p { color: var(--muted); margin-top: .6rem; }

/* ---------- شبكة بطاقات الفنادق ---------- */
.grid-hotels {
  display: grid; gap: 1.6rem;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
}
.hotel-card {
  background: var(--paper); border-radius: var(--radius); overflow: hidden;
  border: 1px solid var(--line); box-shadow: var(--shadow);
  display: flex; flex-direction: column;
  transition: transform .25s, box-shadow .25s;
}
.hotel-card:hover { transform: translateY(-6px); box-shadow: 0 26px 50px -20px rgba(20,40,30,.4); }
.hotel-card .thumb { position: relative; aspect-ratio: 16/10; overflow: hidden; }
.hotel-card .thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.hotel-card:hover .thumb img { transform: scale(1.07); }
.hotel-card .badge-city {
  position: absolute; top: .8rem; inset-inline-start: .8rem;
  background: rgba(20,32,28,.78); color: var(--gold-soft);
  padding: .35rem .85rem; border-radius: 999px; font-size: .8rem; font-weight: 700;
  backdrop-filter: blur(4px);
}
.hotel-card .body { padding: 1.2rem 1.3rem 1.4rem; display: flex; flex-direction: column; gap: .55rem; flex: 1; }
.hotel-card h3 { font-size: 1.3rem; }
.hotel-card .stars-line { color: var(--gold); letter-spacing: .1em; font-size: .95rem; }
.hotel-card .desc { color: var(--muted); font-size: .92rem; flex: 1; }
.hotel-card .foot { display: flex; align-items: center; justify-content: space-between; margin-top: .4rem; }
.hotel-card .price b { color: var(--forest); font-size: 1.25rem; font-family: 'El Messiri', sans-serif; }
.hotel-card .price small { color: var(--muted); display: block; font-size: .75rem; }

/* ---------- شارات المرافق ---------- */
.amenities { display: flex; flex-wrap: wrap; gap: .5rem; }
.amenities span {
  background: rgba(31,64,55,.07); color: var(--forest-2);
  padding: .3rem .8rem; border-radius: 999px; font-size: .8rem; font-weight: 500;
}

/* ---------- صفحة تفاصيل الفندق ---------- */
.hotel-hero {
  position: relative; border-radius: 24px; overflow: hidden; aspect-ratio: 21/9;
  box-shadow: var(--shadow); margin-bottom: 2rem;
}
.hotel-hero img { width: 100%; height: 100%; object-fit: cover; }
.hotel-hero .overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(20,32,28,.85), transparent 60%);
  display: flex; align-items: flex-end; padding: 2rem;
}
.hotel-hero .overlay h1 { color: #fff; font-size: clamp(1.8rem, 4vw, 3rem); }
.hotel-hero .overlay .meta { color: var(--gold-soft); margin-top: .3rem; font-weight: 700; }

.layout-2 { display: grid; grid-template-columns: 2fr 1fr; gap: 2rem; align-items: start; }
.panel {
  background: var(--paper); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 1.6rem; box-shadow: var(--shadow);
}
.panel h2 { font-size: 1.4rem; margin-bottom: .8rem; }

/* ---------- بطاقة الغرفة ---------- */
.room-card {
  display: grid; grid-template-columns: 180px 1fr auto; gap: 1.2rem; align-items: center;
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1rem; margin-bottom: 1rem; box-shadow: var(--shadow);
  transition: border-color .2s;
}
.room-card:hover { border-color: var(--gold-soft); }
.room-card .rimg { width: 180px; height: 130px; border-radius: 12px; object-fit: cover; }
.room-card h4 { font-size: 1.2rem; }
.room-card .rmeta { color: var(--muted); font-size: .88rem; }
.room-card .rprice { text-align: center; }
.room-card .rprice b { font-family: 'El Messiri', sans-serif; font-size: 1.6rem; color: var(--forest); }
.room-card .rprice small { color: var(--muted); display: block; }

/* ---------- النماذج ---------- */
.form-group { margin-bottom: 1.1rem; }
.form-group label { display: block; font-weight: 700; margin-bottom: .4rem; font-size: .9rem; }
.form-group input, .form-group select, .form-group textarea {
  width: 100%; padding: .8rem 1rem; border: 1.5px solid var(--line); border-radius: 12px;
  font-family: inherit; font-size: 1rem; background: #fff; color: var(--ink);
  transition: border-color .2s, box-shadow .2s;
}
.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
  outline: none; border-color: var(--gold); box-shadow: 0 0 0 4px rgba(201,162,75,.15);
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }

/* ---------- التنبيهات ---------- */
.alert { padding: .9rem 1.2rem; border-radius: 12px; margin-bottom: 1.2rem; font-weight: 500; }
.alert-success { background: rgba(47,125,82,.12); color: var(--ok); border: 1px solid rgba(47,125,82,.3); }
.alert-error { background: rgba(179,64,47,.1); color: var(--danger); border: 1px solid rgba(179,64,47,.3); }
.alert-info { background: rgba(31,64,55,.08); color: var(--forest-2); border: 1px solid rgba(31,64,55,.2); }

/* ---------- ملخص الحجز ---------- */
.summary-row { display: flex; justify-content: space-between; padding: .6rem 0; border-bottom: 1px dashed var(--line); }
.summary-row:last-child { border-bottom: none; }
.summary-total { font-family: 'El Messiri', sans-serif; font-size: 1.4rem; color: var(--forest); font-weight: 700; }

/* ---------- التذييل ---------- */
.site-footer {
  background: var(--forest); color: #d8e2dc; margin-top: 4rem;
  padding-block: 3rem 1.5rem; border-radius: 36px 36px 0 0;
}
.site-footer .cols { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 2rem; }
.site-footer h4 { color: var(--gold-soft); margin-bottom: 1rem; }
.site-footer a:hover { color: var(--gold-soft); }
.site-footer ul { list-style: none; display: flex; flex-direction: column; gap: .5rem; }
.site-footer .copy { text-align: center; margin-top: 2rem; padding-top: 1.2rem; border-top: 1px solid rgba(255,255,255,.12); font-size: .85rem; color: #9fb3aa; }

/* ---------- متجاوب ---------- */
@media (max-width: 860px) {
  .search-grid { grid-template-columns: 1fr 1fr; }
  .layout-2 { grid-template-columns: 1fr; }
  .room-card { grid-template-columns: 1fr; text-align: center; }
  .room-card .rimg { width: 100%; height: 180px; }
  .site-footer .cols { grid-template-columns: 1fr; }
  .nav { gap: 1rem; font-size: .9rem; }
  .nav .hide-sm { display: none; }
}
@media (max-width: 560px) {
  .search-grid { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
}

/* ---------- حركة الظهور ---------- */
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: translateY(0); } }
.reveal { animation: rise .6s ease both; }
.reveal-2 { animation: rise .6s ease .1s both; }
.reveal-3 { animation: rise .6s ease .2s both; }
