
:root {
  --paper: #f5f2eb;
  --paper2: #ebe6db;
  --ink: #22251f;
  --muted: #77786f;
  --green: #173b63;
  --green-deep: #102b49;
  --gold: #b79a6b;
  --line: rgba(34, 37, 31, .17);
  --display: "Playfair Display", Georgia, serif;
  --body: "DM Sans", Arial, sans-serif;
  --gutter: clamp(22px, 6.3vw, 104px);
  --ease: cubic-bezier(.22, 1, .36, 1);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 90px;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--body);
  font-size: 14px;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }
button, input { font: inherit; }

::selection {
  background: var(--gold);
  color: var(--ink);
}

/* Announcement and header */

.announcement {
  min-height: 31px;
  padding: 8px var(--gutter);
  display: flex;
  justify-content: space-between;
  gap: 16px;
  background: var(--green);
  color: var(--paper);
  font-size: 10px;
  letter-spacing: .07em;
}

.site-header {
  min-height: 88px;
  padding: 18px var(--gutter);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 26px;
  border-bottom: 1px solid var(--line);
  position: relative;
  z-index: 20;
  background: var(--paper);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  flex-shrink: 0;
}

.brand-mark {
  width: 39px;
  height: 39px;
  display: grid;
  place-items: center;
  border: 1px solid var(--gold);
  color: var(--green);
  font-family: var(--display);
  font-size: 17px;
}

.brand-copy {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.brand-copy strong {
  font-family: var(--display);
  font-weight: 500;
  font-size: 17px;
  line-height: 1;
}

.brand-copy small {
  color: var(--muted);
  font-size: 8px;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: clamp(14px, 2vw, 28px);
}

.desktop-nav a {
  font-size: 11px;
  color: #5d5f57;
  text-decoration: none;
}

.desktop-nav a:hover,
.desktop-nav a[aria-current="page"] {
  color: var(--green);
}

.header-cta,
.btn {
  min-height: 44px;
  padding: 14px 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  border: 1px solid transparent;
  text-decoration: none;
  font-size: 11px;
  transition: background .25s ease, color .25s ease;
}

.header-cta {
  background: var(--green);
  color: var(--paper);
  white-space: nowrap;
}

.header-cta:hover,
.btn-dark:hover {
  background: #244f78;
}

.menu-toggle,
.mobile-menu {
  display: none;
}

.eyebrow {
  margin: 0;
  font-size: 10px;
  letter-spacing: .16em;
  line-height: 1.7;
  text-transform: uppercase;
}

.display {
  font-family: var(--display);
  font-weight: 400;
  letter-spacing: -.045em;
  line-height: 1.13;
}

.display em {
  color: var(--gold);
  font-weight: 400;
}

.section-pad {
  padding: clamp(70px, 9vw, 125px) var(--gutter);
}

/* Hero */

.blog-hero {
  min-height: clamp(520px, 70vh, 720px);
  padding: 95px var(--gutter) 75px;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
  background: var(--green-deep);
  color: var(--paper);
}

.blog-hero-photo,
.blog-hero-shade {
  position: absolute;
  inset: 0;
}

.blog-hero-photo {
  background:
    url("https://images.unsplash.com/photo-1519817650390-64a93db51149?auto=format&fit=crop&w=2200&q=90")
    center 48% / cover no-repeat;
}

.blog-hero-shade {
  background: linear-gradient(
    90deg,
    rgba(17,35,26,.92),
    rgba(17,35,26,.66) 52%,
    rgba(17,35,26,.18)
  );
}

.blog-hero-inner {
  position: relative;
  z-index: 1;
  max-width: 820px;
}

.blog-hero-inner .eyebrow {
  color: #dfc79d;
}

.blog-hero h1 {
  margin: 24px 0;
  font-family: var(--display);
  font-size: clamp(46px, 7vw, 84px);
  font-weight: 400;
  line-height: 1.06;
  letter-spacing: -.045em;
}

.blog-hero h1 em {
  color: #d0b17c;
  font-weight: 400;
}

.blog-hero-inner > p:not(.eyebrow) {
  max-width: 530px;
  color: rgba(245,242,235,.84);
  line-height: 1.9;
  font-size: 15px;
  margin: 0 0 28px;
}

.btn-light {
  background: var(--paper);
  color: var(--green);
}

.btn-light:hover {
  background: #fff;
}

.hero-caption {
  position: absolute;
  right: var(--gutter);
  bottom: 24px;
  z-index: 1;
  color: rgba(245,242,235,.78);
  font-size: 10px;
  letter-spacing: .07em;
}

/* Intro */

.library-intro {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: clamp(40px, 8vw, 120px);
}

.library-intro .eyebrow,
.library-heading .eyebrow,
.masail-heading .eyebrow,
.newsletter-cta .eyebrow {
  color: var(--muted);
}

.library-intro h2 {
  margin: 20px 0 0;
  font-size: clamp(40px, 5vw, 62px);
}

.library-intro .body-copy {
  max-width: 580px;
  color: var(--muted);
  line-height: 1.95;
}

/* Article library */

.blog-library {
  background: var(--paper2);
}

.library-heading {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 30px;
  margin-bottom: 35px;
}

.library-heading h2 {
  margin: 18px 0 0;
  font-size: clamp(38px, 5vw, 60px);
}

.search-box {
  width: min(310px, 100%);
  display: flex;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid var(--ink);
  padding: 0 0 11px;
}

.search-box input {
  width: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink);
  font-size: 12px;
}

