/* Home only, below the existing desktop breakpoint. Uses the site's Ember tokens. */
@media screen and (max-width: 47.99rem) {
  body.mh-home { --header-h: 56px; --header-top: 0px; }
  .mh-home header.site {
    position: sticky; top: 0; padding: 0; height: 56px;
    background: color-mix(in srgb, var(--bg) 92%, transparent);
    -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px);
  }
  .mh-home header.site .bar { min-height: 56px; height: 56px; padding: 0 12px 0 6px; gap: 4px; }
  .mh-home:has(header .menu[open]) header.site { -webkit-backdrop-filter: none; backdrop-filter: none; }
  .mh-home header .menu { order: -1; }
  .mh-home header .menu > summary { width: 44px; height: 44px; border: 0; background: none; box-shadow: none; }
  .mh-home .burger, .mh-home .burger::before, .mh-home .burger::after { width: 20px; }
  .mh-home header .brand { font-size: 21px; gap: 7px; letter-spacing: -.8px; margin-right: auto; }
  .mh-home header .mark { width: 28px; height: 28px; border-radius: 9px; }
  .mh-home header .bar > .btn {
    display: inline-flex; min-height: 36px; padding: 0 12px; margin-left: 5px;
    font-size: 12px; font-weight: 700; border: 1.5px solid var(--primary); border-radius: 10px;
    color: var(--fg); background: var(--card); box-shadow: none;
  }
  .mh-home header .menu nav { padding-top: 66px; padding-bottom: calc(20px + env(safe-area-inset-bottom, 0px)); }
  .mh-tabs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); height: 46px; border-bottom: 1px solid var(--line); }
  .mh-tabs a {
    position: relative; display: flex; align-items: center; justify-content: center; gap: 6px;
    font: 700 13px/1 var(--font-body); text-decoration: none; color: var(--muted-fg);
  }
  .mh-tabs svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
  .mh-tabs .is-active { color: var(--fg); }
  .mh-tabs .is-active svg { color: var(--primary); }
  .mh-tabs .is-active::after {
    content: ''; position: absolute; bottom: -1px; left: 14%; right: 14%; height: 3px;
    border-radius: 3px 3px 0 0; background: linear-gradient(100deg, var(--primary), var(--accent));
    box-shadow: 0 0 12px var(--glow-1);
  }
  .mh-home .hero-home {
    display: block; isolation: isolate; height: 322px; min-height: 0; padding: 0; margin: 12px 12px 0;
    border-radius: 22px; background: radial-gradient(ellipse at 100% 0%, color-mix(in srgb, var(--primary) 22%, var(--card)), var(--bg) 78%);
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--primary) 38%, transparent), 0 20px 40px -22px var(--glow-1);
  }
  .mh-home .hero-home::before {
    z-index: -1; background: linear-gradient(0deg, var(--bg), transparent 45%), linear-gradient(90deg, transparent 20%, color-mix(in srgb, var(--bg) 30%, transparent) 48%, transparent 76%);
  }
  .mh-home .hero-home::after { z-index: 3; border: 1px solid color-mix(in srgb, var(--primary) 30%, transparent); border-radius: inherit; background: none; }
  .mh-home .hero-home .hero-img {
    inset: 0 auto 0 0; z-index: -2; width: 64%; height: 100%; max-width: none;
    object-fit: cover; object-position: 79% 0; opacity: 1;
    -webkit-mask-image: linear-gradient(90deg, #000 45%, transparent 100%), linear-gradient(180deg, #000 65%, transparent 100%);
    -webkit-mask-composite: source-in;
    mask-image: linear-gradient(90deg, #000 45%, transparent 100%), linear-gradient(180deg, #000 65%, transparent 100%);
    mask-composite: intersect;
  }
  .mh-home .hero-home .hero-in { position: absolute; inset: 0; width: 100%; padding: 0; }
  .mh-home .hero-home .hero-in > .kicker, .mh-home .hero-home .hero-in > .lead { display: none; }
  .mh-home .hero-home h1 { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .mh-hero-copy { position: absolute; top: 18px; right: 16px; width: 202px; text-align: right; }
  .mh-flag {
    display: inline-flex; align-items: center; min-height: 24px; padding: 0 9px; border-radius: 999px;
    background: color-mix(in srgb, var(--primary) 17%, var(--card)); border: 1px solid color-mix(in srgb, var(--primary) 55%, transparent);
    color: var(--accent); font: 700 9px/1 var(--font-body); letter-spacing: 1px; text-transform: uppercase;
  }
  .mh-hero-title { margin: 10px 0 0; font: 700 23px/1.25 var(--font-head); letter-spacing: -.8px; color: var(--fg); }
  .mh-hero-title strong {
    display: block; margin-top: 4px; font-size: 43px; line-height: 1.15; letter-spacing: -2px;
    background: linear-gradient(180deg, var(--head-a), var(--primary)); -webkit-background-clip: text; background-clip: text; color: transparent;
    filter: drop-shadow(0 4px 14px var(--glow-1));
  }
  .mh-facts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; margin-top: 14px; }
  .mh-facts > span {
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; height: 54px;
    border: 1px solid rgb(255 255 255 / .12); border-radius: 12px; background: rgb(255 255 255 / .055);
    -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
    color: var(--muted-fg); font: 700 8px/1 var(--font-body); text-transform: uppercase; letter-spacing: .5px;
  }
  .mh-facts b { color: var(--fg); font: 700 20px/1.1 var(--font-head); letter-spacing: -.5px; }
  .mh-home .hero-home .ctas { position: absolute; left: 12px; right: 12px; bottom: 36px; display: block; width: auto; }
  .mh-home .hero-home .ctas > .btn-fill {
    position: relative; display: flex; width: 100%; height: 54px; min-height: 54px; padding: 0 8px;
    overflow: hidden; border-radius: 16px; font: 700 16px/1.2 var(--font-head); letter-spacing: -.3px;
    background: linear-gradient(110deg, var(--primary), var(--accent)); color: var(--on-primary);
    border: 1px solid color-mix(in srgb, var(--accent) 70%, transparent); box-shadow: 0 10px 28px -9px var(--glow-1), inset 0 1px 0 rgb(255 255 255 / .2);
  }
  .mh-home .hero-home .ctas > .btn-stroke { display: none; }
  .mh-hero-terms { position: absolute; bottom: 11px; left: 8px; right: 8px; margin: 0; text-align: center; color: var(--muted-fg); font: 400 11px/1.4 var(--font-body); }
  .mh-home #main > .wrap { padding-inline: 12px; }
  .mh-home #classifica { margin: 0 0 4rem; scroll-margin-top: 68px; }
  .mh-home #classifica > .section-head { display: none; }
  .mh-browse { padding-top: 18px; }
  .mh-browse h2 { max-width: none; margin: 0 4px 13px; font: 700 21px/1.3 var(--font-head); letter-spacing: -.6px; }
  .mh-browse h2 span { color: var(--primary); }
  .mh-chips {
    display: flex; gap: 8px; width: calc(100% + 24px); max-width: none; margin: 12px -12px 0; padding: 0 12px 11px;
    overflow-x: auto; overscroll-behavior-x: contain; scrollbar-width: none; -webkit-mask-image: linear-gradient(90deg, #000 93%, transparent); mask-image: linear-gradient(90deg, #000 93%, transparent);
  }
  .mh-chips::-webkit-scrollbar { display: none; }
  .mh-chips button {
    display: inline-flex; align-items: center; justify-content: center; flex: none; gap: 6px; min-height: 44px; padding: 0 15px;
    border: 1.5px solid transparent; border-radius: 999px; color: var(--fg); background: var(--card); font: 600 12px/1 var(--font-body); white-space: nowrap; cursor: pointer;
  }
  .mh-chips [aria-pressed="true"] { border-color: var(--primary); background: color-mix(in srgb, var(--primary) 8%, var(--card)); }
  .mh-chips svg { width: 15px; height: 15px; fill: none; stroke: var(--accent); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
  .mh-empty button { min-height: 44px; padding: 0; border: 0; color: var(--link); background: none; font: 600 13px/1.4 var(--font-body); text-decoration: underline; cursor: pointer; }
  .mh-home #classifica .toplist { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin: 0; }
  .mh-home #classifica .tool-row {
    display: block; aspect-ratio: 3 / 4; min-height: 0; padding: 12px; gap: 0; border: 1px solid rgb(255 255 255 / .1); border-radius: 18px;
    background: var(--card); box-shadow: none; -webkit-backdrop-filter: none; backdrop-filter: none;
  }
  .mh-home #classifica .tool-row[hidden], .mh-home .mh-empty[hidden] { display: none; }
  .mh-home #classifica .tool-row::before { content: ''; position: absolute; z-index: -1; inset: 0; background: linear-gradient(0deg, rgb(15 10 9 / .98), rgb(15 10 9 / .7) 20%, transparent 58%); }
  .mh-home #classifica .tool-img { z-index: -2; opacity: 1; object-fit: cover; object-position: var(--mh-photo-position); -webkit-mask: none; mask: none; }
  .mh-home #classifica .tool-head { display: block; margin: 0; }
  .mh-home #classifica .rank { position: absolute; top: 10px; left: 10px; width: 25px; height: 25px; display: grid; place-items: center; border: 0; border-radius: 8px; color: var(--on-primary); background: linear-gradient(130deg, var(--primary), var(--accent)); font: 700 12px/1 var(--font-head); }
  .mh-home #classifica .tool-head .chip, .mh-home #classifica .pick-badge, .mh-home #classifica .tool-meta, .mh-home #classifica .tool-desc { display: none; }
  .mh-home #classifica .score { position: absolute; right: 9px; top: 9px; display: grid; place-items: center; width: 38px; height: 38px; margin: 0; border-radius: 50%; color: var(--fg); background: color-mix(in srgb, var(--bg) 70%, transparent); border: 1px solid color-mix(in srgb, var(--accent) 60%, transparent); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); font: 700 14px/1 var(--font-head); }
  .mh-home #classifica .score small { display: none; }
  .mh-home #classifica .tool-name { position: absolute; bottom: 68px; left: 12px; right: 8px; margin: 0; font: 700 clamp(13px, 3.8vw, 17px)/1.3 var(--font-head); letter-spacing: -.4px; white-space: nowrap; }
  .mh-home #classifica .tool-actions { position: absolute; inset: 0; display: flex; align-items: flex-end; width: auto; margin: 0; padding: 0 12px 12px; border-radius: inherit; }
  .mh-home #classifica .tool-actions .btn-fill {
    position: static; display: inline-flex; width: 100%; height: 44px; min-height: 44px; padding: 0 8px; gap: 7px;
    border: 1px solid color-mix(in srgb, var(--accent) 80%, transparent); border-radius: 10px;
    background: linear-gradient(110deg, var(--primary), var(--accent)); color: var(--on-primary);
    box-shadow: 0 6px 20px -7px var(--glow-1), inset 0 1px 0 rgb(255 255 255 / .3);
    font: 700 12px/1.2 var(--font-head); letter-spacing: -.2px;
  }
  .mh-home #classifica .tool-actions .btn-fill::before { content: '↗' / ''; order: 1; font: 700 17px/1 var(--font-body); }
  .mh-home #classifica .tool-actions .btn-fill::after { inset: 0; border-radius: 18px; }
  .mh-home #classifica .tool-actions .btn-fill:focus-visible::after { outline: 2px solid var(--accent); outline-offset: -3px; }
  .mh-home #classifica .tool-actions .btn-ghost { display: none; }
  .mh-empty { max-width: none; padding: 24px 12px; text-align: center; color: var(--muted-fg); font-size: 14px; }
  .mh-home:not(.mh-past-hero) nav.toc, .mh-home:not(.mh-past-hero) a.to-top { visibility: hidden; pointer-events: none; }
  .mh-home nav.toc, .mh-home a.to-top { bottom: calc(32px + env(safe-area-inset-bottom, 0px)); }
  .mh-home #classifica ~ section { scroll-margin-top: 68px; }
  @media (max-width: 374px) {
    .mh-home header .brand { font-size: 19px; }
    .mh-home header .bar > .btn { padding-inline: 10px; font-size: 11px; }
    .mh-hero-copy { right: 12px; width: 192px; }
    .mh-hero-title { font-size: 22px; }
    .mh-hero-title strong { font-size: 40px; }
    .mh-facts { gap: 4px; }
    .mh-browse h2 { font-size: 20px; }
  }
}
