.about-file {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
  margin-top: clamp(48px, 7vw, 88px);
}
@media (min-width: 980px) {
  .about-file {
    grid-template-columns: minmax(0, 1fr) 360px;
    align-items: start;
    gap: 56px;
  }
}

.about-canvas {
  display: grid;
  place-items: center;
  padding: 44px 0 56px;
}
.about-frame-wrap {
  position: relative;
  width: min(100%, 500px);
}
.frame-label {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0 0 8px;
  font-size: 12px;
  color: var(--muted);
}
.frame-label svg, .insp-h svg { width: 11px; height: 11px; flex: none; }
.about-frame {
  position: relative;
  aspect-ratio: 4 / 5;
  border-radius: 2px;
  background:
    radial-gradient(circle at 50% 42%, #1d1d22 0%, #0d0d10 70%);
  outline: 1.5px solid var(--c-blue);
  outline-offset: 0;
  box-shadow: var(--shadow-tile);
}
.about-frame > img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.about-frame::before,
.about-frame::after {
  content: "";
  position: absolute;
  width: 8px; height: 8px;
  background: #fff;
  border: 1.5px solid var(--c-blue);
  z-index: 21;
}
.about-frame::before { left: -5px; top: -5px; }
.about-frame::after { right: -5px; bottom: -5px; }
.frame-dims {
  position: absolute;
  left: 50%;
  top: calc(100% + 10px);
  transform: translateX(-50%);
  padding: 3px 8px;
  border-radius: 5px;
  background: var(--c-blue);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  white-space: nowrap;
  z-index: 21;
}

.about-notes {
  position: absolute;
  inset: 0;
  z-index: 22;
  pointer-events: none;
  --note-c: var(--c-blue);
  --note-gap: 22px;
}
.note { position: absolute; left: 0; right: 0; top: var(--y); height: 0; }
.note-dot {
  position: absolute;
  left: var(--x); top: 0;
  display: grid;
  place-items: center;
  width: 9px; height: 9px;
  margin: -4.5px 0 0 -4.5px;
  border-radius: 50%;
  background: var(--note-c);
  box-shadow: 0 0 0 2px #fff, 0 1px 5px rgba(0, 0, 0, .35);
  transform: scale(0);
  transition: transform .35s var(--ease-spring) calc(var(--i) * 140ms);
}
.note-dot span { display: none; color: #fff; font: 600 11px/1 var(--body-font); }
.note-line {
  position: absolute;
  top: -.5px;
  height: 1px;
  background: var(--note-c);
  transform: scaleX(0);
  transition: transform .45s var(--ease-out) calc(var(--i) * 140ms + 160ms);
}
.note[data-side="left"] .note-line { left: calc(-1 * var(--note-gap)); right: calc(100% - var(--x)); transform-origin: 100% 50%; }
.note[data-side="right"] .note-line { left: var(--x); right: calc(-1 * var(--note-gap)); transform-origin: 0 50%; }
.note-label {
  position: absolute;
  top: 0;
  width: var(--note-w, 200px);
  margin: 0;
  padding: 7px 10px 8px;
  border: 1px solid var(--note-c);
  border-radius: 6px;
  background: var(--tile);
  color: var(--text);
  font-size: 12.5px;
  line-height: 1.4;
  box-shadow: var(--shadow-tile);
  transform: translateY(-50%);
  opacity: 0;
  transition: opacity .35s ease calc(var(--i) * 140ms + 420ms);
}
.note[data-side="left"] .note-label { right: calc(100% + var(--note-gap)); }
.note[data-side="right"] .note-label { left: calc(100% + var(--note-gap)); }
.about-file.notes-in .note-dot { transform: none; }
.about-file.notes-in .note-line { transform: none; }
.about-file.notes-in .note-label { opacity: 1; }

.note-list { display: none; }
.about-file.notes-list .note-line,
.about-file.notes-list .note-label { display: none; }
.about-file.notes-list .note-dot { width: 20px; height: 20px; margin: -10px 0 0 -10px; }
.about-file.notes-list .note-dot span { display: block; }
.about-file.notes-list .note-list {
  display: grid;
  gap: 10px;
  margin: 52px 0 0;
  padding: 0;
  list-style: none;
  opacity: 0;
  transition: opacity .5s ease .3s;
}
.about-file.notes-list.notes-in .note-list { opacity: 1; }
.note-list li {
  display: grid;
  grid-template-columns: 20px 1fr;
  gap: 10px;
  align-items: start;
  color: var(--text);
  font-size: 13.5px;
  line-height: 1.45;
}
.note-list .n {
  display: grid;
  place-items: center;
  width: 20px; height: 20px;
  margin-top: -1px;
  border-radius: 50%;
  background: var(--c-blue);
  color: #fff;
  font: 600 11px/1 var(--body-font);
}

.about-pins { position: absolute; inset: 0; z-index: 23; pointer-events: none; }
.pin {
  position: absolute;
  left: var(--x); top: var(--y);
  pointer-events: auto;
  transform: translate(-3px, calc(-100% + 3px));
}
.pin-btn {
  position: relative;
  display: block;
  width: 36px; height: 36px;
  padding: 2px;
  border-radius: 50% 50% 50% 4px;
  background: var(--tile);
  box-shadow: 0 6px 16px -6px rgba(0, 0, 0, .5), 0 0 0 1px rgba(0, 0, 0, .06);
  transform: scale(0);
  transform-origin: 0 100%;
  transition: transform .45s var(--ease-spring) calc(var(--i) * 110ms);
}
.pin-btn img {
  display: block;
  width: 100%; height: 100%;
  border-radius: 50% 50% 50% 3px;
  object-fit: cover;
}
.about-file.pins-in .pin-btn { transform: none; }
.about-file.pins-in .pin.is-open .pin-btn { transform: scale(1.1); transition-delay: 0s; }
@media (hover: hover) {
  .about-file.pins-in .pin-btn:hover { transform: scale(1.1); transition-delay: 0s; }
}
.pin-btn::after {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  box-shadow: 0 0 0 2px var(--accent);
  opacity: 0;
  pointer-events: none;
}
@media (prefers-reduced-motion: no-preference) {
  .about-file.pins-in .pin:not(.is-read) .pin-btn::after {
    animation: pin-ping 6s var(--ease-out) calc(1.4s + var(--i) * .5s) infinite;
  }
}
@keyframes pin-ping {
  0%   { opacity: .9; transform: scale(1); }
  14%  { opacity: 0;  transform: scale(1.45); }
  100% { opacity: 0;  transform: scale(1.45); }
}

.pin-bubble {
  position: absolute;
  left: calc(100% + 8px);
  bottom: 0;
  width: 240px;
  padding: 10px 12px 12px;
  border: 1px solid var(--border);
  border-radius: 12px 12px 12px 4px;
  background: var(--tile);
  box-shadow: var(--shadow-tile), 0 14px 30px -14px rgba(0, 0, 0, .35);
  color: var(--text);
  font-size: 13px;
  line-height: 1.45;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translate(var(--bx, 0px), 6px) scale(.96);
  transform-origin: 0 100%;
  transition: opacity .2s ease, transform .25s var(--ease-spring), visibility 0s .25s;
}
.pin[data-side="left"] .pin-bubble {
  left: auto;
  right: calc(100% + 8px);
  border-radius: 12px 12px 4px 12px;
  transform-origin: 100% 100%;
}
.pin.is-open { z-index: 2; }
.pin.is-open .pin-bubble {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translate(var(--bx, 0px), 0) scale(1);
  transition-delay: 0s;
}
@media (hover: hover) {
  .pin:hover { z-index: 2; }
  .pin:hover .pin-bubble {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translate(var(--bx, 0px), 0) scale(1);
    transition-delay: 0s;
  }
}
.pin-head {
  display: flex;
  align-items: center;
  gap: 7px;
  margin: 0 0 5px;
  font-size: 12.5px;
}
.pin-head img { width: 20px; height: 20px; border-radius: 50%; flex: none; }
.pin-head b { font-weight: 600; }
.pin-time { color: var(--muted); margin-left: auto; font-size: 12px; }
.pin-text { margin: 0; }

.inspector {
  position: relative;
  border-radius: 14px;
  background: var(--tile);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-tile);
  font-size: 13px;
  overflow: hidden;
}
.insp-tabs {
  display: flex;
  gap: 16px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
}
.insp-tabs .on { color: var(--text); }
.insp-sec {
  padding: 14px 16px 16px;
  border-bottom: 1px solid var(--border);
}
.insp-sec:last-child { border-bottom: 0; }
.insp-h {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0 0 10px;
  font-size: 12px;
  font-weight: 600;
}
.insp-rows { margin: 0; display: grid; gap: 2px; }
.insp-row {
  display: grid;
  grid-template-columns: 92px 1fr;
  gap: 10px;
  padding: 6px 8px;
  border-radius: 6px;
  transition: background-color .15s ease;
}
@media (hover: hover) { .insp-row:hover { background: var(--bg-elev); } }
.insp-row dt { color: var(--muted); }
.insp-row dd { margin: 0; display: flex; align-items: center; gap: 7px; }
.live-dot {
  position: relative;
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--live);
}
.live-dot::after {
  content: "";
  position: absolute;
  inset: -3px;
  border-radius: 50%;
  background: color-mix(in srgb, var(--live) 25%, transparent);
  animation: live-pulse 2s ease-in-out infinite;
}
@keyframes live-pulse { 50% { transform: scale(1.6); opacity: 0; } }

