/* SmirkDuel 0.4.11.9.3 — security/performance/accessibility hardening */

.sd-skip-link{
  position:fixed;left:14px;top:10px;z-index:10050;
  padding:10px 14px;border:3px solid #21183d;border-radius:12px;
  background:#fff;color:#21183d;font-weight:900;
  transform:translateY(-180%);transition:transform .15s ease;
}
.sd-skip-link:focus{transform:translateY(0)}

:where(a,button,input,select,textarea,summary,[tabindex]):focus-visible{
  outline:3px solid #21183d;
  outline-offset:4px;
}
.arena-search:focus-within{
  box-shadow:0 0 0 4px rgba(33,24,61,.18);
}
.arena-search input:focus-visible{outline:0}

/* Keep brand surfaces AA-friendly without changing the palette. */
.story-card-one,
.reaction-quote,
.sd-nav-cta,
.arena-refresh,
.arena-champion-crown,
.footer-primary-cta{
  color:#21183d;
}
.story-card-four{color:#171126}
.story-card-one .story-detail,
.story-card-four .story-detail{color:#3a2448}

/* Mobile navigation */
.sd-mobile-menu-toggle{
  display:none;place-items:center;width:44px;height:44px;
  border:2px solid #21183d;border-radius:13px;background:#fff;color:#21183d;
  box-shadow:3px 3px 0 #21183d;cursor:pointer;
}
.sd-mobile-menu-toggle span{
  display:block;width:20px;height:2px;background:currentColor;border-radius:99px;
  transition:transform .16s ease,opacity .16s ease;
}
.sd-mobile-menu-toggle span+span{margin-top:4px}
.sd-nav.is-menu-open .sd-mobile-menu-toggle span:nth-child(1){transform:translateY(6px) rotate(45deg)}
.sd-nav.is-menu-open .sd-mobile-menu-toggle span:nth-child(2){opacity:0}
.sd-nav.is-menu-open .sd-mobile-menu-toggle span:nth-child(3){transform:translateY(-6px) rotate(-45deg)}

/* Mobile horizontal sections get explicit controls instead of relying on discovery. */
.sd-carousel-controls{
  display:none;align-items:center;justify-content:flex-end;gap:8px;margin:12px 0 0;
}
.sd-carousel-controls span{margin-right:auto;color:#5f526a;font-size:.72rem;font-weight:800}
.sd-carousel-controls button{
  display:grid;place-items:center;width:44px;height:44px;border:2px solid #21183d;
  border-radius:13px;background:#fff;color:#21183d;box-shadow:3px 3px 0 #21183d;cursor:pointer;
}

/* Reserve layout space for media and reduce off-screen work. */
.mode-image-stack picture,
.reaction-card picture,
.footer-brand-lockup picture{display:block;width:min(285px,72%)}
.footer-brand-lockup picture img{display:block;width:100%;height:auto}
.mode-image-stack img,
.reaction-card img,
.footer-brand-lockup img{max-width:100%}
.story-section,
.modes-section,
.lab-section,
.reaction-section,
.difference-section,
.submit-section,
.arena-section,
.final-section{
  content-visibility:auto;
  contain-intrinsic-size:auto 900px;
}

/* Pre-launch primary action. */
.btn-beta{
  display:inline-flex;align-items:center;justify-content:center;gap:11px;
  min-height:58px;padding:14px 20px;border:var(--line);border-radius:17px;
  background:var(--pink);color:#21183d;box-shadow:var(--shadow-sm);font-weight:900;
  transition:.18s ease;
}
.btn-beta:hover{transform:translate(-3px,-3px);box-shadow:9px 9px 0 var(--ink)}
.release-beta-row{
  display:flex;flex-wrap:wrap;gap:10px;margin-top:18px;
}
.release-beta-row a{
  display:inline-flex;align-items:center;gap:8px;padding:11px 14px;border:2px solid #21183d;
  border-radius:13px;background:#fff;color:#21183d;box-shadow:3px 3px 0 #21183d;font-weight:900;
}

/* Standalone legal / notice pages */
.sd-legal-page{
  margin:0;background:#fffaf3;color:#171126;font-family:"DM Sans",system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
}
.sd-legal-page a{color:#4a2dc6}
.sd-legal-page-top{
  position:sticky;top:0;z-index:20;display:flex;align-items:center;justify-content:space-between;
  gap:18px;padding:14px clamp(16px,4vw,48px);border-bottom:3px solid #171126;background:#fff;
}
.sd-legal-page-brand{font-weight:1000;font-size:1.15rem;text-decoration:none;color:#171126!important}
.sd-legal-page-top nav{display:flex;flex-wrap:wrap;gap:8px}
.sd-legal-page-top nav a{
  padding:8px 10px;border:2px solid #171126;border-radius:999px;color:#171126;
  background:#f4edff;font-size:.78rem;font-weight:850;text-decoration:none;
}
.sd-legal-page-main,
.sd-report-page-main{
  width:min(1040px,calc(100% - 28px));margin:34px auto 70px;
}
.sd-legal-page-main .sd-legal-panel{padding:0}
.sd-legal-page-main .sd-legal-panel>section,
.sd-report-page-main>section{
  max-width:920px;margin:28px auto 0;padding:24px;border-top:2px dashed rgba(23,17,38,.18);
}
.sd-report-page-main .sd-legal-hero{margin:0 auto}
.sd-report-page-main h1{position:relative;z-index:1;max-width:820px;margin:18px 0 10px;font-size:clamp(2.3rem,6vw,4.8rem);line-height:.95}
.sd-report-page-main h2{margin:0 0 12px;font-size:1.55rem}
.sd-report-page-main p,
.sd-report-page-main li{line-height:1.7;color:#40364d}
.sd-report-checklist{padding-left:24px}
.sd-report-checklist li+li{margin-top:9px}
.sd-legal-page-footer{
  display:flex;justify-content:space-between;gap:16px;padding:18px clamp(16px,4vw,48px);
  border-top:3px solid #171126;background:#171126;color:#fff;
}
.sd-legal-page-footer a{color:#fff;font-weight:900}

/* Direct legal links can still open the modal on the landing with JS. */
.footer-legal-menu a[data-legal-open]{
  width:100%;display:grid;grid-template-columns:1fr auto;align-items:center;
}

@media(max-width:920px){
  .sd-nav{grid-template-columns:auto 1fr auto auto}
  .sd-mobile-menu-toggle{display:grid;justify-self:end}
  .sd-links{
    position:absolute;left:0;right:0;top:calc(100% + 10px);
    display:none!important;grid-template-columns:1fr;gap:5px;padding:10px;
    border:3px solid #21183d;border-radius:17px;background:#fff;box-shadow:6px 6px 0 #21183d;
  }
  .sd-nav.is-menu-open .sd-links{display:grid!important}
  .sd-links a{display:block;padding:12px 14px;text-align:left}
}

@media(max-width:700px){
  .sd-carousel-controls{display:flex}
  .story-track,.reaction-mosaic{scrollbar-width:thin}
  .btn-beta,.btn-punch,.btn-submit-meme{flex:1;min-width:145px;padding-inline:12px}
  .sd-legal-page-top{align-items:flex-start;flex-direction:column}
  .sd-legal-page-top nav{width:100%}
  .sd-legal-page-top nav a{flex:1;text-align:center}
  .sd-legal-page-footer{align-items:flex-start;flex-direction:column}
}

@media(prefers-reduced-motion:reduce){
  .sd-skip-link,.sd-mobile-menu-toggle span,.btn-beta{transition:none!important}
}
