/* Tipografía de lectura compartida por los seis idiomas. */
@media screen {
  :root {
    --reading-size: calc(17px * var(--text-scale, 1));
    --supporting-size: calc(15px * var(--text-scale, 1));
    --label-size: calc(14px * var(--text-scale, 1));
  }

  body { font-size: var(--reading-size); }

  .section-heading > p,
  .feature > p,
  .clarity-note p,
  .module-intro > p:not(.eyebrow),
  .module-items p,
  .download-availability p,
  .download-card > p:not(.asset-size),
  .project-copy > p:not(.eyebrow),
  .source-card > p,
  .faq-heading > p:last-child,
  .faq-list details > p,
  .checksum-heading > div > p:last-child,
  .checksum-help p {
    font-size: var(--reading-size);
    line-height: 1.8;
  }

  .section-heading > p { max-width: 450px; }
  .feature > p { min-height: 0; }
  .feature h3 { font-size: calc(26px * var(--text-scale, 1)); }
  .feature-top { gap: 12px; flex-wrap: wrap; }
  .feature-bottom { font-size: var(--label-size); line-height: 1.7; }
  .profile-row > span { font-size: var(--label-size); padding: 6px 10px; }
  .decision-path { font-size: var(--supporting-size); gap: 8px; }
  .clarity-note > .icon { flex: none; margin-top: 5px; }
  .module-items h4 { font-size: calc(18px * var(--text-scale, 1)); line-height: 1.5; }
  .module-items > article { min-width: 0; }
  .module-tabs > button { font-size: var(--supporting-size); min-height: 48px; }

  .eyebrow,
  .eyebrow > span,
  .module-intro .eyebrow,
  .feature-number,
  .mini-label,
  .architecture,
  .package-type,
  .pending-label,
  .source-card-head,
  .source-license {
    font-size: var(--label-size);
    line-height: 1.7;
    letter-spacing: .06em;
  }
  .pending-label { white-space: normal; }
  .source-card-head { flex-wrap: wrap; gap: 8px 10px; }

  .button,
  .text-link,
  .hero-actions .text-link,
  .source-card .button,
  .source-actions .button,
  .download-card .download-button,
  .portable-buttons .button,
  .closing .text-link,
  .dialog-controls > .button,
  .checksum-manifest {
    font-size: var(--supporting-size);
    min-height: 46px;
    line-height: 1.6;
  }
  .download-card .download-button { min-height: 50px; }
  .download-card h3 { font-size: calc(24px * var(--text-scale, 1)); line-height: 1.4; }
  .download-extra,
  .download-extra > a,
  .portable-tools,
  .portable-tools select,
  .portable-card small,
  .download-bottom,
  .noscript-note,
  .screenshot-note,
  .source-legal,
  .dialog-note {
    font-size: var(--supporting-size);
    line-height: 1.8;
  }
  .portable-tools { flex-wrap: wrap; }
  .portable-tools select { min-height: 40px; max-width: 100%; }
  .download-card > .asset-size { font-size: var(--label-size); line-height: 1.7; }
  .download-bottom .icon { flex: none; width: 17px; height: 17px; margin-top: 5px; }
  .source-legal { margin-top: 18px; }
  .faq-list summary { font-size: var(--reading-size); line-height: 1.65; }
  .closing { flex-wrap: wrap; }
  .closing p { font-size: var(--supporting-size); line-height: 1.8; }
  .closing p strong { font-size: var(--reading-size); }

  .release { font-size: var(--label-size); letter-spacing: .06em; }
  .hero-footnote { font-size: var(--supporting-size); }
  .visual-label { font-size: var(--label-size); letter-spacing: .06em; }
  .visual-caption { font-size: var(--label-size); }
  .floating-feature > span:last-child { font-size: var(--label-size); }
  .floating-feature strong { font-size: var(--supporting-size); }
  .facts div > span { font-size: var(--supporting-size); }
  .expand-label { font-size: var(--label-size); white-space: normal; }
  .screen-caption { flex-wrap: wrap; gap: 9px; }
  .screen-caption > span { min-width: 0; }
  .screen-caption strong { font-size: calc(16px * var(--text-scale, 1)); line-height: 1.6; }
  .screen-caption small,
  .screen-caption > span:last-child,
  .dialog-top .eyebrow,
  .dialog-controls > span { font-size: var(--label-size); line-height: 1.7; }
  .more-screens > summary { font-size: var(--supporting-size); line-height: 1.6; }

  .checksum-file,
  .checksum-copy,
  .checksum-card-bottom > span,
  .checksum-link,
  .download-extra > .checksum-link,
  .checksum-kicker,
  .checksum-help code { font-size: var(--label-size); }
  .checksum-value,
  .checksum-status { font-size: var(--supporting-size); }
  .checksum-help summary { font-size: calc(16px * var(--text-scale, 1)); }

  .site-footer { font-size: var(--supporting-size); }
  .footer-top { flex-wrap: wrap; gap: 20px 28px; }
  .footer-top > span { display: block; font-size: var(--supporting-size); line-height: 1.8; max-width: 35ch; }
  .footer-top > a:last-child { font-size: var(--supporting-size); line-height: 1.7; min-height: 44px; }
  .footer-top .brand > span { font-size: calc(24px * var(--text-scale, 1)); }
  .footer-top .brand small { display: block; font-size: var(--label-size); line-height: 1.7; }
  .footer-bottom { font-size: var(--label-size); line-height: 1.8; flex-wrap: wrap; gap: 24px; align-items: flex-start; }
  .footer-bottom > div:last-child { flex-wrap: wrap; gap: 14px 24px; min-width: 0; }
  .footer-bottom .author-credit p { font-size: var(--label-size); line-height: 1.8; }
  .author-link { font-size: var(--supporting-size); line-height: 1.7; }
  .author-link strong { font-size: calc(16px * var(--text-scale, 1)); }
  .author-link > span { font-size: var(--label-size); }
  .motion-toggle { font-size: var(--label-size); line-height: 1.7; min-height: 44px; }
  .footer-note { font-size: var(--supporting-size); line-height: 1.85; max-width: 100ch; }

  :root .site-header .navigation > a { font-size: var(--label-size); line-height: 1.6; }
  .site-header .brand small { font-size: var(--label-size); letter-spacing: .02em; }
  .brand-version { font-size: calc(13px * var(--text-scale, 1)); }
  .site-header .theme-control select,
  .site-header .text-size-control select,
  .site-header .language-picker select { font-size: var(--label-size); min-height: 28px; }
  .site-header .theme-control select { width: 10.8em; max-width: none; }
  .site-header .language-picker select { width: 9em; max-width: none; }
  .site-header .text-size-control select { width: 5em; }
}

