/* ترف الحواس — ألوان الهوية مأخوذة من الشعار */
:root {
  --wine: #6B1426;      /* أحمر الشعار */
  --wine-deep: #430B17;
  --gold: #C29B72;      /* بيج الشعار */
  --gold-soft: #EADBC6;
  --gold-ink: #85603C;  /* بيج غامق للنصوص الصغيرة (تباين كافي) */
  --ivory: #FCF8F1;     /* خلفية الشعار */
  --paper: #FFFDF8;
  --ink: #2B1A1F;
  --muted: #7B6668;
  --line: #ECDFCD;
  --ok: #2F6B4F;
  --err: #A33A3A;
  --wa: #1E7D4F;
  --accent: #6B1426;    /* نصوص وعناوين بلون الهوية */
  --on-wine: #FFFDF8;   /* نص فوق خلفية عنابية */
  --tint: #F7EEE2;      /* تظليل خفيف */
  --err-bg: #FBEFEF;
  --radius-arch: 999px 999px 18px 18px;
  --shadow: 0 1px 0 rgba(107, 20, 38, .06), 0 10px 30px -18px rgba(67, 11, 23, .35);
  --display: "Almarai", "Segoe UI", Tahoma, sans-serif;
  --body: "Almarai", "Segoe UI", Tahoma, sans-serif;
  color-scheme: light;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { animation: none !important; transition: none !important; } }
body { margin: 0; overflow-x: clip; background: var(--ivory); color: var(--ink); font: 400 16px/1.75 var(--body); }
img { max-width: 100%; display: block; }
a { color: var(--accent); }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; border-radius: 6px; }
.wrap { width: min(1120px, 100% - 32px); margin-inline: auto; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
h1, h2, h3 { font-family: var(--display); font-weight: 800; color: var(--accent); line-height: 1.4; margin: 0; letter-spacing: -.01em; }
h2 { font-size: clamp(1.9rem, 4.5vw, 2.6rem); }
p { margin: 0; }

/* ---------- أزرار ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5rem; min-height: 48px; padding: .7rem 1.4rem; border-radius: 999px; border: 1px solid transparent; font: 600 1rem/1 var(--body); text-decoration: none; cursor: pointer; transition: background .2s, color .2s, border-color .2s, transform .1s; }
.btn:active { transform: translateY(1px); }
.btn-wine { background: var(--wine); color: var(--on-wine); }
.btn-wine:hover { background: var(--wine-deep); }
.btn-ghost { background: transparent; color: var(--accent); border-color: var(--gold); }
.btn-ghost:hover { background: var(--paper); }
.btn-wa { background: var(--wa); color: #fff; }
.btn-wa:hover { background: #16623d; }
.btn[disabled] { opacity: .55; cursor: wait; }

/* ---------- الشريط العلوي ---------- */
.top { position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--ivory) 92%, transparent); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.top .wrap { display: flex; align-items: center; justify-content: space-between; height: 64px; gap: 1rem; }
.brand { display: flex; align-items: center; gap: .6rem; text-decoration: none; }
.brand img { width: 40px; height: 40px; object-fit: contain; }
.brand span { font-family: var(--display); font-weight: 800; font-size: 1.25rem; color: var(--accent); }
.top nav { display: flex; gap: 1.4rem; }
.top nav a { color: var(--ink); text-decoration: none; font-weight: 500; font-size: .95rem; }
.top nav a:hover { color: var(--accent); }
.top .btn { min-height: 40px; padding: .5rem 1.1rem; font-size: .95rem; }
@media (max-width: 760px) { .top nav { display: none; } }

