/* Minecrafter Store — Marketplace-inspired family download catalog
   (original skin; not Mojang branding) */

:root {
  --bg: #0f1114;
  --bg-elevated: #1a1d22;
  --bg-card: #23272e;
  --bg-card-hover: #2a2f38;
  --border: rgba(255, 255, 255, 0.08);
  --border-strong: rgba(255, 255, 255, 0.14);
  --text: #f2f4f7;
  --text-mute: #9aa3b2;
  --text-dim: #6b7380;
  --green: #3c8527;
  --green-bright: #70b237;
  --green-deep: #2a5c1a;
  --green-glow: rgba(112, 178, 55, 0.35);
  --gold: #e0b03a;
  --watch-deep: #0d2820;
  --watch-mid: #1a6b52;
  --door-deep: #1a1c3a;
  --door-mid: #4a56b8;
  --hamlet-deep: #2a1c0a;
  --hamlet-mid: #c47a1a;
  --font: "Noto Sans", system-ui, sans-serif;
  --font-display: "Rubik", "Noto Sans", system-ui, sans-serif;
  --radius: 6px;
  --radius-lg: 10px;
  --nav-h: 56px;
  --max: 1120px;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.45;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
}

code {
  font-family: ui-monospace, "SF Mono", Menlo, monospace;
  font-size: 0.88em;
  background: rgba(255, 255, 255, 0.08);
  padding: 0.1em 0.35em;
  border-radius: 3px;
}

.store {
  min-height: 100vh;
  background:
    radial-gradient(ellipse 80% 40% at 50% -10%, rgba(60, 133, 39, 0.12), transparent 55%),
    var(--bg);
}

/* —— Top store bar —— */
.store-nav {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--nav-h);
  background: rgba(15, 17, 20, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.store-nav-inner {
  max-width: var(--max);
  height: 100%;
  margin: 0 auto;
  padding: 0 1rem;
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.store-logo {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  flex-shrink: 0;
}

.logo-block {
  width: 28px;
  height: 28px;
  background:
    linear-gradient(135deg, var(--green-bright) 0 50%, var(--green) 50%);
  border: 2px solid #1a3d12;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.15);
  image-rendering: pixelated;
}

.logo-text {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.05rem;
  letter-spacing: -0.02em;
}

.logo-badge {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #0f1114;
  background: var(--green-bright);
  padding: 0.2rem 0.4rem;
  border-radius: 3px;
}

.store-tabs {
  display: flex;
  gap: 0.25rem;
  flex: 1;
  overflow-x: auto;
  scrollbar-width: none;
}

.store-tabs::-webkit-scrollbar { display: none; }

.tab {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-mute);
  padding: 0.45rem 0.75rem;
  border-radius: 4px;
  white-space: nowrap;
  transition: color 0.15s, background 0.15s;
}

.tab:hover,
.tab:focus-visible {
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
  outline: none;
}

.tab.is-active {
  color: var(--text);
  background: rgba(255, 255, 255, 0.08);
}

.store-meta {
  flex-shrink: 0;
}

.coin-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  color: var(--gold);
  background: rgba(224, 176, 58, 0.12);
  border: 1px solid rgba(224, 176, 58, 0.35);
  padding: 0.35rem 0.65rem;
  border-radius: 999px;
}

.coin {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #f5d978, var(--gold) 55%, #a87818);
  border: 1px solid #8a6414;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

/* —— Featured banner —— */
.featured {
  max-width: var(--max);
  margin: 0 auto;
  padding: 1.25rem 1rem 0.5rem;
}

.featured-banner {
  position: relative;
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 1rem;
  min-height: min(42vh, 340px);
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border-strong);
  isolation: isolate;
}

