/* moe.labs homepage - scoped to .ml-home */

/* Full-bleed on the front page of Twenty Twenty-Five: hide the page title, remove top spacing */
body.home { overflow-x: clip; }
body.home .wp-block-post-title { display: none; }
body.home main.wp-block-group { margin-top: 0 !important; padding-top: 0 !important; }
body.home .ml-home {
  max-width: none !important;
  width: 100vw;
  margin-left: calc(50% - 50vw) !important;
  margin-right: 0 !important;
}

.ml-home {
  --ml-ink: #0e0f12;
  --ml-paper: #f4f4f2;
  --ml-line: #e2e2de;
  --ml-mute: #8b8f97;
  --ml-mono: "JetBrains Mono", ui-monospace, Consolas, monospace;
  --ml-sans: "Barlow", "Helvetica Neue", Arial, sans-serif;
  font-family: var(--ml-sans);
  color: var(--ml-ink);
}
.ml-home * { box-sizing: border-box; }
.ml-home a { text-decoration: none; color: inherit; }

/* ---------- hero slideshow ---------- */
.ml-hero {
  position: relative;
  min-height: 600px;
  background: var(--ml-ink);
  color: #fff;
  overflow: hidden;
}
.ml-slide {
  position: absolute; inset: 0;
  opacity: 0; pointer-events: none;
  transition: opacity .9s ease;
}
.ml-slide.is-active { opacity: 1; pointer-events: auto; }
.ml-slide-bg {
  position: absolute; inset: -60px;
  background-size: cover; background-position: center;
  filter: blur(46px) brightness(.32) saturate(.4);
  transform: scale(1.15);
}
.ml-slide-bg::after {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(120% 90% at 70% 40%, transparent 0%, rgba(14,15,18,.75) 70%);
}
.ml-slide-inner {
  position: relative; z-index: 1;
  height: 100%; max-width: 1240px; margin: 0 auto;
  padding: 56px 32px 96px;
  display: grid; grid-template-columns: minmax(280px, 460px) 1fr; gap: 72px; align-items: center;
}
.ml-card {
  display: block; border-radius: 22px; padding: 12px;
  background: rgba(255,255,255,.12); backdrop-filter: blur(6px);
  border: 1px solid rgba(255,255,255,.18);
  transform: translateY(18px); transition: transform 1s cubic-bezier(.2,.7,.2,1);
}
.ml-card img { display: block; width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 14px; }
.ml-copy > * { transform: translateX(24px); opacity: 0; transition: transform .9s cubic-bezier(.2,.7,.2,1), opacity .9s; }
.ml-slide.is-active .ml-card { transform: none; }
.ml-slide.is-active .ml-copy > * { transform: none; opacity: 1; }
.ml-slide.is-active .ml-copy > :nth-child(2) { transition-delay: .08s; }
.ml-slide.is-active .ml-copy > :nth-child(3) { transition-delay: .16s; }
.ml-slide.is-active .ml-copy > :nth-child(4) { transition-delay: .24s; }
.ml-kicker { font: 500 13px/1 var(--ml-mono); letter-spacing: .14em; text-transform: uppercase; color: var(--ml-mute); margin: 0 0 18px; }
.ml-title { font: 500 clamp(44px, 7vw, 104px)/.95 var(--ml-sans); letter-spacing: -.035em; margin: 0 0 22px; color: #fff; }
.ml-price { font: 400 22px/1 var(--ml-mono); margin: 0 0 36px; color: #e8e8e8; }
.ml-btn {
  display: inline-flex; gap: 12px; align-items: center;
  padding: 16px 34px; border-radius: 999px; border: 1px solid rgba(255,255,255,.55);
  font: 500 14px/1 var(--ml-mono); letter-spacing: .12em; text-transform: uppercase; color: #fff !important;
  transition: background .2s, color .2s;
}
.ml-btn:hover { background: #fff; color: var(--ml-ink) !important; }
.ml-dots { position: absolute; z-index: 2; left: 50%; bottom: 32px; transform: translateX(-50%); display: flex; gap: 10px; }
.ml-dot { width: 42px; height: 3px; padding: 0; border: 0; background: rgba(255,255,255,.25); cursor: pointer; position: relative; overflow: hidden; border-radius: 2px; }
.ml-dot span { position: absolute; inset: 0; width: 0; background: #fff; }
.ml-dot.is-active span { animation: ml-fill var(--ml-slide-ms, 5500ms) linear forwards; }
.ml-hero.is-paused .ml-dot.is-active span { animation-play-state: paused; }
@keyframes ml-fill { to { width: 100%; } }

/* ---------- stats bar ---------- */
.ml-stats {
  background: var(--ml-ink); color: #fff;
  display: grid; grid-template-columns: repeat(4, 1fr);
  padding: 0 max(32px, calc(50vw - 588px)) 40px; border-top: 1px solid rgba(255,255,255,.08);
}
.ml-stats div { padding: 28px 0 0; }
.ml-stats span { display: block; font: 500 12px/1 var(--ml-mono); letter-spacing: .14em; text-transform: uppercase; color: var(--ml-mute); margin-bottom: 12px; }
.ml-stats strong { font: 600 19px/1.2 var(--ml-sans); }

/* ---------- catalog ---------- */
.ml-catalog { background: var(--ml-paper); padding: 72px 32px 88px; }
.ml-tabs { max-width: 1240px; margin: 0 auto 36px; display: flex; flex-wrap: wrap; gap: 8px; }
.ml-tab {
  font: 500 12px/1 var(--ml-mono); letter-spacing: .12em; text-transform: uppercase;
  padding: 12px 18px; border-radius: 999px; border: 1px solid var(--ml-line); background: #fff; color: var(--ml-ink); cursor: pointer;
  transition: background .2s, color .2s, border-color .2s;
}
.ml-tab:hover { border-color: var(--ml-ink); }
.ml-tab.is-active { background: var(--ml-ink); color: #fff; border-color: var(--ml-ink); }
.ml-grid { max-width: 1240px; margin: 0 auto; display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 18px; }
.ml-item { background: #f1f1f1; border: 1px solid var(--ml-line); border-radius: 16px; overflow: hidden; display: flex; flex-direction: column; transition: border-color .2s, transform .2s; }
.ml-item:hover { border-color: #bdbdb8; transform: translateY(-2px); }
.ml-item[hidden] { display: none; }
.ml-item-top { display: flex; justify-content: space-between; gap: 8px; padding: 16px 18px 0; font: 500 11px/1.3 var(--ml-mono); letter-spacing: .12em; text-transform: uppercase; color: var(--ml-mute); white-space: nowrap; }
.ml-item-top span:last-child { overflow: hidden; text-overflow: ellipsis; }
.ml-item-img { display: block; }
.ml-item-img img { display: block; width: 100%; aspect-ratio: 1; object-fit: cover; }
.ml-item-foot { background: #fff; padding-top: 16px !important; display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; padding: 0 18px 18px; margin-top: auto; border-top: 1px solid var(--ml-line); }
.ml-item-name { display: block; font: 600 20px/1.15 var(--ml-sans); letter-spacing: -.01em; }
.ml-item-amt { font: 400 13px/1 var(--ml-mono); color: var(--ml-mute); }
.ml-item-buy { display: flex; align-items: center; gap: 12px; flex-shrink: 0; }
.ml-item-price { font: 500 17px/1 var(--ml-mono); }
.ml-add { font: 500 12px/1 var(--ml-mono); letter-spacing: .1em; text-transform: uppercase; padding: 11px 16px; border-radius: 999px; background: var(--ml-ink); color: #fff !important; }
.ml-add:hover { opacity: .85; }
.ml-out { font: 500 12px/1 var(--ml-mono); color: var(--ml-mute); text-transform: uppercase; }

/* ---------- steps ---------- */
.ml-steps { background: var(--ml-paper); border-top: 1px solid var(--ml-line); display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; padding: 64px max(32px, calc(50vw - 620px)); }
.ml-steps em { font: 500 13px/1 var(--ml-mono); font-style: normal; color: var(--ml-mute); }
.ml-steps h3 { font: 600 30px/1.1 var(--ml-sans); letter-spacing: -.02em; margin: 14px 0 10px; }
.ml-steps p { margin: 0; color: #4a4d53; font-size: 16px; line-height: 1.5; }
.ml-ruo { margin: 0; padding: 22px 32px 40px; background: var(--ml-paper); text-align: center; font: 400 12px/1.5 var(--ml-mono); color: var(--ml-mute); letter-spacing: .04em; }

/* ---------- responsive ---------- */
@media (max-width: 860px) {
  .ml-hero { min-height: 780px; }
  .ml-slide-inner { grid-template-columns: 1fr; gap: 28px; padding: 32px 20px 80px; align-content: center; }
  .ml-card { max-width: 340px; margin: 0 auto; }
  .ml-copy { text-align: center; }
  .ml-stats { grid-template-columns: repeat(2, 1fr); padding: 0 20px 32px; }
  .ml-catalog { padding: 48px 16px 64px; }
  .ml-steps { grid-template-columns: 1fr; padding: 48px 20px; }
}
@media (prefers-reduced-motion: reduce) {
  .ml-slide, .ml-card, .ml-copy > * { transition: none !important; }
}