.insp-export { display: flex; }
.insp-export .btn { padding: 9px 16px; font-size: 13px; }

.versions { position: relative; display: grid; }
.versions::before {
  content: "";
  position: absolute;
  left: 13px; top: 14px; bottom: 14px;
  width: 1px;
  background: var(--border);
}
.version-btn {
  position: relative;
  display: grid;
  grid-template-columns: 28px 1fr 18px;
  align-items: start;
  width: 100%;
  padding: 8px 4px 8px 0;
  text-align: left;
  border-radius: 8px;
  transition: background-color .15s ease;
}
@media (hover: hover) {
  .version-btn:hover { background: var(--bg-elev); }
}
.version-dot {
  justify-self: center;
  margin-top: 5px;
  width: 9px; height: 9px;
  border-radius: 50%;
  background: var(--tile);
  border: 2px solid var(--muted-2);
}
.version:first-child .version-dot { border-color: var(--accent); background: var(--accent); }
.version-main { display: grid; gap: 1px; }
.version-year { font-size: 11px; color: var(--muted); font-family: var(--mono-font); }
.version:first-child .version-year { color: var(--accent); }
.version-title { font-weight: 600; font-size: 14px; }
.version-place { color: var(--muted); font-size: 12px; }
.version-chev {
  width: 16px; height: 16px;
  margin-top: 4px;
  color: var(--muted);
  transition: transform .3s ease;
}
.version.open .version-chev { transform: rotate(180deg); }
.version-body {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows .35s var(--ease-out);
}
.version.open .version-body { grid-template-rows: 1fr; }
.version-body > div { overflow: hidden; }
.version-body p {
  margin: 0;
  padding: 2px 8px 12px 28px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

@media (max-width: 640px) {
  .pin-bubble,
  .pin[data-side="left"] .pin-bubble {
    --bw: min(260px, calc(100vw - 2 * var(--px)));
    left: 50%;
    right: auto;
    bottom: calc(100% + 10px);
    width: var(--bw);
    margin-left: calc(var(--bw) / -2);
    border-radius: 12px;
    transform-origin: 50% 100%;
  }
  .pin[data-v="below"] .pin-bubble {
    top: calc(100% + 10px);
    bottom: auto;
    transform-origin: 50% 0;
  }
  .about-canvas { padding: 32px 18px 56px; }
}
@media (prefers-reduced-motion: reduce) {
  .note-dot, .note-line, .note-label, .note-list { transition: none; }
  .pin-btn { transition: none; }
  .version-body { transition: none; }
}