.search-box input::placeholder {
  color: var(--muted);
}

.search-box > span:last-child {
  font-size: 24px;
  color: var(--gold);
}

.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;
}

.filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-bottom: 38px;
}

.filter-btn {
  border: 1px solid var(--line);
  padding: 10px 15px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font-size: 11px;
  transition: all .2s ease;
}

.filter-btn:hover,
.filter-btn.is-active {
  background: var(--green);
  color: var(--paper);
  border-color: var(--green);
}

.article-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 42px 24px;
}

.article-card {
  min-width: 0;
}

.article-card[hidden] {
  display: none !important;
}

.article-image {
  min-height: 245px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 15px;
  background-color: #cfc8b8;
  background-size: cover;
  background-position: center;
  text-decoration: none;
  position: relative;
  overflow: hidden;
}

.article-image::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(15,25,19,.25),
    transparent 50%,
    rgba(15,25,19,.15)
  );
  pointer-events: none;
}

.image-iraq {
  background-image:
    url("https://images.unsplash.com/photo-1565552645632-d725f8bfc19a?auto=format&fit=crop&w=1000&q=85");
}

.image-mosque {
  background-image:
    url("https://images.unsplash.com/photo-1519817650390-64a93db51149?auto=format&fit=crop&w=1000&q=85");
}

.image-book {
  background-image:
    url("https://images.unsplash.com/photo-1609599006353-e629aaabfeae?auto=format&fit=crop&w=1000&q=85");
}

.image-travel {
  background-image:
    url("https://images.unsplash.com/photo-1500530855697-b586d89ba3ee?auto=format&fit=crop&w=1000&q=85");
}

.image-architecture {
  background-image:
    url("https://images.unsplash.com/photo-1577717903315-1691ae25ab3f?auto=format&fit=crop&w=1000&q=85");
}

.image-prayer {
  background-image:
    url("https://images.unsplash.com/photo-1542816417-0983c9c9ad53?auto=format&fit=crop&w=1000&q=85");
}

.article-category {
  position: relative;
  z-index: 1;
  padding: 8px 10px;
  background: var(--paper);
  color: var(--green);
  font-size: 9px;
  letter-spacing: .1em;
}

.image-arrow {
  position: relative;
  z-index: 1;
  width: 31px;
  height: 31px;
  display: grid;
  place-items: center;
  background: var(--paper);
  color: var(--green);
}

.article-meta {
  display: flex;
  gap: 8px;
  margin-top: 19px;
  color: var(--muted);
  font-size: 9px;
  letter-spacing: .09em;
}

