/* Rupiah, in blue — the colours of the Rp 50.000 note; Arial / Helvetica.
   The dashboard page was written against claude.ai's token names, so those names are set here. */

:root {
  color-scheme: light;
  --font-anthropic-sans: Arial, "Helvetica Neue", Helvetica, sans-serif;
  --font-anthropic-serif: Arial, "Helvetica Neue", Helvetica, sans-serif;

  --note-deep: #0b2f5e;         /* banner, darkest */
  --note-blue: #1d5fa8;         /* Rp 50.000 */
  --note-tint: #edf3fb;         /* review panel */
  --site-accent: var(--note-blue);

  --color-bg: #fafbfd;
  --color-panel: #ffffff;
  --color-fg: #142133;
  --color-fg-muted: #586678;
  --color-border-line: #e1e6ee;
  --color-ok: #23804e;          /* better */
  --color-warn: #a86b00;
  --color-bad: #c42b3f;         /* worse */

  /* chart series: blue first, then gold — red and green stay for worse and better */
  --series-1: #1d5fa8; --series-2: #c08a1e; --series-3: #2a8f87; --series-4: #6a4aa0;
  --series-5: #8b5e34; --series-6: #5b8fd0; --series-7: #a3abb8; --series-8: #c9184a;

  --cds-text-secondary: var(--color-fg-muted);
  --cds-border: var(--color-border-line);
  --cds-surface-popover: #ffffff;
  --cds-shadow-popover: 0 8px 28px rgba(11, 47, 94, .16);
  --cds-chart-grid: #edf0f5;
  --cds-chart-axis: #b6c0cc;
  --cds-chart-muted: #9aa6b4;
  --cds-chart-reference: #7d8a9a;

  --cds-font-size-caption: .78rem;
  --cds-font-size-body: .92rem;
  --cds-font-size-heading: 1.02rem;
  --cds-font-size-title: 1.75rem;
  --cds-font-weight-medium: 650;
  --cds-gap-xs: 4px; --cds-gap-sm: 8px; --cds-gap: 12px; --cds-gap-md: 16px; --cds-gap-lg: 28px;
  --cds-pad-xs: 6px; --cds-pad-sm: 10px; --cds-pad-lg: 18px;
  --cds-radius: 6px;
  --cds-dur-slow: 240ms;
  --fp-input: #1d5fa8;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --note-deep: #08203f; --note-blue: #6ea8ec; --note-tint: #142640;
    --color-bg: #0e1622; --color-panel: #142030; --color-fg: #e7edf5; --color-fg-muted: #9dabbb;
    --color-border-line: #26364a; --color-ok: #5cc28e; --color-warn: #e0a83a; --color-bad: #f2707e;
    --series-1: #6ea8ec; --series-2: #e3b04f; --series-3: #4fc1b7; --series-4: #a98be0;
    --series-5: #c99a6b; --series-6: #9ec4f2; --series-7: #7b8899; --series-8: #f07aa8;
    --cds-surface-popover: #1b2a3d; --cds-shadow-popover: 0 8px 28px rgba(0, 0, 0, .55);
    --cds-chart-grid: #1f2d3f; --cds-chart-axis: #3e5068; --cds-chart-muted: #64758a; --cds-chart-reference: #8495aa;
    --fp-input: #6ea8ec;
  }
}
@media (prefers-reduced-motion: reduce) { :root { --cds-dur-slow: 0ms; } }

* { box-sizing: border-box; }
html, body { margin: 0; background: var(--color-bg); color: var(--color-fg); }
body { overflow-x: clip; }
body { font-family: var(--font-anthropic-sans); font-size: 15px; line-height: 1.45; -webkit-font-smoothing: antialiased; }
:focus-visible { outline: 2px solid var(--site-accent); outline-offset: 2px; }

/* claude.ai's loading placeholder */
.dash-skeleton { color: transparent !important; background: var(--cds-chart-grid); border-radius: 4px; animation: site-pulse 1.4s ease-in-out infinite; }
.dash-skeleton * { visibility: hidden; }
@keyframes site-pulse { 50% { opacity: .55; } }
@media (prefers-reduced-motion: reduce) { .dash-skeleton { animation: none; } }

/* ---------- shell ---------- */
.site { max-width: 1320px; margin: 0 auto; padding: 0 clamp(14px, 3vw, 32px); }

