/*
 * Editorial reading style for RateScan.in articles and the /articles/ index.
 * Hand-maintained (not generated). Everything is scoped to pages with <body class="article-page">
 * or to article-* / art-* / viz-* classes, so the rest of the site is unaffected.
 * Serif body (Inria Serif), serif headline (Source Serif 4), Inter for headings and tables, near-black on
 * near-white, teal links, one narrow reading column; dark values are chosen, not inverted.
 */
.article-actions { display: inline-flex; align-items: center; gap: 2px; margin-left: auto; }
.art-icon-btn { width: 40px; height: 40px; display: inline-flex; align-items: center; justify-content: center; border: 0; background: transparent; border-radius: 50%; color: var(--ink); cursor: pointer; padding: 0; }
.art-icon-btn:hover { background: var(--surface-2); }
.art-icon-btn:focus-visible, .art-share-menu a:focus-visible, .art-share-menu button:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
.art-icon-btn[aria-pressed="true"] svg { fill: currentColor; }
.art-share { position: relative; }
.art-share-menu { position: absolute; right: 0; top: 44px; z-index: 30; display: flex; flex-direction: column; gap: 2px; padding: 6px; background: var(--surface); border: 1px solid var(--line); border-radius: 8px; box-shadow: 0 8px 24px rgba(0, 0, 0, 0.14); }
.art-share-menu[hidden] { display: none; }
.art-share-menu a, .art-share-menu button { width: 40px; height: 40px; display: inline-flex; align-items: center; justify-content: center; border: 0; background: transparent; border-radius: 6px; color: var(--ink); cursor: pointer; padding: 0; }
.art-share-menu a:hover, .art-share-menu button:hover { background: var(--surface-2); }
.art-toast { position: fixed; left: 50%; bottom: 24px; z-index: 60; max-width: calc(100vw - 32px); transform: translate(-50%, 16px); opacity: 0; pointer-events: none; background: var(--ink); color: var(--bg); padding: 10px 16px; border-radius: 8px; font: 500 14px/1.4 var(--font); transition: opacity 0.2s, transform 0.2s; }
.art-toast.show { opacity: 1; transform: translate(-50%, 0); }
@media (prefers-reduced-motion: reduce) { .art-toast { transition: none; } }
.article-page .crumb-share, .article-page .crumb-telegram { display: none !important; }
.article-byline { display: flex; align-items: center; gap: 12px; margin: 16px 0 8px; flex-wrap: wrap; }
.article-byline .brand-mark { width: 44px; height: 44px; flex: none; }
.article-byline-text { flex: 1 1 210px; min-width: 0; }
.article-byline-text strong { display: block; font-size: 15px; color: var(--ink); }
.article-byline-text span { font-size: 13px; color: var(--muted); }
.article-follow { margin-left: 4px; padding: 6px 16px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); color: var(--brand); font-weight: 600; font-size: 14px; text-decoration: none; }
.article-follow:hover { border-color: var(--brand); }
.article-follow { display: inline-flex; align-items: center; gap: 7px; }
.article-follow svg { width: 16px; height: 16px; flex: none; }
.tabs > input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.tab-bar { display: flex; gap: 6px; flex-wrap: wrap; margin: 4px 0 12px; }
.tab-bar label { padding: 6px 14px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); color: var(--ink-2); font-weight: 600; font-size: 14px; cursor: pointer; }
.tab-panels > .tab-panel { display: none; }
.tabs > input:nth-of-type(1):checked ~ .tab-panels > .tab-panel:nth-child(1),
.tabs > input:nth-of-type(2):checked ~ .tab-panels > .tab-panel:nth-child(2),
.tabs > input:nth-of-type(3):checked ~ .tab-panels > .tab-panel:nth-child(3) { display: block; }
.tabs > input:nth-of-type(1):checked ~ .tab-bar > label:nth-child(1),
.tabs > input:nth-of-type(2):checked ~ .tab-bar > label:nth-child(2),
.tabs > input:nth-of-type(3):checked ~ .tab-bar > label:nth-child(3) { background: var(--brand); border-color: var(--brand); color: #fff; }
.tabs > input:nth-of-type(1):focus-visible ~ .tab-bar > label:nth-child(1),
.tabs > input:nth-of-type(2):focus-visible ~ .tab-bar > label:nth-child(2),
.tabs > input:nth-of-type(3):focus-visible ~ .tab-bar > label:nth-child(3) { outline: 2px solid var(--brand); outline-offset: 2px; }
/* editorial reading style, scoped to article pages: serif body (Inria Serif), serif headline, sans headings and tables,
   near-black on near-white, teal links, one narrow column. Dark values are chosen, not inverted. */
.article-page { --bg: #fefefe; --surface: #ffffff; --surface-2: #f6f6f4; --ink: #111111; --ink-2: #2d2d2d; --muted: #6b6b6b; --line: #e3e3df; --line-2: #eeeeea; --brand: #007b9d; --font-body: "Inria Serif", Georgia, "Times New Roman", serif; --font-head: "Source Serif 4", Georgia, "Times New Roman", serif; }
html[data-theme="dark"] .article-page { --bg: #0c0e13; --surface: #14171e; --surface-2: #10131a; --ink: #f1f1ee; --ink-2: #d4d4cf; --muted: #9b9b96; --line: #2a2d36; --line-2: #1f222a; --brand: #4cc3e0; }
@media (prefers-color-scheme: dark) { html:not([data-theme="light"]) .article-page { --bg: #0c0e13; --surface: #14171e; --surface-2: #10131a; --ink: #f1f1ee; --ink-2: #d4d4cf; --muted: #9b9b96; --line: #2a2d36; --line-2: #1f222a; --brand: #4cc3e0; } }
.article-page { background: var(--bg); color: var(--ink); }
.art-hero { padding: 28px 0 8px; }
.art-hero-grid { display: grid; grid-template-columns: 1fr; gap: 24px; align-items: start; }
.art-kicker { margin: 0; font: 600 13px/1 var(--font); letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-2); }
.art-kicker i { color: var(--brand); font-style: normal; margin: 0 6px; }
.art-hero h1 { font-family: var(--font-head); font-weight: 700; font-size: clamp(32px, 4.6vw, 48px); line-height: 1.12; letter-spacing: -0.01em; margin: 14px 0 18px; color: var(--ink); max-width: 18ch; }
.art-hero h1 .grad { background: none; -webkit-text-fill-color: currentColor; color: inherit; }
.art-date { margin: 4px 0 0; font-size: 13px; color: var(--muted); }
.art-hero-img { margin: 0; }
.art-hero-img img { display: block; width: 100%; height: auto; border-radius: 4px; }
@media (min-width: 900px) { .art-hero-grid { grid-template-columns: 1.05fr 1fr; gap: 40px; } .art-hero h1 { max-width: none; } }
.article-col { max-width: 860px; }
.article-page .art-dek { font-family: var(--font-body); font-size: 21px; line-height: 1.55; color: var(--ink); margin: 18px 0 20px; max-width: 700px; }
.article-page .article-col p, .article-page .article-col li { font-family: var(--font-body); font-size: 17.5px; line-height: 1.7; color: var(--ink); }
.article-page .article-col p, .article-page .article-col ul.rate-intro, .article-page .article-col .rate-intro { max-width: 700px; }
.article-page .rate-intro { display: block; color: var(--ink); font-size: 17.5px; line-height: 1.7; }
.article-page .rate-intro p { margin: 0 0 16px; }
.article-page .section-note { font-family: var(--font-body); font-size: 17px; line-height: 1.6; color: var(--ink-2); max-width: 700px; }
.article-page .muted, .article-page .section-note a { color: var(--muted); }
.article-page .article-col .muted { font-size: 14.5px; }
.article-page .section-title { font-family: var(--font); font-size: 28px; line-height: 1.3; font-weight: 700; letter-spacing: -0.01em; color: var(--ink); }
.article-page .article-h3 { font-family: var(--font); font-size: 21px; font-weight: 700; letter-spacing: -0.005em; color: var(--ink); }
.article-page .article-h4 { font-family: var(--font); font-weight: 600; color: var(--ink); }
.article-page .article-col a, .article-page .rate-intro a { color: var(--brand); }
.article-page .article-col a.bank-link, .article-page .article-col .bank-link { color: var(--brand); font-weight: 600; }
.article-page .rate-table, .article-page .viz, .article-page .viz-legend li, .article-page .tab-bar label, .article-page .faq-q, .article-page .article-follow, .article-page .article-byline-text { font-family: var(--font); }
.article-page .rate-table td, .article-page .rate-table th { font-family: var(--font); font-size: 14px; line-height: 1.45; }
.article-page .viz-legend li, .article-page .viz-swipe, .article-page .article-swipe { font-family: var(--font); font-size: 13px; line-height: 1.4; }
.article-page .faq-a p { font-family: var(--font-body); }
.article-page .panel, .article-page .table-wrap, .article-page .faq-item { background: var(--surface); border-color: var(--line); box-shadow: none; }
.article-page .viz-pair { position: relative; left: 50%; width: min(1000px, calc(100vw - 44px)); transform: translateX(-50%); }
@media (max-width: 899px) { .article-page .viz-pair { left: 0; width: auto; transform: none; } }
.article-page .viz-pair .viz-svg text { font-size: 15px; }
.article-table { min-width: 0; }
.article-table td, .article-table th, .rate-table.article-table .bank-name, .rate-table.article-table a.bank-link { white-space: normal; }
.article-nowrap { white-space: nowrap !important; }
.article-matrix td, .article-matrix th { min-width: 112px; vertical-align: top; }
.article-matrix td:first-child, .article-matrix th:first-child { min-width: 150px; }
.article-h3 { font-size: 18px; margin: 28px 0 8px; }
.article-h4 { font-size: 15.5px; margin: 18px 0 8px; }
.section-note a, .article-jump a, .muted a, .article-table td a:not(.bank-link) { color: var(--brand); text-decoration: underline; text-underline-offset: 2px; }
.article-swipe, .viz-swipe { display: none; margin: 0 0 8px; font-size: 12.5px; }
.article-sub-block + .article-sub-block { margin-top: 6px; }
.article-sub { display: none; font-size: 12.5px; margin-top: 2px; }
.article-sub-cell { font-size: 12.5px; margin-top: 2px; line-height: 1.35; }
.article-sub a, .article-table td.article-wide a, .rate-intro a { color: var(--brand); text-decoration: underline; text-underline-offset: 2px; }
/* charts: colour roles as variables, validated palette (blue, orange, aqua); dark values selected, not flipped */
.viz, .viz-mapfig { --viz-s1: #2a78d6; --viz-s2: #eb6834; --viz-s3: #1baf7a; --viz-event: #6b7280; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .viz { --viz-s1: #3987e5; --viz-s2: #d95926; --viz-s3: #199e70; --viz-event: #9ca3af; } }
:root[data-theme="dark"] .viz { --viz-s1: #3987e5; --viz-s2: #d95926; --viz-s3: #199e70; --viz-event: #9ca3af; }
.viz { margin: 16px 0 22px; }
.viz figcaption { margin: 0 0 8px; font-size: 13.5px; }
.viz figcaption strong { display: block; font-size: 15px; color: var(--ink); }
.viz-legend { display: flex; flex-wrap: wrap; gap: 6px 16px; list-style: none; margin: 0 0 8px; padding: 0; font-size: 13px; color: var(--ink-2); }
.viz-key { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.viz-scroll { overflow-x: auto; }
.viz-svg { display: block; width: 100%; height: auto; }
.viz-svg text { font-family: inherit; font-size: 12px; fill: var(--ink-2); }
.viz-svg text.vv { fill: var(--ink); font-weight: 600; }
.viz-svg .vgrid { stroke: var(--line); stroke-width: 1; }
.viz-svg .vaxis { stroke: var(--muted); stroke-width: 1; }
.viz-svg .vring { stroke: var(--surface); }
.viz-svg .viz-event { fill: var(--viz-event); }
.viz-map { max-width: 440px; margin: 0 auto; }
.viz-pair { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0 24px; }
.viz-pair > .viz { min-width: 0; }
@media (min-width: 900px) { .viz-pair { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.viz-table { margin-top: 8px; }
.viz-table summary { cursor: pointer; font-size: 13px; color: var(--brand); }
.viz-table:not([open]) > :not(summary) { display: none; }
@media (max-width: 720px) {
  .article-wide, .article-rank { display: none; }
  .article-sub { display: block; }
  .article-table td, .article-table th { padding: 10px 8px; }
  .article-swipe, .viz-swipe { display: block; }
  .article-matrix td:first-child, .article-matrix th:first-child { min-width: 108px; }
  .viz-scroll .viz-svg { min-width: 560px; }
}

/* ---- /articles/ index ---- */
.article-index-col { max-width: 860px; margin: 0 auto; }
.article-page .art-hero .art-dek-index { font-family: var(--font-body); font-size: 21px; line-height: 1.55; color: var(--ink); margin: 0; max-width: 700px; }
.article-page .art-hero-index h1 { max-width: none; margin-bottom: 14px; }
.article-list { display: block; }
.article-card { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; padding: 28px 0; border: 0; border-top: 1px solid var(--line); border-radius: 0; background: none; box-shadow: none; }
.article-card:last-child { border-bottom: 1px solid var(--line); }
@media (min-width: 720px) { .article-card { grid-template-columns: 220px minmax(0, 1fr); gap: 28px; } }
.article-card-thumb { display: block; }
.article-card-thumb img { display: block; width: 100%; height: auto; border-radius: 4px; }
.article-page .article-card-date { margin: 0 0 8px; font: 600 12.5px/1 var(--font); letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); }
.article-page .article-card-title { margin: 0 0 10px; font-family: var(--font-head); font-size: 26px; line-height: 1.2; font-weight: 700; letter-spacing: -0.005em; }
.article-page .article-card-title a { color: var(--ink); text-decoration: none; }
.article-page .article-card-title a:hover { color: var(--brand); }
.article-page .article-card-desc { margin: 0 0 12px; font-family: var(--font-body); font-size: 17px; line-height: 1.6; color: var(--ink-2); }
.article-card-tiles { display: flex; flex-wrap: wrap; gap: 6px 18px; list-style: none; margin: 0 0 14px; padding: 0; font: 400 14px/1.4 var(--font); color: var(--muted); }
.article-card-tiles strong { color: var(--ink); }
.article-card-cta { display: inline-flex; align-items: center; gap: 6px; font: 600 14.5px/1 var(--font); color: var(--brand); text-decoration: none; }
.article-card-cta:hover { text-decoration: underline; }
.article-pager { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 24px; font-family: var(--font); }
.article-pager-link { font-weight: 600; color: var(--brand); text-decoration: none; }
.saved-list { margin: 10px 0 0; padding-left: 20px; line-height: 1.9; font-family: var(--font-body); font-size: 17px; }
.saved-list a { color: var(--brand); font-weight: 600; }
