/* Electric boat page: the two interactive diagrams only (system arrangement and test plan).
   Everything else comes from site.css. */

/* ---------- Tabs shared by both explorers ---------- */

.tabs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-bottom: 1px solid var(--line);
}
.tabs button {
  position: relative;
  display: flex;
  align-items: baseline;
  gap: 8px;
  min-height: 48px;
  padding: 12px 16px 12px 0;
  border: 0;
  border-radius: 0;
  background: none;
  color: var(--muted);
  font-size: 14px;
  text-align: left;
}
.tabs button .step { font: 400 12px/1.4 var(--mono); color: var(--muted); }
.tabs button::after {
  content: "";
  position: absolute;
  left: 0;
  right: 16px;
  bottom: -1px;
  height: 2px;
  background: transparent;
}
.tabs button:hover { color: var(--ink); }
.tabs button:hover::after { background: var(--line-strong); }
.tabs button[aria-pressed="true"] { color: var(--ink); }
.tabs button[aria-pressed="true"]::after { background: var(--accent); }

.tab-panel {
  display: grid;
  grid-template-columns: repeat(8, minmax(0, 1fr));
  column-gap: var(--gutter);
  row-gap: 12px;
  padding-top: 24px;
  min-height: 168px;
  align-content: start;
}
.tab-panel h3 { grid-column: 1 / 4; }
.tab-panel p { grid-column: 4 / 9; color: var(--ink-2); max-width: 62ch; }
.tab-panel .question { font-size: 14px; color: var(--muted); }

/* ---------- System arrangement ---------- */

.system-drawing { padding: 16px; background: var(--surface); color: var(--ink-2); }
.system-drawing svg { width: 100%; height: auto; }
.water-line { stroke: #8bb8c7; stroke-dasharray: 9 8; fill: none; opacity: .7; }
.diagram-label { fill: var(--muted); font: 12px var(--mono); letter-spacing: .06em; }
.water-label { fill: #8bb8c7; }
.hull-shape { fill: #a9b6ad25; stroke: #a9b6ad; stroke-width: 2; }
.foil-line { stroke: #a9b6ad; stroke-width: 6; }
.foil-wing { stroke: #a9b6ad; stroke-width: 8; fill: none; }
.wand { stroke: #a9b6ad; stroke-width: 3; }
.mount-shape { fill: var(--accent); stroke: var(--accent); }
.motor-support { stroke: var(--accent); stroke-width: 10; }
.motor-shape { fill: var(--accent); stroke: var(--accent); stroke-width: 2; }
.prop-line { stroke: var(--accent); stroke-width: 4; }
.battery-shape { fill: #d6bc7a22; stroke: #d6bc7a; stroke-width: 2; }
.battery-symbol { stroke: #d6bc7a; stroke-width: 2; }
.power-route { stroke: #d6bc7a; stroke-width: 2; fill: none; stroke-dasharray: 5 6; }
.control-shape { stroke: #9dbacb; stroke-width: 2; fill: #9dbacb22; }
.control-route { stroke: #9dbacb; stroke-width: 2; fill: none; stroke-dasharray: 3 5; }
.subsystem { opacity: .28; transition: opacity 200ms; }
.system-explorer[data-system="hull"] .subsystem-hull,
.system-explorer[data-system="propulsion"] .subsystem-propulsion,
.system-explorer[data-system="energy"] .subsystem-energy,
.system-explorer[data-system="controls"] .subsystem-controls { opacity: 1; }
.diagram-markers circle { fill: var(--surface); stroke: var(--muted); stroke-width: 1.5; }
.diagram-markers text { fill: var(--ink); font: 14px var(--mono); text-anchor: middle; }

/* ---------- Controls proposal ---------- */

.controls-well { aspect-ratio: 1200 / 880; }
.controls-well picture { display: block; width: 100%; height: 100%; }
@media (max-width: 700px) {
  .controls-well { aspect-ratio: 360 / 990; }
}

@media (max-width: 900px) {
  .tab-panel { grid-template-columns: 1fr; }
  .tab-panel h3, .tab-panel p { grid-column: 1 / -1; }
}
@media (max-width: 700px) {
  .tabs { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .system-drawing { padding: 8px; }
  .diagram-label { display: none; }
  .tab-panel { min-height: 216px; }
}
@media (prefers-reduced-motion: reduce) {
  .subsystem { transition: none; }
}

/* Conversion overview */
.conversion-steps { display: grid; gap: 32px; }
.conversion-step { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: center; gap: 24px; }
.conversion-step img { display: block; width: 100%; height: auto; border-radius: 4px; }
.conversion-step p { margin-top: 8px; color: var(--ink-2); }
@media (max-width: 700px) {
  .conversion-step { grid-template-columns: minmax(0, 1fr); gap: 12px; }
}