/* ---------- الواجهة: نافذة القوس ---------- */
.hero { padding: clamp(2rem, 6vw, 4.5rem) 0 clamp(2.5rem, 6vw, 4rem); overflow: hidden; }
.hero .wrap { display: grid; grid-template-columns: 1.1fr .9fr; align-items: center; gap: clamp(1.5rem, 5vw, 4rem); }
.hero h1 { font-size: clamp(2.2rem, 6vw, 3.7rem); line-height: 1.35; color: var(--hero-ink, var(--wine-deep)); }
.hero .sub { margin-top: 1rem; font-size: clamp(1.05rem, 2.2vw, 1.2rem); color: var(--muted); max-width: 34ch; }
.hero .cta { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1.75rem; }
.facts { display: flex; flex-wrap: wrap; gap: .5rem; margin: 1.75rem 0 0; padding: 0; list-style: none; }
.facts li { padding: .35rem .85rem; border: 1px solid var(--line); border-radius: 999px; background: var(--paper); font-size: .9rem; color: var(--ink); }
.arch { position: relative; aspect-ratio: 4 / 5; max-width: 380px; width: 100%; margin-inline: auto; border-radius: var(--radius-arch); background: linear-gradient(180deg, #FFFDF8 0 40%, #F4E8D8); --accent: #6B1426; display: grid; place-items: center; box-shadow: var(--shadow); }
.arch svg.frame { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.arch svg.frame path { fill: none; stroke: var(--gold); stroke-width: 1.4; stroke-dasharray: 1600; stroke-dashoffset: 1600; animation: draw 2.4s .2s cubic-bezier(.6,.1,.2,1) forwards; }
.arch svg.frame path.inner { stroke-width: .8; opacity: .6; animation-delay: .6s; }
@keyframes draw { to { stroke-dashoffset: 0; } }
.arch img { width: 66%; }
.arch .motto { position: absolute; bottom: 9%; inset-inline: 0; text-align: center; font-family: var(--display); font-weight: 700; color: var(--gold-ink); font-size: 1.1rem; }
@media (max-width: 760px) {
  .hero .wrap { grid-template-columns: 1fr; }
  .hero { padding-top: 1.5rem; }
  .arch { max-width: 200px; }
  .hero .cta .btn { flex: 1 1 100%; }
}

/* ---------- عناوين الأقسام ---------- */
section { scroll-margin-top: 72px; }
.sec { padding: clamp(3rem, 7vw, 5rem) 0; }
.sec-head { max-width: 640px; margin-bottom: 2rem; }
.sec-head p { margin-top: .5rem; color: var(--muted); }
.ornament { display: block; width: 120px; height: 14px; margin: .9rem 0 0; color: var(--gold); }

/* ---------- الخدمات: قائمة مثل المنيو ---------- */
.services { background: var(--paper); border-block: 1px solid var(--line); }
.cat-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; margin-bottom: .5rem; }
@media (max-width: 760px) { .cat-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .75rem; } }
.cat-card { display: flex; flex-direction: column; align-items: stretch; gap: .15rem; padding: 0 0 .8rem; border: 1px solid var(--line); border-radius: 120px 120px 16px 16px; background: var(--ivory); overflow: hidden; cursor: pointer; text-align: center; font-family: var(--body); color: var(--ink); box-shadow: var(--shadow); transition: transform .15s, border-color .15s, box-shadow .15s; }
.cat-card img { width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: cover; margin-bottom: .45rem; }
.cat-card:hover { transform: translateY(-2px); border-color: var(--gold); }
.cat-card[aria-pressed="true"] { border: 2px solid var(--wine); background: var(--paper); }
.cc-title { font-weight: 800; font-size: 1.02rem; color: var(--accent); padding: 0 .4rem; }
.cc-meta { font-size: .8rem; color: var(--gold-ink); padding: 0 .4rem; }
.cat-reset { margin: .5rem 0 1rem; min-height: 1.6rem; }
.tabs { display: flex; gap: .5rem; overflow-x: auto; padding-bottom: .5rem; margin-bottom: 1.5rem; scrollbar-width: thin; }
.tab { flex: none; padding: .55rem 1rem; border-radius: 999px; border: 1px solid var(--line); background: var(--ivory); color: var(--ink); font: 500 .95rem var(--body); cursor: pointer; }
.tab[aria-selected="true"] { background: var(--wine); border-color: var(--accent); color: var(--on-wine); }
.menu { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 460px), 1fr)); gap: 0 3rem; }
.cat { margin-bottom: 2.5rem; }
.cat { scroll-margin-top: 80px; }
.cat-img { display: none; }
.cat h3 { font-size: 1.35rem; display: flex; align-items: baseline; gap: .6rem; margin-bottom: .25rem; }
.cat .note { font-family: var(--body); font-size: .85rem; color: var(--gold-ink); font-weight: 600; }
.item { display: grid; grid-template-columns: 1fr auto; gap: .25rem 1rem; padding: 1rem 0; border-bottom: 1px dashed var(--line); }
.item .row { display: flex; align-items: baseline; gap: .5rem; min-width: 0; }
.item .name { font-weight: 600; }
.item .dots { flex: 1; border-bottom: 2px dotted var(--gold-soft); transform: translateY(-4px); min-width: 1.5rem; }
.item .price { font-weight: 700; color: var(--accent); white-space: nowrap; }
.item .price small { font-weight: 500; color: var(--muted); }
.item .desc { grid-column: 1; font-size: .9rem; color: var(--muted); }
.item .badge { display: inline-block; font-size: .75rem; color: var(--gold-ink); border: 1px solid var(--gold-soft); border-radius: 999px; padding: 0 .5rem; margin-inline-start: .25rem; }
.stepper { grid-row: 1 / span 2; grid-column: 2; align-self: center; display: flex; align-items: center; gap: .25rem; }
.stepper button { width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--gold); background: var(--paper); color: var(--accent); font: 600 1.15rem/1 var(--body); cursor: pointer; }
.stepper button.add { width: auto; min-height: 40px; padding: 0 1.1rem; border-radius: 999px; font-size: .92rem; background: var(--wine); border-color: var(--accent); color: var(--on-wine); }
.stepper button.add:hover { background: var(--wine-deep); }
.item:has(output) { background: linear-gradient(90deg, transparent, var(--tint) 30%, var(--tint) 70%, transparent); }
.stepper output { min-width: 1.4rem; text-align: center; font-weight: 700; color: var(--accent); }
.stepper .two { font-size: .72rem; color: var(--muted); }

