/* =====================================================
   File: public/css/landing/03-hero.css
   HERO FULL COVER (Full screen image)
   ✅ Background image covers entire hero
   ✅ Text + plate overlay for readability
   ✅ Search under text
===================================================== */

:root {
  --hero-bg-1: #061a33;
  --hero-bg-2: #0a2d5f;

  --hero-accent: var(--accent-orange, #ff9f00);
  --hero-text: #fff;
  --hero-muted: rgba(255, 255, 255, .82);

  --hero-radius: 22px;

  --hero-pad-top: 26px;
  --hero-pad-bottom: 64px;

  --hero-max: 1240px;
}

/* =========================
   HERO SECTION (FULL COVER)
========================= */
.hero-split {
  position: relative;
  min-height: calc(100svh - var(--nav-h));
  height: calc(100svh - var(--nav-h));
  overflow: visible; /* ✅ Allow search suggestions to overflow without clipping */
  color: var(--hero-text);
}

/* Layers */
.hero-split__bg,
.hero-split__bg-image,
.hero-split__overlay {
  position: absolute;
  inset: 0;
}

/* base gradient */
.hero-split__bg {
  z-index: 0;
  background:
    radial-gradient(900px 520px at 18% 25%, rgba(245, 158, 11, .18), transparent 60%),
    linear-gradient(180deg, var(--hero-bg-1), var(--hero-bg-2));
}

/* ✅ FULL COVER IMAGE */
.hero-split__bg-image {
  z-index: 1;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;

  /* وضوح أعلى */
  opacity: 1;
  filter: none;
  transform: none;
}

/* ✅ Readability overlay فوق الصورة */
.hero-split__overlay {
  z-index: 2;
  background:
    radial-gradient(900px 520px at 70% 30%, rgba(0, 0, 0, .10), rgba(0, 0, 0, .58) 60%),
    linear-gradient(90deg, rgba(0, 0, 0, .65) 0%, rgba(0, 0, 0, .35) 45%, rgba(0, 0, 0, .55) 100%);
}

/* Inner */
.hero-split__inner {
  position: relative;
  z-index: 3;
  height: 100%;
  padding-top: var(--hero-pad-top);
  padding-bottom: var(--hero-pad-bottom);

  display: flex;
  align-items: center;
}

/* =========================
   CONTENT WRAP (centered)
========================= */
.hero-split__container {
  width: min(var(--hero-max), calc(100% - 80px));
  margin: 0 auto;
  direction: rtl;

  display: grid;
  grid-template-columns: 1fr;
  align-items: center;
}

/* ✅ اخفاء عمود الصورة القديم بالكامل */
.hero-split__media {
  display: none !important;
}

/* =========================
   TEXT AREA (plate)
========================= */
.hero-split__content {
  max-width: 760px;
}

/* plate تحت النص لزيادة وضوح القراءة */
.hero-split__plate {
  padding: 26px 26px 22px;
  border-radius: var(--radius-md);
  background: rgba(3, 12, 26, .58);
  border: 1px solid rgba(255, 255, 255, .16);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: var(--shadow-xl);
}

.hero-split__title {
  font-family: "Cairo", sans-serif;
  font-size: clamp(30px, 3.8vw, 48px);
  font-weight: 900;
  line-height: 1.12;
  margin: 0 0 12px;
  letter-spacing: -0.2px;
  text-shadow: 0 16px 40px rgba(0, 0, 0, .40);
}

.hero-split__subtitle {
  margin: 0 0 18px;
  font-size: 16px;
  line-height: 1.9;
  color: var(--hero-muted);
  max-width: 680px;
  text-shadow: 0 12px 30px rgba(0, 0, 0, .28);
}

/* =========================
   CTA
========================= */
.hero-cta {
  margin-top: 10px;
}

.hero-btn,
.hero-btn:link,
.hero-btn:visited {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .55rem;

  height: 48px;
  padding: 0 18px;
  border-radius: var(--radius-sm);

  background: var(--hero-accent);
  color: #111827;

  font-weight: 900;
  text-decoration: none;

  box-shadow: var(--shadow-md);
  transition: transform .18s ease, box-shadow .18s ease, filter .18s ease;

  direction: rtl;
}

/* ✅ icon size (smaller) */
.hero-btn__icon,
.trophy-icon-img {
  width: 16px;   /* ⬅️ صغّرناها */
  height: 16px;  /* ⬅️ صغّرناها */
  object-fit: contain;
  display: inline-block;
  flex: 0 0 auto;
  margin-right: 2px; /* RTL: مسافة صغيرة عن النص */
}

/* (اختياري) خفف اللمعة إذا بدك */
.hero-btn__icon {
  opacity: .95;
}

.hero-btn:hover {
  transform: translateY(-2px);
  filter: brightness(1.02);
  box-shadow: 0 22px 48px rgba(245, 158, 11, .26);
}

/* =========================
   SEARCH (under plate)
========================= */
.hero-search-wrapper {
  margin-top: 18px;
  width: min(760px, 100%);
  position: relative;
  z-index: 60;
}

.hero-search {
  position: relative;
  display: flex;
  align-items: center;
  height: 58px;

  background: rgba(255, 255, 255, .98);
  border-radius: 999px;

  box-shadow: var(--shadow-lg);
  border: 2px solid transparent;
  overflow: hidden;

  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
  direction: rtl;
}

.hero-search:focus-within {
  transform: translateY(-1px);
  border-color: rgba(245, 158, 11, .88);
  box-shadow: 0 22px 54px rgba(0, 0, 0, .26);
}

.search-icon-wrapper {
  position: absolute;
  right: 18px;
  top: 50%;
  transform: translateY(-50%);
  width: 22px;
  height: 22px;
  pointer-events: none;
  z-index: 2;
}

.search-icon-img {
  width: 22px;
  height: 22px;
  opacity: .62;
  display: block;
}

.search-input {
  width: 100%;
  height: 58px;
  padding: 0 58px 0 56px;
  border: none;
  outline: none;
  background: transparent;

  font-size: 1rem;
  font-family: "Tajawal", sans-serif;
  color: #111827;
  text-align: right;
}

.search-input::placeholder {
  color: rgba(17, 24, 39, .45);
}

.search-clear {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  width: 34px;
  height: 34px;
  border: none;
  background: rgba(0, 0, 0, 0.06);
  border-radius: 999px;
  cursor: pointer;
  z-index: 3;

  display: flex;
  align-items: center;
  justify-content: center;
}

/* Search suggestions: see 18-search.css (single source of truth) */

/* =========================
   MOBILE
========================= */
@media (max-width: 980px) {
  .hero-split {
    min-height: unset;
    height: auto;
  }

  .hero-split__inner {
    padding-top: 22px;
    padding-bottom: 28px;
  }

  .hero-split__container {
    width: calc(100% - 28px);
  }

  .hero-split__plate {
    padding: 20px 18px 18px;
    border-radius: 16px;
  }

  .hero-split__subtitle {
    font-size: 15px;
  }
}

/* remove margins around hero section if wrapped */
.landing-section:has(.hero-split) {
  padding: 0 !important;
  margin: 0 !important;
}
