/* AI 자동분류 업무 화면 확장 스타일 — style.css 토큰 기반 */
@font-face{font-family:'Noto Sans KR';src:url('../fonts/NotoSansKR-Regular.woff2') format('truetype');font-weight:400;font-style:normal;font-display:swap;}
:root{
  --page-max: 1920px;
  --ai-gradient: linear-gradient(135deg, var(--color-brand-navy), var(--color-brand-blue));
  --ai-soft: #eef5ff;
  --ai-violet: #7c3aed;
  --ai-pink: #ec4899;
}
body{min-width:1200px}.app-main{min-width:0}.content-wrap{padding:18px 20px 28px}.page-title-row{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;margin-bottom:14px}.page-kicker{font-size:12px;color:var(--color-brand-blue);font-weight:700;margin-bottom:4px}.page-title{font-size:24px;font-weight:800;letter-spacing:-.7px;color:var(--color-text-primary)}.page-desc{font-size:13px;color:var(--color-text-secondary);margin-top:4px}.hero{background:var(--ai-gradient);border-radius:16px;color:#fff;padding:22px;box-shadow:0 12px 30px rgba(30,77,183,.18);position:relative;overflow:hidden;margin-bottom:16px}.hero:after{content:'';position:absolute;right:-80px;top:-80px;width:240px;height:240px;background:rgba(255,255,255,.14);border-radius:50%}.hero h1{font-size:25px;line-height:1.3;letter-spacing:-.8px;margin-bottom:8px}.hero p{opacity:.88;font-size:13px;max-width:980px}.hero-metrics{display:grid;grid-template-columns:repeat(5,1fr);gap:10px;margin-top:18px}.hero-metric{background:rgba(255,255,255,.13);border:1px solid rgba(255,255,255,.2);border-radius:12px;padding:12px}.hero-metric span{display:block;font-size:11px;opacity:.75}.hero-metric strong{font-size:24px;letter-spacing:-.6px}.quick-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:14px;margin-bottom:16px}.quick-card{background:#fff;border:1px solid var(--color-border);border-radius:14px;padding:16px;box-shadow:var(--shadow-card);transition:.15s;cursor:pointer}.quick-card:hover{transform:translateY(-2px);box-shadow:0 8px 22px rgba(15,23,42,.08);border-color:#bfdbfe}.quick-card__icon{width:34px;height:34px;border-radius:10px;background:var(--ai-soft);display:flex;align-items:center;justify-content:center;font-size:18px;margin-bottom:10px}.quick-card h3{font-size:15px;margin-bottom:5px}.quick-card p{font-size:12px;color:var(--color-text-secondary);line-height:1.5}.section-grid{display:grid;grid-template-columns:1.15fr .85fr;gap:14px}.kpi-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:10px;margin-bottom:14px}.kpi-card{background:#fff;border:1px solid var(--color-border);border-radius:12px;padding:14px;box-shadow:var(--shadow-card)}.kpi-label{font-size:12px;color:var(--color-text-secondary);display:flex;justify-content:space-between}.kpi-value{font-size:25px;font-weight:800;color:var(--color-brand-blue);margin-top:6px}.kpi-delta{font-size:11px;margin-top:4px}.ai-stage-flow{display:grid;grid-template-columns:repeat(5,1fr);gap:8px}.ai-stage{border:1px solid var(--color-border);background:#fff;border-radius:12px;padding:12px;position:relative;min-height:112px}.ai-stage:not(:last-child):after{content:'›';position:absolute;right:-9px;top:40%;font-size:24px;color:#94a3b8;z-index:2}.ai-stage small{display:inline-flex;padding:2px 7px;border-radius:999px;background:#eef2ff;color:var(--color-brand-blue);font-weight:700;font-size:10px}.ai-stage h4{font-size:13px;margin:8px 0 6px}.ai-stage p{font-size:11px;color:var(--color-text-secondary);line-height:1.45}.grade{display:inline-flex;align-items:center;justify-content:center;min-width:44px;height:24px;border-radius:999px;color:white;font-size:12px;font-weight:800}.grade-1{background:#94a3b8}.grade-2{background:#60a5fa}.grade-3{background:#2dd4bf}.grade-4{background:#f97316}.grade-5{background:#ef4444}.confidence{height:8px;border-radius:99px;background:#e2e8f0;overflow:hidden;min-width:74px}.confidence i{display:block;height:100%;background:var(--color-brand-blue);border-radius:99px}.reason-box{background:#f8fafc;border:1px dashed #cbd5e1;border-radius:10px;padding:10px;font-size:12px;color:#334155;line-height:1.55}.side-panel{display:grid;gap:14px}.mini-list{display:grid;gap:8px}.mini-item{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:10px;border:1px solid var(--color-border);border-radius:10px;background:#fff}.mini-item strong{font-size:12px}.mini-item span{font-size:11px;color:var(--color-text-secondary)}.progress-line{height:8px;background:#edf2f7;border-radius:99px;overflow:hidden}.progress-line i{display:block;height:100%;border-radius:99px;background:var(--color-brand-blue)}.search-hero{display:grid;grid-template-columns:1fr 330px;gap:14px;align-items:stretch}.search-box-large{background:#fff;border:1px solid var(--color-border);border-radius:14px;padding:16px}.query-input{height:48px;border:2px solid #dbeafe;border-radius:12px;width:100%;font-size:15px;padding:0 16px;outline:none}.query-input:focus{border-color:var(--color-brand-blue);box-shadow:0 0 0 3px rgba(30,77,183,.1)}.chip-row{display:flex;gap:8px;flex-wrap:wrap;margin-top:12px}.chip{border:1px solid #bfdbfe;background:#eff6ff;color:#1d4ed8;border-radius:999px;padding:5px 10px;font-size:12px;cursor:pointer}.result-card{border:1px solid var(--color-border);border-radius:12px;background:#fff;padding:14px;margin-bottom:10px}.result-card h4{font-size:14px;margin-bottom:6px}.result-meta{display:flex;gap:6px;flex-wrap:wrap;margin-bottom:8px}.score{color:var(--color-brand-blue);font-weight:800}.image-drop{border:2px dashed #bfdbfe;border-radius:14px;background:#f8fbff;min-height:190px;display:flex;align-items:center;justify-content:center;text-align:center;color:#64748b;padding:16px}.ops-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:14px}.model-card{background:#fff;border:1px solid var(--color-border);border-radius:14px;padding:15px;box-shadow:var(--shadow-card)}.model-head{display:flex;align-items:center;justify-content:space-between;margin-bottom:10px}.model-title{font-size:15px;font-weight:800}.metric-row{display:grid;grid-template-columns:repeat(3,1fr);gap:8px;margin-top:10px}.metric-box{background:#f8fafc;border-radius:10px;padding:8px;text-align:center}.metric-box span{display:block;font-size:10px;color:#64748b}.metric-box strong{font-size:15px}.log-line{display:grid;grid-template-columns:130px 90px 1fr 90px;gap:8px;align-items:center;padding:9px 10px;border-bottom:1px solid var(--color-border);font-size:12px}.modal{position:fixed;inset:0;background:rgba(15,23,42,.42);display:none;align-items:center;justify-content:center;z-index:500}.modal.active{display:flex}.modal-card{background:#fff;border-radius:16px;width:760px;max-height:86vh;overflow:auto;box-shadow:0 22px 70px rgba(15,23,42,.28)}.modal-head{display:flex;align-items:center;justify-content:space-between;padding:16px 18px;border-bottom:1px solid var(--color-border)}.modal-body{padding:18px}.toast{position:fixed;right:22px;bottom:22px;background:#0f172a;color:white;border-radius:12px;padding:12px 16px;box-shadow:0 14px 40px rgba(15,23,42,.25);display:none;z-index:600}.toast.show{display:block}.form-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:8px}.form-grid .span-2{grid-column:span 2}.form-grid .span-4{grid-column:span 4}.textarea{width:100%;min-height:112px;border:1px solid var(--color-border);border-radius:8px;padding:10px;resize:vertical}.timeline{position:relative;padding-left:18px}.timeline:before{content:'';position:absolute;left:5px;top:6px;bottom:6px;width:2px;background:#dbeafe}.timeline-item{position:relative;margin-bottom:12px}.timeline-item:before{content:'';position:absolute;left:-17px;top:4px;width:10px;height:10px;background:var(--color-brand-blue);border-radius:50%}.timeline-item strong{font-size:12px}.timeline-item p{font-size:11px;color:#64748b;margin-top:2px}.hidden{display:none!important}@media(max-width:1400px){.quick-grid{grid-template-columns:repeat(2,1fr)}.section-grid,.search-hero{grid-template-columns:1fr}.hero-metrics,.kpi-grid{grid-template-columns:repeat(3,1fr)}.ops-grid{grid-template-columns:1fr 1fr}}
/* Ulsan Startup AI custom additions */
.sidebar-logo-text{font-size:12px;line-height:1.35}.sidebar-logo img{display:block}.hero{background:linear-gradient(135deg,#214f9a,#1e4db7)}
.chat-panel{background:#fff;border:1px solid var(--color-border);border-radius:14px;box-shadow:var(--shadow-card);overflow:hidden; display:flex; flex-direction:column; height:calc(100vh - 230px);}.chat-box{flex:1; min-height:0; overflow-y:auto; padding:16px; background:#f8fafc}.chat-msg{max-width:84%;padding:10px 12px;border-radius:12px;margin-bottom:10px}.chat-msg strong{display:block;font-size:12px;margin-bottom:4px}.chat-msg p{font-size:13px;line-height:1.55}.chat-user{margin-left:auto;background:#dbeafe}.chat-ai{background:#fff;border:1px solid #e2e8f0}.chat-input{display:flex;gap:8px;padding:12px;border-top:1px solid var(--color-border);background:#fff}.chat-input input{flex:1;height:38px;border:1px solid var(--color-border);border-radius:8px;padding:0 12px}.onepager, .doc-preview{background:#fff;border:1px solid var(--color-border);border-radius:14px;padding:16px;box-shadow:var(--shadow-card)}.onepager h3,.doc-preview h3{font-size:18px;margin-bottom:12px;color:var(--color-brand-blue)}.onepager dt{font-weight:800;margin-top:9px}.onepager dd{font-size:13px;color:var(--color-text-secondary);line-height:1.55;margin-top:3px}.doc-preview h4{margin-top:12px;font-size:14px}.doc-preview p{font-size:13px;color:#475569;line-height:1.65}.research-log{padding-left:18px;color:#475569;line-height:1.8}.toast{position:fixed;right:24px;bottom:24px;background:#1e293b;color:#fff;padding:12px 16px;border-radius:10px;box-shadow:0 12px 30px rgba(0,0,0,.22);opacity:0;transform:translateY(10px);transition:.2s;z-index:9999}.toast.show{opacity:1;transform:translateY(0)}

/* History management design additions */
.mt-lg{margin-top:16px}.history-board{background:#fff;border:1px solid var(--color-border);border-radius:16px;padding:16px;margin-bottom:16px;box-shadow:var(--shadow-card)}.history-toolbar{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-bottom:12px}.history-toolbar h2{font-size:20px;letter-spacing:-.5px}.history-tools{display:flex;gap:8px;align-items:center}.history-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:12px}.history-card{border:1px solid #dbeafe;background:linear-gradient(180deg,#fff,#f8fbff);border-radius:14px;padding:14px;transition:.15s;box-shadow:0 1px 3px rgba(15,23,42,.04)}.history-card:hover{transform:translateY(-2px);box-shadow:0 10px 24px rgba(30,77,183,.10)}.history-card__top{display:flex;align-items:center;justify-content:space-between;margin-bottom:10px}.history-type{display:inline-flex;padding:4px 9px;border-radius:999px;font-size:11px;font-weight:800}.history-type--idea{background:#eef2ff;color:#4338ca}.history-type--plan{background:#ecfdf5;color:#047857}.history-type--market{background:#eff6ff;color:#1d4ed8}.history-date{font-size:11px;color:#94a3b8}.history-card h3{font-size:15px;margin-bottom:6px}.history-card p{font-size:12px;color:#64748b;line-height:1.5;min-height:36px}.history-actions{display:flex;gap:6px;margin-top:12px}.history-actions button{border:1px solid #bfdbfe;background:#fff;color:#1e4db7;border-radius:8px;padding:6px 10px;font-size:12px;cursor:pointer}.history-actions button:hover{background:#eff6ff}.history-layout{display:grid;grid-template-columns:320px 1fr;gap:14px;align-items:start}.history-sidebar{background:#fff;border:1px solid var(--color-border);border-radius:14px;padding:12px;box-shadow:var(--shadow-card);position:sticky;top:8px}.history-search{display:grid;gap:8px;margin-bottom:10px}.history-search .filter-input,.history-search .history-list{display:grid;gap:8px;max-height:620px;overflow:auto}.history-list-item{border:1px solid var(--color-border);border-radius:12px;padding:12px;background:#fff;cursor:pointer;transition:.15s}.history-list-item:hover{border-color:#bfdbfe;background:#f8fbff}.history-list-item.active{border-color:#1e4db7;background:#eff6ff;box-shadow:inset 3px 0 0 #1e4db7}.history-list-item strong{display:block;font-size:13px;color:#1e293b;margin-bottom:4px}.history-list-item span{display:block;font-size:11px;color:#1e4db7;font-weight:700;margin-bottom:5px}.history-list-item em{display:block;font-style:normal;font-size:11px;color:#64748b;line-height:1.45}.history-workspace{min-width:0}.history-version-strip{display:flex;gap:8px;flex-wrap:wrap;margin:0 0 12px}.history-version-strip span{border:1px solid #cbd5e1;background:#fff;border-radius:999px;padding:6px 10px;font-size:12px;color:#64748b}.history-version-strip span.active{border-color:#1e4db7;background:#eff6ff;color:#1e4db7;font-weight:800}.history-summary-card{background:#fff;border:1px solid var(--color-border);border-radius:14px;padding:16px;box-shadow:var(--shadow-card)}.history-summary-card strong{display:block;font-size:16px;margin-bottom:8px}.history-summary-card span{display:inline-flex;background:#eff6ff;color:#1e4db7;border-radius:999px;padding:4px 8px;font-weight:800;font-size:11px;margin-bottom:10px}.history-summary-card p{font-size:12px;color:#64748b;line-height:1.6}.table-toolbar__actions{display:flex;gap:8px;align-items:center}.btn--outline{background:#fff;border:1px solid var(--color-border);color:var(--color-brand-blue)}.flex{display:flex}.gap-sm{gap:8px}@media(max-width:1400px){.history-layout{grid-template-columns:1fr}.history-sidebar{position:relative;top:auto}.history-grid{grid-template-columns:1fr}.history-toolbar{align-items:flex-start;flex-direction:column}.history-tools{width:100%}.history-tools input{flex:1}}

/* ============================================================
   Responsive patch - Ulsan Startup AI
   HTML/JS 변경을 최소화하고 CSS 중심으로 모바일 대응
   ============================================================ */
html, body { max-width:100%; }
* { min-width:0; }

@media (max-width: 1180px) {
  body { min-width:0 !important; overflow-x:hidden; }
  .app-wrapper, .app-body, .app-main { width:100%; min-width:0; }
  .app-body { overflow:visible; }
  .app-main { overflow:visible; }
  .content-wrap { overflow:visible; padding:16px; }

  .app-header {
    height:auto;
    min-height:52px;
    flex-wrap:wrap;
    gap:8px;
    padding:10px 12px;
  }
  .header-toggle-btn { order:1; }
  .header-breadcrumb {
    order:2;
    flex:1 1 calc(100% - 48px);
    min-width:0;
    margin-left:0;
    overflow:hidden;
    white-space:nowrap;
    text-overflow:ellipsis;
  }
  .header-favorite-btn,
  .header-logout-btn { order:3; }
  .header-favorite-btn { margin-right:0; }

  .tab-bar {
    height:auto;
    min-height:38px;
    align-items:flex-end;
    overflow-x:auto;
    white-space:nowrap;
    -webkit-overflow-scrolling:touch;
  }
  .tab-item { flex:0 0 auto; }

  .page-title-row {
    flex-direction:column;
    align-items:stretch;
    gap:12px;
  }
  .page-title { font-size:22px; }
  .page-desc { line-height:1.55; }
  .table-toolbar__actions {
    width:100%;
    flex-wrap:wrap;
  }
  .table-toolbar__actions .btn,
  .page-title-row > .btn { flex:1 1 auto; }

  .hero { padding:20px; border-radius:14px; }
  .hero h1 { font-size:22px; }
  .hero-metrics { grid-template-columns:repeat(3,1fr); }
  .quick-grid,
  .section-grid,
  .search-hero,
  .ops-grid,
  .history-layout,
  .profile-layout,
  .profile-card-grid { grid-template-columns:1fr !important; }
  .kpi-grid { grid-template-columns:repeat(2,1fr); }
  .ai-stage-flow { grid-template-columns:repeat(2,1fr); }
  .ai-stage:not(:last-child):after { display:none; }
  .history-sidebar { position:relative; top:auto; }
  .history-list { max-height:none; }

  .form-grid,
  .metric-row,
  .register-grid,
  .profile-form { grid-template-columns:1fr !important; }
  .form-grid .span-2,
  .form-grid .span-4,
  .profile-form .full { grid-column:auto; }

  .filter-area { padding:12px; }
  .filter-row { align-items:stretch; }
  .filter-label { width:100%; min-width:0; text-align:left; }
  .filter-input,
  .filter-date-input,
  .query-input { width:100%; min-width:0; }
  .filter-actions { width:100%; margin-left:0; flex-wrap:wrap; }
  .filter-actions .btn { flex:1 1 120px; }

  .table-toolbar { flex-direction:column; align-items:stretch; gap:10px; }
  .table-wrap { overflow-x:auto; -webkit-overflow-scrolling:touch; }
  .data-table { min-width:720px; }

  .modal { padding:14px; align-items:flex-start; overflow:auto; }
  .modal-card { width:100%; max-height:none; }
  .log-line { grid-template-columns:1fr; gap:4px; }
}

@media (max-width: 768px) {
  :root { --header-height:52px; --tab-bar-height:38px; }
  body { background:#f8fbff; }

  .app-sidebar {
    position:fixed;
    left:0;
    top:0;
    bottom:0;
    width:260px;
    max-width:82vw;
    transform:translateX(-100%);
    transition:transform .22s ease;
    z-index:1000;
    box-shadow:18px 0 48px rgba(15,23,42,.22);
  }
  /* 기존 toggleSidebar()는 collapsed 클래스를 붙이므로, 모바일에서는 이 클래스를 '열림' 상태로 활용 */
  .app-sidebar.collapsed {
    width:260px;
    min-width:0;
    transform:translateX(0);
  }
  .app-sidebar.collapsed .sidebar-nav__label { opacity:1; pointer-events:auto; }
  .sidebar-logo { height:68px; }
  .sidebar-nav__item { height:46px; color:rgba(255,255,255,.78); }

  .app-header { position:sticky; top:0; z-index:900; }
  .header-breadcrumb { font-size:11px; padding:4px 9px; }
  .header-logout-btn { padding:5px 9px; font-size:11px; }

  .content-wrap { padding:12px; }
  .hero { padding:18px; margin-bottom:12px; }
  .hero h1 { font-size:20px; }
  .hero p { font-size:12px; }
  .hero-metrics,
  .kpi-grid,
  .ai-stage-flow { grid-template-columns:1fr; }
  .hero-metric { display:flex; align-items:center; justify-content:space-between; }
  .hero-metric strong { font-size:22px; }

  .quick-grid { gap:10px; }
  .quick-card { padding:14px; }
  .card, .history-board, .history-summary-card, .onepager, .doc-preview, .chat-panel, .model-card, .result-card, .search-box-large { border-radius:12px; }
  .chat-box { height:300px; }
  .chat-msg { max-width:94%; }
  .chat-input { flex-direction:column; }
  .chat-input .btn { width:100%; }

  .history-toolbar { flex-direction:column; align-items:stretch; }
  .history-tools { width:100%; flex-direction:column; align-items:stretch; }
  .history-actions { flex-wrap:wrap; }
  .history-actions button { flex:1 1 90px; }

  .metric-row { grid-template-columns:1fr !important; }
  .chip-row { gap:6px; }
  .chip { font-size:11px; }
  .image-drop { min-height:140px; }
  .toast { left:12px; right:12px; bottom:12px; text-align:center; }
}

@media (max-width: 480px) {
  html { font-size:12px; }
  .page-title { font-size:20px; }
  .page-kicker { font-size:11px; }
  .page-desc { font-size:12px; }
  .content-wrap { padding:10px; }
  .tab-item { height:32px; padding:0 10px; }
  .btn { min-height:36px; justify-content:center; }
  .table-toolbar__actions { flex-direction:column; }
  .table-toolbar__actions .btn { width:100%; }
  .hero h1 { font-size:18px; }
  .quick-card h3 { font-size:14px; }
}

/* Streaming answer indicator removed: keep live answer clean without blinking block cursor */
.chat-msg.streaming p::after,
#planStream::after {
  content: none !important;
  display: none !important;
}


/* 히스토리 항목 삭제 버튼 */
.history-list-item{position:relative;padding-right:38px;}
.history-delete-btn{
  position:absolute;
  right:10px;
  top:10px;
  width:22px;
  height:22px;
  border:1px solid #e2e8f0;
  border-radius:999px;
  background:#fff;
  color:#94a3b8;
  font-size:16px;
  line-height:18px;
  cursor:pointer;
  display:flex;
  align-items:center;
  justify-content:center;
  transition:.15s;
}
.history-delete-btn:hover{background:#fee2e2;border-color:#fecaca;color:#dc2626;}

/* 히스토리 목록은 제목/상태 정보만 표시하고 본문 요약은 숨깁니다. */
.history-list-item em{display:none!important;}

/* 실시간 사업계획 캔버스 */
.business-canvas,
.onepager.business-canvas{
  padding:0;
  overflow:hidden;
}
.canvas-header {
  /* 레이아웃 — 세로 구조 */
  display: flex;
  flex-direction: column;
  gap: 4px;

  /* 좌우 정렬 — 카드와 맞춤 */
  margin: 0 16px;
  padding: 16px 0 12px;

  /* 그라디언트 및 구분선 — 복원 */
  border-bottom: 1px solid var(--color-border);
  background: linear-gradient(180deg, #ffffff, #f8fbff);
}

.canvas-header__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.canvas-header h3 {
  margin: 2px 0 0;
  color: var(--color-brand-blue);
  font-size: 18px;
  letter-spacing: -.4px;
}

.canvas-header .canvas-sub {
  font-size: 12px;
  color: var(--color-text-secondary);
  margin: 0;
  line-height: 1.5;
}
.canvas-sub{
  font-size:12px;
  color:var(--color-text-secondary);
  line-height:1.5;
}
.canvas-badge{
  flex-shrink:0;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:74px;
  height:26px;
  padding:0 10px;
  border-radius:999px;
  background:#eef2ff;
  color:#1e4db7;
  font-size:11px;
  font-weight:800;
  border:1px solid #dbeafe;
}
.canvas-badge--live{
  background:#fff7ed;
  color:#c2410c;
  border-color:#fed7aa;
}
.canvas-item-name{
  margin:14px 16px 12px;
  border:1px solid #dbeafe;
  border-radius:12px;
  background:#eff6ff;
  padding:12px;
}
.canvas-item-name span{
  display:block;
  font-size:11px;
  color:#64748b;
  font-weight:700;
  margin-bottom:4px;
}
.canvas-item-name strong{
  display:block;
  color:#1e293b;
  font-size:16px;
  letter-spacing:-.3px;
}
.canvas-grid{
  display:grid;
  grid-template-columns:1fr;
  gap:10px;
  padding:0 16px 16px;
}
.canvas-card{
  border:1px solid var(--color-border);
  border-radius:12px;
  background:#fff;
  padding:12px;
  box-shadow:0 1px 2px rgba(15,23,42,.04);
}
.canvas-card__head{
  display:grid;
  gap:3px;
  margin-bottom:8px;
}
.canvas-card__head strong{
  font-size:13px;
  color:#0f172a;
  letter-spacing:-.2px;
}
.canvas-card__head small{
  font-size:11px;
  color:#64748b;
  line-height:1.45;
}
.canvas-card p{
  font-size:13px;
  line-height:1.65;
  color:#334155;
}
.canvas-card h2,.canvas-card h3,.canvas-card h4{
  font-size:13px;
  margin:6px 0;
  color:#1e4db7;
}

/* One-pager DOCX download button */
.canvas-actions{
  flex-shrink:0;
  display:flex;
  align-items:center;
  justify-content:flex-end;
  gap:8px;
  flex-wrap:wrap;
}
.canvas-download-btn{
  height:26px;
  padding:0 11px;
  border:1px solid #bfdbfe;
  border-radius:999px;
  background:#ffffff;
  color:#1e4db7;
  font-size:11px;
  font-weight:800;
  cursor:pointer;
  box-shadow:0 1px 2px rgba(15,23,42,.06);
  transition:.15s;
}
.canvas-download-btn:hover{
  background:#eff6ff;
  border-color:#93c5fd;
  transform:translateY(-1px);
}
.canvas-download-btn:active{transform:translateY(0);}
/* 내려받기 형식 선택 드롭다운 (기본 / 린 캔버스 / BMC) */
.canvas-download{position:relative;display:inline-flex;}
.canvas-download__caret{
  font-size:9px;
  margin-left:3px;
  transition:transform .18s ease;
}
.canvas-download.open .canvas-download__caret{transform:rotate(180deg);}
.canvas-download.open .canvas-download-btn{
  background:#eff6ff;
  border-color:#93c5fd;
}
.canvas-download__menu{
  position:absolute;
  top:calc(100% + 6px);
  right:0;
  min-width:236px;
  background:#ffffff;
  border:1px solid #e2e8f0;
  border-radius:14px;
  box-shadow:0 18px 44px rgba(15,23,42,.16),0 2px 8px rgba(15,23,42,.06);
  padding:6px;
  display:none;
  flex-direction:column;
  gap:2px;
  z-index:40;
  opacity:0;
  transform:translateY(-4px);
  transition:opacity .16s ease,transform .16s ease;
}
.canvas-download.open .canvas-download__menu{
  display:flex;
  opacity:1;
  transform:translateY(0);
}
.canvas-download__menu button{
  display:flex;
  flex-direction:column;
  align-items:flex-start;
  gap:2px;
  width:100%;
  text-align:left;
  border:0;
  background:transparent;
  border-radius:10px;
  padding:9px 11px;
  cursor:pointer;
  transition:background .14s ease;
}
.canvas-download__menu button:hover{background:#f1f6ff;}
.canvas-download__menu button strong{
  font-size:12.5px;
  font-weight:800;
  color:#1e293b;
  letter-spacing:-.2px;
}
.canvas-download__menu button:hover strong{color:#1e4db7;}
.canvas-download__menu button span{
  font-size:10.5px;
  color:#64748b;
  font-weight:600;
}
@media(max-width:768px){
  .canvas-actions{width:100%;justify-content:flex-start;}
  .canvas-download__menu{left:0;right:auto;}
}

/* Business Plan live canvas layout */
.business-plan-grid{grid-template-columns:1.15fr .85fr;align-items:stretch;}
.business-plan-panel{background:#fff;border:1px solid var(--color-border);border-radius:14px;box-shadow:var(--shadow-card);overflow:hidden;min-height:calc(100vh - 230px);}
.business-plan-canvas{padding:0;overflow:auto;}
.plan-status-box{margin:0 16px 12px;border:1px solid #fed7aa;background:#fff7ed;border-radius:12px;padding:11px 12px;display:grid;gap:4px;}
.plan-status-box strong{color:#c2410c;font-size:12px;}
.plan-status-box span{color:#7c2d12;font-size:12px;line-height:1.5;}
.plan-canvas-grid{gap:10px;padding-bottom:16px;}
.plan-section-card p{min-height:42px;}
.btn--send{height:38px;padding:0 18px;background:#1e4db7;color:#fff;border-radius:8px;font-size:13px;font-weight:800;}
.btn--send:hover{background:#1740a0;}
@media(max-width:1400px){.business-plan-grid{grid-template-columns:1fr!important}.business-plan-panel{min-height:auto}}

/* Markdown rendering for chat answers: ideation + business-plan */
.chat-msg .chat-content{
  font-size:13px;
  line-height:1.65;
  color:#334155;
  word-break:break-word;
}
.chat-msg .chat-content p{margin:0 0 9px;line-height:1.65;}
.chat-msg .chat-content p:last-child{margin-bottom:0;}
.chat-msg .chat-content h2,
.chat-msg .chat-content h3,
.chat-msg .chat-content h4{
  margin:12px 0 7px;
  color:#0f172a;
  letter-spacing:-.25px;
  line-height:1.35;
}
.chat-msg .chat-content h2{font-size:17px;}
.chat-msg .chat-content h3{font-size:15px;}
.chat-msg .chat-content h4{font-size:14px;}
.chat-msg .chat-content ul,
.chat-msg .chat-content ol{margin:6px 0 10px 20px;padding:0;}
.chat-msg .chat-content li{margin:3px 0;line-height:1.55;}
.chat-msg .chat-content blockquote{
  margin:8px 0;
  padding:8px 10px;
  border-left:3px solid #3b82f6;
  background:#eff6ff;
  border-radius:8px;
  color:#334155;
}
.chat-msg .chat-content code{
  font-family:Consolas,'Courier New',monospace;
  font-size:12px;
  background:#f1f5f9;
  border:1px solid #e2e8f0;
  border-radius:5px;
  padding:1px 4px;
  color:#0f172a;
}
.chat-msg .chat-content pre{
  margin:8px 0 10px;
  padding:10px 12px;
  background:#0f172a;
  color:#e2e8f0;
  border-radius:10px;
  overflow:auto;
  white-space:pre-wrap;
}
.chat-msg .chat-content pre code{
  background:transparent;
  border:0;
  color:inherit;
  padding:0;
}
.md-table-wrap{
  width:100%;
  overflow-x:auto;
  margin:9px 0 12px;
  border:1px solid #dbeafe;
  border-radius:10px;
  background:#fff;
}
.md-table{
  width:100%;
  min-width:420px;
  border-collapse:collapse;
  font-size:12px;
}
.md-table th{
  background:#eff6ff;
  color:#1e4db7;
  font-weight:800;
  text-align:left;
  padding:8px 9px;
  border-bottom:1px solid #dbeafe;
  white-space:nowrap;
}
.md-table td{
  padding:8px 9px;
  border-top:1px solid #eef2ff;
  color:#334155;
  vertical-align:top;
}
.md-table tr:nth-child(even) td{background:#f8fbff;}

/* Ideataion live canvas layout */
.onepager{padding:0;overflow:auto;}
/* ── 히스토리 상태 배지 ─────────────────────────────────── */
.history-status {
  font-style: normal;
  font-weight: 700;
  font-size: 11px;
  padding: 2px 7px;
  border-radius: 999px;
  display: inline-block;
  letter-spacing: .1px;
  vertical-align: middle;
}
.history-list-item span b.history-status {
  display: inline-block !important;
}
.history-status--wip {
  background: #fef9c3;
  color: #92400e;
}
.history-status--done {
  background: #dcfce7;
  color: #166534;
}

/* ── 추가 검증 필요 강조 박스 ───────────────────────────── */
.verify-chip {
  display: block;
  margin: 10px 0 2px;
  padding: 9px 13px 10px;
  background: #fff7ed;
  border: 1.5px solid #fb923c;
  border-left: 4px solid #ea580c;
  border-radius: 10px;
  line-height: 1.6;
}
.verify-chip__label {
  display: block;
  font-size: 11px;
  font-weight: 800;
  color: #c2410c;
  letter-spacing: .3px;
  margin-bottom: 4px;
}
.verify-chip__text {
  display: block;
  font-size: 12px;
  color: #7c2d12;
  font-weight: 400;
}

/* ── 히스토리 상태 필터 select ──────────────────────────── */
.filter-select {
  width: 100%;
  height: 34px;
  border: 1px solid var(--color-border, #e2e8f0);
  border-radius: 10px;
  background: #fff;
  padding: 0 10px;
  font-size: 12px;
  color: #334155;
  font-weight: 600;
  cursor: pointer;
  outline: none;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' stroke='%2394a3b8' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  padding-right: 28px;
}
.filter-select:focus {
  border-color: #1e4db7;
  box-shadow: 0 0 0 3px rgba(30,77,183,.09);
}

/* ── 사업계획서 항목별 상태 배지 (STORM 판정) ──────────────── */
.plan-section-card .canvas-card__head{display:flex;align-items:center;flex-wrap:wrap;gap:6px;}
.sec-status{font-size:11px;font-weight:700;padding:2px 8px;border-radius:999px;display:inline-block;line-height:1.4;}
.sec-status--done{background:#dcfce7;color:#166534;}
.sec-status--wip{background:#fef9c3;color:#92400e;}
.sec-status--empty{background:#fee2e2;color:#b91c1c;}
.plan-section-card .canvas-card__head small{flex-basis:100%;}

/* ============================================================
   ▣ 디자인 시안 v1.0 적용 (Design Shisang v1.0)
   ------------------------------------------------------------
   울산대학교 창업특화 생성형 AI · 디자인시안 v1.0 기준으로
   사이드바 / 헤더 / 탭바 / 대시보드 히어로 / 기본 버튼을
   재정의합니다. HTML 변경 없이 이 블록(파일 최하단, 마지막 로드)
   만으로 기존 style.css · app.css 규칙을 덮어씁니다.
   되돌리려면 본 블록만 삭제하면 됩니다.
   ============================================================ */
:root{
  --shi-brand:#1e4db7; --shi-navy:#4170c0; --shi-accent:#3b82f6; --shi-deep:#16357f;
  --shi-bg:#eef3fb;
  --shi-grad:linear-gradient(135deg,#1e4db7,#3b82f6);
  --shi-side-grad:linear-gradient(180deg,#4170c0,#1e4db7 60%,#16357f);
  --shi-hero-grad:radial-gradient(130% 130% at 88% 0,#2a5fd0,#1e4db7 55%,#16357f);
}

/* ── 전체 배경 톤 (시안 #EEF3FB) ───────────────────────── */
body{background:var(--shi-bg);}
.app-main{background:var(--shi-bg);}
.content-wrap{background:transparent;}

/* ── 사이드바 : 단색 → 세로 그라디언트 + 라운드 네비 ──────── */
.app-sidebar{ background:var(--shi-side-grad); }
.sidebar-logo{
  background:transparent;
  border-bottom:1px solid rgba(255,255,255,.16);
  height:auto; padding:18px 16px; gap:11px;
}
.sidebar-logo img{
  width:36px; height:36px; border-radius:10px;
  background:#fff; padding:4px; object-fit:contain;
}
.sidebar-logo-text{ font-size:13px; font-weight:800; line-height:1.25; }
.sidebar-nav{ padding:14px 10px; }
.sidebar-nav__item{
  height:auto; padding:11px 12px; margin-bottom:3px;
  border-radius:10px; color:#dce8ff; font-size:13px; font-weight:600;
}
.sidebar-nav__item:hover{ background:rgba(255,255,255,.10); color:#fff; }
.sidebar-nav__item.active{ background:rgba(255,255,255,.16); color:#fff; font-weight:700; }
.sidebar-nav__item.active::before{ display:none; } /* 시안은 좌측 바 대신 라운드 배경 */
.sidebar-nav__arrow{ margin-left:auto; opacity:.6; }

/* ── 헤더 : 로그아웃 버튼 채움 → 아웃라인, breadcrumb 정돈 ── */
.app-header{ height:50px; }
.header-breadcrumb{
  background:transparent; border-radius:0; padding:0; margin-left:6px;
  color:#64748b; font-size:12px; font-weight:500;
}
.header-breadcrumb span{ color:#1e293b; font-weight:700; }
.header-logout-btn{
  background:#fff; color:#64748b;
  border:1px solid var(--color-border); border-radius:8px;
  font-size:12px; font-weight:700; padding:7px 13px; margin-left:auto;
}
.header-logout-btn:hover{ background:#fff; border-color:var(--shi-brand); color:var(--shi-brand); }
.header-toggle-btn span{ background:#64748b; }

/* ── 탭바 : 브라우저 탭 → 플랫 언더라인 ──────────────────── */
.tab-bar{
  height:44px; align-items:stretch;
  background:#fff; background-image:none;
  border-bottom:1px solid var(--color-border);
  padding:0 16px; gap:2px;
}
.tab-item{
  background:transparent; border:0; border-radius:0;
  height:auto; max-width:none; padding:0 16px;
  color:#64748b; font-size:13px; font-weight:600;
  border-bottom:2px solid transparent;
}
.tab-item:hover{ background:transparent; color:var(--shi-brand); }
.tab-item.active{
  background:transparent; height:auto; color:var(--shi-brand);
  border:0; border-bottom:2px solid var(--shi-brand); font-weight:700;
}

/* ── 대시보드 히어로 : 사선 → 시안 라디얼 그라디언트 ──────── */
.hero{
  background:var(--shi-hero-grad);
  border-radius:16px; padding:26px;
  box-shadow:0 10px 30px rgba(30,77,183,.18);
}
.hero-metrics{ grid-template-columns:repeat(auto-fit,minmax(150px,1fr)); }

/* ── 기본 버튼 : 시안 그라디언트 프라이머리 ──────────────── */
.btn--primary{
  background:var(--shi-grad);
  border-radius:8px; box-shadow:0 10px 22px rgba(30,77,183,.26);
}
.btn--primary:hover{ background:var(--shi-grad); transform:translateY(-1px); }
.btn--send{ background:var(--shi-brand); border-radius:8px; }
.btn--send:hover{ background:#1740a0; }

/* ── 히스토리 타입 배지 : 시안 컬러 매핑 (계획서=보라, 시장=그린) ─ */
.history-type--idea{ background:#eef2ff; color:#4338ca; }
.history-type--plan{ background:#f5f3ff; color:#7c3aed; }
.history-type--market{ background:#ecfdf5; color:#059669; }

/* ── 모바일 재적용 (위 데스크탑 규칙이 기존 미디어쿼리를 덮지 않도록) ─ */
@media (max-width:768px){
  .tab-bar{ height:auto; min-height:38px; align-items:flex-end; }
  .tab-item{ flex:0 0 auto; }
  .sidebar-nav__item{ color:rgba(255,255,255,.82); }
}
@media (max-width:480px){
  .tab-item{ height:auto; padding:0 12px; }
}

.canvas-service-summary{
    margin-top:8px;
    font-size:14px;
    line-height:1.6;
    color:#64748b;
    font-weight:400;
}
/* ── 생성 로딩 오버레이(스피너 + 진행바): 무거운 PPTX 생성 대기 표시 ── */
.gen-loading{position:fixed;inset:0;z-index:9998;display:none;align-items:center;justify-content:center;background:rgba(15,23,42,.42);backdrop-filter:blur(2px);-webkit-backdrop-filter:blur(2px);}
.gen-loading.show{display:flex;animation:genFade .18s ease;}
@keyframes genFade{from{opacity:0}to{opacity:1}}
.gen-loading__card{background:#fff;border-radius:16px;padding:28px 30px 26px;width:min(90vw,360px);box-shadow:0 24px 60px rgba(15,23,42,.28);text-align:center;}
.gen-loading__spinner{width:46px;height:46px;margin:2px auto 16px;border-radius:50%;border:4px solid #e6ebf3;border-top-color:#1E4DB7;animation:genSpin .8s linear infinite;}
@keyframes genSpin{to{transform:rotate(360deg)}}
.gen-loading__title{font-size:15px;font-weight:800;color:#162033;margin-bottom:6px;}
.gen-loading__sub{font-size:12.5px;color:#64748b;line-height:1.55;margin-bottom:16px;}
.gen-loading__bar{height:7px;background:#eef2f7;border-radius:99px;overflow:hidden;}
.gen-loading__fill{height:100%;width:8%;background:linear-gradient(90deg,#1E4DB7,#3B82F6);border-radius:99px;transition:width .4s ease;}

/* Live Business Canvas — 참고자료(출처) */
.canvas-sources{margin-top:14px;padding:12px 14px;border:1px solid #E2E8F0;border-radius:10px;background:#F8FAFC;margin-left:20px;margin-right:20px;margin-bottom:20px;}
.canvas-sources__head{font-size:12.5px;font-weight:700;color:#1E4DB7;margin-bottom:6px;}
.canvas-sources__list{margin:0;padding-left:2px;list-style:none;}
.canvas-sources__list li{font-size:12px;color:#334155;line-height:1.5;margin:2px 0;word-break:break-all;}
.canvas-sources__pg{color:#64748B;}
.canvas-sources__bk{color:#94A3B8;}
