@font-face { font-family: 'UI Lao'; font-weight: 400; src: url('fonts/NotoSansLao-Regular.ttf'); }
@font-face { font-family: 'UI Lao'; font-weight: 700; src: url('fonts/NotoSansLao-Bold.ttf'); }
:root { --bg: #111317; --panel: #1a1d23; --panel2: #23272f; --line: #30353f; --text: #eceef2; --muted: #98a0ae; --accent: #e5141f; --blue: #3d7bff; }
* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body { background: var(--bg); color: var(--text); font: 14px/1.5 'UI Lao', 'Noto Sans Lao', system-ui, sans-serif; display: flex; flex-direction: column; overflow: hidden; }
button { white-space: nowrap; font: inherit; color: var(--text); background: var(--panel2); border: 1px solid var(--line); border-radius: 8px; padding: 5px 12px; cursor: pointer; }
button:hover { border-color: #566; background: #2b303a; }
button:disabled { opacity: .45; cursor: default; }
button.primary { background: var(--blue); border-color: var(--blue); font-weight: 700; }
button.accent { background: var(--accent); border-color: var(--accent); font-weight: 700; }
button.tiny { padding: 1px 8px; font-size: 12px; }
button.wide { width: 100%; margin-top: 8px; }
input[type=range] { accent-color: var(--blue); width: 100%; margin: 0; }
input[type=text], input[type=number], textarea, select { font: inherit; color: var(--text); background: #12141a; border: 1px solid var(--line); border-radius: 7px; padding: 5px 8px; width: 100%; }
textarea { resize: vertical; line-height: 1.6; }
.hidden { display: none !important; }
.muted { color: var(--muted); }
.small { font-size: 12px; }
.mono { font-family: Consolas, monospace; }
.spacer { flex: 1; }
.grow { flex: 1; min-width: 0; }
.row { display: flex; gap: 8px; align-items: center; margin-top: 8px; }
.row.wrap { flex-wrap: wrap; }
.lbl { font-size: 13px; color: #c7ccd6; display: block; }

header { display: flex; align-items: center; gap: 10px; padding: 8px 14px; background: var(--panel); border-bottom: 1px solid var(--line); flex: none; }
.brand { font-weight: 400; font-size: 16px; letter-spacing: .3px; margin-right: 6px; }
.brand b { color: #ff4b52; }
.homebtn { color: var(--muted); text-decoration: none; font-size: 20px; line-height: 1; padding: 2px 4px; }
.homebtn:hover { color: var(--text); }
#clipName { max-width: 260px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wpc { display: flex; align-items: center; gap: 8px; background: #2a1518; padding: 4px 10px; border-radius: 10px; border: 1px solid #5c262b; }
.wpc label { font-weight: 700; white-space: nowrap; }
.seg { display: inline-flex; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; flex: none; }
.seg button { border: 0; border-radius: 0; background: var(--panel2); padding: 3px 11px; border-right: 1px solid var(--line); }
.seg button:last-child { border-right: 0; }
.seg button.on { background: var(--blue); color: #fff; font-weight: 700; }
.wpc .seg button.on { background: var(--accent); }

main { flex: 1; display: grid; grid-template-columns: 300px minmax(0, 1fr) 370px; min-height: 0; }
aside { background: var(--panel); overflow-y: auto; padding: 10px 12px; }
#left { border-right: 1px solid var(--line); }
#right { border-left: 1px solid var(--line); display: flex; flex-direction: column; padding: 0; overflow: hidden; }
h3 { font-size: 13px; color: var(--muted); margin: 6px 0 8px; font-weight: 700; }
.presets { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; margin-bottom: 8px; }
.preset { position: relative; background: #0c0d10; border: 2px solid transparent; border-radius: 9px; overflow: hidden; cursor: pointer; padding: 0; display: block; }
.preset:hover { border-color: #55607a; background: #0c0d10; }
.preset.on { border-color: #ff4b52; }
.preset canvas { display: block; width: 100%; aspect-ratio: 2/1; }
.preset span { display: block; font-size: 11.5px; padding: 1px 6px 3px; color: #c7ccd6; text-align: left; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; background: #15171c; }
.preset .del { position: absolute; top: 2px; right: 2px; background: rgba(0,0,0,.7); border: 0; color: #fff; font-size: 11px; padding: 0 6px; border-radius: 6px; display: none; }
.preset:hover .del { display: block; }

#center { display: flex; flex-direction: column; min-width: 0; min-height: 0; padding: 10px 14px; gap: 8px; }
#stageWrap { flex: 1; min-height: 0; display: flex; align-items: center; justify-content: center; }
#stage { position: relative; background: #000; border-radius: 6px; overflow: hidden; box-shadow: 0 6px 30px rgba(0,0,0,.5); }
#stage video { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
#stage canvas { position: absolute; inset: 0; width: 100%; height: 100%; touch-action: none; }
#stage.demo { background: linear-gradient(160deg, #2c3442, #14171d 60%, #3a1b1f); }
.dropHint { position: absolute; inset: 10px; border: 2px dashed #fff; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 20px; background: rgba(0,0,0,.6); pointer-events: none; }
.transport { display: flex; align-items: center; gap: 10px; flex: none; }
.transport button { width: 40px; }
.transport span { width: 72px; text-align: right; }
.posbar { display: flex; align-items: center; gap: 12px; flex: none; flex-wrap: wrap; }
.check { display: inline-flex; gap: 5px; align-items: center; cursor: pointer; font-size: 13px; }

.tabs { display: flex; flex: none; border-bottom: 1px solid var(--line); }
.tabs button { flex: 1; border: 0; border-radius: 0; background: transparent; padding: 9px 0; color: var(--muted); border-bottom: 2px solid transparent; }
.tabs button.on { color: #fff; border-bottom-color: #ff4b52; font-weight: 700; }
.tab { flex: 1; overflow-y: auto; padding: 10px 12px; min-height: 0; }
.card { background: #15171c; border: 1px solid var(--line); border-radius: 10px; padding: 10px; margin-bottom: 10px; }
.bar { height: 8px; background: #2b303a; border-radius: 5px; overflow: hidden; margin-top: 8px; }
.bar i { display: block; height: 100%; width: 0; background: var(--blue); transition: width .2s; }
.notice { margin-top: 8px; padding: 6px 9px; border-radius: 7px; font-size: 12.5px; background: #3a2c10; border: 1px solid #7a5c1c; color: #ffdf9e; }
.notice.good { background: #12301f; border-color: #236b43; color: #a9f0c7; }
.notice.bad { background: #3a1417; border-color: #7a2730; color: #ffb6bb; }

.chunks { display: flex; flex-direction: column; gap: 4px; }
.chunk { border: 1px solid var(--line); border-radius: 8px; padding: 4px 7px; cursor: pointer; background: #15171c; }
.chunk.on { border-color: #ff4b52; background: #231a1d; }
.chunk .head { display: flex; gap: 8px; align-items: baseline; }
.chunk .t { font-family: Consolas, monospace; font-size: 11px; color: var(--muted); flex: none; }
.chunk .txt { flex: 1; font-size: 15px; font-weight: 700; word-break: keep-all; }
.chunk .pinned { color: #ffb020; font-size: 11px; }
.edit { margin-top: 6px; cursor: default; }
.chips { display: flex; flex-wrap: wrap; align-items: center; gap: 2px; margin-top: 6px; }
.chip { padding: 1px 8px; font-size: 14px; border-radius: 6px; font-weight: 700; }
.chip.emph { background: var(--accent); border-color: var(--accent); }
.joint { padding: 0 4px; font-size: 11px; border: 0; background: transparent; color: var(--muted); }
.joint.glue { color: #5ec8ff; font-weight: 700; }
.joint.brk { color: #ff7a80; font-weight: 700; }
.times { display: grid; grid-template-columns: 1fr 1fr auto auto; gap: 6px; margin-top: 6px; align-items: center; }
.times input { padding: 2px 6px; font-family: Consolas, monospace; font-size: 12px; }

.group { background: #15171c; border: 1px solid var(--line); border-radius: 10px; padding: 8px 10px; margin-bottom: 9px; }
.group h4 { margin: 0 0 6px; font-size: 13px; color: #fff; }
.ctl { display: grid; grid-template-columns: 96px 1fr 44px; gap: 8px; align-items: center; min-height: 28px; font-size: 12.5px; color: #c7ccd6; }
.ctl output { text-align: right; font-family: Consolas, monospace; font-size: 11.5px; color: var(--muted); }
.ctl input[type=color] { width: 100%; height: 24px; padding: 0; border: 1px solid var(--line); border-radius: 6px; background: none; cursor: pointer; }
.ctl .seg { grid-column: 2 / 4; justify-self: start; }
.ctl .seg button { padding: 2px 9px; font-size: 12px; }
.ctl select { grid-column: 2 / 4; padding: 2px 6px; }
.fontlist { max-height: 230px; overflow-y: auto; display: flex; flex-direction: column; gap: 3px; margin-bottom: 6px; }
.fontitem { display: flex; justify-content: space-between; align-items: center; text-align: left; padding: 2px 9px; background: #101217; }
.fontitem.on { border-color: #ff4b52; background: #231a1d; }
.fontitem b { font-size: 21px; font-weight: 400; line-height: 1.5; white-space: nowrap; overflow: hidden; }
.fontitem small { color: var(--muted); font: 10.5px system-ui; white-space: nowrap; margin-left: 8px; }
.animgrid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 5px; margin-bottom: 6px; }
.animgrid button { padding: 4px 2px; font-size: 12px; }
.animgrid button.on { background: var(--blue); border-color: var(--blue); color: #fff; font-weight: 700; }

.modal { position: fixed; inset: 0; background: rgba(0,0,0,.6); display: flex; align-items: center; justify-content: center; z-index: 10; }
.dialog { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 18px; width: 430px; }
.dialog h2 { margin: 0 0 12px; font-size: 18px; }
.choice { display: block; width: 100%; text-align: left; margin-bottom: 8px; padding: 9px 12px; }
.choice b { display: block; }
.choice span { font-size: 12px; color: var(--muted); }

.mobileOnly { display: none; }
.staticOnly { display: none; margin: 6px 0 0; }
body.static .staticOnly { display: block; }
body.remote #btnPhone, body.remote #exportReveal { display: none; }
body.static .choice[data-mode=overlay] { display: none; }
.linkbtn { font: inherit; color: #fff; background: var(--blue); border-radius: 8px; padding: 5px 12px; text-align: center; text-decoration: none; font-weight: 700; }
.files { display: flex; flex-direction: column; gap: 4px; margin-top: 8px; max-height: 150px; overflow-y: auto; }
.files a { color: #9cc2ff; font-size: 13px; word-break: break-all; }
.qrs { display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; margin: 10px 0; min-height: 60px; }
.qr { text-align: center; }
.qr svg { width: 180px; height: 180px; display: block; border-radius: 8px; background: #fff; }

.vclist { display: flex; flex-direction: column; gap: 4px; margin: 6px 0; }
.vcitem { display: flex; align-items: center; gap: 8px; padding: 5px 8px; border: 1px solid var(--line); border-radius: 8px; cursor: pointer; }
.vcsteps { margin: 6px 0; padding-left: 20px; }
.vcconsent { margin: 8px 0 2px; align-items: flex-start; }
.notice-lic { color: #ffdf9e; background: #2a2210; border-color: #6b5519; }
#tab-voice .lbl { margin-top: 8px; }
#vcAudio { width: 100%; margin-top: 8px; }
.linkbtn.alt { background: var(--panel2); border: 1px solid var(--line); font-weight: 400; }
.webOnly { display: none; }
body.static .webOnly { display: block; }
#baseCanvas { position: absolute; inset: 0; width: 100%; height: 100%; }
#tl { flex: none; background: #15171c; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; position: relative; }
#tlGrip { height: 12px; cursor: ns-resize; touch-action: none; background: linear-gradient(#2b303a, #1c1f26); }
#tlGrip:hover { background: linear-gradient(#3a4250, #232730); }
#tlGrip::after { content: ''; display: block; width: 60px; height: 4px; margin: 4px auto; background: #8a93a3; border-radius: 3px; }
.tlbar { display: flex; gap: 3px; align-items: center; padding: 3px 6px; flex-wrap: wrap; border-bottom: 1px solid var(--line); }
.tlbar button { padding: 2px 8px; font-size: 13px; }
.tlbar button.active { background: var(--blue); border-color: var(--blue); }
.tlbar .sep { width: 1px; height: 18px; background: var(--line); margin: 0 3px; }
#tlCount { color: #ffd21e; font-weight: 700; margin-left: 4px; }
#tlBody { display: flex; }
#tlHeads { flex: none; width: 92px; height: 170px; overflow: hidden; border-right: 1px solid var(--line); background: #1a1d23; }
.tlhead { display: flex; align-items: center; gap: 2px; padding: 0 3px; border-bottom: 1px solid #262a33; margin-top: 2px; box-sizing: border-box; min-height: 0; overflow: hidden; }
.tlhead.ruler { height: 20px; margin-top: 0; border-bottom: 0; }
.tlhead .nm { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; font-size: 11px; }
.tlhead small { color: var(--muted); }
.tlhead button { padding: 0 2px; font-size: 11px; border: 0; background: transparent; min-height: 0; line-height: 1.5; }
.tlhead button.active { background: #5c1f25; border-radius: 3px; }
#tlTracks { flex: 1; min-width: 0; overflow-x: auto; overflow-y: auto; height: 170px; position: relative; -webkit-overflow-scrolling: touch; }
#tlInner { position: relative; min-height: 100%; min-width: 100%; user-select: none; }
#tlRuler { position: sticky; top: 0; z-index: 6; height: 20px; background: #0f1115; cursor: pointer; touch-action: none; user-select: none; }
#tlRuler b { position: absolute; top: 1px; font: 10px Consolas, monospace; color: #aeb5c2; padding-left: 3px; border-left: 1px solid #5a6170; height: 19px; }
#tlRuler u { position: absolute; bottom: 0; height: 5px; border-left: 1px solid #3a404c; }
.tltrack { position: relative; margin-top: 2px; background: rgba(255,255,255,.015); border-bottom: 1px solid #22252c; }
.tlb { position: absolute; border-radius: 5px; overflow: hidden; border: 1px solid rgba(255,255,255,.2); background: #2d4f86 center left / auto 100% repeat-x; cursor: grab; user-select: none; box-sizing: border-box; }
.tlb.overlay { background-color: #6a3f96; }
.tlb.audio { background: #17503f; }
.tlb.on { border: 2px solid #ffd21e; touch-action: none; z-index: 2; }
.tlb.primary { box-shadow: 0 0 0 1px #fff; }
.tlb.band { outline: 2px dashed #ffd21e; outline-offset: -2px; }
.tlb.lock { cursor: not-allowed; filter: saturate(.45) brightness(.8); }
.tlb.missing { background: repeating-linear-gradient(45deg, #5c1f25, #5c1f25 6px, #3a1417 6px, #3a1417 12px); }
.tlb span { position: absolute; left: 4px; top: 1px; right: 4px; font-size: 10.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-shadow: 0 1px 2px #000; pointer-events: none; z-index: 1; }
.tlwave { position: absolute; left: 0; bottom: 0; pointer-events: none; opacity: .95; }
.tlb.clip .tlwave { height: 45%; }
.tlb em { position: absolute; right: 2px; top: 1px; font-size: 11px; font-style: normal; pointer-events: none; z-index: 1; }
.tlb .h { position: absolute; top: 0; bottom: 0; width: 12px; background: #ffd21e; cursor: ew-resize; touch-action: none; z-index: 2; }
.tlb .h.l { left: 0; } .tlb .h.r { right: 0; }
#tlHead { position: absolute; top: 0; bottom: 0; width: 2px; background: #fff; pointer-events: none; z-index: 7; box-shadow: 0 0 3px #000; }
#tlHead::before { content: ''; position: absolute; left: -5px; top: 0; border: 6px solid transparent; border-top: 8px solid #ff4b52; }
#tlGuide { display: none; position: absolute; top: 0; bottom: 0; width: 1px; background: #3dd8ff; pointer-events: none; z-index: 6; box-shadow: 0 0 4px #3dd8ff; }
#tlBox { display: none; position: absolute; border: 1px solid #ffd21e; background: rgba(255,210,30,.14); pointer-events: none; z-index: 8; }
.tlb.cap { background: #a8222b; border-color: rgba(255,255,255,.28); }
.tlb.cap.on { background: #d42a35; overflow: visible; z-index: 3; }
.tlb.cap span { top: 4px; font-size: 11px; font-weight: 700; left: 3px; right: 3px; overflow: hidden; }
.tlb.cap .h { width: 14px; border-radius: 3px; }
.tlb.cap .h.l { left: -15px; } .tlb.cap .h.r { right: -15px; }
body:not(.static) #tl { display: none; }
#tlZoom { width: 110px; flex: none; margin: 0 2px; }
.ctl.kf { grid-template-columns: 96px 1fr 44px 28px; }
.dialog.tpl { width: 720px; max-width: calc(100vw - 24px); max-height: 92vh; overflow-y: auto; }
.tplgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 8px; margin-top: 6px; }
.tplcard { text-align: left; white-space: normal; padding: 8px 10px; display: flex; flex-direction: column; gap: 3px; min-height: 76px; }
.tplcard b { font-size: 14px; }
.tplcard span { font-size: 11.5px; color: var(--muted); line-height: 1.4; }
.tplcard.on { border-color: #ff4b52; }
.leftseg { display: flex; margin-bottom: 10px; }
.leftseg button { flex: 1; padding: 6px 4px; }
.tpldrop { display: flex; flex-direction: column; align-items: center; gap: 3px; text-align: center; border: 2px dashed #4a5060; border-radius: 10px; padding: 14px 8px; cursor: pointer; background: #121419; margin-bottom: 8px; }
.tpldrop:hover, .tpldrop.over { border-color: #ff4b52; background: #1e1418; }
.tpldrop.has { border-style: solid; border-color: #3dd68c; }
.tpldrop #tplList { color: #9ef0c0; word-break: break-all; }
.tplwish { margin-bottom: 8px; }
.tplwish summary { cursor: pointer; color: #c7ccd6; margin-bottom: 4px; }
.tplcards .preset canvas { aspect-ratio: 9/16; }
.tplcard.busy { opacity: .6; pointer-events: none; }
.tplcard.busy::after { content: '⏳'; position: absolute; top: 6px; right: 6px; }
.kfbtn { padding: 0; width: 26px; height: 24px; font-size: 13px; color: #8a92a0; background: transparent; }
.kfbtn.has { color: #e9c46a; }
.kfbtn.on { color: #111; background: #ffd21e; border-color: #ffd21e; }
.tlb .kfm { position: absolute; bottom: 2px; width: 8px; height: 8px; margin-left: -4px; background: #ffd21e; transform: rotate(45deg); border: 1px solid #000; z-index: 2; pointer-events: none; }
.tlb.fxd::after { content: '✦'; position: absolute; right: 3px; bottom: 0; font-size: 11px; color: #7df9ff; pointer-events: none; }

/* Computers: player in the middle, panels on both sides, a full-width timeline underneath, as in CapCut. */
@media (min-width: 1051px) {
  :root { --bg: #0e0f11; --panel: #18191c; --panel2: #232428; --line: #2c2e33; }
  main { grid-template-columns: 290px minmax(0, 1fr) 360px; grid-template-rows: minmax(0, 1fr) auto; grid-template-areas: "left center right" "tl tl tl"; }
  #left { grid-area: left; } #center { grid-area: center; } #right { grid-area: right; }
  main > #tl { grid-area: tl; border-radius: 0; border: 0; border-top: 1px solid var(--line); background: #141518; }
  main > #tl #tlTracks, main > #tl #tlHeads { height: 230px; }
  main > #tl .tlbar { padding: 4px 10px; background: #18191c; }
  main > #tl .tlbar button { padding: 3px 9px; }
  main > #tl #tlHeads { width: 110px; }
  #center { background: #0b0c0e; padding: 10px 18px 8px; }
  #stage { border-radius: 4px; }
  .tlb.clip { background-color: #1f6f7e; }
  .tlb.on { border-color: #22d3ee; }
  .tlb.cap.on { background: #d42a35; border-color: #22d3ee; }
  #tlHead { background: #fff; }
}

/* Phones and narrow windows: clip on top, one scrolling panel below. */
@media (max-width: 1050px) {
  html, body { height: 100%; }
  body { height: 100dvh; }
  .mobileOnly { display: block; }
  header { gap: 6px; padding: 6px 8px; flex-wrap: wrap; }
  header .spacer, .brand, #clipName, .wpc label:last-child { display: none; }
  .wpc { order: 5; flex: 1 0 100%; justify-content: center; padding: 2px 6px; }
  .wpc .seg button { padding: 3px 10px; }
  #btnExport { margin-left: auto; }
  main { display: flex; flex-direction: column; overflow: hidden; }
  #center { flex: 0 0 auto; height: 50dvh; padding: 6px 8px 4px; gap: 4px; }
  body.static #center { height: 64dvh; }
  #tlTracks, #tlHeads { height: 138px; }
  #tlHeads { width: 38px; }
  .tlhead small, .tlhead button:first-of-type { display: none; }
  .tlbar button { min-height: 30px; padding: 2px 6px; }
  .tlhead button { min-height: 0; }
  #tlTime { display: none; }
  .tabs button { font-size: 12.5px; }
  .posbar { gap: 8px; font-size: 12px; flex-wrap: nowrap; overflow-x: auto; }
  .posbar .small { display: none; }
  .posbar label { white-space: nowrap; }
  #right { flex: 1; min-height: 0; border-left: 0; border-top: 1px solid var(--line); }
  #left { background: none; padding: 0; border: 0; overflow: visible; }
  #left .presets { grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); }
  button { min-height: 34px; }
  .tabs button { padding: 7px 0; }
  .joint { min-height: 30px; padding: 0 7px; font-size: 14px; }
  .chip { min-height: 32px; }
  input[type=text], input[type=number], textarea { font-size: 16px; }
  .ctl { grid-template-columns: 88px 1fr 40px; min-height: 36px; }
  .ctl .seg { flex-wrap: wrap; }
  .times { grid-template-columns: 1fr 1fr; }
  .dialog { width: calc(100vw - 24px); max-height: 90dvh; overflow-y: auto; }
}

/* AI cut */
#center { position: relative; }
.aibtn { background: linear-gradient(135deg, #ff2d3a, #ff7a2d); color: #fff; border: 0; font-weight: 700; }
.aibtn.on { box-shadow: 0 0 0 2px rgba(255, 255, 255, .35) inset; }
.aicut { position: absolute; inset: 0; z-index: 30; display: flex; align-items: flex-start; justify-content: center; padding: 16px; background: rgba(8, 9, 11, .86); backdrop-filter: blur(6px); overflow-y: auto; }
.aibox { margin: auto; width: 100%; max-width: 520px; display: flex; flex-direction: column; gap: 10px; background: #15171c; border: 1px solid #2c3039; border-radius: 18px; padding: 18px; box-shadow: 0 20px 60px -20px rgba(255, 45, 58, .35); }
.aihead { display: flex; justify-content: space-between; align-items: center; font-size: 18px; }
.aihead button { background: transparent; border: 0; color: var(--muted); font-size: 16px; }
.aidrop { display: flex; flex-direction: column; align-items: center; gap: 4px; text-align: center; padding: 22px 12px; border: 2px dashed #4a5060; border-radius: 14px; cursor: pointer; background: #101216; transition: border-color .15s, background .15s; }
.aidrop:hover, .aidrop.over { border-color: #ff4b52; background: #1e1418; }
.aidrop.has { border-style: solid; border-color: #3dd68c; }
.aidrop #aiList { color: #9ef0c0; word-break: break-all; }
.aibig { font-size: 28px; line-height: 1; color: #ff6b4a; }
.aibox textarea { width: 100%; resize: vertical; }
.airead { color: #7df9ff; min-height: 0; }
.aistyle { display: flex; align-items: center; gap: 8px; }
.aistyle select { flex: 1; }
.aigo { padding: 12px; font-size: 16px; font-weight: 800; border: 0; border-radius: 12px; color: #fff; background: linear-gradient(135deg, #ff2d3a, #ff7a2d); cursor: pointer; }
.aigo:disabled { opacity: .55; cursor: wait; }
.aisteps { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.aisteps li { display: flex; align-items: center; gap: 8px; color: #6d7280; font-size: 14px; }
.aisteps li i { width: 18px; height: 18px; border-radius: 50%; border: 2px solid #3a3f4a; flex: none; }
.aisteps li em { margin-left: auto; font-style: normal; font-size: 12px; color: var(--muted); text-align: right; }
.aisteps li.run { color: #fff; }
.aisteps li.run i { border-color: #ff4b52; border-top-color: transparent; animation: aispin .8s linear infinite; }
.aisteps li.ok { color: #cfd3da; }
.aisteps li.ok i { border-color: #3dd68c; background: #3dd68c; }
.aisteps li.ok i::after { content: '✓'; display: block; color: #0b0c0e; font-size: 11px; line-height: 14px; text-align: center; font-style: normal; font-weight: 900; }
@keyframes aispin { to { transform: rotate(360deg); } }
.aifoot { margin: 0; text-align: center; }
.airesult { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 6px 10px; border-radius: 10px; background: #1b1418; border: 1px solid #4a2228; font-size: 13px; }
.airesult span { flex: 1; min-width: 180px; }
.airesult small { display: block; color: var(--muted); }
.airesult button { padding: 4px 10px; font-size: 13px; }
@media (max-width: 1050px) { .aicut { position: fixed; z-index: 60; } }
.aiclear { margin-left: 6px; padding: 1px 8px; font-size: 12px; }
