/* ==========================================================================
   POLICY PAGES - policies.css (PREMIUM CARD DESIGN)
   ========================================================================== */

/* ── Policy Hero Header (Centered, Big, Yellow / Gold) ─────────────────── */
.policy-reference-page .breadcrumbs,
main.article-reference-page:has(.policy-page) .breadcrumbs {
  display: flex !important;
  justify-content: center !important;
  text-align: center !important;
  margin: 0 auto 1.8rem auto !important;
  width: 100% !important;
}

.policy-reference-page .post-article,
.policy-post-article,
main.article-reference-page:has(.policy-page) .post-article {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: flex-start !important;
  grid-template-columns: 1fr !important;
  grid-template-rows: auto !important;
  width: 100% !important;
  max-width: 1000px !important;
  margin: 0 auto !important;
}

.policy-reference-page .post-header,
.policy-hero-header,
main.article-reference-page:has(.policy-page) .post-header {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  text-align: center !important;
  width: 100% !important;
  margin: 0 auto 2.5rem auto !important;
  padding: 0 1rem !important;
}

.policy-reference-page .post-header h1,
.policy-hero-header h1,
main.article-reference-page:has(.policy-page) .post-header h1 {
  text-align: center !important;
  margin: 0 auto !important;
  width: 100% !important;
  color: #ffc13b !important;
  -webkit-text-fill-color: #ffc13b !important;
  font-family: 'Cairo', "IBM Plex Sans Arabic", sans-serif !important;
  font-size: clamp(2.8rem, 6.5vw, 4.6rem) !important;
  font-weight: 900 !important;
  line-height: 1.15 !important;
  letter-spacing: -0.01em !important;
  text-shadow: 0 4px 25px rgba(0, 0, 0, 0.4) !important;
}

.policy-reference-page .post-body,
main.article-reference-page:has(.policy-page) .post-body {
  width: 100% !important;
  max-width: 900px !important;
  margin: 0 auto !important;
}

.post-body .policy-page {
  max-width: 850px;
  margin: 2rem auto 4rem auto;
  font-family: 'Cairo', sans-serif;
}

