@charset "utf-8";

.app-mobile-bottom-bar {
  display: none;
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 9990;
  height: auto;
  background: #fff;
  border-top: 1px solid #f1f5f9;
  border-radius: 0;
  box-shadow: none;
  /* 7/27 の値。status-bar-style を置かない＝ iOS が下を確保するので、
     ここは元どおり 16px を足す形でよい。 */
  padding: 8px 0 calc(16px + var(--vq-sab,0px)) 0;
}
@media (max-width: 768px){
  .app-mobile-bottom-bar { display: flex; align-items: center; justify-content: space-around; }
  body { padding-bottom: calc(60px + var(--vq-sab,0px)) !important; }
}
.app-mob-tab {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  flex: 1;
  height: 100%;
  padding: 0;
  background: none;
  border: none;
  color: #c0c5ce;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: color .15s;
}
.app-mob-tab .ms {
  font-size: 26px;
  line-height: 1;
  transition: color .15s;
}
.app-mob-tab .app-mob-label {
  font-size: 10px;
  font-weight: 600;
  display: none;
  margin-top: 1px;
}
/* Active: blue icon + label shown */
.app-mob-tab.is-active {
  color: #6366f1;
}
.app-mob-tab.is-active .ms {
  color: #6366f1;
}
.app-mob-tab.is-active .app-mob-label {
  display: block;
  color: #6366f1;
}
/* Inactive: icon only, no label */
.app-mob-tab:not(.is-active):active {
  transform: scale(.9);
}

/* ═══════════════════════════════════════════════════════════════
   VQ Design System v2 — FINAL OVERRIDE
   ファイル最末尾。全ての既存CSSに勝つ。
   ═══════════════════════════════════════════════════════════════ */

/* 1. Primary buttons → インディゴ */
.navbtn.primary,
.navbtn.is-primary,
.btn.primary,
.btn.is-primary,
.auth-gate-btn,
[data-action="login"],
.melta-btn-primary{
  background:#6366f1 !important;
  color:#fff !important;
  border-color:#6366f1 !important;
}
.navbtn.primary:hover,
.navbtn.is-primary:hover,
.auth-gate-btn:hover,
.melta-btn-primary:hover{
  background:#4f46e5 !important;
  box-shadow:0 4px 14px rgba(99,102,241,.3) !important;
}
.navbtn.danger,.navbtn.is-danger{
  background:#ef4444 !important;color:#fff !important;border-color:#ef4444 !important;
}

/* 2. All buttons → 角丸12px */
.navbtn,.textbtn{
  border-radius:12px !important;font-weight:600 !important;
}
.icon-btn{
  border-radius:12px !important;box-shadow:0 2px 8px rgba(0,0,0,.06) !important;
}

/* 3. Cards/Panels → 角丸16px、軽いシャドウ */
.card,.hero,.sheet,.notify-sheet,.search-sheet,
.settings-fullsheet,#menuPanel,#insightsPanel,.ui-modal-card{
  border-radius:16px !important;box-shadow:0 2px 8px rgba(0,0,0,.06) !important;
}

