/* Keep existing presentation styling; fit the original slides to small screens. */
@media (max-width: 540px) {
  .deck .cover-title { font-size: clamp(2rem, 11vw, 3.5rem); max-width: 100%; overflow-wrap: anywhere; }
  .deck .slide { overflow-y: auto; justify-content: flex-start; padding: 24px 18px; }
  .deck .slide > * { flex-shrink: 0; }
  .deck .headline { font-size: clamp(1.5rem, 6.5vw, 2rem); overflow-wrap: anywhere; }
  .deck .slide-content { width: 100%; }
  .deck .stato-grid-2col { grid-template-columns: 1fr; }
}
:focus-visible { outline: 3px solid #54b5ff; outline-offset: 3px; }

/* Shared-theme template: layout only; all visual tokens come from glifix.css. */
[data-gx-presentation] { padding-top: 0; }
[data-gx-presentation] .pres-main { min-width: 0; }
[data-gx-presentation] .slide:not(.active) { visibility: hidden; }
[data-gx-presentation] .slide-content { padding-bottom: 1.5rem; }
[data-gx-presentation] .slide-content > * + * { margin-top: 1.1rem; }
[data-gx-presentation] .slide-content p { color: var(--text-secondary); }
[data-gx-presentation] .slide-content .wide-text { max-width: none; }
/* Shared slide hierarchy: the message must remain readable beside its heading. */
[data-gx-presentation] .slide-content .headline {
  text-align: start;
  font-size: clamp(1.65rem, 2.6vw, 2.25rem);
  line-height: 1.2;
  margin-bottom: 1rem;
}
[data-gx-presentation] .slide-content .cover-sub {
  font-size: clamp(1.65rem, 3vw, 2.5rem);
  font-weight: 700;
  line-height: 1.3;
  color: var(--text-primary);
  text-align: start;
}
[data-gx-presentation] .slide-content .wide-text {
  font-size: clamp(1.125rem, 1.6vw, 1.375rem);
  line-height: 1.6;
  text-align: start;
}
[data-gx-presentation] .pres-toc__item { width: 100%; border-top: 0; border-right: 0; border-bottom: 0; background: transparent; text-align: start; font: inherit; }
[data-gx-presentation] .pres-toc__item.active { background: var(--accent-glow); }
[data-gx-presentation] .bottom-nav { position: absolute; gap: .75rem; }
.gx-deck-index { display: flex; flex-direction: column; width: 240px; flex-shrink: 0; min-height: 0; background: var(--bg-surface); border-inline-end: 1px solid var(--divider); }
.gx-deck-index[hidden] { display: none; }
.gx-link-button { display: inline-flex; align-items: center; justify-content: center; gap: .5rem; padding: .65rem 1rem; border: 1px solid var(--accent); border-radius: .75rem; background: var(--bg-card); color: var(--text-primary); font-size: 1rem; font-weight: 600; line-height: 1.3; font-family: inherit; text-decoration: none; cursor: pointer; }
.gx-link-button:hover { background: var(--bg-card-hover); color: var(--accent); }
.gx-table-scroll { max-width: 100%; overflow-x: auto; }
.gx-table caption { text-align: start; color: var(--text-secondary); padding-block: .75rem; }
.gx-table tbody th { text-transform: none; letter-spacing: normal; }
@media (max-width: 900px) {
  [data-gx-presentation] .gx-deck-index:not([hidden]) { position: absolute; inset-block-start: var(--gx-bar-total,var(--nav-h)); inset-block-end: var(--gxi-height,76px); inset-inline-start: 0; z-index: 500; width: min(280px,85vw); box-shadow: var(--shadow-card); }
  [data-gx-presentation] .gx-table { min-width: 42rem; }
  .gx-site-bar .gx-deck-index-toggle { padding: .4rem .6rem; font-size: .85rem; }
}
@media (prefers-reduced-motion: reduce) { [data-gx-presentation] .slide { transition: none; } }

/* Self-hosted CJK glyphs for language names; see fonts/OFL-GlifixSelectorCJK.txt. */
@font-face {
  font-family: 'Glifix Selector CJK';
  src: url('/glifix_presentations_base/static/src/fonts/glifix-selector-cjk.woff2?v=525c518effaa5b0f') format('woff2');
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  unicode-range: U+4E2D,U+6587,U+65E5,U+672C,U+8A9E,U+C5B4,U+AD6D,U+D55C;
}
.gx-language-panel a > span:not(.gx-flag),
.gx-language-current {
  font-family: 'Glifix Selector CJK', 'Nunito Sans', system-ui, sans-serif;
}

/* Reuse the shared text-centering utility on presentation headings. */
[data-gx-presentation] .slide-content .headline.tc { text-align: center; }
