/* Patient and doctor accounts, inside the site's own page. Everything is scoped to #pt-app so the theme stays untouched. Mobile first, right to left. */
#pt-app, .rx-body {
  --c: #035dcd;
  --c-deep: color-mix(in srgb, var(--c) 72%, #000);
  --c-soft: color-mix(in srgb, var(--c) 10%, #fff);
  --bg: #f3f5f9;
  --card: #fff;
  --ink: #111a2b;
  --ink-2: #5d6779;
  --ink-3: #98a2b3;
  --line: #e7ebf1;
  --ok: #12a05f;
  --ok-soft: #e3f6ec;
  --warn: #c2750a;
  --warn-soft: #fff4e0;
  --bad: #e5484d;
  --bad-soft: #fdecec;
  --r: 18px;
  --shadow: 0 1px 2px rgba(17, 26, 43, .05), 0 6px 20px rgba(17, 26, 43, .06);
  color-scheme: light;
}
#pt-app * { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
#pt-app { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
#pt-app {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font, system-ui), system-ui, -apple-system, "Segoe UI", "Noto Sans Arabic", Tahoma, sans-serif;
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
#pt-app button, #pt-app input, #pt-app select, #pt-app textarea { font: inherit; color: inherit; }
#pt-app button { cursor: pointer; border: 0; background: none; padding: 0; }
#pt-app a { color: var(--c); text-decoration: none; }
#pt-app img { max-width: 100%; }
#pt-app [hidden] { display: none !important; }
#pt-app .ltr { direction: ltr; unicode-bidi: plaintext; text-align: right; }
#pt-app .num { font-variant-numeric: tabular-nums; }

/* Loading */
#pt-app .pt-boot { min-height: 100vh; display: grid; place-items: center; }
#pt-app .pt-boot span, #pt-app .spin { width: 34px; height: 34px; border-radius: 50%; border: 3px solid var(--c-soft); border-top-color: var(--c); animation: vpa-spin .8s linear infinite; }
#pt-app .spin { width: 22px; height: 22px; border-width: 2.5px; display: inline-block; vertical-align: middle; }
@keyframes vpa-spin { to { transform: rotate(360deg); } }
#pt-app .skel { height: 74px; border-radius: var(--r); margin-bottom: 10px; background: linear-gradient(100deg, #e9edf2 30%, #f5f7fa 50%, #e9edf2 70%) 0 0 / 300% 100%; animation: vpa-shine 1.3s linear infinite; }
@keyframes vpa-shine { to { background-position: -300% 0; } }

/* Frame */
#pt-app .top {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; gap: 8px;
  min-height: 58px; padding: calc(8px + env(safe-area-inset-top)) 12px 8px;
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s;
}
#pt-app .top.edge { border-bottom-color: var(--line); }
#pt-app .top h1 { flex: 1; margin: 0; font-size: 18px; font-weight: 800; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#pt-app .icon-btn { width: 42px; height: 42px; border-radius: 13px; display: grid; place-items: center; color: var(--ink); flex: none; }
#pt-app .icon-btn:active { background: #e6eaf0; }
#pt-app .icon-btn svg, #pt-app .ico { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; flex: none; }
#pt-app main.page { padding: 6px 14px calc(96px + env(safe-area-inset-bottom)); max-width: 680px; margin: 0 auto; }
#pt-app main.page.flat { padding-bottom: 30px; }

#pt-app .tabs {
  position: fixed; left: 10px; right: 10px; bottom: calc(10px + env(safe-area-inset-bottom)); z-index: 30;
  display: flex; justify-content: space-around; max-width: 560px; margin: 0 auto;
  padding: 6px; border-radius: 22px; background: rgba(255, 255, 255, .96);
  -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px);
  box-shadow: 0 10px 30px rgba(17, 26, 43, .14), 0 0 0 1px rgba(17, 26, 43, .04);
}
#pt-app .tabs a { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 7px 2px 5px; border-radius: 16px; color: var(--ink-3); font-size: 11.5px; font-weight: 700; position: relative; }
#pt-app .tabs a .ico { width: 23px; height: 23px; }
#pt-app .tabs a.on { color: var(--c); background: var(--c-soft); }
#pt-app .tabs .badge { position: absolute; top: 3px; right: calc(50% - 20px); min-width: 17px; height: 17px; padding: 0 5px; border-radius: 99px; background: var(--bad); color: #fff; font-size: 10.5px; line-height: 17px; text-align: center; }

/* Building blocks */
#pt-app .card { background: var(--card); border-radius: var(--r); box-shadow: var(--shadow); padding: 16px; margin-bottom: 12px; }
#pt-app .card.tight { padding: 0; overflow: hidden; }
#pt-app .sec-title { display: flex; align-items: center; justify-content: space-between; margin: 20px 4px 10px; font-size: 15.5px; font-weight: 800; }
#pt-app .sec-title a, #pt-app .sec-title button { font-size: 13.5px; font-weight: 700; color: var(--c); }
#pt-app .muted { color: var(--ink-2); }
#pt-app .small { font-size: 13px; }
#pt-app .center { text-align: center; }
#pt-app .row { display: flex; align-items: center; gap: 12px; }
#pt-app .row > .grow { flex: 1; min-width: 0; }
#pt-app .list-row { display: flex; align-items: center; gap: 12px; padding: 13px 15px; color: var(--ink); }
#pt-app .list-row + .list-row { border-top: 1px solid var(--line); }
#pt-app .list-row:active { background: #f7f8fb; }
#pt-app .list-row .chev { color: var(--ink-3); width: 18px; height: 18px; }
#pt-app .tile { width: 42px; height: 42px; border-radius: 13px; display: grid; place-items: center; flex: none; color: var(--t, var(--c)); background: color-mix(in srgb, var(--t, var(--c)) 12%, #fff); }
#pt-app .tile .ico { width: 21px; height: 21px; }
#pt-app .pill { display: inline-flex; align-items: center; gap: 5px; padding: 2px 10px; border-radius: 99px; font-size: 12px; font-weight: 700; background: #eef1f5; color: var(--ink-2); white-space: nowrap; }
#pt-app .pill.ok { background: var(--ok-soft); color: var(--ok); }
#pt-app .pill.warn { background: var(--warn-soft); color: var(--warn); }
#pt-app .pill.bad { background: var(--bad-soft); color: var(--bad); }
#pt-app .pill.brand { background: var(--c-soft); color: var(--c); }
#pt-app .pill.gold { background: linear-gradient(135deg, #ffd66b, #f5a524); color: #4a2d00; }
#pt-app .empty { text-align: center; padding: 34px 20px; color: var(--ink-2); }
#pt-app .empty .tile { width: 64px; height: 64px; border-radius: 20px; margin: 0 auto 12px; }
#pt-app .empty .tile .ico { width: 30px; height: 30px; }
#pt-app .empty b { display: block; color: var(--ink); font-size: 16px; margin-bottom: 4px; }

/* Buttons */
#pt-app .btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 50px; padding: 0 20px; border-radius: 15px;
  background: var(--c); color: #fff; font-weight: 800; font-size: 15.5px;
  box-shadow: 0 10px 22px -12px var(--c);
  transition: transform .12s, opacity .2s;
}
#pt-app .btn:active { transform: scale(.98); }
#pt-app .btn[disabled] { opacity: .55; pointer-events: none; }
#pt-app .btn.block { width: 100%; }
#pt-app .btn.ghost { background: var(--card); color: var(--ink); box-shadow: none; border: 1px solid var(--line); }
#pt-app .btn.soft { background: var(--c-soft); color: var(--c); box-shadow: none; }
#pt-app .btn.danger { background: var(--bad-soft); color: var(--bad); box-shadow: none; }
#pt-app .btn.ok { background: var(--ok); box-shadow: 0 10px 22px -12px var(--ok); }
#pt-app .btn.sm { min-height: 38px; padding: 0 14px; border-radius: 12px; font-size: 13.5px; }
#pt-app .btn-row { display: flex; gap: 8px; flex-wrap: wrap; }
#pt-app .btn-row .btn { flex: 1; }

