/* zRate — public live market panel. Scoped to .zrate.
   Design system consistent with ZPay; market UX inspired by Chand; zRate identity.
   RTL. Numbers/English: Exo 2 (via --font-number); Persian: Vazirmatn. */

html, body { margin:0; padding:0; background:#0a0a0b; }
body { overflow-x:hidden; -webkit-text-size-adjust:100%; text-size-adjust:100%; }

.zrate {
	--font-en:"Exo 2", ui-sans-serif, system-ui, sans-serif;
	--font-number:var(--font-en);
	--mono:var(--font-number);
	--ui:"Vazirmatn", system-ui, -apple-system, "Segoe UI", sans-serif;
	--bg:#f8fafc; --panel:#ffffff; --panel2:#fbfcfe; --ink:#0f172a; --ink2:#334155; --muted:#64748b; --faint:#94a3b8;
	--line:#e9eef4; --line2:#e2e8f0;
	--brand:#3b6fed; --brand-ink:#2b5bd0; --brand-soft:#eef2ff;
	--pos:#059669; --neg:#dc2626; --warn:#b45309; --warn-soft:#fffbeb; --warn-line:#fde68a; --pos-soft:#ecfdf5; --pos-line:#a7f3d0; --neg-soft:#fef2f2; --neg-line:#fecaca;
	--gold:#d4a017; --gold2:#f4cf5b; --silver:#9aa3ad; --silver2:#cdd3da; --star:#f5b301;
	--slate-soft:#f1f5f9;
	--shadow:0 1px 3px rgba(15,23,42,.06), 0 1px 2px rgba(15,23,42,.04);
	min-height:100vh; min-height:100dvh; background:var(--bg); color:var(--ink);
	font-family:var(--ui); line-height:1.5; isolation:isolate; -webkit-font-smoothing:antialiased;
}
.zrate[data-theme="dark"]{
	--bg:#0a0a0b; --panel:#161617; --panel2:#1b1b1d; --ink:#f4f4f5; --ink2:#d4d4d8; --muted:#a1a1aa; --faint:#71717a;
	--line:rgba(255,255,255,0.08); --line2:rgba(255,255,255,0.15);
	--brand:#4c82ff; --brand-ink:#9cc0ff; --brand-soft:rgba(76,130,255,0.16);
	--pos:#34d39a; --neg:#f87171; --warn:#fbbf24; --warn-soft:rgba(251,191,36,0.12); --warn-line:rgba(251,191,36,0.34);
	--pos-soft:rgba(52,211,154,0.12); --pos-line:rgba(52,211,154,0.34); --neg-soft:rgba(248,113,113,0.12); --neg-line:rgba(248,113,113,0.34);
	--gold:#eab308; --gold2:#fde047; --silver:#cbd5e1; --silver2:#e2e8f0;
	--slate-soft:rgba(255,255,255,0.05);
	--shadow:0 2px 8px rgba(0,0,0,.4);
}
.zrate *, .zrate *::before, .zrate *::after{ box-sizing:border-box; }
.zrate button{ font-family:inherit; }
.zrate .is-hidden{ display:none !important; }
.zrate img{ max-width:100%; }
.zrate-price .v, .zrate-change, .zrate-sheet-delta, .zrate-sheet-price, .zrate-sheet-hl b{ direction:ltr; unicode-bidi:isolate; }

/* ================= topbar ================= */
/* Header + category tabs stick together as one opaque block: content never shows through (it used to, under a
   translucent background, which made the header look washed out on phones) and the tabs cannot drift under it. */
.zrate-top{ position:sticky; top:0; z-index:30; background:var(--bg); }
.zrate-topbar{ display:flex; align-items:center; gap:12px;
	padding:calc(11px + env(safe-area-inset-top)) clamp(12px,3vw,30px) 11px; background:var(--bg); border-bottom:1px solid var(--line); }
.zrate-brand{ display:flex; align-items:center; gap:10px; margin-inline-end:auto; text-decoration:none; min-width:0; }
.zrate-logo{ height:36px; width:auto; display:block; flex:0 0 auto; }
.zrate-brand-sub{ font-size:12px; color:var(--faint); font-weight:500; white-space:nowrap; }
.zrate-topbar-right{ display:flex; align-items:center; gap:8px; }

.zrate-unit{ display:inline-flex; padding:3px; border-radius:999px; background:var(--slate-soft); border:1px solid var(--line2); }
.zrate-unit-btn{ border:0; background:transparent; color:var(--muted); font-family:var(--font-number); font-weight:500;
	font-size:12.5px; padding:5px 12px; border-radius:999px; cursor:pointer; transition:.15s; white-space:nowrap; }
.zrate-unit-btn.is-active{ background:var(--brand); color:#fff; font-weight:600; }
.zrate[data-theme="dark"] .zrate-unit-btn.is-active{ color:#0a0a0b; }

.zrate-chip{ display:inline-flex; align-items:center; gap:6px; padding:6px 10px; border-radius:999px;
	font-size:12px; font-weight:500; border:1px solid var(--line2); background:var(--panel); color:var(--muted); white-space:nowrap; }
.zrate-live-fa{ font-family:var(--ui); font-weight:600; }
.zrate-chip .zrate-dot{ width:7px; height:7px; border-radius:50%; background:var(--faint); }
.zrate-chip[data-status="connected"]{ color:var(--pos); border-color:var(--pos-line); background:var(--pos-soft); }
.zrate-chip[data-status="connected"] .zrate-dot{ background:var(--pos); box-shadow:0 0 0 3px var(--pos-soft); animation:zrate-pulse 2s infinite; }
.zrate-chip[data-status="stale"]{ color:var(--warn); border-color:var(--warn-line); background:var(--warn-soft); }
.zrate-chip[data-status="stale"] .zrate-dot{ background:var(--warn); }
@keyframes zrate-pulse{ 0%,100%{ opacity:1 } 50%{ opacity:.45 } }

.zrate-icon-btn{ display:inline-flex; align-items:center; justify-content:center; width:36px; height:36px;
	border-radius:9px; border:1px solid var(--line2); background:var(--panel); color:var(--muted); cursor:pointer; transition:.15s; flex:0 0 auto; }
.zrate-icon-btn:hover{ color:var(--ink); border-color:var(--brand); }
.zrate-icon-btn svg{ width:17px; height:17px; }
.zrate-bell{ position:relative; }
.zrate-bell-dot{ position:absolute; top:7px; right:8px; width:7px; height:7px; border-radius:50%; background:var(--brand); box-shadow:0 0 0 2px var(--panel); }
.zrate-bell-dot[hidden]{ display:none; }
.zrate-sun{ display:none; } .zrate-moon{ display:inline-flex; }
.zrate[data-theme="dark"] .zrate-sun{ display:inline-flex; }
.zrate[data-theme="dark"] .zrate-moon{ display:none; }

/* ================= category switcher ================= */
.zrate-switcher{ display:flex; gap:6px; align-items:stretch;
	padding:11px clamp(12px,3vw,30px); background:var(--bg); border-bottom:1px solid var(--line); overflow-x:auto; scrollbar-width:none; }
.zrate-switcher::-webkit-scrollbar{ display:none; }
.zrate-seg{ display:inline-flex; align-items:center; gap:7px; padding:9px 14px; border-radius:11px;
	border:1px solid transparent; background:transparent; color:var(--ink2); font-size:13.5px; font-weight:500; cursor:pointer; white-space:nowrap; transition:.16s ease; }
.zrate-seg svg{ width:17px; height:17px; opacity:.85; flex:0 0 auto; }
.zrate-seg:hover{ color:var(--ink); background:var(--slate-soft); }
.zrate-seg.is-active{ background:var(--brand-soft); color:var(--brand); font-weight:600; }
.zrate-seg.is-active svg{ opacity:1; color:var(--brand); }
.zrate-seg-count{ font-family:var(--font-number); font-size:10.5px; font-weight:600; font-style:normal; padding:1px 6px; border-radius:7px; background:var(--slate-soft); color:var(--faint); }
.zrate-seg.is-active .zrate-seg-count{ background:var(--brand); color:#fff; }

/* ================= content ================= */
.zrate-content{ padding:clamp(16px,3vw,26px) clamp(12px,3vw,30px) 40px; max-width:1320px; margin:0 auto; width:100%; }
.zrate-empty{ padding:46px 20px; text-align:center; color:var(--faint); font-size:13.5px; }

.zrate-highlights{ display:grid; grid-template-columns:repeat(auto-fit,minmax(230px,1fr)); gap:13px; margin-bottom:20px; }
.zrate-grid{ display:grid; grid-template-columns:repeat(auto-fill,minmax(220px,1fr)); gap:12px; }

/* card (Chand-like): head(icon+title) / change / price ; star top-left */
.zrate-card, .zrate-kpi{ position:relative; background:var(--panel); border:1px solid var(--line); border-radius:16px;
	padding:14px 15px; cursor:pointer; box-shadow:var(--shadow); transition:border-color .15s, transform .15s;
	display:flex; flex-direction:column; gap:7px; overflow:hidden; }
.zrate-card:hover, .zrate-kpi:hover{ border-color:var(--brand); transform:translateY(-1px); }
.zrate-card-head{ display:flex; align-items:center; gap:10px; }
.zrate-id-text{ display:flex; flex-direction:column; min-width:0; flex:1 1 auto; }
.zrate-card-name{ font-size:14px; font-weight:600; color:var(--ink); line-height:1.25; overflow:hidden; display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; word-break:break-word; }
.zrate-card-sym{ font-family:var(--font-number); font-size:11px; font-weight:500; color:var(--faint); letter-spacing:.04em; }

.zrate-change{ font-family:var(--font-number); font-weight:600; font-size:12.5px; display:inline-flex; align-items:center; gap:3px; white-space:nowrap; }
.zrate-change.is-pos{ color:var(--pos); } .zrate-change.is-neg{ color:var(--neg); } .zrate-change.is-flat{ color:var(--muted); }

.zrate-price{ display:flex; align-items:baseline; gap:5px; min-width:0; }
.zrate-price .v{ font-family:var(--font-number); font-size:21px; font-weight:600; letter-spacing:-0.01em; color:var(--ink); line-height:1.1; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; min-width:0; }
.zrate-price .u{ font-size:10.5px; font-weight:500; color:var(--faint); font-family:var(--font-number); flex:0 0 auto; }

.zrate-kpi{ padding:16px 18px; }
.zrate-kpi .zrate-price .v{ font-size:28px; }

/* favorite star — top-left corner */
.zrate-fav{ position:absolute; top:8px; inset-inline-start:auto; left:8px; width:30px; height:30px; border:0; background:transparent; color:var(--faint);
	cursor:pointer; display:inline-flex; align-items:center; justify-content:center; border-radius:8px; -webkit-tap-highlight-color:transparent; transition:.15s; z-index:2; }
.zrate-fav:hover{ color:var(--star); background:var(--slate-soft); }
.zrate-fav svg{ width:18px; height:18px; fill:none; stroke:currentColor; stroke-width:1.8; }
.zrate-fav.is-on{ color:var(--star); }
.zrate-fav.is-on svg{ fill:currentColor; stroke:currentColor; }

/* avatar + monogram fallback (icons are self-hosted now) */
.zrate-ava{ position:relative; width:38px; height:38px; border-radius:50%; flex:0 0 auto; overflow:hidden;
	display:inline-flex; align-items:center; justify-content:center; background:var(--slate-soft); border:1px solid var(--line); background-size:cover; background-position:center; }
.zrate-ava img{ position:absolute; inset:0; width:100%; height:100%; object-fit:cover; }
.zrate-ava-mono{ font-family:var(--font-number); font-weight:600; font-size:11px; color:var(--ink2); text-transform:uppercase; }
.zrate-ava.metal, .zrate-ava.coin{ background:radial-gradient(120% 120% at 30% 25%, var(--gold2), var(--gold)); border:none; color:#5a3e05; }
.zrate-ava.silver{ background:radial-gradient(120% 120% at 30% 25%, var(--silver2), var(--silver)); border:none; color:#374151; }
.zrate-ava.metal svg, .zrate-ava.coin svg, .zrate-ava.silver svg{ width:20px; height:20px; position:relative; }

/* flag background — off by default (only if root has .zrate-flagbg) */
.zrate-flag-bg{ display:none; }
.zrate-flagbg .zrate-flag-bg{ display:block; position:absolute; z-index:0; top:50%; left:50%; width:150%; height:150%;
	transform:translate(-50%,-50%) rotate(-43deg); background-size:cover; background-position:center; opacity:.07; pointer-events:none; }

.zrate-foot{ margin-top:22px; padding-top:4px; font-family:var(--ui); font-size:11px; color:var(--faint); display:flex; gap:6px 18px; flex-wrap:wrap; align-items:center; justify-content:center; }
.zrate-foot-link{ color:var(--muted); text-decoration:none; font:inherit; font-weight:500; display:inline-flex; align-items:center; gap:5px; background:none; border:0; padding:4px 0; cursor:pointer; }
.zrate-foot-link[hidden]{ display:none; }
.zrate-foot-link svg{ width:1.25em; height:1.25em; flex:0 0 auto; color:var(--brand); }
.zrate-foot-link span{ unicode-bidi:isolate; }
.zrate-foot-link:hover{ color:var(--ink); }
.zrate-foot-time{ font-family:var(--ui); }

/* ================= detail sheet ================= */
.zrate-sheet-wrap{ position:fixed; inset:0; z-index:60; display:flex; align-items:flex-end; justify-content:center; }
.zrate-sheet-wrap[hidden]{ display:none; }
.zrate-sheet-backdrop{ position:absolute; inset:0; background:rgba(0,0,0,.45); backdrop-filter:blur(3px); -webkit-backdrop-filter:blur(3px); animation:zrate-fade .32s ease; }
/* matte frosted glass sheet */
.zrate-sheet{ position:relative; width:100%; max-width:560px; color:var(--ink);
	background:rgba(255,255,255,0.80); backdrop-filter:blur(26px) saturate(1.7); -webkit-backdrop-filter:blur(26px) saturate(1.7);
	border-radius:24px 24px 0 0; border:1px solid rgba(255,255,255,0.35); border-bottom:none;
	padding:10px clamp(18px,4vw,26px) calc(30px + env(safe-area-inset-bottom)); box-shadow:0 -16px 50px rgba(0,0,0,.28);
	animation:zrate-rise .42s cubic-bezier(.16,1,.3,1); max-height:92vh; overflow-y:auto; -webkit-overflow-scrolling:touch; }
.zrate[data-theme="dark"] .zrate-sheet{ background:rgba(22,22,24,0.74); border-color:rgba(255,255,255,0.10); }
@media (min-width:620px){ .zrate-sheet-wrap{ align-items:center; } .zrate-sheet{ border-radius:24px; border-bottom:1px solid rgba(255,255,255,0.2); } }
@keyframes zrate-rise{ from{ transform:translateY(46px); opacity:0; filter:blur(4px) } to{ transform:translateY(0); opacity:1; filter:blur(0) } }
@keyframes zrate-fade{ from{ opacity:0 } to{ opacity:1 } }
@media (prefers-reduced-motion:reduce){ .zrate-sheet{ animation:zrate-fade .2s ease; } }
.zrate-sheet-bar{ display:flex; align-items:center; justify-content:flex-end; height:34px; margin-bottom:4px; }
.zrate-sheet-x{ width:32px; height:32px; border-radius:9px; border:1px solid var(--line2); background:var(--panel2); color:var(--muted); cursor:pointer; display:inline-flex; align-items:center; justify-content:center; }
.zrate-sheet-x:hover{ color:var(--ink); border-color:var(--brand); }
.zrate-sheet-x svg{ width:16px; height:16px; }
.zrate-sheet-head{ display:flex; align-items:center; gap:12px; margin-bottom:14px; }
.zrate-sheet-head .zrate-ava{ width:46px; height:46px; }
.zrate-sheet-head .zrate-ava .zrate-ava-mono{ font-size:14px; }
.zrate-sheet-idwrap{ min-width:0; flex:1; }
.zrate-sheet-name{ font-size:18px; font-weight:700; color:var(--ink); }
.zrate-sheet-sym{ font-family:var(--font-number); font-size:12px; color:var(--faint); font-weight:500; }
.zrate-sheet-delta{ font-family:var(--font-number); font-size:13.5px; font-weight:600; white-space:nowrap; flex:0 0 auto; display:inline-flex; align-items:center; gap:3px; }
.zrate-sheet-delta.is-pos{ color:var(--pos); } .zrate-sheet-delta.is-neg{ color:var(--neg); } .zrate-sheet-delta.is-flat{ color:var(--muted); }
.zrate-sheet-prices{ display:flex; align-items:baseline; gap:8px; }
.zrate-sheet-price{ font-family:var(--font-number); font-size:30px; font-weight:700; letter-spacing:-0.01em; color:var(--ink); }
.zrate-sheet-price small{ font-size:13px; font-weight:500; color:var(--faint); margin-inline-start:6px; font-family:var(--ui); }
.zrate-sheet-usd{ display:none; }
.zrate-sheet-hl{ display:flex; gap:18px; margin:12px 0 4px; font-family:var(--font-number); font-size:12px; color:var(--muted); flex-wrap:wrap; }
.zrate-sheet-hl b{ color:var(--ink); font-weight:600; }
.zrate-tfs{ display:flex; gap:6px; margin:14px 0 8px; }
.zrate-tf{ font-family:var(--font-number); font-size:12.5px; font-weight:600; padding:6px 14px; border-radius:9px; border:1px solid var(--line2); background:var(--panel); color:var(--muted); cursor:pointer; transition:.15s; }
.zrate-tf:hover{ color:var(--ink); border-color:var(--brand); }
.zrate-tf.is-active{ background:var(--brand-soft); color:var(--brand); border-color:transparent; }

/* full-bleed chart (fills left & bottom, uniform stroke, no distorted text) */
.zrate-sheet-chart{ height:210px; margin-top:4px; position:relative; }
.zrate-sheet-chart svg{ width:100%; height:100%; display:block; }
.zrate-sheet-chart .zrate-grid-line{ stroke:var(--line); stroke-dasharray:3 4; vector-effect:non-scaling-stroke; }
.zrate-sheet-loading{ display:flex; align-items:center; justify-content:center; height:210px; color:var(--faint); font-size:13px; }

.zrate-sheet-accent{ position:absolute; left:0; bottom:0; width:72px; height:5px; border-radius:0 8px 0 0; background:linear-gradient(90deg, var(--brand), #6f97ff); }

@media (max-width:560px){
	.zrate-brand-sub{ display:none; }
	.zrate-grid{ grid-template-columns:repeat(2,1fr); gap:10px; }
	.zrate-highlights{ grid-template-columns:1fr 1fr; gap:10px; }
	.zrate-card{ padding:12px; }
	.zrate-price .v{ font-size:19px; }
	.zrate-kpi .zrate-price .v{ font-size:23px; }
	.zrate-seg{ padding:8px 12px; font-size:12.5px; }
	.zrate-sheet-price{ font-size:25px; }
	.zrate-fav{ top:6px; left:6px; width:28px; height:28px; }
}

@keyframes zrate-flash-up{ 0%{ background:var(--pos-soft);} 100%{ background:var(--panel); } }
@keyframes zrate-flash-down{ 0%{ background:var(--neg-soft);} 100%{ background:var(--panel); } }
.zrate-card.flash-up{ animation:zrate-flash-up 1s ease-out; }
.zrate-card.flash-down{ animation:zrate-flash-down 1s ease-out; }

/* ---------- favorites: hold-and-drag reordering ---------- */
#zrate-grid-fav .zrate-card{ -webkit-user-select:none; user-select:none; -webkit-tap-highlight-color:transparent; }
#zrate-grid-fav .zrate-card.zrate-dragging{ box-shadow:0 16px 36px rgba(0,0,0,.45); opacity:.97; transition:none; cursor:grabbing; }
.zrate-ph{ border:2px dashed var(--brand); border-radius:16px; background:color-mix(in srgb, var(--brand) 8%, transparent); }
@supports not (background: color-mix(in srgb, red, blue)){ .zrate-ph{ background:rgba(76,130,255,.08); } }

/* ================= price alerts sheet (also the Add to Home Screen sheet) ================= */
/* solid, not the frosted glass of the detail sheet: a form and notices must not show the cards through */
.zrate .zrate-sheet.zrate-al, .zrate[data-theme="dark"] .zrate-sheet.zrate-al{ background:var(--bg); -webkit-backdrop-filter:none; backdrop-filter:none; border-color:var(--line2);
	animation:zrate-up .18s ease-out; }   /* a short slide only: no fade or blur while it opens */
@keyframes zrate-up{ from{ transform:translateY(24px) } to{ transform:none } }
@media (prefers-reduced-motion:reduce){ .zrate .zrate-sheet.zrate-al{ animation:none; } }
.zrate-al-bar{ justify-content:space-between; }
.zrate-sheet-bar .zrate-sheet-x + .zrate-sheet-x{ margin-inline-start:8px; }
.zrate-al-title{ margin:0; font-size:17px; font-weight:700; color:var(--ink); }
.zrate-al-notice{ display:flex; flex-direction:column; align-items:flex-start; gap:10px; padding:12px 14px; margin-bottom:12px; border-radius:12px;
	background:var(--brand-soft); color:var(--ink2); font-size:13px; line-height:1.75; }
.zrate-al-notice[hidden]{ display:none; }
.zrate-al-notice.is-warn{ background:var(--warn-soft); }
.zrate-al-notice p{ margin:0; }
.zrate-al-btn, .zrate-al-save{ height:42px; padding:0 18px; border:0; border-radius:11px; background:var(--brand); color:#fff; font:inherit; font-size:14px; font-weight:600; cursor:pointer; }
.zrate[data-theme="dark"] .zrate-al-btn, .zrate[data-theme="dark"] .zrate-al-save{ color:#0a0a0b; }
.zrate-al-btn[hidden]{ display:none; }
.zrate-al-btn:disabled, .zrate-al-save:disabled{ cursor:default; background:var(--line2); color:var(--muted); }
.zrate-al-form fieldset{ margin:0; padding:14px; min-width:0; border:1px solid var(--line); border-radius:14px; background:var(--panel); display:flex; flex-direction:column; gap:12px; }
.zrate-al-form.is-locked fieldset{ background:var(--panel2); }
.zrate-al-form.is-locked .zrate-al-save{ background:var(--line2); color:var(--muted); }
.zrate-al-formhead{ display:flex; align-items:center; justify-content:space-between; font-size:14px; font-weight:600; color:var(--ink); }
.zrate-al-link{ border:0; background:none; padding:0; font:inherit; font-size:12.5px; font-weight:500; color:var(--brand); cursor:pointer; }
.zrate-al-link[hidden]{ display:none; }
.zrate-al-field{ display:flex; flex-direction:column; gap:6px; min-width:0; font-size:12px; font-weight:500; color:var(--muted); }
.zrate-al-field select, .zrate-al-field input{ width:100%; height:42px; padding:0 12px; border:1px solid var(--line2); border-radius:10px; background:var(--panel2);
	color:var(--ink); font-family:var(--ui); font-size:16px; outline:none; -webkit-appearance:none; appearance:none; }
.zrate-al-field input{ font-family:var(--font-number); font-weight:600; text-align:left; }
.zrate-al-field select:focus, .zrate-al-field input:focus{ border-color:var(--brand); }
.zrate-al-select{ position:relative; display:block; }
.zrate-al-select select{ padding-inline-start:12px; padding-inline-end:34px; }
.zrate-al-select::after{ content:""; position:absolute; top:50%; left:14px; width:7px; height:7px; margin-top:-5px; border-right:2px solid var(--faint); border-bottom:2px solid var(--faint); transform:rotate(45deg); pointer-events:none; }
.zrate-al-now{ margin-top:-4px; font-size:12px; color:var(--muted); }
.zrate-al-now b{ font-family:var(--font-number); font-weight:600; color:var(--ink); unicode-bidi:isolate; }
.zrate-al-row{ display:flex; align-items:flex-end; gap:10px; }
.zrate-al-grow{ flex:1 1 auto; }
.zrate-al-seg{ height:42px; align-items:center; }
.zrate-al-seg .zrate-unit-btn{ height:34px; }
.zrate-al-dirs{ display:grid; grid-template-columns:1fr 1fr; gap:8px; }
.zrate-al-dir{ display:flex; align-items:center; justify-content:center; gap:6px; min-height:42px; padding:6px 8px; border:1px solid var(--line2); border-radius:10px;
	background:var(--panel2); color:var(--ink2); font:inherit; font-size:12.5px; font-weight:500; line-height:1.3; cursor:pointer; }
.zrate-al-dir svg{ width:16px; height:16px; flex:0 0 auto; }
.zrate-al-dir.is-active[data-v="above"]{ border-color:var(--pos-line); background:var(--pos-soft); color:var(--pos); font-weight:600; }
.zrate-al-dir.is-active[data-v="below"]{ border-color:var(--neg-line); background:var(--neg-soft); color:var(--neg); font-weight:600; }
.zrate-al-msg{ font-size:12.5px; line-height:1.6; }
.zrate-al-msg:empty{ display:none; }
.zrate-al-msg.is-err{ color:var(--neg); } .zrate-al-msg.is-ok{ color:var(--pos); }
.zrate-al-tabs{ margin:16px 0 4px; }
.zrate-al-tabs .zrate-tf{ font-family:var(--ui); }
.zrate-al-tabs em{ font-style:normal; font-family:var(--font-number); margin-inline-start:4px; }
.zrate-al-list{ list-style:none; margin:0; padding:0; }
.zrate-al-item{ display:flex; align-items:center; gap:10px; padding:10px 0; border-bottom:1px solid var(--line); }
.zrate-al-item:last-child{ border-bottom:0; }
.zrate-al-item .zrate-ava{ width:32px; height:32px; }
.zrate-al-item .zrate-ava .zrate-ava-mono{ font-size:9.5px; }
.zrate-al-info{ flex:1 1 auto; min-width:0; display:flex; flex-direction:column; gap:1px; }
.zrate-al-cond{ display:block; direction:ltr; unicode-bidi:isolate; text-align:right; font-family:var(--font-number); font-size:14px; font-weight:600; color:var(--ink); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.zrate-al-sub{ font-size:11.5px; color:var(--faint); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.zrate-al-sub b{ font-family:var(--font-number); font-weight:500; color:var(--muted); unicode-bidi:isolate; }
.zrate-al-item.is-off .zrate-al-cond{ color:var(--faint); }
.zrate-switch{ position:relative; flex:0 0 auto; width:38px; height:22px; padding:0; border:0; border-radius:999px; background:var(--line2); cursor:pointer; transition:background .15s; }
.zrate-switch::after{ content:""; position:absolute; top:3px; right:3px; width:16px; height:16px; border-radius:50%; background:#fff; transition:transform .15s; }
.zrate-switch[aria-checked="true"]{ background:var(--brand); }
.zrate-switch[aria-checked="true"]::after{ transform:translateX(-16px); }
.zrate-al-ico{ flex:0 0 auto; display:inline-flex; align-items:center; justify-content:center; width:32px; height:32px; padding:0; border:0; border-radius:9px; background:transparent; color:var(--muted); font:inherit; cursor:pointer; }
.zrate-al-ico svg{ width:16px; height:16px; }
.zrate-al-ico:hover{ color:var(--ink); background:var(--slate-soft); }
.zrate-al-ico.is-confirm{ width:auto; padding:0 10px; background:var(--neg); color:#fff; font-size:12px; font-weight:600; }
.zrate-al-empty{ padding:18px 0; text-align:center; font-size:12.5px; color:var(--faint); }
.zrate-al-details{ margin-top:14px; padding-top:10px; border-top:1px solid var(--line); font-size:12px; color:var(--muted); }
.zrate-al-details summary{ cursor:pointer; list-style:none; padding:4px 0; font-weight:500; }
.zrate-al-details summary::-webkit-details-marker{ display:none; }
.zrate-al-details summary::after{ content:""; display:inline-block; width:6px; height:6px; margin-inline-start:8px; margin-bottom:2px; border-right:1.5px solid currentColor; border-bottom:1.5px solid currentColor; transform:rotate(45deg); }
.zrate-al-details[open] summary::after{ transform:rotate(-135deg); margin-bottom:-1px; }
.zrate-al-details dl{ margin:8px 0 0; }
.zrate-al-details dl div{ display:flex; justify-content:space-between; gap:12px; padding:5px 0; }
.zrate-al-details dt{ color:var(--faint); }
.zrate-al-details dd{ margin:0; color:var(--ink2); font-family:var(--font-number); }
.zrate-al-details a, .zrate-al-sub a{ color:var(--brand); text-decoration:none; }
.zrate-al-details p{ margin:8px 0 0; font-size:11px; color:var(--faint); line-height:1.7; }
.zrate-al-steps{ margin:4px 0 12px; padding-inline-start:20px; font-size:13.5px; line-height:2; color:var(--ink2); }
.zrate-al-steps[hidden]{ display:none; }
.zrate-inline-ico{ width:17px; height:17px; vertical-align:-3px; color:var(--brand); }
.zrate-al > .zrate-al-sub{ display:block; white-space:normal; font-size:12px; line-height:1.8; }
@media (max-width:360px){
	.zrate-topbar{ gap:8px; }
	.zrate-topbar-right{ gap:6px; }
	.zrate-chip{ padding:6px 8px; }
	.zrate-chip .zrate-live-fa{ display:none; }
	.zrate-al-row{ flex-wrap:wrap; }
	.zrate-al-item{ gap:8px; }
	.zrate-al-item .zrate-ava{ display:none; }
	.zrate-al-cond{ font-size:13px; }
	.zrate-al-ico{ width:28px; }
}
