:root {
  color-scheme: light;
  --ink: #142a27;
  --muted: #52645d;
  --green: #1d5e4d;
  --green-dark: #164738;
  --line: #d3dfd5;
  --paper: #fff;
  --wash: #f3f6f2;
  --red: #9a2c32;
  --red-wash: #fff3f2;
  font-family: system-ui, -apple-system, "Segoe UI", sans-serif;
  line-height: 1.55;
  color: var(--ink);
  background: var(--wash);
}
*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; }
[hidden] { display: none !important; }
a { color: var(--green-dark); text-underline-offset: .2em; }
button { font: inherit; cursor: pointer; }
button:disabled { cursor: default; opacity: .48; }
:focus-visible { outline: 3px solid #1d775c; outline-offset: 3px; }
.wrap { width: min(1170px, calc(100% - 2rem)); margin-inline: auto; }
.top { background: var(--paper); border-bottom: 1px solid var(--line); }
.top-inner { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding-block: .8rem; }
.brand { display: inline-flex; align-items: center; gap: .65rem; text-decoration: none; font-weight: 800; line-height: 1.2; }
.brand small { display: block; font-size: .7rem; color: var(--muted); font-weight: 500; }
.mark { display: grid; place-items: center; width: 2.35rem; height: 2.35rem; border-radius: .65rem; background: var(--green); color: white; font-size: 1.75rem; }
.top nav a { font-weight: 650; font-size: .91rem; }
.skip { position: absolute; z-index: 3; left: .75rem; top: .65rem; background: white; padding: .5rem .7rem; transform: translateY(-200%); }
.skip:focus { transform: none; }
.crumb { color: var(--muted); margin: 1.35rem 0 1.05rem; font-size: .86rem; }
.crumb span { margin-inline: .5rem; }
h1, h2, h3 { line-height: 1.19; margin: 0; letter-spacing: -.025em; }
h1 { font-size: clamp(1.95rem, 4vw, 3.6rem); max-width: 26ch; letter-spacing: -.045em; }
.lead { font-size: clamp(1rem, 1.7vw, 1.14rem); max-width: 66ch; color: var(--muted); margin: .75rem 0 1.55rem; }
.card { background: var(--paper); border: 1px solid var(--line); border-radius: 1rem; padding: clamp(1rem, 2.6vw, 1.5rem); box-shadow: 0 4px 16px #16392d08; }
.card h2, .how h2 { font-size: clamp(1.2rem, 2.6vw, 1.55rem); }
.drop { margin-top: .9rem; display: flex; align-items: center; gap: .9rem; padding: 1rem; background: #f2f7f3; border: 1.5px dashed #86a997; border-radius: .78rem; }
.drop.dragging { background: #e1f1e8; border-color: var(--green-dark); }
.file-symbol { display: grid; place-items: center; width: 2.85rem; height: 3.35rem; flex: 0 0 2.85rem; align-self: center; border-radius: .5rem; background: #e0ede6; color: var(--green-dark); font-weight: 800; font-size: .76rem; }
.drop p, .examples { margin: .2rem 0 0; color: var(--muted); font-size: .86rem; }
.drop .primary { margin-inline-start: auto; }
.primary, .secondary { display: inline-flex; justify-content: center; align-items: center; padding: .57rem .84rem; min-height: 2.4rem; font-weight: 700; border: 1px solid transparent; border-radius: .58rem; }
.primary { color: white; background: var(--green); }
.primary:hover:not(:disabled) { background: var(--green-dark); }
.secondary { background: white; color: var(--green-dark); border-color: var(--line); }
.secondary:hover:not(:disabled) { background: #eef5f0; }
.examples { display: flex; align-items: baseline; flex-wrap: wrap; column-gap: .8rem; padding: .78rem 0 .05rem; }
.link-button { background: none; color: var(--green-dark); border: 0; padding: .25rem .04rem; text-decoration: underline; font-weight: 660; text-underline-offset: .18em; }
.notice { color: var(--green-dark); border: 1px solid var(--line); border-radius: .5rem; padding: .55rem .75rem; margin: .8rem 0 0; background: var(--wash); }
.notice.error { background: var(--red-wash); border-color: #e8b7b9; color: var(--red); }
.batch, .results { margin-top: 1.1rem; }
.batch-heading { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: .75rem; }
.batch-actions, .report-actions { display: flex; align-items: center; flex-wrap: wrap; gap: .45rem .6rem; }
.batch-filters { display: flex; flex-wrap: wrap; gap: .25rem; margin: 1rem 0 .65rem; }
.batch-filters button { border: 1px solid transparent; border-radius: .45rem; background: var(--wash); color: var(--ink); padding: .32rem .65rem; font-size: .85rem; font-weight: 650; }
.batch-filters button[aria-pressed=true] { border-color: #86a997; background: #e6f1e9; color: var(--green-dark); }
.batch-table { overflow: auto; border: 1px solid var(--line); border-radius: .55rem; }
.batch-table table { width: 100%; min-width: 35rem; border-collapse: collapse; font-size: .85rem; }
.batch-table th, .batch-table td { padding: .46rem .65rem; text-align: left; border-bottom: 1px solid var(--line); }
.batch-table th { background: var(--wash); font-weight: 700; }
.batch-table tr:last-child td { border-bottom: 0; }
.batch-table td:first-child { width: 40%; overflow-wrap: anywhere; }
.batch-table th:nth-child(4), .batch-table td:nth-child(4) { text-align: center; }
.batch-table td[data-kind="valid"] { color: var(--green-dark); }
.batch-table td[data-kind="issues"], .batch-table td[data-kind="syntax"] { color: var(--red); font-weight: 700; }
.batch-table tr[data-selected=true] { background: #f0f7f2; }
.batch-details-button { min-height: 2rem; padding: .25rem .65rem; font-size: .8rem; }
.report-heading { display: flex; gap: .8rem; align-items: flex-start; justify-content: space-between; margin-bottom: 1rem; }
.file-detail { color: var(--muted); font-size: .85rem; margin: .35rem 0 0; overflow-wrap: anywhere; }
.result-status { color: var(--green-dark); border-radius: .45rem; background: #e9f3ec; padding: .3rem .55rem; font-size: .8rem; font-weight: 700; }
.result-status[data-kind="error"] { background: var(--red-wash); color: var(--red); }
.report-grid { display: grid; grid-template-columns: minmax(0,1fr); gap: 1rem; }
.report-left h3 { font-size: 1.02rem; margin-bottom: .65rem; }
.issue { border: 1px solid var(--line); border-left: 3px solid #bf4d52; border-radius: .52rem; padding: .72rem .8rem; margin-bottom: .65rem; overflow-wrap: anywhere; }
.issue h4 { margin: 0; font-size: .94rem; }
.issue p { font-size: .81rem; margin: .34rem 0; }
.issue-position { color: var(--muted); }
.issue-actions { display: flex; flex-wrap: wrap; gap: .15rem .7rem; }
.issue-actions button { font-size: .79rem; }
.issue[data-selected="true"] { background: #fff8f7; border-color: #d59799; }
.viewer { border: 1px solid var(--line); border-radius: .76rem; min-width: 0; align-self: start; overflow: hidden; }
.viewer-tabs { display: flex; background: #eaf1eb; padding: .3rem .45rem; gap: .25rem; }
.viewer-tabs button { padding: .45rem .7rem; border: 1px solid transparent; border-radius: .45rem; background: transparent; color: var(--ink); font-size: .82rem; font-weight: 700; }
.viewer-tabs button[aria-pressed="true"] { background: white; border-color: var(--line); color: var(--green-dark); }
.panel { padding: .55rem .7rem .7rem; min-width: 0; }
#xml-source { background: #f7f8f7; border: 1px solid var(--line); margin: .6rem 0 0; border-radius: .46rem; padding: .7rem; font: .8rem/1.65 "Cascadia Mono", Consolas, monospace; white-space: pre-wrap; overflow-wrap: anywhere; max-height: 360px; overflow: auto; }
#xml-source mark { background: #ffdedd; color: #72262a; padding: 0 .08em; }
.pdf-toolbar { display: flex; flex-wrap: wrap; gap: .4rem .8rem; align-items: center; justify-content: space-between; }
.pdf-pages, .pdf-zoom { display: flex; align-items: center; gap: .28rem; }
#pdf-page, #pdf-zoom-value { font-weight: 650; font-size: .83rem; }
#pdf-page { margin-inline-end: .25rem; }
#pdf-zoom-value { min-width: 3.3rem; text-align: center; font-variant-numeric: tabular-nums; }
.pdf-toolbar button { min-height: 2.2rem; min-width: 2.2rem; padding: .12rem .55rem; }
.pdf-overflow { margin-top: .55rem; overflow: auto; background: #e8ece8; border-radius: .34rem; max-height: min(68vh, 720px); }
.pdf-sheet { position: relative; width: max-content; margin-inline: auto; }
#pdf-canvas { display: block; width: 100%; height: auto; background: white; }
.pdf-highlight { position: absolute; border: 2px solid #aa2531; border-radius: .16rem; background: #e83d471c; pointer-events: none; }
.how { margin: 1.8rem 0 1.1rem; }
.how ol { padding-inline-start: 1.35rem; }
.how li + li { margin-top: .3rem; }
.how p { color: var(--muted); font-size: .89rem; max-width: 76ch; }
.foot { border-top: 1px solid var(--line); color: var(--muted); padding-block: .85rem 1.4rem; display: flex; flex-wrap: wrap; justify-content: space-between; gap: .6rem 1.2rem; font-size: .83rem; }
@media (max-width: 520px) {
  .drop { align-items: flex-start; flex-wrap: wrap; }
  .drop div:nth-child(2) { flex: 1 1 170px; }
  .drop .primary { margin: 0; width: 100%; }
  .report-heading { flex-wrap: wrap; }
}
