/* 四阶段共用导航及庭审工作区 */
:root { --navy:#0f172a; --navy-2:#1e293b; --bg:#f4f6f9; --gold:#eab04e; --accent:#334155; }
.workflow { flex:none; display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:6px; padding:8px clamp(10px,3vw,48px); background:#10192b; }
.workflow a { display:flex; align-items:center; gap:10px; padding:7px 12px; border:1px solid #344155; border-radius:9px; color:#dce4ef; text-decoration:none; font:600 14px/1.25 Inter,"Microsoft YaHei",sans-serif; }
.workflow a:hover,.workflow a:focus-visible { background:#26344b; }
.workflow a[aria-current] { background:#ffe1a1; color:#38280f; border-color:#f1bd61; }
.workflow b { font:600 14px monospace; opacity:.8; }
.workflow small { display:block; margin-top:3px; font-size:11px; font-weight:400; opacity:.8; }
.intake-view { display:flex; flex-direction:column; height:100dvh; }
.intake-view #app { flex:1; height:auto; min-height:0; }
.intake-brief,.draft-check { margin:12px; padding:12px; border:1px solid #dce2ea; border-radius:10px; background:#fbfcfd; }
summary { cursor:pointer; font-weight:650; color:#25344a; }
#intake-brief { max-height:22vh; overflow:auto; color:#46566c; font-size:13px; }
#intake-brief p { margin-top:6px; }
#structured-case:not(:empty) { border:1px solid #dce5ef; border-radius:10px; background:#f8fafc; padding:10px 12px; margin-bottom:12px; color:#34445a; font-size:12px; max-height:180px; overflow:auto; }
#structured-case summary { cursor:pointer; font-weight:700; }
#structured-case p { margin-top:6px; overflow-wrap:anywhere; }
#page-preview:not(:empty) { padding:12px; max-height:25vh; overflow:auto; border-top:1px solid #dde3ec; }
.draft-check textarea { display:block; width:100%; margin:12px 0; padding:10px; border:1px solid #ccd6e2; border-radius:6px; font:inherit; }
#draft-result { margin-top:8px; }
[hidden] { display:none!important; }
@media(min-width:1150px) {
 .intake-view.has-consultation #app { margin-right:clamp(320px,26vw,440px); }
 .intake-view.has-consultation #case-modal { inset:0 0 0 auto; width:clamp(320px,26vw,440px); z-index:1; background:white; border-left:1px solid #dbe2eb; }
 .intake-view .case-sheet { height:100%; border-radius:0; padding:22px; animation:none; }
 #case-close,#case-btn,#case-strip { display:none; }
}
@media(max-width:700px) {
 .workflow { gap:4px; padding:5px; }
 .workflow a { padding:8px 2px; justify-content:center; flex-wrap:wrap; gap:3px; font-size:11px; }
 .workflow b { font-size:10px; }
 .workflow small { display:none; }
}

.staff-auth { position:relative; font-size:12px; }
.staff-auth summary { color:#eed198; }
.staff-auth form { position:absolute; top:100%; right:0; z-index:12; width:210px; padding:14px; background:#fff; color:#233047; border:1px solid #cbd5e1; border-radius:8px; }
.staff-auth input { width:100%; margin:6px 0; padding:6px; }
@media(max-width:820px){ .staff-auth form { position:fixed; top:65px; right:8px; } }
.assistant-heading { display:flex; justify-content:space-between; gap:20px; align-items:end; margin:0 0 22px; }
.assistant-heading span { color:#9b6b27; font-size:12px; font-weight:700; }
.assistant-heading h2 { margin:3px 0; font-size:25px; color:#17263c; }
.assistant-heading p { margin:0; color:#64748b; }
.assistant-heading a { color:#315678; font-weight:600; text-decoration:none; white-space:nowrap; }
.lead-overview { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:12px; margin-bottom:18px; }
.lead-overview button { text-align:left; background:#fff; color:#17263c; border:1px solid #e2e8f0; padding:16px 18px; border-radius:10px; }
.lead-overview button:hover { border-color:#b99050; }
.lead-overview strong,.lead-overview span { display:block; }
.lead-overview strong { font-size:24px; line-height:1.2; }
.lead-overview span { color:#64748b; margin-top:5px; font-size:12px; }
.service-diagnostics { margin-top:24px; }
.service-diagnostics > summary { background:#fff; border:1px solid #e2e8f0; padding:14px; border-radius:8px; margin-bottom:12px; }
.intake-view #context-panel,.intake-view #provider-tag { display:none; }
.intake-view .hero-card { padding:clamp(18px,3vw,32px); background:linear-gradient(115deg,#102a48,#214e76); }
.intake-view .hero-kicker { padding:0; border:0; color:#f5cb7a; font-weight:650; }
.intake-view .hero-desc { color:#d2deeb; max-width:40em; font-size:14px; }
.intake-view #hero > * { max-width:880px; margin-inline:auto; }
.intake-view .msg.user { background:#234c72; color:#fff; }
.quick-grid button:hover { border-color:#8ca9c4; }
:where(button,summary,a,input,select,textarea):focus-visible { outline:3px solid #3781cb; outline-offset:2px; }
.intake-view .msg.assistant { max-width:85%; padding:16px 18px; border-radius:14px; border-color:#e0e6ed; line-height:1.75; }
.answer-heading { display:inline-block; margin-top:10px; color:#183858; font-weight:700; }
.answer-heading:first-child { margin-top:0; }
.citation-cards { border-color:#f0d7bd; background:#fffbf6; }
.citation-cards > strong { color:#9c4d36; }
.citation-card { border-top-color:#f0ded1; }
.citation-card summary { color:#995c25; font-weight:600; }
@media(max-width:899px) { .intake-view .msg.assistant { max-width:94%; padding:13px 14px; } }
#evidence-type-dialog { width:min(440px,calc(100% - 32px)); border:0; border-radius:16px; padding:24px; margin:auto; color:#172b45; box-shadow:0 18px 60px #0f172a55; }
#evidence-type-dialog::backdrop { background:#0f172a99; }
#evidence-type-dialog h3 { margin:0 0 8px; }
#evidence-type-dialog p { color:#64748b; margin:0 0 18px; font-size:13px; }
#evidence-type-dialog label { display:block; margin:12px 0; font-size:13px; font-weight:600; }
#evidence-type-dialog select,#evidence-type-dialog input { display:block; width:100%; padding:10px; margin-top:6px; border:1px solid #cbd5e1; border-radius:8px; background:white; font:inherit; }
.evidence-dialog-actions { display:flex; gap:10px; justify-content:flex-end; margin-top:20px; }
.evidence-dialog-actions button { border:0; border-radius:8px; padding:10px 16px; cursor:pointer; }
.evidence-dialog-actions button[type=submit] { background:#1857a4; color:white; }
.category-heading { margin:18px 0 0; font-size:14px; font-weight:700; color:#243b53; }
.category-help { margin:12px 0 4px; font-size:12px; color:#64748b; }
.quick-grid button[aria-pressed="true"] { border-color:#1857a4; background:#eef5ff; box-shadow:0 0 0 1px #1857a4; }
.more-categories { grid-column:1 / -1; }
.more-categories summary { color:#395b7d; cursor:pointer; padding:8px 2px; font-size:13px; }
.more-categories .quick-grid { margin-top:2px; }
@media (max-height:720px) and (max-width:899px) { .quick-grid button:nth-child(n+5) { display:flex; } }
@media(max-width:700px) {
 .assistant-heading { align-items:start; flex-direction:column; }
 .lead-overview { grid-template-columns:repeat(2,minmax(0,1fr)); }
 .intake-view .hero-card { padding:18px; }
}
