html, body {
    font-family: 'El Messiri', 'Tahoma', 'Arial', sans-serif;
}

/* ألوان عامة */
:root {
    --bg: #f4f5f7;
    --header-bg: #0b3565;
    --text-main: #222;
    --text-muted: #4a4a4a;
    --card-bg: #ffffff;
    --card-border: #B8BDCF;
    --card-shadow: 0 8px 18px rgba(15, 32, 60, 0.06);
    --accent: #0b8fe6;
    --card2: #d7efff;
}

/* إعادة ضبط بسيطة */
*,
*::before,
*::after {
    box-sizing: border-box;
}

body.home-page {
    margin: 0;
    background: linear-gradient(180deg, #0b3565, #a4bde4, #dcecff, #FFFEFF);
    background-size: cover;
    color: var(--text-main);
}
body {
    background-color: #eee;
    background-image: linear-gradient(135deg, rgba(255, 255, 255, .50) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .50) 50%, rgba(255, 255, 255, .50) 75%, transparent 75%, transparent);
    background-size: 200px 200px;
    margin: 0;
    padding: 0;
}

.home-page h2 {text-align: center; font-size: 1.875em; color: white; }
.home-page h3 {text-align: center; font-size: 1.5em; color: white; }
.home-page h4 {text-align: center; font-size: 1.25em; color: white; }

/* ===== الهيدر ===== */

.site-header {
  background: linear-gradient(180deg, #ffffff, #f8fafc);
  border-bottom: 1px solid #e5e7eb;
  position: relative;
}

/* خط زخرفي علوي */
.site-header::after {
  content: "";
  height: 3px;
  display: block;
  background: linear-gradient(90deg, #2563eb, #22c55e, #0ea5e9);
}

/* ===== Inner ===== */
.site-header-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 18px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

/* ===== Brand ===== */
.site-brand {
  display: flex;
  align-items: center;
  gap: 14px;
}

.brand-icon {
  font-size: 2em;
  border-radius: 12px;
  padding: 10px;
}

.brand-text h1 {
  margin: 0;
  font-size: 1.375em;
  color: #111827;
  line-height: 1.2;
}

.brand-tagline {
  font-size: 0.75em;
  color: #6b7280;
}

/* ===== Meta ===== */
.site-meta {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.hero-greeting {
  font-size: 1em;
  font-weight: 600;
  color: #2563eb;
}

.hero-day {
  font-size: 0.875em;
  color: #374151;
  margin-top: 2px;
}

.hero-date {
  margin-top: 6px;
  font-size: 0.75em;
  color: #6b7280;
  display: flex;
  gap: 6px;
  justify-content: center;
}

/* ===== Mobile ===== */
@media (max-width: 700px) {
  .site-header-inner {
    flex-direction: column;
    text-align: center;
  }

  .site-meta {
    text-align: center;
  }
}

/* ===== المحتوى الرئيسي ===== */

.page-main {
    max-width: 1100px;
    margin: 16px auto 32px;
    padding: 0 12px 24px;
}

/* الأقسام */
.section {
    margin-bottom: 28px;
}

.section-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1.375em;
    margin: 0 0 12px;
    color: #0c3465;
    text-shadow: 1px 1px white;
}

.section-title .icon {
    font-size: 1.5em;
}

.section h4 {
    font-size: 1em;
    font-family: 'El Messiri', 'Tahoma', 'Arial', sans-serif;
    margin: 0 10px;
}
.section p {
    font-family: 'El Messiri', 'Tahoma', 'Arial', sans-serif;
    margin: 0 10px;
}
@media(max-width:768px) {
    .section h4 { font-size: 0.75em; }
    .section p  { font-size: 0.688em; }
}

/* شبكة الكروت */
.grid {
    display: grid;
    gap: 12px;
}
/* شبكة الكروت */
.grid2 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
    gap: 12px;
}

/* الكرت */
.card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 14px;
    box-shadow: var(--card-shadow);
    padding: 10px 12px;
    min-height: 56px; 
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    text-decoration: none;
    color: var(--text-main);
    font-size: 1.5em;
    font-weight: 600;
    transition: transform 0.15s ease-out, box-shadow 0.15s ease-out, border-color 0.15s ease-out;
}
.card2 {
    background: var(--card2);
    border: 1px solid var(--card-border);
    border-radius: 14px;
    box-shadow: var(--card-shadow);
    padding: 10px 12px;
    min-height: 56px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    text-decoration: none;
    color: var(--text-main);
    font-size: 1.125em;
    font-weight: 600;
    transition: transform 0.15s ease-out, box-shadow 0.15s ease-out, border-color 0.15s ease-out;
}

