/* Inside the sensor and the full-screen layer view.
   Loaded after style.css: overrides with the same or higher specificity. */

/* The pinned section: the settle, the separate, the open labelled stack (about
   one screen of its own), one stop per layer and the close, at 1.5 times the
   scroll length of the 2026-10-28 review, so each animation plays at about 65%
   of its old speed. The script reads the same fractions (explode.js, SCREENS). */
.inside {
  height: 940vh;
  background: #000;
  color: var(--fg-dark);
}

/* The same cyan spotlight pool as the part view, centred on the framed
   model (human, 2026-10-28). It is drawn on a layer of its own and masked to
   nothing at the pin's top and bottom edges, so the pool arrives at the
   section's boundary as plain black: no line where the film ends or where the
   live model begins (human, 2026-10-28). */
.inside-pin {
  background: #000;
}

.inside-pin::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background: radial-gradient(ellipse 52% 60% at 42% 46%, #174a56 0%, #0b242b 46%, #03080a 78%, #000 100%);
  -webkit-mask-image: linear-gradient(180deg, transparent 0%, #000 16%, #000 84%, transparent 100%);
  mask-image: linear-gradient(180deg, transparent 0%, #000 16%, #000 84%, transparent 100%);
}

/* The copy sits at the lower left, under the framed model; the model keeps to
   the middle band and its labels to the right, so neither ever sits over it.
   One block per beat; the script shows the one that belongs to the scroll. */
.inside-copy {
  left: 5vw;
  right: auto;
  top: auto;
  bottom: 11vh;
  width: min(260px, 21vw);
  z-index: 3;
  pointer-events: none;
}

.inside-beat {
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.55s var(--ease), transform 0.55s var(--ease);
}

.inside-beat.is-on {
  opacity: 1;
  transform: none;
}

/* The beat owns the fade, so the paragraph itself stays at full strength. */
.inside-copy .copy {
  opacity: 1;
  transform: none;
  transition: none;
  font-size: 19px;
  line-height: 1.42;
  letter-spacing: -0.006em;
  color: var(--fg-dark);
}

.inside-copy .inside-title {
  margin: 0 0 10px;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: 0;
  color: var(--muted-dark);
}

/* A stop with no copy of its own (the camera) carries its label alone. */
.inside-beat.is-title-only .inside-title {
  margin: 0;
  font-size: 24px;
  font-weight: 600;
  letter-spacing: -0.012em;
  line-height: 1.2;
  color: var(--fg-dark);
}

/* Labels: plain text in a right-hand column, each with a fine line to its
   part. No box, no background, no border. The five layers carry the large
   label of the labelled stop; a layer's own parts carry a smaller one. */

#inside-stage .part-label {
  color: var(--fg-dark);
  transition: opacity 0.5s var(--ease), color 0.22s var(--ease);
}

#inside-stage .part-label__title {
  font-size: 15px;
  font-weight: 500;
  letter-spacing: -0.008em;
  color: #f5f5f7;
}

#inside-stage .part-label--group .part-label__title {
  font-size: 24px;
  font-weight: 500;
  letter-spacing: -0.014em;
  line-height: 1.25;
}

#inside-stage .part-label--child .part-label__title {
  font-size: 19px;
  font-weight: 500;
  letter-spacing: -0.01em;
}

/* The layer under the pointer: its label turns cyan, the rest step back. */
#inside-stage .part-label.is-hot .part-label__title {
  color: var(--accent);
}

/* The cyan prompt under a hovered layer's name: the human's words for the
   click, a chevron after them, no box, no background. The five names that
   stand open on their own, and a stop's part names, stay names alone. The
   script keeps it in the label's flow, so the column is measured with it. */
#inside-stage .part-prompt {
  display: table;  /* shrink to its text, so the chevron follows the words */
  margin-top: 5px;
  padding-right: 12px;
  font-family: inherit;
  font-size: 12.5px;
  font-weight: 500;
  line-height: 1.35;
  letter-spacing: 0.02em;
  color: var(--accent);
  background: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='8' height='8' viewBox='0 0 8 8'><path d='M3 1.4 5.7 4 3 6.6' fill='none' stroke='%2323e6ff' stroke-width='1.1' stroke-linecap='round' stroke-linejoin='round'/></svg>") no-repeat right 2px center;
  background-size: 8px 8px;
  opacity: 0;
  transform: translateY(-2px);
  transition: opacity 0.18s var(--ease), transform 0.18s var(--ease);
}