/* ---------- خطوات الطلب ---------- */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; margin: 0; padding: 0; list-style: none; counter-reset: s; }
.steps li { counter-increment: s; padding: 1.5rem 1.25rem 1.25rem; border-radius: var(--radius-arch); background: var(--paper); border: 1px solid var(--line); text-align: center; }
.steps li::before { content: counter(s, arabic-indic); display: grid; place-items: center; width: 44px; height: 44px; margin: 0 auto .75rem; border-radius: 50%; border: 1px solid var(--gold); font-family: var(--display); font-weight: 800; font-size: 1.2rem; color: var(--accent); }
.steps h3 { font-size: 1.2rem; }
.steps p { color: var(--muted); font-size: .95rem; margin-top: .35rem; }
@media (max-width: 760px) { .steps { grid-template-columns: 1fr; } }

.coverage { margin-top: 2rem; padding: 1rem 1.25rem; border-inline-start: 3px solid var(--gold); background: var(--paper); border-radius: 8px; }

/* ---------- نموذج الطلب ---------- */
.order { background: var(--wine-deep); color: var(--on-wine); }
.order h2, .order .sec-head p { color: var(--on-wine); }
.order .sec-head p { opacity: .8; }
.form { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, .8fr); gap: 2rem; align-items: start; }
.form > *, .menu > *, .hero .wrap > * { min-width: 0; }
@media (max-width: 860px) { .form { grid-template-columns: minmax(0, 1fr); } }
.card { background: var(--paper); color: var(--ink); border-radius: 18px; padding: clamp(1.25rem, 3vw, 2rem); }
.field { margin-bottom: 1.5rem; }
.card { counter-reset: f; }
.card > .field { counter-increment: f; }
.card > .field > label::before, .card > .field > .label::before { content: counter(f, arabic-indic); display: inline-grid; place-items: center; width: 26px; height: 26px; margin-inline-end: .5rem; border-radius: 50%; background: var(--wine); color: var(--on-wine); font-size: .85rem; font-weight: 700; vertical-align: 1px; }
.field > label, .field > .label { display: block; font-weight: 600; margin-bottom: .5rem; }
.field .hint { font-size: .85rem; color: var(--muted); margin-top: .35rem; }
.field .error { display: none; color: var(--err); font-size: .9rem; margin-top: .4rem; }
.field.invalid .error { display: block; }
.field.invalid input { border-color: var(--err); }
input[type="text"], input[type="url"] { width: 100%; min-height: 48px; padding: .6rem .9rem; border: 1px solid var(--line); border-radius: 12px; background: var(--ivory); font: 400 1rem var(--body); color: var(--ink); }
input:focus { outline: 2px solid var(--gold); outline-offset: 0; border-color: var(--gold); }
.chips { display: flex; gap: .5rem; overflow-x: auto; padding: .15rem .1rem .5rem; scrollbar-width: thin; }
.chips.wrapgrid { flex-wrap: wrap; overflow: visible; }
.chip { flex: none; min-width: 64px; padding: .5rem .8rem; border-radius: 12px; border: 1px solid var(--line); background: var(--ivory); color: var(--ink); font: 500 .92rem/1.35 var(--body); cursor: pointer; text-align: center; }
.chip small { display: block; font-size: .78rem; color: var(--muted); }
.chip[aria-pressed="true"] { background: var(--wine); border-color: var(--accent); color: var(--on-wine); }
.chip[aria-pressed="true"] small { color: var(--gold-soft); }
.chip:disabled { opacity: .4; text-decoration: line-through; cursor: not-allowed; }
.picked { margin: 0; padding: 0; list-style: none; }
.picked li { display: flex; justify-content: space-between; gap: 1rem; padding: .35rem 0; }
.picked .empty { color: var(--muted); }
.loc { display: flex; flex-wrap: wrap; gap: .6rem; align-items: center; }
.loc .ok { color: var(--ok); font-weight: 600; }
.link-btn { background: none; border: 0; color: var(--accent); text-decoration: underline; font: 500 .95rem var(--body); cursor: pointer; padding: 0; }
.suggest { display: none; margin-top: .6rem; padding: .7rem .9rem; border-radius: 12px; background: var(--err-bg); color: var(--err); font-size: .92rem; }
.suggest.show { display: block; }
.suggest button { margin-inline-start: .4rem; }
.hp { position: absolute; inset-inline-start: -9999px; }