/* 4. Inputs → インディゴフォーカス */
input[type="text"]:focus,input[type="email"]:focus,input[type="number"]:focus,
input[type="search"]:focus,input[type="password"]:focus,
textarea:focus,select:focus,.melta-input:focus{
  border-color:#6366f1 !important;
  box-shadow:0 0 0 3px rgba(99,102,241,.15) !important;
  outline:none !important;
}
input,textarea,select{caret-color:#6366f1 !important;}

/* 5. Badges → インディゴ塗り */
.badge{
  background:rgba(99,102,241,.1) !important;color:#6366f1 !important;
  border:none !important;font-weight:600 !important;border-radius:9999px !important;
}

/* 6. Tabs → シャープ角丸 */
.seg{border-radius:12px !important;padding:3px !important;}
.seg button{border-radius:8px !important;}
.seg button.active{
  background:var(--panel,#fff) !important;color:var(--text,#1e293b) !important;
  font-weight:600 !important;box-shadow:0 1px 3px rgba(0,0,0,.06) !important;
}

/* 7. 正解/不正解 */
.quiz-mark-correct,.correct-mark,.maru{color:#22c55e !important;}
.quiz-mark-wrong,.wrong-mark,.batsu{color:#ef4444 !important;}

/* 8. Selection */
::selection{background:rgba(99,102,241,.2);color:#1e293b;}

/* 9. Focus ring */
:focus-visible{outline:2px solid rgba(99,102,241,.4) !important;outline-offset:2px !important;}

/* 10. Scrollbar */
::-webkit-scrollbar{width:6px;height:6px;}
::-webkit-scrollbar-track{background:transparent;}
::-webkit-scrollbar-thumb{background:rgba(0,0,0,.12);border-radius:3px;}
::-webkit-scrollbar-thumb:hover{background:rgba(0,0,0,.2);}

/* 11. Links */
a{color:#6366f1;}a:hover{color:#4f46e5;}

/* Dark mode */
:root[data-theme-mode="dark"] .badge{background:rgba(129,140,248,.15) !important;color:#818cf8 !important;}
:root[data-theme-mode="dark"] .navbtn.primary,:root[data-theme-mode="dark"] .melta-btn-primary{background:#818cf8 !important;border-color:#818cf8 !important;}
:root[data-theme-mode="dark"] ::selection{background:rgba(129,140,248,.3);color:#f1f5f9;}
:root[data-theme-mode="dark"] ::-webkit-scrollbar-thumb{background:rgba(255,255,255,.1);}

/* ═══════════════════════════════════════════════════════════
   SEDE — VQ Design System v2 完全リスタイル
   ═══════════════════════════════════════════════════════════ */

/* Sede送信ボタン */
.sede-send-btn{
  border-radius:12px !important;
  background:linear-gradient(135deg,#6366f1,#8b5cf6) !important;
  width:42px !important;height:42px !important;
  box-shadow:0 4px 12px rgba(99,102,241,.3) !important;
  transition:all .15s ease !important;
}
.sede-send-btn:hover{
  opacity:1 !important;
  box-shadow:0 6px 20px rgba(99,102,241,.4) !important;
  transform:translateY(-1px) !important;
}

/* Sede New Sessionボタン */
.sede-new-btn{
  border-radius:10px !important;
  background:linear-gradient(135deg,#6366f1,#8b5cf6) !important;
  font-weight:600 !important;font-size:13px !important;
  padding:0 14px !important;height:34px !important;
  box-shadow:0 2px 8px rgba(99,102,241,.2) !important;
  transition:all .15s ease !important;
}
.sede-new-btn:hover{
  opacity:1 !important;
  box-shadow:0 4px 14px rgba(99,102,241,.35) !important;
  transform:translateY(-1px) !important;
}

/* Sedeサイドバー */
.sede-sidebar,.app-sede-sidebar{
  background:#f8fafc !important;
  border-right:1px solid rgba(0,0,0,.06) !important;
}
.sede-session-item{
  border-radius:10px !important;
  padding:10px 12px !important;
  font-size:13px !important;
  transition:all .12s ease !important;
}
.sede-session-item:hover{
  background:rgba(99,102,241,.06) !important;
}
.sede-session-item.is-active{
  background:rgba(99,102,241,.1) !important;
  color:#6366f1 !important;
  font-weight:600 !important;
}

/* Sedeトップバー */
.sede-topbar{
  background:#fff !important;
  border-bottom:1px solid rgba(0,0,0,.06) !important;
}
.sede-topbar-model{
  background:rgba(99,102,241,.08) !important;
  color:#6366f1 !important;
  border-radius:8px !important;
  font-weight:600 !important;
}

/* Sede閉じるボタン */
.sede-close-btn{
  border-radius:10px !important;
  transition:all .12s ease !important;
}
.sede-close-btn:hover{
  background:rgba(99,102,241,.08) !important;
  color:#6366f1 !important;
}

/* Sede入力欄 */
.sede-input,#sedeChatInput{
  border-radius:12px !important;
  border:1.5px solid rgba(0,0,0,.1) !important;
  font-size:14px !important;
  transition:all .15s ease !important;
}
.sede-input:focus,#sedeChatInput:focus{
  border-color:#6366f1 !important;
  box-shadow:0 0 0 3px rgba(99,102,241,.12) !important;
}

/* Sedeチャットバブル */
.sede-chat-msg.is-user .sede-chat-bubble{
  background:linear-gradient(135deg,#6366f1,#7c3aed) !important;
  color:#fff !important;
  border-radius:16px 16px 4px 16px !important;
  box-shadow:0 2px 8px rgba(99,102,241,.2) !important;
}
.sede-chat-msg.is-ai .sede-chat-bubble{
  border-left:3px solid #6366f1 !important;
}

/* Sedeテンプレートカード */
.sede-template-card,.sede-tmpl-card{
  border:1px solid rgba(0,0,0,.06) !important;
  border-radius:14px !important;
  background:#fff !important;
  transition:all .15s ease !important;
  box-shadow:var(--vq-shadow-sm, 0 1px 2px rgba(84,72,140,.05)) !important;
}
.sede-template-card:hover,.sede-tmpl-card:hover{
  border-color:rgba(99,102,241,.3) !important;
  box-shadow:0 4px 14px rgba(99,102,241,.1) !important;
  transform:translateY(-2px) !important;
}

/* Sedeテンプレートアイコン */
.sede-template-card .ms,.sede-tmpl-card .ms,.sede-tmpl-icon{
  color:#6366f1 !important;
}

/* Sedeタブ（Chat/Code切替） */
.sede-tab-bar{
  border-bottom:1px solid rgba(0,0,0,.06) !important;
}

/* Sede Usageセクション */
.app-sede-usage{
  border-top:1px solid rgba(0,0,0,.06) !important;
}
.sede-usage-detail-btn{
  background:rgba(99,102,241,.06) !important;
  border:1px solid rgba(99,102,241,.12) !important;
  color:#6366f1 !important;
  border-radius:10px !important;
}
.sede-usage-detail-btn:hover{
  background:rgba(99,102,241,.12) !important;
}

/* Sedeサイドバーアイテム（メニュー） */
.app-sede-sidebar .app-chat-sidebar-item{
  border-radius:10px !important;
  transition:all .12s ease !important;
}
.app-sede-sidebar .app-chat-sidebar-item:hover{
  background:rgba(99,102,241,.06) !important;
}
.app-sede-sidebar .app-chat-sidebar-item.is-active,
.app-sede-sidebar .app-chat-sidebar-item.active{
  background:rgba(99,102,241,.1) !important;
  color:#6366f1 !important;
}

/* Sedeプレビューバー */
.sede-preview-bar{
  background:#fff !important;
  border-bottom:1px solid rgba(0,0,0,.06) !important;
}
.sede-preview-bar button{
  border-radius:8px !important;
  transition:all .12s ease !important;
}
.sede-preview-bar button:hover{
  background:rgba(99,102,241,.08) !important;
}
.sede-preview-bar button.active,.sede-preview-bar button.is-active{
  background:rgba(99,102,241,.1) !important;
  color:#6366f1 !important;
}

/* Sedeコードエディタツールバー */
.sede-editor-toolbar{
  border-bottom:1px solid rgba(0,0,0,.06) !important;
}
.sede-editor-toolbar button{
  border-radius:8px !important;
}
.sede-editor-toolbar button:hover{
  background:rgba(99,102,241,.08) !important;
  color:#6366f1 !important;
}

/* Sede welcomeメッセージ */
.sede-empty-icon{
  color:rgba(99,102,241,.2) !important;
}

/* Sedeスピナー */
.sede-spinner-icon,.sede-agent-spinner-wrap .sede-spinner-icon{
  border-top-color:#6366f1 !important;
}

/* QuickChatに戻るボタン */
.app-sede-back-btn,.app-sede-footer .app-sede-back-btn{
  border-radius:10px !important;
  transition:all .12s ease !important;
}
.app-sede-back-btn:hover{
  background:rgba(99,102,241,.06) !important;
  color:#6366f1 !important;
}

/* Sede全体の背景 */
#appAiChatShell[data-chat-mode="sede"]{
  background:#f8fafc !important;
}

/* ── VQ v2: High-specificity overrides for data-ui-v2 ── */

/* Primaryボタン → インディゴ */
body[data-ui-v2="1"] .navbtn.primary,
body[data-ui-v2="1"] .navbtn.is-primary,
body[data-ui-v2="1"] .app-home-hero-actions .navbtn.primary,
body[data-ui-v2="1"][data-app-tab="home"] .app-home-hero-actions .navbtn.primary,
body[data-ui-v2="1"] .melta-btn-primary,
body .auth-gate-btn{
  background:#6366f1 !important;
  color:#fff !important;
  border-color:#6366f1 !important;
  border-radius:12px !important;
}
body[data-ui-v2="1"] .navbtn.primary:hover,
body[data-ui-v2="1"] .melta-btn-primary:hover,
body .auth-gate-btn:hover{
  background:#4f46e5 !important;
  box-shadow:0 4px 14px rgba(99,102,241,.3) !important;
}

/* 全ボタン → 角丸12px */
body[data-ui-v2="1"] .navbtn,
body[data-ui-v2="1"] .textbtn,
body[data-ui-v2="1"] .icon-btn{
  border-radius:12px !important;
  font-weight:600 !important;
}

/* カード/サーフェス → 角丸16px、軽いシャドウ */
body[data-ui-v2="1"] .app-home-surface{
  border-radius:16px !important;
  background:var(--panel) !important;
  box-shadow:0 2px 8px rgba(0,0,0,.05) !important;
}
body[data-ui-v2="1"] .card,
body[data-ui-v2="1"] .app-home-practice-card,
body[data-ui-v2="1"] .app-v2-stat-card{
  border-radius:16px !important;
}

/* modeActions(学習モードボタン) */
body[data-ui-v2="1"] .app-home-practice-card #modeActions .btn{
  border-radius:16px !important;
  box-shadow:0 2px 8px rgba(0,0,0,.05) !important;
}
body[data-ui-v2="1"] .app-home-practice-card #modeActions .btn:hover{
  box-shadow:0 4px 14px rgba(0,0,0,.08) !important;
  transform:translateY(-2px) !important;
}

/* バッジ */
body[data-ui-v2="1"] .badge{
  background:rgba(99,102,241,.1) !important;
  color:#6366f1 !important;
  border:none !important;
  font-weight:600 !important;
}

/* Segタブ */
body[data-ui-v2="1"] .seg{
  border-radius:12px !important;
}
body[data-ui-v2="1"] .seg button{
  border-radius:8px !important;
}
body[data-ui-v2="1"] .seg button.active{
  background:var(--panel,#fff) !important;
  font-weight:600 !important;
}

/* inputフォーカス */
body[data-ui-v2="1"] input:focus,
body[data-ui-v2="1"] textarea:focus,
body[data-ui-v2="1"] select:focus{
  border-color:#6366f1 !important;
  box-shadow:0 0 0 3px rgba(99,102,241,.15) !important;
}

/* Hub grid gap */
body[data-ui-v2="1"] .app-home-hub-grid{
  gap:16px !important;
}

/* セクションヘッド */
body[data-ui-v2="1"] .app-home-section-head .app-home-section-title{
  color:var(--text) !important;
}

/* Quick actions */
body[data-ui-v2="1"][data-app-tab="home"] .app-home-quick .textbtn{
  border-radius:12px !important;
}

/* ダークモード */
:root[data-theme-mode="dark"] body[data-ui-v2="1"] .navbtn.primary,
:root[data-theme-mode="dark"] body[data-ui-v2="1"] .melta-btn-primary{
  background:#818cf8 !important;border-color:#818cf8 !important;
}
:root[data-theme-mode="dark"] body[data-ui-v2="1"] .badge{
  background:rgba(129,140,248,.15) !important;color:#818cf8 !important;
}
:root[data-theme-mode="dark"] body[data-ui-v2="1"] .app-home-surface{
  background:var(--panel) !important;
}

/* ═══════════════════════════════════════════════════════════════
   SEDE REDESIGN v2 — 完全上書き
   sede-redesign.html の全スタイルを実際のクラス名で適用
   ファイル最末尾 = 最高優先度
   ═══════════════════════════════════════════════════════════════ */

/* ── Sede全体背景 ── */
#appAiChatShell[data-chat-mode="sede"]{background:#f8fafc !important;}

/* ── サイドバー ── */
#appAiChatShell[data-chat-mode="sede"] .app-sede-sidebar{
  background:#fff !important;border-right:1px solid rgba(0,0,0,.07) !important;
}
/* New Sessionボタン */
#appAiChatShell[data-chat-mode="sede"] .app-sede-nav-item[data-sede-action="newSession"]{
  border-radius:8px !important;background:linear-gradient(135deg,#6366f1,#8b5cf6) !important;
  color:#fff !important;border:none !important;font-weight:600 !important;
  box-shadow:0 2px 8px rgba(99,102,241,.2) !important;transition:all .15s !important;
}
#appAiChatShell[data-chat-mode="sede"] .app-sede-nav-item[data-sede-action="newSession"]:hover{
  box-shadow:0 4px 14px rgba(99,102,241,.35) !important;transform:translateY(-1px) !important;
}
/* サイドバーナビアイテム */
#appAiChatShell[data-chat-mode="sede"] .app-sede-nav-item{
  border-radius:8px !important;font-weight:500 !important;transition:all .12s !important;
}
#appAiChatShell[data-chat-mode="sede"] .app-sede-nav-item:hover{
  background:rgba(99,102,241,.06) !important;
}
/* セッションアイテム */
#appAiChatShell[data-chat-mode="sede"] .app-sede-session-item,
#appAiChatShell[data-chat-mode="sede"] .sede-session-item{
  border-radius:8px !important;transition:all .12s !important;
}
#appAiChatShell[data-chat-mode="sede"] .app-sede-session-item:hover,
#appAiChatShell[data-chat-mode="sede"] .sede-session-item:hover{
  background:rgba(0,0,0,.03) !important;
}
#appAiChatShell[data-chat-mode="sede"] .app-sede-session-item.is-active,
#appAiChatShell[data-chat-mode="sede"] .sede-session-item.is-active{
  background:rgba(99,102,241,.08) !important;color:#6366f1 !important;font-weight:600 !important;
}
/* Usage部分 */
#appAiChatShell[data-chat-mode="sede"] .sede-plan-badge{
  background:rgba(34,197,94,.1) !important;color:#16a34a !important;
  border-radius:6px !important;font-weight:700 !important;
}
#appAiChatShell[data-chat-mode="sede"] .sede-usage-fill.is-daily{
  background:linear-gradient(90deg,#6366f1,#8b5cf6) !important;
}
#appAiChatShell[data-chat-mode="sede"] .sede-usage-detail-btn{
  background:rgba(99,102,241,.06) !important;border:1px solid rgba(99,102,241,.12) !important;
  color:#6366f1 !important;border-radius:8px !important;font-weight:600 !important;
}
#appAiChatShell[data-chat-mode="sede"] .sede-usage-detail-btn:hover{
  background:rgba(99,102,241,.12) !important;
}
/* Quick Chat戻るボタン */
#appAiChatShell[data-chat-mode="sede"] .app-sede-back-btn{
  border-radius:8px !important;transition:all .12s !important;
}
#appAiChatShell[data-chat-mode="sede"] .app-sede-back-btn:hover{
  background:rgba(0,0,0,.04) !important;
}

