:root {
  --paper: #f6f1e7;
  --paper-2: #ede5d3;
  --card: #fbf8f1;
  --line: #ded3bc;
  --line-strong: #cbbe9f;
  --ink: #1a1e1c;
  --muted: #565a53;
  --emerald: #0f3d35;
  --emerald-2: #134a41;
  --emerald-3: #0b2e28;
  --gold-soft: #d9c08a;
  --gold-ink: #7e6025;
  --on-dark: #f3eee2;
  --on-dark-muted: #c3ccc6;
  --danger: #9b2c2c;
  --radius: 6px;
  --serif: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --arabic: "Amiri", "Noto Naskh Arabic", "Traditional Arabic", serif;
  --stars: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='80' height='80'%3E%3Cg fill='none' stroke='%23D9C08A' stroke-opacity='.09'%3E%3Crect x='26' y='26' width='28' height='28'/%3E%3Crect x='26' y='26' width='28' height='28' transform='rotate(45 40 40)'/%3E%3Cpath d='M40 0V20M40 60V80M0 40H20M60 40H80'/%3E%3C/g%3E%3C/svg%3E");
}

* { box-sizing: border-box; }
html { scroll-padding-top: 84px; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 16px/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
}
body.locked { overflow: hidden; }
svg { display: block; }
a { color: inherit; }
p { margin: 0; }
button, input { font: inherit; }
[lang="ar"] { font-family: var(--arabic); }
[hidden] { display: none !important; }

.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.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;
}
.skip {
  position: absolute; left: -9999px; top: 12px; z-index: 100;
  background: var(--paper); color: var(--ink); padding: 10px 14px; border-radius: var(--radius);
}
.skip:focus { left: 16px; }
:focus-visible { outline: 2px solid var(--gold-soft); outline-offset: 2px; }
main :focus-visible, .drawer :focus-visible { outline-color: var(--emerald); }
.hero :focus-visible { outline-color: var(--gold-soft); }

.wrap { max-width: 1180px; margin: 0 auto; padding: 0 24px; }
.icon { width: 20px; height: 20px; flex: none; fill: currentColor; }

/* Buttons: one radius everywhere */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 46px; padding: 0 20px; border: 1px solid transparent; border-radius: var(--radius);
  font-weight: 600; font-size: 15px; text-decoration: none; cursor: pointer; white-space: nowrap;
}
.btn-primary { background: var(--emerald); color: var(--on-dark); }
.btn-primary:hover { background: var(--emerald-2); }
.btn-gold { background: var(--gold-soft); color: var(--emerald-3); }
.btn-gold:hover { background: #e5d1a2; }
.btn-ghost { background: transparent; color: var(--on-dark); border-color: rgba(243, 238, 226, 0.4); }
.btn-ghost:hover { border-color: var(--on-dark); }
.btn-block { width: 100%; }
.btn:disabled { opacity: 0.65; cursor: progress; }

.icon-btn {
  width: 40px; height: 40px; display: grid; place-items: center; flex: none;
  background: transparent; color: var(--ink); border: 1px solid var(--line);
  border-radius: var(--radius); cursor: pointer;
}
.icon-btn:hover { border-color: var(--line-strong); }
.icon-btn-dark { color: var(--emerald-3); border-color: rgba(11, 46, 40, 0.25); }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 20;
  background: var(--emerald); color: var(--on-dark);
  border-bottom: 1px solid rgba(217, 192, 138, 0.22);
}
.header-row { display: flex; align-items: center; gap: 32px; height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; margin-right: auto; }
.brand-icon { width: 28px; height: 28px; fill: var(--gold-soft); }
.brand-name { font: 600 27px/1 var(--serif); letter-spacing: 0.01em; }
.brand-ar { font-size: 20px; line-height: 1; color: var(--gold-soft); }
.nav { display: flex; gap: 28px; }
.nav a { color: var(--on-dark-muted); text-decoration: none; font-size: 15px; font-weight: 500; }
.nav a:hover { color: var(--on-dark); }
.cart-btn {
  display: flex; align-items: center; gap: 8px; height: 42px; padding: 0 12px 0 14px;
  background: transparent; color: var(--on-dark); cursor: pointer;
  border: 1px solid rgba(217, 192, 138, 0.45); border-radius: var(--radius);
  font-size: 15px; font-weight: 500;
}
.cart-btn:hover { border-color: var(--gold-soft); }
/* Language switcher: plain text buttons, the current one framed like the basket button */
.lang { display: flex; gap: 2px; }
.lang button {
  height: 32px; min-width: 34px; padding: 0 6px; cursor: pointer;
  background: transparent; color: var(--on-dark-muted);
  border: 1px solid transparent; border-radius: var(--radius);
  font-size: 13px; font-weight: 600; letter-spacing: 0.04em;
}
.lang button:hover { color: var(--on-dark); }
.lang button[aria-pressed="true"] { color: var(--on-dark); border-color: rgba(217, 192, 138, 0.45); }
.count {
  min-width: 24px; height: 24px; padding: 0 6px; display: grid; place-items: center;
  background: var(--gold-soft); color: var(--emerald-3); border-radius: var(--radius);
  font-size: 13px; font-weight: 600;
}

