/* ========================================================
   Echoes of Faith — shared stylesheet (LTR + RTL)
   Uses logical properties so Arabic (dir="rtl") mirrors itself.
   ======================================================== */

:root {
  --maroon: #7a3218;
  --maroon-dark: #55220f;
  --flame: #e4772e;
  --gold: #d9973b;
  --gold-deep: #b87a25;
  --gold-light: #f8e7c9;
  --cream: #fbf3e7;
  --ink: #2a2320;
  --ink-soft: #5c534c;
  --line: #e6ddc9;
  --white: #ffffff;
  --max: 1120px;
  --radius: 10px;
  --shadow: 0 10px 30px rgba(74, 18, 32, 0.08);
  --font-body: "Georgia", "Iowan Old Style", "Palatino Linotype", serif;
  --font-ui: "Segoe UI", system-ui, -apple-system, sans-serif;
  --font-head: "Trajan Pro", "Cinzel", "Georgia", serif;
  font-size: 16px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font-body);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

/* Arabic: system Arabic-capable fonts, no letter-spacing (it breaks joining) */
html[lang="ar"] {
  --font-body: "Segoe UI", Tahoma, "Noto Naskh Arabic", "Traditional Arabic", serif;
  --font-ui: "Segoe UI", Tahoma, "Noto Sans Arabic", sans-serif;
  --font-head: "Segoe UI", Tahoma, "Noto Naskh Arabic", "Traditional Arabic", serif;
}
html[lang="ar"] body { line-height: 1.9; }
html[lang="ar"] * { letter-spacing: 0 !important; }
html[lang="ar"] h1, html[lang="ar"] h2, html[lang="ar"] h3 { font-weight: 700; }

h1, h2, h3, h4 {
  font-family: var(--font-head);
  letter-spacing: 0.02em;
  color: var(--maroon-dark);
  line-height: 1.3;
}

p { color: var(--ink-soft); }
a { color: var(--maroon); text-decoration: none; }
a:hover { color: var(--gold-deep); }
img { max-width: 100%; display: block; }

.container { max-width: var(--max); margin: 0 auto; padding: 0 24px; }

.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-link {
  position: absolute; inset-inline-start: 12px; top: -60px; z-index: 100;
  background: var(--maroon); color: var(--white); padding: 10px 16px;
  border-radius: 0 0 8px 8px; font-family: var(--font-ui); font-size: 0.9rem;
}
.skip-link:focus { top: 0; color: var(--white); }

:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }

/* ---------- Language flags ---------- */
.topbar { background: var(--gold-light); border-bottom: 1px solid var(--line); }
.topbar .container { display: flex; justify-content: flex-end; padding-block: 5px; }
.flag-links { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 6px; list-style: none; margin: 0; padding: 0; }
.flag-link {
  display: inline-flex; align-items: center; gap: 8px; padding-block: 4px; padding-inline: 5px 12px;
  border-radius: 999px; border: 1px solid transparent; font-family: var(--font-ui);
  font-size: 0.85rem; font-weight: 600; color: var(--maroon-dark); line-height: 1;
}
.flag-link img { width: 26px; height: 26px; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 1px rgba(60, 25, 10, 0.22); flex-shrink: 0; }
.flag-link:hover { background: var(--white); color: var(--maroon-dark); }
.flag-link[aria-current="true"] { background: var(--white); border-color: var(--gold); }

/* ---------- Header ---------- */
header.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(251, 243, 231, 0.94);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--line);
}

.nav-inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: 18px; padding: 10px 24px; max-width: var(--max); margin: 0 auto;
}

.brand { display: flex; align-items: center; flex-shrink: 0; }
.brand .logo-img {
  height: 54px; width: 54px; border-radius: 8px; object-fit: contain; background: var(--white);
}

