/* Every visual change is confined to small screens. Classic is the default. */
.pn2-mobile-feed, .pn2-feed-reader-bar, .pn2-feed-theme-control { display: none; }
@media (max-width: 991.98px) {
    .pn2-feed-theme-control { display: grid; gap: .4rem; margin-block: .7rem; padding: .85rem; border: 1px solid var(--pn-line, #dce3ed); border-radius: 12px; background: var(--pn-surface, #fff); color: var(--pn-ink, #15213a); }
    .pn2-feed-theme-control label { display: grid; gap: .4rem; font-size: .85rem; font-weight: 700; }
    .pn2-feed-theme-control select { width: 100%; min-height: 44px; padding: .55rem; border: 1px solid var(--pn-line, #dce3ed); border-radius: 8px; font: inherit; color: inherit; background: var(--pn-surface, #fff); }
    .pn2-feed-theme-control small { font-size: .75rem; line-height: 1.5; }
    html[data-pn2-mobile-theme="feed"] { --pn2-feed-radius: 18px; }
    html[data-pn2-mobile-theme="feed"] .pn2-shell { background: var(--pn-paper, #f3f5f9); }
    html[data-pn2-mobile-theme="feed"][data-pn2-feed-ready] .body-index-page :is(.pn2-market-pulse, .pn2-dashboard-heading, .pn2-start-banner, .pn2-my-nexus) { display: none !important; }
    html[data-pn2-mobile-theme="feed"][data-pn2-feed-ready] .body-index-page :is(.pn2-dashboard, .pn2-dashboard-grid) { display: block; margin: 0; padding-block: 0; }
    html[data-pn2-mobile-theme="feed"][data-pn2-feed-ready] .body-index-page .pn2-dashboard > .container-fluid { padding-inline: max(12px, env(safe-area-inset-left)) max(12px, env(safe-area-inset-right)); }
    html[data-pn2-mobile-theme="feed"][data-pn2-feed-ready] .body-index-page .pn2-workspace { display: flex; flex-direction: column; gap: 16px; max-width: 680px; margin-inline: auto; }
    html[data-pn2-mobile-theme="feed"][data-pn2-feed-ready] .body-index-page .pn2-workspace > :not(.pn2-mobile-feed):not([data-pn2-feed-ad-visible]) { display: none !important; }
    html[data-pn2-mobile-theme="feed"] .pn2-mobile-feed { display: contents; }
    html[data-pn2-mobile-theme="feed"] .pn2-feed-heading { order: -30; display: flex; align-items: start; justify-content: space-between; gap: 12px; padding-block-start: 22px; color: var(--pn-ink, #15213a); }
    .pn2-feed-heading span { display: block; font-size: .65rem; font-weight: 750; letter-spacing: .12em; color: var(--pn-blue, #3257d5); }
    .pn2-feed-heading h1 { margin: .45rem 0; font-size: clamp(1.5rem, 5.7vw, 2.1rem); line-height: 1.15; letter-spacing: -.035em; }
    .pn2-feed-heading p { margin: .45rem 0 0; font-size: .9rem; color: var(--pn-muted, #52627b); }
    .pn2-feed-heading button { flex: 0 0 auto; padding: .5rem .6rem; font-size: .75rem; white-space: nowrap; }
    html[data-pn2-mobile-theme="feed"] .pn2-feed-tabs { order: -20; display: flex; gap: 8px; align-items: center; padding-block: 4px; }
    .pn2-feed-tabs > :is(a, button) { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: .5rem 1.1rem; border: 1px solid var(--pn-line, #dce3ed); border-radius: 24px; background: var(--pn-surface, #fff); color: var(--pn-ink, #15213a); font: inherit; font-size: .85rem; font-weight: 650; text-decoration: none; }
    .pn2-feed-tabs [aria-pressed="true"] { color: #fff; background: #3257d5; border-color: #3257d5; }
    .pn2-feed-status { order: -10; font-size: .85rem; margin: 0; color: var(--pn-muted, #52627b); }
    .pn2-feed-status:not([data-pn2-feed-empty]) { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; border: 0; overflow: hidden; white-space: nowrap; clip-path: inset(50%); }
    html[data-pn2-mobile-theme="feed"] .pn2-feed-card { order: var(--pn2-feed-order, 10); overflow: hidden; border: 1px solid var(--pn-line, #dce3ed); border-radius: var(--pn2-feed-radius); background: var(--pn-surface, #fff); box-shadow: 0 3px 16px rgb(20 33 61 / 3%); color: var(--pn-ink, #15213a); }
    html[data-pn2-mobile-theme="feed"] .pn2-feed-card[hidden] { display: none !important; }
    .pn2-feed-image { display: block; aspect-ratio: 1.85; overflow: hidden; background: var(--pn-surface, #e5eaf3); }
    .pn2-feed-image img { display: block; width: 100%; height: 100%; object-fit: cover; }
    .pn2-feed-card-copy { padding: 18px; }
    .pn2-feed-meta { display: flex; flex-wrap: wrap; gap: .25rem .7rem; align-items: center; font-size: .7rem; line-height: 1.5; color: var(--pn-muted, #52627b); }
    .pn2-feed-meta > span { font-weight: 750; color: var(--pn-blue, #3257d5); }
    .pn2-feed-card h2 { margin: .65rem 0 .55rem; font-size: clamp(1.2rem, 4.6vw, 1.6rem); line-height: 1.25; letter-spacing: -.02em; overflow-wrap: anywhere; }
    .pn2-feed-card h2 a { color: inherit; text-decoration: none; }
    .pn2-feed-card-copy > p { margin: .5rem 0 1rem; font-size: .94rem; line-height: 1.6; color: var(--pn-muted, #52627b); }
    .pn2-feed-access { font-size: .7rem; font-weight: 700; color: var(--pn-blue, #3257d5); }
    .pn2-feed-actions { display: flex; align-items: center; justify-content: space-between; gap: .7rem; border-block-start: 1px solid var(--pn-line, #dce3ed); margin-block-start: .9rem; padding-block-start: .65rem; }
    .pn2-feed-actions form { margin: 0; }
    .pn2-feed-actions :is(a, button), .pn2-feed-heading button { display: inline-flex; align-items: center; justify-content: center; gap: .6rem; min-height: 44px; border: 1px solid var(--pn-line, #dce3ed); border-radius: 10px; background: var(--pn-surface, #fff); color: var(--pn-ink, #15213a); font: inherit; font-size: .82rem; font-weight: 650; text-decoration: none; }
    .pn2-feed-actions :is(a, button) { padding: .5rem .9rem; }
    .pn2-feed-actions .pn2-feed-read { color: var(--pn-blue, #3257d5); border-color: transparent; padding-inline-start: 0; }
    html[data-pn2-mobile-theme="feed"] [data-pn2-feed-ad="0"] { order: 35; }
    html[data-pn2-mobile-theme="feed"] [data-pn2-feed-ad="1"] { order: 105; }
    html[data-pn2-mobile-theme="feed"] .pn2-feed-more { order: 1000; display: grid; gap: .6rem; padding: 20px; margin-block-end: 18px; border: 1px solid var(--pn-line, #dce3ed); border-radius: var(--pn2-feed-radius); background: var(--pn-surface, #fff); text-align: center; }
    .pn2-feed-more p { margin: 0; color: var(--pn-muted, #52627b); }
    .pn2-feed-more a { display: inline-grid; min-height: 44px; align-items: center; font-weight: 650; color: var(--pn-blue, #3257d5); }
    html[data-pn2-mobile-theme="feed"] .pn2-category-page :is(.pn2-category-grid, #postsLoadMoreContent) { display: flex; flex-direction: column; gap: 16px; }
    html[data-pn2-mobile-theme="feed"] #postsLoadMoreContent > .col-sm-6 { width: 100%; }
    html[data-pn2-mobile-theme="feed"] .pn2-category-card { display: block; overflow: hidden; border-radius: var(--pn2-feed-radius); }
    html[data-pn2-mobile-theme="feed"] .pn2-category-card > a > img { width: 100%; height: auto; aspect-ratio: 1.85; object-fit: cover; }
    html[data-pn2-mobile-theme="feed"] .pn2-category-card h2 { font-size: 1.35rem; line-height: 1.3; }
    html[data-pn2-mobile-theme="feed"] .pn2-feed-reader-bar { display: flex; position: relative; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: .4rem .7rem; margin: 0 0 16px; padding: .5rem .7rem .7rem; border: 1px solid var(--pn-line, #dce3ed); border-radius: 12px; background: var(--pn-surface, #fff); }
    .pn2-feed-reader-bar > div:not(.pn2-feed-reader-progress) { display: flex; gap: .8rem; }
    .pn2-feed-reader-bar a { display: inline-flex; align-items: center; min-height: 44px; font-size: .8rem; font-weight: 650; color: var(--pn-blue, #3257d5); text-decoration: none; }
    .pn2-feed-reader-progress { position: absolute; inset-inline: 10px; bottom: 0; height: 3px; overflow: hidden; border-radius: 3px; background: var(--pn-line, #dce3ed); }
    .pn2-feed-reader-progress span { display: block; width: 100%; height: 100%; background: var(--pn-blue, #3257d5); transform: scaleX(0); transform-origin: left; }
    [dir="rtl"] .pn2-feed-reader-progress span { transform-origin: right; }
    html[data-pn2-mobile-theme="feed"] .pn2-reading-header h1 { font-size: clamp(1.65rem, 6.5vw, 2.4rem); line-height: 1.16; letter-spacing: -.025em; }
    html[data-pn2-mobile-theme="feed"] .pn2-reading-article { min-width: 0; }
    html[data-pn2-mobile-theme="feed"] .pn2-reading-byline { gap: .35rem .7rem; font-size: .75rem; }
    html[data-pn2-mobile-theme="feed"] .pn2-reading-tools { flex-wrap: wrap; gap: .45rem; }
    :is(.pn2-feed-card, .pn2-feed-tabs, .pn2-feed-heading, .pn2-feed-more, .pn2-feed-reader-bar, .pn2-feed-theme-control) :is(a, button, select):focus-visible { outline: 3px solid var(--pn-blue, #3257d5); outline-offset: 3px; }
    [data-bs-theme="dark"] .pn2-feed-theme-control, [data-bs-theme="dark"] .pn2-feed-card, [data-bs-theme="dark"] .pn2-feed-more, [data-bs-theme="dark"] .pn2-feed-reader-bar { color-scheme: dark; }
}
