.mast {
  position: sticky;
  top: 0;
  z-index: 8;
  background: #101113f6;
  backdrop-filter: blur(14px);
}
#studio-object {
  touch-action: pan-y pinch-zoom;
}
.studio-transport {
  position: absolute;
  right: 14px;
  bottom: 12px;
  z-index: 4;
  display: flex;
  align-items: center;
  background: #17191dea;
  border: 1px solid #56595f;
  border-radius: 3px;
  color: #ededf0;
}
.studio-transport button {
  min-width: 34px;
  min-height: 30px;
  font: 16px var(--sans);
}
.studio-transport output {
  min-width: 42px;
  text-align: center;
  font: 11px var(--mono);
}
.studio-transport button:disabled {
  color: #777;
}
@media (pointer: coarse) {
  .studio-transport button,
  .studio-motion {
    min-height: 40px;
  }
  .studio-transport button {
    min-width: 40px;
  }
}
.hero-expanded {
  z-index: 12;
}
.world-rail {
  grid-column: 1/-1;
  display: flex;
  gap: 20px;
  align-items: center;
  min-height: 45px;
  padding: 6px 20px;
  border-top: 1px solid #343638;
  background: #151619e8;
  z-index: 3;
}
.world-rail .rail-label {
  min-width: 98px;
}
.world-rail > div {
  display: flex;
  align-items: center;
  gap: 6px;
  overflow: auto;
  scrollbar-width: thin;
}
.world-rail a,
.date-periods button,
.desk-chip,
#studio-instruments button {
  display: inline-block;
  white-space: nowrap;
  padding: 6px 10px;
  border: 1px solid transparent;
  border-radius: 3px;
  color: #c6c8cd;
  font: 400 0.78rem var(--mono);
}
.world-rail a:hover,
.world-rail a[aria-current],
.date-periods [aria-pressed="true"],
#studio-instruments button[aria-pressed="true"] {
  color: #f7f5f3;
  background: #322322;
  border-color: #8a4843;
}
.world-rail .all-desks {
  color: #e88d84;
}
.atlas-head {
  justify-content: space-between;
  align-items: center;
  left: 15px;
}
.atlas-buttons select,
.archive-tools select {
  min-width: 0;
  max-width: 175px;
  border: 1px solid #52565e;
  background: #191b1f;
  color: #e6e8ec;
  padding: 5px 7px;
  border-radius: 3px;
  font: 400 0.77rem var(--sans);
  pointer-events: auto;
}
.country-copy {
  padding-right: 12px;
}
.country-copy h1 {
  font-size: clamp(2rem, 3.4vw, 3.9rem);
  margin: 0.22em 0;
}
.date-periods {
  display: inline-flex;
  gap: 4px;
  flex-wrap: wrap;
}
.date-periods button {
  border-color: #45494e;
  background: #1b1d21;
  padding: 5px 9px;
}
.country-count,
.archive-status,
.country-leads time,
.studio-story time,
.reader-related time,
.archive-tools > span,
.price-observation {
  color: #acaeb5;
  font: 400 0.74rem/1.45 var(--mono);
}
.country-count {
  margin: 7px 0;
}
.country-leads a {
  display: grid;
  grid-template-columns: 88px 1fr;
  align-items: baseline;
  gap: 10px;
  border-top: 1px solid #34373c;
  padding: 7px 0;
}
.country-leads b {
  font-size: clamp(0.88rem, 1.04vw, 1.03rem);
  font-weight: 550;
  line-height: 1.24;
}
.country-leads a:hover,
.studio-story:hover,
.reader-related button:hover {
  color: #ff9186;
}
.desk-all {
  display: inline-block;
  margin-top: 6px;
}
.empty-period {
  font-size: 0.91rem;
  color: var(--sub);
  margin-top: 8px;
}
.archive-status button {
  text-decoration: underline;
}
.archive-tools {
  display: flex;
  gap: 16px;
  align-items: center;
  flex-wrap: wrap;
  margin-top: 19px;
}
.country-directory {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(195px, 1fr));
  gap: 12px;
  margin-top: 26px;
}
.country-directory a {
  padding: 16px 19px;
  border: 1px solid #33363c;
  border-radius: 4px;
  background: linear-gradient(125deg, #1d2024, #151619);
}
.country-directory a:hover {
  border-color: #a65e56;
}
.country-directory small {
  color: #ef8b81;
  font: 12px var(--mono);
}
.country-directory h2 {
  font-size: 1.22rem;
  letter-spacing: -0.025em;
  margin: 6px 0;
}
.country-directory span {
  color: #b6bac0;
  font-size: 0.86rem;
}
.object-camera [data-camera="in"],
.object-camera [data-camera="out"],
.object-camera #zoom-read {
  display: none;
}
#asset-stage,
#asset-sculpture,
.asset-object {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.asset-object {
  border: 0;
  cursor: zoom-in;
}
.hero:has(#asset-stage:not([hidden])) .atlas-head,
.hero:has(#asset-stage:not([hidden])) .atlas-foot {
  padding: 4px 7px;
  border-radius: 3px;
  background: rgba(20, 21, 24, 0.82);
  width: fit-content;
  left: auto;
  right: 12px;
}
.camera,
.atlas-buttons {
  pointer-events: auto;
}
.hero-expanded .hero-copy {
  overflow: auto;
}
.country-copy .link-btn {
  padding: 4px 0;
}
.reader-related {
  padding: 0 24px 24px;
}
.reader-related h3 {
  font: 550 1.05rem var(--sans);
  margin-bottom: 0.55rem;
}
.reader-related button {
  border-top: 1px solid #383a40;
  padding: 8px 0;
  text-align: left;
  display: grid;
  grid-template-columns: 88px 1fr;
  gap: 12px;
  width: 100%;
}
#market-studio {
  margin: clamp(26px, 3.1vw, 48px) 0;
}
.studio-shell {
  display: grid;
  grid-template-columns: 1.46fr 1fr;
  border: 1px solid #353940;
  min-height: 330px;
  background: #191b20;
  overflow: hidden;
  border-radius: 4px 4px 0 0;
}
.studio-view {
  position: relative;
  min-height: 320px;
  isolation: isolate;
  overflow: hidden;
  background: radial-gradient(ellipse at 60% 45%, #373e45, #101114 74%);
}
.studio-view > canvas,
.studio-view > #studio-object {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.studio-view > #studio-object {
  cursor: zoom-in;
}
.studio-view > #studio-pitch {
  inset: 24% 2% 8%;
  width: 96%;
  height: 68%;
  background: linear-gradient(transparent, #14171adb);
  z-index: 2;
}
.studio-motion {
  position: absolute;
  left: 14px;
  bottom: 12px;
  color: #d0d1d4;
  background: #17191dda;
  border: 1px solid #56595f;
  border-radius: 3px;
  padding: 5px 9px;
  font: 12px var(--mono);
  z-index: 3;
}
.studio-info {
  align-self: center;
  padding: clamp(20px, 2.6vw, 44px);
}
.studio-info h3 {
  font-size: clamp(1.8rem, 3.3vw, 3.7rem);
  line-height: 1.02;
  letter-spacing: -0.06em;
  margin: 9px 0;
}
.studio-info > p:not(.eyebrow) {
  color: var(--sub);
  line-height: 1.45;
  max-width: 44ch;
}
.studio-info #studio-instruments:not(:empty) {
  margin: 14px 0;
}
.studio-info #studio-links {
  margin-top: 15px;
}
.studio-story {
  width: 100%;
  text-align: left;
  border-top: 1px solid #444850;
  padding-top: 9px;
  font-weight: 550;
  line-height: 1.3;
}
.studio-story time {
  display: block;
  margin-bottom: 4px;
}
.quote-open,
.archive-status button {
  color: #ef9a90;
  font: 12px var(--mono);
  margin-bottom: 9px;
}
.studio-gallery {
  position: absolute;
  inset: 13% 3%;
  display: flex;
  align-items: center;
  gap: 10px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  perspective: 750px;
}
.studio-gallery button {
  flex: 0 0 56%;
  align-self: stretch;
  position: relative;
  scroll-snap-align: center;
  overflow: hidden;
  isolation: isolate;
  border: 1px solid #474a50;
  border-radius: 4px;
  transition: transform 0.3s;
}
.studio-gallery button:hover {
  transform: translateZ(14px) rotateY(-3deg);
}
.studio-gallery img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.studio-gallery b {
  position: absolute;
  inset: auto 0 0;
  padding: 28px 10px 10px;
  text-align: left;
  font: 550 0.93rem/1.25 var(--sans);
  background: linear-gradient(transparent, #111 73%);
}
#studio-tabs {
  display: flex;
  flex-wrap: wrap;
  background: #17191d;
  border: 1px solid #353940;
  gap: 0;
  border-top: 0;
}
#studio-tabs button {
  padding: 12px 15px;
  color: #c3c5cb;
  font-size: 0.86rem;
}
#studio-tabs button[aria-pressed="true"] {
  color: #fff;
  box-shadow: inset 0 -2px var(--red);
  background: #242629;
}
.price-observation {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 4px 8px;
  margin-top: 10px;
}
.price-observation input {
  width: 100%;
  min-width: 0;
  accent-color: var(--red);
}
.price-observation output {
  grid-column: 1/-1;
  color: #ddd;
}
.desk-chip {
  border-color: #4b4d54;
  margin: 2px;
}
@media (max-width: 820px) {
  .atlas-head .overline {
    font-size: 0;
  }
  .atlas-buttons select {
    max-width: 142px;
  }
  .country-leads a {
    grid-template-columns: 1fr;
    gap: 2px;
  }
  .country-leads a:nth-child(3) {
    display: none;
  }
  .studio-shell {
    grid-template-columns: 1.1fr 1fr;
  }
  .world-rail {
    gap: 10px;
  }
  .world-rail .rail-label {
    min-width: 75px;
  }
}
@media (max-width: 650px) {
  .mast {
    position: relative;
  }
  .atlas-head .overline {
    font-size: 0.65rem;
  }
  .country-copy {
    padding-right: 0;
  }
  .country-leads a {
    grid-template-columns: 82px 1fr;
    gap: 7px;
  }
  .country-leads a:nth-child(3) {
    display: grid;
  }
  .world-rail {
    display: block;
    padding: 8px 12px;
  }
  .world-rail .rail-label {
    margin-bottom: 5px;
  }
  .world-rail > div {
    gap: 2px;
  }
  .world-rail a {
    padding: 5px 7px;
  }
  .studio-shell {
    grid-template-columns: 1fr;
  }
  .studio-view {
    min-height: 235px;
  }
  .studio-info {
    padding: 16px;
  }
  .studio-gallery button {
    flex-basis: 62%;
  }
  #studio-tabs button {
    padding: 10px 12px;
  }
  .country-directory {
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }
  .country-directory a {
    padding: 13px;
  }
  .country-directory h2 {
    font-size: 1rem;
  }
  .archive-tools {
    gap: 9px;
  }
  .hero:has(.country-copy) .hero-copy {
    min-height: 0;
  }
  .hero-expanded .world-rail {
    display: none;
  }
}
@media (prefers-reduced-motion: reduce) {
  .studio-gallery button {
    transition: none;
  }
  .studio-gallery button:hover {
    transform: none;
  }
}
.focus-rail .models-jump {
  margin-left: auto;
  color: #f29489;
  line-height: 1.2;
  padding: 7px 0;
  text-decoration: underline;
  text-underline-offset: 3px;
}
#market-studio,
.hero {
  scroll-margin-top: 80px;
}
@media (max-width: 650px) {
  .focus-rail {
    flex-wrap: wrap;
  }
  .focus-rail .models-jump {
    margin-left: 0;
  }
  .focus-rail #focus-options {
    max-width: 100%;
  }
  #market-studio,
  .hero {
    scroll-margin-top: 12px;
  }
}