nav.main-nav ul {
  list-style: none; display: flex; gap: 22px; margin: 0; padding: 0; flex-wrap: wrap;
}
nav.main-nav a {
  font-family: var(--font-ui); font-size: 0.92rem; color: var(--ink); font-weight: 600;
  padding-bottom: 4px; border-bottom: 2px solid transparent; white-space: nowrap;
}
nav.main-nav a.active, nav.main-nav a:hover { color: var(--maroon); border-bottom-color: var(--gold); }

.header-tools { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }

.cart-btn {
  display: inline-flex; align-items: center; gap: 6px; cursor: pointer;
  padding: 8px 12px; border: 1px solid var(--line); border-radius: 999px;
  background: var(--white); color: var(--maroon-dark); font-family: var(--font-ui);
  font-size: 0.88rem; font-weight: 600;
}
.cart-btn[hidden] { display: none; }
.cart-btn svg { width: 18px; height: 18px; }

.nav-toggle {
  display: none; background: none; border: none; font-size: 1.6rem; line-height: 1;
  color: var(--maroon-dark); cursor: pointer; padding: 4px 6px;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-block; font-family: var(--font-ui); font-weight: 600; font-size: 0.95rem;
  padding: 13px 26px; border-radius: 999px; border: 2px solid var(--maroon);
  background: var(--maroon); color: var(--white); cursor: pointer; text-align: center;
  line-height: 1.35; transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}
.btn:hover { background: var(--maroon-dark); color: var(--white); transform: translateY(-1px); box-shadow: var(--shadow); }
.btn.outline { background: transparent; color: var(--maroon); }
.btn.outline:hover { background: var(--maroon); color: var(--white); }
.btn.small { padding: 9px 18px; font-size: 0.88rem; }
.btn.block { display: block; width: 100%; }
.btn.disabled, .btn[aria-disabled="true"] {
  background: transparent; color: var(--ink-soft); border-color: var(--line);
  border-style: dashed; cursor: default; box-shadow: none; transform: none;
}

/* ---------- Hero ---------- */
.hero {
  padding: 64px 0 56px; text-align: center;
  background: radial-gradient(circle at 50% 0%, var(--gold-light) 0%, transparent 60%), var(--cream);
}
.hero-logo {
  width: 96px; height: 96px; margin: 0 auto 20px; border-radius: 16px;
  background: var(--white); box-shadow: var(--shadow); object-fit: contain;
}
.eyebrow {
  font-family: var(--font-ui); text-transform: uppercase; letter-spacing: 0.18em;
  font-size: 0.78rem; color: var(--gold-deep); font-weight: 700; margin-bottom: 14px;
}
.hero h1 { font-size: clamp(2rem, 4.6vw, 3.1rem); margin: 0 0 18px; }
.hero p.lead { max-width: 720px; margin: 0 auto 30px; font-size: 1.1rem; }
.hero-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

.page-hero { padding: 56px 0 36px; }
.page-hero h1 { font-size: clamp(1.9rem, 4vw, 2.7rem); margin: 0 0 12px; }
.page-hero p.lead { margin-bottom: 0; }

/* ---------- Sections ---------- */
section { padding: 64px 0; }
.section-head { text-align: center; max-width: 680px; margin: 0 auto 40px; }
.section-head h2 { font-size: clamp(1.6rem, 3.2vw, 2.2rem); margin: 0 0 12px; }
.divider { width: 64px; height: 3px; background: var(--gold); margin: 0 auto 18px; border-radius: 2px; }

