/* Shared responsive guardrails for all server-rendered public pages. */
:where(*,*::before,*::after){box-sizing:border-box}
html,body{max-width:100%;overflow-x:clip}
body{min-width:320px}
:where(main,main>*,.shell,.header-main,.footer-top,.footer-bottom,.hero-layout,
  .match-detail-layout,.match-v3-grid,.matchday-grid,.category-grid,.story-grid,
  .listing-grid,.article-layout,.editorial-page,.match-page,.match-v3){min-width:0}
:where(img,svg,video,iframe){max-width:100%}
:where(input,select,textarea,button){max-width:100%}
:where(pre,code){max-width:100%;overflow-wrap:anywhere}
:where(.table-responsive,.ap-table-wrap){max-width:100%;overflow-x:auto;-webkit-overflow-scrolling:touch}
:where(.article-prose,.editorial-page,.match-detail-section,.match-detail-info-card,
  .match-detail-source-card,.matches-card,.matchday-card,.story-card){min-width:0}
:where(.article-prose img,.story-image img,.hero-visual img){height:auto}
:where(.article-prose table){max-width:100%;border-collapse:collapse}
:where(.article-prose td,.article-prose th){overflow-wrap:anywhere}

@media (min-width:761px) and (max-width:1000px){
  .shell{width:min(1480px,calc(100% - 48px))}
  .match-detail-layout{grid-template-columns:minmax(0,1fr)!important}
  .match-v3-grid{grid-template-columns:minmax(0,1fr)!important}
}
@media (max-width:760px){
  .shell{width:calc(100% - 32px)}
  .site-header,.header-main,.main-nav,.site-footer,main{min-width:0;max-width:100%}
  .main-nav{width:100%;max-width:100vw}
  .main-nav a,.footer-links a{min-width:0;overflow-wrap:anywhere}
  .footer-links{grid-template-columns:repeat(2,minmax(0,1fr))}
  .match-detail-layout,.match-v3-grid{grid-template-columns:minmax(0,1fr)!important}
  .match-detail-main,.match-detail-aside{min-width:0}
  .article-prose,.editorial-page,.match-detail-section{max-width:100%}
  .article-prose pre,.article-prose table{display:block;max-width:100%;overflow-x:auto}
  .match-detail-tabs{max-width:100%;overflow-x:auto}
}
@media (max-width:420px){
  .shell{width:calc(100% - 24px)}
  .footer-links{gap:10px 12px}
  .matches-card,.match-detail-section{min-width:0}
  .match-detail-section-head{align-items:flex-start;flex-direction:column}
  .match-lineups-grid{grid-template-columns:minmax(0,1fr)}
}
@media(prefers-reduced-motion:reduce){
  :where(*,*::before,*::after){scroll-behavior:auto!important;transition-duration:0.01ms!important;animation-duration:0.01ms!important}
}
