/* ============================================================
   AKJ PaisaGyan - Feature styles (market strip, money tools, calculator toolbar,
   listen/voice controls, article mini-calculator, print).
   Loaded after mobile-app.css by layouts/main.php. Sections:
     1 Market strip   2 Money tools   3 Calculator toolbar   4 Listen (TTS) + voice search
     5 Pull-to-refresh   6 Article mini-calculator & CTA   7 Compare picker   8 Print
   ============================================================ */

/* ---- 1. Market strip ---- */
.mkt-strip-wrap { background: var(--body-bg, #fff); border-bottom: 1px solid var(--border, #e2e8f0); }
.mkt-strip { display: flex; align-items: center; gap: 14px; padding: 8px 0; min-height: 52px; }
.mkt-head { display: flex; align-items: center; gap: 8px; flex: 0 0 auto; text-decoration: none; color: var(--text); }
.mkt-title { font-weight: 700; font-size: .9rem; white-space: nowrap; }
.mkt-sub { font-size: .72rem; color: var(--text-muted); white-space: nowrap; }
.mkt-dot { width: 9px; height: 9px; border-radius: 50%; background: #94a3b8; flex: 0 0 auto; }
.mkt-dot[data-open="1"] { background: #16a34a; box-shadow: 0 0 0 0 rgba(22,163,74,.55); animation: mktPulse 1.8s infinite; }
@keyframes mktPulse { 70% { box-shadow: 0 0 0 7px rgba(22,163,74,0); } 100% { box-shadow: 0 0 0 0 rgba(22,163,74,0); } }
.mkt-items { display: flex; gap: 8px; overflow-x: auto; flex: 1 1 auto; min-width: 0; scrollbar-width: none; scroll-snap-type: x proximity; padding: 2px 0; }
.mkt-items::-webkit-scrollbar { display: none; }
.mkt-item { flex: 0 0 auto; display: flex; flex-direction: column; padding: 4px 12px; border: 1px solid var(--border, #e2e8f0); border-radius: 10px; scroll-snap-align: start; line-height: 1.25; min-width: 118px; }
.mkt-label { font-size: .68rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: .02em; }
.mkt-price { font-weight: 700; font-size: .92rem; font-variant-numeric: tabular-nums; }
.mkt-chg { font-size: .72rem; font-weight: 600; font-variant-numeric: tabular-nums; }
.mkt-chg.up { color: #16a34a; } .mkt-chg.down { color: #dc2626; }
.mkt-more { flex: 0 0 auto; font-size: .8rem; font-weight: 600; text-decoration: none; white-space: nowrap; }
@media (max-width: 767.98px) {
    .mkt-strip { flex-wrap: wrap; gap: 6px 10px; padding: 8px 0 6px; }
    .mkt-head { width: 100%; }
    .mkt-items { width: 100%; flex-basis: 100%; }
    .mkt-more { display: none; }
}

/* ---- 1b. Home: open IPO boxes ---- */
.ipo-home { background: var(--body-bg, #fff); border-bottom: 1px solid var(--border, #e2e8f0); padding: 12px 0 8px; }
.ipo-home-head { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px 12px; margin-bottom: 10px; }
.ipo-home-title { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: .95rem; }
.ipo-home-dot { width: 9px; height: 9px; border-radius: 50%; background: #16a34a; box-shadow: 0 0 0 0 rgba(22,163,74,.55); animation: mktPulse 1.8s infinite; flex: 0 0 auto; }
.ipo-home-btns { display: flex; gap: 8px; flex-wrap: wrap; }
.ipo-mini-row { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; padding: 2px 0 8px; }
.ipo-mini { --c: #16a34a; --bg: rgba(22,163,74,.09); display: flex; flex-direction: column; gap: 4px; min-width: 0; padding: 9px 12px; background: var(--bg); border: 1px solid color-mix(in srgb, var(--c) 28%, transparent); border-left: 4px solid var(--c); border-radius: 12px; text-decoration: none; color: var(--text); transition: box-shadow .15s, transform .15s; }
.ipo-mini:hover { box-shadow: 0 4px 14px color-mix(in srgb, var(--c) 28%, transparent); transform: translateY(-1px); color: var(--text); }
/* a different colour for each box (cycles every 8) */
.ipo-mini:nth-child(8n+1) { --c: #16a34a; --bg: rgba(22,163,74,.09); }
.ipo-mini:nth-child(8n+2) { --c: #2563eb; --bg: rgba(37,99,235,.09); }
.ipo-mini:nth-child(8n+3) { --c: #9333ea; --bg: rgba(147,51,234,.09); }
.ipo-mini:nth-child(8n+4) { --c: #ea580c; --bg: rgba(234,88,12,.09); }
.ipo-mini:nth-child(8n+5) { --c: #0d9488; --bg: rgba(13,148,136,.09); }
.ipo-mini:nth-child(8n+6) { --c: #db2777; --bg: rgba(219,39,119,.09); }
.ipo-mini:nth-child(8n+7) { --c: #ca8a04; --bg: rgba(202,138,4,.10); }
.ipo-mini:nth-child(8n+8) { --c: #4f46e5; --bg: rgba(79,70,229,.09); }
.ipo-mini-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 6px; min-width: 0; }
.ipo-mini-name { font-weight: 700; font-size: .86rem; line-height: 1.25; min-width: 0; overflow-wrap: anywhere; }
.ipo-mini-tag { flex: 0 0 auto; font-size: .62rem; font-weight: 700; padding: 1px 6px; border-radius: 999px; background: color-mix(in srgb, var(--c) 16%, transparent); color: var(--c); filter: brightness(.85); }
.ipo-mini-price { font-weight: 700; font-size: .92rem; font-variant-numeric: tabular-nums; }
.ipo-mini-price small { font-weight: 500; color: var(--text-muted); font-size: .72rem; }
.ipo-mini-foot { display: flex; align-items: center; justify-content: space-between; gap: 6px; font-size: .72rem; }
.ipo-mini-close { color: var(--text-muted); }
.ipo-mini-close.hot { color: #dc2626; font-weight: 700; }
.ipo-mini-sub { font-weight: 700; color: var(--c); filter: brightness(.85); font-variant-numeric: tabular-nums; }
.ipo-mini-empty { font-size: .85rem; color: var(--text-muted); padding: 6px 0 10px; grid-column: 1 / -1; }
.ipo-home-note { font-size: .68rem; color: var(--text-muted); padding-bottom: 4px; }
@media (max-width: 991.98px) { .ipo-mini-row { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 575.98px) { .ipo-mini-row { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; } .ipo-mini { padding: 8px 10px; } .ipo-home-btns { width: 100%; } .ipo-home-btns .btn { flex: 1 1 0; } }
@media (prefers-reduced-motion: reduce) { .ipo-home-dot { animation: none; } .ipo-mini { transition: none; } }

/* ---- 1c. Animated-gradient "IPO Calendar" button on the IPO learning pages ---- */
.ipo-cta-wrap { margin: 4px 0 18px; }
.ipo-cta-wrap.ipo-cta-end { margin: 22px 0 6px; }
.ipo-cta-wrap.ipo-cta-side { margin: 16px 0 0; }
.ipo-cta-side .ipo-cta-btn { padding: 12px 14px; gap: 10px; }
.ipo-cta-side .ipo-cta-txt strong { font-size: .92rem; }
.ipo-cta-side .ipo-cta-ico { width: 38px; height: 38px; font-size: 1.15rem; }
.ipo-cta-side .ipo-cta-arrow { font-size: 1.3rem; }
.ipo-cta-btn { position: relative; display: flex; align-items: center; gap: 14px; overflow: hidden; padding: 13px 18px; border-radius: 16px; text-decoration: none; color: #fff;
    background: linear-gradient(115deg, #2563eb, #7c3aed, #db2777, #f59e0b, #16a34a, #2563eb); background-size: 300% 300%; animation: ipoCtaFlow 7s ease infinite;
    box-shadow: 0 8px 22px rgba(124,58,237,.30); transition: transform .18s, box-shadow .18s; }
.ipo-cta-btn:hover { color: #fff; transform: translateY(-2px); box-shadow: 0 12px 28px rgba(219,39,119,.38); }
.ipo-cta-btn::after { content: ""; position: absolute; top: 0; bottom: 0; width: 38%; left: -45%; background: linear-gradient(100deg, transparent, rgba(255,255,255,.38), transparent); transform: skewX(-18deg); animation: ipoCtaShine 3.4s ease-in-out infinite; pointer-events: none; }
.ipo-cta-ico { flex: 0 0 auto; width: 42px; height: 42px; border-radius: 12px; background: rgba(255,255,255,.22); display: inline-flex; align-items: center; justify-content: center; font-size: 1.3rem; animation: ipoCtaBob 2.4s ease-in-out infinite; }
.ipo-cta-txt { display: flex; flex-direction: column; min-width: 0; line-height: 1.25; }
.ipo-cta-txt strong { font-size: 1rem; font-weight: 800; }
.ipo-cta-txt small { font-size: .78rem; opacity: .92; }
.ipo-cta-arrow { margin-left: auto; font-size: 1.5rem; flex: 0 0 auto; transition: transform .18s; }
.ipo-cta-btn:hover .ipo-cta-arrow { transform: translateX(4px); }
@keyframes ipoCtaFlow { 0% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } 100% { background-position: 0% 50%; } }
@keyframes ipoCtaShine { 0% { left: -45%; } 55%, 100% { left: 125%; } }
@keyframes ipoCtaBob { 0%, 100% { transform: translateY(0) rotate(0); } 50% { transform: translateY(-3px) rotate(-6deg); } }
@media (max-width: 575.98px) { .ipo-cta-btn { padding: 11px 13px; gap: 10px; } .ipo-cta-txt strong { font-size: .92rem; } .ipo-cta-ico { width: 36px; height: 36px; font-size: 1.1rem; } }
@media (prefers-reduced-motion: reduce) { .ipo-cta-btn, .ipo-cta-btn::after, .ipo-cta-ico { animation: none; } }
/* Compact animated-gradient button (home "Open IPOs" strip) */
.ipo-grad-btn { position: relative; overflow: hidden; color: #fff; border: 0; font-weight: 700; border-radius: 10px; padding: 6px 14px;
    background: linear-gradient(115deg, #2563eb, #7c3aed, #db2777, #f59e0b, #16a34a, #2563eb); background-size: 300% 300%; animation: ipoCtaFlow 7s ease infinite;
    box-shadow: 0 4px 14px rgba(124,58,237,.30); transition: transform .18s, box-shadow .18s; }
.ipo-grad-btn:hover, .ipo-grad-btn:focus { color: #fff; transform: translateY(-2px); box-shadow: 0 8px 20px rgba(219,39,119,.38); }
.ipo-grad-btn::after { content: ""; position: absolute; top: 0; bottom: 0; width: 38%; left: -45%; background: linear-gradient(100deg, transparent, rgba(255,255,255,.4), transparent); transform: skewX(-18deg); animation: ipoCtaShine 3.4s ease-in-out infinite; pointer-events: none; }
.ipo-grad-btn .bi { display: inline-block; animation: ipoCtaBob 2.4s ease-in-out infinite; }
@media (prefers-reduced-motion: reduce) { .ipo-grad-btn, .ipo-grad-btn::after, .ipo-grad-btn .bi { animation: none; } }

/* ---- 2. Money tools (dashboard) ---- */
.money-tabs { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
.money-tabs::-webkit-scrollbar { display: none; }
.money-tab { flex: 0 0 auto; padding: 7px 14px; border-radius: 999px; border: 1px solid var(--border, #e2e8f0); text-decoration: none; color: var(--text); font-size: .88rem; font-weight: 600; white-space: nowrap; }
.money-tab:hover { border-color: #0d6efd; color: #0d6efd; }
.money-tab.active { background: #0d6efd; border-color: #0d6efd; color: #fff; }
.money-ico { width: 36px; height: 36px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; flex: 0 0 auto; }
.money-ico.exp { background: rgba(13,110,253,.12); color: #0d6efd; }
.money-ico.inc { background: rgba(25,135,84,.14); color: #198754; }
.min-w-0 { min-width: 0; }
/* quick-add sheet (mobile menu) */
.qa-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.qa-chip { border: 1px solid var(--border, #e2e8f0); background: transparent; color: var(--text); border-radius: 999px; padding: 6px 12px; font-size: .85rem; }
.qa-chip.on { background: #0d6efd; border-color: #0d6efd; color: #fff; }
.qa-msg { min-height: 1.3em; font-size: .85rem; margin-top: 8px; }

/* ============================================================
   3. Calculator toolbar (Save / Share image / Print) + print styles
   ============================================================ */
.calc-toolbar { display:flex; flex-wrap:wrap; gap:.5rem; align-items:center; margin-bottom:.75rem; }
.calc-toolbar .calc-save-title { flex:1 1 200px; max-width:320px; min-width:0; }
.calc-toolbar .btn { white-space:nowrap; }
.calc-disclaimer { line-height:1.5; }
.calc-toast { position:fixed; left:50%; bottom:88px; transform:translateX(-50%); background:#198754; color:#fff; padding:.55rem 1rem; border-radius:999px; font-size:.9rem; z-index:2000; box-shadow:0 4px 16px rgba(0,0,0,.25); max-width:90vw; text-align:center; }
.calc-toast.err { background:#dc3545; }
@media (max-width:575.98px) {
    .calc-toolbar .calc-save-title { flex-basis:100%; max-width:none; }
    .calc-toolbar .btn { flex:1 1 auto; }
}
@media print {
    .no-print, .calc-toolbar, header, nav.navbar, .navbar, footer, .site-footer, .mobile-bottom-nav, .akj-bottom-nav,
    #calc-history, .faq-hero-section nav, .market-strip, .calc-related, #ck-extra .btn, .btn, .form-range { display:none !important; }
    body { background:#fff !important; color:#000 !important; }
    .faq-hero-section { background:none !important; padding:0 0 .5rem !important; }
    .faq-hero-section h1, .faq-hero-section p { color:#000 !important; }
    .card { box-shadow:none !important; border:1px solid #bbb !important; break-inside:avoid; }
    .container { max-width:100% !important; }
    a[href]:after { content:none !important; }
    .calc-disclaimer, .alert { display:block !important; border:1px solid #999 !important; background:#fff !important; color:#000 !important; }
}

/* ============================================================
   4. Mobile / desktop polish: pull-to-refresh, listen + mic, mini-calculator, cheat-sheet print
   ============================================================ */
.akj-ptr { position:fixed; top:0; left:50%; transform:translate(-50%,-40px); width:40px; height:40px; border-radius:50%; background:#fff; color:#6b2fa0; box-shadow:0 2px 10px rgba(0,0,0,.25); display:flex; align-items:center; justify-content:center; font-size:1.2rem; opacity:0; z-index:3000; pointer-events:none; }
.akj-ptr.ready { color:#198754; }
.akj-ptr.spin i { animation:akj-spin .7s linear infinite; }
@keyframes akj-spin { to { transform:rotate(360deg); } }
.btn-listen { display:inline-flex; align-items:center; justify-content:center; align-self:flex-start; width:fit-content; max-width:100%; min-height:40px; padding:.4rem 1.05rem; border:1px solid rgba(13,110,253,.35); border-radius:999px; background:rgba(13,110,253,.10); background:color-mix(in srgb, var(--bs-primary,#0d6efd) 11%, transparent); color:var(--bs-primary,#0d6efd); font-size:.92rem; font-weight:700; line-height:1.2; cursor:pointer; transition:background .15s, box-shadow .15s, transform .15s; }
.btn-listen > .bi { font-size:1.1rem; }
.btn-listen:hover, .btn-listen:focus-visible { background:rgba(13,110,253,.18); box-shadow:0 4px 12px -6px rgba(13,110,253,.6); outline:none; }
@media (max-width: 767.98px) { .btn-listen { min-height:44px; padding:.5rem 1.15rem; } }
.btn-listen[aria-pressed="true"] { background:var(--bs-primary,#0d6efd); border-color:var(--bs-primary,#0d6efd); color:#fff; }
/* paragraph being read aloud + floating Stop pill (assets/js/extras.js) */
.listen-current { background:rgba(250,204,21,.26); box-shadow:0 0 0 5px rgba(250,204,21,.26); border-radius:6px; transition:background .2s, box-shadow .2s; }
.listen-float { position:fixed; left:12px; bottom:20px; z-index:1500; display:inline-flex; align-items:center; min-height:44px; padding:.5rem 1.15rem; border:0; border-radius:999px; background:#0d6efd; color:#fff; font-weight:700; font-size:.92rem; box-shadow:0 8px 22px -6px rgba(13,110,253,.65); }
.listen-float[hidden] { display:none; }
@media (max-width: 991.98px) { .listen-float { bottom:78px; } }
@media print { .listen-float { display:none !important; } .listen-current { background:none; box-shadow:none; } }
.akj-mic { border:0; background:transparent; color:inherit; opacity:.7; padding:0 .55rem; font-size:1.05rem; line-height:1; flex:0 0 auto; }
.akj-mic.listening { color:#dc3545; opacity:1; animation:akj-pulse 1s ease-in-out infinite; }
@keyframes akj-pulse { 50% { transform:scale(1.25); } }
.akj-search-form .akj-mic { align-self:center; }
.akj-mic-note { max-width:520px; margin:.5rem auto 0; padding:.5rem .8rem; border-radius:10px; background:#fff3cd; color:#664d03; font-size:.85rem; line-height:1.4; text-align:left; border:1px solid #ffe69c; }
.akj-mic-note[hidden] { display:none; }
.mini-calc .form-control-sm { font-size:.85rem; }
@media (prefers-reduced-motion: reduce) { .akj-mic.listening, .akj-ptr.spin i { animation:none; } }
@media print {
    body.cheat-sheet-page .container > .row > aside, .cs-print-hide, .btn-listen, .akj-mic { display:none !important; }
    .cs-print-img { max-width:100% !important; height:auto !important; page-break-inside:avoid; }
}

/* Header Tools / Quick Links dropdowns: two columns on desktop (long single column) */
@media (min-width: 992px) {
    .dropdown-menu.dropdown-2col.show { display: block; column-count: 2; column-gap: 0; min-width: 480px !important; padding: 8px; }
    .dropdown-menu.dropdown-2col > li { break-inside: avoid; page-break-inside: avoid; }
    .dropdown-menu.dropdown-2col .dropdown-item { white-space: nowrap; border-radius: 8px; }
}

/* Home: "Mutual Funds" strip under the Open IPOs boxes (only when the funds module is on). Its own tinted band + icon cards,
   deliberately unlike the IPO strip's pill buttons. */
.funds-home { background: linear-gradient(90deg, rgba(37,99,235,.06), rgba(22,163,74,.06)); border-top: 1px solid var(--border, #e2e8f0); border-bottom: 1px solid var(--border, #e2e8f0); padding: 26px 0 28px; margin-top: 28px; }
.funds-home-head { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: 1.05rem; margin-bottom: 14px; }
.funds-home-head .bi { color: #2563eb; }
.funds-home-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.funds-home-card { display: flex; align-items: center; gap: 14px; padding: 12px 14px; border-radius: 14px; background: var(--card-bg, #fff); border: 1px solid var(--border, #e2e8f0); color: var(--text, #0f172a); text-decoration: none; box-shadow: 0 2px 10px rgba(15,23,42,.05); transition: transform .18s, box-shadow .18s, border-color .18s; min-width: 0; }
.funds-home-card:hover, .funds-home-card:focus { transform: translateY(-2px); box-shadow: 0 8px 22px rgba(15,23,42,.10); border-color: #2563eb; color: var(--text, #0f172a); }
.funds-home-ico { width: 46px; height: 46px; border-radius: 12px; display: inline-flex; align-items: center; justify-content: center; font-size: 1.3rem; flex: 0 0 auto; color: #fff; }
.funds-home-ico.fx-blue { background: linear-gradient(135deg, #2563eb, #4f46e5); }
.funds-home-ico.fx-green { background: linear-gradient(135deg, #0f766e, #16a34a); }
.funds-home-txt { display: flex; flex-direction: column; min-width: 0; flex: 1 1 auto; }
.funds-home-t { font-weight: 800; font-size: 1rem; line-height: 1.2; }
.funds-home-s { font-size: .76rem; color: var(--text-muted, #64748b); margin-top: 3px; line-height: 1.35; }
.funds-home-arrow { font-size: 1.6rem; color: #2563eb; flex: 0 0 auto; transition: transform .18s; }
.funds-home-card:hover .funds-home-arrow { transform: translateX(4px); }
@media (max-width: 767.98px) { .funds-home { padding: 18px 0 20px; margin-top: 18px; } .funds-home-row { grid-template-columns: 1fr; gap: 8px; } .funds-home-card { padding: 10px 12px; gap: 10px; } .funds-home-ico { width: 40px; height: 40px; font-size: 1.1rem; } }

/* Footer: quick tool buttons under "Subscribe on YouTube" (Calculators / IPO Calendar / Mutual Fund Explorer) */
.footer-tools { display: flex; flex-wrap: wrap; gap: 8px; }
.footer-tool-btn { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 999px; font-size: .8rem; font-weight: 600; color: rgba(255,255,255,.85); background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.18); text-decoration: none; white-space: nowrap; transition: background .15s, border-color .15s, color .15s, transform .15s; }
.footer-tool-btn:hover, .footer-tool-btn:focus { color: #fff; background: rgba(13,110,253,.35); border-color: rgba(13,110,253,.7); transform: translateY(-1px); }
.footer-tool-btn .bi { font-size: .95em; }

/* FAQ deep links (5 Oct 2026): per-question anchor + copy-link button, "questions on this page" list */
.faq-accordion .accordion-item { scroll-margin-top: 90px; }
.faq-accordion .accordion-header { position: relative; }
.faq-accordion .accordion-button { padding-right: 3.4rem; }
.faq-accordion .faq-anchor { position: absolute; right: .55rem; top: 50%; transform: translateY(-50%); z-index: 5; width: 34px; height: 34px; display: inline-flex; align-items: center; justify-content: center; border: 0; border-radius: 50%; background: transparent; color: var(--text-muted, #6c757d); font-size: 1.15rem; opacity: .6; cursor: pointer; transition: opacity .15s, background .15s, color .15s; }
.faq-accordion .faq-anchor:hover, .faq-accordion .faq-anchor:focus-visible { opacity: 1; background: rgba(13,110,253,.12); color: #0d6efd; outline: none; }
.faq-accordion .faq-anchor.copied { opacity: 1; color: #059669; background: rgba(5,150,105,.14); }
.faq-toc { border: 1px solid var(--border, #e2e8f0); border-radius: 14px; padding: 4px 16px; background: rgba(13,110,253,.04); }
.faq-toc summary { cursor: pointer; font-weight: 700; padding: 10px 0; }
.faq-toc ol { padding-left: 1.2rem; font-size: 14.5px; line-height: 1.6; }
.faq-toc li { margin-bottom: 6px; }
.faq-toc a { text-decoration: none; color: inherit; }
.faq-toc a:hover { text-decoration: underline; }

/* FAQ search (5 Oct 2026): sticky pill search with live results, status line, English-anchor items */
.faq-search-bar { position: sticky; top: 56px; z-index: 100; padding: 10px 0; background: var(--body-bg, #fff); border-bottom: 1px solid var(--border, #e2e8f0); box-shadow: 0 8px 20px -14px rgba(15,23,42,.45); }
.faq-search-form { display: flex; align-items: center; gap: 10px; margin: 0; }
.faq-search-box { flex: 1 1 auto; min-width: 0; display: flex; align-items: center; gap: 10px; height: 50px; margin: 0; padding: 0 8px 0 18px; border-radius: 999px; border: 2px solid var(--border, #e2e8f0); background: var(--body-bg, #fff); cursor: text; transition: border-color .15s, box-shadow .15s; }
.faq-search-box:hover { border-color: rgba(37,99,235,.45); }
.faq-search-box:focus-within { border-color: #2563eb; box-shadow: 0 0 0 4px rgba(37,99,235,.16); }
.faq-search-ico { color: #2563eb; font-size: 1.1rem; flex: 0 0 auto; }
.faq-search-box input { flex: 1 1 auto; min-width: 0; height: 100%; border: 0; outline: 0; background: transparent; color: var(--text, #0f172a); font-size: 1rem; padding: 0; box-shadow: none; }
.faq-search-box input::placeholder { color: var(--text-muted, #64748b); opacity: .85; }
.faq-search-box input::-webkit-search-cancel-button, .faq-search-box input::-webkit-search-decoration { -webkit-appearance: none; appearance: none; display: none; }
.faq-search-kbd { flex: 0 0 auto; margin-right: 6px; padding: 1px 8px; font: 600 .78rem/1.5 inherit; color: var(--text-muted, #64748b); background: rgba(100,116,139,.12); border: 1px solid var(--border, #e2e8f0); border-bottom-width: 2px; border-radius: 6px; }
.faq-search-box:focus-within .faq-search-kbd, .faq-search-box:has(input:not(:placeholder-shown)) .faq-search-kbd { display: none; }
@media (hover: none), (max-width: 767.98px) { .faq-search-kbd { display: none; } }
.faq-search-clear { flex: 0 0 auto; width: 34px; height: 34px; display: inline-flex; align-items: center; justify-content: center; border: 0; border-radius: 50%; background: rgba(100,116,139,.14); color: var(--text-muted, #64748b); font-size: .8rem; cursor: pointer; transition: background .15s, color .15s; }
.faq-search-clear:hover, .faq-search-clear:focus-visible { background: rgba(220,38,38,.14); color: #dc2626; outline: none; }
.faq-search-clear[hidden], .faq-search-spin[hidden] { display: none; }
.faq-search-spin { flex: 0 0 auto; width: 18px; height: 18px; border-radius: 50%; border: 2px solid rgba(37,99,235,.25); border-top-color: #2563eb; animation: faq-spin .7s linear infinite; }
@keyframes faq-spin { to { transform: rotate(360deg); } }
.faq-search-go { flex: 0 0 auto; align-items: center; justify-content: center; height: 50px; padding: 0 26px; border: 0; border-radius: 999px; font-weight: 700; color: #fff; background: linear-gradient(135deg, #2563eb, #7c3aed); box-shadow: 0 6px 16px -8px rgba(37,99,235,.7); cursor: pointer; transition: transform .15s, box-shadow .15s; }
.faq-search-go:hover { transform: translateY(-1px); box-shadow: 0 10px 20px -10px rgba(37,99,235,.8); }
.faq-search-topics { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 6px; height: 50px; padding: 0 18px; border-radius: 999px; border: 2px solid var(--border, #e2e8f0); color: var(--text, #0f172a); font-weight: 600; font-size: .9rem; text-decoration: none; white-space: nowrap; transition: border-color .15s, background .15s; }
.faq-search-topics:hover { border-color: #2563eb; background: rgba(37,99,235,.06); color: #2563eb; }
@media (max-width: 575.98px) { .faq-search-bar { padding: 8px 0; } .faq-search-box { height: 46px; padding-left: 14px; } .faq-search-topics { width: 46px; height: 46px; padding: 0; justify-content: center; } .faq-search-box input { font-size: .95rem; } }
.faq-status { margin-bottom: 16px; padding: 10px 14px; border-radius: 12px; background: rgba(37,99,235,.07); border: 1px solid rgba(37,99,235,.18); font-size: .9rem; }
.faq-status[hidden], #faqEmpty[hidden], #faqRelaxed[hidden], .faq-accordion .accordion-item[hidden], .faq-accordion[hidden], [data-faq-nav][hidden] { display: none !important; }
.faq-status-main { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.faq-status-main > .bi { color: #2563eb; }
.faq-status-reset { margin-left: auto; font-weight: 600; text-decoration: none; white-space: nowrap; }
.faq-status-reset:hover { text-decoration: underline; }
.faq-status-note { margin-top: 6px; font-size: .8rem; color: var(--text-muted, #64748b); }

/* ============================================================
   Pros & Cons long-form page (5 Oct 2026): hero chips, "at a glance", toolbar, numbered point cards
   ============================================================ */
.pcx-meta { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.pcx-chip { display: inline-flex; align-items: center; gap: 6px; padding: 5px 12px; border-radius: 999px; font-size: .82rem; font-weight: 600; color: rgba(255,255,255,.92); background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.22); }
.pcx-chip-pro { background: rgba(34,197,94,.22); border-color: rgba(134,239,172,.5); }
.pcx-chip-con { background: rgba(248,113,113,.22); border-color: rgba(252,165,165,.5); }

/* at a glance */
.pcx-glance { margin-bottom: 18px; padding: 16px; border-radius: 18px; border: 1px solid var(--border, #e2e8f0); background: rgba(100,116,139,.05); }
.pcx-glance-title { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; font-weight: 800; font-size: 1.02rem; }
.pcx-glance-col { height: 100%; padding: 12px 14px; border-radius: 14px; border: 1px solid transparent; }
.pcx-glance-pro { background: rgba(22,163,74,.08); border-color: rgba(22,163,74,.28); }
.pcx-glance-con { background: rgba(220,38,38,.07); border-color: rgba(220,38,38,.26); }
.pcx-glance-head { display: flex; align-items: center; gap: 7px; margin-bottom: 8px; font-weight: 800; font-size: .95rem; }
.pcx-glance-pro .pcx-glance-head { color: #15803d; }
.pcx-glance-con .pcx-glance-head { color: #b91c1c; }
.pcx-glance ol { margin: 0; padding-left: 1.25rem; font-size: .86rem; line-height: 1.5; }
.pcx-glance li { margin-bottom: 5px; padding-left: 2px; }
.pcx-glance li::marker { font-weight: 700; color: var(--text-muted, #64748b); }
.pcx-glance a { color: inherit; text-decoration: none; }
.pcx-glance a:hover { text-decoration: underline; }

/* toolbar */
.pcx-toolbar { position: sticky; top: 56px; z-index: 90; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; margin: 0 0 18px; padding: 10px 0; background: var(--body-bg, #fff); border-bottom: 1px solid var(--border, #e2e8f0); }
.pcx-seg { display: inline-flex; padding: 4px; gap: 4px; border-radius: 999px; background: rgba(100,116,139,.12); max-width: 100%; }
.pcx-seg-btn { display: inline-flex; align-items: center; gap: 6px; border: 0; background: transparent; color: var(--text, #0f172a); padding: 7px 16px; border-radius: 999px; font-weight: 700; font-size: .9rem; cursor: pointer; white-space: nowrap; transition: background .15s, color .15s, box-shadow .15s; }
.pcx-seg-btn span { padding: 0 7px; border-radius: 999px; background: rgba(100,116,139,.2); font-size: .75rem; }
.pcx-seg-btn.active { background: #2563eb; color: #fff; box-shadow: 0 4px 12px -6px rgba(37,99,235,.7); }
.pcx-seg-btn.active span { background: rgba(255,255,255,.25); }
.pcx-seg-pro.active { background: #16a34a; box-shadow: 0 4px 12px -6px rgba(22,163,74,.7); }
.pcx-seg-con.active { background: #dc2626; box-shadow: 0 4px 12px -6px rgba(220,38,38,.7); }
.pcx-toolbar .btn-listen { margin: 0; }

/* sections + cards */
.pcx-sec { margin-bottom: 30px; }
.pcx-sec[hidden] { display: none; }
.pcx-sec-head { display: flex; align-items: center; gap: 14px; margin-bottom: 14px; padding: 14px 18px; border-radius: 18px; color: #fff; }
.pcx-sec-pro .pcx-sec-head { background: linear-gradient(135deg, #15803d, #22c55e); }
.pcx-sec-con .pcx-sec-head { background: linear-gradient(135deg, #b91c1c, #f87171); }
.pcx-sec-ico { flex: 0 0 auto; width: 44px; height: 44px; display: inline-flex; align-items: center; justify-content: center; border-radius: 14px; background: rgba(255,255,255,.2); font-size: 1.35rem; }
.pcx-sec-title { margin: 0; font-size: 1.25rem; font-weight: 800; line-height: 1.2; color: #fff; }
.pcx-sec-sub { font-size: .8rem; opacity: .9; }
.pcx-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.pcx-card { position: relative; display: flex; gap: 14px; padding: 16px 18px 16px 16px; border-radius: 16px; border: 1px solid var(--border, #e2e8f0); border-left-width: 5px; background: var(--body-bg, #fff); box-shadow: 0 1px 2px rgba(15,23,42,.04); scroll-margin-top: 130px; transition: box-shadow .2s, transform .2s; }
.pcx-card:hover { box-shadow: 0 10px 24px -14px rgba(15,23,42,.35); transform: translateY(-1px); }
.pcx-sec-pro .pcx-card { border-left-color: #16a34a; background: linear-gradient(90deg, rgba(22,163,74,.06), transparent 60%); }
.pcx-sec-con .pcx-card { border-left-color: #dc2626; background: linear-gradient(90deg, rgba(220,38,38,.055), transparent 60%); }
.pcx-num { flex: 0 0 auto; width: 32px; height: 32px; margin-top: 2px; display: inline-flex; align-items: center; justify-content: center; border-radius: 50%; color: #fff; font-weight: 800; font-size: .88rem; }
.pcx-sec-pro .pcx-num { background: #16a34a; }
.pcx-sec-con .pcx-num { background: #dc2626; }
.pcx-card-body { min-width: 0; }
.pcx-h { margin: 0 0 6px; font-size: 1.06rem; font-weight: 800; line-height: 1.4; }
.pcx-b { margin: 0; font-size: 15.5px; line-height: 1.85; color: var(--text, #1e293b); opacity: .94; }
.pcx-b-only { font-size: 1rem; }
.pcx-flash { animation: pcx-flash 1.6s ease-out 1; }
@keyframes pcx-flash { 0%, 35% { box-shadow: 0 0 0 4px rgba(250,204,21,.55); } 100% { box-shadow: 0 0 0 0 rgba(250,204,21,0); } }
@media (max-width: 575.98px) {
  .pcx-glance { padding: 12px; }
  .pcx-sec-head { padding: 12px 14px; }
  .pcx-card { gap: 10px; padding: 14px 12px 14px 12px; }
  .pcx-num { width: 28px; height: 28px; font-size: .8rem; }
  .pcx-b { font-size: 15px; line-height: 1.8; }
  .pcx-toolbar { gap: 8px; }
  .pcx-seg-btn { padding: 7px 12px; }
}
@media print {
  .pcx-toolbar, .pcx-glance { display: none !important; }
  .pcx-sec[hidden] { display: block !important; }
  .pcx-card { break-inside: avoid; box-shadow: none; transform: none; }
  .pcx-sec-head { color: #000; background: none !important; border-bottom: 2px solid #999; border-radius: 0; }
  .pcx-sec-title { color: #000; }
}

/* mobile show / hide */
.pcx-toggle { display: none; margin-left: auto; align-items: center; gap: 6px; padding: 6px 12px; border: 1px solid rgba(255,255,255,.55); border-radius: 999px; background: rgba(255,255,255,.18); color: #fff; font-weight: 700; font-size: .8rem; cursor: pointer; }
.pcx-glance-head { font-family: inherit; width: 100%; display: flex; align-items: center; gap: 7px; border: 0; background: transparent; padding: 0; text-align: left; cursor: default; }
.pcx-gt { display: none; margin-left: auto; align-items: center; gap: 5px; padding: 3px 10px; border-radius: 999px; background: rgba(100,116,139,.14); color: var(--text, #0f172a); font-size: .72rem; font-weight: 700; }
@media (max-width: 767.98px) {
  .pcx-toggle { display: inline-flex; }
  .pcx-gt { display: inline-flex; }
  .pcx-glance-head { cursor: pointer; }
  .pcx-sec-head { cursor: pointer; }
  .pcx-sec.is-collapsed .pcx-list, .pcx-sec.is-collapsed .pc-col-img { display: none; }
  .pcx-sec.is-collapsed .pcx-sec-head { margin-bottom: 0; }
  .pcx-glance-col.is-collapsed ol { display: none; }
  .pcx-glance-col.is-collapsed .pcx-glance-head { margin-bottom: 0; }
}
@media print { .pcx-toggle, .pcx-gt { display: none !important; } .pcx-sec.is-collapsed .pcx-list { display: block !important; } }

/* ============================================================
   Scroll areas (5 Oct 2026): .akj-scroll = good-looking scrollbar (gradient thumb, soft track) + edge shadows that appear
   where there is more to scroll (wrapper + --ft/--fb/--fl/--fr set in assets/js/extras.js) + optional swipe hint.
   ============================================================ */
.akj-scroll { overflow: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; scroll-behavior: smooth; }
.akj-scroll::-webkit-scrollbar { width: 10px; height: 10px; }
.akj-scroll::-webkit-scrollbar-track { background: rgba(100,116,139,.12); border-radius: 999px; margin: 4px; }
.akj-scroll::-webkit-scrollbar-thumb { border-radius: 999px; border: 2px solid transparent; background-clip: padding-box; background-image: linear-gradient(180deg, #3b82f6, #8b5cf6); background-color: #6366f1; min-height: 40px; min-width: 40px; }
.akj-scroll::-webkit-scrollbar-thumb:hover { background-image: linear-gradient(180deg, #2563eb, #7c3aed); }
.akj-scroll::-webkit-scrollbar-corner { background: transparent; }
@supports not selector(::-webkit-scrollbar) { .akj-scroll { scrollbar-width: thin; scrollbar-color: #6366f1 rgba(100,116,139,.15); } }
.akj-scroll-wrap { position: relative; }
.akj-scroll-wrap::before, .akj-scroll-wrap::after { content: ""; position: absolute; inset: 0; pointer-events: none; z-index: 6; border-radius: inherit; }
.akj-scroll-wrap::before {
  background:
    linear-gradient(to bottom, rgba(15,23,42,calc(.22 * var(--ft, 0))), transparent 28px) top / 100% 28px no-repeat,
    linear-gradient(to top, rgba(15,23,42,calc(.22 * var(--fb, 0))), transparent 28px) bottom / 100% 28px no-repeat;
}
.akj-scroll-wrap::after {
  background:
    linear-gradient(to right, rgba(15,23,42,calc(.22 * var(--fl, 0))), transparent 28px) left / 28px 100% no-repeat,
    linear-gradient(to left, rgba(15,23,42,calc(.22 * var(--fr, 0))), transparent 28px) right / 28px 100% no-repeat;
}
.akj-scroll-hint { position: absolute; z-index: 7; left: 50%; bottom: 14px; transform: translateX(-50%); display: inline-flex; align-items: center; gap: 7px; padding: 6px 14px; border-radius: 999px; font-size: .78rem; font-weight: 700; color: #fff; background: linear-gradient(135deg, #3b82f6, #8b5cf6); box-shadow: 0 8px 20px -8px rgba(59,130,246,.8); pointer-events: none; animation: akj-hint 1.8s ease-in-out infinite; }
.akj-scroll-hint[hidden] { display: none; }
@keyframes akj-hint { 0%, 100% { transform: translateX(-50%); } 50% { transform: translateX(calc(-50% + 6px)); } }
@media (min-width: 992px) { .akj-scroll-hint { display: none; } }
@media (prefers-reduced-motion: reduce) { .akj-scroll { scroll-behavior: auto; } .akj-scroll-hint { animation: none; } }
@media print { .akj-scroll-wrap::before, .akj-scroll-wrap::after, .akj-scroll-hint { display: none !important; } .akj-scroll { max-height: none !important; overflow: visible !important; } }

/* copy-link button on each Pros & Cons point */
.pcx-card-body { position: relative; }
.pcx-anchor { position: absolute; top: -4px; right: -6px; width: 32px; height: 32px; display: inline-flex; align-items: center; justify-content: center; border: 0; border-radius: 50%; background: transparent; color: var(--text-muted, #64748b); font-size: 1.1rem; opacity: .55; cursor: pointer; transition: opacity .15s, background .15s, color .15s; }
.pcx-card:hover .pcx-anchor, .pcx-anchor:focus-visible { opacity: 1; }
.pcx-anchor:hover, .pcx-anchor:focus-visible { background: rgba(37,99,235,.12); color: #2563eb; outline: none; }
.pcx-anchor.copied { opacity: 1; color: #16a34a; background: rgba(22,163,74,.14); }
.pcx-card-body .pcx-h { padding-right: 30px; }
@media print { .pcx-anchor { display: none !important; } }

/* ============================================================
   Downloads page v2 (/downloads) -- 5 Oct 2026. Cards, category chips, sort box, "how to use" fold.
   Old .dl-type-icon rule in style.css stays; the rule below only refines it inside .dl-card.
   ============================================================ */
.dl-page .dl-intro { text-align: center; margin: 0 auto 22px; max-width: 760px; }
.dl-page .dl-intro-hi { font-size: 1.12rem; font-weight: 600; }
.dl-page .dl-intro-en { color: #64748b; font-size: .95rem; }
.dl-controls { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 6px; }
.dl-chipbar { display: flex; flex-wrap: wrap; gap: 8px; }
.dl-cat { --dl-c: #6b2fa0; border: 1px solid color-mix(in srgb, var(--dl-c) 35%, #fff); background: color-mix(in srgb, var(--dl-c) 8%, #fff); color: var(--dl-c); border-radius: 99px; padding: 6px 14px; font-weight: 600; font-size: .88rem; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; transition: background .15s, color .15s, transform .12s; }
.dl-cat:hover { transform: translateY(-1px); background: color-mix(in srgb, var(--dl-c) 16%, #fff); }
.dl-cat.is-on { background: var(--dl-c); color: #fff; border-color: var(--dl-c); }
.dl-cat .dl-n { font-size: .74rem; background: rgba(255,255,255,.65); color: #334155; border-radius: 99px; padding: 0 7px; font-weight: 700; }
.dl-cat.is-on .dl-n { background: rgba(255,255,255,.25); color: #fff; }
.dl-sort { display: inline-flex; align-items: center; gap: 8px; font-size: .88rem; font-weight: 600; margin: 0; }
.dl-sort select { min-width: 190px; border-radius: 10px; }
.dl-privacy { margin: 4px 0 26px; }
.dl-sec-title { font-size: 1.3rem; font-weight: 700; display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.dl-sec-title .dl-sec-ic { width: 38px; height: 38px; border-radius: 12px; display: inline-flex; align-items: center; justify-content: center; color: #fff; background: var(--dl-c, #6b2fa0); box-shadow: 0 4px 10px color-mix(in srgb, var(--dl-c, #6b2fa0) 35%, transparent); }
.dl-sec-title .dl-en, .dl-page .dl-en { font-size: .78em; font-weight: 500; color: #64748b; }

.dl-popular .dl-sec-title i { color: #ea580c; }
.dl-card { --dl-c: #6b2fa0; --dl-f: #dc2626; display: flex; flex-direction: column; gap: 10px; background: #fff; border: 1px solid #e5e7eb; border-top: 4px solid var(--dl-c); border-radius: 16px; padding: 16px 16px 14px; box-shadow: 0 3px 12px rgba(15,23,42,.05); transition: transform .15s, box-shadow .15s; }
.dl-card:hover { transform: translateY(-3px); box-shadow: 0 12px 26px rgba(15,23,42,.1); }
.dl-card-top { display: flex; gap: 12px; align-items: flex-start; }
.dl-card .dl-type-icon { width: 46px; height: 46px; flex: 0 0 46px; font-size: 22px; color: var(--dl-f); background: color-mix(in srgb, var(--dl-f) 11%, #fff); border-radius: 12px; }
.dl-title { font-size: .98rem; font-weight: 700; line-height: 1.35; margin: 0 0 6px; }
.dl-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.dl-chip { font-size: .72rem; font-weight: 600; color: #475569; background: #f1f5f9; border-radius: 99px; padding: 1px 9px; display: inline-flex; align-items: center; gap: 4px; }
.dl-chip-type { color: var(--dl-f); background: color-mix(in srgb, var(--dl-f) 12%, #fff); }
.dl-desc { font-size: .86rem; color: #475569; margin: 0; line-height: 1.55; }
.dl-how { font-size: .84rem; border-radius: 10px; background: #fffbeb; border: 1px solid #fde68a; padding: 6px 10px; }
.dl-how summary { cursor: pointer; font-weight: 600; color: #92400e; list-style: none; }
.dl-how summary::-webkit-details-marker { display: none; }
.dl-how summary i { margin-right: 4px; }
.dl-how p { margin: 6px 0 2px; color: #78350f; }
.dl-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: auto; padding-top: 4px; }
.dl-btn { background: var(--dl-c); color: #fff !important; border: 0; }
.dl-btn { --bs-btn-color: #fff; --bs-btn-bg: var(--dl-c); --bs-btn-border-color: var(--dl-c); --bs-btn-hover-color: #fff; --bs-btn-hover-bg: var(--dl-c); --bs-btn-hover-border-color: var(--dl-c); --bs-btn-active-color: #fff; --bs-btn-active-bg: var(--dl-c); --bs-btn-active-border-color: var(--dl-c); --bs-btn-focus-shadow-rgb: 107,47,160; }
.dl-btn:hover, .dl-btn:focus, .dl-btn:focus-visible, .dl-btn:active { background-color: var(--dl-c); border-color: var(--dl-c); color: #fff !important; filter: brightness(1.12); box-shadow: 0 4px 12px rgba(15,23,42,.2); }
.dl-btn:hover i, .dl-btn:hover span, .dl-btn:hover .dl-en { color: #fff !important; }
.dl-btn .dl-en { color: rgba(255,255,255,.85) !important; font-size: .72rem; }
.dl-related { font-size: .8rem; font-weight: 600; text-decoration: none; color: #6b2fa0; }
.dl-related:hover { text-decoration: underline; }
.dl-count { font-size: .76rem; color: #94a3b8; }
@media (max-width: 575.98px) { .dl-sort { width: 100%; } .dl-sort select { flex: 1; } .dl-chipbar { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 6px; margin: 0 -4px; } .dl-cat { white-space: nowrap; } }
html[data-theme="dark"] .dl-card, body.dark .dl-card { background: #1e2230; border-color: #2d3345; }
html[data-theme="dark"] .dl-desc, body.dark .dl-desc { color: #cbd5e1; }
html[data-theme="dark"] .dl-title, body.dark .dl-title { color: #f1f5f9; }

/* ============================================================
   Resources list (/resources): category chips above the cards -- 5 Oct 2026.
   ============================================================ */
.rs-filter { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 22px; justify-content: center; }
.rs-filter button { border: 1px solid rgba(253,126,20,.4); background: rgba(253,126,20,.08); color: #c2410c; border-radius: 99px; padding: 6px 15px; font-weight: 600; font-size: .88rem; cursor: pointer; transition: background .15s, transform .12s; }
.rs-filter button:hover { transform: translateY(-1px); background: rgba(253,126,20,.16); }
.rs-filter button.is-on { background: #fd7e14; color: #fff; border-color: #fd7e14; }
.rs-filter .rs-n { font-size: .72rem; margin-left: 4px; opacity: .8; }

/* ---- engage.js: Save for later, continue reading, add-to-calendar menu ---- */
.akj-save-btn { display: inline-flex; align-items: center; margin: 0 0 .75rem; padding: .3rem .8rem; font-size: .85rem; font-weight: 600; border-radius: 999px; border: 1px solid rgba(100,116,139,.6); background: transparent; color: inherit; cursor: pointer; }
.akj-save-btn:hover { background: rgba(100,116,139,.12); }
.akj-save-btn[aria-pressed="true"] { border-color: #198754; color: #198754; }
.akj-save-btn.akj-save-dark { border-color: rgba(255,255,255,.55); color: #fff; }
.akj-save-btn.akj-save-dark:hover { background: rgba(255,255,255,.15); }
.akj-save-btn.akj-save-dark[aria-pressed="true"] { border-color: #86efac; color: #86efac; }

.akj-cr-item { display: block; padding: .6rem .8rem; border-radius: 10px; border: 1px solid var(--border, #e2e8f0); text-decoration: none; color: inherit; }
.akj-cr-item:hover { border-color: #2563eb; }
.akj-cr-t { display: block; font-weight: 600; font-size: .9rem; line-height: 1.3; margin-bottom: .35rem; }
.akj-cr-p { display: block; height: 5px; border-radius: 3px; background: rgba(100,116,139,.2); overflow: hidden; }
.akj-cr-p > span { display: block; height: 100%; background: #2563eb; }
.akj-cal-wrap { position: relative; display: inline-block; }
.akj-cal-menu { position: absolute; z-index: 1600; min-width: 260px; margin-top: .3rem; padding: .35rem; background: #fff; color: #0f172a; border: 1px solid #cbd5e1; border-radius: 10px; box-shadow: 0 8px 24px rgba(15,23,42,.18); display: flex; flex-direction: column; }
.akj-cal-menu a, .akj-cal-menu button { display: block; text-align: left; padding: .5rem .7rem; border: 0; background: transparent; color: inherit; font-size: .88rem; text-decoration: none; border-radius: 6px; cursor: pointer; }
.akj-cal-menu a:hover, .akj-cal-menu button:hover { background: #eff6ff; }
.akj-cal-note { padding: .3rem .7rem .4rem; font-size: .75rem; color: #64748b; }
html[data-theme="dark"] .akj-cal-menu { background: #1a1f2e; color: #e2e8f0; border-color: #2d3748; }
html[data-theme="dark"] .akj-cal-menu a:hover, html[data-theme="dark"] .akj-cal-menu button:hover { background: #243049; }

/* ---- one-page printable result (built by calc-toolbar.js) ---- */
#akj-print-sheet { display: none; }
@media print {
    body.akj-printing > *:not(#akj-print-sheet) { display: none !important; }
    body.akj-printing #akj-print-sheet { display: block !important; position: static; color: #000; background: #fff; font-size: 11pt; line-height: 1.4; padding: 0; }
    #akj-print-sheet h1 { font-size: 17pt; margin: 0 0 2pt; }
    #akj-print-sheet h2 { font-size: 11pt; margin: 10pt 0 4pt; text-transform: uppercase; letter-spacing: .04em; border-bottom: 1px solid #999; padding-bottom: 2pt; }
    #akj-print-sheet .ps-meta { font-size: 9pt; color: #444; margin-bottom: 8pt; }
    #akj-print-sheet .ps-cols { display: flex; gap: 16pt; align-items: flex-start; }
    #akj-print-sheet .ps-cols > div { flex: 1 1 0; min-width: 0; }
    #akj-print-sheet table { width: 100%; border-collapse: collapse; font-size: 10pt; }
    #akj-print-sheet td { padding: 2.5pt 0; border-bottom: 1px dotted #bbb; vertical-align: top; }
    #akj-print-sheet td:last-child { text-align: right; font-weight: 600; padding-left: 8pt; }
    #akj-print-sheet .ps-tbl3 td { text-align: right; font-weight: 400; }
    #akj-print-sheet .ps-tbl3 td:first-child { text-align: left; padding-left: 0; }
    #akj-print-sheet .ps-tbl3 td:last-child { font-weight: 600; }
    #akj-print-sheet .ps-notes { font-size: 9pt; margin: 0; padding-left: 14pt; }
    #akj-print-sheet .ps-head { text-align: center; margin: 4pt 0 6pt; }
    #akj-print-sheet .ps-head b { display: block; font-size: 20pt; }
    #akj-print-sheet .ps-head span { font-size: 9pt; color: #444; }
    #akj-print-sheet .ps-verdict { font-size: 10pt; margin: 6pt 0; padding: 5pt 7pt; border: 1px solid #999; }
    #akj-print-sheet img { max-width: 100%; max-height: 180pt; display: block; margin: 6pt auto; }
    #akj-print-sheet .ps-note { font-size: 8.5pt; color: #333; margin-top: 8pt; border: 1px solid #999; padding: 5pt 7pt; }
    #akj-print-sheet .ps-foot { font-size: 8pt; color: #555; margin-top: 6pt; }
    @page { size: A4; margin: 14mm; }
}

/* ============================================================
   Rates & Rules page (/rates-and-rules): .rt-*
   ============================================================ */
.rt-card { border-top: 3px solid var(--rt-c, #0d6efd) !important; }
.rt-ico { width: 38px; height: 38px; border-radius: 10px; display: inline-flex; align-items: center; justify-content: center; font-size: 1.15rem; color: #fff; background: var(--rt-c, #0d6efd); flex: 0 0 auto; }
.rt-list { border-top: 1px solid var(--border, #e2e8f0); }
.rt-row { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: .15rem 1rem; padding: .7rem 0; border-bottom: 1px solid var(--border, #e2e8f0); }
.rt-row:last-child { border-bottom: 0; }
.rt-l { grid-column: 1; }
.rt-v { grid-column: 2; text-align: right; display: flex; flex-direction: column; align-items: flex-end; gap: .2rem; }
.rt-v strong { font-size: 1.02rem; line-height: 1.3; }
.rt-note, .rt-src { grid-column: 1 / -1; font-size: .84rem; }
.rt-src { color: var(--text-muted, #6c757d); font-size: .76rem; }
.rt-tag { display: inline-block; font-size: .7rem; font-weight: 600; padding: .1rem .5rem; border-radius: 99px; white-space: nowrap; cursor: help; }
.rt-tag-ok  { background: #e6f6ee; color: #146c43; }
.rt-tag-rep { background: #fff4d6; color: #8a5a00; }
.rt-note-stale { color: #b42318; font-weight: 600; }
.rt-row-stale .rt-v strong { color: #b42318; }
.rt-slab .table { font-size: .9rem; }
[data-theme="dark"] .rt-tag-ok, [data-theme="ocean"] .rt-tag-ok  { background: #123524; color: #7ee2a8; }
[data-theme="dark"] .rt-tag-rep, [data-theme="ocean"] .rt-tag-rep { background: #3b2f0b; color: #f6c453; }
[data-theme="dark"] .rt-note-stale, [data-theme="ocean"] .rt-note-stale, [data-theme="dark"] .rt-row-stale .rt-v strong { color: #ff8a80; }
@media (max-width: 575.98px) {
    .rt-row { grid-template-columns: 1fr; }
    .rt-v { grid-column: 1; text-align: left; align-items: flex-start; flex-direction: row; flex-wrap: wrap; align-items: center; gap: .35rem .6rem; }
}

/* Merged-menu button row (partials/section-tabs.php): on phones it is ONE swipeable line instead of a tall stack of pills (the Money Rules group now has 7 tabs) */
@media (max-width: 767.98px) {
    nav.section-tabs { flex-wrap: nowrap !important; overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none; margin-bottom: 1rem !important; padding-bottom: .15rem; gap: .4rem !important; }
    nav.section-tabs::-webkit-scrollbar { display: none; }
    nav.section-tabs .btn { flex: 0 0 auto; white-space: nowrap; padding: .3rem .85rem !important; font-size: .85rem; }
    nav.section-tabs .btn .bi { margin-right: .35rem !important; }
}

/* Rates page: section jump chips = one swipeable line on phones */
@media (max-width: 767.98px) {
    .rt-jump { flex-wrap: nowrap !important; overflow-x: auto; scrollbar-width: none; margin-bottom: 1rem !important; }
    .rt-jump::-webkit-scrollbar { display: none; }
    .rt-jump .btn { flex: 0 0 auto; white-space: nowrap; }
}

/* ============================================================
   Scam Alert hub (/scam-alerts): .sc-*
   ============================================================ */
.sc-emer { border-left: 4px solid #dc3545 !important; }
.sc-ico { width: 38px; height: 38px; border-radius: 10px; display: inline-flex; align-items: center; justify-content: center; font-size: 1.1rem; color: #fff; background: #6b2fa0; flex: 0 0 auto; }
.sc-ico-red { background: #dc3545; }
.sc-steps { padding-left: 1.2rem; margin-bottom: .75rem; }
.sc-steps li { margin-bottom: .55rem; }
.sc-rule { display: flex; gap: .75rem; align-items: flex-start; padding: .8rem 1rem; border: 1px solid var(--border, #e2e8f0); border-radius: 12px; background: var(--card-bg, #fff); }
.sc-rule-n { width: 26px; height: 26px; flex: 0 0 auto; border-radius: 50%; background: #0d6efd; color: #fff; font-weight: 700; font-size: .85rem; display: inline-flex; align-items: center; justify-content: center; }
.sc-checks { display: grid; grid-template-columns: 1fr 1fr; gap: .5rem; }
.sc-check { display: flex; gap: .6rem; align-items: flex-start; padding: .55rem .7rem; border: 1px solid var(--border, #e2e8f0); border-radius: 10px; cursor: pointer; margin: 0; }
.sc-check input { margin-top: .25rem; flex: 0 0 auto; }
.sc-check:has(input:checked) { border-color: #dc3545; background: rgba(220,53,69,.07); }
.sc-item { border: 1px solid var(--border, #e2e8f0); border-radius: 12px; margin-bottom: .6rem; background: var(--card-bg, #fff); }
.sc-item > summary { list-style: none; display: flex; align-items: center; gap: .75rem; padding: .7rem .9rem; cursor: pointer; }
.sc-item > summary::-webkit-details-marker { display: none; }
.sc-sum { flex: 1 1 auto; min-width: 0; }
.sc-chev { transition: transform .2s; color: var(--text-muted, #6c757d); }
.sc-item[open] > summary .sc-chev { transform: rotate(180deg); }
.sc-item[open] { border-color: #6b2fa0; }
.sc-body { padding: 0 1rem 1rem; border-top: 1px solid var(--border, #e2e8f0); padding-top: .8rem; }
.sc-h { font-size: .8rem; font-weight: 700; text-transform: uppercase; letter-spacing: .03em; color: var(--text-muted, #6c757d); margin: 0 0 .35rem; }
.sc-h-red { color: #b42318; } .sc-h-green { color: #146c43; }
.sc-ul { padding-left: 1.1rem; margin-bottom: .5rem; }
.sc-ul li { margin-bottom: .4rem; }
.sc-chan { border: 1px solid var(--border, #e2e8f0); border-radius: 12px; padding: .9rem 1rem; background: var(--card-bg, #fff); }
.sc-liab { border: 1px solid var(--border, #e2e8f0); border-radius: 12px; padding: .9rem 1rem; background: var(--card-bg, #fff); }
.sc-liab-on { border: 2px solid #198754; }
[data-theme="dark"] .sc-h-red, [data-theme="ocean"] .sc-h-red { color: #ff8a80; }
[data-theme="dark"] .sc-h-green, [data-theme="ocean"] .sc-h-green { color: #7ee2a8; }
@media (max-width: 767.98px) {
    .sc-checks { grid-template-columns: 1fr; }
    .sc-item > summary { padding: .6rem .7rem; }
    .sc-body { padding-left: .8rem; padding-right: .8rem; }
}
@media print { .sc-item { break-inside: avoid; } .sc-item:not([open]) .sc-body { display: block; } }

/* ===== "Which option fits?" finder (/which-option) ===== */
.fd-q { border: 0; padding: 0; margin: 0 0 1.1rem; min-width: 0; }
.fd-qt { font-size: 1rem; font-weight: 700; margin-bottom: .5rem; padding: 0; float: none; width: auto; }
.fd-opts { display: flex; flex-wrap: wrap; gap: .5rem; }
.fd-pill { position: relative; display: flex; align-items: flex-start; gap: .5rem; padding: .5rem .8rem; border: 1px solid var(--border, #cbd5e1); border-radius: 12px; cursor: pointer; margin: 0; background: var(--card-bg, #fff); max-width: 100%; }
.fd-pill input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.fd-pill > span { line-height: 1.3; font-size: .92rem; }
.fd-pill:hover { border-color: #0d6efd; }
.fd-pill:has(input:checked) { border-color: #0d6efd; background: rgba(13,110,253,.08); box-shadow: inset 0 0 0 1px #0d6efd; }
.fd-pill:has(input:focus-visible) { outline: 2px solid #0d6efd; outline-offset: 2px; }
.fd-group > h3 { padding-left: .6rem; border-left: 4px solid var(--fd-c, #6c757d); }
.fd-g-fit { --fd-c: #198754; } .fd-g-part { --fd-c: #f59f00; } .fd-g-no { --fd-c: #dc3545; }
.fd-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: .75rem; }
.fd-card { border: 1px solid var(--border, #e2e8f0); border-left: 4px solid var(--fd-c, #6c757d); border-radius: 12px; padding: .8rem .95rem; background: var(--card-bg, #fff); }
.fd-card.fd-fit { --fd-c: #198754; } .fd-card.fd-part { --fd-c: #f59f00; } .fd-card.fd-no { --fd-c: #dc3545; }
.fd-rs { margin-top: .5rem; }
.fd-r { display: flex; gap: .5rem; align-items: flex-start; font-size: .86rem; margin-bottom: .25rem; }
.fd-r i { margin-top: .15rem; flex: 0 0 auto; }
.fd-r-ok i { color: #198754; } .fd-r-warn i { color: #d97706; } .fd-r-bad i { color: #dc3545; }
@media (max-width: 575.98px) {
    .fd-cards { grid-template-columns: 1fr; }
    .fd-pill { width: 100%; }
    .fd-card .text-end { text-align: left !important; }
}

/* ===== Which tax regime? guided comparison (/which-tax-regime) ===== */
.tr-steps { counter-reset: none; margin: 0; padding: 0; }
.tr-steps li { display: flex; align-items: center; gap: .4rem; flex: 1 1 0; min-width: 0; padding-bottom: .5rem; border-bottom: 3px solid var(--border, #e2e8f0); color: #64748b; }
.tr-steps li span { display: inline-flex; align-items: center; justify-content: center; width: 24px; height: 24px; border-radius: 50%; background: #e2e8f0; font-size: .78rem; font-weight: 700; flex: 0 0 auto; }
.tr-steps li small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-weight: 600; }
.tr-steps li.on { border-bottom-color: #0d6efd; color: #0d6efd; }
.tr-steps li.on span { background: #0d6efd; color: #fff; }
.tr-steps li.done { border-bottom-color: #198754; color: #198754; }
.tr-steps li.done span { background: #198754; color: #fff; }
.tr-ig { max-width: 340px; }
.tr-ig .form-control { font-variant-numeric: tabular-nums; }
.tr-hint:empty { display: none; }
.tr-hero { border-radius: 16px; padding: 1.1rem 1.25rem; color: #fff; text-align: center; }
.tr-hero.tr-ok { background: linear-gradient(135deg, #0a2342, #198754); }
.tr-hero.tr-eq { background: linear-gradient(135deg, #0a2342, #6b2fa0); }
.tr-big { font-size: clamp(1.5rem, 4vw, 2.1rem); font-weight: 800; line-height: 1.2; margin: .25rem 0; }
.tr-cols { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; }
.tr-col { background: var(--card-bg, #fff); border: 1px solid var(--border, #e2e8f0); border-radius: 14px; padding: .8rem .9rem; box-shadow: 0 1px 3px rgba(0,0,0,.05); }
.tr-col.tr-best { border-color: #198754; box-shadow: inset 0 0 0 1px #198754; }
.tr-colh { font-weight: 700; margin-bottom: .4rem; }
.tr-row { display: flex; justify-content: space-between; gap: .5rem; padding: .22rem 0; font-size: .88rem; border-bottom: 1px dashed rgba(100,116,139,.25); }
.tr-row dt { font-weight: 500; color: #64748b; margin: 0; }
.tr-row dd { margin: 0; font-weight: 600; text-align: right; font-variant-numeric: tabular-nums; }
.tr-total { font-size: .98rem; border-bottom-style: solid; }
.tr-total dt { color: inherit; font-weight: 700; }
@media (max-width: 575.98px) {
    .tr-cols { grid-template-columns: 1fr; }
    .tr-steps li small { display: none; }
}
@media print { #tr-form, .tr-steps { display: none !important; } .tr-hero { color: #000 !important; background: none !important; border: 1px solid #999; } .tr-cols { grid-template-columns: 1fr 1fr; } }

/* ===== Quiz / Checkup result: "what next?" picks ===== */
.reco-grid { display: grid; gap: .6rem; }
.reco-card { display: flex; align-items: center; gap: .75rem; padding: .7rem .9rem; border: 1px solid var(--border, #e2e8f0); border-radius: 14px; background: var(--card-bg, #fff); color: inherit; box-shadow: 0 1px 3px rgba(0,0,0,.05); transition: transform .15s, border-color .15s, box-shadow .15s; }
.reco-card:hover, .reco-card:focus-visible { transform: translateY(-2px); border-color: #0d6efd; box-shadow: 0 4px 14px rgba(13,110,253,.15); }
.reco-ic { font-size: 1.35rem; color: #0d6efd; flex: 0 0 auto; }
.reco-tx { display: flex; flex-direction: column; min-width: 0; flex: 1 1 auto; }
.reco-kind { font-size: .7rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: #64748b; }
.reco-lb { font-weight: 600; line-height: 1.3; color: #0f172a; overflow-wrap: anywhere; }
.reco-go { color: #0d6efd; flex: 0 0 auto; }
@media (min-width: 768px) { .reco-grid { grid-template-columns: repeat(3, 1fr); } .reco-card { flex-direction: column; align-items: flex-start; } .reco-go { display: none; } }
html[data-theme="dark"] .reco-lb, body.dark-mode .reco-lb { color: #e2e8f0; }
[data-theme="dark"] .reco-card { background: #1a1f2e; border-color: #2d3748; }

/* ===== Smart search: popular chips, did-you-mean, zero-result help (/search) ===== */
.srch-chip { display: inline-block; padding: .3rem .8rem; border: 1px solid var(--border, #cbd5e1); border-radius: 999px; background: var(--card-bg, #fff); color: inherit; text-decoration: none; font-size: .9rem; transition: border-color .15s, background .15s; }
.srch-chip:hover, .srch-chip:focus-visible { border-color: #0d6efd; background: rgba(13,110,253,.08); color: #0d6efd; }
.srch-chip-hl { border-color: #0d6efd; color: #0d6efd; font-weight: 600; margin-left: .35rem; }
.srch-hit:hover span { text-decoration: underline; }
[data-theme="dark"] .srch-chip { background: #1a1f2e; border-color: #2d3748; }
.srch-thumb { width: 64px; height: 48px; object-fit: cover; border-radius: 8px; flex: 0 0 auto; }
@media (min-width: 768px) { .reco-card .srch-thumb { width: 100%; height: 110px; } }