.article-card h3 {
  margin: 12px 0 9px;
  font-family: var(--display);
  font-size: 25px;
  line-height: 1.22;
  font-weight: 400;
}

.article-card h3 a {
  text-decoration: none;
}

.article-card h3 a:hover {
  color: #776044;
}

.article-card > p {
  min-height: 52px;
  margin: 0 0 16px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.8;
}

.read-link {
  display: inline-flex;
  gap: 15px;
  align-items: center;
  padding-bottom: 7px;
  border-bottom: 1px solid var(--gold);
  font-size: 11px;
  text-decoration: none;
}

.read-link span {
  color: var(--gold);
}

.no-results {
  padding: 30px 0;
  color: var(--muted);
}

/* Masla Masael */

.masail-section {
  background: var(--paper);
}

.masail-heading {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: end;
  gap: clamp(35px, 8vw, 110px);
  margin-bottom: 50px;
}

.masail-heading h2 {
  margin: 18px 0 0;
  font-size: clamp(40px, 5vw, 64px);
}

.masail-heading .body-copy {
  margin: 0;
  max-width: 570px;
  color: var(--muted);
  line-height: 1.95;
}

.masail-topics {
  border-top: 1px solid var(--line);
}

.masail-topic {
  display: grid;
  grid-template-columns: 55px 1fr 35px;
  gap: 20px;
  align-items: center;
  padding: 25px 0;
  border-bottom: 1px solid var(--line);
  text-decoration: none;
}

.topic-number {
  color: var(--gold);
  font-size: 11px;
  letter-spacing: .1em;
}

.masail-topic strong {
  display: block;
  font-family: var(--display);
  font-size: 23px;
  font-weight: 400;
  margin-bottom: 7px;
}

.masail-topic small {
  display: block;
  color: var(--muted);
  line-height: 1.7;
  font-size: 12px;
}

.topic-arrow {
  justify-self: end;
  color: var(--gold);
  font-size: 19px;
}

.masail-topic:hover strong {
  color: #776044;
}

.topic-static {
  cursor: default;
}

.masail-note {
  margin-top: 32px;
  padding: 22px 25px;
  display: flex;
  align-items: flex-start;
  gap: 17px;
  background: var(--paper2);
}

.note-mark {
  width: 25px;
  height: 25px;
  flex: 0 0 25px;
  display: grid;
  place-items: center;
  border: 1px solid var(--gold);
  color: var(--green);
  font-family: var(--display);
}

.masail-note p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.9;
}

.masail-note strong {
  color: var(--ink);
}

/* Final CTA and footer */

.newsletter-cta {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  background: var(--paper2);
}

.newsletter-cta h2 {
  margin: 20px 0;
  font-size: clamp(40px, 5vw, 62px);
}

.newsletter-cta > p:not(.eyebrow) {
  max-width: 500px;
  color: var(--muted);
  line-height: 1.9;
  margin: 0 0 25px;
}

.btn-dark {
  background: var(--green);
  color: var(--paper);
}

.site-footer {
  padding: 42px var(--gutter) 22px;
  background: var(--green);
  color: var(--paper);
}

.footer-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 25px;
  padding-bottom: 35px;
}

.footer-brand .brand-mark {
  color: var(--paper);
}

.footer-brand .brand-copy small {
  color: rgba(245,242,235,.62);
}

.footer-brand .brand-copy strong {
  color: var(--paper);
}

.footer-top > p {
  margin: 0;
  color: rgba(245,242,235,.72);
  font-family: var(--display);
  font-size: 18px;
}

.footer-contact {
  color: var(--paper);
  text-decoration: none;
  font-size: 11px;
}

.footer-bottom {
  padding-top: 18px;
  border-top: 1px solid rgba(245,242,235,.2);
  display: flex;
  justify-content: space-between;
  gap: 18px;
  color: rgba(245,242,235,.65);
  font-size: 10px;
}

.footer-bottom a {
  color: var(--paper);
  text-decoration: none;
}

