
.media-pagination { display:flex; align-items:center; justify-content:space-between; gap:12px; flex-wrap:wrap; margin-block:12px; min-width:0; }
.media-pagination button { border:1px solid var(--palette-9de63c80); border-radius:var(--radius-16px); padding:10px 16px; color:var(--text,var(--palette-efffe5)); background:var(--palette-194d3dba); }
.media-pagination button:focus-visible, input[type=search]:focus-visible { outline:3px solid var(--palette-b6ef66); outline-offset:3px; }
.media-pagination + input, input[type=search] { max-width:100%; min-width:0; }


:root { --text-scale:1; }
html { touch-action:pan-x pan-y; }
.main { max-width:none; width:100%; margin:0; padding-inline:clamp(12px,2.4vw,48px); }
.shell, .main, .page, .workspace-grid, .profile-card, .user-row, dialog { min-width:0; }
/* v48: break-word, not anywhere: anywhere shrinks min-content to one letter, so flex/grid cells squeeze words into letters. */
.wan-text-content { font-size:calc(var(--text-base,16px) * var(--text-scale) * var(--system-text-scale,1)) !important; overflow-wrap:break-word; }
html[data-text-size=system]{font-size:clamp(12px,100%,24px)}
html[data-text-size=system][data-dynamic-type=true]{font:-apple-system-body}
.system-text-probe{position:fixed;inset:0 auto auto 0;inline-size:1rem;block-size:1rem;visibility:hidden;pointer-events:none;contain:strict}
.text-size-resolved{margin:0 0 12px;font-size:11px;color:var(--soft)}
.text-size-resolved dd{margin:4px 0 0;color:var(--text)}
input:not([type=checkbox]):not([type=radio]):not([type=range]), textarea, select { font-size:max(16px,1rem); max-width:100%; }
.text-scale-setting { display:flex; align-items:center; justify-content:space-between; gap:12px; flex-wrap:wrap; margin-block:14px; }
.text-scale-setting select { padding:8px 12px; border:1px solid var(--palette-8fc66c); border-radius:var(--radius-12px); color:var(--palette-edffdd); background:var(--palette-163c2b); }
.text-scale-toast { position:fixed; bottom:110px; left:50%; transform:translateX(-50%); z-index:10020; pointer-events:none; opacity:0; padding:10px 16px; border:1px solid var(--palette-aeea6d); border-radius:var(--radius-16px); color:var(--palette-edffdb); background:var(--palette-163e2ff0); white-space:nowrap; }
.text-scale-toast.show { opacity:1; }
button:focus-visible,select:focus-visible,summary:focus-visible { outline:3px solid var(--palette-b6ef66); outline-offset:3px; }
@media(min-width:1920px) { .workspace-grid { gap:clamp(24px,3vw,80px); } }

.feature-beta-badge { display:inline-block; vertical-align:baseline; margin-inline-start:4px; padding:2px 4px; border:1px solid var(--palette-a9d978); border-radius:var(--radius-8px); color:var(--palette-e1ffb3); background:linear-gradient(145deg,var(--palette-31583d),var(--palette-173a2b)); font:700 9px/1.15 sans-serif !important; letter-spacing:.02em; white-space:nowrap; font-style:normal; flex:none; }
.feature-beta-badge[hidden] { display:none !important; }
.qr-header-scan .feature-beta-badge { position:absolute; inset-block-start:-5px; inset-inline-end:-6px; margin:0; font-size:7px !important; }

@media(max-width:590px) { .video-dialog { width:calc(100vw - 16px);height:auto;max-height:calc(100dvh - 16px);border:1px solid var(--line);border-radius:var(--radius-20px); } }

.feature-beta-tail { display:inline; white-space:nowrap; }

.studio-player-fullscreen, .gallery-zoom-actions button, #player-fullscreen { position:relative; }
.studio-player-fullscreen .feature-beta-badge, .gallery-zoom-actions button .feature-beta-badge, #player-fullscreen .feature-beta-badge { position:absolute; inset-block-start:-3px; inset-inline-end:-2px; margin:0; padding:1px 3px; font-size:6px !important; }

.help-trigger { position:relative; }
.help-trigger .feature-beta-badge { position:absolute; inset-block-start:-4px; inset-inline-end:-7px; margin:0; padding:1px 3px; font-size:6px !important; }

/* BETA badge placement: corner chip on buttons, trailing chip on headings without splitting words. */
.has-beta-corner{position:relative}
.has-beta-corner>.feature-beta-badge{position:absolute;top:-7px;right:-6px;margin:0;padding:2px 5px;font-size:8px;line-height:1;pointer-events:none;box-shadow:0 2px 6px var(--palette-00000088)}
.feature-beta-label{min-width:0}
.feature-beta-label+.feature-beta-badge{flex:none;align-self:center}
.help-trigger .feature-beta-badge,.studio-player-close .feature-beta-badge,.player-close .feature-beta-badge{display:none!important}

/* The wrapped label keeps the heading's own type and colour (card-head span rules must not reach it). */
.profile-card-head .feature-beta-label,.feature-beta-label{color:inherit!important;font:inherit!important;letter-spacing:inherit}