/* ── トップバー ── */
#appAiChatShell[data-chat-mode="sede"] .sede-topbar{
  background:#fff !important;border-bottom:1px solid rgba(0,0,0,.07) !important;
  padding:8px 16px !important;
}
#appAiChatShell[data-chat-mode="sede"] .sede-topbar-badge{
  background:rgba(99,102,241,.08) !important;color:#6366f1 !important;
  border-radius:6px !important;font-weight:600 !important;
}
/* トップバーのタブ切替 */
#appAiChatShell[data-chat-mode="sede"] .sede-right-tab-bar{
  display:flex !important;gap:4px !important;padding:8px 12px !important;
  border-bottom:1px solid rgba(0,0,0,.07) !important;
}
#appAiChatShell[data-chat-mode="sede"] .sede-right-tab{
  padding:7px 14px !important;font-size:12px !important;font-weight:500 !important;
  color:#94a3b8 !important;border:0 !important;background:none !important;
  border-radius:8px !important;transition:all .12s !important;
  display:flex !important;align-items:center !important;gap:5px !important;
}
#appAiChatShell[data-chat-mode="sede"] .sede-right-tab:hover{
  background:rgba(0,0,0,.04) !important;color:#1e293b !important;
}
#appAiChatShell[data-chat-mode="sede"] .sede-right-tab.is-active{
  background:rgba(99,102,241,.08) !important;color:#6366f1 !important;font-weight:600 !important;
}

