/* Farm shop: cream folder-tab window (reference: classic farm-game shop). */
.shop-modal {
  z-index: 30;
  padding: 88px 18px 18px; /* top room for the icon tabs that sit above the window */
  background: rgba(24, 34, 25, 0.5);
  backdrop-filter: blur(4px);
}

.shop-dialog {
  position: relative;
  width: min(860px, 100%);
  max-height: calc(100vh - 112px);
  display: flex;
  flex-direction: column;
  overflow: visible; /* tabs and the close button overhang the window */
  padding: 54px 30px 28px;
  border: 0;
  border-radius: 26px;
  color: #4b3b25;
  background: linear-gradient(180deg, #fbf0d3, #f5e5ba);
  box-shadow: 0 22px 60px rgba(20, 18, 10, 0.5);
}

/* thin orange keyline inside the window */
.shop-dialog::before {
  content: "";
  position: absolute;
  inset: 34px 13px 15px; /* top edge runs through the SHOP title, like the reference */
  border: 2px solid #f1a63f;
  border-radius: 19px;
  pointer-events: none;
}

/* ---- header: title, wallets, close ---- */
.shop-window-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  justify-items: center;
  row-gap: 4px;
  padding: 0 0 6px;
  color: #4b3b25;
  background: none;
  box-shadow: none;
}