/* Forms */
#pt-app .field { margin-bottom: 14px; }
#pt-app .field > label, #pt-app .field > .lbl { display: block; margin-bottom: 6px; font-size: 13.5px; font-weight: 700; color: var(--ink-2); }
#pt-app .input, #pt-app select.input, #pt-app textarea.input {
  width: 100%; min-height: 50px; padding: 12px 14px; border-radius: 14px;
  border: 1.5px solid var(--line); background: #fff; outline: 0;
  transition: border-color .15s, box-shadow .15s;
}
#pt-app textarea.input { min-height: 96px; resize: vertical; line-height: 1.7; }
#pt-app .input:focus { border-color: var(--c); box-shadow: 0 0 0 4px var(--c-soft); }
#pt-app .hint { margin: 6px 2px 0; font-size: 12.5px; color: var(--ink-3); }
#pt-app .two { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
#pt-app .seg { display: flex; padding: 4px; border-radius: 15px; background: #e8ecf2; gap: 4px; margin-bottom: 16px; }
#pt-app .seg button { flex: 1; min-height: 42px; border-radius: 12px; font-weight: 800; font-size: 14px; color: var(--ink-2); }
#pt-app .seg button.on { background: #fff; color: var(--ink); box-shadow: 0 2px 8px rgba(17, 26, 43, .1); }
#pt-app .choice { display: flex; align-items: center; gap: 12px; padding: 14px; border-radius: 15px; border: 1.5px solid var(--line); background: #fff; margin-bottom: 8px; cursor: pointer; }
#pt-app .choice.on { border-color: var(--c); background: var(--c-soft); }
#pt-app .choice input { width: 20px; height: 20px; accent-color: var(--c); flex: none; margin: 0; }
#pt-app .choice b { display: block; font-size: 15px; }
#pt-app .choice small { display: block; color: var(--ink-2); font-size: 12.5px; }
#pt-app .switch { position: relative; width: 48px; height: 28px; border-radius: 99px; background: #d3d9e2; flex: none; transition: background-color .2s; }
#pt-app .switch::after { content: ""; position: absolute; top: 3px; right: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; box-shadow: 0 2px 4px rgba(0, 0, 0, .2); transition: transform .2s; }
#pt-app .switch.on { background: var(--ok); }
#pt-app .switch.on::after { transform: translateX(-20px); }