/* ── 送信ボタン ── */
#appAiChatShell[data-chat-mode="sede"] .sede-composer-send,
#appAiChatShell[data-chat-mode="sede"] .sede-send-btn,
#appAiChatShell[data-chat-mode="sede"] .app-chat-send{
  border-radius:12px !important;
  background:linear-gradient(135deg,#6366f1,#8b5cf6) !important;
  color:#fff !important;border:none !important;
  box-shadow:0 2px 8px rgba(99,102,241,.25) !important;
  transition:all .15s !important;
}
#appAiChatShell[data-chat-mode="sede"] .sede-composer-send:hover,
#appAiChatShell[data-chat-mode="sede"] .sede-send-btn:hover,
#appAiChatShell[data-chat-mode="sede"] .app-chat-send:hover{
  box-shadow:0 6px 20px rgba(99,102,241,.4) !important;
  transform:translateY(-2px) !important;opacity:1 !important;
}

/* ── チャット入力 ── */
#appAiChatShell[data-chat-mode="sede"] .sede-composer-textarea,
#appAiChatShell[data-chat-mode="sede"] .sede-input,
#appAiChatShell[data-chat-mode="sede"] .app-chat-input{
  border-radius:12px !important;border:1.5px solid rgba(0,0,0,.12) !important;
  font-size:14px !important;transition:all .15s !important;
}
#appAiChatShell[data-chat-mode="sede"] .sede-composer-textarea:focus,
#appAiChatShell[data-chat-mode="sede"] .sede-input:focus,
#appAiChatShell[data-chat-mode="sede"] .app-chat-input:focus{
  border-color:#6366f1 !important;
  box-shadow:0 0 0 3px rgba(99,102,241,.15) !important;
}