/* After-checkout message */
.notice { background: var(--gold-soft); color: var(--emerald-3); }
.notice-row { display: flex; align-items: center; gap: 12px; padding-top: 10px; padding-bottom: 10px; }
.notice-row p { flex: 1; font-weight: 500; }

/* Hero */
.hero { background: var(--emerald) var(--stars); color: var(--on-dark); }
.hero-grid {
  display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 64px; align-items: center;
  padding-top: 72px; padding-bottom: 88px;
}
.bismillah { font-size: 24px; line-height: 1.6; color: var(--gold-soft); margin-bottom: 18px; text-align: left; }
h1 {
  font: 600 clamp(42px, 5.6vw, 68px)/1.04 var(--serif);
  letter-spacing: -0.01em; margin: 0 0 22px; max-width: 12ch;
}
.lead { font-size: 18px; color: var(--on-dark-muted); max-width: 34em; margin-bottom: 34px; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; }

.hero-art {
  position: relative; margin: 0; width: 100%; max-width: 420px; justify-self: center;
  aspect-ratio: 400 / 480; container-type: inline-size;
}
.arch-svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.arch-content {
  position: absolute; inset: 24% 13% 7%; margin: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 3cqw; text-align: center;
}
.arch-word { font-size: 15cqw; line-height: 1.1; color: var(--gold-soft); }
.arch-rule { width: 14cqw; height: 1px; background: var(--gold-soft); opacity: 0.6; }
.verse-ar { font-size: max(15px, 5.4cqw); line-height: 1.9; }
.verse-en { font: italic 500 max(15px, 4.7cqw)/1.35 var(--serif); }
.verse-ref { font-size: max(12px, 3.2cqw); letter-spacing: 0.06em; color: var(--on-dark-muted); }

/* Sections */
.section { padding: 96px 0; }
.section-head { max-width: 760px; margin-bottom: 40px; }
.eyebrow {
  font-size: 13px; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--gold-ink); margin-bottom: 8px;
}
h2 { font: 600 clamp(32px, 4vw, 46px)/1.1 var(--serif); margin: 0; }

