* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: #222; background: #fff; font-family: Arial, Helvetica, sans-serif; font-size: 15px; line-height: 1.55; }
main { max-width: 1220px; margin: 36px auto 48px; padding: 0 28px; }
header { border-bottom: 1px solid #ccc; padding-bottom: 18px; }
h1 { margin: 0 0 12px; font-size: 28px; font-weight: 600; line-height: 1.3; }
h2 { margin: 0 0 10px; font-size: 22px; font-weight: 600; }
h3 { margin: 0; font-size: 17px; font-weight: 600; }
p { margin: 0 0 15px; }
a { color: #225ba2; text-underline-offset: 2px; }
button, select { font: inherit; font-size: 13px; color: #222; }
button { padding: 5px 10px; border: 1px solid #aaa; border-radius: 2px; background: #f7f7f7; cursor: pointer; line-height: 1.4; }
button:hover { background: #ececec; }
button:disabled { opacity: .6; cursor: wait; }
button[aria-pressed="true"] { border-color: #444; background: #e5e5e5; }
button:focus-visible, select:focus-visible, a:focus-visible, video:focus-visible { outline: 2px solid #225ba2; outline-offset: 3px; }
select { padding: 4px 6px; background: #fff; border: 1px solid #aaa; border-radius: 2px; }
.page-controls, .toolbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
nav { display: flex; gap: 22px; font-size: 14px; }
section { margin-top: 28px; scroll-margin-top: 18px; }
.toolbar { margin: 16px 0; font-size: 13px; }
.actions, .view-switch { display: flex; align-items: center; gap: 8px; }
.toolbar label { display: flex; align-items: center; gap: 8px; white-space: nowrap; }
.simulation-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.simulation-grid .method-heading { justify-content: center; margin-bottom: 9px; }
.method-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 10px; }
.method-block { min-width: 0; }
.video-figure { margin: 0; min-width: 0; }
.view-label { margin: 0 0 6px; font-size: 14px; }
.video-stage { position: relative; background: #111; line-height: 0; }
video { display: block; width: 100%; height: auto; aspect-ratio: 16/9; object-fit: contain; background: #111; border: 1px solid #ddd; }
.simulation-grid video { aspect-ratio: 4/3; }
.video-caption { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-top: 5px; color: #666; font-size: 12px; }
.hardware-grid { display: grid; gap: 26px; }
.camera-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.hardware-grid[data-layout="front"], .hardware-grid[data-layout="side"] { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.hardware-grid:not([data-layout="both"]) .camera-grid { grid-template-columns: 1fr; }
.hardware-grid:not([data-layout="both"]) .method-heading { flex-wrap: wrap; }
.hardware-grid [hidden] { display: none !important; }
.note { margin-top: 16px; color: #555; font-size: 13px; }
.status { margin: 10px 0 0; color: #555; font-size: 12px; }
.status:empty { display: none; }
.skip-link { position: absolute; top: -50px; left: 20px; padding: 8px; background: white; }
.skip-link:focus { top: 5px; }
.video-error { position: absolute; inset: 0; display: grid; place-items: center; background: #222; padding: 20px; color: white; text-align: center; line-height: 1.5; font-size: 13px; }
.video-error a { display: block; color: white; }
noscript p { margin: 20px; }
@media (max-width: 760px) {
  main { margin-top: 24px; padding: 0 18px; }
  h1 { font-size: 25px; }
  h2 { font-size: 20px; }
  .simulation-grid, .hardware-grid[data-layout="front"], .hardware-grid[data-layout="side"] { grid-template-columns: 1fr; gap: 22px; }
  .simulation-grid .method-heading { justify-content: flex-start; }
}
@media (max-width: 540px) {
  body { font-size: 14px; }
  .camera-grid { grid-template-columns: 1fr; gap: 16px; }
  .page-controls { flex-wrap: wrap; gap: 12px; }
  .toolbar { align-items: flex-start; flex-wrap: wrap; gap: 12px; }
  .method-heading { flex-wrap: wrap; }
  nav { gap: 16px; font-size: 13px; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