/* El menú deja espacio a los controles cuando crece la tipografía. */
@media screen and (min-width: 1051px) and (max-width: 1400px) {
  .header-inner { grid-template-columns: auto 1fr; }
  .header-actions { justify-self: end; }
  .brand-version { display: none; }
  .js .menu-toggle { display: inline-flex; width: 40px; height: 40px; margin-left: 0; }
  .js .navigation { display: none; position: absolute; top: 100%; left: 24px; right: 24px; padding: 10px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow); max-height: calc(100dvh - 120px); overflow-y: auto; }
  .js .navigation.is-open { display: flex; flex-direction: column; align-items: stretch; }
  .navigation > a { padding: 13px 16px; }
  .navigation .nav-download { margin: 4px 0 0; justify-content: center; }
}
@media screen and (min-width: 1051px) {
  :root:is([data-text-size="110"],[data-text-size="120"],[data-text-size="130"]) .header-inner { grid-template-columns: auto 1fr; }
  :root:is([data-text-size="110"],[data-text-size="120"],[data-text-size="130"]) .header-actions { justify-self: end; }
  :root:is([data-text-size="110"],[data-text-size="120"],[data-text-size="130"]).js .menu-toggle { display: inline-flex; width: 40px; height: 40px; margin-left: 0; }
  :root:is([data-text-size="110"],[data-text-size="120"],[data-text-size="130"]).js .navigation { display: none; position: absolute; top: 100%; left: 24px; right: 24px; padding: 10px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow); max-height: calc(100dvh - 120px); overflow-y: auto; }
  :root:is([data-text-size="110"],[data-text-size="120"],[data-text-size="130"]).js .navigation.is-open { display: flex; flex-direction: column; align-items: stretch; }
  :root:is([data-text-size="110"],[data-text-size="120"],[data-text-size="130"]) .navigation > a { padding: 13px 16px; }
  :root:is([data-text-size="110"],[data-text-size="120"],[data-text-size="130"]) .navigation .nav-download { margin: 4px 0 0; justify-content: center; }
}
@media screen and (max-width: 1050px) {
  .header-inner { position: relative; height: auto; min-height: 120px; display: grid; grid-template-columns: 1fr; gap: 12px; padding-block: 12px; }
  .site-header .brand { justify-self: start; }
  .brand-version { display: none; }
  .header-actions { justify-self: stretch; display: grid; grid-template-columns: minmax(0,1.4fr) minmax(0,.8fr) minmax(0,1.2fr); gap: 8px; }
  .site-header :is(.theme-control,.text-size-control,.language-picker) { width: auto; height: auto; min-width: 0; padding: 6px; gap: 5px; }
  .site-header :is(.theme-control,.text-size-control,.language-picker) select { position: static; opacity: 1; width: 100%; max-width: none; min-width: 0; }
  .theme-control label,.text-size-control label,.language-picker label { display: none; }
  .js .header-actions .menu-toggle { display: inline-flex; position: absolute; right: 0; top: 14px; width: 40px; height: 40px; margin: 0; }
  .js .navigation { display: none; position: absolute; top: calc(100% + 6px); left: 0; right: 0; z-index: 2; padding: 10px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow); justify-self: stretch; max-height: calc(100dvh - 180px); overflow-y: auto; }
  .js .navigation.is-open { display: flex; flex-direction: column; align-items: stretch; }
  .navigation > a { padding: 13px 16px; }
  .navigation .nav-download { margin: 4px 0 0; justify-content: center; }
  .module-panel { grid-template-columns: 1fr; gap: 28px; }
}
@media screen and (max-width: 800px) {
  .section-heading { flex-direction: column; align-items: flex-start; gap: 18px; }
  .section-heading > p { max-width: none; padding: 0; }
  .module-intro { display: block; }
  .module-intro h3 { margin-bottom: 17px; }
  .mini-label { margin-top: 18px; }
  .footer-top > span { max-width: none; flex-basis: 100%; order: 2; }
  .footer-bottom > div:last-child { width: 100%; justify-content: flex-start; }
}
@media screen and (max-width: 600px) {
  .module-items { grid-template-columns: 1fr; }
}
@media screen and (max-width: 500px) {
  .feature-grid { gap: 22px; }
  .feature { padding: 25px 23px 0; }
  .closing .text-link { grid-column: 2; margin-left: 0; white-space: normal; }
}
@media screen and (max-width: 380px) {
  .header-actions { grid-template-columns: minmax(0,1fr) minmax(0,1fr); }
  .theme-control { grid-column: 1 / -1; }
  .text-size-control { grid-column: 1; }
  .language-picker { grid-column: 2; }
}
