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

    html {
      scroll-behavior: smooth;
      height: 100%;
    }

    body {
      font-family: "Cairo", sans-serif;
      overflow-x: hidden;
      display: flex;
      flex-direction: column;
      background: #1e0640;
    }

    /* Give the shared layout's wrapper a real height so .hero's flex:1
       actually has space to grow into, instead of leaving blank body
       background below a shorter-than-viewport page. */
    .dash-main {
      min-height: 100vh;
    }

    :root {
      --pu: #6b2fa0;
      --pd: #3a1260;
      --gold: #d4a017;
      --glt: #f0c040;
      --ink: #1e1030;
    }

    /* HERO */
 .hero {
      position: relative;
      flex: 1;
      min-height: 0; 
      display: flex;
      flex-direction: column;
      align-items: center;
      overflow: hidden;
    }

    .bgl {
      position: absolute;
      inset: 0;
      z-index: 0;
    }

    .bgs {
      position: absolute;
      inset: 0;
      background-size: cover;
      background-position: center;
      opacity: 0;
      transition: opacity 1.8s ease;
      will-change: opacity;
    }

    .bgs.on {
      opacity: 1;
    }

    .bgs:nth-child(1) {
      animation: kb1 16s ease-in-out infinite alternate;
    }

    .bgs:nth-child(2) {
      animation: kb2 14s ease-in-out infinite alternate;
    }

    .bgs:nth-child(3) {
      animation: kb3 18s ease-in-out infinite alternate;
    }

    .bgs:nth-child(4) {
      animation: kb4 13s ease-in-out infinite alternate;
    }

    @keyframes kb1 {
      from {
        transform: scale(1.06);
      }

      to {
        transform: scale(1) translate(-10px, -6px);
      }
    }

    @keyframes kb2 {
      from {
        transform: scale(1.08) translate(8px, 0);
      }

      to {
        transform: scale(1) translate(-6px, 8px);
      }
    }

    @keyframes kb3 {
      from {
        transform: scale(1.05) translate(-5px, 4px);
      }

      to {
        transform: scale(1.1) translate(6px, -6px);
      }
    }

    @keyframes kb4 {
      from {
        transform: scale(1.07) translate(0, 7px);
      }

      to {
        transform: scale(1) translate(-8px, 0);
      }
    }

    .bgo {
      position: absolute;
      inset: 0;
      z-index: 1;
      background: linear-gradient(to bottom,
          rgba(20, 5, 50, 0.15) 0%,
          rgba(30, 6, 64, 0.08) 50%,
          rgba(20, 5, 50, 0.45) 100%);
    }

    .fl {
      position: absolute;
      inset: 0;
      z-index: 2;
      pointer-events: none;
      overflow: hidden;
    }

    .fi {
      position: absolute;
      color: rgba(255, 255, 255, 0.18);
      font-size: 32px;
      animation: fm 9s ease-in-out infinite;
      filter: drop-shadow(0 0 8px rgba(212, 160, 23, 0.4));
    }

    .fi:nth-child(1) {
      top: 12%;
      right: 7%;
      animation-duration: 7s;
    }

    .fi:nth-child(2) {
      top: 20%;
      left: 10%;
      animation-duration: 9s;
      animation-delay: 1s;
    }

    .fi:nth-child(3) {
      top: 55%;
      right: 5%;
      animation-duration: 8s;
      animation-delay: 2s;
    }

    .fi:nth-child(4) {
      top: 70%;
      left: 7%;
      animation-duration: 6s;
      animation-delay: 0.5s;
    }

    .fi:nth-child(5) {
      top: 36%;
      right: 18%;
      animation-duration: 10s;
      animation-delay: 1.5s;
    }

    .fi:nth-child(6) {
      top: 78%;
      right: 22%;
      animation-duration: 7.5s;
      animation-delay: 3s;
    }

    @keyframes fm {

      0%,
      100% {
        transform: translateY(0) rotate(0);
      }

      40% {
        transform: translateY(-20px) rotate(8deg);
      }

      70% {
        transform: translateY(8px) rotate(-5deg);
      }
    }

    .hb {
      position: relative;
      z-index: 3;
      width: 100%;
      max-width: 860px;
      display: flex;
      flex-direction: column;
      align-items: center;
      gap: 0;
    }

    /* SEARCH BOX */
    .sc {
      width: 100%;
      max-width: 1000px;
      margin-left: auto;
      margin-right: auto;
      background: rgba(255, 255, 255, 0.96);
      backdrop-filter: blur(20px);
      border-radius: 14px;
      padding: 10px 14px 9px;
      box-shadow:
        0 16px 48px rgba(0, 0, 0, 0.42),
        0 0 0 1px rgba(212, 160, 23, 0.22);
      margin-bottom: 16px;
      margin-top: 15px;
    }

    .sr {
      display: grid;
      grid-template-columns: repeat(6, 1fr);
      gap: 6px;
    }

    .sg {
      display: flex;
      flex-direction: column;
      min-width: 0;
    }

    .sl {
      font-size: 9px;
      font-weight: 800;
      color: var(--pu);
      letter-spacing: 0.6px;
      margin-bottom: 3px;
      display: flex;
      align-items: center;
      gap: 3px;
      white-space: nowrap;
      overflow: hidden;
    }

    .sg select,
    .sg input[type="date"] {
      width: 100%;
      min-width: 0;
      border: 1.5px solid #ddd5f5;
      border-radius: 7px;
      padding: 5px 8px;
      font-family: "Cairo", sans-serif;
      font-size: 11px;
      font-weight: 600;
      color: var(--ink);
      background: #f7f3ff;
      width: 100%;
      min-width: 0;
      -webkit-appearance: none;
      -moz-appearance: none;
      appearance: none;
      transition: 0.2s;
      box-sizing: border-box;
      height: 30px;
      line-height: 1;
    }

    .sg select:focus,
    .sg input[type="date"]:focus {
      outline: none;
      border-color: var(--pu);
      box-shadow: 0 0 0 3px rgba(107, 47, 160, 0.08);
    }

    .sg input[type="date"]::-webkit-calendar-picker-indicator {
      opacity: 0.5;
      cursor: pointer;
      width: 14px;
      height: 14px;
    }

    .bsf {
      margin-top: 7px;
      width: 100%;
      background: linear-gradient(100deg, #9a6c0a, var(--glt), #9a6c0a);
      background-size: 200%;
      color: var(--ink);
      font-family: "Cairo", sans-serif;
      font-weight: 900;
      font-size: 14px;
      border: none;
      border-radius: 9px;
      padding: 8px;
      cursor: pointer;
      box-shadow: 0 5px 20px rgba(212, 160, 23, 0.4);
      transition: 0.35s;
    }

    .bsf:hover {
      background-position: right center;
      transform: translateY(-2px);
      box-shadow: 0 10px 30px rgba(212, 160, 23, 0.6);
    }

    /* HERO TEXT */
    .ht {
      text-align: center;
      margin-bottom: 10px;
      width: 100%;
      position: relative;
      z-index: 3;
    }

    .ticker-wrap {
      overflow: hidden;
      width: 100%;
      margin-top: 6px;
      margin-bottom: 8px;
    }

    .ticker-text {
      display: inline-block;
      white-space: nowrap;
      font-size: 22px;
      font-weight: 700;
      color: #fff;
      font-family: "Cairo", sans-serif;
      text-shadow: 0 2px 20px rgba(0, 0, 0, 0.6);
      line-height: 1.4;
    }

    html[data-lang="ar"] .ticker-text {
      animation: ticker-ar 55s linear infinite;
    }

    @keyframes ticker-ar {
      0% {
        transform: translateX(-100%);
      }

      100% {
        transform: translateX(100%);
      }
    }

    html[data-lang="en"] .ticker-text {
      animation: ticker-en 55s linear infinite;
    }

    @keyframes ticker-en {
      0% {
        transform: translateX(100%);
      }

      100% {
        transform: translateX(-100%);
      }
    }

    /* CATEGORY CARDS */
    .cg {
      display: flex;
      gap: 12px;
      width: 100%;
      max-width: 960px;
      flex-wrap: wrap;
      justify-content: center;
      margin-top: auto;
      margin-bottom: 130px;
      padding: 0 16px;
      position: relative;
      z-index: 3;
    }

    .cc {
      flex: 1;
      min-width: 155px;
      background: rgba(255, 255, 255, 0.1);
      backdrop-filter: blur(16px);
      border: 1.5px solid rgba(255, 255, 255, 0.2);
      border-radius: 16px;
      padding: 22px 16px;
      text-align: center;
      color: #fff;
      cursor: pointer;
      text-decoration: none;
      transition: all 0.3s cubic-bezier(0.2, 0.8, 0.3, 1);
    }

    .cc:hover {
      background: rgba(212, 160, 23, 0.18);
      border-color: rgba(212, 160, 23, 0.55);
      transform: translateY(-5px);
      box-shadow: 0 12px 30px rgba(0, 0, 0, 0.3);
    }

    .cc.on {
      background: rgba(212, 160, 23, 0.3);
      border-color: var(--gold);
      transform: translateY(-6px);
      box-shadow:
        0 0 0 2px rgba(212, 160, 23, 0.5),
        0 16px 38px rgba(0, 0, 0, 0.35);
    }

    .cc i {
      font-size: 38px;
      color: var(--glt);
      margin-bottom: 12px;
      display: block;
      transition: transform 0.3s;
    }

    .cc.on i,
    .cc:hover i {
      transform: scale(1.2);
    }

    .cc h6 {
      font-weight: 800;
      font-size: 17px;
      margin-bottom: 5px;
    }

    .cc p {
      font-size: 13px;
      color: rgba(255, 255, 255, 0.6);
      margin: 0;
    }

    .dots {
      position: absolute;
      bottom: 20px;
      left: 50%;
      transform: translateX(-50%);
      z-index: 4;
      display: flex;
      gap: 7px;
    }

    .dot {
      width: 8px;
      height: 8px;
      border-radius: 50%;
      background: rgba(255, 255, 255, 0.3);
      border: none;
      padding: 0;
      cursor: pointer;
      transition: 0.35s;
    }

    .dot.on {
      background: var(--gold);
      width: 24px;
      border-radius: 4px;
    }

    /* MARRIAGE OFFICIANT BADGE */
    .madh-badge {
      position: fixed;
      top: 130px;
      left: 18px;
      z-index: 200;
      background: rgba(58, 18, 96, 0.88);
      backdrop-filter: blur(12px);
      border: 1.5px solid rgba(212, 160, 23, 0.55);
      border-radius: 16px;
      padding: 12px 44px;
      display: flex;
      flex-direction: column;
      align-items: center;
      gap: 6px;
      text-decoration: none;
      color: #fff;
      transition: all 0.3s cubic-bezier(0.2, 0.8, 0.3, 1);
      box-shadow:
        0 6px 24px rgba(0, 0, 0, 0.35),
        0 0 0 1px rgba(212, 160, 23, 0.15);
      min-width: 72px;
    }

    .madh-badge:hover {
      background: rgba(212, 160, 23, 0.22);
      border-color: var(--gold);
      transform: translateY(-4px);
      box-shadow:
        0 12px 36px rgba(0, 0, 0, 0.45),
        0 0 0 2px rgba(212, 160, 23, 0.4);
      color: #fff;
    }

    .madh-icon {
      width: 48px;
      height: 48px;
      border-radius: 50%;
      background: linear-gradient(135deg, rgba(212, 160, 23, 0.25), rgba(212, 160, 23, 0.1));
      border: 1.5px solid rgba(212, 160, 23, 0.35);
      display: flex;
      align-items: center;
      justify-content: center;
      font-size: 22px;
      color: var(--glt);
      transition: all 0.3s;
      flex-shrink: 0;
    }

    .madh-badge:hover .madh-icon {
      background: linear-gradient(135deg, rgba(212, 160, 23, 0.5), rgba(212, 160, 23, 0.2));
      transform: scale(1.1);
      box-shadow: 0 4px 16px rgba(212, 160, 23, 0.4);
    }

    .madh-badge .madh-label {
      font-size: 11px;
      font-weight: 800;
      font-family: "Cairo", sans-serif;
      white-space: nowrap;
      text-align: center;
      color: rgba(255, 255, 255, 0.92);
      letter-spacing: 0.3px;
    }

    @media (max-width: 480px) {
      .madh-badge {
        top: 62px;
        left: 12px;
        padding: 9px 10px;
        min-width: 60px;
        border-radius: 13px;
      }

      .madh-icon {
        width: 38px;
        height: 38px;
        font-size: 17px;
      }

      .madh-badge .madh-label {
        font-size: 9.5px;
      }
    }

    /* ═══ RESPONSIVE — ALL BREAKPOINTS ═══ */

    /* Large tablet / small desktop */
    @media (max-width: 1024px) {
      .sr {
        grid-template-columns: repeat(3, 1fr);
      }

      .hb {
        max-width: 700px;
      }

      .sc {
        max-width: 100%;
      }
    }

    /* Tablet (≤ 768px) */
    @media (max-width: 768px) {
      .sr {
        grid-template-columns: repeat(2, 1fr);
      }

      .bsf {
        font-size: 14px;
        padding: 9px;
      }

      .ticker-text {
        font-size: 16px;
      }

      .cg {
        gap: 8px;
        padding: 0 12px;
        margin-bottom: 16px;
      }

      .cc {
        min-width: calc(50% - 8px);
        flex: none;
        padding: 18px 12px;
      }

      .cc i {
        font-size: 32px;
        margin-bottom: 10px;
      }

      .cc h6 {
        font-size: 15px;
      }

      .cc p {
        font-size: 12px;
      }
    }

    /* Mobile (≤ 480px) */
    @media (max-width: 480px) {

      /* Nav */
      .ni {
        height: 54px;
        padding: 0 14px;
      }

      .lt {
        font-size: 20px;
      }

      /* Hero — fills screen height cleanly */
      .hero {
        padding: 0;
      }

      /* Ticker — compact row */
      .ht {
        padding: 0 12px;
        width: 100%;
      }

      .ticker-wrap {
        margin-top: 6px;
        margin-bottom: 0;
      }

      .ticker-text {
        font-size: 12px;
      }

      /* Search block */
      .hb {
        padding: 8px 12px 0;
        width: 100%;
        max-width: 100%;
      }

      .sc {
        margin-top: 6px;
        margin-bottom: 0;
        padding: 10px 10px 8px;
        border-radius: 12px;
      }

      .sr {
        grid-template-columns: 1fr 1fr;
        gap: 5px;
      }

      .sl {
        font-size: 9px;
      }

      .sg select,
      .sg input[type="date"] {
        font-size: 10.5px;
        height: 28px;
        padding: 4px 6px;
      }

      .bsf {
        font-size: 13px;
        padding: 8px;
        margin-top: 6px;
      }

      /* Category cards — horizontal scroll */
      .cg {
        flex-wrap: nowrap;
        overflow-x: auto;
        justify-content: flex-start;
        scrollbar-width: none;
        -webkit-overflow-scrolling: touch;
        padding: 0 12px;
        margin-bottom: 14px;
        gap: 8px;
        max-width: 100%;
      }

      .cg::-webkit-scrollbar {
        display: none;
      }

      .cc {
        min-width: 120px;
        flex-shrink: 0;
        flex: none;
        padding: 14px 10px;
        border-radius: 13px;
      }

      .cc i {
        font-size: 26px;
        margin-bottom: 7px;
      }

      .cc h6 {
        font-size: 13px;
      }

      .cc p {
        font-size: 11px;
      }

      /* Dots — hidden, no room on mobile */
      .dots {
        display: none;
      }

      /* Floating icons — hide distracting extras */
      .fi:nth-child(3),
      .fi:nth-child(4),
      .fi:nth-child(5),
      .fi:nth-child(6) {
        display: none;
      }

    }

    /* Small mobile (≤ 390px) */
    @media (max-width: 390px) {
      .sr {
        grid-template-columns: 1fr 1fr;
      }

      .sc {
        padding: 8px 10px 7px;
      }

      .sg select,
      .sg input[type="date"] {
        font-size: 10.5px;
        height: 28px;
        padding: 4px 6px;
      }

      .bsf {
        font-size: 13px;
        padding: 8px 10px;
      }

      .cc {
        min-width: 122px;
        padding: 13px 9px;
      }

      .cc i {
        font-size: 24px;
      }

      .cc h6 {
        font-size: 12px;
      }

      .ticker-text {
        font-size: 13px;
      }

      .lt {
        font-size: 18px;
      }
    }

    /* Very small (≤ 320px) */
    @media (max-width: 320px) {
      .ni {
        height: 50px;
        padding: 0 12px;
      }

      .lt {
        font-size: 16px;
      }

      .sc {
        padding: 7px 8px 6px;
        border-radius: 10px;
      }

      .sr {
        grid-template-columns: 1fr 1fr;
        gap: 5px;
      }

      .cc {
        min-width: 108px;
        padding: 10px 7px;
      }

      .bsf {
        font-size: 12px;
        padding: 8px;
      }

    }

    /* Short viewport heights (landscape phones / small laptops) */
    @media (max-height: 700px) {
      .ht {
        margin-bottom: 4px;
      }

      .ticker-wrap {
        margin-top: 2px;
        margin-bottom: 4px;
      }

      .sc {
        margin-bottom: 8px;
      }

      /* Hero content is pulled up on short viewports — keep the fixed
         officiant badge from overlapping the search box */
      .madh-badge {
        top: 74px;
        padding: 8px 28px;
        min-width: 60px;
      }

      .madh-icon {
        width: 38px;
        height: 38px;
        font-size: 17px;
      }
    }



 /* =========================================
   إصلاحات زر المأذون والقائمة (Desktop & Mobile)
========================================= */

/* إصلاح النقر على زر القائمة (الهامبرغر) */
.ham {
  position: relative !important;
  z-index: 999999 !important;
  pointer-events: auto !important;
  cursor: pointer !important;
}

/* 🔥 السر هنا: جعل القائمة المنسدلة تطفو فوق الصفحة ولا تدفعها للأسفل 🔥 */
.mob-open .mob-menu {
  position: absolute !important;
  top: 100% !important; /* تفتح تحت الهيدر مباشرة */
  left: 0 !important;
  right: 0 !important;
  background: rgba(74, 31, 116, 0.98) !important;
  z-index: 999998 !important;
  display: flex !important;
  flex-direction: column !important;
  box-shadow: 0 15px 35px rgba(0,0,0,0.6) !important;
}

/* تنسيق زر الجوال الأنيق أسفل البحث */
.madh-mobile-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: rgba(58, 18, 96, 0.95);
  border: 1.5px solid rgba(212, 160, 23, 0.6);
  padding: 10px 24px;
  border-radius: 12px;
  color: #fff;
  text-decoration: none;
  font-weight: 700;
  font-size: 14px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  margin-top: 8px;
  margin-bottom: 8px;
  width: 100%;
  max-width: 320px;
  z-index: 5;
  transition: all 0.2s ease;
}

.madh-mobile-btn i {
  color: var(--glt);
  font-size: 16px;
}

.madh-mobile-btn:hover {
  background: var(--gold);
  color: #1e1030;
}

.madh-mobile-btn:hover i {
  color: #1e1030;
}

/* -------------------------------------
   التحكم في الظهور والاختفاء حسب الشاشة
-------------------------------------- */

/* في شاشات الكمبيوتر والآيباد العريض */
@media (min-width: 769px) {
  .mobile-only {
    display: none !important;
  }
}

/* في شاشات الجوال */
@media (max-width: 768px) {
  .desktop-only {
    display: none !important;
  }
  .mobile-only {
    display: flex !important;
  }
}