:root {
  --accent: #155f96;
  --accent-2: #1e88d8;
  --bg: #ffffff;
  --panel: #f1f2f4;
  --panel-2: #e9eaec;
  --card: #f4f7fb;
  --text: #1f2328;
  --muted: #737b86;
  --line: rgba(15, 23, 42, .12);
  --danger: #d23f57;
  --shadow: 0 12px 36px rgba(15, 23, 42, .12);
  font-family: Arial, Helvetica, sans-serif;
}
* { box-sizing: border-box; }
html, body, #app { width: 100%; height: 100%; margin: 0; }
body { background: var(--bg); color: var(--text); overflow: hidden; }
button, input, textarea { font: inherit; }
button { cursor: pointer; }
.app-shell { display: grid; grid-template-columns: 248px minmax(0, 1fr); width: 100%; height: 100%; min-height: 0; background: var(--bg); }
.sidebar { display: flex; flex-direction: column; min-width: 0; background: var(--panel); border-right: 1px solid var(--line); }
.side-head { height: 48px; display: flex; align-items: center; justify-content: center; gap: 7px; padding: 0 8px; }
.brand-small { display: inline-flex; align-items: center; gap: 5px; white-space: nowrap; font-size: 19px; letter-spacing: 0; }
.brand-small img { width: 17px; height: 17px; }
.brand-wordmark { display: inline-flex; align-items: baseline; gap: 4px; white-space: nowrap; color: #1f2328; }
.brand-globus { color: var(--accent); font-weight: 800; }
.brand-patriot { color: #1f2328; font-weight: 400; }
.search-wrap { display: grid; grid-template-columns: minmax(0, 1fr) 36px; gap: 8px; align-items: center; padding: 4px 14px 10px; }
.search { width: 100%; height: 36px; border-radius: 999px; border: 1px solid rgba(0,0,0,.25); background: #fff; padding: 0 14px 0 34px; outline: 0; font-size: 12px; font-weight: 700; }
.search:focus-visible,
.input:focus-visible,
.rename-input:focus-visible {
  outline: 2px solid rgba(21, 95, 150, .42);
  outline-offset: 2px;
}
.search-box { position: relative; }
.search-box::before {
  content: "";
  position: absolute;
  left: 13px;
  top: 50%;
  width: 15px;
  height: 15px;
  transform: translateY(-50%);
  background: #30343a;
  -webkit-mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='m21 21-4.35-4.35M10.5 18a7.5 7.5 0 1 1 0-15 7.5 7.5 0 0 1 0 15Z' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='m21 21-4.35-4.35M10.5 18a7.5 7.5 0 1 1 0-15 7.5 7.5 0 0 1 0 15Z' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round'/%3E%3C/svg%3E") center / contain no-repeat;
}
.new-chat-round { width: 36px; height: 36px; min-width: 36px; border-radius: 999px; border: 1px solid rgba(0,0,0,.25); background: #fff; color: #1f2328; display: inline-flex; align-items: center; justify-content: center; padding: 0; }
.new-chat-round:hover { background: #e9edf2; }
.new-chat-round .icon { width: 16px; height: 16px; flex-basis: 16px; }
.side-list { flex: 1; min-height: 0; overflow: auto; padding: 0 10px 14px; }
.side-section { margin: 16px 0 10px; color: #6f7782; font-size: 13px; font-weight: 600; text-align: center; }
.side-row { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) 28px; align-items: stretch; min-height: 44px; margin: 4px 0; border-radius: 6px; background: rgba(15, 23, 42, .05); overflow: visible; }
.side-row.active { background: color-mix(in srgb, var(--accent) 14%, transparent); }
.side-main { min-width: 0; border: 0; background: transparent; padding: 7px 8px 6px 10px; text-align: left; color: inherit; border-radius: 6px 0 0 6px; overflow: hidden; }
.side-title { display: block; height: 16px; line-height: 16px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; font-weight: 800; color: #1f2328; }
.side-meta { display: block; height: 14px; line-height: 14px; margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 11px; color: #7a828c; }
.side-menu-btn { width: 28px; min-width: 28px; border: 0; border-radius: 0 6px 6px 0; background: transparent; color: #6b7280; font-size: 18px; line-height: 1; }
.side-menu-btn:hover { background: rgba(15, 23, 42, .08); color: #1f2328; }
.side-menu { position: absolute; right: 6px; top: 36px; z-index: 50; min-width: 132px; padding: 6px; border: 1px solid rgba(0,0,0,.08); border-radius: 8px; background: #fff; box-shadow: var(--shadow); }
.side-menu[hidden] { display: none; }
.side-menu button, .side-menu a { display: flex; align-items: center; width: 100%; min-height: 30px; border: 0; border-radius: 6px; padding: 0 8px; background: transparent; color: #1f2328; font-size: 13px; text-decoration: none; text-align: left; }
.side-menu button:hover, .side-menu a:hover { background: #f1f5f9; }
.danger { color: var(--danger) !important; }
.main { display: grid; grid-template-rows: 44px minmax(0, 1fr); min-width: 0; min-height: 0; height: 100%; background: #fff; }
.topbar { position: relative; display: flex; align-items: center; gap: 8px; padding: 0 14px; background: #fff; border-bottom: 0; }
.pill { display: inline-flex; align-items: center; gap: 2px; height: 30px; border-radius: 999px; border: 1px solid rgba(15,23,42,.12); background: #f3f4f6; padding: 2px; }
.pill button { height: 24px; border: 0; border-radius: 999px; background: #f3f4f6; padding: 0 10px; font-size: 12px; font-weight: 700; color: #48515c; }
.pill button.active { background: var(--accent); color: #fff; box-shadow: 0 1px 4px rgba(21,95,150,.24); }
.quality-pill { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); z-index: 4; }
.quality-pill.is-hidden { display: none; }
.top-spacer { flex: 1; }
.refresh-btn { height: 30px; border-radius: 999px; border: 1px solid rgba(15,23,42,.12); background: #f3f4f6; padding: 0 12px 0 10px; color: #1f2328; font-size: 12px; font-weight: 700; display: inline-flex; align-items: center; gap: 6px; }
.refresh-icon { width: 15px; height: 15px; display: block; stroke: currentColor; fill: none; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; flex: 0 0 15px; }
.workspace { position: relative; display: grid; grid-template-rows: minmax(0, 1fr) auto; min-height: 0; overflow: hidden; }
.messages { min-height: 0; overflow: auto; padding: 28px 0 18px; }
.content-width { width: min(calc(100% - 48px), 900px); margin-inline: auto; }
.welcome { position: absolute; left: 50%; top: 49%; transform: translate(-50%, -50%); text-align: center; pointer-events: none; }
.welcome .brand { display: inline-flex; align-items: center; gap: 12px; font-size: 38px; letter-spacing: 0; }
.welcome img { width: 32px; height: 32px; }
.welcome p { margin: 8px 0 0; color: #5d6168; font-size: 16px; }
.message { width: min(calc(100% - 48px), 900px); margin: 14px auto; display: flex; }
.message.user { justify-content: flex-end; }
.message.assistant { justify-content: flex-start; }
.message.pending-response { width: min(calc(100% - 48px), 900px); }
.message.pending-response .bubble { width: 100%; max-width: none; min-height: 86px; }
.message.has-visual-attachment { width: min(calc(100% - 48px), 900px); }
.message.user.has-visual-attachment .bubble { width: 100%; max-width: none; }
.message.user.has-visual-attachment .bubble::after { content: none; }
.bubble { position: relative; max-width: min(760px, 78%); padding: 12px 16px; border-radius: 4px; background: #e9e9e9; font-size: 16px; line-height: 1.45; white-space: normal; word-break: break-word; }
.message.assistant .bubble { width: 100%; max-width: none; padding: 0; border-radius: 0; background: transparent; }
.message.user .bubble { background: #f3f4f6; }
.message.user .bubble::after { content: ""; position: absolute; right: -12px; bottom: 0; border: 12px solid transparent; border-bottom-color: #f3f4f6; }
.visual-attachment { width: 100%; margin: 0; }
.visual-attachment img { display: block; width: 100%; max-height: min(560px, 62vh); object-fit: contain; border-radius: 6px; background: #111827; }
.visual-attachment figcaption { margin-top: 8px; color: #737b86; font-size: 12px; line-height: 1.35; }
.author { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 10px; padding-bottom: 8px; border-bottom: 1px solid rgba(15,23,42,.10); font-size: 14px; font-weight: 800; }
.author-left { display: inline-flex; align-items: center; gap: 8px; min-width: 0; }
.pending-response .author-left { align-items: center; }
.time { color: #8a929d; font-size: 12px; font-weight: 400; }
.response-meta {
  display: inline-grid;
  grid-template-columns: auto 12px 5ch;
  align-items: center;
  column-gap: 10px;
  flex: 0 0 auto;
  margin-left: auto;
  color: #8a929d;
  font-size: 12px;
  font-weight: 400;
  font-variant-numeric: tabular-nums;
  line-height: 1;
  white-space: nowrap;
}
.response-meta-plain {
  grid-template-columns: 5ch;
}
.response-meta-label {
  min-width: 0;
  overflow: hidden;
  color: #7f8894;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.response-meta-separator {
  color: #aeb5bd;
  font-size: 14px;
  line-height: 1;
  justify-self: center;
  text-align: center;
}
.response-meta-separator-placeholder {
  opacity: 0;
}
.response-meta-value {
  width: 5ch;
  min-width: 5ch;
  justify-self: start;
  text-align: left;
}
.response-meta .time {
  color: inherit;
  font: inherit;
}
.response-meta-spinner-slot {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
}
.response-meta .spinner,
.progress-author .response-meta .spinner {
  width: 12px;
  height: 12px;
  flex: 0 0 12px;
  margin-left: 0;
}
.assistant-name { color: #1f2328; }
.assistant-name::before { content: none; display: none; }
.assistant-name .author-left::before { content: ""; display: inline-block; width: 14px; height: 14px; background: url("/assets/globus-icon.png") center/contain no-repeat; flex: 0 0 14px; transform: translateY(0); }
.thinking-text { margin-top: 18px; color: #8a929d; font-size: 14px; line-height: 1.45; font-weight: 400; }
.actions { display: flex; gap: 14px; justify-content: flex-end; margin-top: 8px; color: #1f2328; }
.actions button { border: 0; background: transparent; padding: 0; color: inherit; }
.md-content { display: flow-root; }
.md-content h1, .md-content h2, .md-content h3 { margin: 18px 0 10px; line-height: 1.2; font-weight: 800; color: #1f2328; }
.md-content h1:first-child, .md-content h2:first-child, .md-content h3:first-child { margin-top: 0; }
.md-content h1 { font-size: 28px; }
.md-content h2 { font-size: 22px; }
.md-content h3 { font-size: 18px; }
.md-content p { margin: 0 0 12px; }
.md-content hr { height: 0; margin: 20px 0; border: 0; border-top: 1px solid rgba(15,23,42,.18); }
.md-content p:last-child { margin-bottom: 0; }
.md-content ul, .md-content ol { margin: 6px 0 12px; padding-left: 22px; }
.md-content li { margin: 4px 0; }
.md-content a { color: var(--accent); font-weight: 700; text-decoration: underline; text-underline-offset: 2px; }
.md-content code { border-radius: 4px; background: rgba(15, 23, 42, .08); padding: 1px 4px; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .92em; }
.md-content .table-wrap { width: 100%; max-width: 100%; margin: 10px 0 14px; overflow-x: auto; border: 1px solid rgba(15,23,42,.12); border-radius: 8px; background: #fff; }
.md-content table { width: 100%; border-collapse: collapse; min-width: 520px; font-size: 14px; line-height: 1.35; }
.md-content th, .md-content td { padding: 9px 11px; border-bottom: 1px solid rgba(15,23,42,.10); border-right: 1px solid rgba(15,23,42,.08); text-align: left; vertical-align: top; }
.md-content th:first-child, .md-content td:first-child { min-width: 64px; }
.md-content th:last-child, .md-content td:last-child { border-right: 0; }
.md-content tr:last-child td { border-bottom: 0; }
.md-content th { background: #eef4fb; color: #172033; font-weight: 800; }
.md-content tbody tr:nth-child(even) td { background: #f8fafc; }
.transport-map-embed { width: 100%; height: min(460px, 52vh); min-height: 340px; margin: 0 0 20px; border: 1px solid rgba(15,23,42,.14); border-radius: 0; background: #fff; overflow: hidden; }
.transport-map-embed iframe { display: block; width: 100%; height: 100%; border: 0; background: #fff; }
/* Crop the provider toolbar while retaining the entire map viewport. */
.transport-map-embed iframe[src^="https://www.vesselfinder.com/aismap"] { height: calc(100% + 20px); transform: translateY(-20px); }
.progress-card { position: relative; width: min(calc(100% - 48px), 900px); margin: 30px auto 14px; padding: 4px 0 8px; border: 0; border-radius: 0; background: transparent; box-shadow: none; color: #1f2328; font-size: 16px; line-height: 1.45; }
.research-card, .refresh-card { position: relative; width: min(calc(100% - 48px), 900px); margin: 16px auto; padding: 16px 76px; border-radius: 8px; background: var(--card); box-shadow: inset 3px 0 0 var(--accent); font-size: 16px; line-height: 1.45; }
.progress-author { margin-bottom: 18px; }
.progress-author .spinner { width: 12px; height: 12px; margin-left: auto; flex: 0 0 12px; }
.progress-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin: 0 0 8px; color: #1f2328; font-size: 16px; font-weight: 400; }
.progress-title { color: inherit; font: inherit; }
.progress-actions { display: inline-flex; align-items: center; justify-content: flex-end; gap: 7px; flex: 0 0 auto; }
.progress-action { display: inline-grid; place-items: center; width: 28px; height: 28px; padding: 0; border: 0; border-radius: 999px; background: #eef1f5; color: #5d6672; cursor: pointer; transition: background-color .16s ease, color .16s ease; }
.progress-action:hover { background: var(--accent); color: #fff; }
.progress-action:focus-visible { outline: 2px solid rgba(21,95,150,.28); outline-offset: 2px; }
.progress-action .icon { width: 15px; height: 15px; stroke: currentColor; stroke-width: 2.2; }
.progress-action svg path[fill="currentColor"] { stroke: none; }
.progress-terminal { margin: 8px 0; font-size: 14px; line-height: 1.45; overflow-wrap: anywhere; }
.progress-terminal strong { display: block; font-weight: 600; }
.progress-card[data-progress-status="failed"] .progress-terminal { color: #b42318; }
.progress-card[data-progress-status="failed"] .bar span { background: #b42318; }
.progress-timer { position: static; margin-left: auto; color: #7a828c; font-size: 12px; line-height: 1.2; font-weight: 400; font-variant-numeric: tabular-nums; }
.research-card h3, .refresh-card h3 { margin: 0 0 6px; color: var(--accent); font-size: 16px; }
.progress-main { color: #1f2328; font-size: 16px; line-height: 1.45; }
.card-close { position: absolute; right: 16px; top: 16px; width: 18px; height: 18px; border: 0; background: transparent; color: #8a929d; font-size: 18px; line-height: 18px; display: inline-flex; align-items: center; justify-content: center; padding: 0; }
.card-time { position: absolute; right: 42px; top: 17px; color: #8a929d; font-size: 12px; line-height: 18px; }
.progress-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 24px; margin-top: 14px; color: #69717c; font-size: 12px; font-weight: 700; }
.progress-row span:first-child { flex: 1 1 auto; min-width: 0; }
.progress-row span:last-child { flex: 0 0 auto; white-space: nowrap; text-align: right; }
.bar { height: 6px; margin-top: 6px; border-radius: 999px; background: #d7e5f0; overflow: hidden; }
.bar span { display: block; height: 100%; width: 0; border-radius: inherit; background: var(--accent); transition: width .2s ease; }
.transport-progress-stages { display:flex; flex-wrap:wrap; gap:8px 24px; padding:0; margin:12px 0; list-style-position:inside; color:#737d89; font-size:13px; }
.transport-progress-stages .active { color:var(--accent); font-weight:600; }
.transport-progress-stages .done { color:#384956; }
.transport-progress-row { display:flex; align-items:center; gap:16px; margin:0 0 12px; }
.transport-progress-row .transport-progress-stages { flex:1; min-width:0; margin:0; }
.transport-progress-row .progress-actions { align-self:flex-start; }
.transport-progress-running span { background-image:linear-gradient(100deg,transparent 25%,rgba(255,255,255,.5) 50%,transparent 75%); background-size:120px 100%; animation:transport-progress-pulse 1.4s linear infinite; }
@keyframes transport-progress-pulse { from { background-position:-120px 0; } to { background-position:120px 0; } }
@media (prefers-reduced-motion:reduce) { .transport-progress-running span { animation:none; } }
.progress-card .progress-foot { justify-content: space-between; }
.progress-foot { display: flex; align-items: baseline; justify-content: space-between; gap: 24px; color: #7b838e; font-size: 12px; margin-top: 5px; }
.progress-foot span:last-child { white-space: nowrap; text-align: right; }
.pause-btn { position: absolute; right: 22px; top: 50%; transform: translateY(-50%); width: 36px; height: 36px; border: 0; border-radius: 999px; background: var(--accent); color: #fff; display: inline-flex; align-items: center; justify-content: center; box-shadow: 0 3px 10px rgba(21,95,150,.28); }
.pause-btn:hover { background: var(--accent-2); }
.pause-btn .icon { width: 18px; height: 18px; stroke-width: 2.8; }
.research-card { padding: 0; overflow: hidden; border: 1px solid rgba(15,23,42,.1); box-shadow: none; background: #fff; }
.research-card.report-card { border: 0; background: transparent; overflow: visible; }
.research-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 18px 24px; border-bottom: 1px solid var(--line); }
.research-head-compact { justify-content: flex-end; padding: 10px 24px; min-height: 42px; }
.research-head h2 { margin: 0; color: var(--accent); font-size: 22px; line-height: 1.2; }
.research-body { max-height: 560px; overflow: auto; background: #f8fbfe; }
.research-body iframe { display: block; width: 100%; height: 560px; border: 0; background: #fff; }
.research-summary { padding: 18px 24px 6px; background: #fff; }
.report-card .research-summary { padding: 18px 0 6px; background: transparent; }
.research-summary .md-content { max-width: none; font-size: 16px; line-height: 1.5; }
.research-summary .md-content h1 { font-size: 26px; color: var(--accent); }
.research-summary .md-content h2 { font-size: 21px; color: var(--accent); }
.research-summary .md-content h3 { font-size: 17px; color: #1f2328; }
.research-result-timeline {
  width: min(calc(100% - 48px), 940px);
  margin-left: auto;
  margin-right: auto;
  border: 0 !important;
  border-radius: 0;
  outline: 0;
  background: transparent;
  box-shadow: none;
  overflow: visible;
}
.timeline-head { padding-bottom: 16px; }
.timeline-native { padding: 18px 24px 24px; background: #fff; }
.timeline-native-loading { color: #7a828c; }
.timeline-native-head { margin: 0 0 18px; max-width: 74ch; }
.timeline-native-head h2 { margin: 0 0 8px; color: #155f96; font-size: 22px; line-height: 1.22; }
.timeline-native-head p { margin: 0; color: #4b5563; font-size: 15px; line-height: 1.55; }
.timeline-event-list { position: relative; display: grid; gap: 0; margin: 0; padding: 0; list-style: none; }
.timeline-event-list::before { content: ""; position: absolute; left: 118px; top: 8px; bottom: 8px; width: 2px; background: #d7e5f0; }
.timeline-event { position: relative; display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 34px; padding: 0 0 22px; }
.timeline-event:last-child { padding-bottom: 0; }
.timeline-event::before { content: ""; position: absolute; left: 113px; top: 5px; width: 12px; height: 12px; border-radius: 999px; background: var(--accent); box-shadow: 0 0 0 4px #fff; }
.timeline-event-date { color: #7a828c; font-size: 12px; line-height: 1.35; font-variant-numeric: tabular-nums; }
.timeline-event-body h3 { margin: 0 0 7px; color: #1f2328; font-size: 16px; line-height: 1.3; font-weight: 800; }
.timeline-event-body p { margin: 0; max-width: 74ch; color: #2d333b; font-size: 15px; line-height: 1.55; }
.timeline-event-sources { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 9px; }
.timeline-event-sources a { color: var(--accent); font-size: 12px; line-height: 1.2; font-weight: 700; text-decoration: underline; }
.research-result-graph { width: min(calc(100% - 48px), 900px); }
.research-result-graph .bubble { width: 100%; max-width: none; padding: 0; border: 0; background: transparent; box-shadow: none; }
.graph-visual-card { width: min(calc(100% - 48px), 900px); padding: 0; border-radius: 0; background: transparent; border: 0; }
.graph-card-head { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-bottom: 14px; }
.graph-card-head h2 { margin: 0 0 8px; color: var(--accent); font-size: 22px; line-height: 1.2; }
.graph-card-head p { display: none; }
.graph-card-head span { flex: 0 0 auto; color: #7a828c; font-size: 12px; line-height: 1.3; white-space: nowrap; }
.graph-view-body { width: 100%; height: min(760px, calc(100vh - 220px)); min-height: 620px; border: 0; background: #fff; overflow: hidden; }
.graph-view-body iframe { display: block; width: 100%; height: 100%; border: 0; background: #fff; }
.graph-workspace { display: block; min-height: 560px; }
.graph-canvas-wrap { position: relative; min-width: 0; min-height: 520px; border: 1px solid rgba(15,23,42,.12); background: #fff; overflow: hidden; }
.graph-canvas { display: block; width: 100%; height: 560px; background: #fff; cursor: grab; }
.graph-tools { position: absolute; top: 10px; left: 10px; z-index: 2; display: inline-flex; gap: 6px; }
.graph-tools button { height: 30px; border: 1px solid rgba(15,23,42,.12); border-radius: 7px; padding: 0 10px; background: rgba(248,250,252,.94); color: #1f2328; font-size: 12px; font-weight: 800; cursor: pointer; box-shadow: 0 4px 14px rgba(15,23,42,.08); }
.graph-tools button:hover, .graph-tools button.active { background: var(--accent); border-color: var(--accent); color: #fff; }
.graph-details { position: absolute; right: 14px; bottom: 14px; z-index: 3; display: none; width: min(360px, calc(100% - 28px)); max-height: 46%; border: 1px solid rgba(15,23,42,.14); background: rgba(255,255,255,.98); padding: 14px 16px; overflow: auto; color: #2d333b; font-size: 13px; line-height: 1.5; box-shadow: 0 12px 32px rgba(15,23,42,.14); }
.graph-details.glp-open { display: block; }
.graph-details strong { display: block; margin: 0 24px 8px 0; color: #1f2328; font-size: 16px; line-height: 1.25; }
.graph-details h4 { margin: 13px 0 5px; color: #1f2328; font-size: 12px; line-height: 1.3; font-weight: 800; }
.graph-details p { margin: 0 0 10px; }
.download-line { display: flex; gap: 14px; align-items: center; padding: 16px 24px; font-size: 16px; }
.download-line strong { margin-right: 4px; }
.download-line a { color: var(--accent); font-weight: 800; }
.report-download-line { padding: 16px 0; color: #1f2328; }
.report-download-line span { font-weight: 800; }
.report-download-line a { color: #1f2328; font-weight: 400; text-decoration-line: underline; text-decoration-style: dotted; text-underline-offset: 4px; }
.composer { position: relative; z-index: 5; width: min(calc(100% - 48px), 900px); margin: 0 auto 14px; display: grid; grid-template-columns: 40px minmax(0, 1fr) 40px; column-gap: 14px; align-items: center; justify-items: center; background: #fff; }
.tool-row, .send-row { display: flex; align-items: center; gap: 8px; height: 44px; }
.tool-launcher { position: relative; width: 40px; height: 44px; display: flex; align-items: center; justify-content: center; }
.tool-menu-btn { background: #fff; border-color: rgba(31,35,40,.42); box-shadow: 0 1px 3px rgba(15,23,42,.06); }
.tool-menu-btn.active { background: var(--accent); border-color: var(--accent); color: #fff; box-shadow: 0 2px 8px rgba(21,95,150,.25); }
.tool-menu-btn.active img { filter: brightness(0) invert(1); opacity: 1; }
.tool-popover { position: absolute; left: 0; bottom: calc(100% + 10px); transform: translateY(8px); display: inline-flex; flex-direction: column; align-items: stretch; gap: 3px; width: 224px; padding: 8px; border: 1px solid rgba(31,35,40,.14); border-radius: 8px; background: #fff; box-shadow: 0 14px 36px rgba(15,23,42,.16); opacity: 0; visibility: hidden; pointer-events: none; transition: opacity .16s ease, transform .16s ease, visibility .16s ease; }
.tool-launcher.open .tool-popover { opacity: 1; visibility: visible; pointer-events: auto; transform: translateY(0); }
.tool-popover .tool-btn { position: relative; width: 100%; height: 34px; min-width: 0; min-height: 34px; justify-content: flex-start; gap: 9px; border: 0; border-radius: 6px; background: #fff; color: #303741; padding: 0 10px; box-shadow: none; }
.tool-popover .tool-btn:hover { background: #f3f5f7; }
.tool-popover .tool-btn.active { background: var(--accent); color: #fff; }
.tool-popover .tool-btn::after { content: none; }
.tool-popover .tool-btn span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; font-weight: 700; line-height: 1; }
.tool-btn, .mic-btn, .send-btn { position: relative; width: 36px; height: 36px; min-width: 36px; min-height: 36px; border-radius: 999px; border: 1px solid rgba(15,23,42,.08); background: #f2f3f5; color: #535b65; display: inline-flex; align-items: center; justify-content: center; padding: 0; line-height: 1; vertical-align: middle; overflow: hidden; }
.tool-btn.active, .send-btn { background: var(--accent); color: #fff; box-shadow: 0 2px 8px rgba(21,95,150,.25); }
.tool-btn img { position: relative; z-index: 1; width: 21px; height: 21px; display: block; flex: 0 0 21px; object-fit: contain; opacity: .68; filter: none; margin: 0; transform: none; pointer-events: none; }
.tool-btn[data-tool="graph"] img { width: 18px; height: 18px; }
.tool-btn[data-tool="timeline"] img { width: 23px; height: 23px; }
.tool-btn[data-tool="deep"] img { width: 21px; height: 21px; }
.tool-btn:not([data-tool]) img { width: 22px; height: 22px; flex-basis: 22px; }
.tool-btn.active img { filter: brightness(0) invert(1); opacity: 1; }
.input-wrap { position: relative; width: 100%; height: 44px; border-radius: 999px; border: 1px solid rgba(15,23,42,.10); background: #f6f6f6; display: flex; align-items: center; overflow: hidden; }
.input { width: 100%; height: 42px; resize: none; border: 0; outline: 0; background: transparent; padding: 11px 56px 11px 18px; font-size: 16px; line-height: 20px; color: #1f2328; overflow: hidden; }
.input-wrap.has-visual-pending .input { padding-left: 238px; }
.input-wrap.has-document-tool .input { flex: 1; min-width: 0; width: 0; padding-left: 10px; }
.input-wrap .document-attach-btn { flex: 0 0 34px; width: 34px; height: 34px; margin-left: 5px; border: 0; background: transparent; box-shadow: none; }
.document-pending { display: flex; align-items: center; gap: 4px; min-width: 0; max-width: 35%; padding: 3px 6px; border-radius: 12px; background: #e9edf2; font-size: 12px; }
.document-pending > span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.document-pending > button { flex: 0 0 auto; border: 0; background: transparent; cursor: pointer; }
.input-wrap.recording .input,
.input-wrap.transcribing .input { color: transparent; caret-color: transparent; }
.input-wrap.recording .input::placeholder,
.input-wrap.transcribing .input::placeholder { color: transparent; }
.voice-inline { position: absolute; inset: 0 52px 0 0; z-index: 2; display: grid; grid-template-columns: minmax(0, 1fr) 46px; align-items: center; gap: 12px; padding: 0 0 0 18px; pointer-events: none; color: #6f7378; }
.voice-wave-canvas { display: block; width: 100%; height: 34px; min-width: 0; opacity: .96; }
.voice-time { min-width: 42px; text-align: right; color: #5e6670; font-size: 12px; font-variant-numeric: tabular-nums; }
.input-wrap.transcribing .voice-inline { display: flex; justify-content: flex-end; gap: 8px; }
.voice-transcribing { color: #5e6670; font-size: 13px; font-weight: 700; }
.send-row { width: 40px; justify-content: center; }
.input-wrap .mic-btn { position: absolute; right: 4px; top: 50%; z-index: 3; transform: translateY(-50%); background: transparent; border-color: transparent; box-shadow: none; color: #606873; }
.input-wrap .mic-btn:hover { background: #eceff3; border-color: rgba(15,23,42,.08); }
.visual-pending-attachment { position: absolute; left: 6px; top: 50%; z-index: 4; transform: translateY(-50%); display: grid; grid-template-columns: 28px minmax(0, 1fr) 24px; align-items: center; gap: 7px; width: min(224px, calc(100% - 72px)); height: 34px; border-radius: 999px; background: #e9edf2; color: #303741; padding: 3px 4px 3px 3px; }
.visual-pending-attachment img { width: 28px; height: 28px; border-radius: 999px; object-fit: cover; background: #111827; }
.visual-pending-attachment span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; font-weight: 700; line-height: 1; }
.visual-pending-attachment button { width: 24px; height: 24px; min-width: 24px; border: 0; border-radius: 999px; background: transparent; color: #68717d; display: inline-flex; align-items: center; justify-content: center; padding: 0; font-size: 17px; line-height: 1; }
.visual-pending-attachment button:hover { background: #d8dee6; color: #1f2328; }
.mic-btn.recording { width: 36px; height: 36px; min-width: 36px; min-height: 36px; border-color: #667085; background: #f2f3f5; color: var(--accent); box-shadow: 0 1px 5px rgba(15,23,42,.18); }
.input-wrap .mic-btn.recording { background: #f2f3f5; border-color: #667085; color: var(--accent); box-shadow: 0 1px 5px rgba(15,23,42,.18); }
.mic-btn.transcribing { opacity: .72; cursor: default; }
.icon { width: 18px; height: 18px; display: block; stroke: currentColor; fill: none; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; flex: 0 0 18px; }
.tool-btn .icon { width: 19px; height: 19px; }
.tool-btn > .icon,
.tool-menu-btn > .icon {
  position: relative;
  inset: auto;
  margin: 0;
  transform: none;
  flex: 0 0 19px;
  color: inherit;
  stroke: currentColor;
  pointer-events: none;
}
.tool-btn.active > .icon,
.tool-menu-btn.active > .icon {
  color: #fff;
  stroke: #fff;
  opacity: 1;
}
.tool-popover .tool-btn > .icon {
  width: 18px;
  height: 18px;
  flex-basis: 18px;
}
.send-btn .icon { width: 18px; height: 18px; stroke-width: 2.3; }
.mic-btn .icon { width: 17px; height: 17px; }
.mic-btn.recording .icon { width: 22px; height: 22px; flex: 0 0 22px; }
.send-btn:disabled { opacity: .5; cursor: default; }
.confirm-backdrop { position: fixed; inset: 0; z-index: 1000; display: grid; place-items: center; background: rgba(15, 23, 42, .24); }
.confirm-card { width: min(390px, calc(100vw - 32px)); border: 1px solid rgba(15,23,42,.12); border-radius: 10px; background: #fff; box-shadow: 0 18px 54px rgba(15,23,42,.18); padding: 18px 18px 16px; }
.confirm-brand { display: flex; align-items: center; gap: 8px; width: 100%; padding-bottom: 12px; border-bottom: 1px solid rgba(15,23,42,.12); font-size: 15px; line-height: 1; color: #1f2328; }
.confirm-brand img { width: 18px; height: 18px; }
.confirm-brand strong { font-weight: 800; }
.confirm-message { margin: 16px 0 22px; font-size: 14px; line-height: 1.45; color: #1f2328; }
.rename-card { padding-top: 18px; }
.rename-input { width: 100%; height: 38px; margin: 18px 0 18px; border: 1px solid rgba(15,23,42,.18); border-radius: 9px; padding: 0 12px; background: #fff; color: #1f2328; font-size: 14px; outline: none; }
.rename-input:focus { border-color: #155f96; box-shadow: 0 0 0 3px rgba(21,95,150,.14); }
.confirm-actions { display: flex; justify-content: flex-end; gap: 8px; }
.confirm-actions button { height: 32px; border: 0; border-radius: 8px; padding: 0 16px; font-size: 13px; font-weight: 800; }
.confirm-cancel { background: #f1f3f5; color: #1f2328; }
.confirm-ok { background: #155f96; color: #fff; }
.notice-backdrop { position: fixed; inset: 0; z-index: 1100; display: grid; place-items: center; background: rgba(15,23,42,.42); }
.notice-card { width: min(390px, calc(100vw - 32px)); border: 1px solid rgba(15,23,42,.14); border-radius: 8px; background: #fff; box-shadow: 0 18px 54px rgba(15,23,42,.22); padding: 16px 16px 15px; }
.notice-brand { display: flex; align-items: center; gap: 8px; width: 100%; padding-bottom: 12px; border-bottom: 1px solid rgba(15,23,42,.12); color: #1f2328; font-size: 15px; font-weight: 800; }
.notice-brand img { width: 18px; height: 18px; display: block; }
.notice-message { margin: 16px 0 18px; color: #1f2328; font-size: 14px; line-height: 1.45; }
.notice-actions { display: flex; justify-content: flex-end; }
.notice-actions button { height: 32px; border: 0; border-radius: 8px; padding: 0 17px; background: #0b66f0; color: #fff; font-size: 13px; font-weight: 800; }
.glp-graph-card { width: min(1120px, calc(100% - 56px)); margin: 14px auto; border: 1px solid #d7dce2; background: #f3f6fa; padding: 18px 22px 22px; color: #1f2328; }
.glp-graph-card-header { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-bottom: 14px; }
.glp-graph-card-title { display: block; margin: 0; font-size: 22px; line-height: 1.2; font-weight: 800; color: #155f96; }
.glp-graph-card-summary { display: none; }
.glp-graph-card-meta { flex: 0 0 auto; color: #7a828c; font-size: 12px; line-height: 1.3; white-space: nowrap; }
.glp-graph-view-body { width: 100%; height: min(760px, calc(100vh - 220px)); min-height: 620px; border: 1px solid rgba(15,23,42,.12); background: #fff; overflow: hidden; }
.glp-graph-view-body iframe { display: block; width: 100%; height: 100%; border: 0; background: #fff; }
.glp-graph-workspace { display: block; min-height: 560px; }
.glp-graph-canvas-wrap { position: relative; min-width: 0; min-height: 520px; border: 1px solid rgba(15,23,42,.12); background: #fff; overflow: hidden; }
.glp-graph-canvas { display: block; width: 100%; height: 560px; background: #fff; cursor: grab; }
.glp-graph-tools { position: absolute; top: 10px; left: 10px; z-index: 2; display: inline-flex; gap: 6px; }
.glp-graph-tools button { height: 30px; border: 1px solid rgba(15,23,42,.12); border-radius: 7px; padding: 0 10px; background: rgba(248,250,252,.94); color: #1f2328; font-size: 12px; font-weight: 800; cursor: pointer; box-shadow: 0 4px 14px rgba(15,23,42,.08); }
.glp-graph-tools button:hover,
.glp-graph-tools button.glp-active { background: #155f96; border-color: #155f96; color: #fff; }
.glp-graph-details { position: absolute; right: 14px; bottom: 14px; z-index: 3; display: none; width: min(360px, calc(100% - 28px)); max-height: 46%; border: 1px solid rgba(15,23,42,.14); background: rgba(255,255,255,.98); padding: 14px 16px; overflow: auto; color: #2d333b; font-size: 13px; line-height: 1.5; box-shadow: 0 12px 32px rgba(15,23,42,.14); }
.glp-graph-details.glp-open { display: block; }
.glp-graph-details strong { display: block; margin: 0 24px 8px 0; color: #1f2328; font-size: 16px; line-height: 1.25; }
.glp-graph-details h4 { margin: 13px 0 5px; color: #1f2328; font-size: 12px; line-height: 1.3; font-weight: 800; }
.glp-graph-details p { margin: 0 0 10px; }
.glp-graph-details-close { position: absolute; top: 8px; right: 8px; display: inline-grid; place-items: center; width: 22px; height: 22px; border: 0; background: transparent; color: #7a828c; cursor: pointer; font-size: 18px; line-height: 1; }
.glp-graph-card .glp-report-body { display: block; font-size: 15px; line-height: 1.55; }
.graph-modal-backdrop { position: fixed; inset: 0; z-index: 1200; display: grid; place-items: center; padding: 28px; background: rgba(15, 23, 42, .54); }
.graph-modal { position: relative; width: min(1480px, calc(100vw - 56px)); height: min(920px, calc(100vh - 56px)); overflow: hidden; border-radius: 12px; background: #fff; box-shadow: 0 24px 72px rgba(15, 23, 42, .28); }
.graph-modal iframe { display: block; width: 100%; height: 100%; border: 0; background: #fff; }
.graph-modal-close { position: absolute; right: 14px; top: 12px; z-index: 2; width: 34px; height: 34px; border: 1px solid rgba(15,23,42,.12); border-radius: 8px; background: rgba(248,250,252,.96); color: #172033; font-size: 24px; line-height: 1; }
.graph-modal-close:hover { background: #eef4fb; }
.typing-state { min-height: 22px; display: flex; align-items: center; }
.spinner { display: inline-block; width: 12px; height: 12px; border: 2px solid #c6d9e8; border-top-color: var(--accent); border-radius: 50%; animation: spin .8s linear infinite; vertical-align: -1px; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (max-width: 900px) {
  .app-shell { grid-template-columns: 220px minmax(0, 1fr); }
  .composer { grid-template-columns: 40px minmax(0, 1fr) 40px; }
  .tool-btn { width: 34px; height: 34px; }
}
.transport-data-credit { color: #687585; font-size: 12px; line-height: 1.5; margin: 12px 0; }

.progress-detail { margin: 8px 0; color: #4d5966; font-size: 14px; line-height: 1.45; overflow-wrap: anywhere; }
