:root {
  color-scheme: light;
  --ink: #232a31;
  --muted: #606870;
  --blue: #365f89;
  --line: #dfE2e3;
  --paper: #fdfdfb;
  font-family: 'Manrope', sans-serif;
  color: var(--ink);
  background: #f7f7f4;
  font-synthesis: none;
}
* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; min-height: 100vh; background: radial-gradient(ellipse at 78% 0%, #edf1f3 0, transparent 52%), linear-gradient(140deg, #fcfcf9, #f5f5f2); }
button, textarea, input { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { color: inherit; cursor: pointer; border: 0; background: none; }
a { color: inherit; }
button:focus-visible, a:focus-visible, textarea:focus-visible { outline: 3px solid #6389b4; outline-offset: 5px; }
main#workspace:focus, aside#detail:focus { outline: none; }
button:disabled { cursor: default; opacity: .55; }
svg { width: 21px; height: 21px; flex: 0 0 21px; }
button svg, a svg { pointer-events: none; }
h1, h2, h3, p { margin: 0; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.skip-link { position: fixed; left: 20px; top: -80px; z-index: 20; background: white; padding: 12px; }
.skip-link:focus { top: 12px; }
.app-shell { max-width: 1600px; margin: 0 auto; }
.app-header { height: 92px; padding: 0 64px; display: flex; align-items: center; justify-content: space-between; }
.wordmark { font-size: 19px; font-weight: 700; letter-spacing: -.8px; }
.perspectives { color: var(--muted); font-size: 12px; text-decoration: none; padding: 12px 0 12px 12px; }
.perspectives:hover { color: var(--blue); text-decoration: underline; }
.workspace-layout { display: grid; grid-template-columns: minmax(0, 1fr); }
.workspace-layout.has-detail { grid-template-columns: minmax(0, 1fr) 450px; gap: 20px; padding-right: 40px; }
.workspace { width: 100%; max-width: 870px; padding: 47px 64px 100px; margin: 0 auto; min-width: 0; }
.has-detail .workspace { padding-left: 52px; padding-right: 42px; }
.breadcrumb { display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: 13px; min-height: 44px; margin-bottom: 29px; }
.breadcrumb button { display: inline-flex; align-items: center; gap: 7px; padding: 9px 0; color: var(--blue); }
.breadcrumb > svg { width: 14px; height: 14px; flex-basis: 14px; color: #939aa0; }
.breadcrumb .mobile-arrow { display: none; }
.matter-heading { margin-bottom: 58px; }
.matter-heading h1 { font-size: clamp(30px, 3vw, 43px); font-weight: 600; letter-spacing: -1.65px; line-height: 1.2; overflow-wrap: anywhere; }
.matter-heading p { margin-top: 12px; color: var(--muted); font-size: 14px; }
.finding { margin-bottom: 60px; }
.section-label { display: flex; align-items: center; gap: 9px; font-size: 13px; font-weight: 500; color: var(--muted); margin-bottom: 22px; }
.section-label svg { width: 19px; height: 19px; flex-basis: 19px; }
.finding h2 { max-width: 570px; font-size: 28px; line-height: 1.38; letter-spacing: -.75px; font-weight: 600; }
.finding .finding-body { max-width: 565px; font-size: 16px; line-height: 1.8; color: var(--muted); margin-top: 17px; }
.source-context { display: block; margin-top: 20px; color: var(--muted); font-size: 12px; line-height: 1.6; }
.primary { display: inline-flex; justify-content: center; align-items: center; gap: 12px; min-height: 46px; padding: 11px 19px; border-radius: 9px; background: var(--blue); color: white; font-size: 14px; font-weight: 600; }
.primary:hover { background: #294e74; }
.finding .primary { margin-top: 22px; }
.next-step { display: flex; gap: 15px; align-items: flex-start; margin-bottom: 29px; }
.next-step > svg { color: var(--muted); margin-top: 2px; }
.next-step h2 { font-size: 13px; font-weight: 600; }
.next-step p { font-size: 14px; line-height: 1.7; margin-top: 6px; color: var(--muted); max-width: 490px; }
.draft-row { display: flex; gap: 14px; align-items: center; width: 100%; padding: 23px 0; text-align: left; border-top: 1px solid var(--line); color: var(--blue); }
.draft-row > span { flex: 1; }
.draft-row strong { display: block; font-size: 14px; font-weight: 600; }
.draft-row small { display: block; color: var(--muted); font-size: 12px; margin-top: 5px; }
.draft-row:hover strong { text-decoration: underline; }
.detail { align-self: start; margin: 28px 0 40px; border: 1px solid #d9dfe2; border-radius: 15px; background: var(--paper); box-shadow: 0 10px 35px #23384b0a; overflow: hidden; min-width: 0; }
.detail-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 17px 22px; background: #f5f6f5; }
.detail-toolbar > span { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 12px; }
.detail-back { width: 36px; height: 36px; display: inline-flex; align-items: center; justify-content: center; border-radius: 6px; }
.detail-back:hover { background: #e9edee; }
.detail-back .mobile-label, .detail-back .mobile-icon { display: none; }
.detail-content { padding: 30px 30px 34px; }
.detail-path { font-size: 11px; color: var(--muted); margin-bottom: 13px; }
.detail h2 { font-size: 23px; font-weight: 600; letter-spacing: -.6px; overflow-wrap: anywhere; }
.source-position { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; font-size: 12px; color: var(--muted); margin-top: 12px; }
.document-excerpt { margin-top: 36px; font-size: 14px; line-height: 1.9; }
.document-excerpt p { margin-bottom: 22px; }
.document-excerpt .document-date { font-size: 12px; color: var(--muted); margin-bottom: 28px; }
.document-excerpt mark { color: var(--ink); background: #e8eef3; box-decoration-break: clone; -webkit-box-decoration-break: clone; padding: 3px 2px; }
.excerpt-footer { padding-top: 4px; color: var(--muted); font-size: 11px; }
.draft-label { display: block; font-size: 13px; font-weight: 500; margin-top: 28px; margin-bottom: 12px; }
textarea { display: block; resize: vertical; width: 100%; min-height: 340px; border: 1px solid #d2d9de; border-radius: 8px; padding: 15px; font-size: 14px; line-height: 1.75; background: white; color: var(--ink); }
.save-area { margin-top: 20px; }
.save-status { font-size: 12px; color: var(--muted); line-height: 1.7; margin-top: 12px; min-height: 40px; }
.root-heading { display: flex; gap: 15px; align-items: center; margin: 25px 0 39px; }
.root-heading svg { color: var(--blue); width: 29px; height: 29px; flex-basis: 29px; }
.root-heading h1 { font-size: 38px; font-weight: 600; letter-spacing: -1px; }
.matter-list { display: grid; }
.matter-item { width: 100%; text-align: left; display: flex; align-items: center; gap: 18px; padding: 27px 0; }
.matter-item + .matter-item { border-top: 1px solid var(--line); }
.matter-item > svg:first-child { color: var(--muted); }
.matter-item > span { flex: 1; }
.matter-item strong { font-size: 18px; font-weight: 500; display: block; letter-spacing: -.35px; }
.matter-item small { display: block; color: var(--muted); font-size: 12px; margin-top: 7px; }
.matter-item:hover strong { color: var(--blue); }
@media (max-width: 1100px) and (min-width: 761px) {
  .workspace-layout.has-detail { grid-template-columns: minmax(0, 1fr) 390px; padding-right: 24px; gap: 0; }
  .has-detail .workspace { padding: 40px 26px 80px; }
  .has-detail .matter-heading h1 { font-size: 30px; }
  .has-detail .finding h2 { font-size: 24px; }
  .detail-content { padding: 25px; }
}
@media (max-width: 760px) {
  .app-header { height: 70px; padding: 0 24px; }
  .wordmark { font-size: 18px; }
  .workspace { padding: 13px 25px 55px; }
  .breadcrumb { margin-bottom: 23px; font-size: 12px; gap: 9px; }
  .breadcrumb .mobile-arrow { display: block; width: 18px; height: 18px; flex-basis: 18px; }
  .breadcrumb > svg { display: none; }
  .breadcrumb [aria-current] { margin-left: auto; }
  .matter-heading { margin-bottom: 41px; }
  .matter-heading h1 { font-size: 32px; letter-spacing: -1.25px; line-height: 1.22; }
  .matter-heading p { font-size: 13px; margin-top: 11px; }
  .finding { margin-bottom: 39px; }
  .section-label { margin-bottom: 18px; font-size: 12px; }
  .finding h2 { font-size: 25px; line-height: 1.4; letter-spacing: -.7px; }
  .finding .finding-body { font-size: 15px; line-height: 1.78; margin-top: 15px; }
  .source-context { font-size: 11px; margin-top: 18px; }
  .finding .primary { width: 100%; margin-top: 20px; min-height: 48px; }
  .next-step { gap: 12px; margin-bottom: 22px; }
  .next-step p { font-size: 13px; }
  .draft-row { padding: 22px 0; }
  .workspace-layout.has-detail { display: block; padding: 0; }
  body.detail-open .app-header, body.detail-open .workspace { display: none; }
  .detail { margin: 0; min-height: 100dvh; border: 0; border-radius: 0; box-shadow: none; background: linear-gradient(155deg, #fcfcfa, #f7f8f7); }
  .detail-toolbar { padding: 13px 20px; min-height: 70px; background: transparent; flex-direction: row-reverse; }
  .detail-toolbar > span { font-size: 11px; }
  .detail-back { width: auto; min-height: 44px; gap: 6px; padding: 0 4px; color: var(--blue); font-size: 13px; }
  .detail-back .mobile-label, .detail-back .mobile-icon { display: block; }
  .detail-back .desktop-icon { display: none; }
  .detail-content { padding: 17px 25px 45px; }
  .detail-path { margin-bottom: 15px; }
  .detail h2 { font-size: 29px; }
  .source-position { font-size: 12px; margin-top: 13px; }
  .document-excerpt { margin-top: 42px; font-size: 15px; line-height: 1.9; }
  .document-excerpt p { margin-bottom: 25px; }
  .draft-label { margin-top: 28px; }
  textarea { min-height: 350px; font-size: 16px; }
  .save-area { padding-bottom: max(30px, env(safe-area-inset-bottom)); }
  .save-area .primary { width: 100%; }
  .root-heading { margin-top: 33px; margin-bottom: 25px; }
  .root-heading h1 { font-size: 32px; }
  .matter-list { gap: 12px; }
  .matter-item { padding: 22px 17px; gap: 12px; background: #ffffffb3; border: 1px solid var(--line); border-radius: 12px; }
  .matter-item + .matter-item { border-top: 1px solid var(--line); }
  .matter-item strong { font-size: 16px; }
}