/* الفاتورة */
.receipt { position: sticky; top: 84px; background: var(--paper); color: var(--ink); border-radius: 18px; padding: 1.5rem; }
.receipt h3 { font-size: 1.3rem; margin-bottom: .75rem; }
.receipt .line { display: flex; align-items: baseline; gap: .5rem; padding: .3rem 0; font-size: .95rem; }
.receipt .line .dots { flex: 1; border-bottom: 2px dotted var(--gold-soft); transform: translateY(-4px); }
.receipt .total { margin-top: .5rem; padding-top: .75rem; border-top: 1px solid var(--line); font-family: var(--display); font-weight: 800; font-size: 1.3rem; color: var(--accent); }
.receipt .pay { margin-top: 1rem; font-size: .88rem; color: var(--muted); }
.receipt .btn { width: 100%; margin-top: 1rem; }
.receipt .form-err { display: none; color: var(--err); font-size: .9rem; margin-top: .6rem; }
.receipt .form-err.show { display: block; }

/* شريط الإجمالي في الجوال */
.bar { display: none; }
@media (max-width: 860px) {
  .receipt { position: static; }
  .bar { position: fixed; inset-inline: 0; bottom: 0; z-index: 30; display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .75rem 16px calc(.75rem + env(safe-area-inset-bottom)); background: var(--wine-deep); color: var(--on-wine); box-shadow: 0 -8px 24px rgba(0,0,0,.18); transform: translateY(110%); transition: transform .25s; }
  .bar.show { transform: none; }
  .bar .sum { font-size: .9rem; }
  .bar .sum b { font-family: var(--display); font-weight: 800; font-size: 1.15rem; color: var(--gold-soft); }
  .bar .btn { min-height: 42px; padding: .5rem 1.1rem; background: var(--gold); color: var(--wine-deep); }
}