#inside-stage .part-prompt.is-on {
  opacity: 1;
  transform: none;
}

#inside-stage .part-label.is-on.is-dim {
  opacity: 0.4;
}

#inside-stage .part-line,
#layer-overlay .part-line {
  background: #86868b;
  transition: opacity 0.5s var(--ease), background-color 0.22s var(--ease);
}

#inside-stage .part-line.is-on,
#layer-overlay .part-line.is-on {
  opacity: 0.6;
}

#inside-stage .part-line.is-on.is-hot,
#layer-overlay .part-line.is-on.is-hot {
  background: var(--accent);
  opacity: 0.75;
}

/* Layer view -------------------------------------------------------------- */

#layer-overlay {
  /* a soft cyan studio pool behind the part, falling to black at the edges:
     black parts read against it instead of vanishing into black (cyan, then
     brighter and more saturated: human, 2026-10-28) */
  background: radial-gradient(ellipse 58% 62% at 50% 46%, #1c5a68 0%, #0d2b33 46%, #03090b 78%, #000 100%);
  transition: opacity 0.32s cubic-bezier(0.4, 0, 0.2, 1);
}

#layer-overlay .layer-stage {
  position: absolute;
  inset: 0;
  will-change: transform;
  backface-visibility: hidden;
}

#layer-overlay .layer-labels {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

#layer-overlay .part-label__title {
  font-size: 16px;
  font-weight: 500;
  letter-spacing: -0.008em;
  color: #f5f5f7;
}

#layer-overlay .part-label {
  transition: opacity 0.5s var(--ease), color 0.22s var(--ease);
}

#layer-overlay .part-label.is-hot .part-label__title {
  color: var(--accent);
}

#layer-overlay .part-label.is-on.is-dim {
  opacity: 0.35;
}

/* The opened node's name, then its paper sentence, at the lower left. */
#layer-overlay .layer-text {
  position: absolute;
  left: 6vw;
  bottom: 10vh;
  z-index: 3;
  width: min(360px, 26vw);
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.7s cubic-bezier(0.4, 0, 0.2, 1),
    transform 0.7s cubic-bezier(0.4, 0, 0.2, 1);
  pointer-events: none;
}

#layer-overlay.is-settled .layer-text {
  opacity: 1;
  transform: none;
}

/* Zoomed in on the node, the corner text steps back instead of sitting over
   the model; it returns as soon as the node is framed again. */
#layer-overlay.is-settled.is-zoomed .layer-text {
  opacity: 0;
}

#layer-overlay .layer-title {
  margin: 0 0 10px;
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.012em;
  line-height: 1.25;
  color: var(--fg-dark);
}

/* A node with no copy of its own (a mount, the module, a single part) shows its
   name as the one piece of text in the view. */
#layer-overlay.is-title-only .layer-title {
  margin: 0;
  font-size: 26px;
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.2;
  color: var(--fg-dark);
}

#layer-overlay .layer-copy {
  position: static;
  left: auto;
  bottom: auto;
  z-index: auto;
  max-width: none;
  margin: 0;
  font-size: 18px;
  line-height: 1.45;
  letter-spacing: -0.006em;
  color: #c7c7cc;
}

#layer-overlay .layer-copy span {
  display: none;
}

#layer-overlay .layer-copy span.is-on {
  display: block;
}

#layer-overlay .overlay-close {
  top: 20px;
  right: 28px;
  width: 44px;
  height: 44px;
  font-size: 26px;
  opacity: 0.6;
  transition: opacity 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

#layer-overlay .overlay-close:hover {
  opacity: 1;
}

#layer-overlay .overlay-close:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  .inside-beat,
  #layer-overlay .layer-stage,
  #layer-overlay .layer-text {
    transition: none !important;
  }
}
