/* ============================================================
   al-Firasah — site stylesheet (hand-editable, no build step)
   Brand: cream paper · emerald signature · one terracotta italic
   ============================================================ */

:root {
  /* surfaces */
  --paper: #faf7f0;
  --ivory: #f4ede0;
  --cream: #ffffff;
  /* ink */
  --ink: #1a1612;
  --ink-soft: #3d362f;
  --muted: #8b7e72;
  --muted-soft: #c4b8a8;
  /* emerald (signature) */
  --emerald: #0a6e54;
  --emerald-soft: #14856b;
  --emerald-deep: #074839;
  --emerald-faint: rgba(10, 110, 84, 0.08);
  /* accent */
  --terracotta: #b8612e;
  /* lines */
  --hairline: rgba(26, 22, 18, 0.08);
  --hairline-strong: rgba(26, 22, 18, 0.14);
  /* category pastels — section signals only */
  --butter: #fce5a4;  --butter-ink: #5d4a0a;
  --mint: #c4e6cf;    --mint-ink: #0d4a2e;
  --sky: #c5dde6;     --sky-ink: #0d3a4a;
  --rose: #f5d4c5;    --rose-ink: #5d2914;

  --shadow-soft: 0 30px 60px -30px rgba(26, 22, 18, 0.18);
  --shadow-card: 0 2px 0 rgba(26, 22, 18, 0.04), 0 12px 28px -12px rgba(26, 22, 18, 0.10);
  --radius-card: 2rem;
  --max-w: 1320px;
}

/* ---------------------------------------------------------- base */

* { box-sizing: border-box; margin: 0; padding: 0; }
html { background: var(--paper); scroll-behavior: smooth; }
body {
  font-family: 'Plus Jakarta Sans', Helvetica, sans-serif;
  background: var(--paper);
  color: var(--ink);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; background: none; border: 0; color: inherit; }

.paper-grain::before {
  content: ''; position: fixed; inset: 0; z-index: 0; pointer-events: none; opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 240 240' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' seed='3'/%3E%3CfeColorMatrix values='0 0 0 0 0.10 0 0 0 0 0.08 0 0 0 0 0.07 0 0 0 0.5 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
body > * { position: relative; z-index: 1; }

/* ---------------------------------------------------------- type roles */

.display {
  font-family: 'Fraunces', serif; font-weight: 500;
  font-optical-sizing: auto; letter-spacing: -0.018em; line-height: 1.05;
}
.display em, .display .accent { font-style: italic; color: var(--terracotta); font-weight: 500; }
.display-italic { font-family: 'Fraunces', serif; font-style: italic; font-weight: 500; letter-spacing: -0.018em; }
.arabic { font-family: 'Amiri', serif; }

.eyebrow {
  display: inline-block; font-size: 11px; font-weight: 700;
  letter-spacing: 0.22em; text-transform: uppercase; color: var(--emerald);
}
.eyebrow.muted { color: var(--muted); }
.eyebrow.center { display: block; text-align: center; }

.masthead-rule {
  display: flex; align-items: center; gap: 1.25rem;
  font-size: 11px; font-weight: 700; letter-spacing: 0.22em;
  text-transform: uppercase; color: var(--ink-soft);
}
.masthead-rule::before, .masthead-rule::after {
  content: ''; flex: 1; height: 1px; background: var(--hairline-strong);
}

.wrap { max-width: var(--max-w); margin: 0 auto; padding: 0 24px; }
@media (min-width: 1024px) { .wrap { padding: 0 40px; } }

/* ---------------------------------------------------------- buttons, inputs */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  border-radius: 999px; padding: 13px 26px; font-size: 15px; font-weight: 600;
  white-space: nowrap; transition: background .18s, color .18s, transform .18s;
}
.btn-ink { background: var(--ink); color: var(--paper); }
.btn-ink:hover { background: var(--emerald-deep); }
.btn-emerald { background: var(--emerald); color: #fff; }
.btn-emerald:hover { background: var(--emerald-soft); }
.btn-ghost { color: var(--ink-soft); border: 1px solid var(--hairline-strong); }
.btn-ghost:hover { border-color: var(--ink); }
.btn-block { width: 100%; }

.icon-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; border-radius: 999px; color: var(--ink);
  transition: background .18s;
}
.icon-btn:hover { background: var(--emerald-faint); }

