:host { all: initial; color-scheme: light; }
.skcb { --ink:#273e34; --head:#46634d; --accent:#b36c4f; --accent-strong:#46634d; --paper:#faf9f5; --surface:#fff; --line:#dce2d8; --line-strong:#b8c2b6; --muted:#69756c; --link:#8a4a30; --bubble:#eaf0e7; --bubble-user:#f6ebe3; --soft-accent:#fbf1ea; --soft-line:#e3c1ae; --status:#5a3a28; --eyebrow:#e9d3c4; --code-bg:#1f2421; --code-ink:#e8ece6; --skcb-bottom:24px; --skcb-keyboard:0px; color:var(--ink); font-family:-apple-system,BlinkMacSystemFont,"Hiragino Kaku Gothic ProN","Noto Sans JP",sans-serif; font-size:14px; line-height:1.65; text-align:left; }
.skcb *, .skcb *::before, .skcb *::after { box-sizing:border-box; }
.skcb [hidden] { display:none !important; }
.skcb button, .skcb textarea, .skcb input { font:inherit; }
.skcb button { cursor:pointer; border:0; line-height:1.5; }
.skcb button:disabled { cursor:default; opacity:.55; }
.skcb button:focus-visible, .skcb a:focus-visible, .skcb textarea:focus-visible, .skcb input:focus-visible { outline:3px solid var(--accent); outline-offset:3px; }
.skcb a { color:var(--link); text-underline-offset:3px; cursor:pointer; }
.skcb .launcher { position:fixed; z-index:2147483000; right:24px; bottom:calc(var(--skcb-bottom) + env(safe-area-inset-bottom,0px)); display:flex; gap:10px; align-items:center; min-height:56px; max-width:calc(100vw - 48px); padding:8px 20px 8px 8px; border-radius:40px; background:var(--head); color:#fff; box-shadow:0 6px 24px #152c4033; font-size:14px; font-weight:700; }
.skcb .paw { display:grid; place-items:center; width:44px; height:44px; flex-shrink:0; border-radius:50%; overflow:hidden; background:#fff; }
.skcb .avatar { display:block; width:100%; height:100%; object-fit:cover; background:#fff; border-radius:50%; flex-shrink:0; }
.skcb .identity { display:flex; align-items:center; gap:10px; min-width:0; }
.skcb .header-avatar { width:40px; height:40px; }
.skcb .message-identity { display:flex; align-items:center; gap:6px; margin-bottom:6px; }
.skcb .message-avatar { width:24px; height:24px; }
.skcb .message-identity .message-label { margin:0; }
.skcb .mobile-label { display:none; }
.skcb .panel { position:fixed; z-index:2147483001; right:24px; bottom:calc(var(--skcb-bottom) + 76px + var(--skcb-keyboard) + env(safe-area-inset-bottom,0px)); display:flex; flex-direction:column; width:420px; max-width:calc(100vw - 48px); height:650px; max-height:calc(var(--skcb-vh,100dvh) - var(--skcb-bottom) - 116px - env(safe-area-inset-bottom,0px)); background:var(--paper); border:1px solid var(--line); border-radius:20px; box-shadow:0 16px 70px #162f4033; overflow:hidden; }
.skcb header { flex-shrink:0; display:flex; align-items:center; justify-content:space-between; gap:8px; padding:17px 20px; background:var(--head); color:#fff; }
.skcb .eyebrow { display:block; font-size:9px; letter-spacing:1.8px; color:var(--eyebrow); }
.skcb h2 { font-size:17px; line-height:1.5; margin:4px 0 0; font-weight:700; color:#fff; }
.skcb .icon { min-width:36px; min-height:36px; border-radius:50%; color:#fff; background:#ffffff14; font-size:26px; }
.skcb .intro { padding:14px 20px 12px; border-bottom:1px solid var(--line); flex-shrink:0; }
.skcb p { margin:0 0 10px; }
.skcb .intro p { margin-bottom:5px; font-size:13px; }
.skcb small { display:block; font-size:10px; color:var(--muted); }
.skcb .consent { overflow:auto; padding:18px 20px; font-size:12px; }
.skcb .consent label { display:flex; align-items:flex-start; gap:8px; padding:12px 0 16px; font-weight:600; }
.skcb .agree { margin-top:5px; flex-shrink:0; accent-color:var(--accent); width:16px; height:16px; }
.skcb .primary { padding:10px 18px; border-radius:10px; background:var(--accent-strong); color:#fff; font-weight:700; }
.skcb .start { width:100%; }
.skcb .conversation { display:flex; flex-direction:column; min-height:0; flex:1; overflow:auto; }
.skcb .messages { overflow:auto; flex:1; min-height:90px; padding:16px; overscroll-behavior:contain; }
.skcb .message { margin-bottom:22px; max-width:96%; }
.skcb .message-label { display:block; font-size:11px; color:var(--muted); margin-bottom:5px; }
.skcb .message .bubble { white-space:pre-wrap; overflow-wrap:anywhere; padding:14px 16px; border-radius:3px 13px 13px; background:var(--bubble); font-size:15px; line-height:1.9; margin:0; }
.skcb .message.user { margin-left:auto; }
.skcb .message.user .bubble { border-radius:13px 3px 13px 13px; background:var(--bubble-user); }
.skcb .message.user .message-label { text-align:right; }
.skcb .suggestions { display:flex; flex-wrap:wrap; gap:6px; padding:0 16px 12px; flex-shrink:0; }
.skcb .suggestions button { border:1px solid var(--line); border-radius:20px; color:var(--ink); background:var(--surface); font-size:11px; padding:7px 10px; }
.skcb form { margin:0; padding:12px 16px; border-top:1px solid var(--line); flex-shrink:0; }
.skcb textarea { display:block; resize:vertical; width:100%; min-height:65px; max-height:120px; padding:10px; border:1px solid var(--line-strong); border-radius:10px; background:var(--surface); color:var(--ink); font-size:16px; line-height:1.5; }
.skcb .send-row { display:flex; gap:8px; justify-content:space-between; align-items:center; margin-top:8px; }
.skcb .send-row small { font-size:9px; }
.skcb .retry { background:var(--soft-accent); color:var(--link); padding:10px; margin:0 16px 8px; border:1px solid var(--soft-line); border-radius:8px; }
.skcb .status { font-size:11px; padding:0 16px; margin:4px 0 8px; color:var(--status); flex-shrink:0; }
.skcb .status:empty { display:none; }
.skcb footer { display:flex; align-items:center; justify-content:space-between; gap:8px; padding:10px 16px; border-top:1px solid var(--line); flex-shrink:0; font-size:11px; }
.skcb footer button { padding:5px 8px; background:transparent; color:var(--ink); text-decoration:underline; text-underline-offset:3px; }
.skcb .sr-only { position:absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border:0; }
@media (max-width:520px) { .skcb .launcher { right:12px; min-height:50px; padding:8px 13px 8px 8px; gap:6px; font-size:12px; } .skcb .launcher-label { display:none; } .skcb .mobile-label { display:inline; } .skcb .paw { width:34px; height:34px; } .skcb .panel { right:12px; width:calc(100vw - 24px); max-width:none; bottom:calc(var(--skcb-bottom) + 64px + var(--skcb-keyboard) + env(safe-area-inset-bottom,0px)); max-height:calc(var(--skcb-vh,100dvh) - var(--skcb-bottom) - 84px - env(safe-area-inset-bottom,0px)); border-radius:16px; } .skcb .intro { padding:10px 16px; } .skcb header { padding:12px 16px; } }
@media (max-height:530px) { .skcb .intro { display:none; } .skcb .panel { max-height:calc(var(--skcb-vh,100dvh) - 20px); bottom:calc(10px + var(--skcb-keyboard)); } }

.skcb .typing .bubble { display:flex; align-items:center; gap:12px; width:fit-content; min-height:44px; padding:12px 16px; }
.skcb .typing-label { font-size:12px; color:var(--muted); }
.skcb .typing-dots { display:inline-flex; align-items:center; gap:5px; height:16px; }
.skcb .typing-dots span { display:block; width:6px; height:6px; border-radius:50%; background:var(--accent); opacity:.35; animation:skcb-typing 1.2s ease-in-out infinite; }
.skcb .typing-dots span:nth-child(2) { animation-delay:.16s; }
.skcb .typing-dots span:nth-child(3) { animation-delay:.32s; }
@keyframes skcb-typing { 0%,60%,100% { transform:translateY(0); opacity:.35; } 30% { transform:translateY(-4px); opacity:1; } }
@media (prefers-reduced-motion:reduce) { .skcb .typing-dots span { animation:none; opacity:.7; } }

/* 1.7.0: links, feedback, hand-off, one-tap questions */
.skcb .message .bubble a { color:var(--link); word-break:break-all; }
.skcb .feedback { display:flex; align-items:center; gap:6px; margin-top:6px; min-height:28px; }
.skcb .feedback button { min-width:36px; min-height:30px; padding:2px 8px; border:1px solid var(--line); border-radius:16px; background:var(--surface); font-size:14px; line-height:1; opacity:.75; }
.skcb .feedback button:hover { opacity:1; }
.skcb .feedback button[aria-pressed="true"] { opacity:1; border-color:var(--accent); background:var(--soft-accent); }
.skcb .feedback-note { font-size:11px; color:var(--muted); }
.skcb .handoff { margin-top:10px; padding:12px 14px; border:1px solid var(--soft-line); border-radius:12px; background:var(--soft-accent); }
.skcb .handoff p { padding:0; background:none; font-size:13px; line-height:1.7; margin:0 0 8px; border-radius:0; }
.skcb .handoff-button { display:inline-block; padding:9px 14px; border-radius:10px; background:var(--accent-strong); color:#fff !important; font-weight:700; font-size:13px; text-decoration:none; }
.skcb .suggestions button { cursor:pointer; }
.skcb .suggestions button:hover { border-color:var(--accent); color:var(--link); }

/* 1.8.0: bot check (Cloudflare Turnstile, shown through a slot) */
.skcb .bot-check { margin:0 0 14px; min-height:65px; }
.skcb .bot-check ::slotted(*) { display:block; width:100%; }

/* sukoyaka: code blocks, dark mode (only if the theme sets data-theme="dark"), support card */
.skcb .message.model { max-width:100%; }
.skcb .bubble .code { margin:10px 0; border-radius:10px; overflow:hidden; background:var(--code-bg); white-space:normal; }
.skcb .code-head { display:flex; align-items:center; justify-content:space-between; gap:8px; padding:6px 10px 6px 12px; background:#00000033; color:#c9d1cb; font:600 11px/1.4 ui-monospace,SFMono-Regular,Menlo,Consolas,monospace; letter-spacing:.5px; }
.skcb .code-head .copy { padding:4px 10px; border-radius:6px; background:#ffffff1a; color:#fff; font-size:11px; }
.skcb .code-head .copy:hover { background:#ffffff33; }
.skcb .bubble pre { margin:0; padding:12px 14px; overflow:auto; max-height:340px; background:var(--code-bg); color:var(--code-ink); font:13px/1.65 ui-monospace,SFMono-Regular,Menlo,Consolas,"Courier New",monospace; white-space:pre; tab-size:2; }
.skcb .bubble pre code { font:inherit; }
.skcb footer .register { color:var(--link); font-weight:700; }
.skcb.dark { --ink:#e8eee9; --head:#0f2b25; --accent:#f3ac67; --accent-strong:#1f7f6b; --paper:#101a18; --surface:#192521; --line:#2c3d38; --line-strong:#4a5f58; --muted:#a9b8b1; --link:#91d6ba; --bubble:#1d2d28; --bubble-user:#3a2c1d; --soft-accent:#2a2418; --soft-line:#6b4f2b; --status:#91d6ba; --code-bg:#0b1311; }
.skcb.dark .panel { box-shadow:0 16px 70px #0009; }
.skcb.dark .launcher { box-shadow:0 6px 24px #0008; border:1px solid #3b4840; }

.skcb .support { margin-top:10px; padding:14px 16px; border:1px solid #c9d6c4; border-left:4px solid var(--head); border-radius:10px; background:#f3f7f1; color:var(--ink); }
.skcb .support p { margin:0 0 8px; font-size:13px; line-height:1.8; }
.skcb .support ul { margin:0 0 8px; padding-left:1.2em; font-size:13px; line-height:1.9; }
.skcb .support a { color:var(--link); font-weight:700; }
.skcb .support .support-urgent { font-weight:700; }