.floating-whatsapp {
  position: fixed;
  z-index: 30;
  right: 24px;
  bottom: 22px;
  min-height: 48px;
  padding: 0 17px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border-radius: 40px;
  background: var(--green);
  color: white;
  text-decoration: none;
  font-size: 11px;
  box-shadow: 0 8px 28px rgba(0,0,0,.14);
}

.floating-whatsapp:hover {
  background: #244f78;
}

/* Reveal effects: content remains visible if JS is unavailable */

.js-ready [data-reveal] {
  opacity: 0;
  transform: translateY(14px);
}

.js-ready [data-reveal].is-visible {
  opacity: 1;
  transform: none;
  transition: opacity .6s ease, transform .6s var(--ease);
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  .js-ready [data-reveal],
  .js-ready [data-reveal].is-visible {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* Tablet */

@media (max-width: 900px) {
  .desktop-nav { gap: 12px; }
  .desktop-nav a { font-size: 10px; }
  .header-cta { padding: 12px; }

  .article-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Mobile */

@media (max-width: 720px) {
  .announcement {
    font-size: 9px;
    gap: 8px;
  }

  .announcement span:last-child {
    text-align: right;
  }

  .site-header {
    min-height: 75px;
    gap: 14px;
  }

  .brand-mark {
    width: 35px;
    height: 35px;
  }

  .brand-copy strong { font-size: 15px; }
  .brand-copy small { font-size: 7px; }

  .desktop-nav,
  .site-header > .header-cta {
    display: none;
  }

  .menu-toggle {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    border: 0;
    padding: 10px 0 10px 10px;
    background: transparent;
    color: var(--ink);
    font-size: 11px;
    cursor: pointer;
  }

  .menu-toggle .close-word { display: none; }

  .menu-toggle[aria-expanded="true"] .menu-word {
    display: none;
  }

  .menu-toggle[aria-expanded="true"] .close-word {
    display: inline;
  }

  .menu-toggle i {
    display: flex;
    flex-direction: column;
    gap: 5px;
    width: 18px;
  }

  .menu-toggle i b {
    height: 1px;
    width: 18px;
    background: currentColor;
  }

  .mobile-menu {
    display: flex;
    position: absolute;
    z-index: 19;
    top: 106px;
    left: 0;
    right: 0;
    padding: 20px var(--gutter) 28px;
    background: var(--paper);
    border-bottom: 1px solid var(--line);
    flex-direction: column;
    gap: 0;
    transform: translateY(-8px);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity .25s ease, transform .25s ease, visibility .25s;
  }

  .mobile-menu.is-open {
    transform: none;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }

  .mobile-menu > a {
    display: flex;
    justify-content: space-between;
    padding: 16px 0;
    border-bottom: 1px solid var(--line);
    text-decoration: none;
    font-family: var(--display);
    font-size: 22px;
  }

  .mobile-menu p {
    color: var(--muted);
    font-size: 9px;
    letter-spacing: .08em;
    margin: 22px 0 0;
  }

  .blog-hero {
    min-height: 570px;
    padding-top: 95px;
    padding-bottom: 80px;
  }

  .blog-hero h1 {
    font-size: clamp(43px, 11vw, 62px);
  }

  .hero-caption {
    left: var(--gutter);
    right: var(--gutter);
    line-height: 1.7;
  }

  .library-intro,
  .masail-heading {
    grid-template-columns: 1fr;
    gap: 25px;
  }

  .library-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .search-box { width: 100%; }

  .article-grid {
    grid-template-columns: 1fr;
    gap: 36px;
  }

  .article-image { min-height: 260px; }
  .article-card > p { min-height: 0; }

  .masail-topic {
    grid-template-columns: 30px 1fr 25px;
    gap: 12px;
  }

  .masail-topic strong { font-size: 21px; }

  .footer-top {
    align-items: flex-start;
    flex-direction: column;
  }

  .footer-bottom {
    flex-wrap: wrap;
    line-height: 1.7;
  }

  .floating-whatsapp {
    right: 14px;
    bottom: 14px;
  }
}