.input {
  width: 100%; background: var(--cream); border: 1px solid var(--hairline);
  border-radius: 999px; padding: 14px 20px; font-size: 15px; font-family: inherit;
  color: var(--ink); transition: border-color .18s, box-shadow .18s;
}
.input::placeholder { color: var(--muted-soft); }
.input:focus { outline: none; border-color: var(--emerald); box-shadow: 0 0 0 3px var(--emerald-faint); }

.pill {
  display: inline-block; font-size: 10px; font-weight: 700;
  letter-spacing: 0.18em; text-transform: uppercase;
  border-radius: 999px; padding: 6px 12px;
}

/* ---------------------------------------------------------- header */

.site-header {
  position: sticky; top: 0; z-index: 40;
  background: rgba(250, 247, 240, 0.92); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--hairline);
}
.header-inner {
  max-width: var(--max-w); margin: 0 auto; padding: 0 24px;
  display: flex; align-items: center; justify-content: space-between; height: 68px;
}
.header-logo img { height: 44px; width: auto; }
.header-nav { display: none; align-items: center; gap: 6px; }
.header-nav a {
  font-size: 14.5px; font-weight: 500; color: var(--ink-soft);
  padding: 8px 14px; border-radius: 999px; transition: background .18s, color .18s;
}
.header-nav a:hover { color: var(--ink); background: var(--emerald-faint); }
.header-nav a.is-active { background: var(--ink); color: var(--paper); }
.nav-divider { width: 1px; height: 18px; background: var(--hairline-strong); margin: 0 8px; }
.header-actions { display: flex; align-items: center; gap: 8px; }
.header-actions .btn { padding: 10px 20px; font-size: 14px; }
.nav-toggle { display: inline-flex; }

@media (min-width: 900px) {
  .header-nav { display: flex; }
  .nav-toggle { display: none; }
}
/* mobile nav open state */
.site-header.nav-open .header-nav {
  display: flex; position: absolute; top: 68px; left: 0; right: 0;
  flex-direction: column; align-items: stretch; gap: 2px;
  background: var(--paper); border-bottom: 1px solid var(--hairline);
  padding: 12px 24px 18px;
}
.site-header.nav-open .nav-divider { display: none; }

/* ---------------------------------------------------------- home: masthead + hero */

.reading-room { padding-top: 34px; padding-bottom: 10px; }

.hero { padding-top: 28px; padding-bottom: 20px; }
.hero-card {
  position: relative; background: var(--cream); border: 1px solid var(--hairline);
  border-radius: var(--radius-card); box-shadow: var(--shadow-card); overflow: hidden;
}
.hero-slide { display: none; }
.hero-slide.is-active { display: grid; }
.hero-slide { grid-template-columns: 1fr; min-height: 440px; }
@media (min-width: 900px) { .hero-slide { grid-template-columns: 1.15fr 1fr; } }

.hero-text { padding: 44px 36px 96px; display: flex; flex-direction: column; align-items: flex-start; gap: 20px; }
@media (min-width: 1024px) { .hero-text { padding: 60px 56px 110px; } }
.hero-meta { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.hero-meta .readtime { font-size: 11px; font-weight: 700; letter-spacing: 0.18em; text-transform: uppercase; color: var(--muted); }
.hero-title { font-size: clamp(2.4rem, 5.4vw, 4.2rem); }
.hero-excerpt { font-size: 17px; color: var(--ink-soft); max-width: 54ch; }
.hero-cta { display: flex; align-items: center; gap: 16px 22px; margin-top: 6px; flex-wrap: wrap; }
.hero-more { font-size: 14.5px; font-weight: 600; color: var(--ink-soft); }
.hero-more:hover { color: var(--emerald); }

.hero-media { position: relative; min-height: 300px; }
.hero-media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }

.hero-controls {
  position: absolute; left: 36px; bottom: 30px; right: 36px;
  display: flex; align-items: center; gap: 18px;
}
@media (min-width: 1024px) { .hero-controls { left: 56px; } }
.hero-arrow {
  width: 42px; height: 42px; border-radius: 999px; border: 1px solid var(--hairline-strong);
  display: inline-flex; align-items: center; justify-content: center; color: var(--ink);
  background: var(--cream); transition: border-color .18s, background .18s;
}
.hero-arrow:hover { border-color: var(--emerald); background: var(--emerald-faint); }
.hero-dots { display: flex; align-items: center; gap: 7px; }
.hero-dot { width: 7px; height: 7px; border-radius: 999px; background: var(--muted-soft); transition: width .3s, background .3s; }
.hero-dot.is-active { width: 30px; background: var(--emerald); }
.hero-tag {
  margin-left: auto; font-size: 10.5px; font-weight: 700; letter-spacing: 0.2em;
  text-transform: uppercase; color: var(--muted); display: none;
}
@media (min-width: 700px) { .hero-tag { display: block; } }