/* ── チャットメッセージ ── */
#appAiChatShell[data-chat-mode="sede"] .sede-chat-msg.is-user .sede-chat-bubble{
  background:linear-gradient(135deg,#6366f1,#7c3aed) !important;
  color:#fff !important;border-radius:16px 16px 4px 16px !important;
  box-shadow:0 2px 8px rgba(99,102,241,.15) !important;
  border:none !important;
}
#appAiChatShell[data-chat-mode="sede"] .sede-chat-msg.is-ai .sede-chat-bubble{
  border-left:3px solid #6366f1 !important;
}
/* コードブロック（チャット内） */
#appAiChatShell[data-chat-mode="sede"] .sede-chat-msg.is-ai .sede-chat-bubble code:not([class*="hljs"]){
  background:#1e1e2e !important;color:#e2e8f0 !important;
  padding:2px 7px !important;border-radius:5px !important;
}
#appAiChatShell[data-chat-mode="sede"] .sede-chat-msg.is-ai .sede-chat-bubble pre{
  background:#1e1e2e !important;border-radius:8px !important;
  border:1px solid rgba(255,255,255,.06) !important;
}
#appAiChatShell[data-chat-mode="sede"] .sede-chat-msg.is-ai .sede-chat-bubble pre code{
  color:#e2e8f0 !important;background:transparent !important;
}