/* ---------- Cards ---------- */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.card {
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 30px 26px; text-align: center; transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.card .icon {
  width: 52px; height: 52px; margin: 0 auto 16px; border-radius: 50%; background: var(--gold-light);
  display: flex; align-items: center; justify-content: center; color: var(--maroon);
}
.card .icon svg { width: 26px; height: 26px; }
.card h3 { font-size: 1.1rem; margin: 0 0 8px; }
.card p { font-size: 0.95rem; margin: 0; }

/* ---------- Showcase banner ---------- */
.showcase-wrap { padding: 8px 0 24px; }
.showcase {
  position: relative; max-width: 860px; margin: 0 auto; height: clamp(220px, 30vw, 380px);
  overflow: hidden; border-radius: var(--radius); box-shadow: var(--shadow);
}
.showcase img { width: 100%; height: 100%; object-fit: cover; object-position: center 30%; }
.showcase::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(0deg, rgba(30,12,6,0.9) 0%, rgba(30,12,6,0.62) 30%, rgba(30,12,6,0.12) 58%, transparent 72%);
}
.showcase-caption {
  position: absolute; inset-inline: 0; bottom: 0; z-index: 1; padding: 24px 24px 30px;
  text-align: center; color: var(--white);
}
.showcase-caption .eyebrow { color: var(--gold); margin-bottom: 8px; }
.showcase-caption h2 {
  color: var(--white); font-size: clamp(1.4rem, 3.4vw, 2.2rem); margin: 0;
  text-shadow: 0 2px 12px rgba(0,0,0,0.4);
}

/* ---------- Books ---------- */
.lang-tabs { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin: 0 0 36px; }
.lang-tabs a {
  font-family: var(--font-ui); font-size: 0.92rem; font-weight: 600; padding: 9px 20px;
  border-radius: 999px; border: 1px solid var(--line); background: var(--white); color: var(--maroon-dark);
}
.lang-tabs a:hover { border-color: var(--gold); }
.lang-tabs a[aria-current="true"] { background: var(--maroon); border-color: var(--maroon); color: var(--white); }

.book-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 260px)); gap: 26px;
  justify-content: center;
}
.book-card {
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; display: flex; flex-direction: column; transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.book-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.book-cover {
  display: block; background: var(--gold-light); padding: 22px 22px 14px; text-align: center;
}
.book-cover img {
  width: 100%; max-width: 170px; margin: 0 auto; border-radius: 4px;
  box-shadow: 0 8px 22px rgba(60, 25, 10, 0.28);
}
.book-info { padding: 18px 20px 22px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.book-lang {
  font-family: var(--font-ui); font-size: 0.75rem; font-weight: 700; color: var(--gold-deep);
  text-transform: uppercase; letter-spacing: 0.1em;
}
.book-info h3 { font-size: 1.1rem; margin: 0; }
.book-info h3 a { color: inherit; }
.book-sub { margin: 0; font-size: 0.92rem; }
.book-info .btn { margin-top: auto; align-self: flex-start; }
.empty-note {
  text-align: center; max-width: 520px; margin: 0 auto; padding: 28px;
  background: var(--white); border: 1px dashed var(--line); border-radius: var(--radius);
}

/* Book detail */
.book-detail { display: grid; grid-template-columns: minmax(220px, 320px) 1fr; gap: 48px; align-items: start; }
.book-detail .cover-wrap { background: var(--gold-light); border-radius: var(--radius); padding: 30px; box-shadow: var(--shadow); }
.book-detail .cover-wrap img { border-radius: 4px; box-shadow: 0 12px 30px rgba(60,25,10,0.32); margin: 0 auto; }
.book-detail h1 { font-size: clamp(1.8rem, 3.6vw, 2.5rem); margin: 0 0 4px; }
.book-detail .subtitle { font-size: 1.15rem; color: var(--gold-deep); margin: 0 0 18px; font-style: italic; }
.book-facts {
  display: grid; grid-template-columns: max-content 1fr; gap: 8px 22px; margin: 22px 0;
  padding: 18px 22px; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius);
  font-family: var(--font-ui); font-size: 0.93rem;
}
.book-facts dt { color: var(--ink-soft); font-weight: 600; }
.book-facts dd { margin: 0; color: var(--ink); }

.order-box { margin-top: 30px; padding: 26px; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); }
.order-box h2 { font-size: 1.3rem; margin: 0 0 6px; }
.order-box > p { margin: 0 0 18px; font-size: 0.95rem; }
.order-options { display: grid; grid-template-columns: 1fr; gap: 14px; }
.order-opt { border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; background: var(--cream); display: flex; flex-direction: column; gap: 10px; }
.order-opt h3 { font-size: 1rem; margin: 0; }
.order-opt p { font-size: 0.85rem; margin: 0; line-height: 1.5; }
.order-opt .btn { font-size: 0.85rem; padding: 10px 14px; }
.ship-note { margin: 18px 0 0; font-size: 0.88rem; font-family: var(--font-ui); }
.related { margin-top: 36px; }
.related h2 { font-size: 1.15rem; }
.related-list { display: flex; flex-wrap: wrap; gap: 12px; }
.related-list a {
  display: flex; align-items: center; gap: 10px; padding: 8px 14px 8px 8px; background: var(--white);
  border: 1px solid var(--line); border-radius: 999px; font-family: var(--font-ui); font-size: 0.88rem; font-weight: 600;
}
.related-list img { width: 30px; height: 42px; object-fit: cover; border-radius: 3px; }
.back-link { display: inline-block; margin-bottom: 22px; font-family: var(--font-ui); font-size: 0.9rem; font-weight: 600; }