/* ---------- الأسئلة ---------- */
.faq details { border-bottom: 1px solid var(--line); padding: 1rem 0; }
.faq summary { cursor: pointer; font-weight: 600; list-style: none; display: flex; justify-content: space-between; gap: 1rem; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--gold); font-size: 1.3rem; line-height: 1; }
.faq details[open] summary::after { content: "−"; }
.faq details p { margin-top: .6rem; color: var(--muted); max-width: 70ch; }

/* ---------- التذييل ---------- */
footer { background: var(--wine-deep); color: var(--gold-soft); padding: 2.5rem 0 calc(2.5rem + 64px); }
footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1.5rem; align-items: center; }
footer .brand span { color: var(--on-wine); }
footer a { color: var(--gold-soft); }
footer p { font-size: .9rem; }
@media (min-width: 861px) { footer { padding-bottom: 2.5rem; } }

/* ---------- شاشة التأكيد ---------- */
.done { position: fixed; inset: 0; z-index: 50; display: none; place-items: center; padding: 16px; background: rgba(67, 11, 23, .72); }
.done.show { display: grid; }
.done .card { width: min(440px, 100%); text-align: center; border-radius: var(--radius-arch); padding-top: 3rem; max-height: 100%; overflow: auto; }
.done h2 { font-size: 2rem; }
.seal { display: inline-block; margin: 1rem auto; padding: .6rem 1.2rem; border: 2px solid var(--gold); border-radius: 12px; font: 700 1.35rem/1.2 var(--body); letter-spacing: .06em; color: var(--accent); direction: ltr; }
.done .note { color: var(--muted); font-size: .92rem; margin: .5rem 0 1.25rem; }
.done .btn { width: 100%; }
.done .copy { margin-top: .75rem; }