/* Sign in */
#pt-app .auth { min-height: 100vh; display: flex; flex-direction: column; }
#pt-app .auth-hero { position: relative; overflow: hidden; padding: calc(34px + env(safe-area-inset-top)) 24px 70px; color: #fff; text-align: center; background: linear-gradient(150deg, color-mix(in srgb, var(--c) 85%, #6aa8ff), var(--c) 50%, var(--c-deep)); }
#pt-app .auth-hero::before, #pt-app .auth-hero::after { content: ""; position: absolute; border-radius: 50%; background: rgba(255, 255, 255, .08); }
#pt-app .auth-hero::before { width: 260px; height: 260px; top: -120px; right: -80px; }
#pt-app .auth-hero::after { width: 160px; height: 160px; bottom: -80px; left: -40px; }
#pt-app .auth-hero img { position: relative; width: 74px; height: 74px; border-radius: 22px; background: #fff; padding: 4px; box-shadow: 0 10px 26px rgba(0, 0, 0, .2); }
#pt-app .auth-hero h1 { position: relative; margin: 14px 0 4px; font-size: 24px; font-weight: 800; }
#pt-app .auth-hero p { position: relative; margin: 0; opacity: .88; font-size: 14.5px; }
#pt-app .auth-card { position: relative; margin: -44px 14px 24px; padding: 20px 18px; border-radius: 24px; background: #fff; box-shadow: 0 18px 40px rgba(17, 26, 43, .12); max-width: 480px; align-self: stretch; }
@media (min-width: 520px) { #pt-app .auth-card { margin-left: auto; margin-right: auto; width: 480px; } }
#pt-app .who { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 16px; }
#pt-app .who button { padding: 12px 8px; border-radius: 15px; border: 1.5px solid var(--line); text-align: center; font-weight: 800; }
#pt-app .who button .tile { margin: 0 auto 6px; }
#pt-app .who button.on { border-color: var(--c); background: var(--c-soft); color: var(--c); }
#pt-app .link-btn { color: var(--c); font-weight: 700; font-size: 14px; }

/* Home */
#pt-app .hello { display: flex; align-items: center; gap: 12px; margin: 6px 2px 14px; }
#pt-app .hello .av { width: 50px; height: 50px; }
#pt-app .hello b { display: block; font-size: 18px; }
#pt-app .av { width: 54px; height: 54px; border-radius: 17px; flex: none; display: grid; place-items: center; overflow: hidden; color: #fff; font-weight: 800; font-size: 19px; background: linear-gradient(145deg, color-mix(in srgb, var(--c) 80%, #6aa8ff), var(--c-deep)); }
#pt-app .av img { width: 100%; height: 100%; object-fit: cover; }
#pt-app .wallet {
  position: relative; overflow: hidden; padding: 20px; border-radius: 24px; color: #fff; margin-bottom: 12px;
  background: linear-gradient(135deg, color-mix(in srgb, var(--c) 82%, #6aa8ff), var(--c) 48%, var(--c-deep));
  box-shadow: 0 18px 34px -18px var(--c);
}
#pt-app .wallet::before { content: ""; position: absolute; width: 220px; height: 220px; border-radius: 50%; border: 28px solid rgba(255, 255, 255, .07); top: -90px; left: -70px; }
#pt-app .wallet small { position: relative; display: block; opacity: .82; font-size: 13px; font-weight: 600; }
#pt-app .wallet .big { position: relative; display: block; font-size: 32px; font-weight: 800; letter-spacing: -.5px; line-height: 1.3; }
#pt-app .wallet .big span { font-size: 15px; font-weight: 700; opacity: .85; margin-right: 4px; }
#pt-app .wallet .pts { position: relative; display: inline-flex; align-items: center; gap: 6px; margin-top: 8px; padding: 5px 12px; border-radius: 99px; background: rgba(255, 255, 255, .16); font-size: 13px; font-weight: 700; }
#pt-app .wallet .acts { position: relative; display: flex; gap: 8px; margin-top: 16px; }
#pt-app .wallet .acts button, #pt-app .wallet .acts a { flex: 1; min-height: 44px; border-radius: 14px; background: rgba(255, 255, 255, .17); color: #fff; font-weight: 800; font-size: 14px; display: flex; align-items: center; justify-content: center; gap: 6px; }
#pt-app .wallet .acts .ico { width: 19px; height: 19px; }
#pt-app .quick { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-bottom: 4px; }
#pt-app .quick a { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 12px 4px; border-radius: 18px; background: #fff; box-shadow: var(--shadow); color: var(--ink); font-size: 12.5px; font-weight: 700; text-align: center; }
#pt-app .stats { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 12px; }
#pt-app .stat { padding: 14px; border-radius: var(--r); background: #fff; box-shadow: var(--shadow); }
#pt-app .stat small { display: block; color: var(--ink-2); font-size: 12.5px; font-weight: 600; }
#pt-app .stat b { display: block; font-size: 22px; font-weight: 800; line-height: 1.35; }
#pt-app .stat .tile { width: 34px; height: 34px; border-radius: 11px; margin-bottom: 8px; }
#pt-app .stat .tile .ico { width: 18px; height: 18px; }
#pt-app .banner { display: flex; gap: 12px; padding: 14px; border-radius: var(--r); margin-bottom: 12px; background: var(--warn-soft); color: #7a4a06; }
#pt-app .banner.bad { background: var(--bad-soft); color: #8f1d21; }
#pt-app .banner.ok { background: var(--ok-soft); color: #0b6b3e; }
#pt-app .banner b { display: block; }

/* Doctors */
#pt-app .search { position: relative; margin-bottom: 10px; }
#pt-app .search .ico { position: absolute; top: 15px; right: 14px; color: var(--ink-3); width: 20px; height: 20px; }
#pt-app .search .input { padding-right: 44px; border-radius: 16px; }
#pt-app .chips { display: flex; gap: 8px; overflow-x: auto; padding: 2px 2px 10px; margin: 0 -14px; padding-right: 14px; padding-left: 14px; scrollbar-width: none; }
#pt-app .chips::-webkit-scrollbar { display: none; }
#pt-app .chip { flex: none; padding: 8px 14px; border-radius: 99px; background: #fff; border: 1px solid var(--line); font-size: 13.5px; font-weight: 700; color: var(--ink-2); }
#pt-app .chip.on { background: var(--ink); border-color: var(--ink); color: #fff; }
#pt-app .doc-card { display: flex; gap: 13px; padding: 14px; color: var(--ink); position: relative; }
#pt-app .doc-card.featured { box-shadow: 0 0 0 1.5px #f5c04a, var(--shadow); }
#pt-app .doc-card h3 { margin: 0; font-size: 16px; font-weight: 800; line-height: 1.45; }
#pt-app .doc-card .meta { font-size: 13px; color: var(--ink-2); }
#pt-app .doc-card .fee { margin-top: 6px; font-size: 13.5px; font-weight: 800; color: var(--c); }
#pt-app .doc-hero { text-align: center; padding: 22px 16px 18px; }
#pt-app .doc-hero .av { width: 92px; height: 92px; border-radius: 28px; margin: 0 auto 12px; font-size: 32px; }
#pt-app .doc-hero h2 { margin: 0; font-size: 21px; font-weight: 800; }
#pt-app .clinic { padding: 15px; }
#pt-app .clinic + .clinic { border-top: 1px solid var(--line); }
#pt-app .clinic h4 { margin: 0 0 4px; font-size: 15.5px; font-weight: 800; }
#pt-app .clinic .line { display: flex; align-items: flex-start; gap: 8px; font-size: 13.5px; color: var(--ink-2); margin-top: 4px; }
#pt-app .clinic .line .ico { width: 17px; height: 17px; margin-top: 3px; color: var(--ink-3); }
#pt-app .clinic .price { font-size: 18px; font-weight: 800; color: var(--ink); }

/* Booking */
#pt-app .days { display: flex; gap: 8px; overflow-x: auto; padding: 2px 14px 10px; margin: 0 -14px; scrollbar-width: none; }
#pt-app .days::-webkit-scrollbar { display: none; }
#pt-app .day { flex: none; width: 64px; padding: 9px 4px; border-radius: 16px; background: #fff; border: 1.5px solid var(--line); text-align: center; }
#pt-app .day small { display: block; font-size: 11.5px; color: var(--ink-2); font-weight: 700; }
#pt-app .day b { display: block; font-size: 20px; font-weight: 800; line-height: 1.3; }
#pt-app .day.on { background: var(--c); border-color: var(--c); color: #fff; }
#pt-app .day.on small { color: rgba(255, 255, 255, .85); }
#pt-app .day.off { opacity: .4; pointer-events: none; }
#pt-app .slots { display: grid; grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); gap: 8px; }
#pt-app .slot { min-height: 44px; border-radius: 13px; background: #fff; border: 1.5px solid var(--line); font-weight: 800; font-size: 14px; }
#pt-app .slot.on { background: var(--c); border-color: var(--c); color: #fff; }
#pt-app .slot[disabled] { background: #f1f3f6; color: var(--ink-3); text-decoration: line-through; border-color: transparent; }
#pt-app .sum-line { display: flex; justify-content: space-between; padding: 6px 0; font-size: 14.5px; }
#pt-app .sum-line.total { border-top: 1px dashed var(--line); margin-top: 6px; padding-top: 12px; font-weight: 800; font-size: 17px; }
#pt-app .sum-line.disc { color: var(--ok); }
#pt-app .sticky-cta { position: sticky; bottom: calc(86px + env(safe-area-inset-bottom)); z-index: 5; margin-top: 12px; }
#pt-app .done-hero { text-align: center; padding: 30px 16px 10px; }
#pt-app .done-hero .tile { width: 78px; height: 78px; border-radius: 26px; margin: 0 auto 14px; --t: var(--ok); }
#pt-app .done-hero .tile .ico { width: 38px; height: 38px; stroke-width: 2.4; }
#pt-app .done-hero h2 { margin: 0 0 6px; font-size: 22px; font-weight: 800; }

/* Bookings list */
#pt-app .bk { padding: 14px; }
#pt-app .bk-top { display: flex; align-items: center; gap: 12px; }
#pt-app .bk-when { flex: none; width: 58px; padding: 8px 4px; border-radius: 15px; text-align: center; background: var(--c-soft); color: var(--c); }
#pt-app .bk-when small { display: block; font-size: 11px; font-weight: 700; }
#pt-app .bk-when b { display: block; font-size: 20px; font-weight: 800; line-height: 1.2; }
#pt-app .bk h3 { margin: 0; font-size: 15px; font-weight: 800; }
#pt-app .bk .meta { font-size: 13px; color: var(--ink-2); }
#pt-app .bk-foot { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line); }
#pt-app .bk-foot .grow { flex: 1; font-size: 13px; color: var(--ink-2); }

/* Wallet */
#pt-app .tx { display: flex; align-items: center; gap: 12px; padding: 12px 15px; }
#pt-app .tx + .tx { border-top: 1px solid var(--line); }
#pt-app .tx .tile { width: 38px; height: 38px; border-radius: 12px; }
#pt-app .tx .tile .ico { width: 18px; height: 18px; }
#pt-app .tx .grow b { display: block; font-size: 14px; font-weight: 700; line-height: 1.5; }
#pt-app .tx .grow small { color: var(--ink-3); font-size: 12px; }
#pt-app .tx .amt { font-weight: 800; font-size: 15px; white-space: nowrap; text-align: left; }
#pt-app .tx .amt.plus { color: var(--ok); }
#pt-app .tx .amt.minus { color: var(--ink); }
#pt-app .tx .amt small { display: block; font-size: 11.5px; font-weight: 700; color: var(--warn); }
#pt-app .copy-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 11px 14px; border-radius: 14px; background: var(--c-soft); margin-bottom: 8px; }
#pt-app .copy-row b { font-size: 14px; }
#pt-app .copy-row button { padding: 6px 12px; border-radius: 10px; background: #fff; color: var(--c); font-weight: 800; font-size: 13px; }
#pt-app .upload { display: flex; align-items: center; gap: 12px; padding: 14px; border-radius: 15px; border: 1.5px dashed #c8d0dc; background: #fafbfc; cursor: pointer; }
#pt-app .upload img { width: 54px; height: 54px; border-radius: 10px; object-fit: cover; }
#pt-app .req { display: flex; align-items: center; gap: 12px; padding: 12px 15px; }
#pt-app .req + .req { border-top: 1px solid var(--line); }

/* Doctor tools */
#pt-app .sched-day { padding: 12px 0; border-top: 1px solid var(--line); }
#pt-app .sched-day:first-child { border-top: 0; }
#pt-app .sched-day .row b { flex: 1; }
#pt-app .range { display: flex; align-items: center; gap: 8px; margin-top: 8px; }
#pt-app .range .input { min-height: 44px; padding: 8px 10px; }
#pt-app .range span { color: var(--ink-3); font-size: 13px; }
.rx-item { padding: 14px; border-radius: 16px; background: #f7f9fc; border: 1px solid var(--line); margin-bottom: 10px; position: relative; }
.rx-item .x { position: absolute; top: 8px; left: 8px; width: 32px; height: 32px; border-radius: 10px; display: grid; place-items: center; color: var(--bad); }
#pt-app .quick-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
#pt-app .quick-chips button { padding: 5px 10px; border-radius: 99px; background: #fff; border: 1px solid var(--line); font-size: 12.5px; font-weight: 700; color: var(--ink-2); }
#pt-app .sig-pad { width: 100%; height: 180px; border-radius: 15px; border: 1.5px dashed #c8d0dc; background: #fff; touch-action: none; display: block; }
#pt-app .stamp-prev { width: 120px; height: 120px; object-fit: contain; border-radius: 12px; background: #fafbfc; border: 1px solid var(--line); }
#pt-app .plan { display: flex; align-items: center; gap: 12px; padding: 16px; }
#pt-app .plan + .plan { border-top: 1px solid var(--line); }
#pt-app .plan b { display: block; font-size: 16px; }
#pt-app .plan .price { font-size: 19px; font-weight: 800; color: var(--c); white-space: nowrap; }
#pt-app .feat-card { position: relative; overflow: hidden; padding: 20px; border-radius: 24px; color: #4a2d00; background: linear-gradient(135deg, #ffe39a, #f7b733); margin-bottom: 12px; }
#pt-app .feat-card::after { content: "★"; position: absolute; left: 18px; top: 4px; font-size: 90px; opacity: .2; }
#pt-app .feat-card b { display: block; font-size: 19px; }
#pt-app .chart { display: flex; align-items: flex-end; gap: 3px; height: 130px; padding-top: 10px; }
#pt-app .chart i { flex: 1; min-width: 3px; border-radius: 5px 5px 2px 2px; background: var(--c); opacity: .85; position: relative; }
#pt-app .chart i.zero { background: #e3e7ee; height: 3px !important; }
#pt-app .chart-x { display: flex; justify-content: space-between; font-size: 11px; color: var(--ink-3); margin-top: 6px; }
#pt-app table.days-table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
#pt-app .days-table th, #pt-app .days-table td { padding: 9px 6px; text-align: right; border-bottom: 1px solid var(--line); }
#pt-app .days-table th { color: var(--ink-2); font-weight: 700; font-size: 12.5px; }

/* Messages */
#pt-app .toast { position: fixed; left: 14px; right: 14px; bottom: calc(96px + env(safe-area-inset-bottom)); z-index: 60; max-width: 460px; margin: 0 auto; padding: 13px 16px; border-radius: 16px; background: #18202e; color: #fff; font-weight: 700; font-size: 14.5px; text-align: center; box-shadow: 0 14px 30px rgba(0, 0, 0, .25); animation: vpa-up .3s cubic-bezier(.2, .8, .2, 1); }
#pt-app .toast.bad { background: #b42318; }
#pt-app .toast.ok { background: #0b7a46; }
@keyframes vpa-up { from { transform: translateY(20px); opacity: 0; } to { transform: none; opacity: 1; } }
#pt-app .sheet-back { position: fixed; inset: 0; z-index: 50; background: rgba(10, 14, 22, .45); display: flex; align-items: flex-end; justify-content: center; animation: vpa-fade .2s; }
@keyframes vpa-fade { from { opacity: 0; } to { opacity: 1; } }
#pt-app .sheet { width: 100%; max-width: 560px; max-height: 92vh; overflow-y: auto; padding: 10px 18px calc(22px + env(safe-area-inset-bottom)); border-radius: 26px 26px 0 0; background: #fff; animation: vpa-up .3s cubic-bezier(.2, .8, .2, 1); }
#pt-app .sheet .grab { width: 44px; height: 5px; border-radius: 9px; background: #d6dbe3; margin: 0 auto 14px; }
#pt-app .sheet h3 { margin: 0 0 6px; font-size: 19px; font-weight: 800; }

/* Prescription page (opened from the QR code, also printed) */
.rx-body { background: #eef1f5; padding: 16px; }
.rx-tools { max-width: 760px; margin: 0 auto 10px; text-align: left; }
.rx-tools button { padding: 10px 18px; border-radius: 12px; background: var(--c); color: #fff; font-weight: 800; }
.rx-sheet { max-width: 760px; margin: 0 auto; padding: 26px; background: #fff; border-radius: 18px; box-shadow: var(--shadow); }
.rx-check { padding: 10px 14px; border-radius: 12px; font-weight: 800; font-size: 14px; margin-bottom: 18px; }
.rx-check.ok { background: var(--ok-soft); color: #0b6b3e; }
.rx-check.ok::before { content: "✓ "; }
.rx-check.bad { background: var(--bad-soft); color: #8f1d21; }
.rx-head { display: flex; justify-content: space-between; gap: 16px; padding-bottom: 16px; border-bottom: 3px solid var(--c); }
.rx-head h1 { margin: 0; font-size: 22px; color: var(--c-deep); }
.rx-head p { margin: 2px 0 0; color: var(--ink-2); }
.rx-logo { width: 56px; height: 56px; border-radius: 14px; }
.rx-patient { display: flex; flex-wrap: wrap; gap: 8px 24px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.rx-block { padding: 14px 0; }
.rx-block h2 { margin: 0 0 8px; font-size: 16px; color: var(--c-deep); }
.rx-r { font-family: Georgia, serif; font-size: 26px; vertical-align: middle; }
.rx-items ol { margin: 0; padding-right: 22px; }
.rx-items li { margin-bottom: 10px; }
.rx-items li b { display: block; font-size: 16px; direction: ltr; text-align: right; unicode-bidi: plaintext; }
.rx-items li span { color: var(--ink-2); }
.rx-items li em { display: block; font-style: normal; font-size: 13px; color: var(--warn); }
.rx-foot { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--line); }
.rx-qr { text-align: center; font-size: 12px; color: var(--ink-2); }
.rx-qr svg { display: block; width: 116px; height: 116px; }
.rx-sign { flex: 0 1 220px; max-width: 55%; display: grid; grid-template-areas: "mark" "label"; justify-items: center; align-items: center; text-align: center; }
.rx-stamp, .rx-signature { grid-area: mark; }
.rx-stamp { width: 120px; height: 120px; object-fit: contain; opacity: .88; }
.rx-signature { width: 100%; max-width: 180px; max-height: 80px; object-fit: contain; position: relative; }
.rx-sign small { grid-area: label; align-self: end; width: 100%; display: block; color: var(--ink-3); border-top: 1px solid var(--line); padding-top: 4px; margin-top: 6px; }
.rx-missing { max-width: 520px; margin: 60px auto; padding: 30px; background: #fff; border-radius: 18px; text-align: center; }
@media print {
  .rx-body { background: #fff; padding: 0; }
  .rx-tools { display: none; }
  .rx-sheet { box-shadow: none; border-radius: 0; padding: 0; }
  .rx-check { border: 1px solid #ccc; }
}
@media (prefers-reduced-motion: reduce) { #pt-app *, #pt-app *::before, #pt-app *::after { animation: none !important; transition: none !important; } }
#pt-app .ico.small { width: 15px; height: 15px; vertical-align: -3px; }
#pt-app .av.big { width: 96px; height: 96px; border-radius: 30px; font-size: 32px; margin: 0 auto; }
@media print {
  #pt-app .top, #pt-app .tabs, #pt-app #pr, #pt-app .seg { display: none !important; }
  #pt-app main.page { padding: 0; }
  #pt-app .wallet { color: #000; background: none; box-shadow: none; border: 1px solid #ccc; }
}
#pt-app main.flat .sticky-cta { bottom: calc(12px + env(safe-area-inset-bottom)); }

/* Notifications */
#pt-app .bell { position: relative; }
#pt-app .bell .dot { direction: ltr; position: absolute; top: 5px; right: 4px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 99px; background: var(--bad); color: #fff; font-size: 10.5px; font-weight: 800; line-height: 18px; text-align: center; box-shadow: 0 0 0 2px var(--bg); }
#pt-app .msg { display: flex; gap: 12px; padding: 14px 15px; color: var(--ink); }
#pt-app .msg + .msg { border-top: 1px solid var(--line); }
#pt-app .msg.new { background: color-mix(in srgb, var(--c) 5%, #fff); }
#pt-app .msg.new b::after { content: ""; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--c); margin-right: 6px; vertical-align: middle; }
#pt-app .msg b { display: block; font-size: 15px; }
#pt-app .msg p { margin: 2px 0 4px; font-size: 13.5px; color: var(--ink-2); line-height: 1.65; }
#pt-app .msg small { color: var(--ink-3); font-size: 12px; }
#pt-app .push-card { display: flex; align-items: center; gap: 12px; border: 1px solid #f5d9a8; background: #fffaf0; }

/* Directory */
#pt-app .kinds { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
#pt-app .kinds a { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 14px 6px 12px; border-radius: 18px; background: #fff; box-shadow: var(--shadow); color: var(--ink); text-align: center; }
#pt-app .kinds a b { font-size: 13.5px; font-weight: 800; }
#pt-app .kinds a small { margin-top: -4px; font-size: 11.5px; color: var(--ink-3); }
#pt-app .kind-tabs { display: flex; gap: 8px; overflow-x: auto; margin: 0 -14px 10px; padding: 2px 14px 6px; scrollbar-width: none; }
#pt-app .kind-tabs::-webkit-scrollbar { display: none; }
#pt-app .kind-tabs button { flex: none; display: flex; flex-direction: column; align-items: center; gap: 4px; min-width: 84px; padding: 10px 8px; border-radius: 18px; background: #fff; border: 1.5px solid var(--line); font-weight: 800; font-size: 13px; }
#pt-app .kind-tabs button .tile { width: 36px; height: 36px; border-radius: 12px; }
#pt-app .kind-tabs button .tile .ico { width: 19px; height: 19px; }
#pt-app .kind-tabs button small { font-size: 11px; color: var(--ink-3); font-weight: 700; }
#pt-app .kind-tabs button.on { border-color: var(--c); background: var(--c-soft); color: var(--c); }
#pt-app .place { padding: 0; overflow: hidden; }
#pt-app .place.featured { box-shadow: 0 0 0 1.5px #f5c04a, var(--shadow); }
#pt-app .place-top { display: flex; align-items: flex-start; gap: 13px; padding: 14px; color: var(--ink); }
#pt-app .place-top .grow { flex: 1; min-width: 0; }
#pt-app .place-top h3 { margin: 0; font-size: 16px; font-weight: 800; line-height: 1.45; }
#pt-app .place-top .meta { font-size: 13px; color: var(--ink-2); margin-top: 2px; }
#pt-app .place-top .pill { flex: none; }
#pt-app .clamp { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
#pt-app .place-acts { display: flex; gap: 8px; padding: 0 14px 14px; }
#pt-app .place-acts .btn { flex: 1; min-width: 0; padding: 0 8px; }
#pt-app .place-acts .btn .ico { width: 18px; height: 18px; }
#pt-app .btn.wa { background: #e7f8ee; color: #128c4a; box-shadow: none; }
#pt-app .plogo { width: 62px; height: 62px; border-radius: 18px; flex: none; display: grid; place-items: center; overflow: hidden; color: var(--t, var(--c)); background: color-mix(in srgb, var(--t, var(--c)) 11%, #fff); border: 1px solid var(--line); }
#pt-app .plogo img { width: 100%; height: 100%; object-fit: cover; }
#pt-app .plogo .ico { width: 28px; height: 28px; }
#pt-app .plogo.big { width: 92px; height: 92px; border-radius: 26px; border: 4px solid #fff; box-shadow: 0 8px 20px rgba(17, 26, 43, .14); margin: -58px auto 10px; }
#pt-app .plogo.big .ico { width: 40px; height: 40px; }
#pt-app .stars { display: inline-flex; align-items: center; gap: 3px; color: #b7791f; font-weight: 800; }
#pt-app .stars .ico { fill: #f5b301; stroke: #f5b301; }
#pt-app .stars span { color: var(--ink-3); font-weight: 600; }
#pt-app .phero { margin: 0 -14px 12px; }
#pt-app .pcover { display: block; width: 100%; height: 190px; object-fit: cover; }
#pt-app .pcover.blank { background: linear-gradient(135deg, color-mix(in srgb, var(--t) 80%, #fff), var(--t) 60%, color-mix(in srgb, var(--t) 70%, #000)); }
#pt-app .pcard { position: relative; margin: -34px 14px 0; padding: 0 16px 16px; border-radius: 24px; background: #fff; box-shadow: var(--shadow); text-align: center; }
#pt-app .pcard h2 { margin: 0; font-size: 21px; font-weight: 800; line-height: 1.45; }
#pt-app .pcard > p { margin: 4px 0 0; font-size: 14px; }
#pt-app .pills { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; margin-top: 10px; }
#pt-app .prating { margin-top: 8px; display: flex; gap: 6px; justify-content: center; align-items: center; }
#pt-app .acts-row { display: flex; gap: 8px; margin-top: 16px; }
#pt-app .act { flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 10px 2px; border-radius: 16px; background: var(--c-soft); color: var(--c); font-size: 12px; font-weight: 800; }
#pt-app .act .ico { width: 21px; height: 21px; }
#pt-app .act.primary { background: var(--c); color: #fff; }
#pt-app .act.wa { background: #e7f8ee; color: #128c4a; }
#pt-app .h { margin: 0 0 8px; font-size: 16px; font-weight: 800; }
#pt-app .about { margin: 0; white-space: pre-line; color: var(--ink-2); line-height: 1.85; }
#pt-app .clamp4 { display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
#pt-app .svc { display: flex; flex-wrap: wrap; gap: 8px; }
#pt-app .svc span { display: inline-flex; align-items: center; gap: 5px; padding: 6px 12px; border-radius: 12px; background: #f3f6fa; font-size: 13.5px; font-weight: 600; }
#pt-app .svc .ico { color: var(--ok); }
#pt-app table.hours { width: 100%; border-collapse: collapse; font-size: 14px; }
#pt-app .hours th, #pt-app .hours td { padding: 8px 4px; border-bottom: 1px solid var(--line); text-align: right; }
#pt-app .hours tr:last-child th, #pt-app .hours tr:last-child td { border-bottom: 0; }
#pt-app .hours th { width: 80px; color: var(--ink-2); font-weight: 700; }
#pt-app .card > .line { display: flex; align-items: flex-start; gap: 8px; font-size: 14px; color: var(--ink-2); margin-top: 6px; }
#pt-app .card > .line .ico { width: 18px; height: 18px; margin-top: 3px; color: var(--ink-3); }
#pt-app .kind-pick { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
#pt-app .kind-pick button { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 10px 4px; border-radius: 15px; border: 1.5px solid var(--line); font-weight: 800; font-size: 13px; }
#pt-app .kind-pick button.on { border-color: var(--c); background: var(--c-soft); color: var(--c); }
#pt-app .pics .lbl { display: block; margin-bottom: 6px; font-size: 13.5px; font-weight: 700; color: var(--ink-2); }
#pt-app .pics .upload { width: 100%; flex-direction: column; justify-content: center; min-height: 110px; padding: 8px; gap: 6px; font-weight: 700; color: var(--ink-2); }
#pt-app .pics .upload img { width: 100%; height: 80px; border-radius: 10px; object-fit: cover; }

/* Doctor profile, laid out like the doctor's page on the site */
#pt-app .dp { margin: -6px -14px 12px; }
#pt-app .dp-cover { display: block; width: 100%; height: 180px; object-fit: cover; }
#pt-app .dp-cover.blank { background: linear-gradient(135deg, color-mix(in srgb, var(--t) 75%, #fff), var(--t) 60%, color-mix(in srgb, var(--t) 70%, #000)); }
#pt-app .dp-card { position: relative; margin: -40px 14px 0; padding: 0 16px 16px; border-radius: 24px; background: #fff; box-shadow: var(--shadow); text-align: center; }
#pt-app .plogo.round { border-radius: 50%; }
#pt-app .plogo.dp-photo { width: 112px; height: 112px; border-radius: 50%; border: 5px solid #fff; box-shadow: 0 8px 22px rgba(17, 26, 43, .16); margin: -62px auto 10px; }
#pt-app .plogo.dp-photo .ico { width: 46px; height: 46px; }
#pt-app .dp-name { margin: 0; font-size: 22px; font-weight: 800; line-height: 1.45; }
#pt-app .dp-sub { margin: 6px 0 0; font-size: 14px; font-weight: 600; color: var(--ink-2); line-height: 1.7; }
#pt-app .dp-book { margin-top: 16px; font-size: 17px; min-height: 54px; }
#pt-app .dp-acts { display: flex; justify-content: center; gap: 8px; margin-top: 12px; }
#pt-app .dp-acts button { display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: 12px; background: #f1f4f8; color: var(--ink-2); font-weight: 700; font-size: 13.5px; }
#pt-app .dp-acts .ico { width: 17px; height: 17px; }
#pt-app .dp-tabs { margin: 0 0 12px; }
#pt-app .dp-sec .h { font-size: 17px; margin-bottom: 10px; }
#pt-app .dp-strong { margin: 0 0 6px; font-weight: 700; line-height: 1.8; }
#pt-app .dp-open.on { color: var(--ok); }
#pt-app .dp-open.off { color: var(--bad); }
#pt-app .rich { color: var(--ink-2); line-height: 1.9; font-size: 14.5px; }
#pt-app .rich p { margin: 0 0 10px; }
#pt-app .rich ul, #pt-app .rich ol { margin: 0 0 10px; padding-right: 20px; }
#pt-app .rich li { margin-bottom: 4px; }
#pt-app .rich strong, #pt-app .rich b { color: var(--ink); }
#pt-app .rich h2, #pt-app .rich h3, #pt-app .rich h4 { font-size: 15.5px; color: var(--ink); margin: 12px 0 6px; }
#pt-app .clamp8 { max-height: 13.5em; overflow: hidden; position: relative; }
#pt-app .clamp8::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 3em; background: linear-gradient(transparent, #fff); }
#pt-app .faq details { border-top: 1px solid var(--line); }
#pt-app .faq details:first-child { border-top: 0; }
#pt-app .faq summary { list-style: none; cursor: pointer; padding: 12px 0; font-weight: 700; display: flex; justify-content: space-between; gap: 10px; }
#pt-app .faq summary::-webkit-details-marker { display: none; }
#pt-app .faq summary::after { content: "+"; color: var(--c); font-size: 20px; line-height: 1; }
#pt-app .faq details[open] summary::after { content: "−"; }
#pt-app .faq p { margin: 0 0 12px; color: var(--ink-2); line-height: 1.8; }
#pt-app .rev { display: flex; gap: 12px; padding: 12px 0; }
#pt-app .rev + .rev { border-top: 1px solid var(--line); }
#pt-app .av.sm { width: 40px; height: 40px; border-radius: 50%; font-size: 15px; }
#pt-app .rev-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
#pt-app .rev small { color: var(--ink-3); font-size: 12px; }
#pt-app .rev p { margin: 4px 0 0; line-height: 1.7; }
#pt-app .dcard { padding: 0; overflow: hidden; }
#pt-app .dcard.featured { box-shadow: 0 0 0 1.5px #f5c04a, var(--shadow); }
#pt-app .dcard-top { display: flex; align-items: flex-start; gap: 13px; padding: 14px 14px 10px; color: var(--ink); }
#pt-app .dcard-top .grow { flex: 1; min-width: 0; }
#pt-app .dcard-top h3 { margin: 0; font-size: 16.5px; font-weight: 800; line-height: 1.45; }
#pt-app .dcard-top .meta { font-size: 13px; color: var(--ink-2); margin-top: 3px; }
#pt-app .dcard-top .plogo { width: 72px; height: 72px; }
#pt-app .dcard-tags { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 6px; }
#pt-app .dcard-tags .pill { font-size: 11.5px; }
#pt-app .dcard .fee { margin-top: 6px; font-size: 13.5px; font-weight: 800; color: var(--c); }
#pt-app .dcard .dcard-btn { display: flex; margin: 0 14px 14px; width: auto; min-height: 46px; }


/* ---------------------------------------------------------------- Inside the site's page */
.rx-body { margin: 0; color: var(--ink); line-height: 1.6; font-family: var(--font, system-ui), Tahoma, sans-serif; }
.rx-brand { font-size: 18px; color: var(--c); }

#pt-app {
  min-height: 0; background: transparent; direction: rtl; text-align: right;
  font-family: var(--font, inherit);
  max-width: 1180px; margin: 0 auto; padding: 22px 16px 48px;
  display: grid; grid-template-columns: minmax(0, 1fr); grid-template-areas: "top" "nav" "main"; gap: 0;
}
#pt-app.vpa-guest, #pt-app.vpa-booting { display: block; }
/* Calm the theme's own styles for tags inside the account area. */
#pt-app h1, #pt-app h2, #pt-app h3, #pt-app h4 { font-family: inherit; letter-spacing: normal; text-transform: none; }
#pt-app button { text-transform: none; letter-spacing: normal; line-height: inherit; box-shadow: none; min-height: 0; border-radius: 0; color: inherit; }
#pt-app input, #pt-app select, #pt-app textarea { margin: 0; box-shadow: none; height: auto; max-width: none; }
#pt-app a:hover, #pt-app a:focus { text-decoration: none; }
#pt-app table { margin: 0; border: 0; }
#pt-app td, #pt-app th { border-left: 0; border-right: 0; border-top: 0; }
#pt-app ul, #pt-app ol { margin-top: 0; }
#pt-app img { height: auto; box-shadow: none; }
#pt-app .pt-boot { min-height: 40vh; }
#pt-app .skel { margin-bottom: 10px; }

/* Header row of the account area (the site's header stays above it) */
#pt-app .top { grid-area: top; position: static; min-height: 0; padding: 0 2px 14px; background: none; -webkit-backdrop-filter: none; backdrop-filter: none; border: 0; }
#pt-app .top h1 { font-size: 24px; margin: 0; color: var(--ink); }
#pt-app main.page, #pt-app main.page.flat { grid-area: main; max-width: none; margin: 0; padding: 0; min-width: 0; }

/* Sections menu: a scrolling strip on phones, a side menu on wide screens */
#pt-app .tabs, #pt-app .tabs.sub {
  grid-area: nav; position: static; display: flex; flex-direction: row; justify-content: flex-start; gap: 6px;
  max-width: none; margin: 0 0 16px; padding: 6px; border-radius: 18px; overflow-x: auto; scrollbar-width: none;
  background: #fff; box-shadow: var(--shadow); -webkit-backdrop-filter: none; backdrop-filter: none;
}
#pt-app .tabs::-webkit-scrollbar { display: none; }
#pt-app .tabs a { flex: none; flex-direction: row; gap: 7px; padding: 9px 14px; font-size: 13.5px; border-radius: 13px; white-space: nowrap; position: relative; }
#pt-app .tabs a .ico { width: 19px; height: 19px; }
#pt-app .tabs .badge { position: static; margin-right: 2px; }
#pt-app .tabs .side-brand { display: none; }
#pt-app .sticky-cta, #pt-app main.flat .sticky-cta { bottom: 14px; }
#pt-app .toast { bottom: 22px; }
#pt-app .wallet { margin-top: 2px; }

/* Sign in: a card inside the page */
#pt-app .auth { min-height: 0; max-width: 520px; margin: 0 auto; }
#pt-app .auth-hero { border-radius: 26px 26px 0 0; padding: 30px 24px 66px; }
#pt-app .auth-card { margin: -44px 12px 0; }

/* Profile page */
#pt-app .dp { margin: 0 0 14px; border-radius: 24px; overflow: hidden; }

@media (min-width: 900px) {
  #pt-app { grid-template-columns: 250px minmax(0, 1fr); grid-template-areas: "nav top" "nav main"; column-gap: 22px; padding-top: 30px; }
  #pt-app .tabs, #pt-app .tabs.sub {
    flex-direction: column; align-self: start; position: sticky; top: 110px; margin: 0; padding: 10px; gap: 4px; overflow: visible; border-radius: 20px;
  }
  #pt-app .tabs a { padding: 12px 14px; font-size: 15px; }
  #pt-app .tabs .badge { margin-right: auto; }
  #pt-app .top h1 { font-size: 26px; }
  #pt-app .stats { grid-template-columns: repeat(4, 1fr); }
  #pt-app .kind-pick { grid-template-columns: repeat(4, 1fr); }
  #pt-app .dp-cover { height: 240px; }
  #pt-app .dp-card { margin: -60px 24px 0; }
  #pt-app .sheet-back { align-items: center; }
  #pt-app .sheet { border-radius: 26px; }
  #pt-app .sticky-cta { max-width: 520px; margin-right: auto; margin-left: auto; }
  #pt-app .grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; align-items: start; }
  #pt-app .grid2 > .card { margin-bottom: 0; }
}
#pt-app .lbl-t { display: block; margin-bottom: 8px; font-size: 13.5px; font-weight: 700; color: var(--ink-2); }
#pt-app .add-card { display: flex; align-items: center; gap: 12px; color: var(--ink); border: 1px dashed color-mix(in srgb, #0e9f6e 45%, #fff); background: #f4fbf7; }
#pt-app .add-card b { display: block; font-size: 15px; }
#pt-app .add-card span { display: block; font-size: 13px; color: var(--ink-2); }
#pt-app .add-card .chev { color: var(--ink-3); width: 18px; height: 18px; }
#pt-app .gal-pick { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
#pt-app .gal-item { position: relative; display: block; aspect-ratio: 1; border-radius: 12px; overflow: hidden; background: #eef1f5; }
#pt-app .gal-item img { width: 100%; height: 100%; object-fit: cover; display: block; }
#pt-app .gal-item button { position: absolute; top: 4px; left: 4px; width: 24px; height: 24px; border-radius: 50%; background: rgba(17, 26, 43, .7); color: #fff; font-size: 16px; line-height: 24px; text-align: center; }
#pt-app .gal-add { aspect-ratio: 1; flex-direction: column; justify-content: center; gap: 4px; padding: 6px; font-size: 12px; font-weight: 700; color: var(--ink-2); }

/* Notifications, always in sight */
/* Header: wallet, points and notifications side by side */
#pt-app .top { flex-wrap: wrap; row-gap: 12px; }
#pt-app .top-chips { display: flex; align-items: stretch; gap: 8px; margin-right: auto; flex-wrap: nowrap; }
#pt-app .chip-w { position: relative; display: flex; align-items: center; gap: 9px; padding: 7px 14px 7px 10px; border-radius: 15px; background: #fff; color: var(--ink) !important; border: 1px solid var(--line); box-shadow: 0 1px 2px rgba(17, 26, 43, .04), 0 6px 16px -10px rgba(17, 26, 43, .18); transition: transform .15s, box-shadow .15s; white-space: nowrap; }
#pt-app .chip-w:hover { transform: translateY(-1px); box-shadow: 0 1px 2px rgba(17, 26, 43, .05), 0 10px 22px -12px rgba(17, 26, 43, .28); }
#pt-app .chip-ic { flex: none; width: 34px; height: 34px; border-radius: 11px; display: grid; place-items: center; }
#pt-app .chip-ic svg { width: 19px; height: 19px; fill: none !important; stroke: currentColor !important; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
#pt-app .chip-t { display: flex; flex-direction: column; line-height: 1.2; min-width: 0; }
#pt-app .chip-t small { font-size: 11px; font-weight: 700; color: var(--ink-3); }
#pt-app .chip-t b { font-size: 14.5px; font-weight: 800; color: var(--ink); }
#pt-app .chip-wallet .chip-ic { background: color-mix(in srgb, #12a05f 12%, #fff); color: #12a05f; }
#pt-app .chip-points .chip-ic { background: #fff5e0; color: #c2750a; }
#pt-app .bell-pill .chip-ic { background: var(--c-soft); color: var(--c); }
#pt-app .bell-pill.has { border-color: color-mix(in srgb, var(--bad) 35%, #fff); background: color-mix(in srgb, var(--bad) 4%, #fff); }
#pt-app .bell-pill.has .chip-ic { background: var(--bad); color: #fff; }
#pt-app .bell-pill.has .chip-t b { color: var(--bad); }
#pt-app .bell-pill.has .chip-ic svg { animation: vpa-ring 1.6s ease-in-out 2; transform-origin: 50% 10%; }
#pt-app .bell-pill .dot { position: absolute; top: -7px; left: -7px; right: auto; min-width: 22px; height: 22px; line-height: 22px; padding: 0 6px; border-radius: 99px; background: var(--bad); color: #fff; font-size: 11.5px; font-weight: 800; text-align: center; box-shadow: 0 0 0 2.5px #fff; }
#pt-app .bell-pill .dot[hidden] { display: none !important; }
@keyframes vpa-ring { 0%, 60%, 100% { transform: rotate(0); } 10%, 30% { transform: rotate(14deg); } 20%, 40% { transform: rotate(-14deg); } }
/* Phones: the three sit in one even row under the title */
@media (max-width: 640px) {
  #pt-app .top-chips { flex: 1 0 100%; margin: 0; display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 6px; }
  #pt-app .chip-w { flex-direction: column; gap: 4px; padding: 9px 4px 8px; text-align: center; border-radius: 14px; }
  #pt-app .chip-ic { width: 30px; height: 30px; border-radius: 10px; }
  #pt-app .chip-t { align-items: center; }
  #pt-app .chip-t b { font-size: 13px; }
  #pt-app .bell-pill .dot { top: -6px; left: 6px; right: auto; }
}
/* Turn on notifications: first thing on the screen */
#pt-app .push-top { flex: 1 0 100%; order: -1; display: flex; align-items: center; gap: 12px; margin: 0; padding: 12px 14px; border-radius: 16px; color: #fff; background: linear-gradient(120deg, var(--c), color-mix(in srgb, var(--c) 60%, #7c3aed)); box-shadow: 0 12px 26px -16px var(--c); border: 0; }
#pt-app .push-top .chip-ic { background: rgba(255, 255, 255, .18); color: #fff; }
#pt-app .push-top .chip-ic svg { animation: vpa-ring 1.6s ease-in-out infinite; transform-origin: 50% 10%; }
#pt-app .push-top b { display: block; font-size: 15px; color: #fff; }
#pt-app .push-top .small { font-size: 12.5px; opacity: .9; line-height: 1.5; }
#pt-app .push-top .btn { flex: none; background: #fff; color: var(--c); font-weight: 800; box-shadow: none; }
#pt-app .push-later { flex: none; width: 30px; height: 30px; border-radius: 50%; background: rgba(255, 255, 255, .16); color: #fff; font-size: 18px; line-height: 30px; text-align: center; }
@media (max-width: 480px) { #pt-app .push-top { flex-wrap: wrap; } #pt-app .push-top .grow { flex: 1 1 calc(100% - 90px); } #pt-app .push-top .btn { flex: 1; } }
#pt-app .tabs .badge[hidden] { display: none !important; }
#pt-app .inbox-home { border: 1.5px solid color-mix(in srgb, var(--bad) 25%, #fff); margin-bottom: 14px; }
#pt-app .inbox-home-h { display: flex; align-items: center; gap: 12px; padding: 12px 15px; border-bottom: 1px solid var(--line); }
#pt-app .inbox-home-h b { font-size: 15.5px; }
#pt-app .site-page { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
#pt-app .site-page .grow { min-width: 160px; }
#pt-pop { position: fixed; z-index: 99999; top: 18px; left: 50%; transform: translateX(-50%); width: min(440px, calc(100vw - 24px)); display: flex; align-items: center; gap: 12px; padding: 13px 15px; border-radius: 18px; background: #18202e; color: #fff !important; text-decoration: none !important; direction: rtl; text-align: right; font-family: inherit; box-shadow: 0 18px 40px rgba(0, 0, 0, .3); animation: vpa-drop .35s cubic-bezier(.2, .8, .2, 1); }
#pt-pop .pt-pop-ic { flex: none; width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: #e5484d; }
#pt-pop .pt-pop-ic svg { width: 22px; height: 22px; fill: none; stroke: #fff; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
#pt-pop .pt-pop-t { flex: 1; min-width: 0; }
#pt-pop b { display: block; font-size: 15px; line-height: 1.4; color: #fff; }
#pt-pop small { display: block; font-size: 13px; line-height: 1.5; opacity: .85; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
#pt-pop .pt-pop-x { flex: none; width: 28px; height: 28px; border-radius: 50%; text-align: center; line-height: 28px; font-size: 18px; background: rgba(255, 255, 255, .12); }
@keyframes vpa-drop { from { opacity: 0; transform: translate(-50%, -16px); } to { opacity: 1; transform: translate(-50%, 0); } }
#pt-app .inbox-home-h .btn { flex: none; white-space: nowrap; }

/* Family */
#pt-app .fam-av { background: linear-gradient(145deg, color-mix(in srgb, var(--t) 75%, #fff), var(--t)); }
#pt-app .av.lg { width: 58px; height: 58px; font-size: 20px; border-radius: 18px; }
#pt-app .av.xl { width: 68px; height: 68px; font-size: 23px; border-radius: 21px; }
#pt-app .fam-grid { display: grid; gap: 12px; }
@media (min-width: 900px) { #pt-app .fam-grid { grid-template-columns: 1fr 1fr; } }
#pt-app .fam-card { margin: 0; display: flex; flex-direction: column; gap: 12px; }
#pt-app .fam-top { display: flex; align-items: center; gap: 12px; color: var(--ink); }
#pt-app .fam-top b { font-size: 16.5px; }
#pt-app .fam-top .chev { color: var(--ink-3); width: 18px; height: 18px; }
#pt-app .fam-acts { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
#pt-app .fam-acts .btn { width: 100%; }
#pt-app .fam-warn { display: inline-flex; align-items: center; gap: 5px; margin-top: 5px; padding: 3px 9px; border-radius: 9px; background: var(--bad-soft); color: #a32025; font-size: 12.5px; font-weight: 700; }
#pt-app .fam-add { margin: 0; display: flex; align-items: center; gap: 12px; color: var(--ink); border: 1.5px dashed color-mix(in srgb, #0e9f6e 45%, #fff); background: #f4fbf7; min-height: 92px; }
#pt-app .fam-add b { display: block; font-size: 15.5px; }
#pt-app .fam-add span { font-size: 13px; color: var(--ink-2); }
#pt-app .rel-pick { display: flex; flex-wrap: wrap; gap: 8px; }
#pt-app .rel-pick button { padding: 9px 15px; border-radius: 12px; border: 1.5px solid var(--line); background: #fff; font-weight: 700; font-size: 14px; color: var(--ink-2); }
#pt-app .rel-pick button.on { border-color: var(--t); background: color-mix(in srgb, var(--t) 10%, #fff); color: var(--t); }
#pt-app .mem-head { display: flex; align-items: center; gap: 14px; }
#pt-app .mem-head h2 { margin: 0; font-size: 20px; }
#pt-app .mem-health { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-bottom: 12px; }
#pt-app .mem-health > div { padding: 10px 12px; border-radius: 14px; background: #fff; box-shadow: var(--shadow); min-width: 0; }
#pt-app .mem-health small { display: block; color: var(--ink-3); font-size: 11.5px; font-weight: 700; }
#pt-app .mem-health b { display: block; font-size: 14px; overflow-wrap: anywhere; }
#pt-app .mem-health .warn { background: var(--bad-soft); }
#pt-app .mem-health .warn b { color: #a32025; }
@media (max-width: 560px) { #pt-app .mem-health { grid-template-columns: 1fr 1fr; } }
#pt-app .tl { position: relative; padding-right: 4px; }
#pt-app .tl::before { content: ""; position: absolute; top: 10px; bottom: 10px; right: 24px; width: 2px; background: var(--line); }
#pt-app .tl-item { position: relative; display: flex; gap: 12px; margin-bottom: 10px; }
#pt-app .tl-item > .tile { position: relative; z-index: 1; box-shadow: 0 0 0 4px var(--bg); }
#pt-app .tl-body { position: relative; flex: 1; min-width: 0; padding: 12px 14px; border-radius: 16px; background: #fff; box-shadow: var(--shadow); }
#pt-app .tl-body b { display: block; font-size: 15px; }
#pt-app .tl-body p { margin: 6px 0 0; font-size: 13.5px; color: var(--ink-2); white-space: pre-line; }
#pt-app .tl-day { font-size: 12px; font-weight: 700; color: var(--c); }
#pt-app .tl-file img { display: block; margin-top: 8px; max-width: 160px; max-height: 120px; border-radius: 10px; object-fit: cover; border: 1px solid var(--line); }
#pt-app .tl-del { position: absolute; top: 8px; left: 8px; width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; color: var(--ink-3); }
#pt-app .tl-del svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.9; }
#pt-app .rec-kinds { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin-bottom: 14px; }
#pt-app .rec-kinds button { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 8px 4px; border-radius: 13px; border: 1.5px solid var(--line); font-size: 12px; font-weight: 700; color: var(--ink-2); }
#pt-app .rec-kinds button .tile { width: 34px; height: 34px; border-radius: 10px; }
#pt-app .rec-kinds button.on { border-color: var(--c); background: var(--c-soft); color: var(--c); }
#pt-app .for-pick { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; scrollbar-width: none; }
#pt-app .for-pick button { flex: none; display: flex; align-items: center; gap: 9px; padding: 8px 14px 8px 10px; border-radius: 15px; border: 1.5px solid var(--line); background: #fff; text-align: right; }
#pt-app .for-pick .av { width: 36px; height: 36px; font-size: 13px; border-radius: 11px; }
#pt-app .for-pick b { display: block; font-size: 14px; }
#pt-app .for-pick small { display: block; font-size: 11.5px; color: var(--ink-3); }
#pt-app .for-pick button.on { border-color: var(--c); background: var(--c-soft); box-shadow: 0 0 0 3px color-mix(in srgb, var(--c) 15%, transparent); }
#pt-app .for-tag { display: inline-flex; align-items: center; gap: 4px; padding: 2px 9px; border-radius: 9px; background: color-mix(in srgb, #0e9f6e 10%, #fff); color: #0a7a54; font-weight: 700; font-size: 12.5px; }
#pt-app .for-tag small { font-weight: 600; opacity: .85; }

/* Referrals */
#pt-app .pts-hero { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; padding: 20px; border-radius: 22px; color: #fff; background: linear-gradient(135deg, #e0911a, #c2750a 55%, #9a5a06); box-shadow: 0 14px 30px -18px #c2750a; }
#pt-app .pts-hero small { display: block; opacity: .9; font-weight: 700; }
#pt-app .pts-hero > div > b { display: block; font-size: 36px; line-height: 1.2; font-weight: 900; }
#pt-app .pts-hero span { font-size: 13.5px; opacity: .95; }
#pt-app .pts-hero .tile { width: 56px; height: 56px; border-radius: 18px; background: rgba(255, 255, 255, .18); }
#pt-app .how > b { display: block; margin-bottom: 4px; font-size: 15.5px; }
#pt-app .how .list-row { padding: 7px 0; font-size: 13.5px; }
#pt-app .ref-row { display: flex; align-items: flex-start; gap: 12px; padding: 13px 15px; }
#pt-app .ref-row + .ref-row { border-top: 1px solid var(--line); }
#pt-app .ref-row b { display: block; font-size: 14.5px; }
#pt-app .ref-side { flex: none; display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
#pt-app .ref-side small { color: #c2750a; font-weight: 800; }
#pt-app .pick-list { display: grid; gap: 6px; margin-top: 10px; max-height: 330px; overflow-y: auto; }
#pt-app .pick { display: flex; align-items: center; gap: 10px; padding: 9px 11px; border-radius: 14px; border: 1.5px solid var(--line); background: #fff; text-align: right; }
#pt-app .pick .av { width: 40px; height: 40px; font-size: 14px; border-radius: 12px; }
#pt-app .pick b { display: block; font-size: 14.5px; }
#pt-app .pick small { display: block; color: var(--ink-3); font-size: 12px; }
#pt-app .pick .pick-ok { visibility: hidden; color: var(--c); }
#pt-app .pick.on { border-color: var(--c); background: var(--c-soft); }
#pt-app .pick.on .pick-ok { visibility: visible; }
#pt-app .ref-promo { border-color: color-mix(in srgb, #c2750a 40%, #fff); background: #fffaf0; }
#pt-app .banner.ok.rec-banner { background: #fff7e8; border-color: #f5d9a8; color: #6b4304; } #pt-app .banner.ok.rec-banner .ico { color: #c2750a; } #pt-app .rec-why { border: 1.5px solid #f5d9a8; background: #fffdf8; }

/* ------------------------------------------------------------ مرضاي (invites) */
#pt-app .inv-hero { background: linear-gradient(135deg, #2b7be6, #035dcd 55%, #02449a); box-shadow: 0 14px 30px -18px #035dcd; }
#pt-app .inv-promo { border-color: color-mix(in srgb, #035dcd 40%, #fff); background: #f3f8ff; }
#pt-app .inv-gen { display: flex; align-items: center; gap: 12px; }
#pt-app .inv-gen b { display: block; font-size: 15px; }
#pt-app .inv-gen span { display: block; font-size: 12.5px; color: var(--ink-2); }
#pt-app .inv-row { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-bottom: 1px solid var(--line, #eef1f5); }
#pt-app .inv-row:last-child { border-bottom: 0; }
#pt-app .inv-row b { display: block; font-size: 15px; }
#pt-app .inv-av { width: 40px; height: 40px; border-radius: 50%; flex: none; display: grid; place-items: center; font-weight: 800; color: #c2750a; background: #fff4e0; }
#pt-app .inv-row.ok .inv-av { color: #12a05f; background: #e8f8ef; }
#pt-app .inv-btns { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; }
#pt-app .inv-btns > div { display: flex; gap: 6px; }
#pt-app .inv-btns .icon-btn { width: 34px; height: 34px; border-radius: 10px; border: 1px solid var(--line, #e4e8ee); background: #fff; display: grid; place-items: center; cursor: pointer; color: var(--ink-2); padding: 0; }
#pt-app .inv-btns [data-send] { color: #12a05f; }
#pt-app .inv-btns [data-del]:hover { color: var(--bad, #e5484d); }
#pt-app .inv-btns .ico { width: 18px; height: 18px; }
#pt-app .inv-sheet { text-align: center; }
#pt-app .inv-sheet > .tile { margin: 0 auto 8px; width: 52px; height: 52px; }
#pt-app .inv-msg { margin: 12px 0; padding: 12px 14px; border-radius: 14px; background: #e7f6ec; color: #0f3d22; text-align: right; font-size: 13.5px; line-height: 1.8; word-break: break-word; border: 1px solid #c5ead2; }
#pt-app .inv-acts { display: flex; flex-wrap: wrap; gap: 8px; }
#pt-app .inv-acts .btn { flex: 1 1 30%; min-width: 0; white-space: nowrap; padding-inline: 10px; font-size: 14px; }
#pt-app .inv-acts .btn.wa { background: #25d366; color: #fff; border-color: #25d366; }
#pt-app .inv-banner { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; padding: 12px 14px; border-radius: 16px; color: #fff; background: linear-gradient(135deg, #2b7be6, #035dcd 60%, #02449a); box-shadow: 0 12px 26px -16px #035dcd; text-align: right; }
#pt-app .inv-banner img, #pt-app .inv-banner > .tile { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; flex: none; border: 2px solid rgba(255,255,255,.6); background: rgba(255,255,255,.15); }
#pt-app .inv-banner > div:not(.inv-gift) { flex: 1; min-width: 0; }
#pt-app .inv-banner small { display: block; font-size: 12px; opacity: .85; }
#pt-app .inv-banner b { display: block; font-size: 16px; }
#pt-app .inv-banner span { display: block; font-size: 12.5px; opacity: .9; }
#pt-app .inv-gift { flex: none; text-align: center; padding: 6px 10px; border-radius: 12px; background: #fff; color: #c2750a; }
#pt-app .inv-gift .ico { width: 18px; height: 18px; display: block; margin: 0 auto; }
#pt-app .inv-gift b { font-size: 18px; line-height: 1.2; color: #c2750a; }
#pt-app .inv-gift small { font-size: 11px; color: #9a5a06; opacity: 1; }

/* ------------------------------------------------------------ Points → balance */
#pt-app .conv-card { display: flex; align-items: center; gap: 12px; border: 1px dashed color-mix(in srgb, #c2750a 45%, #fff); background: #fffaf1; }
#pt-app .conv-card.ready { border-color: color-mix(in srgb, #12a05f 45%, #fff); background: #f2fbf6; }
#pt-app .conv-card b { font-size: 15px; }
#pt-app .conv-card .grow > b { display: block; }
#pt-app .conv-card .grow > span { display: block; font-size: 12.5px; color: var(--ink-2); }
#pt-app .conv-card .conv-worth { color: #12a05f !important; font-weight: 800; font-size: 13.5px !important; margin-top: 2px; }
#pt-app .conv-bar { height: 7px; border-radius: 99px; background: #f3e4c8; margin: 6px 0 3px; overflow: hidden; }
#pt-app .conv-bar i { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, #e0911a, #c2750a); }
#pt-app .conv-card .btn { flex: none; }
#pt-app .conv-card .btn[disabled] { opacity: .55; }
#pt-app .conv-sheet { text-align: center; }
#pt-app .conv-sheet > .tile { margin: 0 auto 8px; width: 52px; height: 52px; }
#pt-app .conv-sheet .field { text-align: right; margin-top: 14px; }
#pt-app .conv-sheet .input { font-size: 22px; font-weight: 800; text-align: center; }
#pt-app .conv-chips { display: flex; justify-content: center; gap: 8px; margin: 4px 0 12px; flex-wrap: wrap; }
#pt-app .conv-chips .chip { border: 1px solid var(--line, #e4e8ee); background: #fff; border-radius: 99px; padding: 6px 14px; font: inherit; font-weight: 700; cursor: pointer; }
#pt-app .conv-out { padding: 14px; border-radius: 16px; background: #e8f8ef; color: #0f5132; margin-bottom: 6px; }
#pt-app .conv-out small { display: block; font-weight: 700; opacity: .8; }
#pt-app .conv-out b { font-size: 28px; font-weight: 900; }
#pt-app .conv-sheet .hint.bad { color: var(--bad, #e5484d); }
