/* ============================================================
   02–04 — deep cases: AgentSecurity, cognition-gym, More index
   ============================================================ */

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.work-deep {
  position: relative;
  padding: clamp(26px, 3vw, 36px) 0 clamp(32px, 3.8vw, 46px);
  border-bottom: 1px solid var(--line);
}

/* ---------- Shared case heading ---------- */

.deep-head {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto;
  grid-template-areas: "num title case";
  gap: 10px clamp(22px, 3vw, 38px);
  align-items: center;
  margin-bottom: clamp(20px, 2.4vw, 28px);
}

.deep-num {
  grid-area: num;
  align-self: start;
  padding-top: 0;
  font-family: "NumHand", var(--serif);
  font-size: 34px;
  line-height: 0.9;
  letter-spacing: 0;
  color: var(--accent);
}

.deep-title-block {
  grid-area: title;
  min-width: 0;
}

.deep-kicker {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px 12px;
  margin: 0 0 9px;
  font-size: 9px;
  letter-spacing: 0.12em;
  color: var(--accent);
}

.deep-badge {
  padding: 2px 6px;
  border: 1px solid var(--line);
  font-size: 7.5px;
  letter-spacing: 0.06em;
  color: var(--muted);
}

.deep-title {
  margin: 0;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(28px, 3.1vw, 40px);
  line-height: 1.1;
  letter-spacing: -0.03em;
}

.deep-line {
  margin: 9px 0 0;
  max-width: 58ch;
  font-size: 12.5px;
  line-height: 1.75;
  color: var(--muted);
  text-wrap: pretty;
}

.deep-case {
  grid-area: case;
  justify-self: end;
  align-self: center;
  font-size: 12.5px;
  white-space: nowrap;
}

.deep-case .arrow {
  font-size: 11px;
}

/* ============================================================
   02 — AgentSecurity instrument
   ============================================================ */

.ags {
  --ags-bg: #14181d;
  --ags-ink: #efe8da;
  --ags-muted: #8d948f;
  --ags-line: rgba(239, 232, 218, 0.13);
  --ags-blue: #8aa4ff;
  position: relative;
  padding: clamp(16px, 2vw, 24px);
  border: 1px solid #101318;
  background: var(--ags-bg);
  color: var(--ags-ink);
  overflow: hidden;
}

.ags-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
}

.ags-label {
  margin: 0;
  font-size: 8px;
  letter-spacing: 0.14em;
  color: var(--ags-muted);
}

.ags-clock {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin: 7px 0 0;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(32px, 3.4vw, 46px);
  line-height: 0.95;
  letter-spacing: -0.035em;
  font-variant-numeric: tabular-nums;
}

.ags-unit {
  font-size: 8px;
  letter-spacing: 0.14em;
  color: var(--ags-muted);
}

.ags-policy {
  display: flex;
  border: 1px solid var(--ags-line);
}

.ags-policy button {
  min-height: 34px;
  padding: 7px 13px;
  border: 0;
  border-left: 1px solid var(--ags-line);
  background: transparent;
  color: var(--ags-muted);
  font-family: var(--mono);
  font-size: 8.5px;
  letter-spacing: 0.08em;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.ags-policy button:first-child {
  border-left: 0;
}

.ags-policy button:hover {
  color: var(--ags-ink);
}

.ags-policy button[aria-pressed="true"] {
  background: rgba(239, 232, 218, 0.1);
  color: var(--ags-ink);
}

.ags-policy button:focus-visible,
.ags-btn:focus-visible {
  outline: 1px solid var(--ags-blue);
  outline-offset: -3px;
}

.ags-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 214px;
  gap: clamp(18px, 2.6vw, 34px);
  margin-top: 16px;
}

.ags-chart {
  min-width: 0;
}

.ags-chart-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--ags-line);
  font-size: 7px;
  letter-spacing: 0.1em;
  color: var(--ags-muted);
}

.ags-bars {
  display: grid;
  grid-template-columns: repeat(13, minmax(0, 1fr));
  grid-template-rows: repeat(2, 1fr);
  gap: 12px 6px;
  height: clamp(150px, 14vw, 188px);
  margin-top: 12px;
}

