@font-face { font-family: "Work Sans"; src: url("work-sans.woff2") format("woff2"); font-weight: 400 800; font-display: swap; }
:root {
  color-scheme: light;
  font-family: "Work Sans", sans-serif;
  color: #161f28;
  background: #f1f5f7;
  --paper: #fff;
  --line: #ced9e1;
  --muted: #465563;
  --accent: #0b5481;
  --deep: #103149;
  --pale: #e5f2f9;
  --radius: 10px;
}
* { box-sizing: border-box; }
body { margin: 0; font-size: 1rem; line-height: 1.45; }
button, input, select { font: inherit; }
button, select { cursor: pointer; }
button:disabled, select:disabled { cursor: default; opacity: .55; }
a { color: var(--accent); text-underline-offset: .17em; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid #a44d04; outline-offset: 3px; }
[hidden] { display: none !important; }
p, h1, h2, h3, h4, ul { margin: 0; }
.shell { width: min(1200px, calc(100% - 64px)); margin-inline: auto; }
.masthead { background: var(--paper); border-bottom: 1px solid var(--line); }
.topbar { min-height: 62px; display: flex; gap: 20px; justify-content: space-between; align-items: center; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--deep); font-weight: 750; text-decoration: none; white-space: nowrap; }
.brand-symbol { display: grid; width: 29px; height: 29px; place-items: center; background: var(--deep); color: white; border-radius: 6px; font-size: 1.2rem; }
.topbar nav { display: flex; align-items: center; gap: 22px; font-size: .9rem; }
.topbar nav a { font-weight: 630; text-decoration: none; }
.topbar nav a:hover { text-decoration: underline; }
.text-button { border: 0; background: none; color: var(--accent); padding: 5px 0; font-weight: 650; font-size: .87rem; }
.text-button:hover { text-decoration: underline; }
.entry { background: #e5f1fa; border-bottom: 1px solid #cadbe8; padding: 32px 0 27px; }
h1 { font-size: clamp(2.4rem, 5vw, 4.2rem); line-height: .98; letter-spacing: -.065em; color: var(--deep); }
#search { display: flex; gap: 8px; max-width: 650px; margin: 18px 0 13px; }
#query, #spare { min-width: 0; width: 100%; color: #202c36; background: var(--paper); border: 1px solid #9aaebe; border-radius: 7px; padding: 9px 11px; }
#query::placeholder { color: #516270; }
.primary, .secondary { min-height: 42px; padding: 8px 13px; border-radius: 7px; font-weight: 650; }
.primary { background: var(--deep); border: 1px solid var(--deep); color: white; white-space: nowrap; }
.primary:hover { background: var(--accent); }
.secondary { background: var(--paper); color: var(--accent); border: 1px solid #9db3c4; }
.secondary:hover { background: var(--pale); }
.goals { display: flex; flex-wrap: wrap; gap: 7px; }
.goals a { background: #f8fcff; border: 1px solid #aec4d5; border-radius: 5px; text-decoration: none; padding: 5px 10px; font-size: .86rem; }
.goals a[aria-current] { background: #d1e5f3; color: #143f5e; font-weight: 680; }
#search-results { list-style: none; padding: 0 0 12px; }
#search-results li { padding: 4px 0; }
.workspace { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr); gap: 26px; align-items: start; margin-top: 27px; }
.goal-header h2 { font-size: clamp(1.6rem, 3vw, 2.6rem); color: var(--deep); line-height: 1.05; letter-spacing: -.045em; }
.goal-header p { margin-top: 8px; color: var(--muted); }
.context { padding: 13px 15px; background: #e8eff3; border-radius: 7px; margin: 17px 0 23px; }
.context strong { display: block; color: var(--deep); margin-bottom: 3px; }
.context p { font-size: .87rem; color: var(--muted); }
.tags { display: flex; list-style: none; padding: 8px 0 0; gap: 12px; flex-wrap: wrap; font-size: .76rem; color: var(--accent); }
.section-title { margin-bottom: 10px; color: var(--deep); font-size: 1.18rem; }
#options { display: grid; gap: 9px; }
.option { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 11px 15px; }
.option.selected { background: #f2faff; border-color: #6287a0; }
.option-kind, .small-heading { color: #345c74; text-transform: uppercase; letter-spacing: .055em; font-size: .72rem; font-weight: 720; }
.option h4 { font-size: 1.02rem; line-height: 1.2; margin: 4px 0; }
.option p { color: var(--muted); font-size: .87rem; }
.option-actions { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 7px; }
.option-summary { font-size: .82rem; color: #345468; font-weight: 650; }
.option .secondary { min-height: 35px; padding: 4px 10px; font-size: .82rem; }
.option.selected .secondary { color: #fff; background: var(--deep); }
.sidebar { display: grid; gap: 12px; scroll-margin-top: 12px; }
.panel { border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); padding: 15px 17px; }
.panel-header { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.panel-header h2 { font-size: 1.19rem; letter-spacing: -.025em; color: var(--deep); }
.caption, .inventory-kind { color: var(--muted); font-size: .81rem; }
.inventory .caption { margin: 4px 0 8px; }
.small-heading { margin: 10px 0 2px; }
.inventory-list, .parts-list { list-style: none; padding: 0; }
.inventory-list li, .parts-list li { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 5px 0; border-bottom: 1px solid #e6edf2; font-size: .83rem; }
.inventory-kind { text-align: right; font-size: .72rem; }
.remove { background: none; color: var(--accent); border: none; min-height: 24px; padding: 2px 0; font-size: .78rem; }
.remove:hover { text-decoration: underline; }
#add-spare { display: flex; gap: 6px; margin-top: 9px; }
#spare { font-size: .86rem; min-height: 42px; }
.plan-name { margin-top: 5px; font-weight: 620; font-size: .88rem; }
.summary { display: inline-block; background: var(--pale); color: #153f5a; font-size: .78rem; font-weight: 680; padding: 3px 6px; margin: 5px 0 3px; border-radius: 4px; }
.part-state { flex-shrink: 0; max-width: 45%; text-align: right; font-size: .74rem; font-weight: 650; }
.owned { color: #245644; }
.missing, .confirm { color: #82460a; }
details { border-top: 1px solid #e6edf2; padding: 7px 0; font-size: .84rem; }
summary { cursor: pointer; color: var(--accent); font-weight: 650; }
details p { margin: 5px 0; }
details ul { padding-left: 18px; }
.buy-links li { margin: 5px 0; }
.buy-links small, .buy-links a { display: block; }
.fit { font-size: .81rem; color: var(--muted); margin-block: 7px; }
.setup { display: block; padding-bottom: 7px; font-size: .85rem; font-weight: 640; }
.footer { margin: 20px auto; padding: 11px 0; border-top: 1px solid var(--line); color: var(--muted); font-size: .77rem; }
dialog { width: min(620px, calc(100% - 28px)); max-height: 85dvh; border: 1px solid var(--line); border-radius: 14px; padding: 20px; color: #161f28; }
dialog::backdrop { background: #182e45a6; }
dialog > p { margin-top: 8px; color: var(--muted); }
.device { border-top: 1px solid var(--line); padding: 10px 0; }
.device h3 { font-size: 1rem; }
.device p, .device ul, .device a { font-size: .86rem; }
.device ul { padding-left: 18px; }
.visually-hidden, .skip:not(:focus) { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip:focus { display: block; padding: 7px; background: white; }
@media (max-width: 750px) {
  .workspace { grid-template-columns: 1fr; gap: 14px; }
  .shell { width: calc(100% - 32px); }
  .entry { padding-block: 23px 19px; }
}
@media (max-width: 400px) {
  .topbar { gap: 8px; align-items: start; padding-block: 8px; }
  .topbar nav { flex-direction: column; align-items: end; gap: 0; }
  .topbar nav a, .text-button { min-height: 26px; }
  #search { gap: 4px; }
  .primary { padding-inline: 8px; font-size: .88rem; }
  .panel { padding: 12px; }
}
@media print {
  :root { background: white; }
  .masthead, .entry, .options, .inventory, .footer, #print, .skip, dialog { display: none; }
  .workspace, .sidebar { display: block; width: 100%; margin: 0; }
  .plan { border: 0; }
  .plan .test > p { display: block; }
}

.inventory-toggle { display: flex; align-items: center; gap: 7px; margin: 5px 0; font-size: .79rem; color: var(--muted); }
.plan-check { border: 1px solid var(--line); border-radius: 7px; margin: 8px 0; padding: 6px 10px 8px; display: grid; gap: 5px; font-size: .82rem; }
.plan-check select, #region { font-size: .82rem; width: 100%; border: 1px solid #9aaebe; padding: 6px; border-radius: 5px; background: white; color: #243442; }
.plan-check legend { font-weight: 650; color: var(--deep); }
.link-meta { margin: 7px 0; font-size: .76rem; color: var(--muted); }
.link-meta a + a { margin-left: 9px; }
.tags button { background: transparent; border: 0; color: var(--accent); padding: 0; text-decoration: underline; }
.device .secondary { margin-top: 7px; font-size: .83rem; }
.device .device-links { margin: 5px 0; }
.device-detail { margin-block: 10px; }
#planner-fallback { padding-bottom: 10px; }
.plan-jump { display: none; }
@media (max-width: 750px) { .plan-jump { display: inline-block; margin-top: 12px; font-weight: 620; } }
@media print {
  #share-plan, .plan-check select, .device-jump { display: none; }
  details::details-content { content-visibility: visible; }
  .parts-list li a { color: inherit; text-decoration: none; }
}

.select-plan { display: inline-flex; align-items: center; text-decoration: none; }
#catalogue-intro { margin-bottom: 9px; }

.print-goal { display: none; }
@media print { .print-goal { display: block; } .plan-check label { display: none; } }

.fixture-note { display: block; font-size: .71rem; color: var(--muted); }
.setup-preview { display: block; padding-bottom: 7px; font-size: .85rem; }