/* ---------- مساعدة ترف الحواس (المحادثة) ---------- */
.chat-fab { position: fixed; z-index: 40; inset-inline-end: 16px; bottom: calc(16px + env(safe-area-inset-bottom)); display: inline-flex; align-items: center; gap: .5rem; padding: .55rem 1rem .55rem .7rem; border: 1px solid var(--gold); border-radius: 999px; background: var(--paper); color: var(--accent); font: 700 .95rem var(--body); box-shadow: 0 10px 30px -10px rgba(67, 11, 23, .45); cursor: pointer; }
.chat-fab img { width: 28px; height: 28px; }
.chat-open .chat-fab { display: none; }
@media (max-width: 860px) { .bar.show ~ .chat-fab { bottom: calc(80px + env(safe-area-inset-bottom)); } }
.chat-panel { position: fixed; z-index: 60; inset-inline-end: 16px; bottom: 16px; width: min(400px, calc(100vw - 32px)); height: min(640px, calc(100dvh - 32px)); display: flex; flex-direction: column; background: var(--ivory); border: 1px solid var(--gold-soft); border-radius: 24px; box-shadow: 0 24px 60px -20px rgba(67, 11, 23, .55); overflow: hidden; }
@media (max-width: 520px) { .chat-panel { inset: 0; width: 100%; height: 100dvh; border-radius: 0; border: 0; } }
.chat-head { display: flex; align-items: center; gap: .7rem; padding: .85rem 1rem; background: var(--wine); color: var(--on-wine); }
.chat-head img { background: #FFFDF8; border-radius: 50%; padding: 3px; }
.chat-head div { flex: 1; min-width: 0; }
.chat-title { font-weight: 800; }
.chat-sub { font-size: .8rem; color: var(--gold-soft); }
.chat-close { width: 36px; height: 36px; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .12); color: var(--on-wine); font-size: 1.5rem; line-height: 1; cursor: pointer; }
.chat-log { flex: 1; overflow-y: auto; padding: 1rem; display: flex; flex-direction: column; gap: .6rem; overscroll-behavior: contain; }
.msg { max-width: 88%; padding: .65rem .85rem; border-radius: 16px; font-size: .95rem; line-height: 1.7; overflow-wrap: anywhere; }
.msg.bot { align-self: flex-start; background: var(--paper); border: 1px solid var(--line); border-start-start-radius: 4px; }
.msg.me { align-self: flex-end; background: var(--wine); color: var(--on-wine); border-start-end-radius: 4px; }
.msg a { color: var(--accent); font-weight: 700; }
.msg.typing { display: inline-flex; gap: 4px; padding: .8rem 1rem; }
.msg.typing span { width: 7px; height: 7px; border-radius: 50%; background: var(--gold); animation: blink 1.2s infinite; }
.msg.typing span:nth-child(2) { animation-delay: .2s; } .msg.typing span:nth-child(3) { animation-delay: .4s; }
@keyframes blink { 0%, 80%, 100% { opacity: .25; } 40% { opacity: 1; } }
.chat-quick { display: flex; flex-wrap: wrap; gap: .4rem; padding: 0 1rem .6rem; max-height: 38%; overflow-y: auto; }
.chat-quick:empty { display: none; }
.qr { padding: .45rem .8rem; border-radius: 999px; border: 1px solid var(--gold); background: var(--paper); color: var(--accent); font: 600 .88rem/1.4 var(--body); cursor: pointer; text-align: start; }
.qr small { display: block; font-weight: 400; font-size: .75rem; color: var(--muted); }
.qr:hover { background: var(--tint); }
.qr-strong { background: var(--wine); color: var(--on-wine); border-color: var(--accent); }
.qr-hint { width: 100%; font-size: .8rem; color: var(--muted); margin-top: .25rem; }
.chat-form { display: flex; gap: .5rem; padding: .75rem 1rem calc(.75rem + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); background: var(--paper); }
.chat-input { flex: 1; min-height: 44px; padding: .5rem .9rem; border: 1px solid var(--line); border-radius: 999px; background: var(--ivory); font: 400 1rem var(--body); }
.chat-send { min-height: 44px; padding: 0 1.1rem; border: 0; border-radius: 999px; background: var(--wine); color: var(--on-wine); font: 700 .92rem var(--body); cursor: pointer; }
.order-card { text-align: center; }
.order-card .seal { margin: .4rem auto .8rem; font-size: 1.1rem; }
.order-card .btn { width: 100%; }

.link-light { color: var(--gold-soft); font-size: inherit; }

