/* Shared screen typography. Keep document overlays and print styles intact. */
button, input, select, textarea { font-family: inherit; }
select:focus-visible, textarea:focus-visible { outline: 3px solid var(--green); outline-offset: 4px; }
h1, h2, h3 { text-wrap: balance; word-break: normal; line-break: strict; }
.heading-phrase { display: inline-block; max-width: 100%; text-wrap: balance; }
p, li, dd { word-break: normal; line-break: strict; overflow-wrap: break-word; }
p { text-wrap: pretty; }
.reading-layout { grid-template-columns: 185px minmax(0, 1fr); }
.reading-layout > div, .hero > div, .guide-hero > div, .ops-hero > div,
.instruction-heading > div, .article-body, .tool-feature > div { min-width: 0; }
.text-link, .professional-hero .text-link { margin-left: 0; margin-right: 0; font-size: .9375rem; }
.professional-hero .button + .text-link { display: block; width: fit-content; }
.text-link { text-underline-offset: .25em; }
.chapter-nav a, .article-toc a { align-items: flex-start; }
.chapter-nav a > span, .article-toc a > span { flex: 0 0 1.6em; }
.breadcrumbs, .chapter-nav p, .chapter-nav a, .article-toc > p, .article-toc a,
.header .desktop-nav, .footer p, .footer > div:last-child > a { font-size: .875rem; }
.brand-name small { font-size: .75rem; letter-spacing: .015em; }
.header { flex-wrap: wrap; }
.header .desktop-nav { flex-wrap: wrap; row-gap: 8px; }
.reading-guide > div { flex-wrap: wrap; }
.footer > div:first-child p { white-space: normal; }
.tag, .news-status, .guide-badge { font-size: .875rem; }
.news-source-type { font-size: .75rem; }
.news-source-type { max-width: 100%; }
.card-top { flex-wrap: wrap; align-items: flex-start; gap: 8px 12px; }
.card-top time, .card-number, .card-bottom, .card-takeaway > span,
.scene-brand small, .scene-header, .scene-footer, .section-meta,
.hero-art figcaption, .ai-heading .eyebrow, .ai-heading .ai-date,
.ai-part h3 > span, .ai-part h3 small, .ai-commentary .ai-disclosure { font-size: .75rem; }
.article-card p, .card-takeaway p, .note-paper p, .ai-part p, .ai-part ul,
.ai-reason p, .service-grid p, .media-about p, .panel-summary,
.hero-takeaway p, .policy-stages p { font-size: 1rem; }
.scene-tabs { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.news-scene .scene-tabs button { flex-direction: column; gap: 2px; padding: 8px 4px; min-width: 0; }
.news-scene .scene-tabs button > span { display: block; font-size: .75rem; }
.scene-tab-label { font-size: .875rem; font-weight: 600; white-space: nowrap; }
.card-bottom { flex-wrap: wrap; gap: 8px 16px; }
.card-bottom > span:last-child { white-space: nowrap; }
.filters button, .search-tools label, .saved-filter, .save-article,
.scene-tabs button, .scene-header button, .filter-result, .reading-guide > div > span,
.reading-guide > p:last-child, .source-box a, .ai-basis, .ai-reason h3 { font-size: .875rem; }
.filters button, .scene-header button, .mobile-menu summary { min-height: 44px; }
.source-note, .article-section .source-note, .article-footnote { font-size: .875rem; line-height: 1.9; }
.source-note a, .guide-sources a { overflow-wrap: anywhere; }

/* Link cards: preserve a clear action without underlining whole paragraphs. */
.tool-feature { color: var(--ink); text-decoration: none; border: 1px solid #e2d2d8; }
.tool-feature:hover { border-color: #9f7b88; }
.tool-feature .text-link, .guide-card .text-link, .tool-learning-grid .text-link { margin-left: 0; margin-right: 0; font-size: .9375rem; }
.tool-feature p, .tool-learning-grid p { font-size: 1rem; }
.tool-feature .eyebrow, .tool-learning-grid small { font-size: .875rem; }
.tool-learning-grid > a { min-width: 0; }
.resource-link span, .resource-link small { font-size: .875rem; }
.version-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }

/* Guides: readable explanations, aligned calls to action, hanging lists. */
.guide-hero h1 { font-size: clamp(2rem, 4.6vw, 3.5625rem); }
.guide-hero h1 br { display: none; }
.guide-hero h1 em { display: block; text-wrap: balance; }
.guide-hero h1 em > span { display: inline-block; max-width: 100%; }
.guide-card p, .guide-disclosure, .condition-grid ul, .guide-case p,
.guide-pitfalls ul, .instruction-heading p, .instruction-note,
.scenario-intro p, .instruction-panel p:not(.eyebrow), .instruction-text section p { font-size: 1rem; }
.guide-card h2 { font-size: clamp(1.125rem, 5.2vw, 1.3125rem); }
.guide-card > small, .guide-meta, .guide-sources small, .guide-next small,
.instruction-banner small, .scenario-intro > span, .paper-hint,
.paper-attribution, .instruction-panel .eyebrow { font-size: .75rem; }
.guide-filters label, .guide-filters button, .guide-filters p, .library-heading a,
.instruction-banner > b, .condition-grid section > span, .guide-case > span,
.guide-sources a, .guide-next b, .guide-related > a, .instruction-bottom a,
.form-tabs button, .instruction-options label, .instruction-options button,
.paper-topline, .instruction-panel h4, .instruction-panel a, .instruction-text section a { font-size: .875rem; }
.guide-filters input, .instruction-options select { font-size: 1rem; }
.instruction-panel h4 small, .rule-table small { font-size: .75rem; }
.guide-filters button, .form-tabs button, .instruction-options button { min-height: 44px; }
.guide-filter-buttons { flex-wrap: wrap; }
.guide-recommendations { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; margin-top: 42px; }
.guide-recommendations .instruction-banner { margin: 0; padding: 24px; flex-wrap: wrap; align-items: flex-start; }
.guide-recommendations .banner-icon { display: none; }
.guide-recommendations .instruction-banner > b { display: block; margin-left: 0; white-space: normal; }
.record-list li { display: grid; grid-template-columns: 1.2em minmax(0, 1fr); gap: 12px; font-size: 1rem; }
.mark-picker { flex-wrap: wrap; }
.mark-picker button { width: 44px; height: 44px; min-width: 44px; font-size: .875rem; }

/* Operations: distinguish explanatory text from source dates and badges. */
.ops-nav a, .ops-tile > b, .ops-three a, .ops-controls label, .ops-controls p,
.ops-check-toolbar label, .ops-count-inputs label, .ops-training-card summary,
.ops-measures > section > span, .ops-check-toolbar > p, .ops-check-toolbar .button,
.ops-bottom-actions .button, .ops-check-row a, .ops-check-row label,
.ops-bottom-actions p, .ops-pref-grid a, .ops-pref-grid details,
.ops-window span { font-size: .875rem; }
.ops-tile p, .ops-section > p, .ops-three p, .ops-notice p,
.ops-title > p:not(.eyebrow), .ops-training-heading > p:last-child,
.ops-record-columns ul, .ops-timeline p, .ops-measures p, .ops-measures small,
.ops-cases p, .ops-eight li, .ops-storage, .ops-check-row p, .ops-pref-grid p,
.ops-window p, .ops-new { font-size: 1rem; }
.ops-tag, .ops-tile > span, .ops-three > section > span, .ops-sources small,
.ops-count-inputs small, .ops-result small, .ops-pref-grid header small,
.ops-pref-grid > section > small, .ops-foot, .ops-new span { font-size: .75rem; }
.ops-pref-status { font-size: .75rem !important; }
.ops-tile p, .ops-three p, .ops-pref-grid p, .ops-sources small,
.ops-pref-grid header small, .ops-pref-grid > section > small, .ops-foot { color: var(--muted); }
.ops-pref-status { color: var(--green) !important; }
.ops-sources { font-size: .875rem; }
.ops-record-columns h3, .ops-check-row h3 { font-size: 1.0625rem; }
.ops-controls input, .ops-controls select, .ops-check-toolbar select,
.ops-count-inputs input, .ops-count-inputs select, .ops-check-row select { font-size: 1rem; }
.ops-nav a { text-decoration: none; min-height: 44px; display: inline-flex; align-items: center; }
.ops-grid, .ops-three, .ops-pref-grid, .ops-record-columns, .ops-timeline,
.condition-grid, .guide-grid { grid-auto-rows: auto; }
.ops-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.ops-check-row { grid-template-columns: minmax(0, 1fr) max(145px, 9rem); }
.ops-check-row label { min-width: 0; }
.ops-check-toolbar { position: static; }
.ops-pref-grid header { flex-wrap: wrap; }

/* Simulator: labels and inputs stay readable alongside detailed descriptions. */
.fee-hero > div > p:not(.eyebrow), .fee-card-heading p, .fee-check,
.fee-formula, .fee-table, .fee-comparison > p:not(.fee-hint),
.fee-comparison > ul, .fee-comparison details ul, .fee-scope p,
.fee-conditions, .fee-adjustments p { font-size: 1rem; }
.fee-field > span, .fee-button, .fee-detail summary, .fee-day > summary,
.fee-tabs button, .fee-comparison details summary, .fee-comparison-load,
.fee-comparison h3, .fee-summary > div, .fee-result-label, .fee-scope a,
.fee-table th, .fee-status, .fee-final-check > span { font-size: .875rem; }
.fee-field input, .fee-field select { font-size: 1rem; }
.fee-field small, .fee-check small, .fee-hint, .fee-row-remove,
.fee-result-label small, .fee-insurance-part, .fee-summary small,
.fee-result-heading > span:last-child, .fee-version, .fee-context span,
.fee-table small, .fee-notes, .fee-hero-note p span,
.fee-mobile-result small { font-size: .75rem; }
.fee-intro-note, .fee-result-note { font-size: .875rem; }
.fee-button, .fee-comparison-load { min-height: 44px; }
.fee-day > summary { flex-wrap: wrap; }
.fee-day > summary span { flex: 0 0 auto; }
.fee-day > summary small { font-size: .75rem; }
.fee-workspace > *, .fee-summary > div > span { min-width: 0; }
.fee-summary > div { flex-wrap: wrap; }
.fee-shell .fee-fields, .fee-shell .fee-visit-fields { grid-template-columns: repeat(2, minmax(0, 1fr)); }

@media (max-width: 1100px) {
  .header .desktop-nav { display: none; }
  .header .mobile-menu { display: block; flex: 0 0 auto; margin-left: auto; position: relative; font-size: .875rem; }
  .mobile-menu summary { cursor: pointer; list-style: none; padding: 8px 12px; background: var(--pale); border-radius: 7px; color: var(--blue); font-weight: 600; display: flex; align-items: center; white-space: nowrap; }
  .mobile-menu summary::-webkit-details-marker { display: none; }
  .header .mobile-menu nav { display: flex; flex-direction: column; position: absolute; right: 0; top: 50px; padding: 12px 16px; min-width: 230px; max-width: calc(100vw - 44px); background: white; box-shadow: 0 12px 35px #59483b20; border: 1px solid var(--line); border-radius: 12px; z-index: 50; gap: 2px; margin: 0; font-size: .9375rem; }
  .mobile-menu nav a { min-height: 44px; display: flex; align-items: center; }
}
@media (max-width: 1000px) {
  .reading-layout { grid-template-columns: 160px minmax(0, 1fr); }
  .guide-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 800px) {
  .reading-layout { display: block; }
  .tool-feature { display: block; padding: 24px; }
  .tool-feature img { display: none; }
  .tool-feature h2 { font-size: 1.5rem; }
  .tool-feature p { font-size: 1rem; }
  .fee-shell .fee-visit-fields { grid-template-columns: 1fr; }
  .fee-checkboxes { grid-template-columns: 1fr; }
  .fee-table-wrap { overscroll-behavior-x: contain; }
}
@media (max-width: 760px) {
  .guide-hero h1 { font-size: clamp(1.65rem, 7.2vw, 2.5rem); }
  .guide-hero { padding-top: 18px; padding-bottom: 36px; }
  .guide-hero > div > p:not(.eyebrow) { font-size: 1rem; }
  .chapter-nav { gap: 10px 20px; }
  .chapter-nav a { font-size: .875rem; padding: 7px 0; }
  .card-top { flex-wrap: wrap; }
  .article-title h1 { font-size: clamp(1.55rem, 7vw, 1.95rem); }
  .instruction-heading h1 { font-size: clamp(1.55rem, 6.8vw, 2rem); }
  .instruction-heading { gap: 14px; }
  .instruction-heading img { margin-right: 0; }
  .ai-heading { align-items: flex-start; }
  .reading-guide > div { grid-template-columns: 1fr; }
  .instruction-banner { flex-wrap: wrap; gap: 12px; padding: 22px; }
  .instruction-banner > div { flex: 1 1 180px; min-width: 0; }
  .instruction-banner > b { margin-left: 0; }
  .instruction-banner h2 { font-size: clamp(1.125rem, 5.2vw, 1.3125rem); }
  .guide-meta span + span::before { content: none; }
  .library-heading { flex-wrap: wrap; gap: 12px; }
  .guide-recommendations { grid-template-columns: 1fr; }
  .fee-fields { grid-template-columns: 1fr; }
}
@media (max-width: 580px) {
  .ops-grid, .ops-pref-grid, .ops-record-columns { grid-template-columns: 1fr; }
  .ops-check-row { grid-template-columns: 1fr; gap: 14px; }
  .ops-check-row label { grid-template-columns: minmax(0, 1fr) max(145px, 9rem); }
  .ops-timeline { grid-template-columns: 1fr; }
  .ops-hero h1 { font-size: clamp(1.8rem, 8vw, 2.3125rem); }
  .ops-title h1 { font-size: clamp(1.65rem, 7.3vw, 1.9375rem); }
  .ops-hero-art span { font-size: .875rem; }
  .tool-feature { padding: 22px; }
  .tool-feature .text-link { display: block; }
}
@media (max-width: 460px) {
  .header { padding-left: 18px; padding-right: 18px; gap: 12px; }
  .brand { gap: 7px; }
  .brand-name { font-size: 1.125rem; }
  .brand-name small { font-size: .75rem; }
  .brand-mark { width: 37px; height: 37px; }
  .mobile-menu summary { padding: 8px 10px; }
  .guide-grid, .guide-next, .version-grid { grid-template-columns: 1fr; }
  .instruction-heading img { display: none; }
  .fee-shell .fee-fields { grid-template-columns: 1fr; }
  .fee-card-heading { gap: 10px; align-items: flex-start; }
  .fee-card-heading > span { flex: 0 0 auto; }
  .fee-main-amount { flex-wrap: wrap; gap: 4px 10px; }
  .fee-main-amount strong { font-size: clamp(2rem, 10vw, 2.6rem); }
}
@media (max-width: 360px) {
  .brand-name small { display: none; }
}

@media screen { .update-status { margin: 0 0 20px; padding: 16px 20px; border: 1px solid #ead9d5; border-radius: 12px; background: #fcf7f9; color: #6e5048; line-height: 1.8; overflow-wrap: anywhere; } .update-status b { display: block; } }