/* ── ログパネル ── */
#appAiChatShell[data-chat-mode="sede"] .sede-log-panel{
  background:#fafafa !important;
}
#appAiChatShell[data-chat-mode="sede"] .sede-log-panel-body{
  font-family:'Fira Code','SF Mono',Consolas,monospace !important;
}
/* ツールコール行 */
#appAiChatShell[data-chat-mode="sede"] .sede-oplog-item{
  font-size:12px !important;color:#94a3b8 !important;
  padding:5px 10px !important;
}
#appAiChatShell[data-chat-mode="sede"] .sede-oplog-item .sede-oplog-dot{display:none !important;}
#appAiChatShell[data-chat-mode="sede"] .sede-oplog-item:not(:last-child)::before{display:none !important;}
#appAiChatShell[data-chat-mode="sede"] .sede-oplog-text{
  color:#64748b !important;font-size:12px !important;
}
#appAiChatShell[data-chat-mode="sede"] .sede-oplog-text .ms{
  color:#6366f1 !important;font-size:15px !important;
}
#appAiChatShell[data-chat-mode="sede"] .sede-oplog-text code{
  background:#1e1e2e !important;color:#e2e8f0 !important;
  padding:2px 6px !important;border-radius:4px !important;
}
/* AI会話ブロック（ログ内） */
#appAiChatShell[data-chat-mode="sede"] .sede-log-chat-item{
  padding:10px 0 !important;
}
#appAiChatShell[data-chat-mode="sede"] .sede-log-chat-item .sede-log-chat-dot{display:none !important;}
#appAiChatShell[data-chat-mode="sede"] .sede-log-chat-item:not(:last-child)::before{display:none !important;}
#appAiChatShell[data-chat-mode="sede"] .sede-log-chat-item .sede-log-chat-body{
  padding-left:14px !important;border-left:3px solid #6366f1 !important;
  font-size:14px !important;line-height:1.8 !important;color:#1e293b !important;
  font-family:'Inter',system-ui,-apple-system,sans-serif !important;
}
#appAiChatShell[data-chat-mode="sede"] .sede-log-chat-item .sede-log-chat-body code{
  background:#1e1e2e !important;color:#e2e8f0 !important;
  padding:2px 6px !important;border-radius:4px !important;
}
#appAiChatShell[data-chat-mode="sede"] .sede-log-chat-item .sede-log-chat-body pre{
  background:#1e1e2e !important;border-radius:8px !important;
}

