/* RareOnion 16px tiles, original sprites at 2x. No isometric transforms. */
.game-shell,
.farm-scroll,
.farm-world {
  background: #559438;
}
.farm-world {
  width: var(--world-width, 2560px) !important;
  height: var(--world-height, 1792px) !important;
  margin-left: auto;
  margin-right: auto;
}
.environment,
.world-objects,
.field {
  display: contents;
}
.terrain-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  image-rendering: pixelated;
  pointer-events: none;
}
.scene-prop > .art {
  width: 100%;
  height: 100%;
  display: block;
}
.atlas-art {
  overflow: hidden;
}
.atlas-art image {
  image-rendering: pixelated;
}
.frame-track > .atlas-art {
  width: calc(100% / var(--frames));
  height: 100%;
  max-width: none;
  flex-shrink: 0;
}
.composite-art {
  position: relative;
}
.composite-art .art {
  width: 100%;
  height: 100%;
}
.world-objects button {
  padding: 0;
  background: none;
  border: 0;
  border-radius: 0;
  outline: none;
}
.world-objects button:hover {
  background: none;
  outline: none;
  filter: drop-shadow(0 0 3px #fff3ad);
}
.world-objects button:focus-visible {
  outline: 2px solid #ffe3a5;
  outline-offset: 4px;
}
.world-objects button > .art,
.world-objects .farm-helper > .art {
  width: 100%;
  height: 100%;
  filter: none;
  flex-shrink: 0;
}
.world-objects button > .world-label {
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  font-size: 9px;
  padding: 2px 6px;
}
.world-objects .animal-object > .world-label {
  bottom: -14px;
}
.world-objects button > .object-ready {
  top: 0;
  right: 0;
}
.world-objects .animal-object > .object-ready {
  top: -18px;
  right: -8px;
}
.machine-working {
  position: absolute;
  right: 22%;
  top: 20%;
  width: 26px;
  height: 26px;
  animation: work-pulse 1.2s ease-in-out infinite;
}
.machine-working .art {
  width: 100%;
  height: 100%;
}
@keyframes work-pulse {
  50% {
    transform: translateY(-4px);
  }
}
.plot {
  position: absolute;
  width: 64px;
  height: 64px;
  display: block;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: none;
  box-shadow: none;
  outline: none;
  isolation: isolate;
  overflow: visible;
}
.plot:active {
  transform: none !important;
}
.plot-hit {
  position: absolute;
  inset: 0;
  pointer-events: auto;
  cursor: pointer;
}
.plot .soil {
  position: absolute;
  inset: 0;
  width: 64px;
  height: 64px;
  object-fit: contain;
  pointer-events: none;
  z-index: -1;
}
.plot .plot-ring {
  position: absolute;
  inset: 1px;
  z-index: 4;
  opacity: 0;
  border: 2px solid #ffe9a7;
  border-radius: 3px;
  box-shadow: 0 0 0 2px #5f461f60;
  pointer-events: none;
}
.plot:hover,
.plot.selected,
.plot.ready {
  outline: none;
  box-shadow: none;
  background: none;
}
.plot:hover .plot-ring,
.plot.selected .plot-ring,
.plot:focus-visible .plot-ring {
  opacity: 1;
}
.plot > .crop-art {
  position: absolute;
  left: 16px;
  bottom: 17px;
  width: 32px;
  height: 32px;
  margin: 0;
  pointer-events: none;
  z-index: 2;
}
.plot > .crop-back-left {
  left: 2px;
  bottom: 32px;
  z-index: 1;
}
.plot > .crop-back-right {
  left: 30px;
  bottom: 32px;
  z-index: 1;
}
.plot .empty-label,
.plot .untilled-label {
  position: absolute;
  inset: 22px 0 auto;
  text-align: center;
  pointer-events: none;
  color: #674c2b;
  opacity: 0.6;
}
.plot-label {
  bottom: 1px;
  font-size: 9px;
  pointer-events: none;
  z-index: 3;
}
.plot .crop-progress {
  width: 38px;
  left: 13px;
  bottom: 12px;
  pointer-events: none;
  z-index: 3;
}
.plot .ready-mark {
  top: -8px;
  right: 0;
  pointer-events: none;
  z-index: 3;
}
.plot .water-indicator {
  left: 3px;
  top: 3px;
  pointer-events: none;
  z-index: 3;
}
.plot-effect,
.harvest-popup {
  z-index: 1900;
}
.plot-effect {
  width: 32px;
  height: 32px;
}
.ambience {
  z-index: 2000;
}
.night-overlay {
  z-index: 2100;
}
.cloud-shadow {
  position: absolute;
  left: -300px;
  top: 100px;
  width: 350px;
  height: 160px;
  border-radius: 50%;
  background: #173b2822;
  filter: blur(30px);
  animation: cloud-crossing 100s linear infinite;
}
@keyframes cloud-crossing {
  to {
    transform: translate(1800px, 380px);
  }
}
.ambience.raining::after {
  content: "";
  position: absolute;
  inset: -100px;
  background: repeating-linear-gradient(
    110deg,
    transparent 0 63px,
    #d4ebf035 64px 65px,
    transparent 66px 120px
  );
  animation: rain-shift 0.6s linear infinite;
  opacity: 0.45;
}
@keyframes rain-shift {
  to {
    transform: translate(-24px, 64px);
  }
}
.area-sign {
  left: 490px;
  bottom: 26px;
  z-index: 1100;
  font-size: 13px;
  color: #e5f2c1;
  text-shadow: 1px 2px #345328;
}
.land-parcel {
  position: absolute;
  z-index: 2;
  border: 2px dashed #86744199;
  background: repeating-linear-gradient(
    135deg,
    #635b2517 0 8px,
    #efe7bb12 8px 16px
  );
  border-radius: 12px;
  display: grid;
  place-items: center;
  padding: 6px;
  color: #53452e;
}
.world-objects button > .world-label.building-sale {
  width: max-content;
  max-width: 180px;
  bottom: -36px;
  padding: 4px 7px;
  font-size: 12px;
  white-space: normal;
  background: #fff0cced;
  color: #594326;
  border: 1px solid #b39459;
}
.building-sale small {
  display: block;
  font-size: 10px;
  margin-top: 2px;
  color: #866335;
}
.building-for-sale:hover > .art {
  filter: drop-shadow(0 0 4px #fff2b9);
}
.land-parcel.next-land {
  border-color: #7c6936;
  background-color: #efd68c24;
}
.land-parcel > span {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 4px 8px;
  padding: 6px 10px;
  background: #fff0c7e8;
  border: 1px solid #ab8955;
  border-radius: 8px;
  box-shadow: 0 3px #795e3890;
}
.land-parcel .art {
  width: 20px;
  height: 20px;
}
.land-parcel strong {
  font-size: 12px;
}
.land-parcel small {
  flex-basis: 100%;
  font-size: 10px;
}
.land-row {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
}
.land-row .row-copy {
  min-width: 0;
}
.land-actions {
  display: flex;
  gap: 8px;
}
.land-actions .button {
  white-space: nowrap;
}
.land-actions .art {
  width: 18px;
  height: 18px;
}
@media (max-width: 600px) {
  .land-row {
    grid-template-columns: 32px minmax(0, 1fr);
    gap: 10px;
  }
  .land-row > .art {
    width: 32px;
    height: 32px;
  }
  .land-actions {
    grid-column: 1 / -1;
  }
  .land-actions .button {
    flex: 1;
  }
}
.expansion-sign {
  right: auto;
  left: 472px;
  top: 635px;
  bottom: auto;
  z-index: 1100;
}
.art-credit {
  pointer-events: auto;
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.seed-controls {
  flex-direction: column;
  width: 100%;
  gap: 6px;
}
.seed-controls .seed-buy {
  order: -1;
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-height: 58px;
  font-size: 12px;
  padding: 9px 5px;
}
.seed-buy small {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  font-size: 11px;
  color: inherit;
  font-weight: 600;
}
.seed-buy small .art {
  width: 18px;
  height: 18px;
}
.seed-controls .button {
  margin-top: 0;
}
.helper-portrait {
  width: 192px;
  height: 162px;
  max-width: 100%;
  align-self: center;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 4px 0 10px;
}
.helper-portrait > .art {
  width: 192px;
  height: 192px;
  max-width: none;
  flex-shrink: 0;
}
.purchase-receipt {
  position: fixed;
  inset: 0;
  margin: auto;
  width: min(330px, calc(100vw - 36px));
  height: fit-content;
  max-height: calc(100dvh - 40px);
  padding: 22px;
  text-align: center;
  border: 3px solid #b88c44;
  border-radius: 18px;
  background: linear-gradient(#fff9e3, #f7e7bd);
  color: #4a3c25;
  box-shadow:
    inset 0 0 0 3px #fff5d4,
    0 6px 0 #785a33,
    0 18px 75px #273b3466;
  pointer-events: auto;
}
.purchase-receipt::backdrop {
  background: none;
  pointer-events: none;
}
.purchase-success {
  display: block;
  font-size: 12px;
  font-weight: 800;
  color: #52773d;
  letter-spacing: 0.3px;
}
.purchase-art {
  position: relative;
  width: 100px;
  height: 100px;
  margin: 14px auto 10px;
}
.purchase-art > .art {
  width: 96px;
  height: 96px;
}
.purchase-art strong {
  position: absolute;
  right: -12px;
  bottom: 0;
  border: 2px solid #405e29;
  border-radius: 20px;
  padding: 4px 10px;
  background: #64883c;
  color: #fff9d7;
  font-size: 23px;
  box-shadow: 0 3px 0 #344826;
}
.purchase-receipt h3 {
  font-size: 21px;
  line-height: 1.25;
  margin: 10px 0;
}
.purchase-receipt p {
  font-size: 13px;
  margin: 9px 0;
  color: #766341;
}
.purchase-receipt small {
  font-size: 11px;
  color: #647a42;
}
@media (max-width: 760px) {
  .helper-portrait {
    height: 132px;
    margin-top: 20px;
  }
  .helper-portrait > .art {
    width: 160px;
    height: 160px;
  }
  .seed-controls .seed-buy {
    font-size: 10px;
    min-height: 57px;
  }
  .seed-buy small {
    font-size: 10px;
  }
}
.stat > .art {
  display: block;
  width: 48px;
  height: 48px;
  margin: 0 auto 8px;
}
#modal:has(.offline-stats) {
  width: min(600px, calc(100vw - 24px));
}
#modal:has(.offline-stats) .modal-head {
  padding: 16px 20px;
}
#modal:has(.offline-stats) .modal-head h2 {
  font-size: 24px;
}
#modal:has(.offline-stats) #modal-body {
  padding: 18px 20px 20px;
}
.offline-stats {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 16px 0;
}
.offline-stats .stat {
  padding: 14px 8px;
}
.offline-stats .stat strong {
  font-size: 25px;
  overflow-wrap: anywhere;
}
.offline-stats .stat small {
  display: block;
  font-size: 11px;
  line-height: 1.4;
}
@media (max-width: 480px) {
  #modal:has(.offline-stats) .modal-head {
    padding: 14px;
    gap: 10px;
  }
  #modal:has(.offline-stats) .modal-head h2 {
    font-size: 21px;
  }
  #modal:has(.offline-stats) #modal-body {
    padding: 14px;
  }
  .offline-stats {
    gap: 6px;
  }
  .offline-stats .stat {
    padding: 12px 5px;
  }
  .offline-stats .stat strong {
    font-size: 22px;
  }
}
.brand {
  font-size: 25px;
  min-width: 239px;
  white-space: nowrap;
}
.brand small {
  letter-spacing: 2px;
  font-size: 7px;
}
@media (max-width: 1100px) and (min-width: 761px) {
  .brand {
    font-size: 22px;
    min-width: 185px;
    gap: 4px;
  }
  .brand-mark .art {
    width: 32px;
    height: 32px;
  }
  .topbar {
    gap: 7px;
  }
  .resource {
    min-width: 70px;
    padding: 7px;
  }
  .resource.level {
    min-width: 118px;
  }
  .resource.level .mini-progress {
    width: 65px;
  }
}
@media (max-width: 760px) {
  .brand {
    font-size: 25px;
    min-width: 0;
  }
  .farm-scroll {
    background-image: none;
  }
  .farm-world {
    margin-top: 100px;
  }
  .rail .nav-item[data-id] {
    display: flex;
    flex: 1;
    min-width: 0;
    font-size: 7px;
    padding: 4px 1px;
  }
  .art-credit {
    font-size: 7px;
  }
  .below-farm {
    gap: 5px;
  }
  .pan-hint {
    max-width: 96px;
  }
}