/* ---------- الوضع الليلي ---------- */
:root[data-theme="dark"] {
  --ivory: #160B0E; --paper: #21121A; --ink: #F3E8DC; --muted: #BBA79F; --line: #3A242B;
  --gold-ink: #D9B48C; --accent: #E7BF95; --tint: #2B1820; --err-bg: #3A1A1E; --err: #F08A8A;
  --wine-deep: #2A0810; --hero-ink: #F1D3B0;
  --shadow: 0 1px 0 rgba(0,0,0,.3), 0 10px 30px -18px rgba(0,0,0,.8);
  color-scheme: dark;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ivory: #160B0E; --paper: #21121A; --ink: #F3E8DC; --muted: #BBA79F; --line: #3A242B;
    --gold-ink: #D9B48C; --accent: #E7BF95; --tint: #2B1820; --err-bg: #3A1A1E; --err: #F08A8A;
    --wine-deep: #2A0810; --hero-ink: #F1D3B0;
    --shadow: 0 1px 0 rgba(0,0,0,.3), 0 10px 30px -18px rgba(0,0,0,.8);
    color-scheme: dark;
  }
}
.theme-btn { width: 40px; height: 40px; display: inline-grid; place-items: center; border-radius: 50%; border: 1px solid var(--line); background: var(--paper); color: var(--accent); font-size: 1.1rem; cursor: pointer; }
.top .wrap .actions { display: flex; align-items: center; gap: .5rem; }
.install-btn { display: none; }
.can-install .install-btn { display: inline-flex; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .brand img { background: #FFFDF8; border-radius: 50%; padding: 3px; } }
:root[data-theme="dark"] .brand img { background: #FFFDF8; border-radius: 50%; padding: 3px; }

/* ---------- صفحة تثبيت التطبيق ---------- */
.inst { max-width: 560px; padding: 1.5rem 0 3rem; }
.inst-head { position: relative; text-align: center; padding: 1rem 0 1.5rem; }
.inst-head img { width: 150px; height: auto; margin: 0 auto .75rem; background: #FFFDF8; border-radius: 999px 999px 24px 24px; padding: 1rem; }
.inst-head h1 { font-size: 1.7rem; }
.inst-head p { color: var(--muted); margin-top: .4rem; }
.inst-head .theme-btn { position: absolute; top: 0; inset-inline-start: 0; }
.inst-card { background: var(--paper); border: 1px solid var(--line); border-radius: 20px; padding: 1.25rem 1.25rem .5rem; margin-bottom: 1rem; box-shadow: var(--shadow); }
.inst-card.mine { border: 2px solid var(--gold); }
.inst-card h2 { font-size: 1.25rem; display: flex; align-items: center; gap: .5rem; margin-bottom: .5rem; }
.inst-go { width: 100%; margin: .25rem 0 .75rem; }
.inst-steps { margin: 0; padding: 0; list-style: none; counter-reset: s; }
.inst-steps li { counter-increment: s; position: relative; padding: .6rem 2.6rem .6rem 0; border-top: 1px dashed var(--line); line-height: 1.9; }
.inst-steps li:first-child { border-top: 0; }
.inst-steps li::before { content: counter(s, arabic-indic); position: absolute; inset-inline-start: 0; top: .65rem; width: 28px; height: 28px; display: grid; place-items: center; border-radius: 50%; background: var(--wine); color: var(--on-wine); font-weight: 700; font-size: .9rem; }
.ico { width: 1.4em; height: 1.4em; vertical-align: -.35em; color: #0A84FF; display: inline-block; }
.inst-warn { background: var(--err-bg); color: var(--err); padding: .6rem .8rem; border-radius: 12px; margin-bottom: .5rem; font-size: .92rem; }
.inst-note { color: var(--muted); font-size: .9rem; padding: .6rem 0 .8rem; }
.inst-done { background: #E7F3EC; color: var(--ok); padding: .8rem 1rem; border-radius: 14px; text-align: center; font-weight: 700; margin-bottom: 1rem; }
.inst-help, .inst-back { text-align: center; margin-top: .75rem; }
.os { font-size: 1.2rem; }
.app-cta { display: none; margin-top: 1rem; color: var(--accent); font-weight: 700; text-decoration: none; border-bottom: 2px solid var(--gold); padding-bottom: 2px; width: fit-content; }
.can-install:not(.installed) .app-cta { display: inline-block; }
footer .hours, footer .rights { width: 100%; font-size: .85rem; opacity: .85; }