/* ── diff表示 ── */
#appAiChatShell[data-chat-mode="sede"] .sede-diff-inline{
  margin:8px 0 !important;border-radius:8px !important;
  border:1px solid rgba(255,255,255,.08) !important;background:#0d1117 !important;
}
#appAiChatShell[data-chat-mode="sede"] .sede-diff-inline-header .sede-diff-fname{
  color:#a5b4fc !important;
}
#appAiChatShell[data-chat-mode="sede"] .sede-diff-inline-line.is-add{background:rgba(46,160,67,.12) !important;}
#appAiChatShell[data-chat-mode="sede"] .sede-diff-inline-line.is-add .sede-diff-inline-code{color:#aff5b4 !important;}
#appAiChatShell[data-chat-mode="sede"] .sede-diff-inline-line.is-del{background:rgba(248,81,73,.12) !important;}
#appAiChatShell[data-chat-mode="sede"] .sede-diff-inline-line.is-del .sede-diff-inline-code{color:#ffa198 !important;}

/* ── コードエディタ ── */
#appAiChatShell[data-chat-mode="sede"] .sede-code-view{
  background:#1e1e2e !important;
}

/* ── ツールバーボタン ── */
#appAiChatShell[data-chat-mode="sede"] .sede-editor-toolbar button{
  border-radius:8px !important;transition:all .12s !important;
}
#appAiChatShell[data-chat-mode="sede"] .sede-editor-toolbar button:hover{
  background:rgba(99,102,241,.08) !important;color:#6366f1 !important;
}

/* ── プレビューバー ── */
#appAiChatShell[data-chat-mode="sede"] .sede-preview-bar button{
  border-radius:8px !important;transition:all .12s !important;
}
#appAiChatShell[data-chat-mode="sede"] .sede-preview-bar button:hover{
  background:rgba(99,102,241,.08) !important;
}
#appAiChatShell[data-chat-mode="sede"] .sede-preview-bar button.active{
  background:rgba(99,102,241,.1) !important;color:#6366f1 !important;
}

/* ── スピナー ── */
#appAiChatShell[data-chat-mode="sede"] .sede-spinner-icon{
  border-top-color:#6366f1 !important;
}
#appAiChatShell[data-chat-mode="sede"] .sede-agent-spinner-wrap .sede-spinner-icon{
  border-top-color:#6366f1 !important;
}

