:root {
  color-scheme: light;
  --ink: #102538;
  --body: #415568;
  --muted: #587389;
  --line: #d9e4ec;
  --teal: #087669;
  --mint: #b8f5e0;
  --paper: #f5f8fa;
  --white: #fff;
  font-family: "Hiragino Sans", "Yu Gothic", "Noto Sans CJK JP", system-ui, sans-serif;
  color: var(--ink);
  background: var(--paper);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; line-height: 1.75; }
a { color: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a:focus-visible, [tabindex]:focus-visible { outline: 3px solid #39a99a; outline-offset: 5px; }
h1, h2, h3, p { margin: 0; }
h1, h2, h3 { overflow-wrap: anywhere; word-break: auto-phrase; text-wrap: balance; }
ul, ol, dl, dd { margin: 0; }
.frame { width: min(71rem, calc(100% - 3rem)); margin-inline: auto; }
.skip-link { position: absolute; inset: .8rem auto auto .8rem; z-index: 5; transform: translateY(-180%); background: white; padding: .5rem 1rem; }
.skip-link:focus { transform: none; }
.site-header { color: #e4eef4; background: var(--ink); border-bottom: 1px solid #2b4256; }
.header-row { min-height: 4.25rem; display: flex; align-items: center; justify-content: space-between; gap: .75rem 1.5rem; flex-wrap: wrap; padding-block: .75rem; }
.brand { display: inline-flex; align-items: center; gap: .6rem; font-size: .92rem; font-weight: 700; text-decoration: none; white-space: nowrap; }
.brand-mark { width: .84rem; height: .84rem; border: 2px solid var(--mint); transform: rotate(45deg); display: inline-block; }
.header-row nav { display: flex; align-items: center; gap: .4rem clamp(.8rem, 3vw, 2rem); flex-wrap: wrap; font-size: .88rem; }
.header-row nav a { text-decoration: none; white-space: nowrap; }
.header-row nav a:hover { color: var(--mint); text-decoration: underline; text-underline-offset: .45em; }
.map-intro { color: #fff; background: #102538; padding-block: clamp(1.35rem, 5vw, 3.1rem); }
.map-intro h1 { font-size: clamp(1.7rem, 4vw, 3.25rem); line-height: 1.25; letter-spacing: -.025em; }
.map-intro p { margin-top: .85rem; color: #c8dbe8; }
.map-section { padding-block: clamp(1.1rem, 4vw, 3rem); }
.map-layout { display: grid; grid-template-columns: minmax(0, 2.1fr) minmax(0, 1fr); gap: 1.1rem; align-items: start; }
.map-board { display: grid; gap: .42rem; min-width: 0; }
.map-columns, .map-lane { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(.55rem, 1.8vw, 1.2rem); }
.map-columns { color: #465a69; font-size: .875rem; font-weight: 750; padding: .3rem .75rem; }
.map-lane { padding: .45rem .75rem; border: 1px solid var(--line); border-radius: .55rem; text-decoration: none; background: white; }
.map-lane:hover, .map-lane[aria-current="true"] { border-color: #309488; background: #edf8f5; }
.map-lane[aria-current="true"] .lane-system { background: #0e685e; color: white; }
.map-lane > span {
  position: relative; display: flex; align-items: center; justify-content: center; min-height: 3.1rem;
  padding: .42rem .3rem; border-radius: .3rem; text-align: center; line-height: 1.4;
  font-size: .875rem; font-weight: 650; word-break: auto-phrase; text-wrap: balance; overflow-wrap: anywhere;
}
.lane-input { color: #394c69; background: #edf2f7; }
.lane-system { color: #124c45; background: #daf0e9; }
.lane-output { color: #394c69; background: #edf2f7; }
.lane-input::after, .lane-system::after {
  content: ""; position: absolute; left: 100%; top: 50%; width: clamp(.55rem, 1.8vw, 1.2rem);
  background: #98abbd; height: 1px;
}
.map-details { position: sticky; top: 1rem; min-width: 0; margin-top: 1.9rem; }
.map-detail { scroll-margin-top: 1rem; padding: clamp(.9rem, 2.5vw, 1.5rem); background: white; border: 1px solid var(--line); border-top: 4px solid #0e685e; border-radius: .6rem; }
.map-detail + .map-detail { margin-top: .8rem; }
.map-detail[hidden] { display: none; }
.map-detail h2 { font-size: clamp(1.2rem, 2.25vw, 1.7rem); line-height: 1.45; }
.detail-tech { margin: .35rem 0 1rem; font-size: .875rem; color: #23645a; font-weight: 650; }
.map-detail dl { display: grid; gap: .95rem; }
.map-detail dt, .operations dt { font-size: .95rem; font-weight: 700; }
.map-detail dd, .operations dd { color: var(--body); line-height: 1.75; }
.operations { background: #e7f0f3; border-block: 1px solid #d5e2e9; }
.operations-grid { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 2.2fr); gap: 1.3rem 3rem; padding-block: clamp(2.6rem, 6vw, 5rem); }
.operations dl { display: grid; gap: 1.3rem; }
.operations dt { font-size: 1.08rem; }
.site-footer { display: flex; flex-wrap: wrap; gap: .4rem 1.2rem; justify-content: space-between; align-items: baseline; padding-block: 1.4rem; color: var(--muted); font-size: .88rem; }
.site-footer small { font-size: .82rem; }
@media (max-width: 52rem) {
  .map-layout, .operations-grid { grid-template-columns: minmax(0, 1fr); }
  .map-details { position: static; margin-top: 0; }
}
@media (max-width: 34rem) {
  .frame { width: calc(100% - 1.6rem); }
  .header-row { justify-content: flex-start; }
  .header-row nav { width: 100%; }
  .map-columns, .map-lane { padding-inline: .4rem; }
  .map-lane > span { font-size: .81rem; min-height: 3.2rem; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