.featured-banner.art-watch {
  background:
    linear-gradient(115deg, rgba(8, 20, 16, 0.92) 0%, rgba(8, 20, 16, 0.55) 48%, transparent 70%),
    linear-gradient(160deg, #0a2e24 0%, #145a45 40%, #0d1f1a 100%);
}

.featured-vignette {
  position: absolute;
  inset: 0;
  background:
    repeating-linear-gradient(
      0deg,
      transparent,
      transparent 3px,
      rgba(0, 0, 0, 0.06) 3px,
      rgba(0, 0, 0, 0.06) 4px
    );
  opacity: 0.5;
  pointer-events: none;
  z-index: 0;
}

.featured-copy {
  position: relative;
  z-index: 1;
  padding: clamp(1.25rem, 4vw, 2.25rem);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 0.5rem;
  max-width: 32rem;
}

.featured-kicker {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--green-bright);
}

.featured-copy h1 {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(2rem, 5vw, 2.75rem);
  letter-spacing: -0.03em;
  line-height: 1.05;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.45);
}

.featured-desc {
  color: rgba(255, 255, 255, 0.85);
  font-size: 1rem;
  max-width: 28rem;
  margin-bottom: 0.35rem;
}

.featured-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
  margin-top: 0.35rem;
}

.price-tag {
  font-weight: 800;
  font-size: 0.95rem;
  color: var(--text);
}

.rating {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8rem;
  color: var(--text-mute);
}

.stars {
  color: var(--gold);
  letter-spacing: 0.05em;
}

/* —— Marketplace green Get button —— */
.btn-get {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 6.5rem;
  min-height: 2.65rem;
  padding: 0.55rem 1.4rem;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #fff;
  background: linear-gradient(180deg, var(--green-bright) 0%, var(--green) 100%);
  border: 2px solid var(--green-deep);
  border-radius: 4px;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.25),
    0 3px 0 var(--green-deep);
  transition: transform 0.12s ease, box-shadow 0.12s ease, filter 0.12s ease;
  cursor: pointer;
}

.btn-get:hover,
.btn-get:focus-visible {
  filter: brightness(1.08);
  transform: translateY(-1px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.25),
    0 4px 0 var(--green-deep),
    0 0 20px var(--green-glow);
  outline: none;
}

.btn-get:active {
  transform: translateY(2px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.15),
    0 1px 0 var(--green-deep);
}

.btn-get--sm {
  min-width: 4.5rem;
  min-height: 2.15rem;
  padding: 0.4rem 0.9rem;
  font-size: 0.85rem;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.25),
    0 2px 0 var(--green-deep);
}

/* Featured side art */
.featured-art {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}

.art-monitor {
  width: min(220px, 70%);
  aspect-ratio: 5 / 4;
  background: #2a3038;
  border: 4px solid #15181c;
  border-radius: 6px;
  padding: 10%;
  box-shadow:
    0 18px 40px rgba(0, 0, 0, 0.45),
    inset 0 0 0 2px rgba(255, 255, 255, 0.06);
  transform: rotate(4deg);
  animation: float-mon 4s ease-in-out infinite;
}

.art-monitor-screen {
  width: 100%;
  height: 100%;
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.15), transparent 40%),
    radial-gradient(circle at 40% 40%, #5ee0a8, #0d3d2c 70%);
  border: 3px solid #0a0c0e;
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 0.75rem;
  letter-spacing: 0.18em;
  color: #9ff0c8;
  text-shadow: 0 0 12px rgba(112, 178, 55, 0.5);
  position: relative;
  overflow: hidden;
}

.art-monitor-screen::after {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 3px,
    rgba(0, 0, 0, 0.18) 3px,
    rgba(0, 0, 0, 0.18) 4px
  );
  animation: scan 2.8s linear infinite;
  pointer-events: none;
}

@keyframes float-mon {
  0%, 100% { transform: rotate(4deg) translateY(0); }
  50% { transform: rotate(3deg) translateY(-8px); }
}

@keyframes scan {
  from { transform: translateY(-8%); }
  to { transform: translateY(8%); }
}

/* —— Product shelf —— */
.shelf {
  max-width: var(--max);
  margin: 0 auto;
  padding: 2rem 1rem 0.5rem;
}

.shelf-head {
  margin-bottom: 1.15rem;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.5rem 1rem;
}

.shelf-head h2 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.35rem;
  letter-spacing: -0.02em;
}

