/* GPU website unified layout · 2026-11-02
   Applies only to public landing pages, including all SEO article variants.
   Keep banner proportions; never stretch/crop uploaded images or alter their paths. */

:root {
  --gpu-layout-max: 1200px;
  --gpu-layout-gutter: clamp(12px, 3.2vw, 24px);
  --max: var(--gpu-layout-max);
}

/* Consistent centered canvas across header, hero, banners, editorial,
   model directory and footer. Full-bleed section backgrounds remain intact. */
.container,
.dense-section > .dense-container,
.footer-shell,
.gpu-seo-article > .gpu-seo-shell {
  width: calc(100% - var(--gpu-layout-gutter) - var(--gpu-layout-gutter));
  max-width: var(--gpu-layout-max);
  margin-inline: auto;
}

/* The article's original side padding made it narrower than the surrounding
   content at the same viewport. One common gutter prevents that mismatch. */
.gpu-seo-article { padding-inline: 0; }
.gpu-seo-article > .gpu-seo-shell { min-width: 0; }
.gpu-seo-article .banner-section > .container {
  width: 100%;
  max-width: 100%;
  margin-inline: auto;
}

/* Browser default figure margin was reducing every 16:9/2:1 banner by 80px.
   All main promotional images now fill the SAME centered content width. */
main figure.media-frame,
main figure.square-frame,
main figure.care-howto-figure {
  display: block;
  margin: 0;
  min-width: 0;
  max-width: 100%;
}
main figure.media-frame { width: 100%; }
main .media-frame > picture,
main .media-frame > .responsive-picture,
main .square-frame > picture,
main .care-howto-figure > picture {
  display: block;
  width: 100%;
  max-width: 100%;
}
main .media-frame img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  aspect-ratio: 2 / 1;
  object-fit: contain;
  object-position: center;
}
/* How-to illustration is intentionally square (1254x1254), not a banner. */
main .square-frame img,
main .care-howto-figure img {
  display: block;
  width: 100%;
  max-width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: contain;
}
main img,
main picture,
main video,
main iframe,
main svg { max-width: 100%; }

/* Prevent grid items and long URLs/model names from expanding the page.
   Wide technical tables scroll inside their OWN panel, not the viewport. */
main,
main > *,
main section,
main article,
main aside,
main .gpu-seo-shell,
main .gpu-seo-block,
main .gpu-seo-lead,
main .gpu-seo-table-wrap,
main .article-content,
main .keyword-directory,
main .keyword-group,
main .footer-panel {
  min-width: 0;
}
main h1,
main h2,
main h3,
main h4,
main p,
main li,
main th,
main td,
main a,
main strong { overflow-wrap: anywhere; }
.gpu-seo-table-wrap,
.article-content table,
.decision-block .data-table,
.knowledge-section .article-content table {
  max-width: 100%;
  overscroll-behavior-x: contain;
  -webkit-overflow-scrolling: touch;
}
.gpu-seo-table-wrap { overflow-x: auto; overflow-y: hidden; }

/* Keep site chrome inside viewport without hiding the contents of cards.
   Existing mobile navigation and floating CTA behavior is preserved. */
html, body { max-width: 100%; }
header .nav,
header .brand,
header #mainNav,
.site-footer .footer-shell { min-width: 0; }
header .brand { max-width: 100%; }
header .brand-text { overflow-wrap: anywhere; }

@media (max-width: 980px) {
  header .brand { flex: 1 1 auto; }
  header #mainNav {
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
  }
  header #mainNav a { white-space: normal; overflow-wrap: anywhere; }
}

@media (max-width: 680px) {
  :root { --gpu-layout-gutter: 12px; }
  .nav { min-height: 64px; }
  .brand { min-width: 0; }
  .brand-text { min-width: 0; white-space: normal; }
  .hero-media { padding-top: 12px; }
  .hero-copy { gap: 18px; }
  main .media-frame { border-radius: 16px; }
  main .media-frame img { aspect-ratio: 2 / 1; }
  main .square-frame,
  main .care-howto-figure { border-radius: 16px; }
  .banner-caption { min-width: 0; flex-wrap: wrap; }
  .gpu-seo-lead,
  .gpu-seo-article .gpu-seo-block { padding: clamp(16px, 4vw, 24px); }
  .gpu-seo-article .gpu-seo-table { width: 100%; }
  .gpu-seo-toc { padding: 15px; }
  .gpu-seo-toc > div { gap: 6px; }
  .gpu-seo-toc a { max-width: 100%; }
  .footer-bottom { min-width: 0; }
  .gpu-credits { white-space: normal; overflow-wrap: anywhere; }
  .floating-cta { max-width: calc(100% - 16px); }
}

@media (max-width: 380px) {
  :root { --gpu-layout-gutter: 10px; }
  .gpu-seo-lead,
  .gpu-seo-article .gpu-seo-block { padding: 16px 14px; }
  .gpu-seo-article .gpu-seo-table th,
  .gpu-seo-article .gpu-seo-table td { padding: 12px; }
  .gpu-seo-faq-item summary { padding-left: 14px; }
}

@media (prefers-reduced-motion: reduce) {
  .gpu-seo-article *, .media-frame * { scroll-behavior: auto !important; }
}
