/* ============================================================
   brand.css — Pak-Qatar brand (logo green + maroon), animations,
   and responsive layouts: phone · tablet · laptop/desktop dashboard
   ============================================================ */
:root {
  --pq-green: #0a7149;
  --pq-green-d: #075a39;
  --pq-green-dd: #053d27;
  --pq-green-l: #e7f4ed;
  --pq-maroon: #85173a;
  --pq-maroon-d: #5e0f28;
  --pq-maroon-l: #f8e9ee;
  --ease: cubic-bezier(.2, .75, .2, 1);
  --sb-w: 276px;
}
html[data-theme="dark"] { --pq-maroon-l: #3a1822; }

/* ---------- Brand touches (all devices) ---------- */
#statusbar { background: var(--pq-green-dd); }
#header { background: linear-gradient(120deg, var(--pq-green-d) 0%, var(--pq-green) 62%, #0d7e52 100%); position: relative; }
#header::after { /* logo swoosh: green → maroon */
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 3px;
  background: linear-gradient(90deg, #39b37d 0%, var(--pq-green) 40%, var(--pq-maroon) 60%, #b0345a 100%);
}
.sec-head { display: flex; align-items: center; gap: 8px; }
.sec-head::before { content: ""; width: 4px; height: 14px; border-radius: 3px; background: linear-gradient(180deg, var(--pq-maroon), #b0345a); flex-shrink: 0; }
.hero-banner { background: linear-gradient(135deg, var(--pq-green-dd) 0%, var(--pq-green) 55%, #13915f 100%); box-shadow: 0 10px 28px rgba(10, 113, 73, .25); }
.hero-banner::before { background: radial-gradient(circle, rgba(133, 23, 58, .55), rgba(133, 23, 58, 0) 70%) !important; width: 220px !important; height: 220px !important; right: -60px !important; bottom: -90px !important; }
.hero-hello { font-size: 11.5px; font-weight: 600; opacity: .85; margin-bottom: 6px; position: relative; letter-spacing: .2px; }
.hero-hello:empty { display: none; }
.prod-card .pc-badge.pc-badge-blink { background: var(--pq-maroon-l); color: var(--pq-maroon); }
html[data-theme="dark"] .prod-card .pc-badge.pc-badge-blink { color: #f19ab4; }
.tab-item .ti-dot { background: var(--pq-maroon); width: 5px; height: 5px; }
.tab-item.active .ti-label { color: var(--pq-green); }
html[data-theme="dark"] .tab-item.active .ti-label { color: #4fbf8e; }
.stab.active { background: linear-gradient(135deg, var(--pq-green-d), var(--pq-green)); border-color: var(--pq-green); }
.qr-btn { border-color: var(--pq-maroon); color: var(--pq-maroon); }
.qr-btn:active, .qr-btn:hover { background: var(--pq-maroon); color: #fff; }
html[data-theme="dark"] .qr-btn { border-color: #d0567d; color: #f19ab4; }
.hosp-city-header { background: linear-gradient(135deg, var(--pq-maroon-d), var(--pq-maroon)) !important; }
#help-btn { font-weight: 800; font-family: 'Inter', sans-serif; font-size: 15px; }
.desk-search { display: none; }
#sidebar { display: none; }

/* ---------- Motion: screens, cards, presses ---------- */
@keyframes pqIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes pqFade { from { opacity: 0; } to { opacity: 1; } }
@keyframes pqPop { from { opacity: 0; transform: translateY(14px) scale(.97); } to { opacity: 1; transform: none; } }
.pq-ready #home-screen, #calc-screen.active, #hosp-screen.active, #greeting-screen.active,
#calc-tool-screen.active, #sfp-screen.active, #iframe-screen.active { animation: pqIn .34s var(--ease); }
#detail-screen.active { animation: pqFade .25s ease-out; }
.pq-ready .prod-card, .pq-ready .tool-card, .pq-ready .calc-card, .pq-ready .pq-banner, .pq-ready .info-strip { animation: pqPop .45s var(--ease) both; }
.prod-grid > :nth-child(2), .tools-grid > :nth-child(2), .calc-grid > :nth-child(2) { animation-delay: .04s !important; }
.prod-grid > :nth-child(3), .tools-grid > :nth-child(3), .calc-grid > :nth-child(3) { animation-delay: .08s !important; }
.prod-grid > :nth-child(4), .tools-grid > :nth-child(4), .calc-grid > :nth-child(4) { animation-delay: .12s !important; }
.prod-grid > :nth-child(5), .tools-grid > :nth-child(5), .calc-grid > :nth-child(5) { animation-delay: .16s !important; }
.prod-grid > :nth-child(n+6), .tools-grid > :nth-child(n+6), .calc-grid > :nth-child(n+6) { animation-delay: .2s !important; }
.prod-card, .tool-card, .calc-card, .info-strip, .pq-banner, .stab, .qr-btn, .header-action, .tab-item { transition: transform .18s var(--ease), box-shadow .2s, border-color .2s, background .2s; }
@media (hover: hover) and (pointer: fine) {
  .prod-card:hover, .calc-card:hover { transform: translateY(-3px); box-shadow: 0 12px 28px rgba(10, 60, 40, .14); border-color: var(--card-accent, var(--cc-accent, var(--pq-green))); }
  .tool-card:hover { transform: translateY(-2px); box-shadow: 0 8px 20px rgba(10, 60, 40, .12); border-color: var(--pq-green); }
  .info-strip:hover { border-color: var(--pq-green); background: var(--primary-light); }
  .pq-banner:hover { transform: translateY(-2px); box-shadow: 0 12px 28px rgba(0, 0, 0, .22); }
  .stab:hover { border-color: var(--pq-green); }
  .header-action:hover { filter: brightness(1.12); }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

/* layout wrappers created by screens.js (same look as before on phones) */
.banner-grid, .strip-grid { display: flex; flex-direction: column; gap: 10px; }
.banner-grid .pq-banner { margin-bottom: 0; }

/* ---------- Splash: animated Pak-Qatar logo ---------- */
#boot-splash {
  position: fixed; inset: 0; z-index: 9999; display: flex; align-items: center; justify-content: center; overflow: hidden;
  background: radial-gradient(circle at 50% 42%, #ffffff 0%, #f5faf7 55%, #e6f1eb 100%);
  transition: opacity .5s ease, transform .55s var(--ease);
}
#boot-splash.hide { opacity: 0; transform: scale(1.05); pointer-events: none; }
.sp-glow { position: absolute; width: 520px; height: 520px; border-radius: 50%; background: radial-gradient(circle, rgba(10, 113, 73, .13), rgba(133, 23, 58, .05) 45%, transparent 68%); animation: spPulse 2.6s ease-in-out infinite; }
.sp-stage { position: relative; display: flex; flex-direction: column; align-items: center; }
.sp-seal-wrap { position: relative; width: 140px; height: 140px; display: grid; place-items: center; }
.sp-seal { width: 128px; height: auto; animation: spSeal 1.15s var(--ease) both; }
.sp-ring { position: absolute; inset: -6px; border-radius: 50%; border: 3px solid transparent; border-top-color: var(--pq-green); border-right-color: var(--pq-maroon); opacity: 0; animation: spFadeIn .4s .35s forwards, spSpin 1.1s linear infinite; }
.sp-swoosh { width: 176px; height: auto; margin-top: 10px; clip-path: inset(0 100% 0 0); animation: spWipe .75s .7s cubic-bezier(.6, 0, .2, 1) forwards; }
.sp-text { width: 232px; height: auto; margin-top: 12px; opacity: 0; animation: spUp .6s 1s var(--ease) forwards; }
.sp-app { margin-top: 18px; font: 600 15px 'Inter', 'DM Sans', sans-serif; color: #44524c; letter-spacing: .4px; opacity: 0; animation: spUp .5s 1.3s var(--ease) forwards; }
.sp-app b { color: var(--pq-maroon); font-weight: 800; }
.sp-bar { width: 150px; height: 3px; border-radius: 3px; background: #dbe8e0; margin-top: 16px; overflow: hidden; opacity: 0; animation: spUp .4s 1.4s forwards; }
.sp-bar span { display: block; height: 100%; width: 40%; border-radius: 3px; background: linear-gradient(90deg, var(--pq-green), var(--pq-maroon)); animation: spSlide 1s ease-in-out infinite; }
.pq-quick .sp-seal, .pq-quick .sp-swoosh, .pq-quick .sp-text, .pq-quick .sp-app, .pq-quick .sp-bar { animation-delay: 0s !important; animation-duration: .35s !important; }
.pq-quick .sp-ring { animation: spFadeIn .2s forwards, spSpin 1.1s linear infinite; }
@keyframes spSeal { 0% { opacity: 0; transform: scale(.35) rotate(-140deg); filter: blur(4px); } 65% { opacity: 1; filter: blur(0); } 100% { transform: scale(1) rotate(0); } }
@keyframes spSpin { to { transform: rotate(360deg); } }
@keyframes spFadeIn { to { opacity: 1; } }
@keyframes spWipe { to { clip-path: inset(0 0 0 0); } }
@keyframes spUp { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes spSlide { 0% { transform: translateX(-100%); } 100% { transform: translateX(260%); } }
@keyframes spPulse { 0%, 100% { transform: scale(.92); opacity: .8; } 50% { transform: scale(1.06); opacity: 1; } }

/* ---------- Guided tour ---------- */
.tour-ov { position: fixed; inset: 0; z-index: 10000; display: none; }
.tour-ov.show { display: block; }
.tour-ov.center { background: rgba(6, 22, 15, .62); backdrop-filter: blur(2px); animation: pqFade .25s; }
.tour-hole { position: fixed; border-radius: 14px; box-shadow: 0 0 0 9999px rgba(6, 22, 15, .62), 0 0 0 3px rgba(255, 255, 255, .9), 0 0 0 7px rgba(133, 23, 58, .55); transition: all .38s var(--ease); pointer-events: none; }
.tour-card {
  position: fixed; width: min(360px, calc(100vw - 24px)); background: var(--surface); color: var(--text); border-radius: 18px; padding: 18px 18px 14px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, .35); font-family: 'DM Sans', sans-serif; transition: left .38s var(--ease), top .38s var(--ease), opacity .2s; animation: pqPop .35s var(--ease);
}
.tour-card.moving { opacity: .0; }
.tour-card h3 { margin: 6px 0 6px; font: 800 17px 'Inter', sans-serif; color: var(--text); }
.tour-card p { margin: 0; font-size: 13.5px; line-height: 1.55; color: var(--text-2); }
.tour-prog { display: flex; gap: 4px; flex-wrap: wrap; }
.tour-prog i { height: 4px; flex: 1; min-width: 8px; border-radius: 4px; background: var(--border); }
.tour-prog i.past { background: var(--pq-green); }
.tour-prog i.on { background: linear-gradient(90deg, var(--pq-green), var(--pq-maroon)); }
.tour-acts { display: flex; align-items: center; gap: 8px; margin-top: 16px; }
.tour-n { margin-left: auto; font-size: 12px; color: var(--text-3); font-weight: 600; }
.tour-btn { border: 0; border-radius: 11px; padding: 10px 16px; font: 700 13.5px 'DM Sans', sans-serif; cursor: pointer; background: linear-gradient(135deg, var(--pq-green-d), var(--pq-green)); color: #fff; box-shadow: 0 4px 12px rgba(10, 113, 73, .3); }
.tour-btn.ghost { background: transparent; color: var(--text-2); box-shadow: none; padding: 10px 10px; }
.tour-btn.sm { font-size: 12px; padding: 8px 4px; }
.tour-card.welcome { text-align: center; width: min(400px, calc(100vw - 32px)); padding: 26px 24px 18px; left: 50% !important; top: 50% !important; transform: translate(-50%, -50%); animation: none; }
.tour-card.welcome .tour-acts { justify-content: center; }
.tw-logo { display: flex; flex-direction: column; align-items: center; gap: 6px; margin-bottom: 8px; }
.tw-logo img { width: 84px; animation: spSeal .9s var(--ease) both; }
.tw-logo .tw-sw { width: 120px; clip-path: inset(0 100% 0 0); animation: spWipe .6s .45s forwards; }
.tour-card.welcome h3 { font-size: 20px; }

/* ============================================================
   TABLET (700–1023px): full width, more columns, bottom tabs
   ============================================================ */
@media (min-width: 700px) {
  #app { max-width: none; }
  #home-screen, #calc-screen { padding: 22px 28px 32px; }
  #home-screen > *, #calc-screen > * { width: 100%; max-width: 980px; margin-left: auto; margin-right: auto; }
  .prod-grid { grid-template-columns: repeat(3, 1fr); gap: 14px; }
  .tools-grid { grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 12px; }
  .calc-grid { grid-template-columns: repeat(3, 1fr); gap: 14px; }
  .banner-grid, .strip-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .detail-body, .qr-strip { width: 100%; max-width: 820px; margin-left: auto; margin-right: auto; }
  .detail-header { padding-left: max(18px, calc((100% - 820px) / 2 + 16px)); padding-right: max(18px, calc((100% - 820px) / 2 + 16px)); }
  .sub-tabs { padding-left: max(16px, calc((100% - 820px) / 2 + 16px)); padding-right: 16px; }
  #ct-native > *, #sfp-native > * { max-width: 820px; margin-left: auto !important; margin-right: auto !important; }
  .ct-features-list { display: grid; grid-template-columns: 1fr 1fr; }
  .gc-wrap { max-width: 900px; margin: 0 auto; width: 100%; }
  .hero-title { font-size: 21px; }
  .hero-stat .val { font-size: 15px; }
  #share-modal { align-items: center !important; }
  #share-modal > div { border-radius: 20px !important; }
  .pq-toast-bar { bottom: calc(84px + env(safe-area-inset-bottom)); }
}

/* ============================================================
   LAPTOP / DESKTOP (≥1024px): dashboard with sidebar
   ============================================================ */
@media (min-width: 1024px) {
  html, body { background: var(--bg) !important; }
  body { display: block; }
  #app {
    width: 100%; height: 100vh; height: 100dvh; max-width: none; border-radius: 0; box-shadow: none;
    display: grid; grid-template-columns: var(--sb-w) minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr);
  }
  #app > * { grid-column: 2; grid-row: 2; min-height: 0; min-width: 0; }
  #statusbar, #tab-bar, #search-toggle-btn, #home-search-wrap { display: none !important; }

  /* sidebar */
  #sidebar {
    display: flex; flex-direction: column; grid-column: 1; grid-row: 1 / span 2; min-height: 0;
    background: linear-gradient(180deg, var(--pq-green-dd) 0%, #06482f 55%, #073a28 100%); color: #e7f4ed; position: relative; overflow: hidden;
  }
  #sidebar::after { content: ""; position: absolute; right: 0; top: 0; bottom: 0; width: 3px; background: linear-gradient(180deg, #39b37d, var(--pq-green) 40%, var(--pq-maroon) 60%, #b0345a); }
  .sb-brand { display: flex; align-items: center; gap: 12px; padding: 20px 18px 16px; cursor: pointer; }
  .sb-brand img { width: 46px; height: 46px; object-fit: contain; background: #fff; border-radius: 12px; padding: 3px; box-shadow: 0 4px 12px rgba(0, 0, 0, .25); }
  .sb-brand b { display: block; font: 800 16px 'Inter', sans-serif; color: #fff; }
  .sb-brand small { font-size: 11.5px; color: rgba(231, 244, 237, .72); }
  .sb-main { padding: 6px 12px 10px; display: flex; flex-direction: column; gap: 3px; border-bottom: 1px solid rgba(255, 255, 255, .1); }
  .sb-main button, .sb-item, .sb-foot button {
    display: flex; align-items: center; gap: 11px; width: 100%; text-align: left; background: none; border: 0; color: rgba(231, 244, 237, .86);
    font: 600 13.5px 'DM Sans', sans-serif; padding: 9px 12px; border-radius: 10px; cursor: pointer; transition: background .15s, color .15s;
  }
  .sb-main button { font-size: 14px; padding: 10px 12px; }
  .sb-main button:hover, .sb-item:hover, .sb-foot button:hover { background: rgba(255, 255, 255, .08); color: #fff; }
  .sb-main button.on { background: #fff; color: var(--pq-green-d); box-shadow: 0 4px 14px rgba(0, 0, 0, .18); }
  .sb-main button.on::after { content: ""; margin-left: auto; width: 7px; height: 7px; border-radius: 50%; background: var(--pq-maroon); }
  .sb-i { width: 22px; text-align: center; font-size: 16px; flex-shrink: 0; display: inline-flex; justify-content: center; }
  .sb-groups { flex: 1; overflow-y: auto; padding: 8px 12px; scrollbar-width: thin; scrollbar-color: rgba(255, 255, 255, .2) transparent; }
  .sb-group { margin-bottom: 4px; }
  .sb-gh { display: flex; align-items: center; width: 100%; background: none; border: 0; color: rgba(231, 244, 237, .55); font: 700 10.5px 'DM Sans', sans-serif; letter-spacing: .09em; text-transform: uppercase; padding: 10px 12px 6px; cursor: pointer; }
  .sb-gh span { flex: 1; text-align: left; }
  .sb-gh i { font-style: normal; transition: transform .2s; }
  .sb-group.closed .sb-gh i { transform: rotate(-90deg); }
  .sb-group.closed .sb-items { display: none; }
  .sb-item { font-weight: 500; font-size: 13px; padding: 7px 12px; }
  .sb-item .sb-t { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .sb-item.on { background: rgba(255, 255, 255, .14); color: #fff; box-shadow: inset 3px 0 0 #e86a90; }
  .sb-foot { padding: 10px 12px 14px; border-top: 1px solid rgba(255, 255, 255, .1); }
  .sb-foot button { font-size: 13px; padding: 8px 12px; }
  .sb-upd { font-size: 11px; color: rgba(231, 244, 237, .5); padding: 6px 12px 0; }

  /* top bar */
  #header { grid-row: 1; background: var(--surface); color: var(--text); box-shadow: none; border-bottom: 1px solid var(--border); padding: 12px 28px; gap: 14px; z-index: 30; }
  #header::after { display: none; }
  #header .app-logo { display: none; }
  #header .app-title { font-size: 19px; font-weight: 800; color: var(--text); }
  #header .app-subtitle { color: var(--text-3); font-size: 12.5px; }
  .app-title-wrap { flex: 0 1 auto !important; min-width: 180px; }
  .desk-search {
    display: flex; align-items: center; gap: 10px; flex: 0 1 520px; margin-left: auto; background: var(--bg); border: 1.5px solid var(--border);
    border-radius: 12px; padding: 0 12px; height: 42px; transition: border-color .2s, box-shadow .2s;
  }
  .desk-search:focus-within { border-color: var(--pq-green); box-shadow: 0 0 0 4px rgba(10, 113, 73, .12); background: var(--surface); }
  .desk-search span { opacity: .55; }
  .desk-search input { flex: 1; border: 0; outline: 0; background: none; font: 500 14px 'DM Sans', sans-serif; color: var(--text); min-width: 0; }
  .desk-search kbd { font: 600 11px 'DM Sans', sans-serif; color: var(--text-3); border: 1px solid var(--border); border-radius: 6px; padding: 2px 6px; background: var(--surface); }
  .header-action { width: 40px; height: 40px; background: var(--bg); color: var(--text); border: 1.5px solid var(--border); }
  #back-btn { width: 40px; height: 40px; background: var(--bg); border-color: var(--border); box-shadow: none; }
  #back-btn svg path { stroke: var(--text); }
  #share-btn, #screenshot-btn { width: 40px !important; height: 40px !important; }

  /* home */
  #home-screen, #calc-screen { padding: 28px 36px 48px; gap: 18px; }
  #home-screen > *, #calc-screen > * { max-width: 1240px; }
  .hero-banner { display: grid; grid-template-columns: 1fr auto; grid-template-areas: "h s" "t s" "u s"; align-items: center; column-gap: 32px; padding: 30px 34px; border-radius: 22px; }
  .hero-hello { grid-area: h; font-size: 12.5px; }
  .hero-title { grid-area: t; font-size: 30px; font-weight: 800; letter-spacing: -.3px; }
  .hero-sub { grid-area: u; font-size: 14px; margin-top: 6px; }
  .hero-stats { grid-area: s; margin-top: 0; gap: 12px; }
  .hero-stat { padding: 14px 16px; min-width: 118px; border-radius: 14px; backdrop-filter: blur(4px); }
  .hero-stat .val { font-size: 19px; }
  .hero-stat .lbl { font-size: 11.5px; }
  .sec-head { font-size: 13.5px; margin-top: 10px; }
  .prod-grid { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 18px; }
  .prod-card { padding: 22px 20px; gap: 8px; border-radius: 18px; }
  .prod-card .pc-icon { font-size: 32px; }
  .prod-card .pc-name { font-size: 16px; }
  .prod-card .pc-desc { font-size: 13px; }
  .prod-card .pc-badge { font-size: 11px; padding: 4px 10px; }
  .tools-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 14px; }
  .tool-card { padding: 18px 12px; border-radius: 16px; gap: 8px; }
  .tool-card .tc-icon { font-size: 28px; }
  .tool-card .tc-label { font-size: 13px; }
  .banner-grid { grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 16px; }
  .pq-banner { padding: 20px; border-radius: 18px; }
  .strip-grid { grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 14px; }
  .info-strip { padding: 16px 18px; border-radius: 14px; }
  .search-results { padding: 0; max-width: 900px !important; }
  .sr-item { padding: 14px 18px; }

  /* calculators */
  .calc-banner { padding: 28px 32px !important; border-radius: 22px !important; }
  .calc-grid { grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: 18px; }
  .calc-card { padding: 22px 20px; border-radius: 18px; }
  .calc-card .cc-name { font-size: 16px; }
  .calc-card .cc-desc { font-size: 13px; }
  .suite-hub-card { padding: 22px 26px !important; }

  /* topic pages */
  .detail-header { padding-top: 34px; padding-bottom: 30px; padding-left: max(36px, calc((100% - 900px) / 2)); padding-right: max(36px, calc((100% - 900px) / 2)); }
  .detail-header .dh-icon { font-size: 42px; }
  .detail-header .dh-title { font-size: 30px; letter-spacing: -.3px; }
  .detail-header .dh-sub { font-size: 14.5px; }
  .sub-tabs { position: sticky; top: 0; z-index: 4; padding: 12px max(36px, calc((100% - 900px) / 2)); flex-wrap: wrap; }
  .stab { font-size: 13px; padding: 8px 16px; }
  .detail-body, .qr-strip { max-width: 900px; padding-left: 36px; padding-right: 36px; }
  .detail-body { padding-top: 28px; padding-bottom: 28px; }
  .content-block { font-size: 15px; line-height: 1.7; }
  .qr-strip { flex-wrap: wrap; padding-bottom: 28px; }

  /* calculator info + planner */
  .ct-hero, .sfp-hero { padding: 44px 24px 38px !important; }
  #ct-native > *, #sfp-native > * { max-width: 900px; }
  .ct-steps-grid { grid-template-columns: repeat(4, 1fr); }

  /* hospitals: city list left, results right */
  #hosp-tabs { padding: 0 28px; justify-content: flex-start; gap: 6px; }
  .hosp-tab { flex: 0 0 auto; padding: 14px 18px; font-size: 13px; }
  #hview-panel[style*="flex"], #hview-panel:not([style]) { display: grid !important; grid-template-columns: 270px minmax(0, 1fr); grid-template-rows: auto auto minmax(0, 1fr); flex: 1; min-height: 0; }
  #hview-panel .hosp-search-wrap, #hview-panel .hosp-stats-bar { grid-column: 1 / -1; padding-left: 28px; padding-right: 28px; }
  #hosp-city-index { grid-column: 1; grid-row: 3; flex-direction: column !important; flex-wrap: nowrap !important; overflow-y: auto; padding: 12px 14px 24px 22px !important; gap: 4px !important; border-right: 1px solid var(--border); max-height: none !important; }
  #hosp-city-index .hosp-city-chip { border-radius: 10px; padding: 8px 12px; font-size: 12.5px; text-align: left; border-color: transparent; background: transparent; }
  #hosp-city-index .hosp-city-chip:hover { background: var(--surface); border-color: var(--border); }
  #hosp-city-index .hosp-city-chip.sel { background: var(--pq-green); color: #fff; }
  #hosp-results { grid-column: 2; grid-row: 3; padding: 0 28px 28px; }
  #hview-panel:has(#hosp-city-index[style*="none"]) #hosp-results { grid-column: 1 / -1; }
  .hosp-city-section { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 14px; margin-top: 14px; }
  .hosp-city-header { grid-column: 1 / -1; border-radius: 10px; margin-bottom: 6px; position: static !important; }
  .hosp-card { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; margin-bottom: 10px; padding: 12px 14px; }
  #hview-nonr, #hview-room { max-width: 900px; margin: 0 auto; width: 100%; padding: 20px 28px; overflow-y: auto; }

  /* greetings: settings left, live card right */
  .gc-wrap { display: grid; grid-template-columns: minmax(0, 1fr) 440px; gap: 24px; max-width: 1240px; padding: 28px 36px 40px; align-items: start; }
  .gc-wrap > :nth-child(1), .gc-wrap > :nth-child(2) { grid-column: 1; }
  .gc-wrap > :nth-child(3) { grid-column: 2; grid-row: 1 / span 2; position: sticky; top: 0; }
  .gc-wrap > :nth-child(4) { grid-column: 2; }
  .gc-occ-grid { grid-template-columns: repeat(4, 1fr) !important; }

  /* modals become centred dialogs */
  #share-modal { align-items: center !important; }
  #share-modal > div { border-radius: 20px !important; max-width: 480px !important; }
  .pq-toast-bar { bottom: 24px; left: calc(50% + var(--sb-w) / 2); }
  #ss-toast { left: calc(50% + var(--sb-w) / 2) !important; }
}

@media (min-width: 1440px) {
  :root { --sb-w: 296px; }
  .prod-grid { grid-template-columns: repeat(4, 1fr); }
}
#sidebar [hidden] { display: none !important; }
@media (max-width: 1023px) {
  #header .app-title { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; line-height: 1.25; }
}