/* Product grid */
.grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
.card {
  display: flex; flex-direction: column; overflow: hidden;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
}
.visual {
  aspect-ratio: 1 / 1; display: grid; place-items: center;
  background: var(--paper-2); border-bottom: 1px solid var(--line);
}
.visual .art { height: 76%; width: auto; }
.visual-give {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px;
  padding: 20px; text-align: center;
  background: var(--emerald) var(--stars); border-bottom-color: var(--emerald);
}
.give-icon { width: 34%; height: auto; aspect-ratio: 1; fill: var(--gold-soft); }
.card-body { display: flex; flex-direction: column; flex: 1; padding: 20px; }
.card-ar { font-size: 18px; line-height: 1.5; color: var(--gold-ink); }
.card h3 { font: 600 25px/1.15 var(--serif); margin: 2px 0 8px; }
.card-text { color: var(--muted); font-size: 15px; margin-bottom: 20px; }
.card-foot { margin-top: auto; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.price { font-size: 19px; font-weight: 600; font-variant-numeric: tabular-nums; }
.card-foot .btn { padding: 0 16px; }

.hadith { font: italic 500 18px/1.35 var(--serif); color: var(--on-dark); max-width: 16em; }
.hadith cite { display: block; font: normal 12px/1.5 var(--sans); letter-spacing: 0.04em; margin-top: 4px; color: var(--gold-soft); }
.give-form { margin-top: auto; }
.presets { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; border: 0; padding: 0; margin: 0 0 10px; min-width: 0; }
.presets button {
  height: 40px; background: var(--paper); color: var(--ink); cursor: pointer;
  border: 1px solid var(--line); border-radius: var(--radius); font-weight: 600; font-size: 15px;
}
.presets button:hover { border-color: var(--line-strong); }
.presets button[aria-pressed="true"] { background: var(--emerald); border-color: var(--emerald); color: var(--on-dark); }
.amount-field {
  display: flex; align-items: center; gap: 6px; height: 44px; padding: 0 12px; margin-bottom: 12px;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
}
.amount-field:focus-within { border-color: var(--emerald); outline: 2px solid var(--emerald); outline-offset: 1px; }
.amount-field .cur { color: var(--muted); font-weight: 600; }
.amount-field input {
  flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; color: var(--ink);
  font-size: 16px; font-weight: 500; -moz-appearance: textfield; appearance: textfield;
}
.amount-field input::-webkit-outer-spin-button,
.amount-field input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.amount-field.invalid { border-color: var(--danger); }
.field-error { color: var(--danger); font-size: 14px; margin: -4px 0 12px; }

/* Promise strip */
.promise { background: var(--paper-2); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.promise-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; padding-top: 48px; padding-bottom: 48px; }
.promise-item { display: flex; gap: 16px; align-items: flex-start; }
.promise-icon { width: 34px; height: 34px; flex: none; fill: var(--emerald); }
.promise-item h3 { font: 600 23px/1.2 var(--serif); margin: 0 0 4px; }
.promise-item p { color: var(--muted); font-size: 15px; }

/* FAQ: styled dropdowns, click to open */
.faq-grid { display: grid; grid-template-columns: 1fr 1.6fr; gap: 48px; align-items: start; }
.faq details {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); margin-bottom: 12px;
}
.faq details[open] { border-color: var(--line-strong); }
.faq summary {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 18px 20px; cursor: pointer; list-style: none; font-weight: 600; font-size: 17px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary .icon { fill: var(--emerald); }
.faq details[open] summary .icon { transform: rotate(180deg); }
.faq details p { padding: 0 20px 20px; color: var(--muted); }

/* Footer */
.site-footer { background: var(--emerald-3) var(--stars); color: var(--on-dark-muted); padding: 40px 0; font-size: 14px; }
.site-footer .brand { color: var(--on-dark); margin-right: 0; }
.footer-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px; }
.footer-nav { display: flex; gap: 24px; }
.footer-nav a { text-decoration: none; }
.footer-nav a:hover { color: var(--on-dark); }