/* Shopify Buy Button mount */
.shopify-product { min-height: 20px; }


/* ---------- Video (Instagram reel) next to the books ---------- */
.books-layout { display: grid; grid-template-columns: 1fr 380px; gap: 44px; align-items: start; }
.reel-aside { text-align: center; }
.reel-title { font-size: 1.25rem; margin: 0 0 14px; }
.reel-frame {
  width: 100%; max-width: 380px; margin: 0 auto; background: var(--white);
  border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden;
}
.reel-frame iframe { display: block; width: 100%; height: 680px; border: 0; }
.reel-video { position: relative; background: #000; }
.reel-video video { display: block; width: 100%; max-height: 680px; background: #000; }
.sound-btn {
  position: absolute; top: 12px; inset-inline-end: 12px; z-index: 2; display: inline-flex; align-items: center;
  gap: 6px; padding: 8px 14px; border: 0; border-radius: 999px; cursor: pointer;
  background: rgba(30, 12, 6, 0.78); color: var(--white); font-family: var(--font-ui);
  font-size: 0.85rem; font-weight: 600; backdrop-filter: blur(4px);
}
.sound-btn[hidden] { display: none; }
.sound-btn:hover { background: var(--maroon); }
.sound-btn svg { width: 18px; height: 18px; }
.reel-link { margin: 12px 0 0; font-family: var(--font-ui); font-size: 0.9rem; font-weight: 600; }

/* ---------- How to order ---------- */
.steps { display: grid; grid-template-columns: repeat(5, 1fr); gap: 14px; counter-reset: step; margin: 0; padding: 0; list-style: none; }
.steps li {
  counter-increment: step; background: var(--white); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 18px 12px; text-align: center; font-family: var(--font-ui);
  font-size: 0.9rem; font-weight: 600; color: var(--maroon-dark);
}
.steps li::before {
  content: counter(step); display: flex; align-items: center; justify-content: center;
  width: 34px; height: 34px; margin: 0 auto 10px; border-radius: 50%;
  background: var(--gold-light); color: var(--maroon); font-weight: 700;
}
.order-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.order-card {
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 30px 26px; display: flex; flex-direction: column; gap: 14px; text-align: center;
}
.order-card h2 { font-size: 1.3rem; margin: 0; }
.order-card p { margin: 0; font-size: 0.95rem; flex: 1; }

/* ---------- About ---------- */
.mission-block { max-width: 780px; margin: 0 auto; }
.mission-block h2 { margin: 34px 0 8px; font-size: 1.35rem; }
.mission-block p { margin: 0; font-size: 1.05rem; }
.page-banner {
  width: 100%; max-width: 620px; max-height: 400px; object-fit: cover; border-radius: var(--radius);
  box-shadow: var(--shadow); margin: 0 auto 36px; display: block;
}
.chip-row { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
.chip-row a {
  font-family: var(--font-ui); font-size: 0.88rem; font-weight: 600; padding: 8px 16px;
  border: 1px solid var(--line); border-radius: 999px; background: var(--white);
}

/* ---------- Contact ---------- */
.contact-grid { display: grid; grid-template-columns: 1.3fr 1fr; gap: 48px; align-items: start; }
.contact-form { display: grid; gap: 16px; }
.contact-form label { display: grid; gap: 6px; font-family: var(--font-ui); font-size: 0.9rem; font-weight: 600; color: var(--maroon-dark); }
.contact-form input, .contact-form textarea {
  width: 100%; padding: 12px 14px; border: 1px solid var(--line); border-radius: 8px;
  font: inherit; font-family: var(--font-ui); font-size: 0.95rem; background: var(--white); color: var(--ink);
}
.contact-form textarea { min-height: 150px; resize: vertical; }
.form-status { font-family: var(--font-ui); font-size: 0.92rem; min-height: 1.4em; margin: 0; }
.form-status.ok { color: #2f6b34; }
.form-status.err { color: #a12a1c; }
.contact-details { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; }
.contact-details h2 { font-size: 1.15rem; margin: 0 0 14px; }
.contact-details dl { margin: 0; display: grid; gap: 12px; font-family: var(--font-ui); font-size: 0.95rem; }
.contact-details dt { font-weight: 700; color: var(--ink-soft); font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.08em; }
.contact-details dd { margin: 2px 0 0; word-break: break-word; }

/* ---------- Policies ---------- */
.policy-nav { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 30px; }
.policy-nav a { font-family: var(--font-ui); font-size: 0.88rem; font-weight: 600; padding: 8px 16px; border: 1px solid var(--line); border-radius: 999px; background: var(--white); }
.policy { scroll-margin-top: 90px; padding: 6px 0 18px; }
.policy h2 { font-size: 1.35rem; margin: 22px 0 8px; }
.policy p { margin: 0; }

/* ---------- News ---------- */
.event-card {
  display: flex; gap: 20px; background: var(--white); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 22px; margin-bottom: 18px; align-items: flex-start;
}
.event-date { flex-shrink: 0; width: 72px; text-align: center; background: var(--gold-light); border-radius: 8px; padding: 10px 6px; font-family: var(--font-ui); }
.event-date .day { display: block; font-size: 1.5rem; font-weight: 700; color: var(--maroon); line-height: 1; }
.event-date .month { display: block; font-size: 0.72rem; text-transform: uppercase; color: var(--maroon-dark); margin-top: 4px; }
.event-card h3 { margin: 0 0 6px; font-size: 1.1rem; }
.event-card p { margin: 0; font-size: 0.95rem; }
.news-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 26px; }
.news-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.news-card img { width: 100%; height: 190px; object-fit: cover; }
.news-card .body { padding: 22px; }
.date-tag { font-family: var(--font-ui); font-size: 0.78rem; color: var(--gold-deep); font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 8px; }
.news-card h3 { font-size: 1.1rem; margin: 0 0 8px; }
.news-card p { font-size: 0.93rem; margin: 0 0 12px; }
.read-more { font-family: var(--font-ui); font-size: 0.88rem; font-weight: 700; }
.news-heading { text-align: start; margin: 0 0 24px; }
.news-heading h2 { font-size: 1.45rem; margin: 0 0 10px; }
.news-heading .divider { margin-inline-start: 0; }

/* ---------- CTA band ---------- */
.cta-band { background: var(--maroon); text-align: center; padding: 56px 0; }
.cta-band h2 { color: var(--white); margin: 0 0 12px; }
.cta-band p { color: var(--gold-light); margin: 0 0 26px; }
.cta-band .btn { background: var(--gold); border-color: var(--gold); color: var(--maroon-dark); }
.cta-band .btn:hover { background: var(--white); border-color: var(--white); }

/* ---------- Footer ---------- */
footer.site-footer { background: var(--maroon-dark); color: var(--gold-light); padding: 52px 0 26px; font-family: var(--font-ui); }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 34px; margin-bottom: 32px; }
.footer-brand img { height: 64px; width: 64px; border-radius: 10px; background: var(--white); margin-bottom: 14px; }
.footer-brand p { color: var(--gold-light); font-size: 0.9rem; max-width: 300px; margin: 0; }
footer h4 { color: var(--white); font-family: var(--font-ui); font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.1em; margin: 0 0 14px; }
footer ul { list-style: none; padding: 0; margin: 0; }
footer li { margin-bottom: 9px; }
footer a { color: var(--gold-light); font-size: 0.9rem; }
footer a:hover { color: var(--white); }
.footer-langs { display: flex; flex-wrap: wrap; gap: 6px 16px; padding: 18px 0; border-top: 1px solid rgba(255,255,255,0.12); }
footer .bottom {
  border-top: 1px solid rgba(255,255,255,0.12); padding-top: 20px; font-size: 0.82rem;
  color: rgba(232,217,181,0.75); display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px;
}

/* ---------- Language chooser (site root) ---------- */
.chooser { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 40px 20px; text-align: center; }
.chooser-inner { max-width: 620px; }
.chooser img { width: 120px; height: 120px; border-radius: 20px; margin: 0 auto 22px; background: var(--white); box-shadow: var(--shadow); }
.chooser h1 { font-size: 1.9rem; margin: 0 0 8px; }
.chooser p { margin: 0 0 28px; }
.chooser-links { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }
.chooser-links a { min-width: 140px; }



/* ---------- Cart (Lebanon store) ---------- */
.cart-count {
  min-width: 18px; height: 18px; padding: 0 5px; border-radius: 999px; background: var(--maroon);
  color: var(--white); font-size: 0.72rem; line-height: 18px; text-align: center;
}
.cart-count[hidden] { display: none; }
.shop-buy .btn { width: 100%; }
.shop-error { margin: 6px 0 0; font-family: var(--font-ui); font-size: 0.85rem; color: #a12a1c; }

html.cart-open { overflow: hidden; }
.cart-overlay {
  position: fixed; inset: 0; z-index: 90; background: rgba(30, 12, 6, 0.5);
  opacity: 0; pointer-events: none; transition: opacity 0.2s ease;
}
.cart-overlay.open { opacity: 1; pointer-events: auto; }
.cart-drawer {
  position: fixed; top: 0; bottom: 0; inset-inline-end: 0; z-index: 95; width: min(420px, 100%);
  display: flex; flex-direction: column; background: var(--cream);
  box-shadow: 0 0 40px rgba(30, 12, 6, 0.3); transform: translateX(100%); visibility: hidden;
  transition: transform 0.25s ease, visibility 0.25s ease;
}
[dir="rtl"] .cart-drawer { transform: translateX(-100%); }
.cart-drawer.open { transform: none; visibility: visible; }
.cart-drawer.is-busy .cart-body, .cart-drawer.is-busy .cart-foot { opacity: 0.55; pointer-events: none; }
.cart-head {
  display: flex; align-items: center; justify-content: space-between; padding: 18px 22px;
  border-bottom: 1px solid var(--line);
}
.cart-head h2 { margin: 0; font-size: 1.3rem; }
.cart-close { background: none; border: 0; font-size: 2rem; line-height: 1; color: var(--maroon-dark); cursor: pointer; padding: 0 6px; }
.cart-body { flex: 1; overflow-y: auto; padding: 8px 22px; }
.cart-empty { text-align: center; margin: 48px 0; }
.cart-line { display: flex; gap: 14px; align-items: flex-start; padding: 16px 0; border-bottom: 1px solid var(--line); }
.cl-img { width: 60px; height: 84px; object-fit: cover; border-radius: 4px; flex-shrink: 0; background: var(--gold-light); }
.cl-info { flex: 1; display: flex; flex-direction: column; gap: 4px; font-family: var(--font-ui); }
.cl-title { font-family: var(--font-body); font-size: 0.98rem; color: var(--maroon-dark); line-height: 1.35; }
.cl-price { font-size: 0.9rem; color: var(--ink-soft); }
.cl-qty { display: inline-flex; align-items: center; gap: 4px; margin-top: 4px; }
.cl-qty button {
  width: 30px; height: 30px; border: 1px solid var(--line); border-radius: 50%; background: var(--white);
  color: var(--maroon-dark); font-size: 1.1rem; line-height: 1; cursor: pointer;
}
.cl-qty span { min-width: 30px; text-align: center; font-weight: 700; }
.cl-remove { background: none; border: 0; padding: 4px 0; cursor: pointer; font-family: var(--font-ui); font-size: 0.8rem; color: var(--ink-soft); text-decoration: underline; }
.cart-foot { padding: 18px 22px 24px; border-top: 1px solid var(--line); background: var(--white); }
.cart-foot[hidden] { display: none; }
.cart-msg { min-height: 1.2em; margin: 0 0 6px; color: #a12a1c; font-family: var(--font-ui); font-size: 0.85rem; }
.cart-subtotal { display: flex; justify-content: space-between; font-family: var(--font-ui); font-size: 1.05rem; margin-bottom: 6px; }
.cart-note { margin: 0 0 14px; font-family: var(--font-ui); font-size: 0.82rem; }

/* Flags inside other components */
.site-footer .flag-link { color: var(--gold-light); }
.site-footer .flag-link:hover { background: rgba(255,255,255,0.12); color: var(--white); }
.site-footer .flag-link[aria-current="true"] { background: rgba(255,255,255,0.14); border-color: var(--gold); color: var(--white); }
.lang-tabs a { display: inline-flex; align-items: center; gap: 8px; }
.lang-tabs a img { width: 20px; height: 20px; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 1px rgba(60,25,10,0.22); }
.chooser-links a { display: inline-flex; align-items: center; justify-content: center; gap: 10px; }
.chooser-links a img { width: 24px; height: 24px; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 1px rgba(60,25,10,0.22); }

/* ---------- Responsive ---------- */
@media (max-width: 1000px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .steps { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 900px) {
  .nav-toggle { display: block; }
  nav.main-nav {
    position: absolute; top: 100%; inset-inline: 0; background: var(--cream);
    border-bottom: 1px solid var(--line); display: none; padding: 12px 24px 22px;
  }
  nav.main-nav.open { display: block; }
  nav.main-nav ul { flex-direction: column; gap: 14px; }
  .nav-inner { flex-wrap: nowrap; }
  .grid-3, .order-cards, .contact-grid, .books-layout { grid-template-columns: 1fr; }
  .book-detail { grid-template-columns: 1fr; gap: 28px; }
  .book-detail .cover-wrap { max-width: 320px; margin: 0 auto; }
  section { padding: 48px 0; }
}

@media (max-width: 700px) {
  .topbar .container { justify-content: center; padding-inline: 12px; }
  .flag-link { padding-inline: 3px; }
  .flag-name { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
  .site-footer .flag-link { padding-inline: 3px; }
}

@media (max-width: 600px) {
  .footer-grid { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr 1fr; }
  .event-card { flex-direction: column; }
  .hero { padding: 44px 0 40px; }
  .book-facts { grid-template-columns: 1fr; gap: 2px; }
  .book-facts dd { margin-bottom: 10px; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; scroll-behavior: auto !important; }
}
