/* DubiLook™ — shell.css (LR-16 Mini App v4, 27 Oct 2026): the one-page shell on top of the design system
   v7 tokens and components (tokens.css / components.css stay byte-identical to the v7 export). What lives
   here: the stage and the screens that slide, the opening video, the fallback Main / Secondary bar, the
   light theme (second token set, demo v4 `.phone[data-theme="light"]`), the size floor (body 17 px, titles
   28 px, tap targets 48 px, main buttons 54 px) and the v4 screen pieces the demo draws (credential hero,
   keypad tiles, big rows, footer, post list, step bar, rules with Why?, level ladder, history rows). */

/* ---------- light theme: the second token set (gold for text = the darker #94750f) ---------- */
:root[data-theme="light"] {
  --bg-000: #f5f2ea; --bg-100: #ffffff; --bg-200: #efebe1; --bg-300: #e5e0d4;
  --line-100: #e3ded2; --line-200: #8a877f;
  --ink: #16181b; --ink-muted: #4f545b; --ink-faint: #6b7077;
  --gold: #94750f; --gold-hover: #a8861a; --gold-press: #7d630c; --on-gold: #ffffff;
  --gold-soft: rgba(148,117,15,0.10); --gold-line: rgba(148,117,15,0.40);
  --state-success: #1f8a4c; --state-warning: #a86a00; --state-info: #2f6fd6; --state-danger: #c0392b;
  --danger-soft: rgba(192,57,43,0.10);
  --scrim: rgba(40,36,24,0.45);
  --shadow-1: 0 1px 2px rgba(30,25,10,0.06); --shadow-2: 0 8px 24px rgba(30,25,10,0.14); --shadow-3: 0 -12px 40px rgba(30,25,10,0.18);
  --shadow-gold: 0 6px 18px rgba(148,117,15,0.25);
  --tg-post: #effdde; --tg-post-ink: #000; --tg-post-who: #3a8d2f;
}
:root { --tg-post: #2b5278; --tg-post-ink: #fff; --tg-post-who: #8fd0ff; --tabbar-h: 0px; --tap-min: 48px; }
:root.sh-themeing, :root.sh-themeing * { transition: background-color .4s ease, color .4s ease, border-color .4s ease !important; }

/* ---------- the shell: nothing scrolls but the screen ---------- */
html, body { height: 100%; overflow: clip; }
body.dl-app { font-size: 17px; line-height: 26px; }
#dl-stage { position: fixed; inset: 0; overflow: hidden; background: var(--bg-000); isolation: isolate; }
.dl-screen { position: absolute; inset: 0; overflow-y: auto; overflow-x: hidden; -webkit-overflow-scrolling: touch; overscroll-behavior: contain;
  padding: 10px 16px calc(28px + env(safe-area-inset-bottom)); max-width: 520px; margin: 0 auto; will-change: transform, opacity; scrollbar-width: none; background: var(--bg-000); }
.dl-screen::-webkit-scrollbar { display: none; }
.dl-screen.is-leaving { pointer-events: none; }
body.has-mainbar .dl-screen { padding-bottom: calc(150px + env(safe-area-inset-bottom)); }
body.has-mainbar.has-second .dl-screen { padding-bottom: calc(210px + env(safe-area-inset-bottom)); }
body.has-mainbar { --tabbar-h: 90px; }
body.has-mainbar.has-second { --tabbar-h: 150px; }
.sh-busy { position: absolute; inset: 0; display: grid; place-items: center; z-index: 5; pointer-events: none; opacity: 0; transition: opacity .2s; }
.sh-busy.is-on { opacity: 1; }
.sh-busy i { width: 34px; height: 34px; border-radius: 50%; border: 3px solid var(--line-100); border-top-color: var(--gold); animation: sh-spin .9s linear infinite; }
@keyframes sh-spin { to { transform: rotate(360deg); } }
.sh-error { padding: 48px 16px; text-align: center; }
.sh-error .dl-icon { width: 36px; height: 36px; color: var(--state-warning); }
.sh-error h2 { margin: 12px 0 6px; font: 800 22px/28px var(--font-sans); }
.sh-error p { margin: 0 0 16px; color: var(--ink-muted); }

/* the fallback bar: a Telegram client without a MainButton (browser preview, very old apps) or a
   second action on a client older than Bot API 7.10 */
.sh-mainbar { position: fixed; left: 0; right: 0; bottom: 0; z-index: var(--z-tabbar); padding: 10px 16px calc(12px + env(safe-area-inset-bottom)); background: var(--bg-100); border-top: 1px solid var(--line-100); display: flex; flex-direction: column; gap: 8px; max-width: 520px; margin: 0 auto; }
.sh-mainbar[hidden] { display: none; }
.sh-mainbar button { width: 100%; min-height: 54px; border: 0; border-radius: 14px; background: var(--gold); color: var(--on-gold); font: 800 17px/1 var(--font-sans); cursor: pointer; transition: transform .12s, background-color .12s; }
.sh-mainbar button:active { transform: scale(.98); background: var(--gold-press); }
.sh-mainbar button.sh-second { background: transparent; color: var(--gold); border: 1.5px solid var(--gold-line); }
.sh-mainbar button.sh-second:active { background: var(--gold-soft); }
.sh-mainbar button[hidden] { display: none; }

/* ---------- size floor ---------- */
.dl-app .dl-btn { min-height: 48px; font-size: 17px; }
.dl-app .dl-btn--sm { min-height: 48px; font-size: 16px; }
.dl-app .dl-btn--primary.dl-btn--block, .dl-app .dl-btn--secondary.dl-btn--block { min-height: 54px; font-size: 17px; }
.dl-app .dl-input { min-height: 54px; font-size: 17px; }
.dl-app textarea.dl-input { min-height: 120px; line-height: 26px; }
.dl-app .dl-section-title h2, .dl-app .dl-pagehead__title { font-size: 28px; line-height: 34px; }
.dl-app .dl-chips-radio label span { min-height: 44px; display: inline-flex; align-items: center; }
.dl-app .dl-note, .dl-app .dl-muted, .dl-app .dl-option__desc { font-size: 15px; line-height: 22px; }
.dl-app .dl-dest a, .dl-app .dl-dest button { min-height: 60px; font-size: 17px; }
.dl-app .dl-sheet__title { font-size: 21px; line-height: 28px; }
.dl-app .dl-sheet__text { font-size: 16px; line-height: 25px; }

/* ---------- opening: the owner's logo motion, on screen from the first paint ---------- */
#dl-intro { position: fixed; inset: 0; z-index: 80; background: #000; display: grid; place-items: center; overflow: hidden; }
:root[data-theme="light"] #dl-intro { background: #fff; }
#dl-intro video, #dl-intro img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
#dl-intro video { opacity: 0; transition: opacity .25s; }
#dl-intro.is-playing video { opacity: 1; }
#dl-intro .sh-intro__skip { position: absolute; bottom: calc(28px + env(safe-area-inset-bottom)); left: 0; right: 0; text-align: center; font: 600 13px/16px var(--font-sans); color: rgba(255,255,255,.55); z-index: 2; }
:root[data-theme="light"] #dl-intro .sh-intro__skip { color: rgba(0,0,0,.45); }
#dl-intro .sh-intro__msg { position: absolute; left: 16px; right: 16px; bottom: calc(72px + env(safe-area-inset-bottom)); z-index: 3; text-align: center; color: #f5f4f0; font: 500 16px/24px var(--font-sans); opacity: 0; transition: opacity .3s; }
#dl-intro.has-msg .sh-intro__msg { opacity: 1; }
#dl-intro .sh-intro__msg a { color: #c9a227; }
#dl-intro.is-leaving { transition: opacity 450ms var(--ease-out), transform 450ms var(--ease-out); opacity: 0; transform: scale(1.03); pointer-events: none; }
#dl-intro[hidden] { display: none; }
#dl-stage.is-enter .dl-screen.is-current { animation: sh-app-in 520ms var(--ease-out) both; }
@keyframes sh-app-in { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
.sh-denied { position: fixed; inset: 0; display: grid; place-items: center; padding: 24px; text-align: center; color: var(--ink); }
.sh-denied h1 { color: var(--gold); font: 800 22px/28px var(--font-sans); margin: 0 0 8px; }
.sh-denied a { color: var(--gold); }

/* ---------- shared v4 type ---------- */
.sh-h1 { margin: 4px 0 16px; font: 800 28px/34px var(--font-sans); letter-spacing: -.01em; color: var(--ink); }
.sh-h2 { margin: 24px 0 10px; font: 700 19px/26px var(--font-sans); color: var(--ink); }
.sh-sub { margin: -8px 0 18px; font: 500 16px/24px var(--font-sans); color: var(--ink-muted); }
.sh-p { font: 500 17px/27px var(--font-sans); color: var(--ink); margin: 0 0 12px; }
.sh-sect { margin: 22px 2px 10px; font: 700 15px/20px var(--font-sans); color: var(--ink-muted); }
[dir="rtl"] .sh-h1, [dir="rtl"] .sh-h2, [dir="rtl"] .sh-p, [dir="rtl"] .sh-sub { font-family: var(--font-fa); }
.sh-press { transition: transform .14s var(--ease-out), background-color .14s, border-color .14s; }
.sh-press:active { transform: scale(.97); }
.sh-muted { color: var(--ink-muted); }

/* credential hero (Home, Level) */
.sh-hero { position: relative; text-align: center; padding: 20px 16px 18px; border-radius: 22px; background: radial-gradient(120% 80% at 50% 0%, var(--bg-300) 0%, var(--bg-100) 60%); border: 1px solid var(--line-100); }
:root[data-theme="light"] .sh-hero { background: radial-gradient(120% 80% at 50% 0%, #fbf6e6 0%, #ffffff 60%); }
/* LR-17 item 3: Settings on Home (opens the app menu with Appearance), a 48 px target in the hero's corner */
.sh-hero__settings { position: absolute; top: 10px; right: 10px; width: var(--tap-min); height: var(--tap-min); border-radius: 50%; border: 1.5px solid var(--line-100); background: var(--bg-200); color: var(--gold); display: grid; place-items: center; cursor: pointer; }
.sh-hero__settings svg { width: 20px; height: 20px; }
.sh-hero__plq { width: 148px; height: 148px; object-fit: contain; display: block; margin: 0 auto -4px; filter: drop-shadow(0 10px 24px rgba(60,110,220,.35)); }
.sh-hero__av { width: 72px; height: 72px; border-radius: 50%; margin: 6px auto 4px; background: var(--bg-300); display: grid; place-items: center; font: 800 26px/1 var(--font-sans); color: var(--gold); object-fit: cover; }
.sh-hero__name { margin: 6px 0 0; font: 800 24px/30px var(--font-sans); color: var(--ink); }
.sh-hero__lvl { margin: 2px 0 14px; font: 700 17px/22px var(--font-sans); color: var(--gold); }
.sh-hero .dl-labels { justify-content: center; }
.sh-hero__code { margin: 14px 0 0; font: 600 14px/18px var(--font-sans); color: var(--ink-muted); }
.sh-hero__code span { color: var(--ink); font-variant-numeric: tabular-nums; letter-spacing: .04em; }
.sh-look { display: flex; align-items: flex-start; gap: 10px; margin-top: 14px; padding: 12px 14px; border-radius: 14px; background: var(--bg-200); text-align: start; font: 500 15px/22px var(--font-sans); color: var(--ink-muted); }
.sh-look .dl-icon { color: var(--gold); width: 20px; height: 20px; margin-top: 1px; flex: none; }

/* "Your next steps" card under the hero */
.sh-next { display: flex; align-items: center; gap: 14px; width: 100%; margin-top: 12px; padding: 12px 16px; border-radius: 18px; border: 1.5px dashed var(--gold-line); background: transparent; text-align: start; cursor: pointer; color: var(--ink); font: inherit; text-decoration: none; }
.sh-next b { display: block; font: 700 17px/22px var(--font-sans); }
.sh-next small { display: block; font: 500 15px/21px var(--font-sans); color: var(--ink-muted); }

/* keypad tiles */
.sh-pad { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 12px; }
.sh-tile { position: relative; min-height: 132px; border-radius: 20px; border: 1px solid var(--line-100); background: var(--bg-100); display: flex; flex-direction: column; justify-content: space-between; align-items: flex-start; padding: 16px; cursor: pointer; text-align: start; color: var(--ink); text-decoration: none; font: inherit; box-shadow: var(--shadow-1); }
.sh-tile .dl-icon { width: 30px; height: 30px; color: var(--gold); flex: none; }
.sh-tile b { display: block; font: 800 19px/24px var(--font-sans); }
.sh-tile small { display: block; margin-top: 2px; font: 500 14px/19px var(--font-sans); color: var(--ink-muted); }
.sh-tile--main { grid-column: 1 / -1; min-height: 112px; justify-content: flex-start; background: linear-gradient(135deg, #2a2412 0%, var(--bg-100) 70%); border-color: var(--gold-line); flex-direction: row; align-items: center; gap: 16px; }
:root[data-theme="light"] .sh-tile--main { background: linear-gradient(135deg, #f6edcf 0%, #ffffff 70%); }
.sh-tile--main .dl-icon { width: 40px; height: 40px; }
.sh-tile .sh-pill { position: absolute; top: 12px; right: 12px; }
[dir="rtl"] .sh-tile .sh-pill { right: auto; left: 12px; }
.sh-tile:active { background: var(--bg-200); }
.sh-pill { min-width: 28px; height: 28px; padding: 0 9px; border-radius: 14px; background: var(--gold); color: var(--on-gold); font: 800 15px/28px var(--font-sans); text-align: center; flex: none; }

/* big rows (hub lists, guides, menus) */
.sh-rows { list-style: none; margin: 0; padding: 0; border-radius: 18px; background: var(--bg-100); border: 1px solid var(--line-100); overflow: hidden; box-shadow: var(--shadow-1); }
.sh-row { display: flex; align-items: center; gap: 14px; width: 100%; min-height: 76px; padding: 12px 16px; border: 0; background: none; cursor: pointer; text-align: start; border-top: 1px solid var(--line-100); color: var(--ink); text-decoration: none; font: inherit; }
.sh-rows li:first-child .sh-row { border-top: 0; }
.sh-row:active { background: var(--bg-200); }
.sh-row__ic { width: 46px; height: 46px; border-radius: 14px; background: var(--gold-soft); color: var(--gold); display: grid; place-items: center; flex: none; }
.sh-row__ic .dl-icon { width: 24px; height: 24px; }
.sh-row__t { flex: 1; min-width: 0; }
.sh-row__t b { display: block; font: 700 18px/24px var(--font-sans); }
.sh-row__t small { display: block; font: 500 15px/21px var(--font-sans); color: var(--ink-muted); }
.sh-row__go { color: var(--ink-faint); flex: none; }
[dir="rtl"] .sh-row__go .dl-icon { transform: scaleX(-1); }
.sh-row .sh-switch { flex: none; }

/* switch (Show my phone, options) */
.sh-switch { width: 52px; height: 32px; border-radius: 16px; background: var(--bg-300); border: 1.5px solid var(--line-200); position: relative; transition: background-color .2s, border-color .2s; display: inline-block; }
.sh-switch i { position: absolute; left: 4px; top: 4px; width: 21px; height: 21px; border-radius: 50%; background: var(--ink-muted); transition: transform .25s var(--ease-spring), background-color .2s; }
.sh-switch.is-on { background: var(--gold); border-color: var(--gold); }
.sh-switch.is-on i { transform: translateX(20px); background: var(--on-gold); }

/* footer, the signature at the end of Home */
.sh-foot { margin: 28px -16px calc(-28px - env(safe-area-inset-bottom)); padding: 28px 20px calc(28px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line-100); background: var(--bg-100); text-align: center; }
body.has-mainbar .sh-foot { margin-bottom: 0; }
.sh-foot__logo { height: 44px; width: auto; display: block; margin: 0 auto; }
.sh-logo--light { display: none; }
:root[data-theme="light"] .sh-logo--dark { display: none; }
:root[data-theme="light"] .sh-logo--light { display: block; }
.sh-foot__tag { margin: 12px auto 0; max-width: 300px; font: 500 15px/22px var(--font-sans); color: var(--ink-muted); }
.sh-foot__soc { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin: 18px 0 6px; }
.sh-foot__soc a { width: 44px; height: 44px; flex: none; border-radius: 50%; display: grid; place-items: center; background: var(--bg-200); border: 1px solid var(--line-100); color: var(--gold); }
.sh-foot__soc .dl-icon { width: 20px; height: 20px; }
.sh-foot__links { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 6px; margin-top: 12px; }
.sh-foot__links a, .sh-foot__links button { min-height: 44px; padding: 0 10px; border: 0; background: none; font: 700 15px/44px var(--font-sans); color: var(--ink); cursor: pointer; text-decoration: none; }
.sh-foot__mail { margin: 2px 0 0; font: 600 15px/22px var(--font-sans); color: var(--gold); }
.sh-foot__note { margin: 14px auto 0; max-width: 280px; font: 500 13px/19px var(--font-sans); color: var(--ink-faint); }
.sh-foot__c { margin: 8px 0 0; font: 600 13px/18px var(--font-sans); color: var(--ink-faint); }

/* tools row + chips (My posts, Listings) */
.sh-tools { display: flex; gap: 8px; align-items: center; margin-bottom: 12px; }
.sh-tools .dl-search__box { flex: 1; margin: 0; min-height: 52px; }
.sh-sq { width: 52px; height: 52px; border-radius: 14px; border: 1.5px solid var(--line-100); background: var(--bg-100); display: grid; place-items: center; cursor: pointer; flex: none; color: var(--ink); position: relative; }
.sh-sq[aria-pressed="true"] { border-color: var(--gold); color: var(--gold); }
.sh-fbadge { position: absolute; top: -6px; right: -6px; min-width: 22px; height: 22px; border-radius: 11px; background: var(--gold); color: var(--on-gold); font: 800 12px/22px var(--font-sans); text-align: center; }
.sh-chips { display: flex; gap: 8px; overflow-x: auto; margin: 0 -16px 14px; padding: 0 16px; scrollbar-width: none; }
.sh-chips::-webkit-scrollbar { display: none; }
.sh-chips--wrap { flex-wrap: wrap; overflow: visible; margin: 0 0 10px; padding: 0; }
.sh-chip { flex: none; display: inline-flex; align-items: center; gap: 6px; height: 44px; padding: 0 16px; border-radius: 22px; border: 1.5px solid var(--line-100); background: var(--bg-100); color: var(--ink); font: 700 15px/1 var(--font-sans); cursor: pointer; white-space: nowrap; text-decoration: none; }
.sh-chip .dl-icon { width: 18px; height: 18px; }
.sh-chip[aria-pressed="true"], .sh-chip[aria-current="page"] { background: var(--gold); border-color: var(--gold); color: var(--on-gold); }

/* my posts: list / grid */
.sh-plist { display: flex; flex-direction: column; gap: 10px; }
.sh-plist.is-grid { display: grid; grid-template-columns: 1fr 1fr; }
.sh-pc { display: flex; gap: 12px; align-items: center; width: 100%; padding: 10px; border-radius: 16px; border: 1px solid var(--line-100); background: var(--bg-100); cursor: pointer; text-align: start; color: var(--ink); text-decoration: none; font: inherit; box-shadow: var(--shadow-1); }
.sh-pc:active { background: var(--bg-200); }
.sh-pc__img { width: 84px; height: 84px; border-radius: 12px; flex: none; position: relative; overflow: hidden; background: var(--bg-300) center/cover no-repeat; display: grid; place-items: center; color: var(--ink-faint); }
.sh-pc__t { flex: 1; min-width: 0; }
.sh-pc__num { font: 700 13px/18px var(--font-sans); color: var(--ink-faint); font-variant-numeric: tabular-nums; }
.sh-pc__area { display: block; font: 700 17px/22px var(--font-sans); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sh-pc__type { display: block; font: 500 14px/20px var(--font-sans); color: var(--ink-muted); }
.sh-pc__price { display: block; margin-top: 2px; font: 800 17px/22px var(--font-sans); color: var(--gold); font-variant-numeric: tabular-nums; }
.is-grid .sh-pc { flex-direction: column; align-items: stretch; }
.is-grid .sh-pc__img { width: 100%; height: 96px; }
.is-grid .sh-pc__area { white-space: normal; }
.sh-st { display: inline-flex; align-items: center; gap: 5px; font: 700 13px/18px var(--font-sans); color: var(--ink-muted); }
.sh-st::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.sh-st--live { color: var(--state-success); } .sh-st--review { color: var(--state-warning); } .sh-st--sold { color: var(--state-info); } .sh-st--expired, .sh-st--hidden { color: var(--ink-faint); }
.sh-empty { padding: 40px 16px; text-align: center; color: var(--ink-muted); font: 500 16px/24px var(--font-sans); }

/* post page */
.sh-ph { height: 210px; border-radius: 18px; margin-bottom: 16px; position: relative; background: var(--bg-200) center/cover no-repeat; display: grid; place-items: center; color: var(--ink-faint); overflow: hidden; }
.sh-ph .dl-icon { width: 40px; height: 40px; }
.sh-ph__n { position: absolute; left: 12px; top: 12px; padding: 6px 10px; border-radius: 10px; background: rgba(14,15,17,.78); color: #f5f4f0; font: 800 14px/1 var(--font-sans); font-variant-numeric: tabular-nums; }
[dir="rtl"] .sh-ph__n { left: auto; right: 12px; }
.sh-ph .dl-tile__promo { position: absolute; right: 12px; top: 12px; }
.sh-price { font: 800 30px/36px var(--font-sans); color: var(--gold); font-variant-numeric: tabular-nums; margin: 6px 0 4px; }
.sh-price small { font-size: 16px; color: var(--ink-muted); font-weight: 600; }
.sh-facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 16px 0; }
.sh-fact { padding: 12px; border-radius: 14px; background: var(--bg-100); border: 1px solid var(--line-100); text-align: center; }
.sh-fact b { display: block; font: 800 20px/26px var(--font-sans); color: var(--ink); }
.sh-fact small { font: 500 14px/18px var(--font-sans); color: var(--ink-muted); }
.sh-info { display: flex; gap: 10px; align-items: flex-start; padding: 14px; border-radius: 14px; background: var(--bg-100); border: 1px solid var(--line-100); font: 500 15px/22px var(--font-sans); color: var(--ink-muted); margin-top: 14px; }
.sh-info .dl-icon { width: 20px; height: 20px; color: var(--gold); margin-top: 1px; flex: none; }
.sh-post { font: 500 17px/27px var(--font-sans); color: var(--ink); white-space: pre-wrap; word-break: break-word; margin: 0; }
.sh-agent { display: flex; align-items: center; gap: 14px; margin-top: 18px; padding: 14px 16px; border-radius: 18px; background: var(--bg-100); border: 1px solid var(--line-100); }
.sh-agent__av { width: 52px; height: 52px; border-radius: 50%; background: var(--bg-300); display: grid; place-items: center; font: 800 18px/1 var(--font-sans); color: var(--gold); flex: none; object-fit: cover; }
.sh-agent__name { margin: 0; font: 800 19px/24px var(--font-sans); color: var(--ink); }
.sh-agent__lvl { margin: 2px 0 0; font: 600 15px/20px var(--font-sans); color: var(--gold); }
.sh-two { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.sh-three { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 10px; }
.sh-btnx { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 54px; padding: 0 14px; border-radius: 14px; border: 1.5px solid var(--line-200); background: transparent; color: var(--ink); font: 700 16px/1 var(--font-sans); cursor: pointer; text-decoration: none; }
.sh-btnx .dl-icon { width: 20px; height: 20px; }
.sh-btnx--gold { background: var(--gold); border-color: var(--gold); color: var(--on-gold); }

/* choice cards (promote steps, share) */
.sh-choice { display: flex; align-items: center; gap: 14px; width: 100%; min-height: 68px; padding: 12px 14px; border-radius: 16px; border: 1.5px solid var(--line-100); background: var(--bg-100); cursor: pointer; text-align: start; margin-bottom: 10px; color: var(--ink); font: inherit; }
.sh-choice[aria-checked="true"] { border-color: var(--gold); background: #1d1a10; }
:root[data-theme="light"] .sh-choice[aria-checked="true"] { background: #fbf5e2; }
.sh-choice input { position: absolute; opacity: 0; width: 0; height: 0; }
.sh-box { width: 28px; height: 28px; border-radius: 8px; border: 2px solid var(--line-200); display: grid; place-items: center; flex: none; transition: background-color .15s, border-color .15s; }
.sh-box--r { border-radius: 50%; }
.sh-box .dl-icon { width: 18px; height: 18px; color: var(--on-gold); stroke-width: 3; transform: scale(0); transition: transform .2s var(--ease-spring); }
[aria-checked="true"] .sh-box, .sh-choice:has(input:checked) .sh-box { background: var(--gold); border-color: var(--gold); }
[aria-checked="true"] .sh-box .dl-icon, .sh-choice:has(input:checked) .sh-box .dl-icon { transform: scale(1); }
.sh-choice:has(input:checked) { border-color: var(--gold); background: #1d1a10; }
:root[data-theme="light"] .sh-choice:has(input:checked) { background: #fbf5e2; }
.sh-choice b { display: block; font: 700 17px/22px var(--font-sans); }
.sh-choice small { display: block; font: 500 14px/20px var(--font-sans); color: var(--ink-muted); }
.sh-choice__ic { width: 44px; height: 44px; border-radius: 12px; background: var(--gold-soft); color: var(--gold); display: grid; place-items: center; flex: none; }
.sh-choice__img { width: 56px; height: 56px; border-radius: 12px; flex: none; background: var(--bg-300) center/cover no-repeat; }

/* step bar (Promote: one step per screen) */
.sh-steps { display: flex; align-items: center; gap: 12px; margin: 2px 0 6px; font: 700 14px/18px var(--font-sans); color: var(--ink-muted); }
.sh-steps__bar { flex: 1; display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; }
.sh-steps__bar i { height: 6px; border-radius: 3px; background: var(--bg-300); }
.sh-steps__bar i.on { background: var(--gold); }
[data-flow] [data-step-panel] { display: none; }
[data-flow] [data-step-panel].is-on { display: block; animation: sh-app-in .3s var(--ease-out); }
.dl-screen [tabindex="-1"]:focus { outline: none; }
.sh-hub-hidden { display: none; }

/* build your post */
.sh-seg { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 4px; padding: 4px; border-radius: 14px; background: var(--bg-200); border: 1px solid var(--line-100); }
.sh-seg button, .sh-seg a { height: 46px; border: 0; border-radius: 10px; background: transparent; color: var(--ink-muted); font: 700 16px/46px var(--font-sans); cursor: pointer; text-align: center; text-decoration: none; }
.sh-seg button[aria-pressed="true"], .sh-seg a[aria-current="page"] { background: var(--bg-100); color: var(--ink); box-shadow: 0 1px 3px rgba(0,0,0,.25); }
.sh-longcard { margin-top: 16px; padding: 22px 18px; border-radius: 18px; background: var(--bg-100); border: 1px solid var(--gold-line); text-align: center; }
.sh-longcard .dl-icon { width: 40px; height: 40px; color: var(--gold); margin-bottom: 6px; }
.sh-longcard b { display: block; font: 800 20px/26px var(--font-sans); }
.sh-longcard p { margin: 8px 0 0; font: 500 16px/24px var(--font-sans); color: var(--ink-muted); }
.sh-sitelink { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 56px; margin-top: 14px; padding: 0 16px; border-radius: 14px; border: 1.5px solid var(--line-100); background: var(--bg-100); color: var(--gold); font: 700 16px/22px var(--font-sans); cursor: pointer; text-align: start; text-decoration: none; }
.sh-sitelink .dl-icon { width: 20px; height: 20px; flex: none; }
.sh-tgpost { margin-top: 8px; padding: 14px 16px; border-radius: 16px 16px 16px 4px; background: var(--tg-post); color: var(--tg-post-ink); font: 500 16px/24px system-ui, -apple-system, sans-serif; white-space: pre-wrap; word-break: break-word; position: relative; }
.sh-tgpost__who { display: block; font-weight: 700; color: var(--tg-post-who); margin-bottom: 4px; }
.sh-checks { list-style: none; margin: 10px 0 0; padding: 0; }
.sh-checks li { display: flex; gap: 10px; align-items: center; padding: 6px 0; font: 600 15px/21px var(--font-sans); color: var(--ink-muted); }
.sh-checks .dl-icon { width: 20px; height: 20px; flex: none; }
.sh-checks .ok { color: var(--state-success); } .sh-checks .no { color: var(--state-warning); }
.sh-field { display: block; margin-bottom: 14px; }
.sh-field > span { display: block; margin: 0 2px 6px; font: 700 15px/20px var(--font-sans); color: var(--ink-muted); }

/* rules with Why? */
.sh-rule { border-top: 1px solid var(--line-100); }
.sh-rules .sh-rule:first-child { border-top: 0; }
.sh-rule__q { display: flex; gap: 12px; align-items: flex-start; width: 100%; padding: 16px; border: 0; background: none; text-align: start; cursor: pointer; font: 600 17px/25px var(--font-sans); color: var(--ink); }
[dir="rtl"] .sh-rule__q { font-family: var(--font-fa); }
.sh-rule__q .sh-why { margin-inline-start: auto; flex: none; font: 700 14px/25px var(--font-sans); color: var(--gold); display: flex; align-items: center; gap: 2px; }
.sh-rule__q .sh-why .dl-icon { width: 18px; height: 18px; transition: transform .25s var(--ease-out); }
.sh-rule.is-open .sh-why .dl-icon { transform: rotate(90deg); }
[dir="rtl"] .sh-rule__q .sh-why .dl-icon { transform: scaleX(-1); }
[dir="rtl"] .sh-rule.is-open .sh-why .dl-icon { transform: scaleX(-1) rotate(-90deg); }
.sh-rule__a { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .28s var(--ease-out); }
.sh-rule.is-open .sh-rule__a { grid-template-rows: 1fr; }
.sh-rule__a > div { overflow: hidden; }
.sh-rule__a p { margin: 0; padding: 0 16px 16px 16px; font: 500 16px/25px var(--font-sans); color: var(--ink-muted); }
[dir="rtl"] .sh-rule__a p { font-family: var(--font-fa); }
.sh-rule__a a { color: var(--gold); }
.sh-rules__sec { margin: 20px 2px 8px; font: 700 15px/20px var(--font-sans); color: var(--ink-muted); }

/* how it works */
.sh-ladder { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; }
.sh-ladder li { aspect-ratio: 1 / 1.15; border-radius: 14px; background: var(--bg-100); border: 1px solid var(--line-100); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; }
.sh-ladder li img { width: 60%; height: auto; }
.sh-ladder b { font: 800 22px/1 var(--font-sans); color: var(--ink); }
.sh-ladder small { font: 700 11px/14px var(--font-sans); color: var(--ink-muted); text-align: center; }
.sh-ladder .is-me { border-color: var(--gold); background: var(--gold-soft); }
.sh-ladder .is-me b { color: var(--gold); }
.sh-ladder .is-apex { border-color: #6b5a1c; background: linear-gradient(160deg, #2a2412, var(--bg-100)); }
:root[data-theme="light"] .sh-ladder .is-apex { background: linear-gradient(160deg, #f6edcf, #fff); border-color: #d8c58a; }
.sh-hsteps { list-style: none; margin: 0; padding: 0; counter-reset: s; }
.sh-hsteps li { position: relative; padding: 4px 0 18px 46px; font: 500 16px/25px var(--font-sans); color: var(--ink-muted); }
[dir="rtl"] .sh-hsteps li { padding: 4px 46px 18px 0; font-family: var(--font-fa); }
.sh-hsteps li b { display: block; color: var(--ink); font: 700 17px/24px var(--font-sans); }
[dir="rtl"] .sh-hsteps li b { font-family: var(--font-fa); }
.sh-hsteps li::before { counter-increment: s; content: counter(s); position: absolute; left: 0; top: 2px; width: 32px; height: 32px; border-radius: 50%; background: var(--gold-soft); color: var(--gold); display: grid; place-items: center; font: 800 15px/32px var(--font-sans); text-align: center; }
[dir="rtl"] .sh-hsteps li::before { left: auto; right: 0; }
.sh-art p { font: 500 17px/27px var(--font-sans); color: var(--ink); margin: 0 0 14px; }
.sh-art h2 { font: 700 19px/26px var(--font-sans); margin: 20px 0 8px; color: var(--ink); }
.sh-art ul { margin: 0 0 14px; padding-inline-start: 22px; font: 500 17px/27px var(--font-sans); color: var(--ink); }
[dir="rtl"] .sh-art p, [dir="rtl"] .sh-art h2, [dir="rtl"] .sh-art ul { font-family: var(--font-fa); }
/* Batch C1 1.5 (3 Nov 2026): a line of English inside an RTL screen keeps its own direction, so its full stop and "?" stay at its end */
[dir="rtl"] .sh-art p, [dir="rtl"] .sh-art li, [dir="rtl"] .sh-art h2, [dir="rtl"] .sh-rulebook p, [dir="rtl"] .sh-rulebook li, [dir="rtl"] .v3 .lead, [dir="rtl"] .v3 .small, [dir="rtl"] .sh-rule__q span:first-child, [dir="rtl"] .sh-rule__a p { unicode-bidi: plaintext; }
.sh-bar { height: 12px; border-radius: 6px; background: var(--bg-300); overflow: hidden; margin: 10px 0 6px; }
.sh-bar i { display: block; height: 100%; border-radius: 6px; background: linear-gradient(90deg, var(--gold-press), var(--gold-hover)); }

/* history rows (requests, contact history) */
.sh-hist { list-style: none; margin: 0; padding: 0; border-radius: 16px; background: var(--bg-100); border: 1px solid var(--line-100); }
.sh-hist li { display: flex; align-items: center; gap: 12px; padding: 14px; border-top: 1px solid var(--line-100); }
.sh-hist li:first-child { border-top: 0; }
.sh-hist__d { flex: none; width: 56px; font: 700 14px/18px var(--font-sans); color: var(--ink-muted); }
.sh-hist__t { flex: 1; min-width: 0; }
.sh-hist__t b { display: block; font: 700 16px/22px var(--font-sans); color: var(--ink); }
.sh-hist__t small { font: 500 14px/20px var(--font-sans); color: var(--ink-muted); }
.sh-minibtn { width: 46px; height: 46px; border-radius: 12px; border: 1.5px solid var(--line-100); background: var(--bg-200); display: grid; place-items: center; color: var(--gold); cursor: pointer; flex: none; text-decoration: none; }
.sh-linkcard { display: flex; align-items: center; gap: 10px; min-height: 56px; padding: 0 16px; border-radius: 14px; background: var(--bg-200); font: 700 16px/22px var(--font-sans); color: var(--ink); word-break: break-all; }
.sh-linkcard .dl-icon { color: var(--gold); flex: none; }
.sh-req { padding: 16px; border-radius: 18px; background: var(--bg-100); border: 1px solid var(--line-100); margin-bottom: 12px; }
.sh-req__h b { font: 700 18px/24px var(--font-sans); color: var(--ink); }
.sh-req__m { display: block; font: 500 14px/20px var(--font-sans); color: var(--ink-muted); }

/* the promoted sample post on the Promote hub */
.sh-promo-mark { position: absolute; right: 10px; bottom: -12px; }
[dir="rtl"] .sh-promo-mark { right: auto; left: 10px; }

/* the app menu's appearance row */
.sh-appearance { margin: 16px 0 8px; }

/* RTL: the design system's chevrons point the other way */
[dir="rtl"] .dl-dest__go .dl-icon, [dir="rtl"] .dl-back .dl-icon { transform: scaleX(-1); }

@media (prefers-reduced-motion: reduce) {
  .dl-screen, #dl-intro, .sh-rule__a, .sh-switch i, .sh-box .dl-icon, [data-flow] [data-step-panel].is-on { animation: none !important; transition: none !important; }
}

/* the rulebook's own paragraphs and lists inside the Group guide */
.sh-rulebook p, .sh-rulebook li { font: 500 17px/27px var(--font-sans); color: var(--ink); margin: 0 0 12px; }
.sh-rulebook ul, .sh-rulebook ol { margin: 0 0 14px; padding-inline-start: 22px; }
.sh-rulebook a { color: var(--gold); }
.sh-rulebook strong { color: var(--ink); }
[dir="rtl"] .sh-rulebook p, [dir="rtl"] .sh-rulebook li { font-family: var(--font-fa); }

/* a screen's own copy of the MainButton (the pay / send button of a summary) hides when Telegram draws the real one */
body.has-native .sh-native-hide { display: none; }
/* the community tiles: a long title never widens a column (minmax(0,1fr), as the design's 2-column grid intends) */
.dl-app .dl-tiles { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.dl-app .dl-tile { min-width: 0; }
/* Batch B task 4: Ask the admins · My questions. The red dot of a new answer (tile and card), the new card's edge, the answer box */
.sh-dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; background: var(--state-danger, #d92d20); margin-inline-start: 8px; vertical-align: middle; }
.sh-tile .sh-dot { position: absolute; top: 14px; right: 14px; margin: 0; }
[dir="rtl"] .sh-tile .sh-dot { right: auto; left: 14px; }
.dl-qcard.is-new { box-shadow: inset 3px 0 0 var(--state-danger, #d92d20); }
.dl-qans { background: var(--surface-2, rgba(127,127,127,.08)); border-radius: 12px; padding: 10px 12px; }
.dl-qans small { font-weight: 700; opacity: .7; }
/* Batch C3 2.5: Telegram full screen — the page clears the phone's status bar and Telegram's own top buttons
   (--dl-safe-top, set by shell.js from Telegram's safe areas; 0 outside full screen and outside Telegram). */
#dl-stage { top: var(--dl-safe-top, 0px); }
.dl-offline { top: var(--dl-safe-top, 0px); }
.dl-viewer { padding-top: var(--dl-safe-top, 0px); }
.dl-tabbar { height: calc(var(--tabbar-h) + max(env(safe-area-inset-bottom), var(--dl-safe-bottom, 0px))); padding-bottom: max(env(safe-area-inset-bottom), var(--dl-safe-bottom, 0px)); }
.dl-page { padding-bottom: calc(var(--tabbar-h) + var(--space-6) + max(env(safe-area-inset-bottom), var(--dl-safe-bottom, 0px))); }
