@import url('https://fonts.googleapis.com/css2?family=Barlow+Condensed:wght@500;600;700;800;900&family=Barlow:wght@400;500;600;700;800&display=swap');
:root {
  --forest: #14291e;
  --green: #31543b;
  --lime: #e4b860;
  --paper: #f5f3ea;
  --muted: #aab6a8;
  --line: #ffffff24;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--forest);
  color: var(--paper);
  font-family: Barlow, Arial, sans-serif;
  font-size: 14px;
}
button,
a,
input {
  -webkit-tap-highlight-color: transparent;
}
button {
  font: inherit;
  cursor: pointer;
}
button:focus-visible,
a:focus-visible,
canvas:focus-visible,
input:focus-visible {
  outline: 3px solid var(--lime);
  outline-offset: 4px;
}
button {
  border: 0;
}
button:disabled {
  cursor: default;
}
.hidden {
  display: none !important;
}
.header {
  height: 88px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 36px;
  border-bottom: 1px solid #ffffff18;
  position: relative;
  z-index: 5;
  background: #13271d;
}
.brand {
  color: var(--paper);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 18px;
}
/* The real Top Crop logo from cornwarriorstv.com (656 x 206, transparent). */
.brand-mark {
  display: block;
  flex: none;
  line-height: 0;
}
.brand-mark img {
  display: block;
  height: 52px;
  width: auto;
}
.brand-divider {
  height: 33px;
  width: 1px;
  background: var(--line);
}
.brand-sub {
  font-size: 10px;
  line-height: 1.5;
  font-weight: 700;
  letter-spacing: 2px;
}
.header nav {
  align-self: stretch;
  display: flex;
  gap: 28px;
  /* Centre the navigation and keep the clock and buttons together on the right. */
  margin-inline: auto;
}
.header nav button {
  position: relative;
  background: none;
  color: #acb6aa;
  font-weight: 700;
  letter-spacing: 1.4px;
  font-size: 11px;
  padding: 0 4px;
}
.header nav .nav-shop {
  color: var(--lime);
  font-weight: 700;
  letter-spacing: 1.4px;
  font-size: 11px;
  padding: 0 4px;
  text-decoration: none;
  white-space: nowrap;
}
.header nav button:hover,
.header nav .nav-shop:hover,
.header nav .nav-active {
  color: white;
}
.header nav .nav-active:after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--lime);
}
.header nav span {
  color: var(--lime);
  padding-left: 8px;
}
.profile-btn {
  background: none;
  color: white;
  display: flex;
  gap: 10px;
  align-items: center;
  font-size: 12px;
}
.avatar {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid #ffffff44;
  border-radius: 50%;
  color: var(--lime);
  font-weight: 700;
  font-size: 11px;
}
#world {
  position: relative;
  height: calc(100svh - 88px);
  min-height: 650px;
  overflow: hidden;
  background: linear-gradient(#c7d5bf, #eee0b9);
}
#scene {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  touch-action: none;
  cursor: grab;
}
#scene:active {
  cursor: grabbing;
}
.world-vignette {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, #10271deb 0%, #11291dcf 18%, #18301e78 34%, transparent 62%),
    linear-gradient(0deg, #10271da8, transparent 25%);
  pointer-events: none;
}
.world-topline {
  position: absolute;
  left: 36px;
  top: 25px;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.7px;
}
.live-dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--lime);
  box-shadow: 0 0 10px #e4b86055;
}
.slash {
  opacity: 0.4;
  margin: 0 6px;
}
.prototype {
  border: 1px solid #f5f3ea55;
  padding: 5px 8px;
  font-size: 8px;
  margin-left: 8px;
  letter-spacing: 1px;
}
.intro {
  position: absolute;
  left: 5%;
  top: 18%;
  width: 430px;
}
.eyebrow {
  font-size: 10px;
  letter-spacing: 1.8px;
  font-weight: 700;
  color: var(--lime);
}
h1 {
  font-family: 'Barlow Condensed', Impact, sans-serif;
  font-size: clamp(52px, 5.6vw, 88px);
  line-height: 0.99;
  letter-spacing: -0.6px;
  font-weight: 700;
  margin: 24px 0;
}
h1 em {
  font-style: normal;
  color: var(--lime);
}
.intro p {
  color: #d5dcd1;
  line-height: 1.8;
  font-size: 14px;
  margin: 0 0 28px;
}
.primary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  background: var(--lime);
  color: #17291d;
  font-size: 11px;
  letter-spacing: 1.5px;
  font-weight: 800;
  padding: 17px 20px;
  border-radius: 3px;
  transition:
    background 0.2s,
    transform 0.2s;
}
.primary:hover {
  background: #f3cd7c;
  transform: translateY(-1px);
}
.primary.large {
  width: 284px;
  padding: 20px 22px;
}
.primary span {
  font-size: 20px;
  line-height: 10px;
}
.text-link {
  display: flex;
  gap: 10px;
  align-items: center;
  background: none;
  color: #e4e8df;
  font-size: 11px;
  padding: 20px 0;
}
.text-link:hover {
  color: var(--lime);
}
.play-small {
  font-size: 8px;
  border: 1px solid #fff7;
  border-radius: 50%;
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
}
.intro-facts {
  display: flex;
  gap: 25px;
  border-top: 1px solid #ffffff26;
  padding-top: 22px;
  margin-top: 18px;
}
.intro-facts span {
  display: flex;
  flex-direction: column;
  gap: 7px;
  font-size: 8px;
  letter-spacing: 1px;
  color: #becbbd;
}
.intro-facts b {
  font-family: 'Barlow Condensed', Impact, sans-serif;
  font-size: 26px;
  color: white;
  font-weight: 600;
}
.score-stack {
  position: absolute;
  right: 28px;
  top: 77px;
  width: 220px;
  display: grid;
  gap: 10px;
}
.score-card {
  background: #152b20f2;
  color: var(--paper);
  text-align: left;
  border: 1px solid #ffffff20;
  padding: 20px;
  border-radius: 5px;
  backdrop-filter: blur(12px);
}
.score-card > .eyebrow {
  display: flex;
  justify-content: space-between;
  color: #c1d0bb;
  font-size: 9px;
}
.tiny-arrow {
  font-size: 14px;
  color: var(--lime);
}
.score-card strong {
  font-family: 'Barlow Condensed', Impact, sans-serif;
  font-size: 62px;
  font-weight: 600;
  line-height: 1.35;
}
.score-unit {
  font-size: 17px;
  color: #b6c1ae;
  margin-left: 10px;
}
.score-caption {
  font-size: 7px;
  letter-spacing: 1.3px;
  color: #bfccb8;
  display: block;
  line-height: 1.5;
}
.score-line {
  height: 3px;
  background: #ffffff20;
  margin-top: 15px;
}
.score-line i {
  height: 100%;
  width: 0;
  display: block;
  background: var(--lime);
  transition: width 0.6s;
}
.real-score {
  display: flex;
  align-items: center;
  gap: 11px;
  border: 1px solid #fff3;
  background: #f6f3e9ee;
  color: var(--forest);
  padding: 14px 12px;
  border-radius: 4px;
  text-align: left;
}
.real-score b {
  font-size: 9px;
  letter-spacing: 1.7px;
}
.real-score small {
  display: block;
  font-size: 9px;
  margin-top: 4px;
}
.score-icon {
  font-size: 24px;
  color: #63724d;
}
.real-score > span:last-child {
  margin-left: auto;
}
#markers {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.world-marker {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 11px;
  background: #f5f3eaf5;
  box-shadow: 0 4px 20px #1a2b2222;
  color: var(--forest);
  border-radius: 5px;
  padding: 11px 14px;
  pointer-events: auto;
  white-space: nowrap;
  transform: translate(-50%, -100%);
  text-align: left;
  border: 1px solid white;
}
.world-marker:after {
  content: '';
  position: absolute;
  left: 50%;
  top: 100%;
  height: 24px;
  width: 1px;
  background: #f5f3ea;
}
.world-marker b {
  font-size: 10px;
  letter-spacing: 1.5px;
}
.world-marker small {
  display: block;
  font-size: 10px;
  margin-top: 3px;
  color: #657359;
}
.marker-symbol {
  border: 1px solid #b9c4a9;
  border-radius: 50%;
  height: 29px;
  width: 29px;
  display: grid;
  place-items: center;
  color: #4c6b40;
  font-size: 18px;
}
.marker-arrow {
  margin-left: 12px;
  font-size: 20px;
}
.world-marker.subtle {
  padding: 8px 11px;
  background: #193022eb;
  color: #f5f3ea;
  border: 1px solid #ffffff40;
}
.world-marker.subtle small {
  color: #becab7;
}
.world-marker.subtle .marker-symbol {
  color: var(--lime);
  border-color: #d9e5c34a;
}
.location-tag {
  position: absolute;
  right: 28px;
  bottom: 158px;
  display: flex;
  gap: 10px;
  align-items: center;
  font-size: 11px;
  letter-spacing: 1.5px;
  color: #fcfff5;
  text-shadow: 0 1px 6px #152b20;
}
.location-tag > span:first-child {
  font-size: 28px;
}
.location-tag small {
  display: block;
  font-size: 7px;
  margin-top: 6px;
  letter-spacing: 1.4px;
}
.camera-tools {
  position: absolute;
  right: 28px;
  bottom: 214px;
  display: grid;
  gap: 1px;
  border: 1px solid #ffffff50;
  border-radius: 4px;
  overflow: hidden;
  background: #193022ed;
}
.camera-tools button {
  width: 38px;
  height: 37px;
  color: white;
  background: none;
  font-size: 21px;
}
.camera-tools button:hover,
.camera-tools .selected {
  background: #e4b860;
  color: #14291e;
}
.camera-tools > span {
  height: 1px;
  background: #ffffff40;
  grid-column: 1 / -1;
}
@media (min-width: 701px) {
  .camera-tools {
    grid-template-columns: repeat(2, 1fr);
  }
}
/* Hover label and the info card for places picked in the 3D farm. */
.world-hover {
  position: absolute;
  z-index: 4;
  pointer-events: none;
  padding: 5px 9px;
  border-radius: 4px;
  background: #14291eeb;
  color: #f5f3ea;
  font-size: 11px;
  letter-spacing: 0.4px;
  white-space: nowrap;
  box-shadow: 0 4px 14px #0004;
}
.world-hover.hidden,
.world-card.hidden {
  display: none;
}
.world-card {
  position: absolute;
  z-index: 4;
  width: min(310px, calc(100vw - 24px));
  transform: translate(-50%, calc(-100% - 18px));
  padding: 14px 16px 15px;
  border-radius: 6px;
  background: #f5f3eaf7;
  color: var(--forest, #14291e);
  border: 1px solid #fff;
  box-shadow: 0 10px 34px #1a2b2240;
  animation: world-card-in 0.18s ease-out;
}
.world-card:after {
  content: '';
  position: absolute;
  left: 50%;
  top: 100%;
  width: 1px;
  height: 18px;
  background: #f5f3ea;
}
.world-card.offscreen {
  visibility: hidden;
}
.world-card .eyebrow {
  color: #657359;
}
.world-card h3 {
  margin: 4px 26px 6px 0;
  font-size: 18px;
}
.world-card p {
  margin: 0 0 10px;
  font-size: 13px;
  line-height: 1.45;
  color: #3d4c3a;
}
.world-card-close {
  position: absolute;
  top: 6px;
  right: 8px;
  width: 30px;
  height: 30px;
  background: none;
  color: #3d4c3a;
  font-size: 20px;
}
.world-card-grow {
  height: 5px;
  border-radius: 3px;
  background: #d9dccb;
  margin: 0 0 12px;
  overflow: hidden;
}
.world-card-grow i {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #6d893b, #e4b860);
}
.world-card-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.world-card-actions button {
  padding: 8px 11px;
  font-size: 11px;
}
@keyframes world-card-in {
  from {
    opacity: 0;
    margin-top: 6px;
  }
}
@media (max-width: 700px) {
  .world-card {
    left: 12px !important;
    right: 12px;
    top: auto !important;
    bottom: 120px;
    width: auto;
    transform: none;
  }
  .world-card:after {
    display: none;
  }
}
body:not(.playing) .world-card,
body.entering .world-card {
  display: none;
}
.world-controls {
  position: absolute;
  bottom: 140px;
  left: 36px;
  font-size: 8px;
  letter-spacing: 1.5px;
  display: flex;
  align-items: center;
  gap: 12px;
  color: #d5deca;
}
.mouse-icon {
  font-size: 19px;
}
.farm-dock {
  position: absolute;
  left: 28px;
  right: 28px;
  bottom: 24px;
  min-height: 93px;
  display: flex;
  align-items: center;
  gap: 30px;
  background: #f5f3eaf7;
  border: 1px solid #fff;
  color: var(--forest);
  padding: 20px 26px;
  border-radius: 6px;
  box-shadow: 0 8px 40px #10271d22;
}
.dock-identity {
  display: flex;
  align-items: center;
  gap: 15px;
  min-width: 230px;
}
.field-icon {
  width: 48px;
  height: 48px;
  border: 1px solid #c5ccb6;
  border-radius: 4px;
  font-size: 34px;
  display: grid;
  place-items: center;
  color: #647747;
  background: #e9ecdf;
}
.dock-identity .eyebrow {
  font-size: 8px;
  color: #6e795f;
  letter-spacing: 1.5px;
}
.dock-identity h3 {
  font-family: 'Barlow Condensed', Impact, sans-serif;
  font-size: 25px;
  margin: 3px 0 0;
  font-weight: 600;
}
.dock-stat {
  border-left: 1px solid #d5d9c9;
  padding-left: 28px;
  flex: 1;
  white-space: nowrap;
}
.dock-stat > span {
  font-size: 8px;
  letter-spacing: 1.2px;
  color: #6c785f;
  display: block;
  margin-bottom: 8px;
}
.dock-stat b {
  font-size: 14px;
  font-weight: 600;
}
.dock-stat small {
  font-size: 11px;
  font-weight: 400;
  color: #76816c;
}
.dock-action {
  background: var(--forest);
  color: white;
  border-radius: 3px;
  white-space: nowrap;
  font-size: 9px;
  letter-spacing: 1.2px;
  padding: 17px 20px;
  font-weight: 700;
}
.dock-action span {
  margin-left: 20px;
  color: var(--lime);
}
.mission-card {
  position: absolute;
  top: 90px;
  left: 36px;
  width: 290px;
  background: #14291ef2;
  backdrop-filter: blur(12px);
  border: 1px solid #ffffff2d;
  border-radius: 6px;
  padding: 22px;
}
.mission-card .eyebrow {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 8px;
}
.mission-card .eyebrow > span:last-child {
  margin-left: auto;
  color: #adbaa4;
}
.mission-card h2 {
  font-family: 'Barlow Condensed', Impact, sans-serif;
  font-size: 34px;
  line-height: 1.05;
  margin: 20px 0 12px;
}
.mission-card p {
  font-size: 12px;
  line-height: 1.7;
  color: #cbd5c4;
  margin-bottom: 20px;
}
.mission-card .primary {
  width: 100%;
  font-size: 9px;
  padding: 15px;
}
.mission-progress {
  height: 3px;
  background: #ffffff20;
  margin-top: 22px;
}
.mission-progress span {
  display: block;
  height: 3px;
  background: var(--lime);
  width: 0;
  transition: width 0.5s;
}
.mission-card > small {
  font-size: 8px;
  letter-spacing: 1.6px;
  color: #aab99f;
  display: block;
  margin-top: 10px;
}
.movement {
  position: absolute;
  bottom: 186px;
  left: 32px;
  text-align: center;
}
.movement button {
  height: 40px;
  width: 42px;
  background: #152b20db;
  color: white;
  border: 1px solid #ffffff55;
  border-radius: 4px;
  font-size: 20px;
  margin: 2px;
  touch-action: none;
}
.engine-status {
  position: absolute;
  bottom: 4px;
  right: 30px;
  font-size: 8px;
  letter-spacing: 1px;
  color: #ced7c3;
}
.modal-overlay {
  position: fixed;
  inset: 0;
  background: #091b15bd;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  backdrop-filter: blur(8px);
}
.modal {
  background: var(--paper);
  color: var(--forest);
  width: 650px;
  max-width: 100%;
  max-height: 90svh;
  overflow-y: auto;
  position: relative;
  border-radius: 10px;
  padding: 38px;
  box-shadow: 0 30px 100px #0004;
}
.modal.wide {
  width: 920px;
}
.modal-close {
  position: absolute;
  right: 16px;
  top: 13px;
  background: #e6e8dc;
  color: #284030;
  border-radius: 50%;
  height: 29px;
  width: 29px;
  font-size: 23px;
  z-index: 2;
}
.modal .eyebrow {
  color: #7b784c;
  font-size: 9px;
}
.modal h2 {
  font-family: 'Barlow Condensed', Impact, sans-serif;
  font-size: 42px;
  line-height: 1.05;
  font-weight: 600;
  margin: 15px 0;
}
.modal p {
  line-height: 1.7;
  color: #61705e;
  font-size: 14px;
}
.modal .lead {
  font-size: 16px;
  color: #304932;
}
.question-context {
  padding: 17px 20px;
  background: #e7ebdd;
  border-left: 3px solid #9caa7b;
  font-size: 13px;
  line-height: 1.7;
  color: #3e543d;
  margin: 23px 0;
}
.choices {
  display: grid;
  gap: 10px;
  margin: 20px 0;
}
.choice {
  display: flex;
  align-items: center;
  gap: 16px;
  text-align: left;
  background: #fff;
  border: 1px solid #d9dfd0;
  border-radius: 5px;
  padding: 16px;
  color: #304730;
  font-size: 13px;
  line-height: 1.5;
}
.choice:hover:not(:disabled) {
  border-color: #6c8355;
  background: #f0f3e7;
}
.choice-letter {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  flex-shrink: 0;
  border-radius: 4px;
  border: 1px solid #d6decc;
  font-weight: 700;
  color: #71825d;
}
.choice.correct {
  border-color: #5d8558;
  background: #e4eddd;
}
.choice.incorrect {
  border-color: #c49966;
  background: #f0e4d5;
}
.feedback {
  background: #e6eddd;
  border-radius: 5px;
  padding: 20px;
  margin: 18px 0;
  line-height: 1.7;
  font-size: 13px;
}
.feedback strong {
  display: block;
  font-size: 15px;
  margin-bottom: 6px;
}
.modal-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  margin-top: 24px;
}
.modal-foot small {
  font-size: 10px;
  line-height: 1.5;
  color: #7b856f;
}
.secondary {
  background: #e3e7da;
  padding: 13px 17px;
  border-radius: 4px;
  color: var(--forest);
  font-weight: 700;
  font-size: 11px;
  letter-spacing: 0.5px;
}
.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
}
.metric-box {
  background: #e7ebde;
  padding: 22px;
  border-radius: 5px;
}
.metric-box strong {
  font-family: 'Barlow Condensed', Impact, sans-serif;
  font-size: 52px;
  font-weight: 600;
  display: block;
}
.metric-box small {
  font-size: 11px;
  line-height: 1.6;
  color: #61705e;
  display: block;
}
.metric-box .eyebrow {
  color: #617346;
}
.score-big {
  font-family: 'Barlow Condensed', Impact, sans-serif;
  font-size: 84px;
  font-weight: 600;
  color: #46633d;
  margin: 10px 0;
}
.score-big span {
  font-size: 24px;
  color: #8a967c;
}
.stage-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 24px;
}
.lesson-card {
  padding: 18px;
  text-align: left;
  background: #e8ecdf;
  border: 1px solid #d6ddcb;
  border-radius: 5px;
  color: var(--forest);
}
.lesson-card b {
  font-size: 15px;
  display: block;
  margin: 8px 0;
}
.lesson-card small {
  font-size: 10px;
  color: #748063;
  line-height: 1.5;
}
.lesson-card:hover {
  border-color: #738c5c;
}
.lesson-number {
  font-size: 10px;
  color: #71815d;
  letter-spacing: 1.5px;
}
.rank-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  margin-top: 20px;
}
.rank-table th {
  text-align: left;
  font-size: 9px;
  letter-spacing: 1px;
  color: #748063;
  padding: 12px 10px;
  border-bottom: 1px solid #cbd5bf;
}
.rank-table td {
  padding: 15px 10px;
  border-bottom: 1px solid #dfe5d6;
}
.rank-table tr.you {
  background: #e3ead7;
}
.tabs {
  display: flex;
  gap: 7px;
  margin: 20px 0;
}
.tabs button {
  padding: 12px 16px;
  background: #e1e7d7;
  font-size: 11px;
  font-weight: 700;
  color: #526547;
  border-radius: 4px;
}
.tabs .active {
  background: var(--forest);
  color: white;
}
.form-label {
  display: block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1px;
  margin: 24px 0 8px;
}
.farm-input {
  width: 100%;
  border: 1px solid #becbac;
  background: #fff;
  padding: 14px;
  font: inherit;
  border-radius: 4px;
  color: var(--forest);
}
.notice {
  font-size: 11px;
  line-height: 1.7;
  padding: 15px;
  background: #e9ecdf;
  border-radius: 4px;
  color: #657457;
}
.video-frame {
  position: relative;
  aspect-ratio: 16/9;
  background: #14291e;
  margin: 22px 0;
  border-radius: 6px;
  overflow: hidden;
}
.video-frame iframe {
  width: 100%;
  height: 100%;
  border: 0;
}
.links-row {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  margin-top: 20px;
}
.links-row a,
.source-link {
  font-size: 11px;
  color: #47603b;
  text-decoration: underline;
  text-underline-offset: 4px;
}
.source-link {
  display: inline-block;
  margin-top: 15px;
}
.summary-list {
  padding: 0;
  list-style: none;
}
.summary-list li {
  display: flex;
  justify-content: space-between;
  gap: 15px;
  padding: 12px 0;
  border-bottom: 1px solid #dce2d2;
  font-size: 12px;
}
.toast {
  position: fixed;
  bottom: 140px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 30;
  background: #152b20;
  color: #f4e6bf;
  box-shadow: 0 5px 30px #0003;
  border: 1px solid #d5b65d55;
  border-radius: 5px;
  padding: 16px 23px;
  font-size: 13px;
  max-width: 90%;
  text-align: center;
}
.control-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.control-grid div {
  background: #e8ecde;
  padding: 15px;
  font-size: 12px;
  line-height: 1.6;
}
.control-grid b {
  display: block;
  margin-bottom: 5px;
}
.harvest-badge {
  height: 78px;
  width: 78px;
  border: 2px solid #bea258;
  color: #7f783c;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 40px;
  margin: 10px auto;
}
.result-title {
  text-align: center;
}
.modal small {
  line-height: 1.5;
}
@media (min-height: 950px) {
  .intro {
    top: 22%;
  }
}
@media (max-height: 800px) and (min-width: 901px) {
  #world {
    min-height: 620px;
  }
  .intro {
    top: 15%;
  }
  h1 {
    font-size: 65px;
    margin: 18px 0;
  }
  .intro p {
    margin-bottom: 18px;
  }
  .intro-facts {
    margin-top: 4px;
    padding-top: 14px;
  }
}
@media (max-width: 1100px) {
  .header {
    padding: 0 24px;
  }
  .header nav {
    gap: 18px;
  }
  .header nav button,
  .header nav .nav-shop {
    font-size: 9px;
  }
  .brand-sub {
    display: none;
  }
  .brand-divider {
    display: none;
  }
  .brand-mark img {
    height: 44px;
  }
  .score-stack {
    width: 180px;
    right: 20px;
  }
  .score-card {
    padding: 16px;
  }
  .score-card strong {
    font-size: 50px;
  }
  .real-score small {
    font-size: 8px;
  }
  .intro {
    left: 4%;
    width: 390px;
  }
  .farm-dock {
    gap: 18px;
    padding: 18px;
  }
  .dock-identity {
    min-width: 190px;
  }
  .dock-stat {
    padding-left: 18px;
  }
  .dock-stat:nth-of-type(3) {
    display: none;
  }
  .world-topline {
    left: 28px;
  }
  .mission-card {
    left: 25px;
    width: 260px;
  }
  .world-controls {
    left: 28px;
  }
}
@media (max-width: 700px) {
  .header {
    height: 70px;
    padding: 0 18px;
  }
  .brand-mark img {
    height: 42px;
  }
  .brand-sub {
    display: block;
    font-size: 8px;
    letter-spacing: 1.3px;
  }
  .brand-divider {
    display: block;
    height: 26px;
  }
  .brand {
    gap: 10px;
    margin-right: auto;
  }
  .header nav {
    display: none;
  }
  .profile-btn {
    gap: 6px;
  }
  .profile-btn > span:not(.avatar) {
    display: none;
  }
  .avatar {
    width: 32px;
    height: 32px;
  }
  #world {
    height: calc(100svh - 70px);
    min-height: 720px;
  }
  .world-topline {
    top: 18px;
    left: 18px;
    gap: 7px;
    font-size: 8px;
    letter-spacing: 1px;
  }
  .prototype {
    font-size: 6px;
    padding: 4px;
    margin-left: 0;
  }
  .slash {
    margin: 0 3px;
  }
  .intro {
    left: 24px;
    top: 92px;
    width: calc(100% - 48px);
  }
  h1 {
    font-size: 58px;
    line-height: 0.98;
    margin: 18px 0;
  }
  .intro p {
    font-size: 13px;
    line-height: 1.6;
    max-width: 275px;
    margin-bottom: 20px;
  }
  .intro > .eyebrow {
    font-size: 8px;
    letter-spacing: 1.3px;
  }
  .primary.large {
    width: 245px;
    padding: 18px;
  }
  .text-link {
    font-size: 10px;
    padding: 15px 0;
  }
  .intro-facts {
    gap: 22px;
    width: 280px;
    margin-top: 3px;
    padding-top: 14px;
  }
  .intro-facts span {
    font-size: 7px;
  }
  .intro-facts b {
    font-size: 22px;
  }
  .score-stack {
    right: 14px;
    top: auto;
    bottom: 163px;
    width: 140px;
    gap: 6px;
  }
  .score-card {
    padding: 12px;
    background: #152b20e8;
  }
  .score-card > .eyebrow {
    font-size: 7px;
    letter-spacing: 1px;
  }
  .score-card strong {
    font-size: 38px;
  }
  .score-unit {
    font-size: 13px;
  }
  .score-caption {
    font-size: 6px;
    letter-spacing: 0.5px;
  }
  .score-line {
    margin-top: 9px;
  }
  .real-score {
    padding: 9px;
    gap: 7px;
  }
  .real-score b {
    font-size: 8px;
  }
  .real-score small {
    display: none;
  }
  .score-icon {
    font-size: 19px;
  }
  .farm-dock {
    left: 12px;
    right: 12px;
    bottom: 16px;
    gap: 12px;
    padding: 14px;
    min-height: 113px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    row-gap: 13px;
  }
  .dock-identity {
    min-width: 0;
    gap: 9px;
  }
  .field-icon {
    height: 35px;
    width: 35px;
    font-size: 25px;
  }
  .dock-identity h3 {
    font-size: 22px;
  }
  .dock-identity .eyebrow {
    font-size: 6px;
  }
  .dock-stat {
    padding-left: 12px;
    flex: none;
  }
  .dock-stat > span {
    font-size: 7px;
    margin-bottom: 5px;
  }
  .dock-stat b {
    font-size: 12px;
  }
  .dock-stat:nth-of-type(3),
  .dock-stat:nth-of-type(4) {
    display: none;
  }
  .dock-action {
    grid-column: 1 / -1;
    padding: 12px;
    font-size: 8px;
    text-align: center;
  }
  .dock-action span {
    margin-left: 30px;
  }
  .location-tag {
    left: 18px;
    right: auto;
    bottom: 155px;
    font-size: 8px;
  }
  .location-tag small {
    font-size: 6px;
    letter-spacing: 1px;
  }
  .location-tag > span:first-child {
    font-size: 23px;
  }
  .world-controls {
    display: none;
  }
  .camera-tools {
    right: 14px;
    bottom: 360px;
    grid-template-columns: repeat(3, 1fr);
    gap: 1px;
  }
  .camera-tools > span {
    display: none;
  }
  .camera-tools button {
    width: 33px;
    height: 32px;
    font-size: 19px;
  }
  .world-vignette {
    background:
      linear-gradient(90deg, #10271de6, #11291dab 50%, #18301e33),
      linear-gradient(0deg, #10271d80, transparent 40%);
  }
  body.playing .world-vignette {
    background: linear-gradient(0deg, #10271d70, transparent 35%);
  }
  body.playing .score-stack {
    bottom: 164px;
  }
  body:not(.playing) #markers {
    display: none;
  }
  .world-marker {
    padding: 8px;
    gap: 6px;
  }
  .world-marker b {
    font-size: 8px;
  }
  .world-marker small {
    font-size: 8px;
  }
  .marker-symbol {
    height: 23px;
    width: 23px;
    font-size: 15px;
  }
  .marker-arrow {
    display: none;
  }
  #marker-barn {
    display: none;
  }
  .mission-card {
    top: 55px;
    left: 14px;
    width: calc(100% - 28px);
    padding: 16px;
    background: #14291eeb;
  }
  .mission-card h2 {
    font-size: 29px;
    margin: 12px 0 7px;
  }
  .mission-card p {
    font-size: 11px;
    line-height: 1.6;
    margin: 7px 0 12px;
  }
  .mission-card .primary {
    padding: 13px;
  }
  .mission-progress {
    margin-top: 13px;
  }
  .mission-card > small {
    font-size: 7px;
    margin-top: 8px;
  }
  .modal-overlay {
    padding: 12px;
  }
  .modal {
    padding: 30px 22px;
    max-height: 94svh;
  }
  .modal h2 {
    font-size: 35px;
  }
  .modal p {
    font-size: 13px;
  }
  .choice {
    padding: 12px;
    font-size: 12px;
    gap: 10px;
  }
  .modal-foot {
    flex-wrap: wrap;
  }
  .modal-foot .primary {
    width: 100%;
  }
  .stage-grid {
    gap: 8px;
  }
  .lesson-card {
    padding: 13px;
  }
  .lesson-card b {
    font-size: 13px;
  }
  .metric-box {
    padding: 16px;
  }
  .metric-box strong {
    font-size: 42px;
  }
  .engine-status {
    font-size: 6px;
    right: 16px;
    bottom: 3px;
  }
  .movement {
    left: 15px;
    bottom: 210px;
  }
  .movement button {
    height: 36px;
    width: 38px;
  }
  .toast {
    bottom: 145px;
    width: max-content;
    font-size: 12px;
  }
  .rank-table {
    font-size: 11px;
  }
  .rank-table td,
  .rank-table th {
    padding: 12px 6px;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    scroll-behavior: auto !important;
    transition: none !important;
    animation: none !important;
  }
}
@media (min-width: 701px) {
  .intro {
    top: 15%;
  }
  h1 {
    font-size: clamp(52px, 5.1vw, 78px);
    margin: 20px 0;
  }
  .intro-facts {
    margin-top: 4px;
    padding-top: 15px;
  }
}
.mobile-menu {
  display: none;
}
@media (max-width: 700px) {
  .mobile-menu {
    display: block;
    background: none;
    color: #f5f3ea;
    font-size: 22px;
    width: 40px;
    height: 40px;
    margin-left: auto;
    margin-right: 12px;
  }
  .dock-identity h3 {
    font-size: 19px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 135px;
  }
  .dock-identity {
    gap: 7px;
  }
  .field-icon {
    width: 30px;
    height: 33px;
    font-size: 23px;
    flex-shrink: 0;
  }
  .farm-dock {
    grid-template-columns: 1.2fr 1fr;
  }
  .location-tag {
    bottom: 178px;
  }
  .camera-tools button {
    width: 36px;
    height: 36px;
  }
  .modal .choice {
    min-height: 48px;
  }
}
@media (max-width: 700px) {
  body:not(.playing) .score-stack,
  body:not(.playing) .camera-tools {
    display: none;
  }
}
/* Cinematic layer: a lightweight photographic landing page, a deferred 3D world. */
#world {
  background: #17291d;
}
.cinematic-layer {
  position: absolute;
  inset: 0;
  z-index: 1;
  overflow: hidden;
  pointer-events: none;
  opacity: 1;
  transition:
    opacity 2.5s ease,
    filter 2.5s ease;
}
.cinematic-layer img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 58% 52%;
  transform: scale(1.025);
  animation: opening-drift 30s ease-in-out infinite alternate;
}
/* Landing scenery (landing-scenes.js): later scenes stack over the opening photo and cross-fade in. */
.cinematic-layer img.scene-shot {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: var(--kb-from);
  transition: opacity 4.5s cubic-bezier(0.45, 0, 0.25, 1);
  animation: scene-drift 24s linear forwards;
  will-change: opacity, transform;
}
.cinematic-layer img.scene-shot.in {
  opacity: 1;
}
.cinematic-layer img.scene-gone {
  opacity: 0;
  animation: none;
}
@keyframes scene-drift {
  from {
    transform: var(--kb-from);
  }
  to {
    transform: var(--kb-to);
  }
}
.scene-label {
  display: block;
  margin-top: 6px;
  font-size: 7px;
  font-weight: 400;
  letter-spacing: 2px;
  color: #e9e4cebf;
  text-transform: uppercase;
  opacity: 0;
  transition: opacity 1.2s ease;
}
.scene-label.show {
  opacity: 1;
}
.world-vignette {
  z-index: 2;
  background:
    linear-gradient(90deg, #0c1b13ed, #1020179c 28%, #122a1930 55%, transparent 80%),
    linear-gradient(0deg, #0c1b148c, transparent 38%);
  transition: background 2s;
}
.world-topline,
.intro,
.score-stack,
.location-tag,
.camera-tools,
.world-controls,
.farm-dock,
.mission-card,
.engine-status,
#markers,
.movement {
  z-index: 3;
}
.cinematic-grain {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  opacity: 0.04;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' opacity='.6' filter='url(%23n)'/%3E%3C/svg%3E");
}
.intro {
  top: 16%;
  transition:
    opacity 0.8s,
    transform 1.2s;
}
.intro p {
  text-shadow: 0 2px 8px #0005;
}
.intro-facts {
  max-width: 365px;
}
.intro .eyebrow {
  color: #edd095;
}
.primary {
  box-shadow: 0 3px 18px #0001;
}
.score-card {
  background: #14271edb;
  backdrop-filter: blur(10px);
}
.real-score {
  background: #f5f0e2ed;
}
.landing-credit {
  position: absolute;
  z-index: 3;
  left: 5%;
  right: 28px;
  bottom: 38px;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  font-size: 8px;
  letter-spacing: 2px;
  color: #e9e4ce;
  border-top: 1px solid #ffffff38;
  padding-top: 20px;
}
.landing-credit > span:last-child {
  text-align: right;
  font-size: 7px;
  line-height: 1.9;
}
.landing-credit i {
  display: block;
  font-style: normal;
  font-size: 9px;
  letter-spacing: 2px;
  color: #edcf96;
}
.engine-status {
  opacity: 0.65;
  font-size: 7px;
}
.film-bar {
  position: absolute;
  left: 0;
  right: 0;
  height: 0;
  background: #08120d;
  z-index: 8;
  pointer-events: none;
  transition: height 0.8s;
}
.film-bar.top {
  top: 0;
}
.film-bar.bottom {
  bottom: 0;
}
.transition-title {
  position: absolute;
  left: 0;
  right: 0;
  top: 42%;
  z-index: 9;
  text-align: center;
  pointer-events: none;
  opacity: 0;
  color: #fff8e8;
  text-shadow: 0 2px 35px #000c;
}
.transition-title small,
.transition-title span {
  display: block;
  font-size: 9px;
  letter-spacing: 4px;
}
.transition-title strong {
  display: block;
  font-family: 'Barlow Condensed', Impact, sans-serif;
  font-size: 64px;
  letter-spacing: 5px;
  font-weight: 500;
  margin: 12px 0;
}
.skip-cinematic {
  position: absolute;
  z-index: 10;
  right: 30px;
  bottom: 65px;
  background: transparent;
  color: #f8f1d9;
  border: 1px solid #ffffff55;
  border-radius: 3px;
  padding: 12px 16px;
  font-size: 9px;
  letter-spacing: 2px;
  display: none;
}
body:not(.playing) #markers,
body:not(.playing) .camera-tools,
body:not(.playing) .location-tag,
body:not(.playing) .farm-dock,
body:not(.playing) .world-controls {
  display: none;
}
body:not(.playing) #scene {
  opacity: 0;
}
body.playing .cinematic-layer {
  opacity: 0;
  filter: blur(3px);
}
body.playing .cinematic-layer img {
  transform: scale(1.18);
  transition: transform 3s ease-out;
  animation: none;
}
body.playing .landing-credit {
  display: none;
}
body.playing .world-vignette {
  background: linear-gradient(0deg, #14291e72, transparent 30%);
}
body.playing #scene {
  opacity: 1;
}
body.entering .film-bar {
  height: 7%;
}
body.entering .transition-title {
  animation: location-reveal 2.9s ease both;
}
body.entering .skip-cinematic {
  display: block;
}
body.entering .mission-card,
body.entering .score-stack,
body.entering .farm-dock,
body.entering #markers,
body.entering .location-tag,
body.entering .camera-tools,
body.entering .world-controls,
body.entering .movement {
  opacity: 0;
  pointer-events: none;
}
body.entering #scene {
  animation: world-focus 2.6s ease-out;
}
.mission-card,
.farm-dock,
.score-stack,
.camera-tools {
  transition: opacity 0.5s ease;
}
.primary:disabled {
  opacity: 0.85;
  cursor: wait;
}
.farm-input select,
select.farm-input {
  appearance: auto;
  font: inherit;
  font-size: 13px;
}
.source-link {
  line-height: 1.6;
}
@keyframes opening-drift {
  from {
    transform: scale(1.025) translate3d(0, 0, 0);
  }
  to {
    transform: scale(1.085) translate3d(-0.5%, -0.4%, 0);
  }
}
@keyframes location-reveal {
  0%,
  8% {
    opacity: 0;
    transform: translateY(12px);
  }
  30%,
  74% {
    opacity: 1;
    transform: translateY(0);
  }
  100% {
    opacity: 0;
    transform: translateY(-8px);
  }
}
@keyframes world-focus {
  from {
    filter: blur(4px);
    opacity: 0.25;
  }
  65% {
    filter: blur(0);
    opacity: 1;
  }
  to {
    filter: blur(0);
    opacity: 1;
  }
}
@media (max-width: 1100px) {
  .landing-credit {
    left: 4%;
  }
  .intro {
    top: 14%;
  }
}
@media (max-width: 700px) {
  .cinematic-layer img {
    object-position: 62% 50%;
  }
  .intro {
    top: 97px;
    left: 24px;
  }
  .landing-credit {
    left: 24px;
    right: 24px;
    bottom: 33px;
    display: block;
    padding-top: 17px;
    line-height: 1.8;
    font-size: 7px;
    letter-spacing: 1.5px;
  }
  .landing-credit > span:last-child {
    display: block;
    text-align: left;
    margin-top: 12px;
    font-size: 6px;
  }
  .landing-credit i {
    font-size: 8px;
  }
  .world-vignette {
    background:
      linear-gradient(90deg, #0b1a12d9, #0e211680 65%, #0e211630),
      linear-gradient(0deg, #0d2016b0, transparent 45%);
  }
  .intro-facts {
    width: 100%;
    max-width: 300px;
    gap: 26px;
  }
  .transition-title strong {
    font-size: 42px;
    letter-spacing: 2px;
  }
  .transition-title small,
  .transition-title span {
    font-size: 7px;
    letter-spacing: 2px;
  }
  .skip-cinematic {
    bottom: 70px;
    right: 18px;
    padding: 11px;
    font-size: 8px;
  }
  body.playing .world-topline {
    font-size: 7px;
  }
  .camera-tools {
    grid-template-columns: repeat(3, 1fr);
    bottom: 365px;
  }
  .camera-tools button {
    width: 38px;
    height: 38px;
  }
  .score-stack {
    bottom: 175px;
  }
  .location-tag {
    bottom: 182px;
  }
  body:not(.playing) .engine-status {
    font-size: 5px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .cinematic-layer img {
    animation: none !important;
    transform: none !important;
  }
  .cinematic-layer {
    transition: opacity 0.1s !important;
    filter: none !important;
  }
  .transition-title,
  .film-bar,
  .cinematic-grain {
    display: none !important;
  }
  body.entering #scene {
    animation: none !important;
  }
}
body.replaying .cinematic-layer {
  transition: opacity 0.5s;
  filter: none;
}
/* Front-page topic finder: search the show's topic index or pick a topic from the list. */
.landing-rail {
  position: absolute;
  z-index: 4;
  right: 28px;
  top: 77px;
  width: 280px;
  display: grid;
  gap: 12px;
  transition: opacity 0.6s;
}
.topic-finder {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 16px 18px 18px;
  border: 1px solid #e5c27840;
  border-radius: 6px;
  background: linear-gradient(145deg, #0f2219ee, #163628e0);
  box-shadow: 0 12px 45px #0003;
  backdrop-filter: blur(12px);
}
.topic-finder > .eyebrow {
  font-size: 9px;
  letter-spacing: 2px;
  color: #e8c985;
}
.topic-finder-row {
  display: flex;
  align-items: center;
  background: #0a1710cc;
  border: 1px solid #ffffff2e;
  border-radius: 4px;
  transition:
    border-color 0.2s,
    box-shadow 0.2s;
}
.topic-finder-row:focus-within {
  border-color: var(--lime);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--lime) 25%, transparent);
}
.topic-finder-row > span {
  padding: 0 2px 0 10px;
  color: var(--muted);
}
.topic-finder-row input {
  flex: 1;
  min-width: 0;
  background: none;
  border: 0;
  color: white;
  font: inherit;
  font-size: 12px;
  padding: 11px 6px;
  outline: none;
}
.topic-finder-row input::placeholder {
  color: #aab6a8cc;
}
.topic-finder-row button {
  background: none;
  color: var(--lime);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 1.2px;
  padding: 11px 10px;
}
.topic-finder-row button:hover {
  color: white;
}
.topic-finder select {
  background: #0a1710b3;
  color: #d5dcd1;
  border: 1px solid #ffffff20;
  border-radius: 4px;
  font: inherit;
  font-size: 11px;
  padding: 8px 10px;
}
.topic-finder select:focus-visible {
  outline: 2px solid var(--lime);
  outline-offset: 1px;
}
@media (max-height: 800px) and (min-width: 701px) {
  .landing-rail {
    gap: 8px;
  }
  .landing-rail .premiere-card h3 {
    font-size: 28px;
    margin: 10px 0 12px;
  }
  .landing-rail .promo-date {
    margin-bottom: 12px;
  }
  .landing-rail .premiere-countdown {
    padding: 11px 0;
  }
  .landing-rail .promo-actions {
    margin-top: 12px;
  }
  .topic-finder {
    gap: 6px;
    padding: 12px 14px 14px;
  }
  .topic-finder-row input,
  .topic-finder-row button {
    padding-block: 9px;
  }
}
/* Mobile: the countdown on top, then a single search row. The topic list opens once the search is in use. */
@media (max-width: 700px) {
  .landing-rail {
    gap: 8px;
  }
  .topic-finder {
    padding: 0;
    border: 0;
    background: none;
    box-shadow: none;
    backdrop-filter: none;
    gap: 6px;
  }
  .topic-finder > .eyebrow {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
  }
  .topic-finder-row {
    background: #0c1b13e6;
    border-color: #e5c27855;
    border-radius: 5px;
    backdrop-filter: blur(10px);
  }
  .topic-finder-row input {
    font-size: 16px;
    padding: 9px 6px;
  }
  .topic-finder select {
    display: none;
    font-size: 16px;
  }
  .topic-finder:focus-within select {
    display: block;
  }
}

/* Top bar: room for the farm clock chip and the sign-in/sign-out button. */
@media (max-width: 1100px) and (min-width: 701px) {
  .profile-btn > span:not(.avatar) {
    display: none;
  }
}
@media (max-width: 960px) and (min-width: 701px) {
  .header nav {
    gap: 12px;
  }
}
@media (max-width: 420px) {
  .brand-sub,
  .brand-divider {
    display: none !important;
  }
}

/* Front page on shorter desktop and laptop screens. The intro column has grown (casting pill, sponsor
   badge, social row) and so has the right rail, so tighten the spacing here. landing-fit.js grows the
   landing for anything that still doesn't fit, so nothing is cut off or drawn under the credit line. */
@media (max-height: 1100px) and (min-width: 701px) {
  body:not(.playing) #world .intro {
    top: 11%;
  }
  body:not(.playing) #world .intro-facts {
    display: none;
  }
  body:not(.playing) #world .intro h1 {
    font-size: clamp(48px, 4.6vw, 70px);
    margin: 16px 0;
  }
  body:not(.playing) #world .intro p {
    margin-bottom: 18px;
  }
  body:not(.playing) #world .intro .text-link {
    padding: 12px 0;
  }
  .landing-credit {
    bottom: 22px;
    padding-top: 12px;
  }
  /* End the credit line before the right rail so its text never sits behind the cards. */
  body:not(.playing) .landing-credit {
    right: 332px;
  }
}
@media (max-height: 1150px) and (min-width: 701px) {
  .landing-rail {
    gap: 8px;
  }
  .landing-rail .premiere-card {
    padding: 18px 20px;
  }
  .landing-rail .premiere-card h3 {
    font-size: 28px;
    margin: 10px 0 12px;
  }
  .landing-rail .promo-date {
    margin-bottom: 12px;
  }
  .landing-rail .premiere-countdown {
    padding: 11px 0;
  }
  .landing-rail .promo-actions {
    margin-top: 12px;
  }
  .topic-finder {
    gap: 6px;
    padding: 12px 14px 14px;
  }
  .topic-finder-row input,
  .topic-finder-row button {
    padding-block: 9px;
  }
}
