@font-face {
  font-family: "Inter Display";
  src: url("/static/brand/InterVariable.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
:root {
  color-scheme: light;
  --navy: #173a55;
  --ink: #08183f;
  --coral: #d84b50;
  --pale: #edf4fa;
  --border: #e0edf7;
  --muted: #526b7e;
  font-family: "Inter Display", Arial, sans-serif;
  font-optical-sizing: none;
  font-variation-settings: "opsz" 32;
  font-synthesis: none;
  color: var(--ink);
  background: #fff;
}
* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; font-size: 15px; line-height: 1.55; }
button, input { font: inherit; }
button { cursor: pointer; -webkit-tap-highlight-color: transparent; }
a { color: var(--navy); text-underline-offset: 3px; }
img { display: block; max-width: 100%; }
:focus-visible { outline: 3px solid var(--navy); outline-offset: 4px; }
.skip-link { position: fixed; top: 12px; left: 12px; z-index: 5; padding: 12px 18px; border-radius: 12px; background: var(--navy); color: #fff; transform: translateY(-160%); }
.skip-link:focus { transform: none; }
.topbar { border-bottom: 1px solid var(--border); background: #fff; padding: 12px 5%; }
.topbar-inner { max-width: 1240px; margin: auto; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.brand { display: block; flex-shrink: 0; }
.brand-frame { display: block; position: relative; width: 204px; aspect-ratio: 800 / 378; }
.brand-frame > img { width: 100%; height: auto; }
.brand-icon-replacement { position: absolute; top: 0; left: 33.75%; display: flex; align-items: flex-start; justify-content: center; width: 32.5%; height: 54.25%; background: #fff; }
.brand-icon-replacement img { width: 73%; height: auto; }
.source-state { display: flex; align-items: center; gap: 9px; min-height: 42px; padding: 10px 17px; border: 1px solid var(--border); border-radius: 24px; background: var(--pale); color: var(--navy); font-size: 12px; font-weight: 550; }
.dot { width: 8px; height: 8px; flex: 0 0 8px; border-radius: 50%; background: var(--coral); }
.connected .dot { background: var(--navy); }
main { max-width: 1364px; margin: auto; padding: 30px 5% 0; }
.intro { display: flex; align-items: center; gap: 27px; padding: 24px 32px; margin-bottom: 28px; border-radius: 28px; background: linear-gradient(120deg, #eff6fb, #e5f0f9); color: var(--navy); }
.module-icon { flex: 0 0 126px; width: 126px; height: 126px; border-radius: 50%; }
.intro-copy { min-width: 0; }
.eyebrow { color: var(--navy); font-size: 11px; font-weight: 650; letter-spacing: .13em; }
h1 { margin: 5px 0 8px; color: var(--ink); font-size: clamp(36px, 4vw, 48px); line-height: 1.12; font-weight: 700; letter-spacing: -.035em; }
.intro p { margin: 0; font-size: 16px; line-height: 1.55; letter-spacing: -.015em; }
.workspace { display: grid; grid-template-columns: 340px minmax(0, 1fr); gap: 22px; align-items: start; scroll-margin-top: 20px; }
.panel { min-width: 0; border: 1.7px solid var(--border); border-radius: 26px; background: #fff; box-shadow: 0 8px 25px rgb(23 58 85 / 4%); }
.import-panel { padding: 27px; }
.section-heading { display: flex; align-items: center; gap: 12px; }
h2 { margin: 0; color: var(--ink); font-size: 18px; line-height: 1.25; font-weight: 650; letter-spacing: -.025em; }
.step { display: inline-grid; place-items: center; flex-shrink: 0; width: 34px; height: 34px; border-radius: 50%; background: var(--pale); color: var(--navy); font-size: 12px; font-weight: 650; }
.drop-zone { display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 180px; margin-top: 23px; padding: 18px; border: 1.5px dashed #b9d5e9; border-radius: 18px; background: var(--pale); text-align: center; cursor: pointer; transition: background 150ms ease, border-color 150ms ease; }
.drop-zone svg { width: 42px; height: 46px; margin: 3px 0 14px; fill: none; stroke: var(--navy); stroke-width: 1.8; stroke-linejoin: round; }
.drop-zone strong { max-width: 245px; color: var(--navy); font-size: 14px; font-weight: 650; overflow-wrap: anywhere; }
.drop-zone > span { margin-top: 5px; color: var(--muted); font-size: 12px; }
.drop-zone.dragging { border-color: var(--navy); background: #e1edf7; }
.drop-zone:focus-within { outline: 3px solid var(--navy); outline-offset: 4px; }
.drop-zone input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.formats { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 13px; }
.formats span { padding: 3px 7px; border: 1px solid var(--border); border-radius: 6px; color: var(--muted); font-size: 10px; }
.hint { margin: 12px 0 22px; color: var(--muted); font-size: 11px; line-height: 1.65; }
.date-label { display: block; margin-bottom: 7px; color: var(--navy); font-size: 12px; font-weight: 550; }
input[type=date] { width: 100%; min-height: 44px; padding: 10px 12px; border: 1px solid #cddfea; border-radius: 12px; background: #fff; color: var(--navy); font-size: 14px; }
.primary { display: flex; align-items: center; justify-content: space-between; gap: 10px; width: 100%; min-height: 48px; margin-top: 18px; padding: 12px 16px; border: 0; border-radius: 24px; background: var(--navy); color: #fff; font-size: 13px; font-weight: 600; }
.primary > span { font-size: 22px; line-height: 1; }
.primary:hover { background: var(--ink); }
button:disabled { opacity: .55; cursor: wait; }
.sample-button { display: block; margin: 10px auto 15px; padding: 7px 10px; border: 0; background: none; color: var(--navy); font-size: 11px; text-decoration: underline; text-underline-offset: 3px; }
.preservation { display: flex; align-items: center; gap: 11px; padding-top: 18px; border-top: 1px solid var(--border); }
.preservation > span { color: var(--coral); font-size: 24px; }
.preservation p { margin: 0; color: var(--muted); font-size: 11px; }
.import-panel > .hint { margin-bottom: 0; }
.review-panel { min-height: 555px; overflow: hidden; }
.review-heading { display: flex; align-items: center; justify-content: space-between; gap: 15px; padding: 25px 28px; border-bottom: 1px solid var(--border); }
.document-name { max-width: 43%; overflow: hidden; color: var(--muted); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.empty-state { padding: 58px 20px 50px; text-align: center; }
.illustration { position: relative; width: 144px; height: 130px; margin: 0 auto 25px; }
.paper { display: block; width: 97px; height: 120px; padding: 25px 16px; transform: rotate(-6deg); border: 2px solid var(--navy); border-radius: 9px; background: #fff; box-shadow: 10px 10px 0 var(--pale); }
.paper i { display: block; height: 4px; margin: 9px 0; border-radius: 4px; background: #d9e7f1; }
.paper .link-line { width: 90%; background: var(--coral); }
.paper .short { width: 60%; }
.chain { position: absolute; right: 6px; bottom: 0; display: grid; place-items: center; width: 62px; height: 62px; border: 6px solid #fff; border-radius: 50%; background: var(--pale); color: var(--navy); font-size: 30px; font-weight: 500; }
h3 { margin: 18px 0 11px; color: var(--ink); font-size: 23px; font-weight: 650; line-height: 1.25; letter-spacing: -.025em; }
.empty-state p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.8; }
.empty-steps { display: flex; justify-content: center; flex-wrap: wrap; gap: 13px; margin-top: 25px; color: var(--navy); font-size: 11px; font-weight: 500; }
.empty-steps span:nth-child(even) { color: var(--coral); }
.stats { display: flex; flex-wrap: wrap; gap: 13px 24px; padding: 20px 28px; border-bottom: 1px solid var(--border); background: var(--pale); }
.stats div { display: flex; align-items: baseline; gap: 8px; }
.stats strong { color: var(--navy); font-size: 25px; font-weight: 650; }
.stats span { color: var(--muted); font-size: 10px; }
.tabs { display: flex; gap: 25px; padding: 0 28px; border-bottom: 1px solid var(--border); }
.tabs button { min-height: 48px; padding: 13px 0; border: 0; border-bottom: 3px solid transparent; background: none; color: var(--muted); font-size: 12px; font-weight: 550; }
.tabs button.active { border-color: var(--coral); color: var(--navy); }
.document-view { max-height: 560px; overflow: auto; padding: 28px; color: var(--ink); font-size: 15px; line-height: 1.85; }
.document-paragraph { margin-bottom: 1em; overflow-wrap: anywhere; white-space: pre-wrap; }
.document-view a { color: var(--navy); text-decoration-color: var(--coral); text-decoration-thickness: 2px; }
.document-view a:hover { background: var(--pale); }
.citations { max-height: 560px; overflow: auto; padding: 10px 28px; }
.citation { display: flex; align-items: start; gap: 11px; padding: 16px 0; border-bottom: 1px solid var(--border); font-size: 13px; }
.citation input { width: 16px; height: 16px; margin-top: 4px; accent-color: var(--navy); }
.citation a { overflow-wrap: anywhere; }
.citation small { display: block; margin-top: 4px; color: var(--muted); font-size: 10px; }
.unresolved { color: #a0323b; }
.citation .badge { display: inline-block; margin-top: 6px; padding: 3px 7px; border: 1px solid #f0d7d9; border-radius: 7px; background: #fff7f7; color: #a0323b; font-size: 10px; }
.warnings { margin: 0 28px; color: #924048; font-size: 11px; }
.warnings p { padding: 11px 13px; border: 1px solid #f0d7d9; border-radius: 12px; background: #fff7f7; }
.export-bar { display: flex; align-items: center; justify-content: space-between; gap: 15px; margin-top: 18px; padding: 20px 28px; border-top: 1px solid var(--border); }
.export-bar > span { color: var(--muted); font-size: 12px; font-weight: 500; }
.export-bar div { display: flex; flex-wrap: wrap; gap: 8px; }
.export-bar button { min-height: 42px; padding: 9px 15px; border: 1px solid var(--border); border-radius: 22px; background: var(--pale); color: var(--navy); font-size: 12px; font-weight: 550; }
.export-bar button:hover { background: #dcebf6; }
.original-link { display: block; padding: 0 28px 22px; color: var(--muted); font-size: 11px; cursor: pointer; }
footer { display: flex; justify-content: space-between; gap: 15px; padding: 26px 0 30px; color: var(--muted); font-size: 10px; }
.hidden { display: none !important; }
.error { margin-top: 15px; padding: 13px; border: 1px solid #f0d7d9; border-radius: 12px; background: #fff3f3; color: #a0323b; font-size: 12px; }
.progress { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding-top: 15px; color: var(--navy); font-size: 11px; }
.progress strong { font-weight: 550; }
.progress > span { width: 100%; padding-left: 25px; }
.spinner { width: 16px; height: 16px; border: 2px solid #d9e7f1; border-top-color: var(--navy); border-radius: 50%; animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
dialog { width: min(570px, calc(100% - 36px)); padding: 32px; border: 1.7px solid var(--border); border-radius: 26px; background: #fff; color: var(--navy); box-shadow: 0 25px 75px rgb(8 24 63 / 22%); }
dialog::backdrop { background: rgb(8 24 63 / 26%); backdrop-filter: blur(3px); }
dialog h2 { margin: 11px 0; font-size: 30px; }
dialog p { color: var(--muted); font-size: 13px; }
#close-source { float: right; width: 36px; height: 36px; border: 0; border-radius: 50%; background: var(--pale); color: var(--navy); font-size: 25px; line-height: 1; }
dialog details { margin-top: 20px; font-size: 12px; }
dialog li { margin: 9px 0; color: var(--muted); }
#source-details { padding: 13px; border-radius: 12px; background: var(--pale); font-size: 12px; }
@media (max-width: 1000px) {
  .workspace { grid-template-columns: 295px minmax(0, 1fr); gap: 18px; }
  .import-panel { padding: 22px; }
  .review-heading, .document-view { padding: 22px; }
  .stats { padding: 18px 22px; }
  .citations { padding: 10px 22px; }
  .export-bar { flex-wrap: wrap; padding: 20px 22px; }
}
@media (max-width: 780px) {
  main { padding-top: 24px; }
  .workspace { grid-template-columns: minmax(0, 1fr); }
  .intro { gap: 20px; padding: 22px; }
  .module-icon { flex-basis: 105px; width: 105px; height: 105px; }
  .review-panel { min-height: 450px; }
  .empty-state { padding: 40px 18px; }
}
@media (max-width: 520px) {
  .topbar { padding: 10px 5%; }
  .topbar-inner { gap: 12px; }
  .brand-frame { width: 150px; }
  .source-state { max-width: 158px; padding: 9px 11px; font-size: 10px; line-height: 1.35; }
  .intro { gap: 14px; padding: 19px 17px; border-radius: 24px; }
  .module-icon { flex-basis: 82px; width: 82px; height: 82px; }
  .eyebrow { font-size: 9px; letter-spacing: .1em; }
  h1 { margin: 5px 0 7px; font-size: 33px; }
  .intro p { font-size: 12px; line-height: 1.6; }
  .intro p br { display: none; }
  h2 { font-size: 17px; }
  .import-panel { padding: 22px; }
  .review-heading { flex-wrap: wrap; gap: 10px; }
  .document-name { max-width: 100%; }
  .empty-state p br { display: none; }
  .stats { gap: 10px 18px; }
  .stats strong { font-size: 23px; }
  .tabs { padding: 0 22px; gap: 22px; }
  .warnings { margin: 0 22px; }
  footer { flex-direction: column; gap: 7px; font-size: 10px; }
  dialog { padding: 25px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; }
  .spinner { animation: none; }
}
