/* KASKOW Lab — AI */
.lai-out { min-height: 380px; display: flex; flex-direction: column; }
.lai-out > div { display: flex; flex-direction: column; gap: 12px; }
.lai-card { display: flex; flex-direction: column; gap: 10px; padding: 14px 16px; border-radius: 16px; border: 1px solid var(--lab-line); background: color-mix(in srgb, var(--lab-acc) 3%, var(--lab-card)); animation: laiIn .3s ease both; }
.lai-card:nth-child(2) { animation-delay: .06s; } .lai-card:nth-child(3) { animation-delay: .12s; }
@keyframes laiIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.lai-card-h { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.lai-card-h small { font-size: .74rem; color: var(--muted); font-variant-numeric: tabular-nums; }
.lai-card-h small.bad { color: #dc2626; font-weight: 700; }
.lai-card-h .grow { flex: 1; }
.lai-text { white-space: pre-wrap; word-break: break-word; font-size: .93rem; line-height: 1.7; }
.lai-text ins { text-decoration: none; background: rgba(22,163,74,.18); border-radius: 3px; box-shadow: inset 0 -2px 0 rgba(22,163,74,.5); }
.lai-text del { color: #b91c1c; background: rgba(239,68,68,.12); border-radius: 3px; }
[data-theme="dark"] .lai-text del { color: #fca5a5; }
.lai-card.sk { gap: 10px; animation: none; }
.lai-card.sk i { display: block; height: 12px; border-radius: 6px; background: linear-gradient(90deg, color-mix(in srgb, var(--text) 7%, transparent) 25%, color-mix(in srgb, var(--lab-acc) 18%, transparent) 50%, color-mix(in srgb, var(--text) 7%, transparent) 75%); background-size: 300% 100%; animation: laiSk 1.3s linear infinite; }
@keyframes laiSk { from { background-position: 100% 0; } to { background-position: -50% 0; } }
.lai-err { display: flex; gap: 10px; align-items: flex-start; padding: 14px 16px; border-radius: 14px; background: rgba(239,68,68,.08); border: 1px solid rgba(239,68,68,.25); color: #b91c1c; }
[data-theme="dark"] .lai-err { color: #fca5a5; }
.lai-err > div { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }
.lai-priv { margin: 0; }
.lab-btn.primary.busy { position: relative; color: transparent; pointer-events: none; }
.lab-btn.primary.busy::after { content: ""; position: absolute; inset: 0; margin: auto; width: 22px; height: 22px; border-radius: 50%; border: 3px solid rgba(255,255,255,.4); border-top-color: #fff; animation: laiSpin .8s linear infinite; }
@keyframes laiSpin { to { transform: rotate(360deg); } }
.lab-btn.primary.busy svg { opacity: 0; }