/* the banner: banknote guilloche over Rp 50.000 blue — the one bold element on the page */
.site-bar {
  display: flex; align-items: baseline; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  margin: 0 calc(50% - 50vw) 30px; padding: 26px calc(50vw - 50%) 22px; color: #fff;   /* full width, text aligned with the page */
  background-color: var(--note-deep);
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='60' viewBox='0 0 240 60'%3E%3Cg fill='none' stroke='%23ffffff' stroke-opacity='.15' stroke-width='.7'%3E%3Cpath d='M0 30 Q30 2 60 30 T120 30 T180 30 T240 30'/%3E%3Cpath d='M0 30 Q30 58 60 30 T120 30 T180 30 T240 30'/%3E%3Cpath d='M0 22 Q30 -6 60 22 T120 22 T180 22 T240 22'/%3E%3Cpath d='M0 38 Q30 66 60 38 T120 38 T180 38 T240 38'/%3E%3Cpath d='M0 14 Q30 42 60 14 T120 14 T180 14 T240 14'/%3E%3Cpath d='M0 46 Q30 18 60 46 T120 46 T180 46 T240 46'/%3E%3C/g%3E%3C/svg%3E"),
    linear-gradient(100deg, #0b2f5e 0%, #1d5fa8 58%, #123f78 100%);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .site-bar { background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='60' viewBox='0 0 240 60'%3E%3Cg fill='none' stroke='%23ffffff' stroke-opacity='.1' stroke-width='.7'%3E%3Cpath d='M0 30 Q30 2 60 30 T120 30 T180 30 T240 30'/%3E%3Cpath d='M0 30 Q30 58 60 30 T120 30 T180 30 T240 30'/%3E%3Cpath d='M0 22 Q30 -6 60 22 T120 22 T180 22 T240 22'/%3E%3Cpath d='M0 38 Q30 66 60 38 T120 38 T180 38 T240 38'/%3E%3C/g%3E%3C/svg%3E"),
    linear-gradient(100deg, #061a33 0%, #10386a 58%, #0a2649 100%); }
}
.site-name { margin: 0; color: #fff; text-decoration: none; font-weight: 700; font-size: 1.1rem; letter-spacing: -.01em; }
.site-name span { color: rgba(255, 255, 255, .75); font-weight: 500; }
.site-asof { font-size: .8rem; color: rgba(255, 255, 255, .82); font-variant-numeric: tabular-nums; }
#dash-root { min-height: 60vh; }

/* ---------- headlines and footer ---------- */
.site-news { margin: 40px 0 0; padding: 22px 0 0; border-top: 1px solid var(--color-border-line); }
.site-news h2 { font-size: 1.02rem; margin: 0 0 4px; font-weight: 700; }
.site-news p { margin: 0 0 14px; color: var(--color-fg-muted); font-size: .8rem; }
.site-news ol { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 19rem), 1fr)); gap: 2px 28px; }
.site-news li { padding: 9px 0; border-bottom: 1px solid var(--color-border-line); }
.site-news a { color: var(--color-fg); text-decoration: none; font-size: .9rem; line-height: 1.35; }
.site-news a:hover { color: var(--note-blue); text-decoration: underline; }
.site-news time { display: block; margin-top: 3px; font-size: .74rem; color: var(--color-fg-muted); font-variant-numeric: tabular-nums; }
.site-foot { margin: 36px 0 28px; font-size: .76rem; color: var(--color-fg-muted); line-height: 1.55; max-width: 62rem; }


/* the site shows its own banner above the page, so the page's banner stays hidden here */
.site #dash-root .fp-banner { display: none; }