/* ============================================================
   Market terminal — interactive chart hero + preserved 3D model
   (markets upgrade 2026-12-02). Graphite/vermilion terminal look,
   IBM Plex Mono data type, editorial restraint.
   ============================================================ */
.hero:has(#asset-stage:not([hidden])) .atlas {
  min-height: 640px;
}
.hero-expanded:has(#asset-stage:not([hidden])) .atlas {
  min-height: 0;
}
.market-terminal {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
}
.terminal-chart {
  flex: 1 1 auto;
  min-height: 0;
  padding: 44px 10px 0 12px;
}
.terminal-model {
  position: relative;
  flex: 0 0 168px;
  border-top: 1px solid #34363a;
  background: radial-gradient(ellipse at 50% 120%, #1d2025 0, #151619 70%);
  overflow: hidden;
}
.terminal-model-tag {
  position: absolute;
  left: 12px;
  top: 8px;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 6px;
  font: 400 0.62rem var(--mono);
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: #9da0a9;
  pointer-events: none;
}
.terminal-model-tag i {
  color: var(--red);
  font-size: 0.85rem;
}
.mc-root {
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 0;
}
.mc-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding: 0 2px 6px;
}
.mc-ranges {
  display: flex;
  gap: 2px;
}
.mc-ranges button {
  font: 400 0.68rem var(--mono);
  color: #bfc1c8;
  padding: 4px 9px;
  border-radius: 3px;
  border: 1px solid transparent;
  background: transparent;
  cursor: pointer;
}
.mc-ranges button:hover:not(:disabled) {
  background: #2a2c31;
  color: #fff;
}
.mc-ranges button[aria-pressed="true"] {
  background: #35373c;
  color: #fff;
  border-color: #4a4d54;
}
.mc-ranges button:disabled {
  opacity: 0.32;
  cursor: default;
}
.mc-tools {
  display: flex;
  align-items: center;
  gap: 8px;
}
.mc-newscount {
  font: 400 0.66rem var(--mono);
  color: #ea6c64;
  white-space: nowrap;
}
.mc-reset {
  width: 24px;
  height: 24px;
  background: #17181bb3;
  border: 1px solid #383b40;
  border-radius: 3px;
  color: #bcbfc5;
  cursor: pointer;
  font-size: 0.8rem;
  line-height: 1;
}
.mc-reset:hover {
  border-color: #696c73;
  color: #fff;
}
.mc-plot {
  position: relative;
  flex: 1 1 auto;
  min-height: 120px;
}
.mc-plot canvas {
  display: block;
  width: 100%;
  height: 100%;
  touch-action: none;
  cursor: crosshair;
  outline: none;
}
.mc-plot canvas:focus-visible {
  box-shadow: 0 0 0 1px var(--red);
}
.mc-legend {
  position: absolute;
  top: 2px;
  left: 60px;
  right: 70px;
  display: flex;
  flex-wrap: wrap;
  gap: 4px 9px;
  font: 400 0.66rem var(--mono);
  color: #c2c4c9;
  pointer-events: none;
}
.mc-l-title {
  color: #8b8e96;
  letter-spacing: 0.05em;
}
.mc-up {
  color: var(--up);
}
.mc-down {
  color: #f87973;
}
.mc-l-close {
  color: #e8e9ec;
}
.mc-l-vol {
  color: #9da0a9;
}
.mc-l-time {
  color: #777a82;
  margin-left: auto;
}
.mc-tooltip {
  position: absolute;
  z-index: 5;
  max-width: 270px;
  background: #17181bf2;
  border: 1px solid #4a4d54;
  border-radius: 4px;
  padding: 8px 10px;
  pointer-events: none;
  box-shadow: 0 6px 18px #00000066;
}
.mc-tip-date {
  font: 400 0.62rem var(--mono);
  color: #ea6c64;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  margin-bottom: 4px;
}
.mc-tip-title {
  font-size: 0.78rem;
  line-height: 1.3;
  color: #e8e9ec;
  margin-bottom: 3px;
}
.mc-tip-more {
  font: 400 0.64rem var(--mono);
  color: #9da0a9;
}
.mc-tip-cta {
  font: 400 0.62rem var(--mono);
  color: #777a82;
  margin-top: 4px;
  border-top: 1px solid #303237;
  padding-top: 4px;
}
.mc-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}
.mc-foot {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 14px;
  align-items: baseline;
  padding: 6px 2px 2px;
  font: 400 0.64rem var(--mono);
  color: #8b8e96;
  border-top: 1px solid #26282c;
  margin-top: 6px;
}
.mc-vol-label {
  color: #b4b6bc;
}
.mc-src a {
  color: #c5c8ce;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.mc-hint {
  margin-left: auto;
  color: #6a6d75;
}
.focus-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 28px;
  margin: 16px 0 4px;
  max-width: 490px;
}
.focus-stats .stat span {
  display: block;
  font: 400 0.62rem var(--mono);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #8b8e96;
  margin-bottom: 3px;
}
.focus-stats .stat b {
  font: 400 0.86rem var(--mono);
  color: #e8e9ec;
}
.focus-stats .stat small {
  display: block;
  font: 400 0.62rem var(--mono);
  color: #777a82;
  margin-top: 2px;
}
.card-rank {
  font: 400 0.68rem var(--mono);
  color: #ea6c64;
  border: 1px solid #4a3230;
  padding: 2px 7px;
  border-radius: 3px;
}
.card-vol {
  display: block;
  font: 400 0.64rem var(--mono);
  color: #8b8e96;
  margin: 2px 0 8px;
}
#watch-rows {
  max-height: 560px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: #3a3d43 transparent;
}
@media (max-width: 1100px) {
  .hero:has(#asset-stage:not([hidden])) .atlas {
    min-height: 600px;
  }
  .terminal-model {
    flex-basis: 140px;
  }
}
@media (max-width: 820px) {
  .hero:has(#asset-stage:not([hidden])) .atlas {
    min-height: 560px;
  }
  .mc-legend {
    left: 48px;
    right: 56px;
  }
  .mc-hint {
    display: none;
  }
}
@media (max-width: 650px) {
  .hero:has(#asset-stage:not([hidden])) .atlas {
    height: 580px;
    min-height: 0;
  }
  .hero:has(#asset-stage:not([hidden])) .atlas-head .overline {
    display: none;
  }
  .terminal-chart {
    padding-top: 38px;
  }
  .terminal-model {
    flex-basis: 120px;
  }
  .mc-legend {
    font-size: 0.6rem;
    gap: 3px 6px;
  }
  .mc-l-time {
    display: none;
  }
  .focus-stats {
    gap: 10px 20px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .mc-ranges button,
  .mc-reset {
    transition: none;
  }
}