/* ── Welcome画面テンプレートカード ── */
#appAiChatShell[data-chat-mode="sede"] .sede-tmpl-card{
  border:1px solid rgba(0,0,0,.07) !important;border-radius:12px !important;
  background:#fff !important;transition:all .15s !important;
  box-shadow:var(--vq-shadow-sm, 0 1px 2px rgba(84,72,140,.05)) !important;
}
#appAiChatShell[data-chat-mode="sede"] .sede-tmpl-card:hover{
  border-color:rgba(99,102,241,.3) !important;
  box-shadow:0 6px 20px rgba(99,102,241,.1) !important;
  transform:translateY(-3px) !important;
}

/* ── Composerエリア全体 ── */
#appAiChatShell[data-chat-mode="sede"] .sede-composer-inline{
  background:#fff !important;border-top:1px solid rgba(0,0,0,.07) !important;
}
#appAiChatShell[data-chat-mode="sede"] .sede-composer-btn{
  border-radius:8px !important;transition:all .12s !important;
}
#appAiChatShell[data-chat-mode="sede"] .sede-composer-btn:hover{
  background:rgba(0,0,0,.04) !important;
}

/* ── 閉じるボタン ── */
#appAiChatShell[data-chat-mode="sede"] .sede-close-btn{
  border-radius:8px !important;transition:all .12s !important;
}
#appAiChatShell[data-chat-mode="sede"] .sede-close-btn:hover{
  background:rgba(99,102,241,.08) !important;color:#6366f1 !important;
}

/* ── ダークモード対応 ── */
:root[data-theme-mode="dark"] #appAiChatShell[data-chat-mode="sede"]{background:#0f172a !important;}
:root[data-theme-mode="dark"] #appAiChatShell[data-chat-mode="sede"] .app-sede-sidebar{background:#1e293b !important;}
:root[data-theme-mode="dark"] #appAiChatShell[data-chat-mode="sede"] .sede-topbar{background:#1e293b !important;}
:root[data-theme-mode="dark"] #appAiChatShell[data-chat-mode="sede"] .sede-composer-inline{background:#1e293b !important;}
:root[data-theme-mode="dark"] #appAiChatShell[data-chat-mode="sede"] .sede-chat-msg.is-user .sede-chat-bubble{
  background:linear-gradient(135deg,#818cf8,#7c3aed) !important;
}
:root[data-theme-mode="dark"] #appAiChatShell[data-chat-mode="sede"] .sede-chat-msg.is-ai .sede-chat-bubble{
  border-left-color:#818cf8 !important;
}
:root[data-theme-mode="dark"] #appAiChatShell[data-chat-mode="sede"] .sede-composer-send,
:root[data-theme-mode="dark"] #appAiChatShell[data-chat-mode="sede"] .sede-send-btn,
:root[data-theme-mode="dark"] #appAiChatShell[data-chat-mode="sede"] .app-chat-send{
  background:linear-gradient(135deg,#818cf8,#7c3aed) !important;
}
:root[data-theme-mode="dark"] #appAiChatShell[data-chat-mode="sede"] .app-sede-session-item.is-active,
:root[data-theme-mode="dark"] #appAiChatShell[data-chat-mode="sede"] .sede-session-item.is-active{
  background:rgba(129,140,248,.12) !important;color:#818cf8 !important;
}
:root[data-theme-mode="dark"] #appAiChatShell[data-chat-mode="sede"] .sede-right-tab.is-active{
  background:rgba(129,140,248,.12) !important;color:#818cf8 !important;
}
:root[data-theme-mode="dark"] #appAiChatShell[data-chat-mode="sede"] .sede-oplog-text .ms{color:#818cf8 !important;}
:root[data-theme-mode="dark"] #appAiChatShell[data-chat-mode="sede"] .sede-log-chat-item .sede-log-chat-body{
  border-left-color:#818cf8 !important;color:#f1f5f9 !important;
}
:root[data-theme-mode="dark"] #appAiChatShell[data-chat-mode="sede"] .sede-tmpl-card{
  background:#1e293b !important;border-color:rgba(255,255,255,.08) !important;
}
:root[data-theme-mode="dark"] #appAiChatShell[data-chat-mode="sede"] .sede-tmpl-card:hover{
  border-color:rgba(129,140,248,.3) !important;
}