/* الكروت ذات الإطار فقط */
.card-outline {
    /*background: transparent;*/
    border-style: dashed;
    border-color: #eaa63f;
    box-shadow: none;
}

/* الأيقونة داخل الكرت – مقاس ثابت لتقليل تحرك النص */
.card .icon {
    font-size: 1.375em;
    width: 2em;
    height: 1.3em;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.card .icon2 {
    font-size: 1.125em;
    width: 2em;
    height: 1.3em;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

/* تأثير hover */
.card:hover {
    transform: translateY(-3px);
    border-color: var(--accent);
    box-shadow: 0 10px 22px rgba(11, 143, 230, 0.16);
    color: var(--accent);
}

/* ===== Footer Base ===== */
.site-footer {
  margin-top: 60px;
  background: linear-gradient(180deg, #ffffff, #f9fafb);
  border-top: 1px solid #e5e7eb;
  font-family: "El Messiri", system-ui;
}

/* خط فاصل علوي متدرج */
.site-footer::before {
  content: "";
  display: block;
  height: 3px;
  background: linear-gradient(90deg, #2563eb, #22c55e, #0ea5e9);
}

/* ===== Inner ===== */
.site-footer-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 12px 16px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 10px;
  font-size: 0.813em;
  color: #6b7280;
  text-align: center;
}

/* ===== Brand Row ===== */
.footer-brand {
  font-weight: 500;
  color: #374151;
}

.footer-sep {
  opacity: 0.5;
}

/* ===== Stats ===== */
.footer-stats {
  background: #f1f5f9;
  border-radius: 999px;
  padding: 8px 18px;
  font-size: 0.813em;
}

.stats-box b {
  color: #111827;
}

.stats-box .divider {
  margin: 0 8px;
  opacity: 0.5;
}

/* ===== Tech Info ===== */
.footer-tech {
  font-size: 0.75em;
  color: #9ca3af;
}

/* ===== Links ===== */
.footer-links {
  gap: 16px;
}

.footer-links a {
  color: #2563eb;
  text-decoration: none;
  font-weight: 500;
  position: relative;
}

.footer-links a::after {
  content: "";
  position: absolute;
  bottom: -3px;
  right: 0;
  width: 0;
  height: 2px;
  background: #2563eb;
  transition: width 0.2s ease;
}

.footer-links a:hover::after {
  width: 100%;
}

.footer-links a:hover {
  color: #1e40af;
}

/* ===== Mobile ===== */
@media (max-width: 600px) {
  .footer-stats {
    border-radius: 14px;
  }
}

/* ===== الجوال ===== */

@media (max-width: 600px) {
    .page-main {
        padding-inline: 10px;
    }

    .card {
        font-size: 1.375em;
        justify-content: flex-start;
    }
    .card-outline {
        justify-content: center;
    }
    .grid {
    display: grid;
    gap: 12px;
}
.home-page h2 {text-align: center; font-size: 1.125em; color: white; }
}

/* تقليل الحركة لمن يفضل ذلك */
@media (prefers-reduced-motion: reduce) {
    * {
        scroll-behavior: auto !important;
        animation-duration: 0.001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.001ms !important;
    }
}

.tool-bottom-content {
        width: 90%;
    margin: 0 auto;
}
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0,0,0,0);
    white-space: nowrap;
    border: 0;
}
.brand-text h1 a {
    color: #cfe1f5;
    font-size: 2.188em;
    text-decoration: none;
}
.brand-text2 a {
    color: #cfe1f5;
    font-size: 1.25em;
    text-decoration: none;
}
/* ===========================
   📱 تنسيق الهيدر للجوال
=========================== */
@media (max-width: 480px) {

  .site-header-inner {
    flex-direction: column;
    text-align: center;           /* توسيط كامل */
    gap: 6px;
  }

  .brand {
    justify-content: center;      /* توسيط الشعار */
  }

  .brand-text h1 {
    font-size: 1.625em;              /* حجم مناسب للجوال */
    margin: 0;
  }

  .brand-icon {
    font-size: 1.75em;
  }

  .hero-info {
    text-align: center;           /* توسيط النصوص */
  }

  #date-box {
    align-items: center !important;
  }

  #gregorian-date,
  #hijri-date {
    width: 100%;
    text-align: center; 
  }
}
/* SemiBold 600 */ 
@font-face {
  font-family: 'El Messiri';
  src: url('https://www.sult4n.com/fonts/ElMessiri-SemiBold.woff2') format('woff2');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
/* NAV */
/* ===== شريط الأقسام ===== */
.main-nav {
  background: linear-gradient(135deg, #0f172a, #1e293b);
  border-top: 1px solid rgba(255,255,255,.08);
  border-bottom: 1px solid rgba(0,0,0,.2);
}

.nav-list {
  list-style: none;
  display: flex;
  gap: 6px;
  margin: 0;
  padding: 6px 12px;
  justify-content: center;
  flex-wrap: wrap;
}

.nav-list li a {
  display: block;
  padding: 8px 14px;
  font-family: "El Messiri", system-ui;
  font-size: 0.938em;
  color: #e5e7eb;
  text-decoration: none;
  border-radius: 8px;
  transition: all .25s ease;
  white-space: nowrap;
}

.nav-list li a:hover {
  background: rgba(255,255,255,.12);
  color: #fff;
}

/* الرابط الحالي */
.nav-list li a.active {
  background: #2563eb;
  color: #fff;
  box-shadow: 0 3px 8px rgba(37,99,235,.4);
}

/* موبايل */
@media (max-width: 768px) {
  .nav-list {
    justify-content: flex-start;
    overflow-x: auto;
    scrollbar-width: none;
  }
  .nav-list::-webkit-scrollbar {
    display: none;
  }
}
.whats {
  display: flex;
  justify-content: center;
}

.button2 {
-webkit-appearance: none;
    /* display: inline-block; */
    text-decoration: none;
    cursor: pointer;
    border: 0;
    border-radius: 5px;
    background: #25D366;
    color: #fff !important;
    font-weight: 700;
    font-family: 'El Messiri';
    outline: 0;
    font-size: 0.8em;
    padding: 0.65em 1.5em 0.65em 1.5em;
    text-align: center;
    margin: 0 0 0 0;
    box-shadow: 1px 1px #cc15cd;
}

.content2 {
  background: #fff;
  width: 90%;
  margin: 20px auto 0;
  padding: 20px;
  border-radius: 10px;
  line-height: 1.9;
  font-size: 1em;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.content2 p {
  text-align: justify;
}
.content2 h2 {
    color: #000;
}

.dc-related {
  text-align: center;
  margin-bottom: 20px;
  font-size: 0.938em;
}

.dc-related p {
  margin-bottom: 8px;
  color: #444;
}

.dc-related-links {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
}

.dc-btn-outline {
  border-radius: 999px;
  border: 1px solid #0c3465;
  color: #0c3465;
  background: #fff;
  padding: 7px 16px;
  font-size: 0.875em;
  text-decoration: none;
}

.dc-btn-outline:hover {
  background: #0c3465;
  color: #fff;
}
.dc-related h3 {
    color: #000;
}

.footer2 {
  text-align: center;
  padding: 10px;
}

p.footer2 {
  font-size: small;
  margin: 0px 10px 10px 0px;
  color: #000;
}