/* Basket drawer (opens on click, no animation) */
.overlay { position: fixed; inset: 0; z-index: 40; background: rgba(11, 46, 40, 0.5); }
.drawer {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 50; width: min(420px, 100%);
  display: flex; flex-direction: column; background: var(--paper);
  box-shadow: -16px 0 48px rgba(11, 46, 40, 0.2);
}
.drawer-head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 14px 20px; border-bottom: 1px solid var(--line);
}
.drawer-head h2 { font-size: 28px; }
.drawer-body { flex: 1; overflow-y: auto; padding: 4px 20px; }
.empty { display: flex; flex-direction: column; align-items: center; gap: 16px; padding: 56px 0; color: var(--muted); text-align: center; }
.lines { list-style: none; margin: 0; padding: 0; }
.line { display: grid; grid-template-columns: 64px 1fr auto; gap: 14px; padding: 16px 0; border-bottom: 1px solid var(--line); }
.line:last-child { border-bottom: 0; }
.line-thumb {
  width: 64px; height: 64px; display: grid; place-items: center; overflow: hidden;
  background: var(--paper-2); border-radius: var(--radius);
}
.line-thumb .art { height: 82%; width: auto; }
.line-thumb.give { background: var(--emerald); }
.line-thumb.give svg { width: 34px; height: 34px; fill: var(--gold-soft); }
.line-name { font-weight: 600; line-height: 1.35; }
.line-unit { color: var(--muted); font-size: 14px; margin: 2px 0 10px; }
.stepper {
  display: inline-flex; align-items: center; height: 36px;
  border: 1px solid var(--line); border-radius: var(--radius); background: var(--card);
}
.stepper button {
  width: 36px; height: 34px; display: grid; place-items: center;
  border: 0; background: transparent; color: var(--ink); cursor: pointer; border-radius: var(--radius);
}
.stepper button:disabled { color: #b5b0a3; cursor: default; }
.stepper .icon { width: 14px; height: 14px; }
.stepper output { min-width: 26px; text-align: center; font-weight: 600; font-size: 14px; }
.line-end { display: flex; flex-direction: column; align-items: flex-end; justify-content: space-between; gap: 8px; }
.line-total { font-weight: 600; font-variant-numeric: tabular-nums; }
.link-btn {
  padding: 0; border: 0; background: none; cursor: pointer;
  color: var(--muted); font-size: 14px; text-decoration: underline; text-underline-offset: 3px;
}
.link-btn:hover { color: var(--ink); }
.drawer-foot { padding: 18px 20px 20px; border-top: 1px solid var(--line); background: var(--card); }
.subtotal { display: flex; align-items: baseline; justify-content: space-between; font-size: 17px; }
.subtotal strong { font-size: 21px; font-variant-numeric: tabular-nums; }
.foot-note { color: var(--muted); font-size: 13px; margin: 2px 0 14px; }
.cart-msg {
  margin-bottom: 12px; padding: 10px 12px; font-size: 14px;
  background: #f3e9d2; border: 1px solid #e2cfa4; border-radius: var(--radius);
}
.secure { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 12px; color: var(--muted); font-size: 13px; }
.secure .icon { width: 16px; height: 16px; }

/* Tablet */
@media (max-width: 1060px) {
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 860px) {
  .nav { display: none; }
  .hero-grid { grid-template-columns: 1fr; gap: 44px; padding-top: 48px; padding-bottom: 64px; }
  .hero-art { max-width: 360px; }
  .section { padding: 72px 0; }
  .promise-grid { grid-template-columns: 1fr; gap: 24px; }
  .faq-grid { grid-template-columns: 1fr; gap: 0; }
}
/* Phone */
@media (max-width: 600px) {
  .wrap { padding-left: 16px; padding-right: 16px; }
  .grid { grid-template-columns: 1fr; }
  .visual { aspect-ratio: 4 / 3; }
  .bismillah { font-size: 21px; }
  .lead { font-size: 17px; }
  .actions .btn { flex: 1 1 auto; }
  .footer-row { flex-direction: column; align-items: flex-start; }
}
/* Narrow phones: make room for the language switcher in the header */
@media (max-width: 600px) {
  .header-row { gap: 12px; }
}
@media (max-width: 480px) {
  .cart-label { display: none; }
}
@media (max-width: 420px) {
  .brand-ar { display: none; }
}
@media (max-width: 350px) {
  .brand-icon { display: none; }
}
