/* Reading edition: presentation only. Page scripts retain data and interactions.
   Keep legacy styles underneath for chart sizing and specialised workbenches. */
:root.hkex-reading {
  --read-paper:#f7f8f4; --read-ink:#232924; --read-muted:#657168;
  --read-line:#d9dfd8; --read-green:#23664e; --read-red:#a84f46;
  --read-serif:Georgia,"Noto Serif TC","Songti TC",serif;
  --read-sans:-apple-system,BlinkMacSystemFont,"PingFang TC","Microsoft JhengHei",sans-serif;
}
/* Specificity intentionally exceeds historical theme overrides, not chart styles. */
:root.hkex-reading:is(#reading-theme,html) {
  --ed-paper:var(--read-paper); --ed-ink:var(--read-ink); --ed-muted:var(--read-muted);
  --ed-line:var(--read-line); --ed-green:var(--read-green); --ed-red:var(--read-red);
}
:root.hkex-reading:is(#reading-theme,html) body {
  background:var(--read-paper)!important; color:var(--read-ink)!important;
  font-family:var(--read-sans)!important; font-size:16px; -webkit-font-smoothing:antialiased;
}
:root.hkex-reading:is(#reading-theme,html) :is(button,input,select,textarea) {font-family:var(--read-sans)!important}
:root.hkex-reading:is(#reading-theme,html) :is(button,a,summary,input,select,textarea):focus-visible {
  outline:3px solid #5389b8!important; outline-offset:3px!important;
}
:root.hkex-reading:is(#reading-theme,html) [id] {scroll-margin-top:92px}
:root.hkex-reading:is(#reading-theme,html) :is(main,.page) {min-width:0;box-sizing:border-box}
:root.hkex-reading:is(#reading-theme,html):not([data-reading-surface="immersive"]) h1 {
  font-family:var(--read-serif)!important; font-size:clamp(32px,3.4vw,44px)!important;
  font-weight:600!important; line-height:1.22!important; letter-spacing:-.025em!important;
  color:var(--read-ink)!important; text-wrap:pretty;
}
:root.hkex-reading:is(#reading-theme,html):not([data-reading-surface="immersive"]) h2 {
  font-family:var(--read-sans)!important;font-size:23px!important;line-height:1.4!important;
  font-weight:650!important;letter-spacing:-.015em!important;color:var(--read-ink)!important;
}
:root.hkex-reading:is(#reading-theme,html):not([data-reading-surface="immersive"]) h3 {font-family:var(--read-sans)!important;line-height:1.45!important}
/* Shared header remains familiar; data-page title bands become paper, like simulator. */
:root.hkex-reading:is(#reading-theme,html) .site-top-nav.site-top-nav {min-height:68px!important;padding-inline:28px!important}
:root.hkex-reading:is(#reading-theme,html):not([data-reading-surface="home"]):not([data-reading-surface="immersive"]) .editorial-hero.editorial-hero {
  background:transparent!important; color:var(--read-ink)!important;
  width:100%!important; max-width:none!important; min-height:0!important;
  margin:0 0 26px!important;padding:26px 0 30px!important;
  border:0!important;border-bottom:1px solid var(--read-line)!important;box-shadow:none!important;
}
:root.hkex-reading:is(#reading-theme,html):not([data-reading-surface="home"]):not([data-reading-surface="immersive"]) .editorial-hero :is(h1,h2,h3,strong,b,em,span) {
  color:var(--read-ink)!important;-webkit-text-fill-color:currentColor!important;
}
:root.hkex-reading:is(#reading-theme,html):not([data-reading-surface="home"]):not([data-reading-surface="immersive"]) .editorial-hero :is(p,small,.eyebrow,.backlink,.hero-meta,.eco-kicker,.briefing-stamp) {
  color:var(--read-muted)!important;line-height:1.7!important;
}
:root.hkex-reading:is(#reading-theme,html):not([data-reading-surface="home"]):not([data-reading-surface="immersive"]) .editorial-hero :is(p,.lede) {font-size:16px!important}
:root.hkex-reading:is(#reading-theme,html):not([data-reading-surface="home"]) .editorial-hero :is(a,.source-popover-trigger) {color:var(--read-green)!important}
:root.hkex-reading:is(#reading-theme,html):not([data-reading-surface="home"]) .editorial-hero :is(.search-box,.ipo-search) {background:#fff!important;border:1px solid #cbd3cc!important;box-shadow:none!important}
:root.hkex-reading:is(#reading-theme,html):not([data-reading-surface="home"]) .editorial-hero .search-box input {background:#fff!important;color:var(--read-ink)!important}
:root.hkex-reading:is(#reading-theme,html):not([data-reading-surface="home"]) .editorial-hero input::placeholder {color:#6c746e!important}
:root.hkex-reading:is(#reading-theme,html):not([data-reading-surface="home"]) .editorial-hero :is(.hero-status,.hero-guide,.ipo-snapshot article,.hero-panel,.hero-kpis article,.eco-next) {
  background:transparent!important;border:0!important;border-left:1px solid var(--read-line)!important;border-radius:0!important;box-shadow:none!important;
}
/* No nested card walls: preserve region geometry, chart backgrounds and heat scales. */
:root.hkex-reading:is(#reading-theme,html):not([data-reading-surface="immersive"]) main :is(
  .panel,.decision-chart-card,.stock-price-module,.stock-owner-simple,.analysis-panel,
  .chart-panel,.reading-panel,.eco-card,.briefing-queue,.briefing-rail,.market-sidebar,
  .market-detail,.rank-card,.ipo-panel,.stock-secondary-module,.stock-more-analysis,
  .stock-record-archive,.card,.chart-card,.thesis-card,.dv-panel,.ss-panel,.mom-panel,
  .topic-watch,.topic-watch-card,.feature-main-story,.feature-side-story,.video-card,
  .channel-overview,.stock-chart-experience,.buyback-price-card,.stats,.stat,.sb-flow-card
) {
  border-radius:0!important;box-shadow:none!important;background:transparent!important;
  border-color:var(--read-line)!important;
}
:root.hkex-reading:is(#reading-theme,html) main :is(.topic-watch,.ipo-panel,.eco-card,.panel,.analysis-panel,.chart-card,.dv-panel,.ss-panel,.mom-panel) {
  border-width:1px 0 0!important;padding:24px 0!important;
}
:root.hkex-reading:is(#reading-theme,html) main :is(.topic-watch-grid,.ipo-snapshot) {gap:0!important}
:root.hkex-reading:is(#reading-theme,html) main .topic-watch-card {
  border:0!important;border-right:1px solid var(--read-line)!important;
  padding:14px 20px!important;min-width:0;transition:background-color .15s ease!important;
}
:root.hkex-reading:is(#reading-theme,html) main .topic-watch-card:last-child {border-right:0!important}
:root.hkex-reading:is(#reading-theme,html) main .topic-watch-card:hover {background:#edf2e9!important}
:root.hkex-reading:is(#reading-theme,html) main :is(.southbound-stock-kpis,.owner-key-numbers) > :is(article,div) {
  background:transparent!important;border:0!important;border-left:1px solid var(--read-line)!important;
  border-radius:0!important;box-shadow:none!important;padding:14px 22px!important;
}
:root.hkex-reading:is(#reading-theme,html) main :is(.southbound-stock-kpis,.owner-key-numbers) > :first-child {border-left:0!important}
:root.hkex-reading:is(#reading-theme,html) main :is(.southbound-stock-kpis,.owner-key-numbers,.ipo-snapshot) strong {
  font-family:var(--read-serif)!important;font-size:36px!important;line-height:1.25!important;font-variant-numeric:tabular-nums;
}
:root.hkex-reading:is(#reading-theme,html) main :is(.section-head,.section-heading,.queue-header,.dv-heading,.ss-heading) {gap:16px;border-color:var(--read-line)!important}
:root.hkex-reading:is(#reading-theme,html) main :is(.reading-page-nav,.stock-reading-nav,.research-reading-links,.dv-rail,.ss-rail) {
  background:transparent!important;box-shadow:none!important;border-radius:0!important;
  border:0!important;border-bottom:1px solid var(--read-line)!important;
  gap:24px!important;overflow-x:auto;max-width:100%;
}
:root.hkex-reading:is(#reading-theme,html) main :is(.reading-page-nav,.stock-reading-nav,.research-reading-links,.dv-rail,.ss-rail) > a {
  background:transparent!important;border-radius:0!important;box-shadow:none!important;
  color:#57655b!important;border:0!important;padding:14px 0!important;min-height:44px;
}
:root.hkex-reading:is(#reading-theme,html) main :is(.reading-page-nav,.stock-reading-nav,.research-reading-links) > a:is([aria-current="step"],[aria-current="page"]) {
  color:var(--read-green)!important;box-shadow:inset 0 -3px var(--read-green)!important;
}
:root.hkex-reading:is(#reading-theme,html) main :is(.decision-tabs,.queue-tabs,.stock-segmented,.sb-flow-tabs,.dv-tabs,.ss-tabs) {background:transparent!important;border-radius:0!important;gap:4px}
:root.hkex-reading:is(#reading-theme,html) main :is(.decision-tabs,.queue-tabs,.stock-segmented,.sb-flow-tabs,.dv-tabs,.ss-tabs) button {
  border-radius:2px!important;min-height:40px;box-shadow:none!important;
}
:root.hkex-reading:is(#reading-theme,html) main :is(.reading-help,.reader-explanation,.research-fold,.dv-help,.ss-help) {
  border-radius:0!important;box-shadow:none!important;background:transparent!important;border-color:var(--read-line)!important;
}
:root.hkex-reading:is(#reading-theme,html) main :is(.reading-help,.reader-explanation,.research-fold,.dv-help,.ss-help) > summary {font-size:15px!important;line-height:1.6!important;padding-block:14px!important}
:root.hkex-reading:is(#reading-theme,html) main table {font-variant-numeric:tabular-nums}
:root.hkex-reading:is(#reading-theme,html) main :is(.ipo-compare-table,.market-table,.data-table) th {background:#eef1eb!important;color:#55635a!important}
:root.hkex-reading:is(#reading-theme,html) main :is(.ipo-compare-table,.market-table,.data-table) :is(td,th) {border-color:var(--read-line)!important}
:root.hkex-reading:is(#reading-theme,html) main :is(.ipo-compare-table,.market-table,.data-table) tbody tr:hover {background:#edf2e9!important}
/* The homepage stays dark. It receives the same measured spacing, not a new theme. */
:root.hkex-reading:is(#reading-theme,html)[data-reading-surface="home"] .fiscal-landing-hero h1 {color:#f6f7f2!important;font-size:clamp(36px,4.3vw,62px)!important}
:root.hkex-reading:is(#reading-theme,html)[data-reading-surface="home"] :is(.fiscal-products,.fiscal-news,.fiscal-research) {padding-block:48px!important}
:root.hkex-reading:is(#reading-theme,html)[data-reading-surface="home"] .fiscal-product-card {border-radius:3px!important;box-shadow:none!important}
/* One native details guide per route: no tracking, popups or unsolicited animation. */
.reading-companion {
  box-sizing:border-box;grid-column:1/-1;display:block;clear:both;position:relative;
  margin:32px 0 16px;padding:18px 0 0;border-top:1px solid var(--read-line);
  color:var(--read-ink);font:14px/1.7 var(--read-sans);max-width:100%;
}
.reading-companion > summary {display:flex!important;align-items:center;justify-content:flex-end;gap:18px;list-style:none;cursor:pointer;padding:0!important;min-height:78px}
.reading-companion > summary::-webkit-details-marker {display:none}
:root.hkex-reading:is(#reading-theme,html) .reading-companion > summary {background:transparent!important;border:0!important;border-radius:0!important;box-shadow:none!important}
.reading-companion .companion-invitation {color:var(--read-muted);font-size:14px;font-weight:400;text-align:right}
.reading-companion .companion-invitation small {display:block;font:12px/1.8 var(--read-sans);color:var(--read-green)}
.reading-companion .companion-cat {display:block;width:112px;height:74px;object-fit:contain;mix-blend-mode:multiply;flex:0 0 auto}
.reading-companion .companion-explanation {max-width:580px;margin:12px 0 0 auto;padding:18px 20px;border-left:2px solid #c5d5c5;background:#eef2e9}
.reading-companion .companion-explanation p {margin:0 0 10px;font:15px/1.75 var(--read-sans);color:var(--read-ink)}
.reading-companion nav {display:flex;gap:18px;flex-wrap:wrap}
.reading-companion nav a {font-size:14px;color:var(--read-green)!important;text-decoration:underline;text-underline-offset:4px;padding-block:6px}
.reading-companion[data-placement="side"] {max-width:480px;margin-left:auto}
.reading-companion[data-placement="section"] {margin-block:26px}
:root.hkex-reading:is(#reading-theme,html) main.reader-standard:has(.bb-story) .reading-companion {margin-top:30px}
@media(min-width:1000px) {
  :root.hkex-reading:is(#reading-theme,html):not([data-reading-surface="immersive"]) main:is(.page,.vcp-page,.eco-page,.desk-shell,.dv-page,.ss-page,.mom-page,.ai-desk) {padding-inline:28px!important}
}
@media(max-width:760px) {
  :root.hkex-reading:is(#reading-theme,html) .ipo-panel-head {box-sizing:border-box;max-width:100%;margin-inline:0!important;flex-wrap:wrap}
  :root.hkex-reading:is(#reading-theme,html) .site-top-nav.site-top-nav {min-height:62px!important;padding-inline:16px!important}
  :root.hkex-reading:is(#reading-theme,html):not([data-reading-surface="immersive"]) h1 {font-size:32px!important;line-height:1.3!important}
  :root.hkex-reading:is(#reading-theme,html):not([data-reading-surface="immersive"]) h2 {font-size:21px!important}
  :root.hkex-reading:is(#reading-theme,html):not([data-reading-surface="home"]):not([data-reading-surface="immersive"]) .editorial-hero.editorial-hero {margin:0 0 20px!important;padding:22px 0!important;width:100%!important}
  :root.hkex-reading:is(#reading-theme,html) main .topic-watch-card {padding:12px 16px!important}
  :root.hkex-reading:is(#reading-theme,html) main :is(.reading-page-nav,.stock-reading-nav,.research-reading-links,.dv-rail,.ss-rail) {gap:18px!important}
  :root.hkex-reading:is(#reading-theme,html) main :is(.southbound-stock-kpis,.owner-key-numbers) > :is(article,div) {padding:12px!important}
  :root.hkex-reading:is(#reading-theme,html) main :is(.southbound-stock-kpis,.owner-key-numbers,.ipo-snapshot) strong {font-size:28px!important}
  .reading-companion {margin-top:24px}
  .reading-companion > summary {gap:12px;min-height:60px}
  .reading-companion .companion-cat {width:86px;height:60px}
  .reading-companion .companion-explanation {padding:14px 16px;margin-top:8px}
  .reading-companion[data-placement="side"] {max-width:none}
}
@media(prefers-reduced-motion:reduce) {
  .reading-companion * {animation:none!important;transition:none!important;scroll-behavior:auto!important}
}
/* Family edition: shared language, different in-flow placements, never a floating pet. */
.reading-companion {--companion-accent:#496777}
.reading-companion[data-member="data"] {--companion-accent:#37624d}
.reading-companion[data-member="news"] {--companion-accent:#806026}
.reading-companion .companion-role {display:block;margin-bottom:4px;color:var(--companion-accent);font-size:11px;letter-spacing:.05em;font-weight:600}
.reading-companion .companion-invitation {color:var(--read-ink);line-height:1.6}
.reading-companion .companion-invitation small {color:var(--read-muted);font-size:11px}
.reading-companion[data-placement="inline"],.reading-companion[data-placement="section"] {max-width:none;margin:10px 0 24px;padding:0;border:0}
.reading-companion[data-placement="inline"] > summary,.reading-companion[data-placement="section"] > summary {min-height:64px;justify-content:flex-start;gap:16px;padding:8px 16px!important;border-left:2px solid #d7dfd3!important;background:#f0f3ec!important}
.reading-companion[data-placement="inline"] .companion-cat,.reading-companion[data-placement="section"] .companion-cat {order:-1;width:80px;height:54px}
.reading-companion[data-placement="inline"] .companion-invitation,.reading-companion[data-placement="section"] .companion-invitation {text-align:left}
.reading-companion[data-placement="inline"] .companion-explanation,.reading-companion[data-placement="section"] .companion-explanation {max-width:none;margin:0;border-left:2px solid #d7dfd3;padding:4px 24px 16px 112px;background:#f0f3ec}
.reading-companion[data-placement="rail"] {width:100%;max-width:none;margin:20px 0;padding:16px 0;border-top:1px solid var(--read-line)}
.reading-companion[data-placement="rail"] > summary {align-items:flex-start;gap:10px;min-height:60px}
.reading-companion[data-placement="rail"] .companion-cat {width:76px;height:54px}
.reading-companion[data-placement="rail"] .companion-invitation {text-align:left;flex:1}
.reading-companion[data-placement="rail"] .companion-explanation {padding:12px;margin-top:12px}
.reading-companion[data-placement="rail"] nav {gap:8px}
.reading-companion[data-placement="rail"] nav a {display:block;width:100%}
/* Homepage: a decorative title accent only, with no help row or expansion. */
:root.hkex-reading:is(#reading-theme,html) .fiscal-products > header {padding-inline:0}
:root.hkex-reading:is(#reading-theme,html) .fiscal-products > header h2 {display:inline-block;position:relative;max-width:100%;box-sizing:border-box;padding-right:60px;background:var(--read-paper)}
:root.hkex-reading:is(#reading-theme,html) .reading-companion[data-placement="home-title"] {display:block;position:absolute;right:0;top:50%;transform:translateY(-50%);width:52px;height:32px;margin:0;padding:0;border:0;clear:none;pointer-events:none;background:var(--read-paper)}
:root.hkex-reading:is(#reading-theme,html) .reading-companion[data-placement="home-title"] .companion-cat {width:52px;height:32px;object-fit:contain}
/* Standalone reading pages retain their grids but join the paper/color system. */
:root.hkex-reading:is(#reading-theme,html)[data-reading-surface="data"] :is(.update-badge,.editor-note,.signal-strip,.control-inner,.progress-panel,.rail-notes,.topic-dossier,.topic-queue,.source-grid > article,.priority-card) {background:transparent!important;color:var(--read-ink)!important;border-color:var(--read-line)!important;box-shadow:none!important;border-radius:0!important}
:root.hkex-reading:is(#reading-theme,html)[data-reading-surface="data"] :is(.update-badge,.editor-note) :is(strong,span,p) {color:var(--read-ink)!important}
:root.hkex-reading:is(#reading-theme,html)[data-reading-route="mind-map"] :is(.date-strip button,.category-strip button,.control-panel .search-box,.control-panel .text-button) {background:#eef1eb!important;color:var(--read-ink)!important;border:1px solid var(--read-line)!important;border-radius:3px!important;box-shadow:none!important}
:root.hkex-reading:is(#reading-theme,html)[data-reading-route="mind-map"] :is(.date-strip button,.category-strip button).active {background:#dfe8db!important;color:#244d39!important;border-color:#9cac9b!important}
:root.hkex-reading:is(#reading-theme,html)[data-reading-route="mind-map"] .control-panel .search-box input {color:var(--read-ink)!important;background:#fff!important}
:root.hkex-reading:is(#reading-theme,html)[data-reading-route="mind-map"] .control-panel .search-box > span {white-space:nowrap;min-width:2em;flex:0 0 auto}
:root.hkex-reading:is(#reading-theme,html)[data-reading-route="mind-map"] :is(.brief-layout,.brief-rail,.brief-main) {color:var(--read-ink)!important}
:root.hkex-reading:is(#reading-theme,html)[data-reading-route="mind-map"] :is(.brief-article,.article-notes,.mind-map,.map-node,.rail-link) {background:transparent!important;color:var(--read-ink)!important;border-color:var(--read-line)!important;border-radius:0!important;box-shadow:none!important}
:root.hkex-reading:is(#reading-theme,html)[data-reading-route="mind-map"] .brief-article {border-width:1px 0 0!important;padding:24px 0!important}
:root.hkex-reading:is(#reading-theme,html)[data-reading-route="mind-map"] .brief-article :is(p,li,strong,h3) {color:var(--read-ink)!important}
:root.hkex-reading:is(#reading-theme,html)[data-reading-route="mind-map"] .map-center {background:#edf2e9!important;color:var(--read-ink)!important;box-shadow:none!important}
:root.hkex-reading:is(#reading-theme,html)[data-reading-route="mind-map"] :is(.rail-label,.rail-label strong,.progress-panel p,.rail-notes p,.article-meta,.map-node > span) {color:var(--read-muted)!important}
:root.hkex-reading:is(#reading-theme,html)[data-reading-route="mind-map"] .rail-link.active {background:#e6eddf!important;color:#244d39!important}
:root.hkex-reading:is(#reading-theme,html)[data-reading-route="mind-map"] .control-panel {position:static!important;transform:none!important;opacity:1!important;pointer-events:auto!important}
:root.hkex-reading:is(#reading-theme,html)[data-reading-route="mind-map"] :is(.map-center span,.rail-link span,.rail-link strong) {color:var(--read-ink)!important}
:root.hkex-reading:is(#reading-theme,html)[data-reading-route="mind-map"] :is(.tag,.map-title > span) {background:#edf2e9!important;color:#52624f!important;border-color:var(--read-line)!important}
:root.hkex-reading:is(#reading-theme,html)[data-reading-route="mind-map"] .progress-track {background:#dfe6da!important}
:root.hkex-reading:is(#reading-theme,html) .editorial-hero + .topic-watch {border-top:0!important}
/* Dedicated full-screen chart stays dark; help occupies the existing scrollable filter rail. */
:root.hkex-reading:is(#reading-theme,html)[data-reading-route="heatmap"] .reading-companion {background:var(--read-paper);padding:12px;border:0;border-radius:3px}
:root.hkex-reading:is(#reading-theme,html)[data-reading-route="heatmap"] .reading-companion .companion-cat {width:54px;height:42px}
@media(max-width:760px) {
  :root.hkex-reading:is(#reading-theme,html) .fiscal-products > header h2 {padding-right:42px}
  :root.hkex-reading:is(#reading-theme,html) .reading-companion[data-placement="home-title"],:root.hkex-reading:is(#reading-theme,html) .reading-companion[data-placement="home-title"] .companion-cat {width:36px;height:24px}
  .reading-companion[data-placement="inline"] > summary,.reading-companion[data-placement="section"] > summary {padding:8px 10px!important;gap:10px}
  .reading-companion[data-placement="inline"] .companion-cat,.reading-companion[data-placement="section"] .companion-cat {width:60px;height:46px}
  .reading-companion[data-placement="inline"] .companion-explanation,.reading-companion[data-placement="section"] .companion-explanation {padding:4px 16px 16px}
  .reading-companion .companion-role {font-size:10px}
  .reading-companion .companion-invitation {font-size:13px}
}