.ags-bar {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
  height: 100%;
}

.ags-bar-track {
  display: flex;
  flex: 1;
  align-items: flex-end;
  min-height: 0;
}

.ags-bar-track i {
  display: block;
  width: 100%;
  height: calc(var(--v, 0) * 100%);
  min-height: 1px;
  background: linear-gradient(180deg, #9db4ff, #4166e8);
  transition: height 0.18s linear, filter 0.2s ease;
}

.ags[data-policy="uniform"] .ags-bar-track i {
  background: linear-gradient(180deg, #a3aba6, #6f7873);
}

.ags-bar b {
  font-size: 7px;
  font-weight: 400;
  line-height: 1;
  letter-spacing: 0;
  text-align: center;
  color: var(--ags-muted);
}

.ags-bar:hover .ags-bar-track i {
  filter: brightness(1.28);
}

.ags-axis {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 9px;
  font-size: 7px;
  letter-spacing: 0.09em;
  color: var(--ags-muted);
}

.ags-side {
  display: flex;
  flex-direction: column;
  gap: 20px;
  min-width: 0;
  padding-left: clamp(18px, 2vw, 26px);
  border-left: 1px solid var(--ags-line);
}

.ags-spark-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
}

.ags-legend {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin: 0;
  font-size: 6.5px;
  letter-spacing: 0.05em;
  color: var(--ags-muted);
  white-space: nowrap;
}

.ags-legend i {
  display: inline-block;
  width: 12px;
  height: 1px;
  margin-left: 3px;
}

.ags-legend i.ucb {
  background: var(--ags-blue);
}

.ags-legend i.uni {
  background: #6f7873;
}

.ags-spark svg {
  display: block;
  width: 100%;
  height: auto;
  margin-top: 7px;
}

.ags-spark-grid line {
  stroke: var(--ags-line);
  stroke-width: 1;
}

.ags-spark-area {
  fill: rgba(138, 164, 255, 0.09);
}

.ags-spark-ucb {
  fill: none;
  stroke: var(--ags-blue);
  stroke-width: 1.5;
}

.ags-spark-uni {
  fill: none;
  stroke: #6f7873;
  stroke-width: 1.2;
  stroke-dasharray: 3 4;
}

.ags-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 16px;
  margin: 0;
}

.ags-stats > div {
  padding: 8px 0 9px;
  border-top: 1px solid var(--ags-line);
}

.ags-stats dt {
  margin: 0;
  font-size: 6.8px;
  letter-spacing: 0.1em;
  color: var(--ags-muted);
}

.ags-stats dd {
  margin: 4px 0 0;
  font-family: var(--serif);
  font-size: 21px;
  line-height: 1;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}

.ags-stats dd span {
  margin-left: 3px;
  font-family: var(--mono);
  font-size: 7.5px;
  color: var(--ags-muted);
}

.ags-controls {
  display: grid;
  grid-template-columns: auto auto minmax(0, 1fr) auto;
  align-items: center;
  gap: clamp(10px, 1.6vw, 18px);
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid var(--ags-line);
}

.ags-btn {
  min-height: 34px;
  padding: 7px 14px;
  border: 1px solid var(--ags-line);
  background: transparent;
  color: var(--ags-muted);
  font-family: var(--mono);
  font-size: 8.5px;
  letter-spacing: 0.08em;
  cursor: pointer;
  transition: border-color 0.2s ease, color 0.2s ease;
}

.ags-btn:hover {
  border-color: rgba(239, 232, 218, 0.34);
  color: var(--ags-ink);
}

.ags-play {
  border-color: rgba(138, 164, 255, 0.42);
  color: #c9d6ff;
}

.ags-scrub {
  width: 100%;
  height: 32px;
  margin: 0;
  background: transparent;
  accent-color: var(--ags-blue);
  cursor: pointer;
}

.ags-scrub:focus-visible {
  outline: 1px solid var(--ags-blue);
  outline-offset: 2px;
}

