:root {
  --accent: #43b3e0;
  --accent-dark: #2a8fba;
  --ink: #2f3337;
  --ink-soft: #5d646b;
  --line: #e3e7ea;
  --bg: #f4f6f8;
  --card: #fff;
  --green: #2e9e5b;
  --amber: #d9911a;
  --red: #d2453b;
  --orange: #e2730f;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(20, 30, 40, .06), 0 8px 24px rgba(20, 30, 40, .08);
}

* { box-sizing: border-box; }
/* The hidden attribute always wins (component display rules were overriding it). */
[hidden] { display: none !important; }
html, body { margin: 0; }
body {
  font-family: 'Open Sans', system-ui, sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
main { max-width: 1040px; margin: 0 auto; padding: 0 16px 80px; }
h1, h2, h3 { line-height: 1.2; margin: 0 0 .4em; }
h1 { font-size: clamp(30px, 5vw, 46px); font-weight: 800; letter-spacing: -.02em; }
h1 em { font-style: normal; color: var(--accent); }
h2 { font-size: clamp(22px, 3.4vw, 30px); font-weight: 700; }
h3 { font-size: 18px; margin-top: 32px; }
.lede { font-size: 18px; color: var(--ink-soft); margin: 0 0 28px; }
.muted { color: var(--ink-soft); }
.error { color: var(--red); font-weight: 600; }

/* ---------------------------------------------------------------- chrome */

.topbar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 20px; background: #3e3e3e; color: #fff; position: relative; z-index: 6;
}
.brand { color: #fff; text-decoration: none; font-size: 17px; position: relative; padding-left: 120px; }
/* The homepage's N18MD circle at about a third of its size, hanging from the top bar. */
.brand-logo { position: absolute; left: 0; top: -8px; width: 104px; height: 104px; border-radius: 50%; object-fit: cover;
  border: 3px solid #fff; box-shadow: 0 4px 14px rgba(20, 30, 40, .25); z-index: 6; }
@media (max-width: 760px) {
  .brand { padding-left: 64px; }
  .brand-logo { width: 52px; height: 52px; top: -14px; border-width: 2px; }
}
.product { font-size: 13px; letter-spacing: .12em; text-transform: uppercase; opacity: .8; }
a.product { color: inherit; text-decoration: none; }

.steps {
  display: flex; gap: 8px; justify-content: center; list-style: none;
  margin: 24px auto 36px; padding: 0 16px; max-width: 1040px; flex-wrap: wrap;
}
.steps li {
  display: flex; align-items: center; gap: 8px; padding: 6px 14px 6px 6px;
  border-radius: 999px; background: #fff; color: var(--ink-soft); font-weight: 600; font-size: 14px;
  border: 1px solid var(--line); transition: all .3s;
}
.steps li span {
  width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center;
  background: var(--line); color: var(--ink-soft); font-size: 13px;
}
.steps li.active { border-color: var(--accent); color: var(--ink); }
.steps li.active span { background: var(--accent); color: #fff; }
.steps li.done span { background: var(--green); color: #fff; }

.screen { display: none; animation: rise .45s ease both; }
.screen.active { display: block; }
@keyframes rise { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }

.card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 24px; }

.btn {
  font: inherit; font-weight: 700; border: 0; cursor: pointer; border-radius: 10px;
  padding: 12px 22px; font-size: 16px; text-decoration: none; display: inline-block;
  transition: transform .1s, background .2s, opacity .2s;
}
.btn:active { transform: translateY(1px); }
.btn.primary { background: var(--accent); color: #fff; }
.btn.primary:hover { background: var(--accent-dark); }
.btn.ghost { background: transparent; color: var(--ink-soft); border: 1px solid var(--line); }
.btn.big { font-size: 19px; padding: 16px 34px; }
.btn:disabled { opacity: .4; cursor: not-allowed; }

/* ---------------------------------------------------------------- 1. aircraft */

.plate-form { display: flex; flex-wrap: wrap; align-items: stretch; gap: 14px; }
.plate-label { width: 100%; font-weight: 700; font-size: 14px; color: var(--ink-soft); text-transform: uppercase; letter-spacing: .08em; }
.plate {
  display: flex; align-items: center; background: #fff; border-radius: 12px; box-shadow: var(--shadow);
  border-bottom: 6px solid var(--accent); padding: 4px 18px; flex: 0 1 340px;
}
.plate-n, .plate input {
  font-family: 'Open Sans', sans-serif; font-weight: 800; font-size: 48px; line-height: 1.25; letter-spacing: .06em; color: var(--ink);
}
.plate input {
  border: 0; outline: 0; width: 100%; min-width: 0; text-transform: uppercase; background: transparent; padding: 0 0 0 4px;
}
.plate input::placeholder { color: #c9d0d6; }
.plate:focus-within { border-bottom-color: var(--accent-dark); }
.plate-form .btn { padding: 0 28px; font-size: 18px; }
.plate-form .error { width: 100%; margin: 0; }

.aircraft-card { margin-top: 28px; max-width: 640px; animation: rise .45s ease both; }
.aircraft-reg { font-weight: 800; font-size: 15px; letter-spacing: .14em; color: var(--accent); }
.aircraft-title { font-weight: 800; font-size: 26px; margin-bottom: 14px; }
.aircraft-facts { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 12px 24px; margin: 0 0 20px; }
.aircraft-facts dt { font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: var(--ink-soft); }
.aircraft-facts dd { margin: 0; font-weight: 600; }
.card-actions { display: flex; gap: 10px; flex-wrap: wrap; }

/* ---------------------------------------------------------------- 2. logbooks */

.dropzone {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
  min-height: 260px; border: 3px dashed #b9c6cf; border-radius: 20px; background: #fff;
  cursor: pointer; text-align: center; padding: 24px; transition: all .2s;
}
.dropzone:hover, .dropzone.over { border-color: var(--accent); background: #eef8fc; transform: scale(1.01); }
.dropzone.over .drop-icon { transform: translateY(-6px); }
.drop-icon { width: 72px; height: 72px; color: var(--accent); transition: transform .2s; }
.drop-title { font-size: 24px; font-weight: 800; }
.drop-sub { color: var(--ink-soft); font-size: 16px; }

.include-list { list-style: none; padding: 0; margin: 16px 0 0; display: flex; flex-wrap: wrap; gap: 8px; }
.include-list li { background: #fff; border: 1px solid var(--line); border-radius: 999px; padding: 4px 12px; font-size: 14px; color: var(--ink-soft); }
.include-list li::before { content: '✓ '; color: var(--accent); font-weight: 800; }

.file-list { list-style: none; padding: 0; margin: 20px 0 0; display: grid; gap: 10px; }
.file-list li {
  display: grid; grid-template-columns: 40px 1fr auto; gap: 12px; align-items: center;
  background: #fff; border-radius: 12px; padding: 12px 14px; box-shadow: var(--shadow); animation: rise .3s ease both;
}
.file-badge { width: 40px; height: 48px; border-radius: 6px; background: #eef1f4; display: grid; place-items: center; font-size: 11px; font-weight: 800; color: var(--ink-soft); }
.file-badge.pdf { background: #fde8e6; color: var(--red); }
.file-name { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file-meta { font-size: 13px; color: var(--ink-soft); }
.file-bar { height: 6px; background: var(--line); border-radius: 3px; margin-top: 6px; overflow: hidden; }
.file-bar div { height: 100%; width: 0; background: var(--accent); transition: width .2s; }
.file-state { font-size: 22px; }
.file-list li.done .file-bar div { background: var(--green); }

.screen-actions { margin-top: 28px; text-align: center; }

/* ---------------------------------------------------------------- 3. reading */

.reading { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 28px; align-items: start; }
.scanner {
  position: relative; margin: 0; background: #fff; border-radius: var(--radius); box-shadow: var(--shadow);
  min-height: 420px; overflow: hidden; display: flex; flex-direction: column;
}
.scanner img { width: 100%; height: 520px; object-fit: contain; background: #eceff1; display: block; animation: rise .4s ease both; }
.scanner img[hidden] { display: none; }
.scanner figcaption { padding: 10px 14px; font-size: 14px; color: var(--ink-soft); }
.scan-line {
  position: absolute; left: 0; right: 0; top: 0; height: 80px; pointer-events: none;
  background: linear-gradient(to bottom, rgba(67, 179, 224, 0), rgba(67, 179, 224, .35), rgba(67, 179, 224, 0));
  animation: scan 2.6s ease-in-out infinite;
}
.scanner.idle .scan-line { display: none; }
@keyframes scan { 0% { transform: translateY(-80px); } 100% { transform: translateY(520px); } }

.progress-count { font-size: 44px; font-weight: 800; line-height: 1; }
.progress-count small { font-size: 18px; font-weight: 600; color: var(--ink-soft); }
.bar { height: 12px; background: var(--line); border-radius: 6px; overflow: hidden; margin-top: 12px; }
.bar div { height: 100%; width: 0; background: linear-gradient(90deg, var(--accent), var(--accent-dark)); transition: width .6s ease; }

.counters { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 22px 0; }
.counters div { background: #fff; border-radius: 12px; padding: 12px; box-shadow: var(--shadow); text-align: center; }
.counters strong { display: block; font-size: 28px; font-weight: 800; }
.counters span { font-size: 13px; color: var(--ink-soft); }
.counters strong.bump { animation: bump .35s ease; }
@keyframes bump { 50% { transform: scale(1.25); color: var(--accent); } }

.stages { list-style: none; padding: 0; margin: 0 0 20px; }
.stages li { padding: 8px 0 8px 34px; position: relative; color: var(--ink-soft); font-weight: 600; }
.stages li::before {
  content: ''; position: absolute; left: 0; top: 9px; width: 20px; height: 20px; border-radius: 50%;
  border: 2px solid var(--line); background: #fff;
}
.stages li.current { color: var(--ink); }
.stages li.current::before { border-color: var(--accent); border-top-color: transparent; animation: spin .9s linear infinite; }
.stages li.done { color: var(--ink); }
.stages li.done::before { content: '✓'; background: var(--green); border-color: var(--green); color: #fff; font-size: 12px; display: grid; place-items: center; font-weight: 800; }
@keyframes spin { to { transform: rotate(360deg); } }

.ticker { background: #fff; border-left: 4px solid var(--accent); border-radius: 8px; padding: 12px 14px; box-shadow: var(--shadow); min-height: 84px; }
.ticker-label { font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: var(--ink-soft); }
#ticker-text { font-family: ui-monospace, 'SF Mono', Menlo, monospace; font-size: 14px; animation: rise .3s ease both; }
.hint { font-size: 14px; color: var(--ink-soft); }

/* ---------------------------------------------------------------- 4. report */

.report-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; }
.headline { font-size: 20px; font-weight: 600; margin: 4px 0 24px; }

.tiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.tile { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px; border-top: 5px solid var(--line); animation: rise .4s ease both; }
.tile.green { border-top-color: var(--green); }
.tile.amber { border-top-color: var(--amber); }
.tile.red { border-top-color: var(--red); }
.tile-head { display: flex; align-items: center; gap: 10px; font-weight: 800; }
.tile-icon { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; color: #fff; font-size: 16px; flex: none; }
.tile.green .tile-icon { background: var(--green); }
.tile.amber .tile-icon { background: var(--amber); }
.tile.red .tile-icon { background: var(--red); }
.tile-key { font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: var(--ink-soft); margin-bottom: 6px; }
.tile p { margin: 8px 0 0; font-size: 14px; color: var(--ink-soft); }

.report-cols { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 28px; align-items: start; }
.flags, .likes { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.flags li, .likes li { background: #fff; border-radius: 12px; padding: 14px 16px; box-shadow: var(--shadow); border-left: 5px solid var(--line); }
.flags li.red { border-left-color: var(--red); }
.flags li.amber { border-left-color: var(--amber); }
.likes li { border-left-color: var(--green); }
.flags strong, .likes strong { display: block; }
.flags p, .likes p { margin: 4px 0 0; font-size: 15px; color: var(--ink-soft); }
.page-links { margin-top: 6px; display: flex; gap: 6px; flex-wrap: wrap; }
.page-link { font-size: 12px; font-weight: 700; color: var(--accent-dark); background: #eef8fc; border: 0; border-radius: 6px; padding: 2px 8px; cursor: pointer; }

.upsell { position: sticky; top: 16px; margin-top: 32px; border-top: 5px solid var(--accent); }
.upsell h3 { margin-top: 0; }
.upsell .price { font-size: 18px; margin: 8px 0 0; }
.upsell .fine { font-size: 13px; color: var(--ink-soft); }

.timeline { position: relative; margin-top: 12px; }
.tl-year { font-weight: 800; font-size: 22px; color: var(--accent); margin: 22px 0 8px; }
.tl-item { display: grid; grid-template-columns: 110px 1fr; gap: 14px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.tl-date { font-weight: 700; font-size: 14px; }
.tl-date small { display: block; font-weight: 400; color: var(--ink-soft); }
.tl-kind { display: inline-block; font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; background: #eef1f4; border-radius: 4px; padding: 1px 6px; margin-right: 6px; }
.tl-work { font-size: 15px; }
.tl-notes { color: var(--amber); font-size: 14px; font-weight: 600; margin-top: 4px; }
.disclaimer { font-size: 13px; color: var(--ink-soft); margin-top: 32px; }

dialog#page-viewer { border: 0; border-radius: 12px; padding: 0; max-width: min(96vw, 1000px); max-height: 94vh; }
dialog#page-viewer::backdrop { background: rgba(10, 20, 30, .7); }
dialog#page-viewer img { display: block; max-width: 100%; max-height: 94vh; }
dialog#page-viewer .close { position: absolute; top: 8px; right: 10px; border: 0; background: #fff; border-radius: 50%; width: 36px; height: 36px; font-size: 22px; cursor: pointer; box-shadow: var(--shadow); }

/* ---------------------------------------------------------------- pause, share */

.reading-actions { display: flex; gap: 10px; margin: 16px 0 4px; }
.btn.small { padding: 6px 14px; font-size: 14px; }

.link-box { display: grid; gap: 12px; margin: 8px 0 24px; border-top: 5px solid var(--green); }
.link-box .muted { display: block; font-size: 14px; }
.link-row { display: flex; gap: 8px; flex-wrap: wrap; }
.link-row input {
  flex: 1 1 260px; min-width: 0; font: inherit; font-size: 14px; padding: 10px 12px;
  border: 1px solid var(--line); border-radius: 10px; background: var(--bg); color: var(--ink);
}

/* share page */
body.share main { padding-top: 28px; }
.report-title { font-size: clamp(26px, 4vw, 36px); margin: 2px 0 4px; }
.downloads { display: flex; gap: 10px; flex-wrap: wrap; margin: 18px 0 8px; }
.section-nav {
  position: sticky; top: 0; z-index: 5; display: flex; gap: 4px; overflow-x: auto;
  background: rgba(244, 246, 248, .94); backdrop-filter: blur(6px); padding: 10px 0; margin-bottom: 8px;
  border-bottom: 1px solid var(--line);
}
.section-nav a { text-decoration: none; color: var(--ink-soft); font-weight: 700; font-size: 15px; padding: 6px 12px; border-radius: 8px; white-space: nowrap; }
.section-nav a:hover { background: #fff; color: var(--ink); }
.report-section { padding-top: 24px; scroll-margin-top: 56px; }
.report-section > h2 { border-bottom: 3px solid var(--accent); display: inline-block; padding-bottom: 2px; margin-bottom: 14px; }
.upsell.wide { position: static; display: grid; grid-template-columns: 1fr minmax(0, 340px); gap: 24px; align-items: center; margin-top: 40px; }
.review-form { display: flex; flex-direction: column; gap: 6px; }
.review-form label { font-weight: 700; font-size: 14px; margin-top: 4px; }
.review-form input, .review-form textarea { font: inherit; font-size: 15px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; resize: vertical; }
.review-form .btn { margin-top: 8px; }
.review-msg { margin: 0; font-size: 13px; color: var(--ink-soft); min-height: 1em; }
.review-done { margin: 0; font-weight: 600; }

.files { display: grid; gap: 16px; }
.file-card { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px; }
.file-card-head { display: grid; grid-template-columns: 40px 1fr auto; gap: 12px; align-items: center; }
.file-card-title { min-width: 0; }
.file-card-title strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file-card-title .muted { font-size: 13px; }
.thumbs { display: grid; grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); gap: 8px; margin-top: 14px; }
.thumb {
  position: relative; border: 1px solid var(--line); border-radius: 6px; padding: 0; background: #eceff1;
  aspect-ratio: 3 / 4; overflow: hidden; cursor: zoom-in; transition: transform .15s, box-shadow .15s;
}
.thumb:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.thumb img { width: 100%; height: 100%; object-fit: cover; object-position: top; display: block; }
.thumb span { position: absolute; right: 4px; bottom: 4px; background: rgba(0, 0, 0, .6); color: #fff; font-size: 11px; font-weight: 700; border-radius: 4px; padding: 0 5px; }

@media (max-width: 760px) {
  .upsell.wide { grid-template-columns: 1fr; }
}
@media print {
  .downloads, .section-nav, .link-box, .reading-actions, .thumbs { display: none !important; }
  .report-section { break-inside: auto; }
  .file-card { box-shadow: none; border: 1px solid var(--line); }
}

/* costs */
.beta { font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; background: var(--amber); color: #fff; border-radius: 4px; padding: 2px 6px; vertical-align: middle; }
.costs { overflow-x: auto; }
.costs table { width: 100%; border-collapse: collapse; background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); font-size: 14px; }
.costs th, .costs td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.costs th { font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-soft); }
.costs td small { display: block; color: var(--ink-soft); font-size: 12px; }
.costs .mono { font-family: ui-monospace, 'SF Mono', Menlo, monospace; font-size: 13px; }
.costs .num, .costs tfoot td:last-child { text-align: right; font-variant-numeric: tabular-nums; }
.costs tfoot td { font-weight: 800; border-bottom: 0; }
.small { font-size: 13px; }

/* ---------------------------------------------------------------- intake, buckets, life */

.linklike { background: none; border: 0; padding: 0; font: inherit; color: var(--accent-dark); text-decoration: underline; cursor: pointer; }
.drop-formats { font-size: 12px; letter-spacing: .06em; color: var(--ink-soft); margin-top: 6px; }
.upload-summary { margin-top: 18px; padding: 14px 18px; }
.upload-summary-head { display: flex; justify-content: space-between; gap: 12px; align-items: center; margin-bottom: 8px; flex-wrap: wrap; }
.file-list li { grid-template-columns: 40px 1fr auto; }
.file-end { display: flex; align-items: center; gap: 8px; }
.remove { border: 0; background: #eef1f4; color: var(--ink-soft); width: 28px; height: 28px; border-radius: 50%; font-size: 18px; line-height: 1; cursor: pointer; }
.remove:hover { background: #fde8e6; color: var(--red); }
.file-list li.duplicate, .file-list li.error { opacity: .75; }
.file-list li.duplicate .file-meta { color: var(--ink-soft); }
.file-list li.error .file-meta { color: var(--red); }
.file-badge.zip { background: #fff3dc; color: var(--amber); }
.file-badge.doc { background: #e6f0fd; color: #3b6fd0; }

.aircraft-facts .warn dd { color: var(--red); }
.warn { color: var(--red); }

.eta { font-weight: 700; color: var(--accent-dark); margin: 10px 0 0; }
.counters .concerns strong { color: var(--red); }
.counter-minor { margin: -12px 0 18px; font-size: 13px; color: var(--ink-soft); text-align: right; }

.intake-panel { margin-top: 24px; }
.intake-panel h3 { margin-top: 0; }
.intake-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.intake-list li { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 10px; background: var(--bg); border-left: 4px solid var(--line); }
.intake-list li.rejected { border-left-color: var(--red); }
.intake-list li.duplicate { border-left-color: var(--ink-soft); }
.intake-list li.skipped { border-left-color: var(--amber); }
.intake-list strong { display: block; word-break: break-word; }
.intake-list .muted { font-size: 13px; }

h3 .count { display: inline-block; margin-left: 8px; font-size: 12px; background: var(--red); color: #fff; border-radius: 999px; padding: 1px 8px; vertical-align: middle; }
h3 .count.good { background: var(--green); }
.tag { margin-left: 8px; font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; background: #eef1f4; color: var(--ink-soft); border-radius: 4px; padding: 1px 6px; vertical-align: middle; }
details.fyi { margin-top: 24px; background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 12px 16px; }
details.fyi summary { cursor: pointer; font-weight: 700; }
.fyi-list { list-style: none; padding: 0; margin: 12px 0 0; display: grid; gap: 10px; }
.fyi-list li { border-left: 4px solid var(--line); padding: 4px 0 4px 12px; }
.fyi-list p { margin: 2px 0 0; font-size: 14px; color: var(--ink-soft); }

.tl-note { font-size: 14px; font-weight: 600; margin-top: 4px; padding-left: 18px; position: relative; }
.tl-note::before { position: absolute; left: 0; font-weight: 800; }
.tl-note.concern { color: var(--red); }
.tl-note.concern::before { content: '!'; }
.tl-note.good { color: var(--green); }
.tl-note.good::before { content: '✓'; }
.tl-note.fyi { color: var(--ink-soft); font-weight: 400; }
.tl-note.fyi::before { content: 'i'; font-style: italic; }
.tl-suspect { font-size: 13px; color: var(--amber); font-weight: 600; margin-top: 4px; }

/* life: newest at top; year rail, owner-colored spine, event cards */
.life-legend { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 13px; color: var(--ink-soft); margin: 0 0 12px; }
.life-legend i { display: inline-block; width: 12px; height: 12px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.life { position: relative; }
.life-row, .life-gap { display: grid; grid-template-columns: 52px 34px 1fr; align-items: stretch; }
.life-year { font-weight: 800; color: var(--accent); font-size: 15px; padding-top: 12px; text-align: right; padding-right: 10px; }
.life-spine { position: relative; display: flex; justify-content: center; }
.life-spine::before { content: ''; position: absolute; top: 0; bottom: 0; width: 6px; border-radius: 3px; background: var(--c, #c9d0d6); }
.life-dot { position: relative; z-index: 1; margin-top: 10px; width: 26px; height: 26px; border-radius: 50%; background: #fff; border: 2px solid var(--c, #c9d0d6);
  display: grid; place-items: center; font-style: normal; font-size: 13px; font-weight: 800; color: var(--ink); }
.life-card { background: #fff; border-radius: 12px; box-shadow: var(--shadow); padding: 10px 14px; margin: 6px 0 6px 6px; }
.life-title { font-weight: 700; }
.life-meta { font-size: 12px; color: var(--ink-soft); margin-top: 2px; }
.life-detail { font-size: 14px; color: var(--ink-soft); margin-top: 4px; }
.life-gap > .muted { font-size: 13px; padding: 10px 0 10px 12px; font-style: italic; }
.life-row.accident .life-dot, .life-row.damage .life-dot { background: #fde8e6; color: var(--red); }
.life-row.repair .life-dot, .life-row.overhaul .life-dot { color: var(--ink-soft); }
.life-row.owner .life-dot, .life-row.nnumber .life-dot { background: var(--c); color: #fff; }
.life-row.birth .life-dot { background: var(--ink); color: #fff; border-color: var(--ink); }
.life-row.annual .life-dot { color: var(--green); }
.life-row.nnumber .life-title { color: var(--accent-dark); }

.ownership p { margin: 6px 0; }
.owner-table { width: 100%; border-collapse: collapse; background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); font-size: 14px; margin: 10px 0; overflow: hidden; }
.owner-table th, .owner-table td { text-align: left; padding: 9px 12px; border-bottom: 1px solid var(--line); }
.owner-table th { font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-soft); }

.file-card.duplicate, .file-card.skipped, .file-card.rejected { opacity: .7; }
.file-state-note { font-size: 13px; font-weight: 700; color: var(--amber); margin-bottom: 8px; }
.file-card.rejected .file-state-note { color: var(--red); }

@media (max-width: 460px) {
  .life-row, .life-gap { grid-template-columns: 40px 28px 1fr; }
  .life-year { font-size: 13px; padding-right: 6px; }
}

/* ---------------------------------------------------------------- small screens */

@media (max-width: 760px) {
  .reading, .report-cols { grid-template-columns: 1fr; }
  .tiles { grid-template-columns: 1fr 1fr; }
  .scanner img { height: 360px; }
  .plate { flex-basis: 100%; }
  .plate-form .btn { width: 100%; }
  .upsell { position: static; }
}
@media (max-width: 460px) {
  .tiles { grid-template-columns: 1fr; }
  .tl-item { grid-template-columns: 1fr; gap: 2px; }
  .counters strong { font-size: 22px; }
}
@media print {
  .topbar, .steps, .upsell, .report-head .btn, .page-links { display: none !important; }
  body { background: #fff; }
  .tile, .flags li, .likes li { box-shadow: none; border: 1px solid var(--line); }
}

/* ================================================================ report v2 */

.report-v2 { --navy: #12324a; --slate: #1d2730; --concern: #d2453b; --concern-bg: #fdf0ee; --like: #2e9e5b; --like-bg: #edf8f1;
  --note: #2a78d6; --note-bg: #eef4fc; --gold: #e0a243; }
.icon { width: 1em; height: 1em; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; vertical-align: -0.15em; flex: none; }

/* hero */
.hero { position: relative; overflow: hidden; border-radius: 22px; padding: 30px 32px 26px; margin: 4px 0 18px; color: #fff;
  background: radial-gradient(1200px 300px at 90% -20%, rgba(67, 179, 224, .45), transparent 60%), linear-gradient(135deg, var(--slate), var(--navy));
  box-shadow: 0 18px 40px rgba(18, 50, 74, .25); }
.hero::after { content: ''; position: absolute; right: -60px; bottom: -80px; width: 340px; height: 340px; border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, .07); box-shadow: 0 0 0 40px rgba(255, 255, 255, .03), 0 0 0 80px rgba(255, 255, 255, .02); pointer-events: none; }
.hero-top { display: flex; gap: 22px; align-items: center; flex-wrap: wrap; position: relative; z-index: 1; }
.hero-plate { background: #fff; color: var(--slate); border-radius: 10px; padding: 6px 18px 4px; border-bottom: 6px solid var(--accent);
  font-weight: 800; font-size: clamp(30px, 5vw, 44px); letter-spacing: .08em; box-shadow: 0 8px 20px rgba(0, 0, 0, .25); transform: rotate(-1.5deg); }
.hero-id { flex: 1; min-width: 240px; }
.hero-kicker { font-size: 12px; font-weight: 800; letter-spacing: .18em; text-transform: uppercase; color: var(--accent); }
.hero-title { font-size: clamp(24px, 3.6vw, 34px); margin: 2px 0 10px; color: #fff; }
.hero-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.hchip { background: rgba(255, 255, 255, .1); border: 1px solid rgba(255, 255, 255, .16); border-radius: 999px; padding: 4px 12px; font-size: 14px; font-weight: 600; }
.hchip small { opacity: .65; font-weight: 600; margin-right: 6px; text-transform: uppercase; font-size: 10px; letter-spacing: .1em; }
.hero-headline { position: relative; z-index: 1; font-size: clamp(17px, 2.2vw, 21px); line-height: 1.45; margin: 22px 0 20px; max-width: 900px; color: #e9f2f8; }
.hero-counts { position: relative; z-index: 1; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.hcount { display: flex; align-items: baseline; gap: 10px; text-decoration: none; color: #fff; border-radius: 14px; padding: 12px 16px;
  background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .14); transition: transform .15s, background .15s; }
.hcount:hover { transform: translateY(-2px); background: rgba(255, 255, 255, .14); }
.hcount strong { font-size: 34px; font-weight: 800; line-height: 1; }
.hcount span { font-weight: 600; opacity: .9; }
.hcount.concern strong { color: #ff8a80; }
.hcount.like strong { color: #7ee2a4; }
.hcount.note strong { color: #8cc3ff; }

/* verdict tiles */
.verdicts { margin-bottom: 26px; }
.report-v2 .tiles { grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; }
.report-v2 .tile { border-top: 0; border-left: 5px solid var(--line); padding: 14px 16px; }
.report-v2 .tile.green { border-left-color: var(--green); }
.report-v2 .tile.amber { border-left-color: var(--amber); }
.report-v2 .tile.red { border-left-color: var(--red); }
.tile-top { display: flex; align-items: center; gap: 8px; }
.tile-glyph { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; background: #eef1f4; color: var(--ink-soft); font-size: 16px; }
.report-v2 .tile-key { flex: 1; margin: 0; font-size: 11px; }
.tile-status { white-space: nowrap; display: inline-flex; align-items: center; gap: 4px; font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; border-radius: 999px; padding: 2px 8px; }
.tile.green .tile-status { background: var(--like-bg); color: var(--green); }
.tile.amber .tile-status { background: #fff4e0; color: #b87500; }
.tile.red .tile-status { background: var(--concern-bg); color: var(--red); }
.tile-title { font-weight: 800; font-size: 16px; margin: 10px 0 0; line-height: 1.3; }
.ntsb-note { display: flex; gap: 6px; align-items: center; font-size: 13px; color: var(--ink-soft); margin: 12px 2px 0; }

/* the three groupings */
.groups { display: grid; gap: 22px; margin-bottom: 34px; }
.group { border-radius: 20px; padding: 6px; background: var(--gbg); }
.g-concern { --gc: var(--concern); --gbg: var(--concern-bg); }
.g-like { --gc: var(--like); --gbg: var(--like-bg); }
.g-note { --gc: var(--note); --gbg: var(--note-bg); }
.group-head { display: flex; gap: 14px; align-items: center; padding: 14px 16px 12px; }
.group-icon { width: 44px; height: 44px; border-radius: 14px; background: var(--gc); color: #fff; display: grid; place-items: center; font-size: 22px; box-shadow: 0 6px 14px color-mix(in srgb, var(--gc) 35%, transparent); }
.group-head h2 { margin: 0; font-size: clamp(20px, 2.6vw, 25px); display: flex; align-items: center; gap: 10px; }
.group-count { font-size: 14px; background: var(--gc); color: #fff; border-radius: 999px; padding: 1px 10px; }
.group-head p { margin: 2px 0 0; color: var(--ink-soft); font-size: 14px; }
.group-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 420px), 1fr)); gap: 10px; padding: 0 6px 6px; }
.group-empty { padding: 4px 16px 16px; color: var(--ink-soft); }
.fcard { background: #fff; border-radius: 14px; padding: 14px 14px 14px 16px; display: flex; flex-direction: column; gap: 10px;
  box-shadow: 0 1px 2px rgba(20, 30, 40, .06); border-left: 4px solid var(--gc); animation: rise .35s ease both; }
.fcard.concern.red { border-left-width: 6px; }
.fcard.concern.amber { --gc: var(--orange); }
.fcard-date { color: var(--ink-soft); letter-spacing: .04em; }
.fcard-link { display: inline-block; margin-top: 6px; font-size: 14px; font-weight: 700; color: var(--accent-dark); }
.fcard-body { flex: 1; min-width: 0; }
.fcard-kicker { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; color: var(--gc); }
.fcard h4 { margin: 4px 0 4px; font-size: 16px; line-height: 1.3; }
.fcard p { margin: 0; font-size: 14px; color: var(--ink-soft); }
.chip-checked, .chip-engine { display: inline-flex; gap: 3px; align-items: center; background: #eef1f4; color: var(--ink-soft); border-radius: 999px; padding: 1px 7px; letter-spacing: .04em; }
.chip-engine { background: #fff4e0; color: #9a6400; }
.fcard-pages { display: flex; gap: 6px; flex-wrap: wrap; margin-top: auto; }
.fcard-thumb, .ev-thumb { border: 1px solid var(--line); border-radius: 8px; padding: 0; width: 58px; height: 76px; overflow: hidden; background: #eceff1; cursor: zoom-in; transition: transform .15s, box-shadow .15s; }
.fcard-thumb:hover, .ev-thumb:hover { transform: scale(1.06) rotate(-1deg); box-shadow: var(--shadow); }
.fcard-thumb img, .ev-thumb img { width: 100%; height: 100%; object-fit: cover; object-position: top; display: block; }

/* report sections */
/* Summary: the first-impressions letter, set for reading (narrow measure, plain lists). */
.synopsis { background: var(--card); border-radius: 20px; box-shadow: var(--shadow); padding: 26px 32px 24px; margin: 0 0 18px; }
.syn-head h2 { font-size: clamp(22px, 3vw, 28px); margin: 0; display: inline-block; border-bottom: 4px solid var(--accent); padding-bottom: 2px; }
.syn-opening { color: var(--ink-soft); margin: 10px 0 4px; max-width: 760px; }
.synopsis p, .synopsis ul { max-width: 760px; }
.syn-topic p { margin: 14px 0 4px; }
.synopsis ul { margin: 4px 0 0; padding-left: 22px; }
.synopsis li { margin: 3px 0; }
.synopsis li > ul { margin-top: 2px; }
.syn-block { margin-top: 22px; padding-top: 16px; border-top: 1px solid var(--line); }
.syn-block h3 { margin: 0 0 6px; font-size: 18px; display: flex; align-items: center; gap: 8px; }
.syn-block h3 .icon { width: 20px; height: 20px; }
.syn-likes h3 { color: var(--green); }
.syn-closer h3 { color: var(--amber); }
.syn-closer > ul > li { margin-top: 10px; }
.syn-paper h3 { color: var(--accent-dark); }
.syn-cite { border: 0; background: none; padding: 0 0 0 4px; color: var(--accent-dark); cursor: zoom-in; vertical-align: -2px; opacity: .7; }
.syn-cite:hover { opacity: 1; }
.syn-cite .icon { width: 15px; height: 15px; }
.syn-cite span { font-size: 11px; font-weight: 700; margin-left: 1px; }
@media (max-width: 640px) { .synopsis { padding: 20px 18px 18px; border-radius: 16px; } }

.rsection { margin: 36px 0 0; scroll-margin-top: 60px; }
.rsection-head { margin-bottom: 14px; }
.rsection-head h2 { font-size: clamp(22px, 3vw, 28px); margin: 0; display: inline-block; border-bottom: 4px solid var(--accent); padding-bottom: 2px; }
.rsection-head p { margin: 6px 0 0; color: var(--ink-soft); }

/* life story */
.story { position: relative; }
.chapter { position: relative; margin-bottom: 8px; }
.chapter-head { position: relative; z-index: 1; display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 14px; margin: 0 auto 6px; max-width: 760px;
  background: var(--c); color: #fff; border-radius: 16px; padding: 14px 20px; box-shadow: 0 10px 22px color-mix(in srgb, var(--c) 30%, transparent); }
.chapter-years { font-size: 28px; font-weight: 800; letter-spacing: -.01em; }
.chapter-head h3 { margin: 0; font-size: 18px; flex: 1; min-width: 200px; }
.chapter-meta { font-size: 13px; font-weight: 700; opacity: .9; }
.chapter-events { position: relative; padding: 6px 0; }
.chapter-events::before { content: ''; position: absolute; left: 50%; top: 0; bottom: 0; width: 6px; margin-left: -3px; border-radius: 3px; background: color-mix(in srgb, var(--c) 55%, #fff); }
.ev { display: grid; grid-template-columns: 1fr 52px 1fr; align-items: center; }
.ev-dot { grid-column: 2; grid-row: 1; justify-self: center; z-index: 1; width: 36px; height: 36px; border-radius: 50%; background: #fff; border: 3px solid var(--c); color: var(--c);
  display: grid; place-items: center; font-size: 17px; margin: 14px 0; box-shadow: 0 2px 6px rgba(0, 0, 0, .12); }
.ev-card { background: #fff; border-radius: 14px; padding: 12px 14px; box-shadow: var(--shadow); margin: 4px 0; position: relative; border-top: 3px solid var(--c); transition: transform .15s, box-shadow .15s; }
.ev-card:hover { transform: translateY(-2px); box-shadow: 0 2px 4px rgba(20, 30, 40, .08), 0 14px 30px rgba(20, 30, 40, .12); }
.ev-year { position: relative; z-index: 1; display: flex; justify-content: center; margin: 10px 0 2px; }
.ev-year span { background: var(--slate); color: #fff; font-weight: 800; font-size: 13px; letter-spacing: .06em; border-radius: 999px; padding: 3px 12px; box-shadow: 0 0 0 4px var(--bg); }
.ev-l .ev-card { grid-column: 1; grid-row: 1; text-align: right; }
.ev-r .ev-card { grid-column: 3; grid-row: 1; }
.ev-top { display: flex; gap: 8px; align-items: center; justify-content: space-between; }
.ev-l .ev-top { flex-direction: row-reverse; }
.ev-cat { font-size: 11px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--c); }
.ev-date { font-size: 12px; font-weight: 700; color: var(--ink-soft); }
.ev-title { font-weight: 700; margin-top: 4px; line-height: 1.35; }
.ev-detail { font-size: 14px; color: var(--ink-soft); margin-top: 3px; }
.ev-pages { display: flex; gap: 6px; margin-top: 8px; }
.ev-l .ev-pages { justify-content: flex-end; }
.ev-thumb { width: 44px; height: 58px; }
.cat-accident .ev-dot, .cat-damage .ev-dot { background: var(--red); border-color: var(--red); color: #fff; }
.cat-birth .ev-dot { background: var(--slate); border-color: var(--slate); color: var(--gold); }
.cat-annual .ev-dot { color: var(--green); border-color: var(--green); }
.cat-nnumber .ev-card { outline: 2px dashed var(--c); outline-offset: -2px; }
.chapter-arrival { position: relative; z-index: 1; margin: 0 auto 26px; width: max-content; max-width: 90%; background: #fff; border: 2px solid var(--c); color: var(--ink);
  border-radius: 999px; padding: 6px 16px; font-size: 14px; font-weight: 700; display: flex; gap: 6px; align-items: center; }

/* ownership */
.own { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px 20px; }
.own-status { display: flex; gap: 8px; align-items: center; font-weight: 700; padding: 10px 12px; border-radius: 10px; margin-bottom: 14px; }
.own-status.ok { background: var(--like-bg, #edf8f1); color: #1f6f40; }
.own-status.bad { background: #fdf0ee; color: var(--red); }
.own-chain { list-style: none; margin: 0; padding: 0 0 0 10px; border-left: 3px solid var(--line); display: grid; gap: 12px; }
.own-chain li { display: grid; grid-template-columns: 18px 1fr auto; gap: 10px; align-items: center; margin-left: -19px; }
.own-dot { width: 16px; height: 16px; border-radius: 50%; background: var(--c); box-shadow: 0 0 0 4px #fff; }
.own-chain strong { display: block; }
.own-chain span { font-size: 13px; color: var(--ink-soft); }

/* engine health */
.engine-health { display: grid; gap: 16px; }
.ecard { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px 20px; }
.ecard-head { display: flex; gap: 12px; align-items: center; margin-bottom: 12px; }
.ecard-icon { width: 40px; height: 40px; border-radius: 12px; background: #fff4e0; color: #b87500; display: grid; place-items: center; font-size: 20px; }
.ecard h4 { margin: 0; font-size: 18px; }
.ecard-head p { margin: 2px 0 0; font-size: 13px; color: var(--ink-soft); }
.charts { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); gap: 14px; }
.figure { margin: 0; }
.figure figcaption { font-weight: 700; font-size: 14px; margin-bottom: 4px; }
.legend { display: flex; flex-wrap: wrap; gap: 4px 12px; font-size: 12px; color: var(--ink-soft); margin-bottom: 4px; }
.legend i, .chart-tip i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 5px; vertical-align: -1px; }
.chart-wrap { position: relative; }
.chart { width: 100%; height: auto; display: block; touch-action: pan-y; }
.chart .grid { stroke: #e7ebee; stroke-width: 1; }
.chart .axis { fill: var(--ink-soft); font-size: 11px; }
.chart .line, .spark-svg .line { fill: none; stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.chart .ref, .spark-svg .ref { stroke: var(--red); stroke-width: 1.5; stroke-dasharray: 5 4; }
.chart .ref-label { fill: var(--red); font-size: 11px; font-weight: 700; paint-order: stroke; stroke: var(--card, #fff); stroke-width: 4px; stroke-linejoin: round; }
.chart .cross { stroke: #9aa6b0; stroke-width: 1; }
.chart .cross-dot { stroke: #fff; stroke-width: 2; }
.chart-tip { position: absolute; top: 8px; background: rgba(29, 39, 48, .94); color: #fff; font-size: 12px; border-radius: 8px; padding: 8px 10px; pointer-events: none; min-width: 120px; }
.sparks { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 10px; }
.spark { background: var(--bg); border-radius: 12px; padding: 10px 12px; }
.spark-head { display: flex; justify-content: space-between; align-items: baseline; gap: 6px; font-size: 13px; font-weight: 700; }
.spark-val strong { font-size: 18px; }
.spark-val small { color: var(--ink-soft); font-weight: 600; }
.spark-delta { font-size: 11px; font-weight: 800; margin-left: 6px; }
.spark-delta.up { color: var(--red); }
.spark-delta.down { color: var(--note, #2a78d6); }
.spark-svg { width: 100%; height: 64px; display: block; margin-top: 4px; }
.spark-svg .line { stroke: #2a78d6; }
.spark-svg .pt { fill: #2a78d6; stroke: #fff; stroke-width: 2; }
.table-view { margin-top: 12px; }
.table-view summary { cursor: pointer; font-weight: 700; font-size: 14px; color: var(--accent-dark); }
.table-scroll { overflow-x: auto; margin-top: 8px; }
.table-scroll table { border-collapse: collapse; font-size: 13px; width: 100%; }
.table-scroll th, .table-scroll td { padding: 6px 8px; border-bottom: 1px solid var(--line); text-align: left; white-space: nowrap; }
.table-scroll th { font-size: 11px; text-transform: uppercase; letter-spacing: .05em; color: var(--ink-soft); }
.mono { font-family: ui-monospace, 'SF Mono', Menlo, monospace; }
.lab-comment { margin: 14px 0 0; padding: 10px 14px; background: var(--bg); border-left: 4px solid var(--accent); border-radius: 8px; font-style: italic; color: var(--ink-soft); }
.cyl-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr)); gap: 12px; }
.cyl { border-radius: 14px; padding: 12px; background: var(--bg); border-top: 4px solid var(--green); }
.cyl.watch { border-top-color: var(--amber); }
.cyl.concern { border-top-color: var(--red); }
.cyl-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-bottom: 8px; }
.cyl-badge { display: inline-flex; gap: 4px; align-items: center; font-size: 11px; font-weight: 800; text-transform: uppercase; border-radius: 999px; padding: 2px 8px; }
.cyl-badge.good { background: var(--like-bg, #edf8f1); color: var(--green); }
.cyl-badge.watch { background: #fff4e0; color: #b87500; }
.cyl-badge.concern { background: #fdf0ee; color: var(--red); }
.cyl.unclear { border-top-color: var(--line, #d9dee5); }
.cyl-badge.unclear { background: #eef1f5; color: #5b6573; }
.cyl-frames { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 8px; }
.cyl-frame { position: relative; padding: 0; border: 0; border-radius: 50%; overflow: hidden; aspect-ratio: 1; background: #000; cursor: zoom-in; box-shadow: inset 0 0 0 3px rgba(255, 255, 255, .15); }
.cyl-frame img { width: 100%; height: 100%; object-fit: cover; }
.cyl-frame span { position: absolute; left: 50%; bottom: 9%; transform: translateX(-50%); white-space: nowrap; padding: 2px 7px; border-radius: 999px; background: rgba(10, 20, 35, .72); font-size: 9.5px; font-weight: 800; letter-spacing: .02em; text-transform: uppercase; color: #fff; }
.cyl-frame.unclear img { opacity: .55; filter: grayscale(.6); }
.cyl-frame.unclear span { background: rgba(91, 101, 115, .9); }
.cyl-notes { list-style: none; padding: 0; margin: 8px 0 0; font-size: 13px; }
.cyl-notes li { padding-left: 14px; position: relative; color: var(--ink-soft); }
.cyl-notes li::before { content: '•'; position: absolute; left: 0; }
.cyl-notes li.concern { color: var(--red); font-weight: 600; }

/* every entry, collapsed */
.all-entries { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 14px 18px; }
.ae-head { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.ae-title { font-weight: 800; font-size: 17px; display: inline-flex; gap: 8px; align-items: center; }
.ae-head small { color: var(--ink-soft); flex: 1; }
.entries-tools { display: grid; gap: 10px; margin: 14px 0 6px; }
.entry-search { font: inherit; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; width: 100%; }
.year-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.ychip { border: 1px solid var(--line); background: #fff; border-radius: 999px; padding: 3px 10px; font: inherit; font-size: 13px; font-weight: 700; cursor: pointer; color: var(--ink-soft); }
.ychip.on { background: var(--accent); border-color: var(--accent); color: #fff; }
.entry { display: grid; grid-template-columns: 110px 1fr; gap: 14px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.entry-date { font-weight: 700; font-size: 14px; }
.entry-date small { display: block; font-weight: 400; color: var(--ink-soft); }
.entry-kind { display: inline-block; font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; background: #eef1f4; border-radius: 4px; padding: 1px 6px; margin-right: 6px; }
.entry-work { font-size: 14px; }
.note-line { font-size: 13px; font-weight: 600; margin-top: 3px; padding-left: 16px; position: relative; }
.note-line::before { position: absolute; left: 0; font-weight: 800; }
.note-line.concern { color: var(--red); } .note-line.concern::before { content: '!'; }
.note-line.good { color: var(--green); } .note-line.good::before { content: '✓'; }
.note-line.fyi { color: var(--ink-soft); font-weight: 400; } .note-line.fyi::before { content: 'i'; font-style: italic; }
.entry-src { margin-top: 6px; border: 0; background: #eef8fc; color: var(--accent-dark); font: inherit; font-size: 12px; font-weight: 700; border-radius: 6px; padding: 2px 8px; cursor: pointer; display: inline-flex; gap: 4px; align-items: center; }

@media (max-width: 760px) {
  .hero { padding: 22px 18px 18px; border-radius: 18px; }
  .hero-counts { grid-template-columns: 1fr; }
  .hcount strong { font-size: 28px; }
  .ev { grid-template-columns: 40px 1fr; }
  .chapter-events::before { left: 20px; }
  .ev-year { justify-content: flex-start; }
  .ev-dot { grid-column: 1; }
  .ev-l .ev-card, .ev-r .ev-card { grid-column: 2; text-align: left; }
  .ev-l .ev-top { flex-direction: row; }
  .ev-l .ev-pages { justify-content: flex-start; }
  .chapter-years { font-size: 22px; }
  .fcard { flex-direction: column; }
  .entry { grid-template-columns: 1fr; gap: 2px; }
}
@media print {
  .hero { box-shadow: none; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .group, .chapter-head, .tile, .fcard, .ev-card, .syn-topic { break-inside: avoid; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .all-entries { display: none; }
  .chart-tip { display: none; }
}


/* ---------------------------------------------------------------- landing: how it works, coverage, sample */

.landing { margin-top: 64px; }
.landing h2 { margin-bottom: 18px; }
.how-steps { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.how-step { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 14px 16px 18px; display: flex; flex-direction: column; }
.how-step h3 { margin: 14px 0 6px; font-size: 17px; display: flex; align-items: center; gap: 8px; }
.how-step h3 span { width: 24px; height: 24px; border-radius: 50%; background: var(--accent); color: #fff; font-size: 13px; display: grid; place-items: center; flex: none; }
.how-step p { margin: 0; color: var(--ink-soft); font-size: 14px; }
.how-visual { height: 132px; border-radius: 10px; background: var(--bg); overflow: hidden; position: relative; }

.v-plate { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; }
.mini-plate { background: #fff; border-radius: 6px; border-bottom: 4px solid var(--accent); padding: 3px 14px 1px; font-weight: 800; font-size: 24px; letter-spacing: .06em; box-shadow: var(--shadow); }
.mini-reg { font-size: 12px; color: var(--ink-soft); text-align: center; line-height: 1.4; }

.v-files { display: flex; flex-wrap: wrap; align-content: center; justify-content: center; gap: 5px; padding: 8px; }
.v-files span { background: #fff; border: 1px solid var(--line); border-radius: 6px; padding: 2px 7px; font-size: 11px; white-space: nowrap; }
.v-files span:nth-child(odd) { transform: rotate(-2deg); }
.v-files span:nth-child(3n) { transform: rotate(2deg); }

.v-read { display: grid; grid-template-columns: 74px 1fr; gap: 10px; padding: 10px; }
.v-page { background: #e7ebee; border-radius: 4px; overflow: hidden; box-shadow: var(--shadow); }
.v-page img { width: 100%; height: 100%; object-fit: cover; object-position: top; display: block; }
.v-entry { margin: 0; display: grid; grid-template-columns: auto 1fr; gap: 2px 8px; font-size: 11.5px; align-content: start; overflow: hidden; }
.v-entry dt { color: var(--ink-soft); font-weight: 600; }
.v-entry dd { margin: 0; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; }

.v-report { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; padding: 12px; align-content: center; }
.v-report .t { background: #fff; border-radius: 6px; padding: 4px 8px 4px 22px; font-size: 12px; font-weight: 600; position: relative; }
.v-report .t::before { content: ''; position: absolute; left: 8px; top: 50%; width: 8px; height: 8px; margin-top: -4px; border-radius: 50%; background: var(--c); }
.t.green, .sample-tile.green { --c: var(--green); }
.t.amber, .sample-tile.amber { --c: var(--amber); }
.t.red, .sample-tile.red { --c: var(--red); }

.checks-list { margin-top: 56px; }
.covers { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 230px), 1fr)); gap: 12px 20px; }
.covers > div { border-left: 3px solid var(--accent); padding: 2px 0 2px 14px; }
.covers h3 { margin: 0 0 2px; font-size: 16px; }
.covers p { margin: 0; color: var(--ink-soft); font-size: 14px; }

.sample { margin-top: 56px; }
.sample .lede { margin-bottom: 16px; }
.sample-card { position: relative; max-height: 560px; overflow: hidden; margin-bottom: 18px; }
.sample-card.clipped::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 90px; background: linear-gradient(transparent, var(--card)); }
.sample-headline { font-size: 18px; margin: 0 0 16px; }
.sample-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 200px), 1fr)); gap: 8px; }
.sample-tile { border: 1px solid var(--line); border-left: 4px solid var(--c, var(--line)); border-radius: 8px; padding: 8px 10px; font-size: 14px; }
.sample-status { display: block; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--c); }
.sample-syn { margin-top: 20px; max-width: 760px; }
.sample-syn h3 { margin: 0 0 4px; font-size: 18px; }
.sample-syn h4 { margin: 14px 0 4px; font-size: 15px; }
.sample-syn p { margin: 8px 0; }
.sample-syn ul { margin: 2px 0; padding-left: 20px; }

@media (max-width: 900px) { .how-steps { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .how-steps { grid-template-columns: 1fr; } .landing { margin-top: 44px; } }

/* Lien book */
.liens { margin-top: 18px; }
.liens h3 { margin: 0 0 4px; font-size: 17px; }
.lien-table { overflow-x: auto; }
.lien-table table { border-collapse: collapse; width: 100%; font-size: 14px; }
.lien-table th { text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-soft); padding: 6px 10px 6px 0; border-bottom: 1px solid var(--line); }
.lien-table td { padding: 6px 10px 6px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
.lien-table td.num { font-variant-numeric: tabular-nums; white-space: nowrap; }
.lien-table tr.open td { color: var(--red); }

/* Hover zoom: the page large beside the pointer. */
.zoom-pop { position: fixed; left: 0; top: 0; z-index: 50; pointer-events: none; width: min(560px, 46vw); background: #fff;
  border-radius: 10px; box-shadow: 0 12px 40px rgba(20, 30, 40, .28); overflow: hidden; }
.zoom-pop img { display: block; width: 100%; max-height: 86vh; object-fit: contain; }
.zoom-pop.multi { width: min(calc(var(--n) * 340px), 92vw); display: grid; grid-template-columns: repeat(var(--n), 1fr); gap: 4px; padding: 4px; }
.zoom-pop.multi img { max-height: 80vh; border-radius: 6px; }
#page-viewer .pv-nav { position: absolute; left: 50%; bottom: 14px; transform: translateX(-50%); display: flex; align-items: center; gap: 12px;
  background: rgba(20, 24, 28, .78); color: #fff; border-radius: 999px; padding: 4px 8px; }
#page-viewer .pv-nav[hidden] { display: none; }
#page-viewer .pv-nav button { background: none; border: 0; color: #fff; font-size: 26px; line-height: 1; width: 36px; height: 36px; cursor: pointer; border-radius: 50%; }
#page-viewer .pv-nav button:hover { background: rgba(255, 255, 255, .15); }
.pv-count { font-size: 14px; font-variant-numeric: tabular-nums; min-width: 44px; text-align: center; }
@media print { .zoom-pop { display: none !important; } }

/* Spec-sheet summary */
.spec-times { margin: 16px 0 0; display: grid; gap: 4px; }
.spec-time { display: grid; grid-template-columns: 150px 1fr; gap: 12px; align-items: baseline; padding: 6px 0; border-bottom: 1px solid var(--line); }
.spec-time dt { font-weight: 700; color: var(--ink-soft); font-size: 14px; }
.spec-time dd { margin: 0; }
.spec-time dd strong { font-size: 18px; font-variant-numeric: tabular-nums; }
.spec-weights { display: flex; flex-wrap: wrap; gap: 8px 28px; margin: 16px 0 0; padding: 12px 14px; background: var(--bg); border-radius: 10px; }
.spec-weights dt { font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-soft); }
.spec-weights dd { margin: 0; font-weight: 700; font-variant-numeric: tabular-nums; }
.spec-wb { align-self: end; font-size: 13px; color: var(--ink-soft); }
.spec-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 0 32px; }
.spec-block { margin-top: 20px; }
.spec-block h3 { margin: 0 0 6px; font-size: 16px; padding-bottom: 4px; border-bottom: 2px solid var(--accent); display: inline-block; }
.spec-block ul { margin: 0; padding-left: 20px; }
.spec-block li { margin: 3px 0; }
.spec-removed li { color: var(--ink-soft); }
.spec-removed h3 { border-bottom-color: var(--line); }
.spec-date { display: inline-block; min-width: 64px; font-weight: 700; font-variant-numeric: tabular-nums; margin-right: 6px; }
@media (max-width: 760px) { .spec-cols { grid-template-columns: 1fr; } .spec-time { grid-template-columns: 1fr; gap: 0; } }

/* Report tracing: the last line of the Records tab. */
.tracing { font-size: 14px; color: #000; margin: 32px 0 0; font-family: ui-monospace, Menlo, Consolas, monospace; white-space: pre; overflow-x: auto; }

.guidance { background: var(--card); border-left: 4px solid var(--accent); border-radius: 8px; padding: 12px 16px; margin: -12px 0 22px; font-size: 15px; color: var(--ink-soft); box-shadow: var(--shadow); }
.guidance strong { color: var(--ink); }

.tile-link { display: inline-block; margin-top: 6px; font-size: 13px; font-weight: 600; color: var(--accent-dark); }
#liens { scroll-margin-top: 70px; }

/* Twin engines, side by side */
.spec-twin { width: 100%; border-collapse: collapse; table-layout: fixed; font-size: 15px; }
.spec-twin th { text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-soft); padding: 4px 10px; border-bottom: 1px solid var(--line); }
.spec-twin td { vertical-align: top; padding: 6px 10px; border: 1px solid var(--line); }
.spec-twin tr.both td { background: var(--bg); }
.spec-twin ul { margin: 0; padding-left: 18px; }
@media (max-width: 560px) { .spec-twin { font-size: 14px; } .spec-twin td { padding: 6px; } }

/* report tabs: one part of the report at a time */
.report-tabs { position: sticky; top: 0; z-index: 5; display: flex; gap: 2px; overflow-x: auto; scrollbar-width: none;
  background: rgba(244, 246, 248, .94); backdrop-filter: blur(6px); padding: 10px 0; margin: 0 0 18px; border-bottom: 1px solid var(--line); scroll-margin-top: 0; }
.report-tabs::-webkit-scrollbar { display: none; }
.report-tabs a { text-decoration: none; color: var(--ink-soft); font-weight: 700; font-size: 14px; padding: 7px 11px; border-radius: 999px; white-space: nowrap; }
.report-tabs a:hover { background: #fff; color: var(--ink); }
.report-tabs a.on { background: var(--navy); color: #fff; }
.tab-alert { display: inline-flex; align-items: center; justify-content: center; min-width: 18px; height: 18px; padding: 0 6px; box-sizing: border-box; margin-left: 6px; border-radius: 999px; font-size: 12px; font-weight: 900; color: #fff; vertical-align: 1px; font-variant-numeric: tabular-nums; }
.tab-alert.red { background: var(--red); }
.tab-alert.amber { background: var(--orange); }
.report-tabs a.on .tab-alert { box-shadow: 0 0 0 2px #fff; }
.tab-panel > .rsection:first-child { margin-top: 6px; }
.tab-panel[hidden] { display: none; }
.comp-times { margin-bottom: 18px; }
.comp-times .spec-times { margin: 0; }
.comp-notes { margin: 14px 0 0; padding-left: 20px; }
.comp-notes li { margin: 4px 0; }
.comp-block { margin: 0 0 22px; }
.comp-block > h3 { font-size: 18px; margin: 0 0 10px; }
.comp-cards { padding: 0; }
/* "dir-" (directive), not "ad-": ad blockers hide elements whose class starts with "ad-". */
.dir-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 230px), 1fr)); gap: 8px; }
.dir-row { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; text-align: left; font: inherit; cursor: pointer;
  background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 8px 12px; }
.dir-row:hover { border-color: var(--accent); }
.dir-row strong { font-size: 15px; }
.dir-row span { font-size: 13px; color: var(--ink-soft); }
.entry-kind.side { background: var(--navy); color: #fff; }
@media print {
  .report-tabs { display: none; }
  .tab-panel[hidden] { display: block; }
}

/* summary and part tabs: dated cards, older history folded */
.groups-older { margin: -10px 4px 0; }
.older-cards { margin-top: 12px; }
.older-cards > summary { cursor: pointer; font-weight: 700; color: var(--ink-soft); padding: 6px 0; }
.older-cards .fcard { opacity: .82; }
.spec-block li.strong, .comp-notes li.strong, .spec-twin li.strong { font-weight: 800; }

/* ADs: one line each */
.dir-table { overflow-x: auto; background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 8px 14px 10px; }
.dir-table table { border-collapse: collapse; width: 100%; font-size: 14px; }
.dir-table th { text-align: left; font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-soft); padding: 8px 10px 6px 0; border-bottom: 1px solid var(--line); }
.dir-table td { padding: 7px 10px 7px 0; border-bottom: 1px solid var(--line); vertical-align: middle; }
.dir-table td.dir-no { font-weight: 800; white-space: nowrap; font-variant-numeric: tabular-nums; }
.dir-table td.dir-no a { color: inherit; }
.dir-table td small { color: var(--ink-soft); }
.dir-table tr.na td { color: var(--ink-soft); }
.dir-table tr.bad .dir-status { color: var(--red); font-weight: 700; }
.dir-type { white-space: nowrap; font-weight: 700; }
.dir-type.rec { color: var(--orange); }
.dir-type.unk { color: var(--ink-soft); font-weight: 400; }
.dir-table .entry-src { margin: 0; }
.dir-table p { margin: 8px 0 0; }

/* ownership: the stretch the FAA file does not cover */
.own-chain li.own-gap .own-dot { background: #fff; border: 2px dashed var(--ink-soft); box-shadow: 0 0 0 4px #fff; width: 12px; height: 12px; }
.own-chain li.own-gap strong { color: var(--ink-soft); }
.records-files { margin-top: 26px; }
@media print {
  .older-cards > *:not(summary) { display: grid; }
}
.own-stale { align-items: flex-start; font-weight: 400; }
.own-stale strong { font-weight: 800; }
.own-stale .icon { flex: none; margin-top: 3px; }

/* welcome: price and the optional beta access code */
.welcome { display: grid; grid-template-columns: 1.4fr 1fr; gap: 22px; align-items: center; margin: 0 0 26px; padding: 20px 22px; }
.welcome h2 { margin: 2px 0 6px; font-size: 22px; }
.welcome p { margin: 0; color: var(--ink-soft); }
.welcome-kicker { display: inline-block; font-size: 11px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; background: var(--amber); color: #fff; border-radius: 4px; padding: 2px 7px; }
.code-form label { display: block; font-weight: 700; font-size: 14px; margin-bottom: 6px; }
.code-row { display: flex; gap: 8px; }
.code-row input { flex: 1; min-width: 0; font: inherit; font-family: ui-monospace, Menlo, monospace; letter-spacing: .06em; text-transform: uppercase; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; }
.code-msg { margin: 8px 0 0; font-size: 14px; font-weight: 700; }
.code-msg.ok { color: var(--green); }
.code-msg.bad { color: var(--red); }
@media (max-width: 760px) { .welcome { grid-template-columns: 1fr; } }

/* the FAA records (CARES) card on the logbooks step */
.cares-card { margin: 16px 0; padding: 18px 20px; border-left: 5px solid var(--amber); }
.cares-card.good { border-left-color: var(--green); }
.cares-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; }
.cares-head h3 { margin: 0; font-size: 18px; }
.cares-badge { font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; color: var(--amber); }
.cares-card.good .cares-badge { color: var(--green); }
.cares-card > p { margin: 8px 0; color: var(--ink-soft); }
.cares-open { margin: 4px 0 10px; }
.cares-steps { margin: 0 0 12px; padding-left: 22px; }
.cares-steps li { margin: 4px 0; }
.cares-drop { display: block; border: 2px dashed var(--line); border-radius: 12px; padding: 16px; text-align: center; cursor: pointer; color: var(--ink-soft); font-weight: 600; }
.cares-drop.over, .cares-drop:hover { border-color: var(--accent); background: #f3fafd; }
.cares-results { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 6px; font-size: 14px; }
.cares-results li { padding: 8px 12px; border-radius: 8px; background: #f4f6f8; }
.cares-results li.current { background: #edf8f1; color: #1f6f40; }
.cares-results li.stale, .cares-results li.other-aircraft { background: #fdf0ee; color: var(--red); }
.cares-results li.airworthiness { background: #eef4fc; }
.start-note { margin: 8px 0 0; text-align: center; }

/* the landing sample's tab strip: the report's tabs as links into the full sample, not sticky */
.sample-tabs { margin: -4px 0 14px; }
.sample-tabs .report-tabs { position: static; background: none; backdrop-filter: none; padding: 0 0 10px; margin: 0; }
.sample-tabs .report-tabs { --navy: #12324a; }

/* why us (top of the first screen) and the story (lower on the landing page) */
.why-us { margin: 0 0 18px; padding: 16px 20px; border-left: 4px solid var(--accent); background: #fff; border-radius: 0 var(--radius) var(--radius) 0; box-shadow: var(--shadow); }
.why-us h2 { margin: 0 0 6px; font-size: 20px; }
.why-us p { margin: 0; color: var(--ink); line-height: 1.55; }
.why-us a { font-weight: 700; white-space: nowrap; }
.story { margin-top: 56px; scroll-margin-top: 20px; }
.story h2 { margin-bottom: 10px; }
.story p { line-height: 1.65; margin: 0 0 12px; }

/* the tail number: a green start cue, and the lookup's quiet status line */
.plate-label.start-here { color: var(--green); font-size: 20px; font-weight: 800; letter-spacing: .04em; }
.plate-label.start-here::before { content: '▶ '; }
.n-status { align-self: center; color: var(--ink-soft); font-size: 14px; }

/* the CARES checklist: one box per download */
.cares-checklist { list-style: none; margin: 0 0 12px; padding: 0; display: grid; gap: 6px; }
.cares-checklist li { display: flex; gap: 10px; align-items: flex-start; }
.cares-checklist small { display: block; color: var(--ink-soft); font-size: 12px; }
.cares-checklist .box { flex: none; width: 20px; height: 20px; margin-top: 1px; border: 2px solid var(--line); border-radius: 5px; display: grid; place-items: center; font-size: 13px; font-weight: 900; color: #fff; }
.cares-checklist li.done .box { background: var(--green); border-color: var(--green); }
.cares-checklist li.done .box::after { content: '✓'; }
.cares-checklist li.warn .box { background: var(--orange); border-color: var(--orange); }
.cares-checklist li.warn .box::after { content: '!'; }

/* Terms and privacy pages, and the footer that links to them. */
.legal { max-width: 760px; padding-top: 36px; }
.legal h2 { font-size: 20px; margin-top: 28px; }
.legal p, .legal li { line-height: 1.6; }
.site-footer { max-width: 1040px; margin: 0 auto; padding: 24px 16px 40px; border-top: 1px solid var(--line); font-size: 14px; color: var(--ink-soft); }
.site-footer a { color: inherit; }
.site-footer span { float: right; }
.site-footer .textron-idiots { clear: both; margin: 16px 0 0; font-size: 12px; line-height: 1.5; }
@media (max-width: 760px) { .site-footer span { float: none; display: block; margin-top: 6px; } }

/* Reports started on this device, above the tail-number form. */
.recent { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 14px; margin: 0 0 20px; font-size: 15px; }
.recent ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 18px; }
.recent a { font-weight: 700; color: var(--accent-dark); }
