.study-bench {
  --study-ink: #20211c;
  --study-muted: #585b52;
  --study-rule: #d3d4ca;
  --study-accent: #aa701e;
  --study-mono:
    "IBM Plex Mono", ui-monospace, SFMono-Regular, Consolas, monospace;
  width: 100%;
  min-width: 0;
  color: var(--study-ink);
  background: #fff;
  scroll-margin-top: 5rem;
}
.study-bench *,
.study-bench *::before,
.study-bench *::after {
  box-sizing: border-box;
}
.study-bench button,
.study-bench a {
  font: inherit;
  color: inherit;
  touch-action: manipulation;
}
.study-bench button {
  background: #fff;
  cursor: pointer;
  letter-spacing: normal;
}
.study-bench :is(button, a):focus-visible {
  outline: 2px solid var(--study-accent);
  outline-offset: 3px;
}
.study-tabs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-block: 1px solid var(--study-rule);
}
.study-tabs button {
  min-height: 52px;
  display: flex;
  gap: 0.6em;
  align-items: center;
  justify-content: center;
  padding: 12px 8px;
  position: relative;
  color: var(--study-muted);
  border: 0;
  font-size: clamp(0.83rem, 1.25vw, 1.03rem);
  font-weight: 500;
  line-height: 1.2;
}
.study-tabs button + button {
  border-left: 1px solid var(--study-rule);
}
.study-tabs button[aria-selected="true"] {
  color: var(--study-ink);
}
.study-tabs button[aria-selected="true"]::after {
  content: "";
  height: 2px;
  position: absolute;
  bottom: -1px;
  left: 0;
  right: 0;
  background: var(--study-ink);
}
.study-tabs button[aria-selected="true"] svg {
  color: var(--study-accent);
}
.study-tabs button:hover,
.study-choices button:hover,
.study-steps button:hover,
.study-next:hover,
.study-explode:hover {
  color: var(--study-accent);
}
.study-tabs svg,
.study-next svg,
.study-explode svg {
  width: 1.13em;
  height: 1.13em;
  flex: none;
  stroke: currentColor;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.25;
}
.study-sheet {
  display: grid;
  grid-template-columns: minmax(0, 1.72fr) minmax(270px, 1fr);
  border-bottom: 1px solid var(--study-rule);
  background: #fff;
}
.study-figure {
  margin: 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: white;
  border-right: 1px solid var(--study-rule);
  padding: clamp(0.6rem, 2vw, 1.6rem);
}
.study-plate {
  flex: 1;
  display: grid;
  place-items: center;
  min-width: 0;
  min-height: 0;
  background: #fff;
}
.study-plate > svg {
  display: block;
  width: 100%;
  height: auto;
  max-height: 415px;
  overflow: visible;
}
.study-part {
  cursor: pointer;
}
.study-part.is-current {
  --part-ink: var(--study-accent);
}
.study-figure figcaption {
  display: flex;
  align-items: baseline;
  gap: 0.95rem;
  padding: 0.8rem 0 0.3rem;
  border-top: 1px solid var(--study-rule);
  font-size: 0.76rem;
  line-height: 1.4;
  color: var(--study-muted);
  letter-spacing: normal;
}
.study-fig-id,
.study-boundary,
.study-steps button {
  font-family: var(--study-mono);
}
.study-fig-id {
  color: var(--study-ink);
  font-size: 0.65rem;
  white-space: nowrap;
}
.study-inspection {
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: clamp(1.1rem, 2.6vw, 2.6rem);
  background: white;
}
.study-inspection h3 {
  font-size: clamp(1.45rem, 2.6vw, 2.5rem);
  font-weight: 500;
  line-height: 1.05;
  letter-spacing: -0.055em;
  margin: 0 0 0.65rem;
  text-wrap: balance;
}
.study-inspection .study-instruction,
.study-readout p {
  font-size: 0.9rem;
  line-height: 1.55;
  letter-spacing: -0.012em;
  color: var(--study-muted);
  margin: 0;
}
.study-inspection .study-instruction {
  margin-bottom: 1.1rem;
}
.study-choices,
.study-steps {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}
.study-choices button,
.study-steps button,
.study-next,
.study-explode {
  min-height: 34px;
  border: 1px solid var(--study-rule);
  border-radius: 2px;
  padding: 0.34rem 0.68rem;
  font-size: 0.8rem;
  line-height: 1.2;
  font-weight: 500;
}
.study-choices button[aria-pressed="true"],
.study-steps button[aria-pressed="true"],
.study-explode[aria-pressed="true"] {
  border-color: var(--study-accent);
  color: #774c13;
}
.study-steps button {
  min-width: 33px;
  padding: 0.28rem;
  font-size: 0.74rem;
}
.study-readout {
  padding: 1.05rem 0 0.3rem;
}
.study-readout h4 {
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: -0.025em;
  margin: 0 0 0.35rem;
}
.study-explode,
.study-next {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}
.study-explode {
  margin: 0 0 0.65rem;
}
.study-next {
  margin-top: 0.4rem;
  border: 0;
  padding-left: 0;
}
.study-next svg,
.study-reference span {
  color: var(--study-accent);
}
.study-reference {
  display: inline-block;
  font-size: 0.77rem !important;
  text-decoration: underline;
  text-underline-offset: 3px;
  margin: 0.45rem 0 0.2rem;
}
.study-inspection .study-boundary {
  width: 100%;
  margin: auto 0 0;
  padding-top: 1.25rem;
  font-size: 0.66rem;
  line-height: 1.55;
  color: var(--study-muted);
  letter-spacing: normal;
}
.study-live {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  clip-path: inset(50%);
  white-space: nowrap;
}
@media (max-width: 720px) {
  .study-tabs button {
    min-height: 48px;
  }
  .study-sheet {
    grid-template-columns: 1fr;
  }
  .study-figure {
    border-right: 0;
    border-bottom: 1px solid var(--study-rule);
    padding: 12px 16px;
  }
  .study-plate > svg {
    max-height: 320px;
  }
  .study-figure figcaption {
    padding-top: 0.55rem;
  }
  .study-inspection {
    padding: 1.15rem 1rem 1.4rem;
  }
  .study-inspection h3 {
    font-size: 1.65rem;
  }
  .study-inspection .study-boundary {
    padding-top: 0.8rem;
  }
}
@media (max-width: 460px) {
  .study-tabs button {
    font-size: 0.76rem;
    gap: 0.33rem;
  }
  .study-tabs svg {
    width: 14px;
    height: 14px;
  }
  .study-figure {
    padding-inline: 6px;
  }
  .study-figure figcaption {
    margin-inline: 7px;
  }
  .study-steps button {
    min-width: 40px;
  }
  .study-next,
  .study-choices button,
  .study-explode,
  .study-steps button {
    min-height: 40px;
  }
}
@media (max-width: 340px) {
  .study-tabs svg {
    display: none;
  }
}

