.kg-dialog { border:0; border-radius:22px; padding:0; width:calc(100% - 20px); max-width:520px; max-height:calc(var(--app-height, 100dvh) - 24px); margin:auto; color:#243748; background:#fff; box-shadow:0 20px 70px #15395044; }
.kg-dialog::backdrop { background:#17324580; }
.kg-shell { display:flex; flex-direction:column; max-height:calc(var(--app-height, 100dvh) - 24px); }
.kg-head { display:flex; align-items:center; justify-content:space-between; padding:17px 18px 13px; border-bottom:1px solid #e8edf1; flex:none; }
.kg-head small { color:#7c8d9b; font-size:11px; letter-spacing:1px; }
.kg-head h3 { margin:4px 0 0; font-size:19px; }
.kg-close { border:0; background:#f0f4f7; color:#516577; width:40px; height:40px; border-radius:50%; font-size:24px; }
.kg-body { overflow-y:auto; overscroll-behavior:contain; -webkit-overflow-scrolling:touch; min-height:0; padding:16px 18px; }
.kg-question { padding:14px; border-radius:14px; background:#edf5ff; line-height:1.65; overflow-wrap:anywhere; }
.kg-question b { font-size:16px; display:block; }
.kg-meta { color:#64809a; font-size:12px; line-height:1.6; margin-top:7px; }
.kg-context { margin:14px 0; border:1px solid #e2e9ef; border-radius:12px; padding:12px; }
.kg-context summary { font-size:14px; font-weight:600; cursor:pointer; min-height:25px; }
.kg-tip { font-size:12px; color:#778898; line-height:1.7; margin:10px 0; }
.kg-turn { padding:10px 0; border-bottom:1px solid #edf0f4; font-size:13px; line-height:1.7; white-space:pre-wrap; overflow-wrap:anywhere; }
.kg-turn:last-child { border:0; }
.kg-turn .kg-original-answer { color:#7a8894; margin-top:5px; }
.kg-label { display:block; font-size:15px; font-weight:600; margin:16px 0 9px; }
.kg-body textarea { display:block; box-sizing:border-box; width:100%; min-height:180px; resize:vertical; border:1px solid #bdcedb; border-radius:12px; padding:12px; font-family:inherit; font-size:16px; line-height:1.7; color:#25394c; background:white; }
.kg-body textarea:focus { outline:2px solid #aacdf5; border-color:#5394d7; }
.kg-foot { padding:12px 18px max(14px, env(safe-area-inset-bottom)); border-top:1px solid #e8edf1; background:#fff; flex:none; }
.kg-buttons { display:flex; gap:9px; }
.kg-buttons button { min-height:44px; border-radius:11px; padding:10px 12px; font-size:13px; font-weight:600; border:1px solid #c2d3e0; background:#f4f8fb; color:#426580; cursor:pointer; flex:1; }
.kg-buttons button.kg-primary { color:white; border-color:#2379bf; background:#2379bf; flex:1.65; }
.kg-buttons button:disabled { opacity:.5; cursor:wait; }
.kg-feedback { min-height:0; font-size:12px; line-height:1.6; color:#aa3737; margin:0 0 8px; white-space:pre-wrap; }
.kg-feedback:empty { display:none; }
.kg-preview-answer { border:1px solid #dce7ef; padding:14px; border-radius:12px; white-space:pre-wrap; overflow-wrap:anywhere; line-height:1.8; font-size:15px; }
.gap-actions button { min-height:38px; padding:7px 12px; font-size:12px; }
.home-alert-card p { font-size:13px; line-height:1.7; overflow-wrap:anywhere; }
.home-alert-card button { min-height:38px; font-size:12px; padding:8px 12px; }
.kg-dialog [hidden] { display:none !important; }
.kg-feedback-note { margin-top:12px; padding:12px; background:#fff5ef; border-radius:12px; color:#945431; font-size:13px; line-height:1.7; overflow-wrap:anywhere; }
.kg-feedback-note p { white-space:pre-wrap; margin-top:6px; }
.feedback-reply-actions { display:flex; flex-wrap:wrap; align-items:center; gap:10px; margin-top:12px; }
.feedback-reply-actions button { min-height:44px; border:1px solid #c8dced; border-radius:10px; padding:9px 13px; background:#edf6ff; color:#216cad; font-weight:600; font-size:13px; }
.feedback-reply-actions span { color:#617789; font-size:12px; }
.feedback-status-filter { display:flex; align-items:center; flex-wrap:wrap; gap:12px; margin:12px 0; color:#657586; font-size:13px; }
.feedback-status-filter select { min-height:44px; border:1px solid #c8d7e3; border-radius:9px; padding:7px; background:#fff; font-size:14px; }
.fi-intro { font-size:14px; line-height:1.8; color:#60758a; margin-bottom:15px; }
.fi-impact { width:100%; margin-top:10px; padding:14px 0 0; border-top:1px solid #dbe8e7; }
.fi-impact-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:6px; text-align:center; }
.fi-impact-grid > div { min-width:0; padding:10px 3px; background:#edf7f4; border-radius:10px; }
.fi-impact .fi-impact-grid strong { display:block; font-size:24px; color:#176f66; overflow-wrap:anywhere; }
.fi-impact-grid span { display:block; font-size:11px; margin-top:5px; color:#53766f; }
.fi-impact-note { font-size:11px; line-height:1.7; color:#6b7d8b; margin:10px 0; }
.fi-impact-badge { display:inline-block; padding:4px 9px; background:#fff1d5; color:#936412; border-radius:8px; font-size:12px; }
.fi-impact-message { font-size:13px; line-height:1.8; color:#42635f; margin:9px 0; }
.fi-impact summary { min-height:32px; font-size:11px; color:#6b7d8b; cursor:pointer; }
.fi-notice { width:100%; display:flex; flex-direction:column; align-items:flex-start; text-align:left; gap:8px; padding:16px; margin-bottom:12px; border:1px solid #dbe6ef; border-radius:15px; background:linear-gradient(135deg,#f4f9ff,#fff); color:#233d55; font-family:inherit; overflow-wrap:anywhere; }
.fi-notice strong { font-size:16px; line-height:1.5; }
.fi-state { color:#167769; background:#e6f4ef; padding:3px 8px; border-radius:6px; font-size:11px; }
.fi-excerpt { white-space:pre-wrap; font-size:13px; line-height:1.75; }
.fi-date { font-size:12px; color:#70869c; }
.fi-original { white-space:pre-wrap; margin-top:12px; line-height:1.8; overflow-wrap:anywhere; }
.fi-card-head { display:flex; align-items:center; justify-content:space-between; gap:12px; width:100%; }
.fi-ack { min-height:44px; min-width:88px; padding:9px 13px; border:1px solid #b7d8ef; border-radius:10px; background:#e9f4ff; color:#1565a4; font-family:inherit; font-size:14px; font-weight:600; line-height:1.4; white-space:nowrap; }
.fi-ack:disabled { background:#f0f4f7; border-color:#e2e8ed; color:#789; }
.fi-open { display:flex; flex-direction:column; align-items:flex-start; gap:8px; width:100%; border:0; padding:0; text-align:left; background:transparent; color:inherit; font-family:inherit; overflow-wrap:anywhere; }
.fi-open:focus-visible,.fi-ack:focus-visible { outline:2px solid #5394d7; outline-offset:3px; }
.fi-card-status { margin:0; font-size:12px; line-height:1.6; color:#60758a; }
.fi-card-status:empty { display:none; }
.fi-count { margin:0 0 14px; font-size:13px; color:#52738d; }
.fi-more { padding:12px; width:100%; border:1px solid #cbddeb; border-radius:10px; background:#f4f9ff; color:#296f9f; font-family:inherit; font-size:14px; }
@media(max-height:500px) { .kg-head { padding:8px 14px; } .kg-body { padding:10px 14px; } .kg-foot { padding:8px 14px; } }