/* ---------------------------------------------------------- section shells */

.section { padding-top: 72px; padding-bottom: 12px; }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 36px; flex-wrap: wrap; }
.section-title { font-size: clamp(2rem, 4.2vw, 3rem); margin-top: 10px; }
.section-link { font-size: 14.5px; font-weight: 600; color: var(--ink-soft); border-bottom: 1px solid var(--hairline-strong); padding-bottom: 2px; }
.section-link:hover { color: var(--emerald); border-color: var(--emerald); }

/* ---------------------------------------------------------- article cards (cover thumbnails) */

.card-grid { display: grid; gap: 26px; grid-template-columns: 1fr; }
@media (min-width: 680px)  { .card-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .card-grid { grid-template-columns: repeat(3, 1fr); } }

.post-card {
  display: flex; flex-direction: column; background: var(--cream);
  border: 1px solid var(--hairline); border-radius: var(--radius-card);
  overflow: hidden; box-shadow: var(--shadow-card);
  transition: transform .25s ease, box-shadow .25s ease;
}
.post-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-soft); }

.post-card-media { position: relative; aspect-ratio: 4 / 3; overflow: hidden; background: var(--ivory); }
.post-card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.post-card:hover .post-card-media img { transform: scale(1.04); }
.post-card-media .pill { position: absolute; top: 14px; left: 14px; box-shadow: 0 4px 14px -6px rgba(26,22,18,.35); }