.ags-readout {
  margin: 0;
  font-size: 7.5px;
  letter-spacing: 0.07em;
  color: var(--ags-muted);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.ags-foot {
  margin: 11px 0 0;
  padding-top: 11px;
  border-top: 1px solid var(--ags-line);
  font-size: 7.5px;
  line-height: 1.7;
  letter-spacing: 0.06em;
  color: var(--ags-muted);
}

html:not(.js) .ags-controls {
  display: none;
}

html:not(.js) .ags-bar-track i {
  transition: none;
}

/* ============================================================
   03 — cognition-gym paper
   ============================================================ */

.gym {
  --gym-blue: #2b50d8;
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(258px, 0.72fr);
  border: 1px solid var(--line);
  background: #fbf7ee;
}

.gym-paper {
  position: relative;
  min-width: 0;
  padding: clamp(18px, 2.3vw, 28px) clamp(18px, 2.8vw, 34px) clamp(22px, 2.8vw, 34px);
  background:
    radial-gradient(120% 90% at 8% 0%, rgba(255, 253, 247, 0.9), transparent 58%),
    #fbf7ee;
}

.gym-paper-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
  font-size: 8px;
  letter-spacing: 0.1em;
  color: var(--muted);
}

.gym-title {
  margin: clamp(16px, 2vw, 22px) 0 0;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(22px, 2.4vw, 30px);
  line-height: 1.2;
  letter-spacing: -0.025em;
}

.gym-text {
  margin: 11px 0 0;
  font-family: var(--serif);
  font-size: clamp(16px, 1.35vw, 18px);
  line-height: 2.05;
  letter-spacing: 0.005em;
  color: var(--ink-soft);
}

.gym-sentence {
  display: inline;
  margin: 0;
  padding: 1px 2px;
  border: 0;
  border-radius: 2px;
  background: transparent;
  font: inherit;
  line-height: inherit;
  color: inherit;
  text-align: left;
  cursor: pointer;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
  transition: background-color 0.18s ease, color 0.18s ease;
}

.gym-sentence .gym-n {
  margin-right: 3px;
  font-family: var(--mono);
  font-size: 0.55em;
  letter-spacing: 0;
  color: var(--muted);
  vertical-align: 0.5em;
}

.gym-sentence:hover {
  background: rgba(184, 65, 39, 0.08);
}

.gym-sentence[aria-pressed="true"] {
  background: rgba(184, 65, 39, 0.11);
  box-shadow: inset 0 -1px 0 var(--accent);
}

.gym-sentence:disabled {
  opacity: 1;
  cursor: default;
}

.gym-sentence.is-answer {
  text-decoration: underline;
  text-decoration-style: dashed;
  text-decoration-color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 5px;
}

.gym-sentence.is-false {
  background: rgba(25, 23, 19, 0.075);
  color: var(--muted);
}

.gym-sentence.is-missed::after {
  content: "漏报";
  display: inline-block;
  margin-left: 4px;
  padding: 0 3px;
  border: 1px solid var(--accent);
  font-family: var(--mono);
  font-size: 7px;
  line-height: 1.5;
  letter-spacing: 0.02em;
  color: var(--accent);
  vertical-align: 0.35em;
}

.gym-prompt {
  margin: 22px 0 0;
  font-size: 7.5px;
  letter-spacing: 0.09em;
  color: var(--muted);
}

.gym-feedback {
  margin-top: 18px;
  padding-top: 15px;
  border-top: 1px solid var(--line);
}

.gym-score {
  margin: 0;
  font-size: 9px;
  letter-spacing: 0.06em;
  color: var(--ink-soft);
}

.gym-notes {
  display: grid;
  gap: 9px;
  margin: 12px 0 0;
  padding: 0;
  list-style: none;
}

.gym-notes li {
  display: grid;
  gap: 2px;
  font-size: 12.5px;
  line-height: 1.7;
  color: var(--ink-soft);
}

