/* .99: reduce the old blank headroom, retain full controls and a compact bottom walking strip.
 * Preserve the site's sticky/static positioning. Reserve actual headroom.
   No rule in this file changes header position/top/z-index or the sizes of its controls. */
:root{--kr97-w:88px;--kr97-h:96px;--kr97-reserve:24px}
body>header.kr94-integrated{height:auto!important;min-height:54px!important;padding-top:7px!important;padding-bottom:5px!important}
.kr94-lane{box-sizing:border-box;position:absolute!important;inset:0!important;width:auto!important;height:auto!important;min-height:0!important;min-width:0!important;max-width:none!important;margin:0!important;padding:0!important;border:0!important;background:none!important;pointer-events:none!important;overflow:hidden!important;contain:layout style;isolation:isolate;z-index:2}
#kr94-header-lane{flex:0 0 0!important}
#ks21About.kr97-information .ks21-footer-inner>.kr97-foot-col{position:relative;padding-top:106px!important}
#kr94-footer-lane{border-radius:0}
#kr94-launcher{all:unset;box-sizing:border-box;display:block;position:absolute;left:0;top:0;width:var(--kr97-w);height:var(--kr97-h);padding:0;margin:0;border:0;border-radius:10px;background:none;pointer-events:auto;touch-action:pan-y;cursor:pointer;user-select:none;-webkit-user-select:none;-webkit-tap-highlight-color:transparent;opacity:0;transition:opacity .12s linear;transform-origin:0 0}
#kr94-launcher[data-visible="true"]{opacity:1}
#kr94-launcher[data-visible="false"],#kr94-launcher[data-fading="true"]{opacity:0;pointer-events:none}
#kr94-launcher:focus-visible{outline:2px solid #75eaf1;outline-offset:-2px}
#kr94-launcher .kr97-canvas{display:block;position:absolute;inset:0;width:100%;height:100%;pointer-events:none;background:none;border:0;margin:0}
#kr94-launcher .kr97-shadow{display:block;position:absolute;left:24%;width:52%;height:5%;top:91.5%;background:radial-gradient(ellipse,#04111a36,transparent 72%);pointer-events:none}
#kr94-launcher .kr97-fallback{font:12px/1.6 "Noto Sans Khmer",sans-serif;display:grid;place-items:center;position:absolute;inset:8px;white-space:normal;text-align:center;border:1px dashed #96c5d5;border-radius:10px;color:#a6e6eb;background:#10232b}
#kr94-launcher [hidden]{display:none!important}
.kr97-caption{position:absolute;pointer-events:none!important;max-width:calc(100% - 10px);color:#ffcd55;-webkit-text-stroke:.5px white;paint-order:stroke fill;text-shadow:0 1px 2px #0009;font-family:"Moul","Noto Sans Khmer",sans-serif;font-weight:400;font-size:13px;line-height:1.8;text-align:center;background:none!important;border:0!important;padding:0!important;white-space:normal;overflow-wrap:anywhere;z-index:3}
.kr97-caption[hidden]{display:none!important}
.kr97-prop{position:absolute!important;left:0!important;top:0!important;display:block!important;min-width:0!important;max-width:none!important;max-height:none!important;object-fit:contain;padding:0!important;margin:0!important;pointer-events:none!important;transform-origin:50% 50%;z-index:3}
.kr97-prop svg{display:block;width:100%;height:100%;pointer-events:none}
.kr97-held{opacity:0!important} /* The original anchor remains present, sized and clickable. */
html[data-kr94-fullscreen="true"] #kr94-launcher,html[data-kr94-fullscreen="true"] .kr94-slot,html[data-kr94-fullscreen="true"] .kr97-caption,html[data-kr94-suppressed="true"] #kr94-launcher,html[data-kr94-suppressed="true"] .kr94-slot,html[data-kr94-suppressed="true"] .kr97-caption{visibility:hidden!important;pointer-events:none!important}
.kr94-sr{position:absolute!important;width:1px!important;height:1px!important;overflow:hidden!important;clip-path:inset(50%)!important;white-space:nowrap!important}
.kr97-extra-controls{display:flex;gap:8px;align-items:center;flex-wrap:wrap;width:100%}.kr97-mic{margin-top:10px;padding:10px;border:1px solid #819dad44;border-radius:8px}.kr97-mic[hidden]{display:none!important}.kr97-mic button{margin-right:8px}.kr97-extra-controls button:disabled{opacity:.6;cursor:default}
@media(max-width:760px){:root{--kr97-w:72px;--kr97-h:84px;--kr97-reserve:18px}body>#ks21About.kr97-information{display:block!important}#ks21About.kr97-information .ks21-footer-inner>.kr97-foot-col{padding-top:100px!important}.kr97-caption{font-size:12px}}
@media(prefers-reduced-motion:reduce){#kr94-launcher{transition:none!important}}
.kr94-slot{position:relative;box-sizing:border-box;width:100%;max-width:100%;min-width:0;overflow-anchor:none;pointer-events:none;z-index:auto}
.kr94-dialog{box-sizing:border-box;position:relative;margin:14px auto;padding:16px;width:calc(100% - 24px);max-width:780px;color:#e9f6ff;background:linear-gradient(145deg,#122537,#111c29);border:1px solid #5ddfe636;border-radius:18px;font:14px/1.8 "Noto Sans Khmer","Segoe UI",Arial,sans-serif;pointer-events:auto;box-shadow:0 6px 24px #0002;text-align:left}
.kr94-dialog *{box-sizing:border-box}.kr94-dialog[hidden]{display:none!important}.kr94-dialog header{display:flex;align-items:center;gap:12px;background:none;color:inherit;border:0;position:static;height:auto;box-shadow:none;padding:0;margin:0}.kr94-dialog h2{font:700 17px/1.8 "Noto Sans Khmer","Segoe UI",sans-serif;color:#d5ffff;margin:0}.kr94-dialog p{color:inherit;font:inherit;margin:6px 0}.kr94-dialog .kr94-disclosure{font-size:12px;color:#b3c9d9;margin:5px 0 12px}.kr94-dialog button,.kr94-dialog input{font:inherit;color:inherit}.kr94-dialog button{border:1px solid #98dcea36;border-radius:9px;background:#1d3546;min-height:36px;padding:5px 11px;cursor:pointer;line-height:1.6}.kr94-dialog button:hover{background:#294c60}.kr94-dialog button:focus-visible,.kr94-dialog input:focus-visible,.kr94-dialog summary:focus-visible{outline:2px solid #69e4e7;outline-offset:2px}.kr94-dialog .kr94-close{margin-left:auto;min-width:44px;min-height:44px;padding:4px;font-size:24px}.kr94-log{max-height:210px;overflow-y:auto;overscroll-behavior:contain;scrollbar-gutter:stable;padding:6px 8px;background:#08162477;border-radius:10px;overflow-wrap:anywhere;white-space:pre-wrap}.kr94-line{padding:8px 12px;margin:6px 0;max-width:95%;border:1px solid #89e7e423;border-radius:12px;background:#163447}.kr94-line[data-speaker="user"]{margin-left:auto;background:#263546}.kr94-line small{display:block;color:#9eccd2;font-size:11px;line-height:1.6}.kr94-topics{display:flex;flex-wrap:wrap;gap:6px;margin:12px 0}.kr94-compose{display:flex;gap:8px;margin:10px 0 0}.kr94-compose input{min-width:0;flex:1;background:#091724;border:1px solid #99d7d04a;border-radius:9px;padding:8px 10px;min-height:44px}.kr94-compose button{flex:0 0 auto}.kr94-bottom{display:flex;align-items:center;flex-wrap:wrap;gap:12px;margin-top:10px;font-size:12px;color:#b1c8d6}.kr94-demo{margin-top:9px}.kr94-demo summary{cursor:pointer;color:#bfdee8;font-size:12px}.kr94-demo-controls{display:flex;flex-wrap:wrap;gap:6px;padding-top:8px}
/* Restore the existing non-modal chat in normal flow; no page-covering layer. */
#kr94-header-chat,#kr94-footer-chat{position:relative;z-index:auto}
#kr94-dialog{z-index:3}
body[data-theme="light"] #kr94-dialog{background:#f3f8fc;color:#162938;border-color:#276a8d44}body[data-theme="light"] #kr94-dialog h2{color:#143e50}body[data-theme="light"] #kr94-dialog button{color:#19384c;background:#e1edf5}body[data-theme="light"] #kr94-dialog input{color:#19384c;background:white}
@media(max-width:420px){.kr94-dialog{padding:12px;width:calc(100% - 12px)}.kr94-compose{flex-wrap:wrap}.kr94-compose input{flex-basis:65%}.kr94-log{max-height:170px}}

/* Site-wide hover lifts/transitions must not move the assistant hit box. */
#kr94-launcher,#kr94-launcher:hover,#kr94-launcher:active,#kr94-launcher:focus{animation:none!important;transition:opacity .12s linear!important;translate:none!important;rotate:none!important;scale:none!important;filter:none!important;box-shadow:none!important;min-height:0!important;min-width:0!important;}
#kr94-launcher::before,#kr94-launcher::after{content:none!important;display:none!important}

/* Site pseudo-fullscreen hides helpers immediately, before a delayed animation frame. */
html.ks-p1-media-fullscreen :is(#kr94-launcher,.kr94-slot,.kr97-caption),html.komsan-pseudo-fullscreen-active-v1214 :is(#kr94-launcher,.kr94-slot,.kr97-caption){visibility:hidden!important;pointer-events:none!important}

/* .98 additions change ONLY the actor/help panel; no header or control dimensions. */
#kr94-launcher{overflow:visible!important;isolation:isolate}
#kr94-launcher .kr97-canvas{max-width:none!important;max-height:none!important;inset:auto!important;top:0!important}
#kr94-launcher .kr97-shadow{top:auto;bottom:.3px;height:3%;background:radial-gradient(ellipse,#04111a26,transparent 72%)}
#kr94-dialog{width:calc(100% - 20px);max-width:440px;padding:12px;margin:10px auto;border-radius:12px;border:1px solid #9cdfea4d;background:linear-gradient(135deg,rgba(15,40,57,.70),rgba(22,25,48,.70));opacity:1;box-shadow:0 5px 18px #0002;font-size:13px;line-height:1.7}
#kr94-dialog h2{font-size:15px;line-height:1.7}
#kr94-dialog .kr94-log{max-height:145px;background:rgba(8,22,36,.28);padding:4px 6px}
#kr94-dialog .kr94-line{padding:6px 8px;background:rgba(13,45,62,.55);font-size:13px}
#kr94-dialog .kr94-line[data-speaker="user"]{background:rgba(34,39,63,.5)}
#kr94-dialog .kr94-topics{gap:4px;margin:8px 0}
#kr94-dialog .kr94-disclosure{font-size:11px;line-height:1.65;margin:4px 0 8px}
#kr94-dialog button{opacity:1;min-height:34px;padding:4px 8px;font-size:12px;color:#f1faff;background:#1a3a50}
#kr94-dialog input{opacity:1;background:#0c2231;color:#f3faff;min-height:38px}
#kr94-dialog .kr94-close{min-width:36px;min-height:36px;font-size:22px}
#kr94-dialog .kr97-extra-controls{gap:5px}
#kr94-dialog .kr94-bottom{gap:7px;margin-top:8px}
.kr98-music-note{display:block;width:100%;font-size:11px;color:#e5d59a}
body[data-theme="light"] #kr94-dialog{background:linear-gradient(135deg,rgba(245,250,255,.70),rgba(226,239,249,.70));color:#172b3b;border-color:#5a8ba966}
body[data-theme="light"] #kr94-dialog .kr94-line{background:rgba(248,253,255,.55);color:#172b3b}
body[data-theme="light"] #kr94-dialog .kr98-music-note{color:#5f4a0c}
@media(max-width:460px){#kr94-dialog{width:calc(100% - 12px);padding:10px}#kr94-dialog .kr94-log{max-height:128px}}

/* Transparent canvas may carry props outside the hit target only after stage-fit checks.
   Crop below the existing model ground plane; no artwork or input extends into video. */
#kr94-launcher .kr97-canvas{clip-path:inset(0 0 6.428571% 0);pointer-events:none!important}

html[data-kr94-fullscreen="true"] .kr97-prop,html[data-kr94-suppressed="true"] .kr97-prop,html.ks-p1-media-fullscreen .kr97-prop,html.komsan-pseudo-fullscreen-active-v1214 .kr97-prop{visibility:hidden!important;pointer-events:none!important}

/* .99 compact chat and safe sky-blue captions. These rules don't change model colors or site controls. */
#kr94-dialog.kr99-chat{max-width:370px;width:calc(100% - 16px);padding:11px;border:1px solid #b7e2ff55;border-radius:13px;background:linear-gradient(135deg,rgba(18,40,66,.70),rgba(32,23,55,.70));color:#f3faff;opacity:1;font-size:13px;backdrop-filter:blur(10px)}
body[data-theme="light"] #kr94-dialog.kr99-chat{background:linear-gradient(135deg,rgba(233,245,255,.70),rgba(244,234,255,.70));color:#142c45}
#kr94-dialog.kr99-chat .kr94-log{max-height:185px;padding:4px;background:transparent;border:0}#kr94-dialog.kr99-chat .kr94-line{padding:6px 8px;margin:4px 0;border:1px solid #bedaff28;background:#122638b0;color:#f1faff;font-size:13px;line-height:1.75}
body[data-theme="light"] #kr94-dialog.kr99-chat .kr94-line{background:#ffffffe8;color:#122638}
.kr99-chat header h2{font-size:15px;margin:0}#kr94-dialog.kr99-chat .kr94-close{min-width:34px;min-height:34px;font-size:22px}
#kr94-dialog.kr99-chat .kr94-disclosure{font-size:10px;line-height:1.6;margin:4px 0 7px}#kr94-dialog.kr99-chat .kr94-compose{display:grid;grid-template-columns:1fr 36px;gap:6px;margin:8px 0 0}
#kr94-dialog.kr99-chat .kr94-compose input{grid-column:1;min-width:0;width:100%;box-sizing:border-box;font-size:12px;padding:7px}#kr94-dialog.kr99-chat .kr94-compose>[type="submit"]{grid-column:2;min-width:34px;padding:4px}
.kr99-toolbar{grid-column:1/-1;display:flex;gap:6px}#kr94-dialog.kr99-chat .kr99-toolbar button{width:38px;min-height:36px;font-size:16px;padding:4px}#kr94-dialog.kr99-chat .kr99-toolbar [data-state="recording"]{background:#8f2739;color:#fff}
#kr94-dialog.kr99-chat .kr99-status{font-size:11px;line-height:1.65;overflow-wrap:anywhere;margin:6px 0;color:inherit}.kr99-cloud{font-size:11px;line-height:1.7}.kr99-cloud summary{cursor:pointer}.kr99-cloud label{display:block;margin:6px 0}.kr99-cloud input{margin-right:6px}.kr99-cloud button{font-size:11px;max-width:100%}
.kr97-caption{color:#7ed5ff!important;-webkit-text-stroke:.25px rgba(15,31,48,.8)!important;text-shadow:0 1px 2px #091d35d9!important;paint-order:stroke fill;background:none!important;font-size:14px!important;font-weight:600!important;line-height:1.65!important}
.kr94-lane:focus{outline:none}
@media(max-width:700px){.kr97-caption{display:none!important}#kr94-dialog.kr99-chat{width:calc(100% - 12px);max-width:360px}}

#kr94-dialog.kr99-chat .kr99-cloud input[type=checkbox]{min-height:0;width:16px;height:16px;vertical-align:middle;accent-color:#65ccff}
/* Keep the old pause node only for preview/controller compatibility, not the compact chat UI. */
#kr94-dialog.kr99-chat [hidden]{display:none!important}

/* .101: one real toolbar, relocated only into a collision-free box in the active lane. */
.kr101-toolbar-slot{grid-column:1/-1;min-height:40px;box-sizing:border-box}
.kr99-toolbar[data-placement=actor]{position:absolute;display:flex!important;box-sizing:border-box;width:132px;height:40px;padding:2px;gap:4px;pointer-events:auto;z-index:3;border:1px solid #a5d8ff60;border-radius:10px;background:linear-gradient(130deg,rgba(16,38,61,.85),rgba(36,30,55,.85));backdrop-filter:blur(8px)}
.kr99-toolbar[data-placement=actor] button{all:unset!important;box-sizing:border-box!important;display:grid!important;place-items:center!important;width:39px!important;height:34px!important;font:18px/1.2 "Segoe UI",sans-serif!important;color:#effaff!important;cursor:pointer!important;border-radius:7px!important;transform:none!important;transition:none!important;pointer-events:auto!important;touch-action:manipulation!important}
.kr99-toolbar[data-placement=actor] button:hover{background:#b8e4ff25!important}.kr99-toolbar[data-placement=actor] button:focus-visible{outline:2px solid #72d3ff!important;outline-offset:-2px!important}.kr99-toolbar[data-placement=actor] button[data-state=recording]{background:#872a40!important}
.kr99-toolbar[hidden],.kr97-caption[hidden]{display:none!important}
html[data-kr94-fullscreen=true] .kr99-toolbar,html[data-kr94-suppressed=true] .kr99-toolbar{visibility:hidden!important;pointer-events:none!important}
.kr101-frame-prop{object-fit:contain;pointer-events:none!important;border:0!important;background:none!important;transform-origin:50% 50%;will-change:transform,opacity}
.kr101-user-caption{color:#83d9ff!important}

/* .102 compact geometry: remove the 43px blank strip, not the logo/navigation.
   A narrow horizontal breathing space is reserved beside the existing Brand;
   no additional row, duplicate header, sticky or z-index override is introduced. */
body>header.kr94-integrated > .brand{margin-inline-end:36px!important}
#kr94-dialog.kr99-chat{max-width:360px;margin:7px auto;padding:10px;background:linear-gradient(135deg,rgba(18,40,66,.70),rgba(32,23,55,.70));opacity:1}
#kr94-dialog.kr99-chat .kr99-toolbar{position:static;width:auto;height:auto;background:none;border:0;backdrop-filter:none;padding:0;gap:7px}
#kr94-dialog.kr99-chat .kr99-toolbar button{min-width:42px;min-height:42px}
#kr94-dialog.kr99-chat .kr102-mic-level{height:4px;width:100%;background:#6ac7ef25;border-radius:4px;overflow:hidden}
.kr102-mic-meter{display:block;height:100%;width:0%;background:#73daff;transition:width .08s linear}
.kr102-transcript-review{font:inherit;margin:6px 0;padding:6px;border:1px solid #a5d8ff44;border-radius:8px}
.kr102-transcript-review[hidden]{display:none!important}
.kr102-caption-pending{color:#8fdcff}
@media(min-width:1301px){body>header.kr94-integrated{column-gap:6px!important}}

/* Existing narrow-header title labels are optional; retain the actual logo, all existing
   action controls, and their accessible names. Prevent overflowing flex children from
   occupying the reserved actor pocket. No additional header row is introduced. */
@media(max-width:520px){
 body>header.kr94-integrated > .brand .anime-brand-words{display:none!important}
 body>header.kr94-integrated > .brand{margin-inline-end:36px!important}
}
@media(max-width:520px){
 body>header.kr94-integrated > .brand{flex:0 0 42px!important;width:42px!important;min-width:42px!important;max-width:42px!important;gap:0!important}
}