.shelf-sub {
  color: var(--text-mute);
  font-size: 0.9rem;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

.product {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: background 0.15s, border-color 0.15s, transform 0.15s;
}

.product:hover,
.product:focus-within {
  background: var(--bg-card-hover);
  border-color: var(--border-strong);
  transform: translateY(-2px);
}

/* Cover tile — square like Marketplace key art */
.product-cover {
  position: relative;
  display: block;
  aspect-ratio: 1;
  overflow: hidden;
  border-bottom: 1px solid var(--border);
}

.product-badge {
  position: absolute;
  top: 0.55rem;
  left: 0.55rem;
  z-index: 2;
  font-size: 0.7rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #0f1114;
  background: var(--green-bright);
  padding: 0.25rem 0.45rem;
  border-radius: 3px;
  box-shadow: 0 2px 0 rgba(0, 0, 0, 0.25);
}

.cover-scene {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
}

.art-watch {
  background:
    linear-gradient(160deg, #0d2820 0%, #1a6b52 45%, #0a1a16 100%);
}

.art-door {
  background:
    linear-gradient(160deg, #12142e 0%, #3a46a0 50%, #0e1024 100%);
}

.art-hamlet {
  background:
    linear-gradient(160deg, #2a1c0a 0%, #8a5520 40%, #3d6b2a 75%, #1a2810 100%);
}

/* Voxel-ish cover ornaments */
.voxel-cam {
  display: flex;
  flex-direction: column;
  align-items: center;
  transform: translate(-28px, 8px);
}

.cam-head {
  width: 52px;
  height: 36px;
  background: #5c6570;
  border: 3px solid #1a1c20;
  border-radius: 4px;
  position: relative;
}

.cam-head::after {
  content: "";
  position: absolute;
  right: 6px;
  top: 7px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2px solid #111;
  background: radial-gradient(circle at 35% 35%, #9fe8c8, #0d3d2c);
  box-shadow: 0 0 10px rgba(112, 178, 55, 0.5);
  animation: pulse-lens 2.2s ease-in-out infinite;
}

.cam-pole {
  width: 8px;
  height: 40px;
  background: #3a4048;
  border: 2px solid #1a1c20;
}

.voxel-monitor {
  position: absolute;
  right: 18%;
  bottom: 22%;
  width: 72px;
  height: 56px;
  background: #2a3038;
  border: 3px solid #111;
  border-radius: 4px;
  display: grid;
  place-items: center;
  box-shadow: 0 8px 0 rgba(0, 0, 0, 0.3);
}

.voxel-monitor span {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 0.65rem;
  letter-spacing: 0.12em;
  color: #70e0a8;
  background: #0d3d2c;
  width: 80%;
  height: 60%;
  display: grid;
  place-items: center;
  border: 2px solid #0a0c0e;
}

.voxel-doorframe {
  width: 70px;
  height: 110px;
  background: #3d3548;
  border: 4px solid #1a1628;
  border-radius: 4px 4px 0 0;
  display: grid;
  place-items: end center;
  padding: 6px;
  box-shadow: 0 12px 0 rgba(0, 0, 0, 0.25);
}

.voxel-door-panel {
  width: 100%;
  height: 100%;
  background: linear-gradient(180deg, #d4b896, #b8946a);
  border: 3px solid #2a2018;
  border-radius: 2px;
  position: relative;
}

.voxel-door-panel::after {
  content: "";
  position: absolute;
  right: 8px;
  top: 48%;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #f0c040;
  box-shadow: 0 0 8px rgba(240, 192, 64, 0.6);
}

.voxel-sparkles {
  position: absolute;
  inset: 15% 18%;
  background:
    radial-gradient(circle at 20% 30%, rgba(255, 255, 255, 0.9) 0 2px, transparent 3px),
    radial-gradient(circle at 80% 25%, rgba(180, 200, 255, 0.9) 0 2px, transparent 3px),
    radial-gradient(circle at 70% 70%, rgba(255, 255, 255, 0.7) 0 1.5px, transparent 2.5px);
  animation: twinkle 2.5s ease-in-out infinite;
}

.voxel-cottage {
  width: 96px;
  height: 72px;
  background: #8b5a2b;
  border: 3px solid #2a1808;
  border-radius: 2px;
  position: relative;
  box-shadow: 0 10px 0 rgba(0, 0, 0, 0.25);
}

.voxel-cottage::before {
  content: "";
  position: absolute;
  top: -28px;
  left: -8px;
  right: -8px;
  height: 36px;
  background: #6b3030;
  clip-path: polygon(50% 0, 100% 100%, 0 100%);
  border-bottom: 3px solid #2a1808;
}

.voxel-cottage::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 22px;
  height: 32px;
  background: #4a3020;
  border: 2px solid #1a1008;
  border-bottom: none;
}

.voxel-flag {
  position: absolute;
  top: 18%;
  right: 22%;
  width: 4px;
  height: 56px;
  background: #2a2a2a;
  border: 1px solid #111;
}

.voxel-flag::after {
  content: "";
  position: absolute;
  top: 4px;
  left: 4px;
  width: 28px;
  height: 18px;
  background: var(--green-bright);
  border: 2px solid #1a3d12;
  animation: wave 2.2s ease-in-out infinite;
  transform-origin: left center;
}

@keyframes pulse-lens {
  0%, 100% { box-shadow: 0 0 8px rgba(112, 178, 55, 0.4); }
  50% { box-shadow: 0 0 16px rgba(112, 178, 55, 0.8); }
}

@keyframes twinkle {
  0%, 100% { opacity: 0.7; }
  50% { opacity: 1; }
}

@keyframes wave {
  0%, 100% { transform: scaleX(1); }
  50% { transform: scaleX(0.92); }
}

.product-info {
  padding: 0.85rem 0.9rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  flex: 1;
}

.product-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: -0.01em;
}

.product-creator {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.product-blurb {
  font-size: 0.88rem;
  color: var(--text-mute);
  margin: 0.25rem 0 0.5rem;
  flex: 1;
}

.product-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-top: auto;
  padding-top: 0.35rem;
}

.product-ver {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-dim);
}

/* —— How to —— */
.howto {
  padding-bottom: 1rem;
}

.howto-steps {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.howto-steps li {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem 0.9rem;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.step-n {
  width: 1.75rem;
  height: 1.75rem;
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 0.85rem;
  background: var(--green);
  border: 2px solid var(--green-deep);
  border-radius: 4px;
  color: #fff;
}

.howto-steps strong {
  display: block;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.95rem;
  margin-bottom: 0.2rem;
}

.howto-steps p {
  font-size: 0.85rem;
  color: var(--text-mute);
}

.howto-proof {
  background: rgba(60, 133, 39, 0.12);
  border: 1px solid rgba(112, 178, 55, 0.35);
  border-radius: var(--radius);
  padding: 0.9rem 1rem;
  font-size: 0.92rem;
  font-weight: 500;
  color: #c5e8a8;
}

/* —— Footer —— */
.store-foot {
  max-width: var(--max);
  margin: 2.5rem auto 0;
  padding: 1.5rem 1rem 2.5rem;
  border-top: 1px solid var(--border);
  text-align: center;
  color: var(--text-dim);
  font-size: 0.82rem;
}

.store-foot strong {
  color: var(--text-mute);
  font-weight: 700;
}

.store-foot-links {
  margin-top: 0.5rem;
}

.store-foot-links a {
  color: var(--text-mute);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.store-foot-links a:hover {
  color: var(--green-bright);
}

/* —— Responsive —— */
@media (max-width: 900px) {
  .featured-banner {
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .featured-art {
    display: none;
  }

  .product-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .howto-steps {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 560px) {
  .store-meta {
    display: none;
  }

  .logo-badge {
    display: none;
  }

  .product-grid {
    grid-template-columns: 1fr;
    max-width: 360px;
    margin: 0 auto;
  }

  .howto-steps {
    grid-template-columns: 1fr;
  }

  .btn-get {
    min-width: 5.5rem;
  }

  .product-foot .btn-get {
    width: auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  .art-monitor,
  .art-monitor-screen::after,
  .cam-head::after,
  .voxel-sparkles,
  .voxel-flag::after {
    animation: none;
  }

  .btn-get,
  .product {
    transition: none;
  }

  .product:hover {
    transform: none;
  }
}