.gym-notes b {
  font-family: var(--mono);
  font-size: 8px;
  font-weight: 400;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.gym-notes .hit b {
  color: var(--accent);
}

.gym-notes .miss b {
  color: var(--gym-blue);
}

.gym-notes .fp b {
  color: var(--muted);
}

.gym-notes .type b {
  color: #9a6a1f;
}

.gym-stamp {
  position: absolute;
  top: clamp(58px, 8vw, 82px);
  right: clamp(22px, 3vw, 40px);
  display: grid;
  place-content: center;
  width: 68px;
  height: 68px;
  border: 2px double var(--accent);
  border-radius: 50%;
  font-family: var(--serif);
  font-size: 27px;
  line-height: 1;
  color: var(--accent);
  opacity: 0.78;
  transform: rotate(-8deg);
  pointer-events: none;
}

.gym-stamp::after {
  content: "分";
  margin-top: 3px;
  font-family: var(--mono);
  font-size: 7px;
  letter-spacing: 0.1em;
  text-align: center;
}

.gym-side {
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: clamp(18px, 2.3vw, 26px);
  border-left: 1px solid var(--line);
  background: rgba(234, 228, 214, 0.3);
}

.gym-side-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
}

.gym-side-head p {
  margin: 0;
  font-size: 8px;
  letter-spacing: 0.1em;
  color: var(--muted);
}

.gym-marks {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.gym-empty {
  margin: 0;
  font-size: 12px;
  line-height: 1.8;
  color: var(--muted);
}

.gym-mark {
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line-soft);
}

.gym-mark-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.gym-mark-no {
  font-size: 8px;
  letter-spacing: 0.06em;
  color: var(--accent);
}

.gym-remove {
  display: inline-grid;
  place-content: center;
  width: 24px;
  height: 24px;
  padding: 0;
  border: 0;
  background: transparent;
  font-size: 14px;
  line-height: 1;
  color: var(--muted);
  cursor: pointer;
}

.gym-remove:hover {
  color: var(--accent);
}