/* the site's Dark switch: the same dark values, whatever the device says */
  :root[data-theme="dark"] {
    color-scheme: dark;
    --note-deep: #08203f; --note-blue: #6ea8ec; --note-tint: #142640;
    --color-bg: #0e1622; --color-panel: #142030; --color-fg: #e7edf5; --color-fg-muted: #9dabbb;
    --color-border-line: #26364a; --color-ok: #5cc28e; --color-warn: #e0a83a; --color-bad: #f2707e;
    --series-1: #6ea8ec; --series-2: #e3b04f; --series-3: #4fc1b7; --series-4: #a98be0;
    --series-5: #c99a6b; --series-6: #9ec4f2; --series-7: #7b8899; --series-8: #f07aa8;
    --cds-surface-popover: #1b2a3d; --cds-shadow-popover: 0 8px 28px rgba(0, 0, 0, .55);
    --cds-chart-grid: #1f2d3f; --cds-chart-axis: #3e5068; --cds-chart-muted: #64758a; --cds-chart-reference: #8495aa;
    --fp-input: #6ea8ec;
  }
  :root[data-theme="dark"] .site-bar { background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='60' viewBox='0 0 240 60'%3E%3Cg fill='none' stroke='%23ffffff' stroke-opacity='.1' stroke-width='.7'%3E%3Cpath d='M0 30 Q30 2 60 30 T120 30 T180 30 T240 30'/%3E%3Cpath d='M0 30 Q30 58 60 30 T120 30 T180 30 T240 30'/%3E%3Cpath d='M0 22 Q30 -6 60 22 T120 22 T180 22 T240 22'/%3E%3Cpath d='M0 38 Q30 66 60 38 T120 38 T180 38 T240 38'/%3E%3C/g%3E%3C/svg%3E"),
    linear-gradient(100deg, #061a33 0%, #10386a 58%, #0a2649 100%); }

/* the theme switch, in the banner */
.site-tools { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.site-theme { display: inline-flex; border: 1px solid rgba(255, 255, 255, .35); border-radius: 999px; overflow: hidden; }
.site-theme button { font: inherit; font-size: .76rem; font-weight: 600; color: rgba(255, 255, 255, .85); background: none; border: 0; padding: 4px 11px; cursor: pointer; }
.site-theme button + button { border-left: 1px solid rgba(255, 255, 255, .25); }
.site-theme button[aria-pressed="true"] { background: #fff; color: var(--note-deep); }
.site-theme button:focus-visible { outline: 2px solid #fff; outline-offset: -2px; }


/* ---------- navigation ---------- */
.site-brand { display: flex; align-items: baseline; gap: 6px 26px; flex-wrap: wrap; }
.site-nav { display: flex; gap: 18px; font-size: .86rem; }
.site-nav a { color: rgba(255, 255, 255, .78); text-decoration: none; padding-bottom: 3px; border-bottom: 2px solid transparent; }
.site-nav a:hover { color: #fff; }
.site-nav a[aria-current="page"] { color: #fff; border-bottom-color: #fff; font-weight: 600; }
.site-foot a { color: inherit; }

/* ---------- home and letters ---------- */
.home { display: flex; flex-direction: column; gap: 34px; }
.home h1 { font-size: clamp(1.5rem, 3vw, 2.1rem); line-height: 1.2; margin: 0 0 8px; letter-spacing: -.01em; }
.home h2 { font-size: 1.05rem; margin: 0 0 12px; font-weight: 700; }
.home-hero p { margin: 0 0 16px; color: var(--color-fg-muted); max-width: 46rem; font-size: 1rem; }
.home-cta { display: inline-block; background: var(--note-blue); color: #fff; text-decoration: none; font-weight: 600; font-size: .88rem; padding: 9px 16px; border-radius: var(--cds-radius); }
.home-cta:hover { filter: brightness(1.08); }
:root[data-theme="dark"] .home-cta { color: #08203f; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .home-cta { color: #08203f; } }
.home-note { margin: 10px 0 0; color: var(--color-fg-muted); font-size: .78rem; line-height: 1.5; max-width: 62rem; }
.home-eyebrow { margin: 0 0 6px; color: var(--color-fg-muted); font-size: .76rem; text-transform: uppercase; letter-spacing: .05em; }

.home-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 10rem), 1fr)); gap: 12px; }
.home-kpi { background: var(--color-panel); border: 1px solid var(--color-border-line); border-radius: var(--cds-radius); padding: 14px 16px; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.home-kpi-label { font-size: .78rem; color: var(--color-fg-muted); }
.home-kpi-value { font-size: 1.45rem; font-weight: 700; font-variant-numeric: tabular-nums; }
.home-kpi-chg { font-size: .78rem; color: var(--color-fg-muted); font-variant-numeric: tabular-nums; min-height: 1em; }
.home-good { color: var(--color-ok); }
.home-bad { color: var(--color-bad); }

.home-split { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 32px; align-items: start; }
.home-split > * { min-width: 0; }
.home-main { display: flex; flex-direction: column; gap: 28px; min-width: 0; }
.home-side { display: flex; flex-direction: column; gap: 24px; min-width: 0; }
@media (max-width: 900px) { .home-split { grid-template-columns: 1fr; } }
.home-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
.home-chips button { font: inherit; font-size: .76rem; background: none; border: 1px solid var(--color-border-line); border-radius: 999px; padding: 4px 11px; color: var(--color-fg-muted); cursor: pointer; }
.home-chips button[aria-pressed="true"] { background: var(--note-blue); border-color: var(--note-blue); color: #fff; }
:root[data-theme="dark"] .home-chips button[aria-pressed="true"] { color: #08203f; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .home-chips button[aria-pressed="true"] { color: #08203f; } }
.home-news-list { list-style: none; margin: 0; padding: 0; }
.home-news-list li { padding: 10px 0; border-bottom: 1px solid var(--color-border-line); }
.home-news-list a { color: var(--color-fg); text-decoration: none; font-size: .93rem; line-height: 1.35; }
.home-news-list a:hover { color: var(--note-blue); text-decoration: underline; }
.home-news-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 4px; font-size: .74rem; color: var(--color-fg-muted); }
.home-tag { background: var(--note-tint); color: var(--note-blue); border-radius: 4px; padding: 1px 6px; font-weight: 600; }
.home-news-empty { color: var(--color-fg-muted); font-size: .85rem; }
.home-more { font: inherit; font-size: .82rem; margin-top: 10px; background: none; border: 1px solid var(--color-border-line); border-radius: var(--cds-radius); padding: 6px 14px; color: var(--color-fg); cursor: pointer; }

.home-letter { background: var(--note-tint); border-radius: var(--cds-radius); padding: 20px; border-left: 4px solid var(--note-blue); }
.home-letter h2 { font-size: 1.2rem; line-height: 1.3; margin-bottom: 8px; }
.home-letter-sum { margin: 0 0 16px; font-size: .9rem; line-height: 1.5; }
.home-letter-links { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; font-size: .85rem; }
.home-letter-links a:not(.home-cta) { color: var(--note-blue); }

.home-banks { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 13.5rem), 1fr)); gap: 10px; }
@media (max-width: 560px) { .home-banks { grid-template-columns: 1fr 1fr; } .home-bank-top { flex-direction: column; gap: 0; } }
.home-bank { display: flex; flex-direction: column; gap: 3px; padding: 12px 14px; background: var(--color-panel); border: 1px solid var(--color-border-line); border-radius: var(--cds-radius); text-decoration: none; color: var(--color-fg); }
.home-bank:hover { border-color: var(--note-blue); }
.home-bank-top { display: flex; justify-content: space-between; gap: 8px; align-items: baseline; }
.home-bank-name { font-weight: 700; font-size: .92rem; }
.home-bank-kbmi { font-size: .7rem; color: var(--color-fg-muted); white-space: nowrap; }
.home-bank-assets { font-size: 1.05rem; font-variant-numeric: tabular-nums; }
.home-bank-meta { font-size: .74rem; color: var(--color-fg-muted); font-variant-numeric: tabular-nums; }

.letters { list-style: none; margin: 0; padding: 0; max-width: 46rem; }
.letter { padding: 18px 0; border-bottom: 1px solid var(--color-border-line); }
.letter-title { font-size: 1.15rem; font-weight: 700; color: var(--color-fg); text-decoration: none; }
.letter-title:hover { color: var(--note-blue); text-decoration: underline; }
.letter-sum { margin: 6px 0 0; color: var(--color-fg-muted); font-size: .9rem; line-height: 1.5; }

/* the banks list */
.home-table-wrap { overflow-x: auto; border: 1px solid var(--color-border-line); border-radius: var(--cds-radius); background: var(--color-panel); }
.home-table { width: 100%; border-collapse: collapse; font-size: .86rem; font-variant-numeric: tabular-nums; }
.home-table th { text-align: left; font-weight: 600; font-size: .74rem; color: var(--color-fg-muted); padding: 9px 10px; border-bottom: 1px solid var(--color-border-line); white-space: nowrap; vertical-align: bottom; }
.home-table th span { display: block; font-weight: 400; }
.home-table td { padding: 8px 10px; border-bottom: 1px solid var(--color-border-line); white-space: nowrap; }
.home-table tbody tr:last-child td { border-bottom: 0; }
.home-table tbody tr { cursor: pointer; }
.home-table tbody tr:hover { background: var(--note-tint); }
.home-table .num { text-align: right; }
.home-t-name a { color: var(--color-fg); font-weight: 650; text-decoration: none; }
.home-t-name a:hover { color: var(--note-blue); text-decoration: underline; }
.home-t-q { color: var(--color-fg-muted); }
.home-t-kbmi { display: block; font-size: .7rem; color: var(--color-fg-muted); font-weight: 400; }
.home-t-late { color: var(--color-warn); }
.home-t-go { text-align: right; }
.home-t-go a { color: var(--note-blue); text-decoration: none; font-size: 1rem; font-weight: 600; }
@media (max-width: 560px) { .home-t-q, .home-t-qh { display: none; } .home-table th, .home-table td { padding: 8px 7px; } }

/* the weekly letter list */
.home-letter-list { list-style: none; margin: 0; padding: 0; }
.home-letter-list li { padding: 10px 0; border-bottom: 1px solid var(--color-border-line); }
.home-letter-list a { color: var(--color-fg); text-decoration: none; font-size: .93rem; font-weight: 600; line-height: 1.35; }
.home-letter-list a:hover { color: var(--note-blue); text-decoration: underline; }
.home-letter-new { border-left: 3px solid var(--note-blue); padding-left: 12px !important; background: var(--note-tint); border-radius: 0 var(--cds-radius) var(--cds-radius) 0; }
.home-letter-new a { font-size: 1.02rem; }
.home-letter-list .home-letter-sum { margin: 4px 0 2px; font-size: .85rem; color: var(--color-fg-muted); }
.home-link { display: inline-block; margin-top: 10px; color: var(--note-blue); font-size: .85rem; font-weight: 600; text-decoration: none; }
.home-link:hover { text-decoration: underline; }

/* leaders and shares on the home page */
.home-more { display: inline-block; text-decoration: none; }
.home-leaders { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 9.5rem), 1fr)); gap: 10px; }
.home-lead { background: var(--color-panel); border: 1px solid var(--color-border-line); border-radius: var(--cds-radius); padding: 12px 14px; }
.home-lead h3 { margin: 0 0 8px; font-size: .78rem; font-weight: 600; color: var(--color-fg-muted); }
.home-lead ol { margin: 0; padding: 0; list-style: none; counter-reset: lead; }
.home-lead li { display: flex; justify-content: space-between; gap: 8px; padding: 4px 0; font-size: .86rem; counter-increment: lead; }
.home-lead li::before { content: counter(lead); color: var(--color-fg-muted); width: 1em; flex: none; }
.home-lead li a { color: var(--color-fg); text-decoration: none; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.home-lead li a:hover { color: var(--note-blue); text-decoration: underline; }
.home-lead .num { font-variant-numeric: tabular-nums; font-weight: 600; }
.home-t-index td { color: var(--color-fg-muted); font-style: italic; }
.home-t-index { cursor: default !important; }

/* the news page */
.news-tools { display: flex; flex-direction: column; gap: 10px; }
.news-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.news-q, .news-src { font: inherit; font-size: .86rem; padding: 7px 10px; border: 1px solid var(--color-border-line); border-radius: var(--cds-radius); background: var(--color-panel); color: var(--color-fg); }
.news-q { flex: 1 1 16rem; max-width: 26rem; }
.news-count { margin: 0; }
.news-page { max-width: 52rem; display: flex; flex-direction: column; gap: 22px; }
.news-day h2 { font-size: .8rem; text-transform: uppercase; letter-spacing: .05em; color: var(--color-fg-muted); margin: 0 0 2px; font-weight: 600; }

/* the right column runs to the bottom of the banks list: the shares table stretches its rows to fill */
@media (min-width: 901px) {
  .home-split { align-items: stretch; }
  /* whichever column is shorter stretches its table's rows, so both tables end level */
  .home-side > #home-shares-sec:not([hidden]), .home-main > .home-banks-sec { flex: 1; display: flex; flex-direction: column; }
  #home-shares-sec .home-table-wrap, .home-banks-sec .home-table-wrap { flex: 1; display: flex; }
  #home-shares-sec .home-table, .home-banks-sec .home-table { flex: 1; height: 100%; }
  .home-banks-sec > .home-note, #home-shares-note { min-height: 3em; }   /* same space under both tables, so their bottoms line up */
}