/* whatever title markup the page ships stays for screen readers but is not drawn */
.shop-window-head > :not(.shop-wallets):not(.shop-close) {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.shop-title {
  position: absolute;
  left: 36px;
  top: 12px;
  z-index: 2;
  color: #6b6153;
  font: 900 2.4rem/1 "Arial Rounded MT Bold", "Trebuchet MS", sans-serif;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  -webkit-text-stroke: 8px #fff;
  paint-order: stroke fill;
  text-shadow: 0 3px 3px rgba(84, 62, 28, 0.3);
  transform: rotate(-2deg);
  transform-origin: left center;
  pointer-events: none;
  user-select: none;
}

.shop-wallets {
  display: flex;
  align-items: center;
  justify-self: center;
  gap: 28px;
}

.shop-wallet > .shop-currency-img { width: 34px; height: 34px; }
.shop-wallet > .shop-currency-fallback.compact-coin-icon { width: 28px; height: 28px; flex-basis: 28px; }

.shop-add-credits {
  min-height: 38px;
  padding: 0 20px;
  border: 2px solid #8fcdf0;
  border-radius: 9px;
  color: #fff;
  background: linear-gradient(180deg, #58bdf0, #2b86c9);
  box-shadow: 0 2px 4px rgba(40, 70, 100, 0.35), inset 0 -3px 0 rgba(20, 80, 130, 0.25);
  cursor: pointer;
  font: 900 1.05rem/1 "Arial Rounded MT Bold", "Trebuchet MS", sans-serif;
  text-shadow: 0 1px 2px rgba(0, 50, 90, 0.65);
  white-space: nowrap;
}

.shop-add-credits { display: inline-flex; align-items: center; justify-content: center; gap: 8px; }

.shop-add-credits svg {
  width: 21px;
  height: 21px;
  fill: #2988d6;
  stroke: #135896;
  stroke-width: 1.4;
  filter: drop-shadow(0 1px 0 rgba(255, 255, 255, 0.38));
}

.shop-add-credits:hover { filter: brightness(1.08); }
.shop-add-credits:active { transform: translateY(1px); }

.shop-wallet {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  color: #4b3b25;
  background: none;
  box-shadow: none;
}

.shop-wallet.gem-wallet { background: none; }
.shop-wallet > span { grid-row: auto; font-size: 1.4rem; line-height: 1; }
.shop-wallet strong,
.shop-wallet small {
  font-size: 1.05rem;
  font-weight: 900;
  text-transform: none;
}

.shop-close {
  position: absolute;
  top: -20px;
  right: -20px;
  z-index: 4;
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 3px solid #fff;
  border-radius: 50%;
  color: #fff;
  background: radial-gradient(circle at 35% 28%, #86d3f8, #2f8fd3 72%);
  box-shadow: 0 3px 9px rgba(10, 30, 50, 0.45), inset 0 -3px 0 rgba(20, 80, 130, 0.3);
  cursor: pointer;
  font-size: 0; /* the text glyph is replaced by the two bars below, so it is centred exactly */
  line-height: 0;
  transition: transform 120ms ease, filter 120ms ease;
}

.shop-close > * { display: none; }

.shop-close::before,
.shop-close::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 20px;
  height: 4px;
  margin: -2px 0 0 -10px;
  border-radius: 2px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(0, 50, 90, 0.55);
}

.shop-close::before { transform: rotate(45deg); }
.shop-close::after { transform: rotate(-45deg); }

.shop-close:hover,
.shop-close:focus-visible { filter: brightness(1.08); outline: none; transform: scale(1.06); }

/* ---- folder tabs (icon only) ---- */
.shop-category-tabs {
  position: absolute;
  left: 38px;
  bottom: 100%;
  z-index: 3;
  display: flex;
  align-items: flex-end;
  gap: 4px;
  padding: 0;
  background: none;
}

.shop-category {
  position: relative;
  width: 92px;
  height: 58px;
  display: grid;
  place-items: center;
  padding: 4px 6px 2px;
  border: 0;
  border-radius: 20px 20px 0 0;
  color: #4a3824;
  background: linear-gradient(180deg, #e1d0a6, #f4e6c1); /* darker tone at the top -> panel colour at the bottom */
  box-shadow: none;
  cursor: pointer;
  transition: height 120ms ease, filter 120ms ease;
}

.shop-category:hover,
.shop-category:focus-visible { filter: brightness(1.04); outline: none; }

.shop-category.active,
.shop-category.seasonal-category.active {
  z-index: 2;
  height: 68px;
  margin-bottom: -1px;
  color: #4a3824;
  background: linear-gradient(180deg, #f6e8c6, #fbf0d3);
  box-shadow: none;
  transform: none;
}

.shop-category.seasonal-category { background: linear-gradient(180deg, #e1d0a6, #f4e6c1); }

.shop-category-icon { width: 46px; height: 46px; display: grid; place-items: center; }

.shop-category-icon img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* label stays for screen readers; sighted users get the icon + tooltip */
.shop-category small {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* ---- body ---- */
.shop-window-body {
  display: flex;
  flex-direction: column;
  min-height: 0;
  padding: 0;
  background: none;
}

.shop-category-note {
  margin: 2px 0 0;
  color: #6d5f46;
  font-size: 0.86rem;
  font-weight: 700;
  line-height: 1.3;
  text-align: center;
}

.shop-product-type { color: #b27a2e; font-size: 0.61rem; font-weight: 950; letter-spacing: 0.09em; }

.shop-grid {
  /* Fixed height so the window never resizes between tabs or after a purchase. */
  height: min(54vh, 460px);
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-auto-rows: max-content;
  align-content: start;
  gap: 10px 12px;
  overflow-y: auto;
  overflow-x: hidden;
  scrollbar-gutter: stable;
  overscroll-behavior: contain;
  padding: 20px 8px 8px 4px;
}

.shop-grid.seasonal-preview-grid { display: block; }

/* blue scrollbar */
.shop-grid::-webkit-scrollbar { width: 16px; }
.shop-grid::-webkit-scrollbar-track { margin: 6px 0; border-radius: 10px; background: #f1dba5; box-shadow: inset 0 0 0 2px #e5c985; }
.shop-grid::-webkit-scrollbar-thumb { border: 2px solid #fff4d6; border-radius: 10px; background: linear-gradient(90deg, #58b7ec, #2b88cb); }
.shop-grid::-webkit-scrollbar-thumb:hover { background: linear-gradient(90deg, #6cc4f4, #3796db); }
@supports not selector(::-webkit-scrollbar) {
  .shop-grid { scrollbar-color: #2f8fd0 #f1dba5; scrollbar-width: auto; }
}

/* ---- crop / flower tiles: white art box + price on a peach plate ---- */
.shop-crop-tile {
  position: relative;
  width: auto;
  min-height: 72px;
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr);
  align-items: start;
  gap: 8px;
  padding: 4px 10px 4px 4px;
  border: 0;
  border-radius: 11px;
  color: #4a3a22;
  background: linear-gradient(180deg, #feeabf, #fddfa1);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7), 0 1px 0 rgba(176, 118, 36, 0.28);
  cursor: pointer;
  font: inherit;
  text-align: left;
  transition: box-shadow 120ms ease, filter 120ms ease;
}

.shop-crop-tile:hover,
.shop-crop-tile:focus-visible,
.shop-crop-tile.selected {
  z-index: 2;
  outline: none;
  box-shadow: 0 0 0 3px #fff, 0 0 0 5px #7cc6f0, 0 4px 10px rgba(40, 70, 100, 0.25);
}

.shop-crop-art {
  width: 64px;
  height: 64px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 0;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 1px 3px rgba(110, 78, 28, 0.3);
}

.shop-crop-art img { width: 56px; height: 56px; object-fit: contain; filter: drop-shadow(0 2px 1px rgba(65, 44, 22, 0.18)); }
.shop-crop-art > span { font-size: 2.4rem; filter: drop-shadow(0 2px 1px rgba(65, 44, 22, 0.18)); }

.shop-crop-info { display: grid; gap: 2px; padding-top: 8px; min-width: 0; }

.shop-crop-price {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  white-space: nowrap;
  font-size: 1.02rem;
  font-weight: 900;
}

.shop-crop-price strong { margin-left: auto; font-variant-numeric: tabular-nums; }
.shop-crop-lock { color: #8b867b; font-size: 0.66rem; font-weight: 850; text-align: right; }

/* coin / credit icons are the ones the game already ships (HUD art, or the compact-* CSS icons as fallback) */
.shop-currency-img {
  flex: none;
  width: 26px;
  height: 26px;
  object-fit: contain;
  filter: drop-shadow(0 1px 1px rgba(80, 50, 10, 0.35));
}

.shop-currency-fallback { margin: 0; }
.shop-currency-fallback.compact-coin-icon { width: 22px; height: 22px; flex: 0 0 22px; border-width: 2px; }
.shop-currency-fallback.compact-credit-icon { margin: 0 3px; }

/* locked (level too low): greyed out like the reference */
.shop-crop-tile.locked { color: #8b867b; background: linear-gradient(180deg, #ebe9e4, #dbd8d1); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7); }
.shop-crop-tile.locked .shop-crop-art img,
.shop-crop-tile.locked .shop-crop-art > span { filter: grayscale(1) opacity(0.6); }
.shop-crop-tile.locked .shop-currency-img,
.shop-crop-tile.locked .shop-currency-fallback { filter: grayscale(1) opacity(0.7); }

/* name bubble on hover / keyboard focus */
.shop-crop-tile::after {
  content: attr(data-name);
  position: absolute;
  left: 38%;
  top: -17px;
  z-index: 5;
  padding: 4px 12px 5px;
  border-radius: 10px;
  color: #1d6f9f;
  background: linear-gradient(180deg, #f6fcff, #cfe9f7);
  box-shadow: 0 2px 6px rgba(30, 60, 80, 0.35);
  font-size: 0.92rem;
  font-weight: 900;
  white-space: nowrap;
  opacity: 0;
  transform: translateY(4px);
  pointer-events: none;
  transition: opacity 120ms ease, transform 120ms ease;
}

.shop-crop-tile:nth-child(4n)::after { left: auto; right: 14%; }
.shop-crop-tile:hover::after,
.shop-crop-tile:focus-visible::after { opacity: 1; transform: none; }

/* ---- product cards (animals, upgrades, decorations) ---- */
.shop-product-card {
  grid-column: span 2;
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr);
  grid-template-rows: auto auto;
  gap: 4px 10px;
  min-height: 78px;
  padding: 4px 10px 8px 4px;
  border: 0;
  border-radius: 11px;
  background: linear-gradient(180deg, #feeabf, #fddfa1);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7), 0 1px 0 rgba(176, 118, 36, 0.28);
}

.shop-product-card.selected { box-shadow: 0 0 0 3px #fff, 0 0 0 5px #7cc6f0; }
.shop-product-card.locked,
.shop-product-card.owned { opacity: 0.72; }

.shop-product-art {
  grid-row: 1 / span 2;
  display: grid;
  width: 64px;
  height: 64px;
  place-items: center;
  border: 0;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 1px 3px rgba(110, 78, 28, 0.3);
}

.shop-product-art span { font-size: 2.4rem; filter: drop-shadow(0 2px 1px rgba(65, 44, 22, 0.18)); }
.shop-product-art img { width: 56px; height: 56px; object-fit: contain; filter: drop-shadow(0 2px 1px rgba(65, 44, 22, 0.18)); }
.shop-product-copy { min-width: 0; padding-top: 2px; }
.shop-product-copy h4 { margin: 2px 0 3px; color: #3f3221; font-size: 0.92rem; line-height: 1.1; }
.shop-product-copy p { color: #7a6845; font-size: 0.7rem; font-weight: 700; line-height: 1.28; }

.shop-product-buy {
  grid-column: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.shop-price { display: inline-flex; align-items: center; gap: 6px; color: #4a3a22; font-size: 1rem; font-weight: 900; }

.shop-buy-button {
  min-width: 88px;
  min-height: 34px;
  padding: 0 14px;
  border: 2px solid #fff;
  border-radius: 9px;
  color: #fff;
  background: linear-gradient(180deg, #55b9ee, #2a86c7);
  box-shadow: 0 2px 4px rgba(40, 70, 100, 0.35), inset 0 -3px 0 rgba(20, 80, 130, 0.25);
  cursor: pointer;
  font-size: 0.78rem;
  font-weight: 950;
  text-shadow: 0 1px 2px rgba(0, 50, 90, 0.5);
}

.shop-buy-button:hover:not(:disabled) { filter: brightness(1.08); }

.shop-buy-button:disabled {
  border-color: #f2eee4;
  color: #7d7666;
  background: #d9d4c6;
  box-shadow: none;
  text-shadow: none;
  cursor: default;
}

/* ---- seasonal preview ---- */
.shop-season-preview {
  min-height: 290px;
  display: grid;
  grid-template-columns: minmax(150px, 230px) minmax(0, 1fr) auto;
  align-items: center;
  gap: 22px;
  padding: 22px 28px;
  border: 3px solid #f1a63f;
  border-radius: 19px;
  background:
    radial-gradient(circle at 88% 12%, rgba(255, 255, 255, 0.78), transparent 20%),
    linear-gradient(135deg, #f4f0c8 0%, #dce7a4 44%, #f1c1b0 100%);
  box-shadow: inset 0 3px 0 rgba(255, 255, 255, 0.72), 0 8px 20px rgba(91, 57, 25, 0.14);
}

.shop-season-preview > img { width: 100%; max-height: 230px; object-fit: contain; filter: drop-shadow(0 9px 8px rgba(48, 70, 31, 0.24)); }
.shop-season-preview h4 { margin: 5px 0 8px; color: #7b2429; font-size: clamp(1.25rem, 3vw, 2rem); line-height: 1.05; }
.shop-season-preview p { max-width: 470px; color: #69553b; font-size: 0.8rem; font-weight: 750; line-height: 1.45; }

.shop-season-preview > strong {
  align-self: start;
  padding: 8px 12px;
  border: 2px solid #9d2d32;
  border-radius: 999px;
  color: #fff;
  background: linear-gradient(180deg, #dd5657, #ac2a31);
  box-shadow: inset 0 -3px 0 rgba(102, 22, 27, 0.22);
  font-size: 0.68rem;
  text-transform: uppercase;
  white-space: nowrap;
}

@media (min-width: 761px) and (max-width: 880px) {
  .shop-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .shop-product-card { grid-column: span 3; }
  .shop-crop-tile:nth-child(4n)::after { left: 38%; right: auto; }
  .shop-crop-tile:nth-child(3n)::after { left: auto; right: 14%; }
}

.crop-details-modal {
  z-index: 40;
  padding: 16px;
  background: rgba(28, 34, 23, 0.58);
  backdrop-filter: blur(6px);
}

.crop-details-dialog {
  width: min(520px, 100%);
  max-height: calc(100vh - 32px);
  overflow: auto;
  border: 8px solid #f5f3df;
  border-radius: 22px;
  color: #564426;
  background: #f8d98c;
  box-shadow: 0 20px 65px rgba(33, 26, 15, 0.52), inset 0 0 0 3px #d9aa4f;
}

.crop-details-head {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 68px;
  padding: 12px 66px 8px;
  border-bottom: 2px solid rgba(184, 128, 46, 0.42);
}

.crop-details-head h2 {
  color: #4f3b20;
  font-size: clamp(1.55rem, 5vw, 2.15rem);
  line-height: 1;
  text-align: center;
  text-shadow: 0 2px 0 rgba(255, 247, 210, 0.9);
}

.crop-details-close {
  position: absolute;
  top: 9px;
  right: 10px;
  width: 42px;
  height: 42px;
  border: 3px solid #9f442d;
  border-radius: 50%;
  color: #fff;
  background: linear-gradient(180deg, #ef7754, #c44531);
  box-shadow: inset 0 -4px 0 rgba(120, 39, 27, 0.25);
  cursor: pointer;
  font-size: 1.7rem;
  font-weight: 950;
  line-height: 1;
}

.crop-details-body { padding: 14px 16px 10px; }

.crop-details-summary {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  margin-bottom: 13px;
}

.crop-details-art {
  width: 104px;
  height: 104px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 3px solid #c58e37;
  border-radius: 18px;
  background: linear-gradient(180deg, #fff6d1, #eed18b);
  box-shadow: inset 0 3px 0 rgba(255, 255, 255, 0.75);
}

.crop-details-art img {
  width: 92px;
  height: 92px;
  object-fit: contain;
  filter: drop-shadow(0 5px 3px rgba(72, 46, 20, 0.22));
}

.crop-details-art span { font-size: 4.3rem; }

.crop-details-cost {
  min-width: 158px;
  display: grid;
  justify-items: center;
  gap: 3px;
  padding: 10px 13px;
  border-radius: 13px;
  color: #6c542d;
  background: rgba(187, 137, 57, 0.25);
}

.crop-details-cost > span,
.crop-details-cost small { font-size: 0.7rem; font-weight: 850; }
.crop-details-cost > span { text-transform: uppercase; }
.crop-details-cost strong { font-size: 1.25rem; }

.crop-details-facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
  padding: 10px;
  border: 2px solid rgba(185, 127, 42, 0.45);
  border-radius: 15px;
  background: rgba(255, 244, 196, 0.67);
}

.crop-details-facts p {
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 9px;
  margin: 0;
  padding: 7px 9px;
  border-radius: 9px;
  color: #715c38;
  background: rgba(218, 178, 103, 0.3);
  font-size: 0.74rem;
  font-weight: 800;
}

.crop-details-facts strong { color: #49391f; text-align: right; }
.crop-details-facts .crop-details-total { grid-column: 1 / -1; }

.crop-details-purchase {
  display: grid;
  grid-template-columns: auto 78px minmax(0, 1fr);
  align-items: center;
  gap: 9px;
  width: min(360px, 100%);
  margin: 12px auto 0;
  padding: 9px 11px;
  border: 2px solid rgba(185, 127, 42, 0.45);
  border-radius: 12px;
  color: #67502d;
  background: rgba(255, 246, 209, 0.72);
  font-size: 0.76rem;
  font-weight: 900;
}

.crop-details-purchase input {
  width: 78px;
  min-height: 36px;
  border: 2px solid #c18e42;
  border-radius: 8px;
  color: #4f391d;
  background: #fff9de;
  font: inherit;
  font-size: 0.95rem;
  font-weight: 900;
  text-align: center;
}

.crop-details-purchase > span { justify-self: end; }

.crop-details-note {
  margin: 10px 0 0;
  color: #765d35;
  font-size: 0.68rem;
  font-weight: 750;
  text-align: center;
}

.crop-details-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 8px 16px 16px;
}

.crop-details-cancel,
.crop-details-select {
  min-height: 42px;
  padding: 8px 18px;
  border: 3px solid;
  border-radius: 10px;
  color: #fff;
  cursor: pointer;
  font-weight: 950;
}

.crop-details-cancel {
  border-color: #9c3828;
  background: linear-gradient(180deg, #ef684c, #c63e2e);
}

.crop-details-select {
  border-color: #38712f;
  background: linear-gradient(180deg, #76c858, #43943a);
}

.crop-details-select:disabled {
  border-color: #9c8d71;
  color: #665a46;
  background: #d8cba9;
  cursor: default;
}

@media (max-width: 760px) {
  .friends-dock {
    min-height: 64px;
    grid-template-columns: 26px minmax(0, 1fr) 26px auto;
    padding: 5px;
  }

  .friends-dock-title { display: none; }
  .friends-arrow { width: 24px; height: 42px; }
  .friends-dock-actions { position: static; }
  .invite-friend-button,
  .more-friends-button { min-width: 62px; min-height: 38px; padding: 0 6px; }

  .tooldock {
    bottom: 70px;
    max-width: calc(100vw - 12px);
    padding: 5px;
  }

  .tooldock .tool {
    width: 42px;
    min-width: 42px;
    height: 42px;
    min-height: 42px;
    padding: 3px;
  }

  .tooldock .tool-icon { width: 30px; height: 30px; }
  .stage-cash-counter { display: none !important; }

  .shop-modal { padding: 86px 8px 8px; }
  .shop-dialog { max-height: calc(100vh - 94px); max-height: calc(100dvh - 94px); padding: 54px 14px 18px; border-radius: 20px; }
  .shop-dialog::before { inset: 30px 7px 8px; border-radius: 15px; }
  .shop-title { left: 20px; top: 10px; font-size: 1.8rem; -webkit-text-stroke: 6px #fff; }
  .shop-wallets { flex-wrap: wrap; justify-content: center; gap: 6px 14px; }
  .shop-add-credits { min-height: 40px; padding: 0 16px; font-size: 0.95rem; }
  .shop-wallet > .shop-currency-img { width: 26px; height: 26px; }
  .shop-wallet > .shop-currency-fallback.compact-coin-icon { width: 22px; height: 22px; flex-basis: 22px; }
  .shop-wallet > span { font-size: 1.2rem; }
  .shop-wallet strong, .shop-wallet small { font-size: 0.9rem; }
  /* close button sits inside the top-right corner (mirrors the SHOP title) so the tab row can use the full width */
  .shop-close { top: 4px; right: 8px; width: 44px; height: 44px; }
  .shop-close::before, .shop-close::after { width: 17px; margin-left: -8.5px; }
  /* tabs share the whole row width, so they stay big enough to tap (>= 44px wide, 58px tall) */
  .shop-category-tabs { left: 20px; right: 20px; width: auto; max-width: none; margin: 0; justify-content: center; gap: 4px; }
  .shop-category { flex: 1 1 0; width: auto; max-width: 84px; min-width: 0; height: 58px; padding: 4px 3px 2px; border-radius: 16px 16px 0 0; }
  .shop-category.active, .shop-category.seasonal-category.active { height: 68px; }
  .shop-category-icon { width: 100%; max-width: 42px; height: auto; aspect-ratio: 1; }
  .shop-category-note { font-size: 0.78rem; margin-bottom: 6px; }
  .shop-grid { height: 46vh; height: 46dvh; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; padding: 18px 4px 6px 2px; }
  .shop-grid::-webkit-scrollbar { width: 12px; }
  .shop-crop-tile { grid-template-columns: 54px minmax(0, 1fr); gap: 6px; padding: 3px 7px 3px 3px; min-height: 62px; }
  .shop-crop-art { width: 54px; height: 54px; }
  .shop-crop-art img { width: 46px; height: 46px; }
  .shop-crop-art > span { font-size: 2rem; }
  .shop-crop-price { font-size: 0.9rem; }
  .shop-crop-tile:nth-child(4n)::after { left: 38%; right: auto; }
  .shop-crop-tile:nth-child(2n)::after { left: auto; right: 8%; }
  .shop-product-card { grid-column: 1 / -1; }
  .shop-season-preview { min-height: 0; grid-template-columns: 90px minmax(0, 1fr); gap: 12px; padding: 13px; }
  .shop-season-preview > img { max-height: 110px; }
  .shop-season-preview > strong { grid-column: 1 / -1; justify-self: center; }
  .shop-season-preview h4 { font-size: 1.05rem; }
  .shop-season-preview p { font-size: 0.68rem; }
  .crop-details-dialog { border-width: 5px; border-radius: 17px; }
  .crop-details-summary { gap: 12px; }
  .crop-details-art { width: 88px; height: 88px; }
  .crop-details-art img { width: 78px; height: 78px; }
  .crop-details-facts { grid-template-columns: 1fr; }
  .crop-details-facts .crop-details-total { grid-column: auto; }
  .crop-details-purchase { grid-template-columns: auto 70px; }
  .crop-details-purchase > span { grid-column: 1 / -1; justify-self: center; }
  .seed-bag-tray { min-width: min(290px, calc(100vw - 16px)); padding-left: 8px; }
}
/* End painted farm HUD and shop. */