.post-card-body { padding: 22px 24px 26px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.post-card-meta { display: flex; align-items: center; gap: 10px; font-size: 11.5px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.post-card-meta .dot { width: 3px; height: 3px; border-radius: 99px; background: var(--muted-soft); }
.post-card-title { font-size: 24px; line-height: 1.15; }
.post-card:hover .post-card-title { color: var(--emerald-deep); }
.post-card-excerpt {
  font-size: 14.5px; color: var(--ink-soft);
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.post-card-read { margin-top: auto; padding-top: 8px; font-size: 13.5px; font-weight: 600; color: var(--emerald); }

/* ---------------------------------------------------------- sections bento */

.bento { display: grid; gap: 22px; grid-template-columns: 1fr; }
@media (min-width: 680px) { .bento { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .bento { grid-template-columns: repeat(4, 1fr); } }

.bento-tile {
  border-radius: var(--radius-card); padding: 28px 26px 24px; min-height: 210px;
  display: flex; flex-direction: column; position: relative;
  transition: transform .25s ease;
}
.bento-tile:hover { transform: translateY(-4px); }
.bento-no { font-size: 10.5px; font-weight: 700; letter-spacing: .2em; opacity: .75; }
.bento-name { font-size: 30px; margin-top: 10px; }
.bento-desc { font-size: 14px; margin-top: 8px; opacity: .85; }
.bento-count { margin-top: auto; padding-top: 18px; font-size: 11px; font-weight: 700; letter-spacing: .18em; text-transform: uppercase; }
.bento-arrow { position: absolute; top: 24px; right: 24px; opacity: .7; }

/* ---------------------------------------------------------- purpose (the mark) */

.purpose { background: var(--ivory); border-radius: var(--radius-card); position: relative; overflow: hidden; padding: 64px 36px; }
@media (min-width: 1024px) { .purpose { padding: 84px 72px; } }
.purpose-f {
  position: absolute; right: -30px; bottom: -90px; font-family: 'Fraunces', serif; font-style: italic;
  font-size: 380px; line-height: 1; color: var(--emerald); opacity: .07; pointer-events: none;
}
.purpose-lead { font-size: clamp(1.6rem, 3vw, 2.3rem); line-height: 1.3; max-width: 30ch; margin-top: 18px; }
.purpose-values { display: grid; gap: 26px; grid-template-columns: 1fr; margin-top: 44px; max-width: 860px; }
@media (min-width: 800px) { .purpose-values { grid-template-columns: repeat(3, 1fr); } }
.purpose-value h4 { font-size: 12px; font-weight: 700; letter-spacing: .2em; text-transform: uppercase; color: var(--emerald); margin-bottom: 8px; }
.purpose-value p { font-size: 14.5px; color: var(--ink-soft); }
.purpose-cta { display: flex; align-items: center; gap: 22px; margin-top: 42px; flex-wrap: wrap; }
.purpose-masirah { font-size: 14.5px; font-weight: 600; color: var(--ink-soft); }
.purpose-masirah:hover { color: var(--emerald); }

/* ---------------------------------------------------------- guide + dispatch panels */

.panel {
  border-radius: var(--radius-card); padding: 56px 36px; position: relative; overflow: hidden;
}
@media (min-width: 1024px) { .panel { padding: 72px 64px; } }
.panel-emerald { background: var(--emerald-deep); color: #f2ede2; }
.panel-emerald .eyebrow { color: #9fd3c2; }
.panel-emerald .display em { color: #e8a877; }
.panel-cream { background: var(--cream); border: 1px solid var(--hairline); box-shadow: var(--shadow-card); }
.panel-title { font-size: clamp(1.9rem, 3.6vw, 2.8rem); max-width: 22ch; }
.panel-lead { font-size: 16px; max-width: 52ch; margin-top: 16px; opacity: .92; }
.panel-cta { margin-top: 28px; display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.panel-note { font-size: 12px; letter-spacing: .14em; text-transform: uppercase; opacity: .65; font-weight: 600; }
.panel-f {
  position: absolute; right: 20px; top: -40px; font-family: 'Fraunces', serif; font-style: italic;
  font-size: 240px; line-height: 1; opacity: .08; pointer-events: none;
}

/* ---------------------------------------------------------- category page */

.cat-hero { padding: 64px 0 56px; }
.cat-hero-inner { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 28px; }
.cat-hero .display { font-size: clamp(3.4rem, 9vw, 6.5rem); }
.cat-hero-side { max-width: 320px; padding-bottom: 12px; }
.cat-hero-side p { font-size: 15.5px; }
.cat-hero-count { font-size: 11px; font-weight: 700; letter-spacing: .2em; text-transform: uppercase; margin-top: 10px; opacity: .7; }

.empty-note {
  border: 1px dashed var(--hairline-strong); border-radius: var(--radius-card);
  padding: 48px 32px; text-align: center; color: var(--muted); font-size: 15px;
}

/* ---------------------------------------------------------- article page */

.article-kicker { padding-top: 40px; }
.article-head { text-align: center; max-width: 780px; margin: 0 auto; padding: 26px 24px 0; }
.article-head .hero-meta { justify-content: center; }
.article-title { font-size: clamp(2.6rem, 6vw, 4.4rem); margin: 22px 0 20px; }
.article-excerpt { font-size: 18px; color: var(--ink-soft); max-width: 60ch; margin: 0 auto; }
.article-byline { display: flex; align-items: center; justify-content: center; gap: 12px; margin-top: 26px; font-size: 11.5px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.article-byline img { width: 26px; height: 26px; border-radius: 999px; object-fit: cover; }

.article-cover { max-width: 1000px; margin: 44px auto 0; padding: 0 24px; }
.article-cover img { border-radius: var(--radius-card); box-shadow: var(--shadow-soft); width: 100%; }

.article-video { max-width: 1000px; margin: 44px auto 0; padding: 0 24px; }
.article-video .video-frame { position: relative; padding-top: 56.25%; border-radius: var(--radius-card); overflow: hidden; box-shadow: var(--shadow-soft); }
.article-video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

.prose { max-width: 680px; margin: 0 auto; padding: 56px 24px 24px; }
.prose p { font-size: 17px; line-height: 1.85; color: var(--ink-soft); margin-bottom: 26px; }
.prose h2 {
  font-family: 'Fraunces', serif; font-weight: 500; letter-spacing: -0.016em;
  font-size: 30px; color: var(--ink); margin: 44px 0 18px;
}
.prose h3 { font-family: 'Fraunces', serif; font-weight: 500; font-size: 23px; color: var(--ink); margin: 36px 0 14px; }
.prose blockquote {
  border-left: 3px solid var(--emerald); background: var(--emerald-faint);
  border-radius: 0 18px 18px 0; padding: 22px 28px; margin: 30px 0;
}
.prose blockquote p { font-family: 'Fraunces', serif; font-size: 19px; font-style: italic; color: var(--ink); margin: 0; line-height: 1.7; }
.prose ul, .prose ol { margin: 0 0 26px 22px; }
.prose li { font-size: 16.5px; line-height: 1.8; color: var(--ink-soft); margin-bottom: 8px; }
.prose a { color: var(--emerald); border-bottom: 1px solid rgba(10,110,84,.3); }
.prose a:hover { border-color: var(--emerald); }
.prose code { background: var(--ivory); border-radius: 6px; padding: 2px 7px; font-size: 15px; }

.author-box {
  max-width: 680px; margin: 40px auto 0; padding: 0 24px;
}
.author-box-inner {
  border-top: 1px solid var(--hairline-strong); padding-top: 36px;
  display: flex; gap: 20px; align-items: flex-start;
}
.author-box img { width: 64px; height: 64px; border-radius: 999px; object-fit: cover; flex-shrink: 0; }
.author-box .eyebrow { margin-bottom: 6px; }
.author-name { font-size: 21px; }
.author-role { font-size: 11px; font-weight: 700; letter-spacing: .18em; text-transform: uppercase; color: var(--muted); margin: 2px 0 10px; }
.author-bio { font-size: 14.5px; color: var(--ink-soft); }
.author-links { display: flex; gap: 14px; margin-top: 12px; }
.author-links a { font-size: 13px; font-weight: 600; color: var(--emerald); }

.article-back { text-align: center; padding: 48px 0 0; }

/* ---------------------------------------------------------- static pages */

.page-head { max-width: 720px; margin: 0 auto; text-align: center; padding: 72px 24px 0; }
.page-title { font-size: clamp(2.6rem, 6vw, 4rem); margin-top: 16px; }
.page-lead { font-size: 17.5px; color: var(--ink-soft); margin-top: 20px; }
.page-body { max-width: 680px; margin: 0 auto; padding: 40px 24px 0; }
.page-body h2 { font-family: 'Fraunces', serif; font-weight: 500; font-size: 26px; margin: 40px 0 14px; }
.page-body p, .page-body li { font-size: 16px; line-height: 1.8; color: var(--ink-soft); }
.page-body p { margin-bottom: 20px; }
.page-body ul { margin: 0 0 20px 22px; }
.page-body a { color: var(--emerald); }
.page-updated { font-size: 12px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); margin-top: 14px; }

.contact-card {
  max-width: 560px; margin: 48px auto 0; text-align: center;
  background: var(--cream); border: 1px solid var(--hairline); border-radius: var(--radius-card);
  box-shadow: var(--shadow-card); padding: 48px 36px;
}
.contact-card a.email { font-family: 'Fraunces', serif; font-size: 26px; color: var(--emerald); }

/* ---------------------------------------------------------- guide page */

.guide-grid { display: grid; gap: 48px; grid-template-columns: 1fr; padding-top: 64px; align-items: start; }
@media (min-width: 1000px) { .guide-grid { grid-template-columns: 1.05fr 1fr; gap: 72px; } }
.guide-title { font-size: clamp(2.6rem, 5.5vw, 4rem); margin: 16px 0 20px; }
.guide-lead { font-size: 17px; color: var(--ink-soft); max-width: 46ch; }
.guide-list { list-style: none; margin-top: 36px; }
.guide-list li { position: relative; padding: 12px 0 12px 30px; font-size: 15.5px; color: var(--ink-soft); border-bottom: 1px solid var(--hairline); }
.guide-list li:last-child { border-bottom: 0; }
.guide-list li::before { content: ''; position: absolute; left: 2px; top: 21px; width: 7px; height: 7px; border-radius: 999px; background: var(--emerald); }

.form-card {
  background: var(--cream); border: 1px solid var(--hairline); border-radius: 28px;
  padding: 40px 34px; box-shadow: var(--shadow-soft);
}
.form-card h2 { font-family: 'Fraunces', serif; font-weight: 500; font-size: 25px; text-align: center; margin: 8px 0 24px; letter-spacing: -0.02em; }
.form-card form { display: flex; flex-direction: column; gap: 14px; }
.form-foot { text-align: center; font-size: 12px; color: var(--muted); margin-top: 16px; }
.captcha-slot { display: flex; justify-content: center; min-height: 78px; }

/* ---------------------------------------------------------- footer */

.site-footer { margin-top: 96px; background: var(--ivory); border-top: 1px solid var(--hairline); }
.footer-inner { max-width: var(--max-w); margin: 0 auto; padding: 64px 24px 40px; }
@media (min-width: 1024px) { .footer-inner { padding: 72px 40px 44px; } }
.footer-grid { display: grid; gap: 40px; grid-template-columns: 1fr; }
@media (min-width: 800px) { .footer-grid { grid-template-columns: 2fr 1fr 1fr 1fr; gap: 32px; } }
.footer-headline { font-size: clamp(1.9rem, 3.4vw, 2.6rem); margin-bottom: 14px; }
.footer-brand p { font-size: 14.5px; color: var(--ink-soft); max-width: 40ch; margin-bottom: 22px; }
.footer-col { display: flex; flex-direction: column; gap: 10px; }
.footer-col .eyebrow { margin-bottom: 6px; }
.footer-col a { font-size: 14.5px; color: var(--ink-soft); }
.footer-col a:hover { color: var(--emerald); }
.footer-bottom {
  display: flex; flex-wrap: wrap; align-items: center; gap: 16px 28px;
  border-top: 1px solid var(--hairline-strong); margin-top: 52px; padding-top: 26px;
  font-size: 13px; color: var(--muted);
}
.footer-legal { display: flex; gap: 18px; }
.footer-legal a:hover { color: var(--emerald); }
.footer-arabic { color: var(--emerald); font-size: 18px; margin-left: auto; }
.footer-issue { font-size: 11px; font-weight: 700; letter-spacing: .18em; text-transform: uppercase; }

/* ---------------------------------------------------------- modals */

.modal { position: fixed; inset: 0; z-index: 60; display: flex; align-items: center; justify-content: center; padding: 24px; }
.modal[hidden] { display: none; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(26, 22, 18, 0.45); backdrop-filter: blur(3px); }
.modal-card {
  position: relative; background: var(--cream); border-radius: 28px;
  box-shadow: var(--shadow-soft); width: 100%; max-width: 440px;
  padding: 44px 36px 30px; max-height: 90vh; overflow-y: auto;
}
.modal-card-wide { max-width: 620px; }
.modal-close {
  position: absolute; top: 16px; right: 20px; font-size: 26px; line-height: 1;
  color: var(--muted); transition: color .18s;
}
.modal-close:hover { color: var(--ink); }
.modal-icon {
  width: 46px; height: 46px; border-radius: 14px; background: var(--emerald-faint);
  color: var(--emerald); display: flex; align-items: center; justify-content: center;
  margin: 0 auto 16px;
}
.modal-title { text-align: center; font-size: 32px; margin: 10px 0 12px; }
.modal-lead { text-align: center; font-size: 14.5px; color: var(--ink-soft); margin-bottom: 26px; }
.modal-card form { display: flex; flex-direction: column; gap: 13px; }
.modal-foot { text-align: center; font-size: 12px; color: var(--muted); margin-top: 16px; }
.modal-success { text-align: center; padding: 18px 0 8px; }
.modal-success .display { font-size: 26px; margin-bottom: 10px; }
.modal-success p:last-child { font-size: 14.5px; color: var(--ink-soft); }

.search-input { margin: 18px 0 8px; }
.search-results { display: flex; flex-direction: column; }
.search-result { display: flex; align-items: center; gap: 16px; padding: 14px 6px; border-bottom: 1px solid var(--hairline); border-radius: 10px; }
.search-result:hover { background: var(--emerald-faint); }
.search-result img { width: 64px; height: 44px; object-fit: cover; border-radius: 10px; flex-shrink: 0; }
.search-result-title { font-size: 15.5px; font-weight: 600; }
.search-result-meta { font-size: 11px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.search-empty { text-align: center; color: var(--muted); font-size: 14px; padding: 22px 0 10px; }

/* ---------------------------------------------------------- consent banner */

.consent {
  position: fixed; z-index: 70; left: 50%; transform: translateX(-50%); bottom: 24px;
  width: min(720px, calc(100vw - 32px));
  background: var(--ink); color: var(--paper); border-radius: 22px;
  padding: 18px 22px; display: flex; align-items: center; gap: 18px;
  box-shadow: var(--shadow-soft);
}
.consent[hidden] { display: none; }
.consent p { font-size: 13.5px; flex: 1; opacity: .92; }
.consent a { color: #9fd3c2; text-decoration: underline; }
.consent-actions { display: flex; gap: 10px; flex-shrink: 0; }
.consent .btn { padding: 10px 18px; font-size: 13.5px; }
.consent .btn-ghost { color: var(--paper); border-color: rgba(250,247,240,.3); }
.consent .btn-ink { background: var(--paper); color: var(--ink); }
@media (max-width: 640px) { .consent { flex-direction: column; align-items: stretch; text-align: center; } }

/* ---------------------------------------------------------- misc */

.center { text-align: center; }
.mt-2 { margin-top: 16px; }
.section-pad-bottom { padding-bottom: 96px; }