/* ── Intro Section ───────────────────────────────────────────────────────── */
.post-body .policy-intro {
  background: linear-gradient(135deg, rgba(23,107,104,0.03), rgba(23,107,104,0.08));
  border: 1px solid rgba(23,107,104,0.1);
  border-right: 5px solid var(--color-primary, #176b68);
  border-radius: 16px;
  padding: 2.5rem;
  margin-bottom: 3rem;
  box-shadow: 0 4px 20px rgba(0,0,0,0.02);
}
html[dir="ltr"] .post-body .policy-intro {
  border-right: 1px solid rgba(23,107,104,0.1);
  border-left: 5px solid var(--color-primary, #176b68);
}
.post-body .policy-intro p {
  font-size: 1.15rem;
  line-height: 1.8;
  color: var(--color-heading, #1f2937);
  margin: 0;
  font-weight: 700;
}

/* ── Cards (Sections) ────────────────────────────────────────────────────── */
.post-body .policy-section {
  background: #ffffff;
  border: 1px solid rgba(0,0,0,0.06);
  border-radius: 16px;
  padding: 2.5rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.03), 0 2px 4px -1px rgba(0, 0, 0, 0.02);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.post-body .policy-section:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 20px -5px rgba(0, 0, 0, 0.06), 0 4px 6px -3px rgba(0, 0, 0, 0.04);
}

/* ── Headings ────────────────────────────────────────────────────────────── */
.post-body .policy-section h2 {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--color-primary, #176b68);
  margin-top: 0;
  margin-bottom: 1.8rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid rgba(0,0,0,0.06);
}
.post-body .policy-num {
  background: rgba(23,107,104,0.1);
  color: var(--color-primary, #176b68);
  font-size: 1.2rem;
  font-weight: 800;
  width: 46px;
  height: 46px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* ── Text & Typography ───────────────────────────────────────────────────── */
.post-body .policy-section p {
  font-size: 1.05rem;
  line-height: 1.9;
  color: #4b5563;
  margin-top: 0;
  margin-bottom: 1.2rem;
}
.post-body .policy-section p:last-child {
  margin-bottom: 0;
}
.post-body .policy-section strong {
  color: #1f2937;
  font-weight: 700;
}

/* ── Lists ───────────────────────────────────────────────────────────────── */
.post-body .policy-list {
  margin: 0 0 1.2rem 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.85rem;
}
.post-body .policy-list:last-child {
  margin-bottom: 0;
}
.post-body .policy-list li {
  position: relative;
  padding-right: 2rem;
  font-size: 1.05rem;
  color: #4b5563;
  line-height: 1.8;
}
html[dir="ltr"] .post-body .policy-list li {
  padding-right: 0;
  padding-left: 2rem;
}
.post-body .policy-list li::before {
  content: "✔";
  position: absolute;
  right: 0;
  top: 3px;
  color: var(--color-primary, #176b68);
  font-size: 1.1rem;
}
html[dir="ltr"] .post-body .policy-list li::before {
  right: auto;
  left: 0;
}

/* ── Highlights ──────────────────────────────────────────────────────────── */
.post-body .policy-highlight {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1.25rem 1.5rem;
  border-radius: 12px;
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 1.2rem;
}
.post-body .policy-highlight--success {
  background: #f0fdf4;
  color: #166534;
  border: 1px solid #bbf7d0;
}
.post-body .policy-highlight--warning {
  background: #fefce8;
  color: #854d0e;
  border: 1px solid #fef08a;
}
.post-body .policy-highlight--danger {
  background: #fef2f2;
  color: #991b1b;
  border: 1px solid #fecaca;
}

/* ── Links & Date ────────────────────────────────────────────────────────── */
.post-body .policy-page a {
  color: var(--color-primary, #176b68);
  font-weight: 700;
  text-decoration: none;
  border-bottom: 2px solid rgba(23,107,104,0.2);
  transition: border-color 0.2s;
}
.post-body .policy-page a:hover {
  border-color: var(--color-primary, #176b68);
}
.post-body .policy-date {
  margin-top: 3rem;
  font-size: 0.95rem;
  color: #9ca3af;
  text-align: center;
  font-weight: 500;
}

/* ── Dark Mode ───────────────────────────────────────────────────────────── */
[data-theme="dark"] .post-body .policy-intro {
  background: rgba(255,255,255,0.03);
  border-color: rgba(255,255,255,0.05);
}
[data-theme="dark"] .post-body .policy-intro p {
  color: #f3f4f6;
}
[data-theme="dark"] .post-body .policy-section {
  background: var(--surface-2, #1e293b);
  border-color: rgba(255,255,255,0.05);
  box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}
[data-theme="dark"] .post-body .policy-section h2 {
  border-bottom-color: rgba(255,255,255,0.05);
  color: #fff;
}
[data-theme="dark"] .post-body .policy-num {
  background: rgba(23,107,104,0.4);
  color: #86efac;
}
[data-theme="dark"] .post-body .policy-section p,
[data-theme="dark"] .post-body .policy-list li {
  color: #cbd5e1;
}
[data-theme="dark"] .post-body .policy-section strong {
  color: #f8fafc;
}
[data-theme="dark"] .post-body .policy-highlight--success {
  background: rgba(22,163,74,0.15); color: #86efac; border-color: rgba(22,163,74,0.3);
}
[data-theme="dark"] .post-body .policy-highlight--warning {
  background: rgba(234,179,8,0.15); color: #fde047; border-color: rgba(234,179,8,0.3);
}
[data-theme="dark"] .post-body .policy-highlight--danger {
  background: rgba(239,68,68,0.15); color: #fca5a5; border-color: rgba(239,68,68,0.3);
}

/* ── Mobile Responsive ───────────────────────────────────────────────────── */
@media (max-width: 768px) {
  .post-body .policy-page {
    margin-top: 1rem;
  }
  .post-body .policy-intro {
    padding: 1.5rem;
    font-size: 1.05rem;
  }
  .post-body .policy-section {
    padding: 1.5rem;
    border-radius: 12px;
  }
  .post-body .policy-section h2 {
    font-size: 1.2rem;
    gap: 1rem;
  }
  .post-body .policy-num {
    width: 38px;
    height: 38px;
    font-size: 1.05rem;
  }
  .post-body .policy-section p, 
  .post-body .policy-list li {
    font-size: 1rem;
  }
}

/* Hide hero navigation buttons on all policy pages */
.hero-related-actions,
.policy-page ~ .hero-related-actions,
.post-header .hero-related-actions,
.article-reference-page .hero-related-actions {
  display: none !important;
}

