/* Mielovia origins atlas 1.2.0 (plugin): the map of terroirs and the traceability walk in one block, in the Origins
   room (in place of the theme's two sections) and in the home's Traceability band (light version, .mla-light). A lens in the middle holds the Earth, then the photographs of each step, then the jar's lid;
   the terroir is on its left, the step on its right, the walk under it. */

/* The theme's two sections stay in the page for its scripts, out of sight. */
#terroirs-theme[hidden],
#trace-theme[hidden] { display: none !important; }

.mla {
  --lens: clamp(300px, min(42vw, 100vh - 330px), 600px);
  --mla-ease: cubic-bezier(.2, .7, .1, 1);
  background: var(--ink-2, #120e0a);
  overflow: hidden;
}
.mla-anchor { position: absolute; top: 0; left: 0; width: 1px; height: 1px; pointer-events: none; }
.mla .section-head { margin-bottom: clamp(30px, 4vw, 56px); }

.mla-atlas {
  --mla-ease: cubic-bezier(.2, .7, .1, 1);
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) var(--lens) minmax(0, 1fr);
  grid-template-areas:
    "pick pick pick"
    "id   lens step"
    "walk walk walk"
    "play play play"
    "fine fine fine";
  column-gap: clamp(28px, 3.6vw, 64px);
  align-items: center;
}