.gym-mark-text {
  display: -webkit-box;
  margin: 4px 0 8px;
  overflow: hidden;
  font-size: 11.5px;
  line-height: 1.65;
  color: var(--ink-soft);
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.gym-mark-controls {
  display: flex;
  gap: 6px;
}

.gym-mark select {
  min-width: 0;
  flex: 1;
  min-height: 36px;
  padding: 5px 8px;
  border: 1px solid var(--line);
  border-radius: 0;
  background: #fbf7ee;
  color: var(--ink);
  font-family: var(--sans);
  font-size: 12px;
}

.gym-mark.is-right select {
  border-color: rgba(43, 80, 216, 0.5);
}

.gym-mark.is-wrong select {
  border-color: rgba(184, 65, 39, 0.55);
}

.gym-mark.is-right .gym-mark-no {
  color: var(--gym-blue);
}

.gym-hint {
  margin: 14px 0 0;
  font-size: 10.5px;
  line-height: 1.7;
  color: var(--muted);
}

.gym-actions {
  display: flex;
  gap: 9px;
  margin-top: auto;
  padding-top: 18px;
}

.gym-btn {
  flex: 1;
  min-height: 42px;
  padding: 9px 12px;
  border: 1px solid var(--ink);
  background: var(--ink);
  color: var(--paper);
  font-family: var(--mono);
  font-size: 8.5px;
  letter-spacing: 0.08em;
  cursor: pointer;
  transition: opacity 0.2s ease, background-color 0.2s ease, color 0.2s ease;
}

.gym-btn:hover:not(:disabled) {
  background: var(--accent);
  border-color: var(--accent);
}

.gym-btn:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

.gym-next {
  border-color: var(--line);
  background: transparent;
  color: var(--ink);
}

.gym-next:hover:not(:disabled) {
  background: transparent;
  border-color: var(--ink);
  color: var(--accent);
}

.gym-next[hidden] {
  display: none;
}

.gym-note {
  margin: 14px 0 0;
  padding-top: 10px;
  border-top: 1px solid var(--line-soft);
  font-size: 7px;
  letter-spacing: 0.06em;
  color: var(--muted);
}

.gym-noscript {
  grid-column: 1 / -1;
  margin: 0;
  padding: 12px clamp(18px, 2.8vw, 34px);
  border-top: 1px solid var(--line);
  font-size: 7.5px;
  letter-spacing: 0.05em;
  color: var(--muted);
}

.gym-foot {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  margin: 10px 0 0;
  font-size: 7.5px;
  letter-spacing: 0.06em;
  color: var(--muted);
}

html:not(.js) .gym {
  grid-template-columns: minmax(0, 1fr);
}

html:not(.js) .gym-side {
  display: none;
}

/* ============================================================
   04 — More projects index
   ============================================================ */

.more {
  border-top: 1px solid var(--line);
}

.more-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.more-row {
  border-bottom: 1px solid var(--line-soft);
}

.more-trigger {
  position: relative;
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) auto 26px;
  gap: 14px;
  align-items: center;
  width: 100%;
  padding: 17px 0;
  border: 0;
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.more-trigger::before {
  content: "";
  position: absolute;
  inset: 0 -14px;
  z-index: -1;
  background: var(--wash);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.more-trigger:hover::before,
.more-trigger:focus-visible::before,
.more-trigger[aria-pressed="true"]::before {
  opacity: 1;
}

.more-trigger:focus-visible {
  outline-offset: 1px;
}

.more-no {
  font-family: "NumHand", var(--serif);
  font-size: 21px;
  line-height: 1;
  letter-spacing: 0;
  color: var(--muted);
  transition: color 0.25s ease;
}

.more-trigger:hover .more-no,
.more-trigger:focus-visible .more-no,
.more-trigger[aria-pressed="true"] .more-no {
  color: var(--accent);
}

.more-name {
  min-width: 0;
  font-family: var(--serif);
  font-size: clamp(20px, 2vw, 26px);
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.more-tags {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 4px 6px;
}

.more-tags span {
  padding: 2px 7px;
  border: 1px solid var(--line);
  font-family: var(--mono);
  font-size: 7.5px;
  letter-spacing: 0.03em;
  color: var(--muted);
  white-space: nowrap;
}

.more-arrow {
  justify-self: end;
  font-size: 16px;
  line-height: 1;
  color: var(--muted);
  transition: color 0.25s ease, transform 0.3s var(--ease);
}

.more-trigger:hover .more-arrow,
.more-trigger:focus-visible .more-arrow,
.more-trigger[aria-pressed="true"] .more-arrow {
  color: var(--accent);
  transform: translate(2px, -2px);
}

.more-mobile-head {
  display: none;
  grid-template-columns: 36px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: baseline;
  padding: 15px 0 10px;
}

.more-panel {
  padding: 0 0 22px;
}

.more-frame {
  position: relative;
  aspect-ratio: 8 / 5;
  overflow: hidden;
  border: 1px solid var(--line);
  background-color: #f7f2e8;
  background-image:
    linear-gradient(rgba(72, 62, 46, 0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(72, 62, 46, 0.055) 1px, transparent 1px);
  background-size: 24px 24px;
}

.more-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  box-shadow: inset 0 0 38px rgba(90, 76, 54, 0.06);
}

.more-frame svg {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
}

.more-frame svg text {
  font-family: var(--mono);
  font-size: 9px;
  letter-spacing: 0.02em;
  fill: var(--ink-soft);
}

.more-frame svg .sm {
  font-size: 7.5px;
  fill: var(--muted);
}

.more-frame svg .sans {
  font-family: var(--sans);
}

.more-frame svg .blue {
  fill: #2b50d8;
}

.more-frame svg .red {
  fill: var(--accent);
}

.more-frame svg .line {
  fill: none;
  stroke: rgba(25, 23, 19, 0.24);
  stroke-width: 1;
}

.more-frame svg .rule,
.more-frame svg .rule-v {
  fill: none;
  stroke: rgba(25, 23, 19, 0.24);
  stroke-width: 1;
}

.more-frame svg .rule-v {
  stroke-dasharray: 2 4;
}

.more-frame svg .dash {
  stroke-dasharray: 3 4;
}

.more-frame svg .line-blue {
  fill: none;
  stroke: #2b50d8;
  stroke-width: 1.6;
}

.more-frame svg .line-red {
  fill: none;
  stroke: var(--accent);
  stroke-width: 1.2;
}

.more-frame svg .dot-blue {
  fill: #2b50d8;
}

.more-frame svg .tick path {
  stroke: rgba(25, 23, 19, 0.24);
}

.more-frame svg .box rect {
  fill: rgba(255, 253, 247, 0.78);
  stroke: rgba(25, 23, 19, 0.2);
}

.more-frame svg .hub {
  fill: rgba(255, 253, 247, 0.9);
  stroke: #2b50d8;
  stroke-width: 1.3;
}

.more-frame svg .track {
  fill: #e9e2d4;
}

.more-frame svg .bar-red {
  fill: var(--accent);
}

.more-frame svg .bar-grey {
  fill: #777265;
}

.more-frame svg .seg-a {
  fill: #3a362e;
}

.more-frame svg .seg-b {
  fill: #2b50d8;
  opacity: 0.62;
}

.more-frame svg .seg-c {
  fill: var(--accent);
  opacity: 0.78;
}

.more-frame svg .heat rect {
  fill: var(--accent);
}

.more-caption {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 14px;
  padding-top: 8px;
}

.more-caption-note {
  font-size: 7.5px;
  letter-spacing: 0.05em;
  color: var(--muted);
}

.more-caption-link {
  flex: none;
  padding-bottom: 2px;
  border-bottom: 1px solid var(--line);
  font-family: var(--mono);
  font-size: 8px;
  letter-spacing: 0.05em;
  color: var(--ink-soft);
  white-space: nowrap;
  transition: color 0.2s ease, border-color 0.2s ease;
}

.more-caption-link:hover {
  color: var(--accent);
  border-color: var(--accent);
}

.more-caption-nolink {
  flex: none;
  font-size: 7.5px;
  letter-spacing: 0.05em;
  color: var(--muted);
  white-space: nowrap;
}

.more-stage {
  display: none;
}

.more.is-enhanced {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(340px, 480px);
  gap: clamp(30px, 4vw, 56px);
  align-items: start;
}

.more.is-enhanced .more-trigger {
  padding: 18px 0;
}

.more.is-enhanced .more-list .more-panel {
  display: none;
}

.more.is-enhanced .more-stage {
  display: block;
  position: sticky;
  top: 96px;
  min-width: 0;
}

.more-stage-inner .more-panel {
  padding: 0;
}

.more-stage-inner .more-frame {
  border-color: var(--line);
  box-shadow: 0 18px 46px -34px rgba(20, 18, 14, 0.4);
}

/* ---------- Responsive ---------- */

@media (max-width: 1080px) {
  .deep-head {
    grid-template-columns: 34px minmax(0, 1fr);
    grid-template-areas:
      "num title"
      "num case";
    gap: 10px clamp(16px, 2.6vw, 26px);
    align-items: start;
  }

  .deep-case {
    grid-area: case;
    justify-self: start;
    align-self: start;
    margin-top: 2px;
  }

  .ags-body {
    grid-template-columns: minmax(0, 1fr);
  }

  .ags-side {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr);
    gap: 20px 28px;
    padding: 16px 0 0;
    border-top: 1px solid var(--ags-line);
    border-left: 0;
  }

  .ags-stats {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0 14px;
    align-content: start;
  }

  .more.is-enhanced {
    grid-template-columns: minmax(0, 1fr) minmax(320px, 420px);
    gap: 30px;
  }
}

@media (max-width: 900px) {
  .gym {
    grid-template-columns: minmax(0, 1fr);
  }

  .gym-side {
    border-top: 1px solid var(--line);
    border-left: 0;
  }

  .gym-marks {
    min-height: 0;
  }

  .gym-actions {
    margin-top: 0;
  }

  .more.is-enhanced {
    display: block;
  }

  .more.is-enhanced .more-trigger {
    display: none;
  }

  .more-mobile-head {
    display: grid;
  }

  .more.is-enhanced .more-list .more-panel {
    display: block;
  }

  .more.is-enhanced .more-stage {
    display: none;
  }
}

@media (max-width: 640px) {
  .work-deep {
    padding: 22px 0 30px;
  }

  .deep-head {
    grid-template-columns: 24px minmax(0, 1fr);
    gap: 9px 13px;
    margin-bottom: 18px;
  }

  .deep-num {
    font-size: 26px;
  }

  .deep-kicker {
    margin-bottom: 7px;
    font-size: 8.5px;
    letter-spacing: 0.1em;
  }

  .deep-title {
    font-size: clamp(26px, 8vw, 32px);
  }

  .deep-line {
    margin-top: 7px;
    font-size: 12px;
    line-height: 1.7;
  }

  .deep-case {
    font-size: 12px;
  }

  .ags {
    padding: 14px;
  }

  .ags-top {
    gap: 12px;
  }

  .ags-clock {
    font-size: 32px;
  }

  .ags-bars {
    height: 208px;
    gap: 10px 5px;
    margin-top: 10px;
  }

  .ags-bar b {
    font-size: 6.5px;
  }

  .ags-side {
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
  }

  .ags-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .ags-controls {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  .ags-btn {
    min-height: 44px;
  }

  .ags-scrub {
    grid-column: 1 / -1;
    grid-row: 2;
    height: 40px;
  }

  .ags-readout {
    grid-column: 1 / -1;
    grid-row: 3;
  }

  .ags-foot {
    font-size: 7px;
    line-height: 1.65;
  }

  .gym-paper {
    padding: 16px 15px 22px;
  }

  .gym-title {
    font-size: 22px;
  }

  .gym-text {
    font-size: 15.5px;
    line-height: 2.02;
  }

  .gym-side {
    padding: 16px 15px 18px;
  }

  .gym-btn {
    min-height: 44px;
  }

  .gym-stamp {
    top: 56px;
    right: 18px;
    width: 56px;
    height: 56px;
    font-size: 22px;
  }

  .gym-paper-head,
  .gym-title,
  .gym-text {
    padding-right: 0;
  }

  .gym-foot {
    flex-direction: column;
    gap: 4px;
    font-size: 7px;
  }

  .more-name {
    font-size: 21px;
  }

  .more-tags span {
    font-size: 7px;
    padding: 2px 6px;
  }

  .more-mobile-head .more-tags {
    justify-content: flex-end;
  }

  .more-panel {
    padding-bottom: 18px;
  }

  .more-caption {
    align-items: flex-start;
    gap: 10px;
  }

  .more-caption-note {
    font-size: 7px;
    line-height: 1.5;
  }

  .more-caption-link,
  .more-caption-nolink {
    font-size: 7.5px;
    margin-top: 1px;
  }
}

@media (max-width: 380px) {
  .ags {
    padding: 12px;
  }

  .ags-policy button {
    padding: 6px 10px;
  }

  .ags-bars {
    height: 190px;
  }

  .ags-bar b {
    font-size: 6px;
  }

  .deep-title {
    font-size: 25px;
  }

  .gym-text {
    font-size: 15px;
  }

  .more-mobile-head {
    grid-template-columns: 32px minmax(0, 1fr);
    row-gap: 5px;
  }

  .more-mobile-head .more-tags {
    grid-column: 2;
    justify-content: flex-start;
  }
}

/* ---------- Coarse pointers ---------- */

@media (hover: none), (pointer: coarse) {
  .more-caption-link,
  .gym-btn,
  .ags-btn,
  .more-trigger {
    -webkit-tap-highlight-color: transparent;
  }
}

/* ---------- Reduced motion ---------- */

@media (prefers-reduced-motion: reduce) {
  .ags-bar-track i {
    transition: none;
  }

  .more-trigger::before,
  .more-arrow,
  .gym-sentence {
    transition: none;
  }

  .gym-stamp {
    transform: none;
  }
}