.study-plate[data-three-study] {
  position:relative;
  min-height:clamp(340px, 35vw, 530px);
  width:100%;
}
.study-drawing-fallback { width:100%; }
.study-drawing-fallback > svg { width:100%; max-height:415px; height:auto; }
[data-three-surface] {
  position:absolute;
  inset:0;
  display:block;
  width:100% !important;
  height:100% !important;
  cursor:default;
  background:#fff;
}

[data-three-surface]:focus-visible {outline:2px solid #a2600c;outline-offset:-2px;}
.study-plate > svg[data-three-surface] {max-height:none;overflow:hidden;}
.study-plate > svg.study-mast-label {
  position:absolute;
  inset:0;
  z-index:1;
  display:none;
  width:100%;
  height:100%;
  max-height:none;
  pointer-events:none;
}
.study-mast-label path {fill:none;stroke:#3c4945;stroke-width:1.2;}
.study-mast-label circle {fill:#3c4945;stroke:white;stroke-width:1;}
.study-mast-label text {
  fill:#26322e;
  stroke:white;
  stroke-width:3px;
  paint-order:stroke;
  font:500 13px var(--mono,monospace);
}
.study-render-note {
  min-height:1.4em;
  margin:.22rem 0;
  font:400 .72rem/1.4 var(--mono,monospace);
  color:#565b54;
}
.case-strip a > img {
  display:block;
  grid-row:span 2;
  width:100%;
  height:auto;
  align-self:center;
  object-fit:contain;
}
@media(max-width:760px) {
  .case-strip a > img {width:min(100%,8.5rem);}
}
@media(max-width:720px) {
  .study-plate[data-three-study] {min-height:clamp(250px,72vw,420px);}
  .study-drawing-fallback > svg {max-height:320px;}
}

.study-mechanism {min-inline-size:0;margin:1rem 0 .25rem;padding:.65rem 0 0;border:0;border-top:1px solid var(--study-rule);width:100%}
.study-mechanism legend {padding:0 .6rem 0 0;font-weight:600;font-size:.95rem}
.study-mechanism .study-mechanism-readout {font-size:.88rem;line-height:1.45;color:var(--study-muted);margin:.6rem 0 .75rem}

.study-drawing-fallback img[data-drone-poster],
.study-drawing-fallback img[data-photonics-poster] {
  display:block; width:100%; height:auto; object-fit:contain;
  max-height:clamp(340px,35vw,530px); margin:auto;
}
.study-plate[data-study="photonics"] [data-three-surface] { display:none !important; }

.study-project-panel{border:1px solid var(--study-rule);border-top:0}
.study-project-preview{position:relative;display:grid;place-items:center;height:clamp(350px,37vw,455px);background:#eff2f5;overflow:hidden}
.study-project-preview>img{width:100%;height:100%;object-fit:contain}
.study-project-frame{position:absolute;inset:0;width:100%;height:100%;border:0}
.study-project-footer{padding:.7rem 1rem;display:flex;gap:.8rem;justify-content:space-between;align-items:baseline;flex-wrap:wrap}
.study-project-footer h3{font:600 1rem/1.25 var(--sans,system-ui);margin:0}
.study-project-footer>span{display:flex;gap:1rem;flex-wrap:wrap}
.study-project-footer .study-reference{margin:0}
@media(max-width:700px){.study-project-preview{height:480px}.study-project-footer{gap:.4rem}}

/* Eight photo-led selection cards, followed by one active model. */
.study-bench .study-tabs {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(.55rem,1.3vw,1.05rem);
  margin: 0 0 1rem;
  border: 0;
}
.study-bench .study-tabs button {
  min-width: 0;
  display: grid;
  grid-template-rows: auto 1fr;
  align-items: stretch;
  gap: 0;
  padding: 0;
  border: 1px solid var(--study-rule);
  background: #fff;
  color: var(--study-ink);
  text-align: center;
  font-size: clamp(.92rem,1.6vw,1.07rem);
}
.study-bench .study-tab-image {
  display:block;
  width:100%;
  height:auto;
  aspect-ratio:8/5;
  object-fit:contain;
  background:#fafafa;
}
.study-bench .study-tab-label {
  display:grid;
  place-items:center;
  min-height:3.1rem;
  padding:.55rem .5rem;
  border-top:1px solid var(--study-rule);
}
.study-bench .study-tabs button[aria-selected="true"] { border-color:var(--study-ink); }
.study-bench .study-tabs button[aria-selected="true"]::after { bottom:0; height:3px; }
.study-bench .study-tabs button[aria-selected="true"] .study-tab-label { background:#f4f3ef;font-weight:650; }
.study-bench .study-project-panel { border-top:1px solid var(--study-rule); }
.study-bench .study-project-preview{height:clamp(420px,45vw,555px)}
.study-bench .study-project-note{font-size:.875rem;line-height:1.4;padding:0 1rem .85rem;margin:0;color:var(--study-muted)}
.study-bench .study-reference{padding:.25rem 0}
.study-bench .study-extra{padding:0 1rem 1rem;font-size:.875rem}
@media(max-width:620px){
  .study-bench .study-tabs{grid-template-columns:repeat(2,minmax(0,1fr))}
  .study-bench .study-project-preview{height:510px}
}