/* ---- Terroirs ---- */
.mla-pick {
  grid-area: pick;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin-bottom: clamp(24px, 2.6vw, 40px);
}
.mla-chip {
  display: grid;
  gap: 3px;
  justify-items: start;
  min-height: 54px;
  padding: 8px 16px 10px 14px;
  border: 1px solid var(--line-2, rgba(216, 178, 110, .3));
  border-radius: 14px;
  background: transparent;
  color: var(--ivory, #f3ece0);
  text-align: left;
  cursor: pointer;
  transition: border-color .25s, background-color .25s;
}
.mla-chip .c {
  font-family: var(--f-mono);
  font-size: .62rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--faint, #75695b);
  transition: color .25s;
}
.mla-chip .f {
  display: inline-flex;
  align-items: center;
  gap: .5em;
  font-family: var(--f-display);
  font-size: 1.06rem;
  line-height: 1.1;
  white-space: nowrap;
}
.mla-chip .f::before {
  content: "";
  flex: none;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--line-2, rgba(216, 178, 110, .3));
  transition: background-color .25s, box-shadow .25s;
}
.mla-chip:hover { border-color: var(--gold, #d8b26e); }
.mla-chip[aria-pressed="true"] { border-color: var(--gold, #d8b26e); background: rgba(216, 178, 110, .1); }
.mla-chip[aria-pressed="true"] .c { color: var(--gold, #d8b26e); }
.mla-chip[aria-pressed="true"] .f::before { background: var(--amber, #e39b32); box-shadow: 0 0 0 3px rgba(227, 155, 50, .22); }

/* ---- The terroir (left) and the step (right), each hugging the lens ---- */
.mla-id,
.mla-step { display: grid; gap: 12px; align-content: center; min-width: 0; }
.mla-id { grid-area: id; justify-self: end; justify-items: end; text-align: right; max-width: 30ch; }
.mla-step { grid-area: step; justify-self: start; justify-items: start; max-width: 34ch; }
.mla-k {
  margin: 0;
  font-family: var(--f-mono);
  font-size: var(--s--1, .8rem);
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--gold, #d8b26e);
}
.mla-of { color: var(--faint, #75695b); }
.mla-name {
  margin: 0;
  font-family: var(--f-display);
  font-weight: 400;
  font-size: clamp(2.2rem, 1.05rem + 2.6vw, 4rem);
  line-height: .98;
  letter-spacing: -.01em;
  font-variation-settings: "SOFT" 100, "opsz" 144;
  color: var(--ivory, #f3ece0);
  overflow-wrap: anywhere;
}
.mla-latin {
  margin: -4px 0 6px;
  font-family: var(--f-display);
  font-style: italic;
  font-size: 1.15rem;
  color: var(--cream, #e5d6bb);
}
.mla-kv { text-align: left; }
.mla-sv {
  margin: 0;
  font-family: var(--f-display);
  font-weight: 400;
  font-size: clamp(1.5rem, 1rem + 1.15vw, 2.2rem);
  line-height: 1.12;
  font-variation-settings: "SOFT" 100, "opsz" 72;
  color: var(--ivory, #f3ece0);
}
.mla-sv2 {
  display: block;
  margin-top: .35em;
  font-family: var(--f-body);
  font-size: .95rem;
  line-height: 1.35;
  letter-spacing: 0;
  color: var(--muted, #a69684);
}
.mla-sv2::first-letter { text-transform: uppercase; }
.mla-st { margin: 0; line-height: 1.55; color: var(--cream, #e5d6bb); }
.mla-atlas[data-step="lot"] .mla-sv { font-family: var(--f-mono); font-size: clamp(1.05rem, .7rem + .9vw, 1.45rem); letter-spacing: .04em; white-space: nowrap; }
.mla-x .pill-state { line-height: 1.5; border-radius: 12px; }
.mla-x { display: grid; gap: 10px; justify-items: inherit; }
.mla-x:empty { display: none; }
.mla-x p { margin: 0; }
.mla-geo { font-family: var(--f-mono); font-size: .74rem; letter-spacing: .1em; color: var(--muted, #a69684); }
.mla-x .pill-state { justify-self: inherit; }
.mla-step.swap > * { animation: mla-in .6s var(--mla-ease) both; }
.mla-step.swap > :nth-child(2) { animation-delay: .05s; }
.mla-step.swap > :nth-child(3) { animation-delay: .1s; }
.mla-step.swap > :nth-child(4) { animation-delay: .15s; }
.mla-id.swap > * { animation: mla-in .6s var(--mla-ease) both; }
@keyframes mla-in { from { opacity: 0; transform: translateY(8px); } }

/* ---- The lens ---- */
.mla-lens {
  grid-area: lens;
  position: relative;
  width: var(--lens);
  aspect-ratio: 1;
  border-radius: 50%;
  isolation: isolate;
  touch-action: pan-y;
  -webkit-user-select: none;
  user-select: none;
}
.mla-lens::before {          /* outer hairline, a little away from the glass */
  content: "";
  position: absolute;
  inset: -14px;
  border-radius: 50%;
  border: 1px solid rgba(216, 178, 110, .16);
  pointer-events: none;
}
.mla-lens::after {           /* the glass: rim and a soft highlight, over everything */
  content: "";
  position: absolute;
  inset: 0;
  z-index: 6;
  border-radius: 50%;
  box-shadow: inset 0 0 0 1px rgba(216, 178, 110, .4), inset 0 0 0 2px rgba(11, 8, 6, .5), inset 0 0 50px rgba(0, 0, 0, .35);
  background: radial-gradient(120% 90% at 28% 12%, rgba(255, 244, 220, .07), rgba(255, 244, 220, 0) 45%);
  pointer-events: none;
}
.mla-space {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 46%, #18120c 0%, #0b0806 58%, #050403 100%);
  box-shadow: 0 40px 90px -40px rgba(0, 0, 0, .9);
}
.mla-earth {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  opacity: 0;
  transition: opacity 1.4s var(--mla-ease);
  cursor: grab;
}
.mla-earth.on { opacity: 1; }
.mla-earth.grab { cursor: grabbing; }
.mla-atlas:not([data-step="earth"]):not([data-step="region"]) .mla-earth { cursor: default; }

/* Pins: one per terroir, on the side of the Earth that faces us. */
.mla-pins { position: absolute; inset: 0; z-index: 2; pointer-events: none; transition: opacity .5s; }
.mla-atlas:not([data-step="earth"]):not([data-step="region"]) .mla-pins,
.mla-pins.off { opacity: 0; visibility: hidden; transition: opacity .3s, visibility 0s .3s; }
.mla-pin {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 0;
  height: 0;
  pointer-events: auto;
  cursor: pointer;
  will-change: transform;
}
.mla-pin::before {           /* touch area */
  content: "";
  position: absolute;
  left: -16px;
  top: -16px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
}
.mla-pin i {
  position: absolute;
  left: -4px;
  top: -4px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gold, #d8b26e);
  box-shadow: 0 0 0 2px rgba(11, 8, 6, .55), 0 0 12px rgba(240, 198, 74, .55);
  transition: transform .3s;
}
.mla-pin:hover i { transform: scale(1.35); }
.mla-pin.on i { left: -6px; top: -6px; width: 12px; height: 12px; background: var(--amber, #e39b32); }
.mla-pin.on i::after {
  content: "";
  position: absolute;
  inset: -2px;
  border-radius: 50%;
  border: 1.5px solid var(--amber, #e39b32);
  animation: mla-pulse 2.4s ease-out infinite;
}
@keyframes mla-pulse { from { transform: scale(1); opacity: .9; } to { transform: scale(3.6); opacity: 0; } }
.mla-pin b {
  position: absolute;
  left: 14px;
  top: -12px;
  display: none;
  white-space: nowrap;
  padding: 3px 9px 4px;
  border: 1px solid rgba(216, 178, 110, .45);
  border-radius: 999px;
  background: rgba(11, 8, 6, .74);
  font-family: var(--f-mono);
  font-size: .64rem;
  font-weight: 400;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ivory, #f3ece0);
}
.mla-pin.on b { display: block; }
.mla-pin.on.left b { left: auto; right: 14px; }
.mla-pin.dim { opacity: .55; }

/* Photographs: the incoming one fades in over the last, or opens from the pin. */
.mla-photos {
  position: absolute;
  inset: 0;
  z-index: 3;
  border-radius: 50%;
  overflow: hidden;
  pointer-events: none;
}
.mla-photos img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transform: scale(1.05);
  transition: opacity .8s var(--mla-ease), transform 1.4s var(--mla-ease);
}
.mla-photos img.in { opacity: 1; transform: none; }
.mla-photos img.rv { opacity: 1; transform: none; clip-path: circle(0% at 50% 50%); transition: clip-path 1.05s cubic-bezier(.7, 0, .2, 1); }
.mla-photos img.rv.in { clip-path: circle(72% at 50% 50%); }
.mla-photos img.gone { opacity: 0; transition: opacity .6s var(--mla-ease); }
.mla-tag {
  position: absolute;
  left: 50%;
  bottom: 7%;
  z-index: 5;
  transform: translateX(-50%);
  padding: 3px 10px 4px;
  border-radius: 999px;
  background: rgba(11, 8, 6, .58);
  font-family: var(--f-mono);
  font-size: .6rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ivory, #f3ece0);
  pointer-events: none;
}
.mla-tag[hidden] { display: none; }

/* The lid of the jar: black, knurled, with a round paper label and its code. */
.mla-lid {
  position: absolute;
  inset: 0;
  z-index: 4;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 46%, #18120c 0%, #0b0806 58%, #050403 100%);
  opacity: 0;
  transform: rotate(-38deg) scale(.9);
  transition: opacity .55s var(--mla-ease), transform 1.1s cubic-bezier(.2, .85, .2, 1);
  pointer-events: none;
}
.mla-lid.in { opacity: 1; transform: none; }
.mla-cap {
  position: absolute;
  inset: 4%;
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 50%, #1d1a17 0 76%, rgba(0, 0, 0, 0) 76.5%),
    repeating-conic-gradient(from 0deg, #2b2724 0deg 1.2deg, #0d0c0b 1.2deg 2.4deg);
  box-shadow: 0 18px 50px rgba(0, 0, 0, .65), inset 0 0 0 1px rgba(255, 255, 255, .06);
}
.mla-cap::after {           /* light on the black lid */
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: radial-gradient(90% 70% at 30% 18%, rgba(255, 255, 255, .13), rgba(255, 255, 255, 0) 55%);
  pointer-events: none;
}
.mla-label {
  position: absolute;
  inset: 13%;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--paper, #eee5d4);
  box-shadow: inset 0 0 0 1px rgba(138, 90, 20, .35), inset 0 0 0 7px var(--paper, #eee5d4), inset 0 0 0 8px rgba(138, 90, 20, .28), 0 2px 6px rgba(0, 0, 0, .4);
  color: var(--paper-ink, #1d1610);
}
.mla-ring { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.mla-ring text {
  font-family: var(--f-mono);
  font-size: 8.4px;
  letter-spacing: .14em;
  fill: #6a5b4a;
  text-transform: uppercase;
}
.mla-qrbox { display: grid; justify-items: center; gap: 6px; width: 50%; }
.mla-qr { width: 100%; aspect-ratio: 1; }
.mla-qr svg, .mla-qr canvas { display: block; width: 100%; height: 100%; }
.mla-qr.none { display: grid; place-items: center; border: 1px dashed rgba(29, 22, 16, .3); font-family: var(--f-mono); font-size: .7rem; }
.mla-lot { margin: 0; font-family: var(--f-mono); font-size: clamp(.56rem, .4rem + .45vw, .74rem); letter-spacing: .08em; color: var(--paper-ink, #1d1610); white-space: nowrap; }
.mla-seal {                 /* the gold seal over the edge, as on the jars */
  position: absolute;
  left: 50%;
  top: -1%;
  width: 9%;
  height: 15%;
  transform: translateX(-50%);
  border-radius: 2px;
  background: linear-gradient(90deg, #a77a2e, #e9c77e 45%, #c4974a 60%, #8d6322);
  box-shadow: 0 2px 6px rgba(0, 0, 0, .45);
}
.mla-seal::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 55%;
  width: 46%;
  aspect-ratio: .866;
  transform: translate(-50%, -50%);
  clip-path: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%);
  background: rgba(70, 45, 10, .55);
}

/* ---- The walk ---- */
.mla-walk {
  grid-area: walk;
  justify-self: center;
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) 44px;
  align-items: start;
  gap: 14px;
  width: min(100%, 1000px);
  margin-top: clamp(24px, 2.6vw, 40px);
}
.mla-arw {
  margin-top: 5px;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid var(--line-2, rgba(216, 178, 110, .3));
  border-radius: 50%;
  background: transparent;
  color: var(--ivory, #f3ece0);
  cursor: pointer;
  transition: border-color .25s, background-color .25s, opacity .25s;
}
.mla-arw:hover:not(:disabled) { border-color: var(--gold, #d8b26e); background: rgba(216, 178, 110, .1); }
.mla-arw:disabled { opacity: .3; cursor: default; }
.mla-rail {
  position: relative;
  display: grid;
  grid-template-columns: repeat(8, minmax(0, 1fr));
  margin: 0;
  padding: 0;
  list-style: none;
}
.mla-rail li { position: relative; display: flex; justify-content: center; min-width: 0; }
.mla-rail li + li::before {  /* the thread from the previous step */
  content: "";
  position: absolute;
  top: 27px;
  right: 50%;
  width: 100%;
  height: 1px;
  background: var(--line-2, rgba(216, 178, 110, .3));
  transition: background-color .4s;
}
.mla-rail li.done + li::before { background: var(--gold, #d8b26e); }
.mla-rail button {
  position: relative;
  z-index: 1;
  display: grid;
  justify-items: center;
  gap: 10px;
  width: 100%;
  padding: 0 2px 4px;
  border: 0;
  background: none;
  color: var(--muted, #a69684);
  font: inherit;
  cursor: pointer;
}
.mla-rail .th {
  position: relative;
  display: block;
  width: 54px;
  height: 54px;
  overflow: hidden;
  border-radius: 50%;
  background: var(--ink-3, #1a1510);
  box-shadow: 0 0 0 1px var(--line-2, rgba(216, 178, 110, .3));
  transition: box-shadow .35s;
}
.mla-rail .th img { display: block; width: 100%; height: 100%; object-fit: cover; opacity: .55; filter: saturate(.7); transition: opacity .35s, filter .35s; }
.mla-rail .th-lot {          /* a tiny lid: black rim, paper label, the corners of a code */
  background:
    linear-gradient(#1d1610, #1d1610) 37% 37% / 9% 9% no-repeat,
    linear-gradient(#1d1610, #1d1610) 63% 37% / 9% 9% no-repeat,
    linear-gradient(#1d1610, #1d1610) 37% 63% / 9% 9% no-repeat,
    linear-gradient(#8a5a14, #8a5a14) 58% 58% / 6% 6% no-repeat,
    radial-gradient(circle, #eee5d4 0 44%, #8a5a14 45% 47%, #eee5d4 48% 58%, #1d1a17 59% 100%);
  opacity: .7;
}
.mla-rail .l { display: inline-flex; align-items: baseline; gap: .45em; font-size: .8rem; line-height: 1.2; white-space: nowrap; transition: color .35s; }
.mla-rail .n { font-family: var(--f-mono); font-size: .62rem; letter-spacing: .06em; font-variant-numeric: tabular-nums; color: var(--faint, #75695b); transition: color .35s; }
.mla-rail button:hover .th { box-shadow: 0 0 0 1px var(--gold, #d8b26e); }
.mla-rail button:hover .th img,
.mla-rail li.done .th img { opacity: .85; filter: none; }
.mla-rail li.done .th { box-shadow: 0 0 0 1px var(--gold, #d8b26e); }
.mla-rail li.done .th-lot,
.mla-rail button:hover .th-lot { opacity: .9; }
.mla-rail button[aria-current="step"] .th { box-shadow: 0 0 0 2px var(--amber, #e39b32), 0 0 0 7px rgba(227, 155, 50, .16); }
.mla-rail button[aria-current="step"] .th img,
.mla-rail button[aria-current="step"] .th-lot { opacity: 1; filter: none; }
.mla-rail button[aria-current="step"] .l { color: var(--ivory, #f3ece0); }
.mla-rail button[aria-current="step"] .n { color: var(--amber, #e39b32); }
.mla-tools {
  grid-area: play;
  justify-self: center;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: center;
  gap: 14px 28px;
  margin-top: 24px;
}
.mla-find { display: grid; gap: 6px; justify-items: start; }
.mla-find label { font-family: var(--f-mono); font-size: .62rem; letter-spacing: .14em; text-transform: uppercase; color: var(--faint, #75695b); }
.mla-find-row { display: flex; }
.mla-find input {
  width: 15.5em;
  min-height: 40px;
  padding: .45em .9em;
  border: 1px solid var(--line-2, rgba(216, 178, 110, .3));
  border-right: 0;
  border-radius: 999px 0 0 999px;
  background: rgba(11, 8, 6, .5);
  color: var(--ivory, #f3ece0);
  font-family: var(--f-mono);
  font-size: .78rem;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.mla-find input::placeholder { color: var(--faint, #75695b); }
.mla-find input:focus { outline: 0; border-color: var(--gold, #d8b26e); }
.mla-find button {
  min-height: 40px;
  padding: .45em 1.1em;
  border: 1px solid var(--gold, #d8b26e);
  border-radius: 0 999px 999px 0;
  background: var(--gold, #d8b26e);
  color: var(--ink, #0b0806);
  font-family: var(--f-mono);
  font-size: .66rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  cursor: pointer;
}
.mla-find button:hover { background: var(--amber, #e39b32); border-color: var(--amber, #e39b32); }
.mla-find button:focus-visible { outline: 2px solid var(--gold, #d8b26e); outline-offset: 3px; }
.mla-find-msg { min-height: 1.2em; font-size: .78rem; color: var(--muted, #a69684); }
.mla-find-msg:empty { display: none; }
.mla-play {
  align-self: flex-end;
  display: inline-flex;
  align-items: center;
  gap: .65em;
  min-height: 40px;
  padding: .5em 1.15em .5em 1em;
  border: 1px solid var(--line-2, rgba(216, 178, 110, .3));
  border-radius: 999px;
  background: transparent;
  color: var(--cream, #e5d6bb);
  font-family: var(--f-mono);
  font-size: .68rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  cursor: pointer;
  transition: border-color .25s, background-color .25s, color .25s;
}
.mla-play:hover { border-color: var(--gold, #d8b26e); background: rgba(216, 178, 110, .08); }
.mla-play .pa,
.mla-play.on .pl { display: none; }
.mla-play.on .pa { display: inline; }
.mla-play.on { border-color: var(--amber, #e39b32); color: var(--ivory, #f3ece0); }
.mla-play:focus-visible { outline: 2px solid var(--gold, #d8b26e); outline-offset: 3px; }
.mla-lotanchor { position: absolute; top: calc(-1 * (var(--nav-h, 64px) + 18px)); left: 0; width: 1px; height: 1px; pointer-events: none; }
.mla-fine { grid-area: fine; justify-self: center; max-width: 72ch; margin: clamp(26px, 3vw, 40px) 0 0; text-align: center; }

.mla-chip:focus-visible,
.mla-arw:focus-visible,
.mla-rail button:focus-visible { outline: 2px solid var(--gold, #d8b26e); outline-offset: 3px; }
.mla-rail button:focus-visible { outline: 0; }
.mla-rail button:focus-visible .th { outline: 2px solid var(--gold, #d8b26e); outline-offset: 4px; }

/* ---- Tablets and phones: one column, the lens first ---- */
@media (max-width: 1099px) {
  .mla { --lens: min(86vw, 540px, 70vh); }
  .mla-atlas {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas: "pick" "lens" "walk" "play" "step" "id" "find" "fine";
    justify-items: center;
  }
  .mla-pick {
    flex-wrap: nowrap;
    justify-content: flex-start;
    width: calc(100% + 2 * var(--gutter, 16px));
    margin-inline: calc(-1 * var(--gutter, 16px));
    padding: 2px var(--gutter, 16px) 6px;
    overflow-x: auto;
    scroll-snap-type: x proximity;
    scroll-padding-inline: var(--gutter, 16px);
    scrollbar-width: none;
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 var(--gutter, 16px), #000 calc(100% - var(--gutter, 16px)), transparent);
    mask-image: linear-gradient(90deg, transparent, #000 var(--gutter, 16px), #000 calc(100% - var(--gutter, 16px)), transparent);
  }
  .mla-pick::-webkit-scrollbar { display: none; }
  .mla-chip { flex: none; scroll-snap-align: start; }
  .mla-walk { width: 100%; margin-top: clamp(26px, 5vw, 40px); grid-template-columns: 40px minmax(0, 1fr) 40px; gap: 6px; }
  .mla-arw { width: 40px; height: 40px; margin-top: 7px; }
  .mla-rail {
    grid-template-columns: repeat(8, 86px);
    overflow-x: auto;
    scroll-snap-type: x proximity;
    scrollbar-width: none;
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 18px, #000 calc(100% - 18px), transparent);
    mask-image: linear-gradient(90deg, transparent, #000 18px, #000 calc(100% - 18px), transparent);
  }
  .mla-rail::-webkit-scrollbar { display: none; }
  .mla-rail li { scroll-snap-align: center; }
  .mla-step,
  .mla-id { justify-self: center; justify-items: center; text-align: center; max-width: 40ch; }
  .mla-step { margin-top: clamp(22px, 4.5vw, 34px); min-height: 13.5em; align-content: start; }
  .mla-tools { display: contents; }
  .mla-play { grid-area: play; align-self: center; margin-top: 18px; }
  .mla-find { grid-area: find; justify-items: center; text-align: center; margin-top: 30px; }
  .mla-find input { width: min(15.5em, 56vw); }
  .mla-id { margin-top: 30px; padding-top: 30px; border-top: 1px solid var(--line, rgba(216, 178, 110, .16)); width: min(100%, 40ch); }
  .mla-name { font-size: clamp(2rem, 1.2rem + 3.6vw, 3rem); }
}
@media (max-width: 1099px) and (min-width: 700px) {
  .mla-rail { grid-template-columns: repeat(8, minmax(0, 1fr)); overflow: visible; -webkit-mask-image: none; mask-image: none; }
  .mla-pick { justify-content: safe center; }
}
@media (max-width: 380px) {
  .mla-chip { padding-inline: 12px; }
  .mla-chip .f { font-size: .98rem; }
}

/* ---- 1.1.0 · On a paper band (the home's Traceability section): same block, ink on paper; the lens keeps the night ---- */
.mla-wrap { width: 100%; }
.mla-light {
  --ivory: var(--paper-ink, #1d1610);
  --cream: #3d3226;
  --muted: #5f5143;
  --faint: #76685a;
  --gold: #8a5a14;
  --line: rgba(29, 22, 16, .14);
  --line-2: rgba(29, 22, 16, .24);
  --ink-2: var(--paper, #eee5d4);
  --ink-3: #e4d9c4;
  --lens: clamp(300px, min(40vw, 100vh - 330px), 580px);
  color: var(--paper-ink, #1d1610);
}
.mla-light .mla-lens {
  --ivory: #f3ece0;
  --cream: #e5d6bb;
  --muted: #a69684;
  --faint: #75695b;
  --gold: #d8b26e;
  --line: rgba(216, 178, 110, .16);
  --line-2: rgba(216, 178, 110, .3);
}
.mla-light .mla-lens::before { border-color: rgba(138, 90, 20, .3); }
.mla-light .mla-space { box-shadow: 0 34px 80px -34px rgba(29, 22, 16, .6), 0 0 0 1px rgba(29, 22, 16, .08); }
.mla-light .mla-chip { background: #f8f2e8; }
.mla-light .mla-chip:hover { background: #fffaf1; }
.mla-light .mla-chip[aria-pressed="true"] { background: #fffaf1; box-shadow: 0 6px 18px -10px rgba(29, 22, 16, .35); }
.mla-light .mla-chip[aria-pressed="true"] .f::before { box-shadow: 0 0 0 3px rgba(227, 155, 50, .25); }
.mla-light .mla-arw { background: #f8f2e8; }
.mla-light .mla-arw:hover:not(:disabled) { background: #fffaf1; }
.mla-light .mla-rail .th { box-shadow: 0 0 0 1px var(--line-2), 0 4px 10px -6px rgba(29, 22, 16, .4); }
.mla-light .mla-rail .th img { opacity: .72; filter: saturate(.85); }
.mla-light .mla-rail li.done .th { box-shadow: 0 0 0 1px var(--gold), 0 4px 10px -6px rgba(29, 22, 16, .4); }
.mla-light .mla-rail button[aria-current="step"] .th { box-shadow: 0 0 0 2px var(--amber, #e39b32), 0 0 0 7px rgba(227, 155, 50, .2); }
.mla-light .mla-rail button[aria-current="step"] .n { color: #a8620e; }
.mla-light .mla-x .pill-state { color: #8a5a14; border-color: #8a5a14; }
.mla-light .mla-play { background: #f8f2e8; color: var(--paper-ink, #1d1610); }
.mla-light .mla-play:hover { background: #fffaf1; border-color: #8a5a14; }
.mla-light .mla-play.on { border-color: var(--amber, #e39b32); color: var(--paper-ink, #1d1610); }
.mla-light .mla-find input { background: #fbf8f2; color: var(--paper-ink, #1d1610); }
.mla-light .mla-find input:focus { border-color: #8a5a14; }
.mla-light .mla-find button { background: var(--paper-ink, #1d1610); border-color: var(--paper-ink, #1d1610); color: #f6f0e6; }
.mla-light .mla-find button:hover { background: #3d3226; border-color: #3d3226; }
.mla-light :focus-visible { outline-color: #8a5a14; }
@media (max-width: 1099px) {
  .mla-light { --lens: min(86vw, 520px, 68vh); }
  .mla-light .mla-id { border-top-color: var(--line); }
}

@media (prefers-reduced-motion: reduce) {
  .mla-step.swap > *,
  .mla-id.swap > * { animation: none; }
  .mla-photos img,
  .mla-photos img.rv { transform: none; clip-path: none; transition: opacity .3s; }
  .mla-lid { transform: none; transition: opacity .3s; }
  .mla-pin.on i::after { animation: none; }
  .mla-earth { transition: opacity .3s; }
}

/* ---- 1.2.0 · The walk plays by itself: the ring of the step shown fills until the next step (it stops while the
   walk waits); the Earth says it can be turned. ---- */
@property --mla-p { syntax: "<number>"; inherits: false; initial-value: 0; }
.mla-rail button::after {
  content: "";
  position: absolute;
  z-index: 2;
  top: -6px;
  left: 50%;
  width: 66px;
  height: 66px;
  margin-left: -33px;
  border-radius: 50%;
  background: conic-gradient(var(--amber, #e39b32) calc(var(--mla-p) * 360deg), transparent 0);
  -webkit-mask: radial-gradient(closest-side, transparent calc(100% - 2px), #000 calc(100% - 1.5px));
  mask: radial-gradient(closest-side, transparent calc(100% - 2px), #000 calc(100% - 1.5px));
  opacity: 0;
  pointer-events: none;
  transition: opacity .3s;
}
.mla-auto .mla-rail button[aria-current="step"]::after { opacity: 1; animation: mla-fill-a var(--mla-step-ms, 5600ms) linear both; }
.mla-auto.mla-t2 .mla-rail button[aria-current="step"]::after { animation-name: mla-fill-b; }
.mla-auto.mla-wait .mla-rail button[aria-current="step"]::after { opacity: .45; animation-play-state: paused; }
@keyframes mla-fill-a { from { --mla-p: 0; } to { --mla-p: 1; } }
@keyframes mla-fill-b { from { --mla-p: 0; } to { --mla-p: 1; } }
.mla-hint {
  position: absolute;
  left: 50%;
  bottom: 3.4%;
  z-index: 5;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 4px 11px 5px 9px;
  border: 1px solid rgba(216, 178, 110, .4);
  border-radius: 999px;
  background: rgba(11, 8, 6, .7);
  color: #f3ece0;
  font-family: var(--f-mono);
  font-size: .6rem;
  letter-spacing: .12em;
  line-height: 1.2;
  text-transform: uppercase;
  white-space: nowrap;
  transform: translate(-50%, 4px);
  opacity: 0;
  pointer-events: none;
  transition: opacity .5s var(--mla-ease), transform .5s var(--mla-ease);
}
.mla-hint svg { flex: none; color: var(--gold, #d8b26e); }
.mla-turnable:not(.mla-turned)[data-step="earth"] .mla-hint,
.mla-turnable:not(.mla-turned)[data-step="region"] .mla-hint { opacity: 1; transform: translate(-50%, 0); transition-delay: 1.2s; }
@media (max-width: 699px) {
  .mla-hint { bottom: 6.5%; padding: 3px 9px 4px 8px; font-size: .55rem; gap: 6px; }   /* inside the circle where it narrows */
  .mla-rail { padding-top: 8px; margin-top: -8px; }   /* the row scrolls sideways here, so it clips: room for the ring */
}
@media (prefers-reduced-motion: reduce) {
  .mla-auto .mla-rail button[aria-current="step"]::after { animation: none; opacity: 0; }
  .mla-hint { transition: opacity .3s; transform: translate(-50%, 0); }
}
