/* Istighfar website — same palette and type as the app. */

@font-face { font-family: "Plex Arabic"; src: url("../fonts/IBMPlexSansArabic-Regular.ttf") format("truetype"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Plex Arabic"; src: url("../fonts/IBMPlexSansArabic-Medium.ttf") format("truetype"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Plex Arabic"; src: url("../fonts/IBMPlexSansArabic-SemiBold.ttf") format("truetype"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Plex Arabic"; src: url("../fonts/IBMPlexSansArabic-Bold.ttf") format("truetype"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Naskh"; src: url("../fonts/NotoNaskhArabic.ttf") format("truetype"); font-weight: 400 700; font-display: swap; }

:root {
  --bg: #F8F7F2;
  --bg-alt: #F2F0E8;
  --surface: #FDFCF8;
  --accent: #829985;
  --accent-strong: #526B58;
  --accent-soft: #E3E9DF;
  --beige: #E9E4D9;
  --text: #283A30;
  --text-2: #6F7069;
  --text-3: #898A82;
  --divider: #E6E2D8;
  --on-accent: #FDFCF8;
  --shadow: 0 1px 2px rgba(40, 58, 48, .04), 0 12px 32px -12px rgba(40, 58, 48, .14);
  --radius: 28px;
  --page: min(1080px, 100% - 48px);
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #131B16;
    --bg-alt: #18221C;
    --surface: #1C2620;
    --accent: #9DB3A0;
    --accent-strong: #B8CCBA;
    --accent-soft: #2A3A30;
    --beige: #2C352F;
    --text: #EFEBE1;
    --text-2: #B0B1A6;
    --text-3: #8E9086;
    --divider: #2A352E;
    --on-accent: #131B16;
    --shadow: 0 1px 2px rgba(0, 0, 0, .2), 0 16px 40px -16px rgba(0, 0, 0, .5);
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; animation: none !important; } }

body {
  margin: 0;
  font-family: "Plex Arabic", system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 17px;
  line-height: 1.75;
  color: var(--text);
  background:
    radial-gradient(1200px 600px at 85% -10%, var(--accent-soft), transparent 60%),
    var(--bg);
  background-repeat: no-repeat;
  text-rendering: optimizeLegibility;
}
html[lang="en"] body { line-height: 1.65; }

a { color: var(--accent-strong); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 2px solid var(--accent-strong); outline-offset: 3px; border-radius: 8px; }
img { max-width: 100%; display: block; }

.wrap { width: var(--page); margin-inline: auto; }

.skip { position: absolute; inset-inline-start: 16px; top: -60px; background: var(--surface); padding: 8px 14px; border-radius: 12px; z-index: 10; }
.skip:focus { top: 12px; }

/* Header */
.site-header { padding: 20px 0; }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.brand { display: inline-flex; align-items: center; gap: 12px; color: var(--text); text-decoration: none; font-weight: 700; font-size: 20px; }
.brand img { width: 40px; height: 40px; border-radius: 11px; box-shadow: var(--shadow); }
.nav { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.nav a { color: var(--text-2); text-decoration: none; padding: 8px 14px; border-radius: 999px; font-size: 15px; font-weight: 500; }
.nav a:hover, .nav a[aria-current="page"] { background: var(--accent-soft); color: var(--accent-strong); }
.nav .lang { border: 1px solid var(--divider); }

/* Hero */
.hero { padding: 40px 0 24px; }
.hero .wrap { display: grid; grid-template-columns: 1.05fr .95fr; align-items: center; gap: 48px; }
.eyebrow { display: inline-block; color: var(--accent-strong); background: var(--accent-soft); padding: 4px 14px; border-radius: 999px; font-size: 14px; font-weight: 600; }
h1 { font-size: clamp(40px, 6vw, 64px); line-height: 1.2; margin: 18px 0 12px; font-weight: 700; letter-spacing: -.01em; }
.phrase { font-family: "Naskh", serif; font-weight: 600; color: var(--accent-strong); font-size: clamp(22px, 2.6vw, 28px); line-height: 1.9; margin: 0 0 12px; }
.lead { font-size: 19px; color: var(--text-2); max-width: 34em; margin: 0 0 28px; }

.stores { display: flex; gap: 12px; flex-wrap: wrap; }
.store { display: inline-flex; align-items: center; gap: 12px; padding: 12px 20px; border-radius: 18px; background: var(--surface); border: 1px solid var(--divider); color: var(--text); text-decoration: none; min-width: 200px; }
.store svg { width: 26px; height: 26px; flex: none; }
.store small { display: block; font-size: 12px; color: var(--text-3); line-height: 1.3; }
.store strong { display: block; font-size: 17px; line-height: 1.3; white-space: nowrap; }
.store[aria-disabled="true"] { cursor: default; }
.note { color: var(--text-3); font-size: 14px; margin-top: 12px; }

/* Phones */
.phones { position: relative; display: flex; justify-content: center; align-items: flex-end; min-height: 560px; }
.phones::before { content: ""; position: absolute; inset: 10% 8% 0; background: radial-gradient(closest-side, var(--accent-soft), transparent); z-index: -1; }
.phone { width: 260px; border-radius: 40px; padding: 9px; background: var(--surface); box-shadow: var(--shadow); border: 1px solid var(--divider); }
.phone img { border-radius: 32px; width: 100%; height: auto; aspect-ratio: 1179 / 2556; background: var(--bg-alt); }
.phones .phone:nth-child(2) { width: 220px; margin-inline-start: -60px; margin-bottom: 40px; transform: rotate(-4deg); opacity: .96; }
html[dir="ltr"] .phones .phone:nth-child(2) { transform: rotate(4deg); }

/* Sections */
section { padding: 56px 0; }
.section-head { max-width: 40em; margin-bottom: 32px; }
h2 { font-size: clamp(28px, 3.6vw, 38px); line-height: 1.3; margin: 0 0 10px; }
.section-head p { color: var(--text-2); margin: 0; font-size: 18px; }

.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.card { background: var(--surface); border: 1px solid var(--divider); border-radius: var(--radius); padding: 26px; box-shadow: var(--shadow); }
.card h3 { margin: 14px 0 6px; font-size: 19px; }
.card p { margin: 0; color: var(--text-2); font-size: 16px; }
.icon { width: 48px; height: 48px; border-radius: 16px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent-strong); }
.icon svg { width: 24px; height: 24px; }

.gallery { display: flex; gap: 20px; overflow-x: auto; padding: 8px 4px 24px; scroll-snap-type: x mandatory; }
.gallery figure { margin: 0; flex: none; scroll-snap-align: center; text-align: center; }
.gallery .phone { width: 230px; }
@media (min-width: 1000px) { .gallery { justify-content: space-between; overflow: visible; } .gallery .phone { width: 188px; padding: 7px; border-radius: 32px; } .gallery .phone img { border-radius: 26px; } }
.gallery figcaption { margin-top: 12px; color: var(--text-2); font-size: 15px; }

.privacy-band { background: var(--accent-soft); border-radius: 36px; padding: 44px; display: grid; grid-template-columns: auto 1fr; gap: 28px; align-items: center; }
.privacy-band .icon { width: 72px; height: 72px; border-radius: 24px; background: var(--surface); }
.privacy-band .icon svg { width: 34px; height: 34px; }
.privacy-band h2 { margin-bottom: 6px; }
.privacy-band p { margin: 0; color: var(--text-2); }
.privacy-band ul { margin: 12px 0 0; padding: 0; list-style: none; display: flex; flex-wrap: wrap; gap: 8px; }
.privacy-band li { background: var(--surface); border-radius: 999px; padding: 4px 14px; font-size: 14px; font-weight: 500; color: var(--accent-strong); }

/* Document pages (privacy, support) */
.doc { padding: 24px 0 64px; }
.doc .wrap { max-width: 760px; }
.doc h1 { font-size: clamp(34px, 5vw, 46px); margin-top: 8px; }
.doc .meta { color: var(--text-3); font-size: 15px; margin: 0 0 28px; }
.doc h2 { font-size: 24px; margin: 40px 0 10px; }
.doc h3 { font-size: 19px; margin: 24px 0 6px; }
.doc p, .doc li { color: var(--text-2); }
.doc strong { color: var(--text); }
.doc ul { padding-inline-start: 22px; }
.doc li { margin: 6px 0; }
.summary { background: var(--surface); border: 1px solid var(--divider); border-radius: var(--radius); padding: 22px 26px; box-shadow: var(--shadow); }
.summary p { margin: 0; color: var(--text); }

.contact-card { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; background: var(--surface); border: 1px solid var(--divider); border-radius: var(--radius); padding: 24px 28px; box-shadow: var(--shadow); margin: 8px 0 12px; }
.contact-card p { margin: 0; }
.btn { display: inline-flex; align-items: center; gap: 10px; background: var(--accent-strong); color: var(--on-accent); text-decoration: none; font-weight: 600; padding: 12px 22px; border-radius: 999px; }
.btn:hover { filter: brightness(1.08); }
.email { direction: ltr; unicode-bidi: isolate; font-weight: 600; color: var(--text); }

details { background: var(--surface); border: 1px solid var(--divider); border-radius: 20px; padding: 4px 22px; margin: 10px 0; }
details[open] { padding-bottom: 14px; }
summary { cursor: pointer; font-weight: 600; padding: 14px 0; list-style: none; display: flex; justify-content: space-between; gap: 16px; color: var(--text); }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; color: var(--accent-strong); font-weight: 400; font-size: 22px; line-height: 1; }
details[open] summary::after { content: "−"; }
details p, details li { margin: 6px 0; }

/* Footer */
.site-footer { border-top: 1px solid var(--divider); padding: 32px 0 44px; margin-top: 24px; color: var(--text-3); font-size: 15px; }
.site-footer .wrap { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.site-footer nav { display: flex; gap: 18px; flex-wrap: wrap; }
.site-footer a { color: var(--text-2); text-decoration: none; }
.site-footer a:hover { color: var(--accent-strong); }

@media (max-width: 880px) {
  .hero .wrap { grid-template-columns: 1fr; gap: 24px; }
  .phones { min-height: 0; }
  .phone { width: 220px; }
  .phones .phone:nth-child(2) { width: 180px; margin-inline-start: -50px; }
  .grid { grid-template-columns: 1fr 1fr; }
  .privacy-band { grid-template-columns: 1fr; padding: 32px; }
}
@media (max-width: 560px) {
  body { font-size: 16px; }
  .site-header .wrap { flex-direction: column; align-items: flex-start; }
  .grid { grid-template-columns: 1fr; }
  .store { min-width: 0; flex: 1 1 160px; }
  section { padding: 40px 0; }
}
