/* Africa edition: counter-led layout, Pan-African accents, quiet data surfaces. */
:root {
  --paper: #eceeef;
  --ink: #181b19;
  --muted: #59615e;
  --line: #d3d8d5;
  --accent: #a92234;
  --wash: #f4f6f4;
  --green: #196447;
  --gold: #b98514;
}
.topbar {
  background: #111713;
  color: #fff;
  min-height: 76px;
  padding: 16px 26px;
  border: 0;
  border-top: 4px solid transparent;
  border-image: linear-gradient(
      90deg,
      #ba2439 0 33.3%,
      #e9b845 33.3% 66.6%,
      #20754d 66.6%
    )
    1;
  gap: 25px;
}
.brand {
  font:
    900 25px/1.15 Arial,
    Helvetica,
    sans-serif;
  letter-spacing: 1.4px;
}
.brand-debt {
  color: #e4b54c;
}
.topbar nav {
  gap: 19px;
}
.nav-button {
  color: #d2d8d4;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
  padding: 10px 0;
}
.nav-button.active,
.nav-button:hover {
  color: #edbc52;
}
.nav-button.active:after {
  bottom: -16px;
  height: 2px;
  background: #edbc52;
}
.edition {
  color: #bbc7bd;
  font-size: 10px;
}
.app-shell {
  display: block;
  max-width: 1180px;
  padding: 0 30px;
}
.country-toolbar {
  display: flex;
  align-items: center;
  gap: 25px;
  padding: 22px 0;
  border-bottom: 1px solid var(--line);
}
.country-picker {
  display: flex;
  align-items: center;
  gap: 15px;
}
.country-picker label {
  font-size: 10px;
  letter-spacing: 1.4px;
  font-weight: 700;
  color: var(--green);
}
.country-picker select {
  font-size: 15px;
  font-weight: 700;
  min-width: 200px;
  background: #fff;
}
.continent-note {
  font-size: 12px;
  color: var(--muted);
  margin-right: auto;
}
.country-toolbar .button {
  font-size: 11px;
  background: #fff;
}
.sidebar {
  position: static;
  width: auto;
  height: auto;
  min-height: 0;
  border: 1px solid var(--line);
  padding: 22px;
  background: #fff;
  margin: 16px 0 0;
}
.sidebar h2,
.sidebar-note {
  display: none;
}
.sidebar-heading {
  margin-bottom: 8px;
}
.sidebar .search-box {
  max-width: 480px;
}
.sidebar .region-filters {
  margin: 12px 0 16px;
}
.sidebar .country-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  overflow: auto;
  max-height: 260px;
  min-height: 0;
}
.sidebar .list-label {
  display: none;
}
.sidebar .country-option {
  border: 0;
  border-bottom: 1px solid var(--line);
  padding: 11px;
  min-width: 0;
  width: 100%;
}
.country-option.selected {
  background: var(--green);
  color: white;
}
.sidebar .list-name {
  white-space: normal;
}
main {
  padding: 24px 0 0;
  container-type: inline-size;
}
.country-sections {
  gap: 24px;
  margin-bottom: 20px;
}
.country-section-button {
  font-size: 12px;
  padding-bottom: 11px;
  color: var(--muted);
}
.country-section-button.active {
  color: var(--green);
  border-color: var(--green);
}
.breadcrumb {
  font-size: 10px;
  margin-bottom: 12px;
}
.page-heading {
  margin-bottom: 22px;
  align-items: center;
}
h1 {
  font:
    750 36px/1.1 Arial,
    Helvetica,
    sans-serif;
  letter-spacing: -1px;
}
.page-heading p {
  font-size: 12px;
  margin-top: 9px;
}
.country-code {
  background: var(--green);
  color: white;
  border: 0;
  font-weight: 700;
}
.clock-card {
  background: #141c17;
  color: white;
  border: 1px solid #263c2d;
  padding: 30px 38px 25px;
  border-radius: 2px;
  position: relative;
}
.clock-top {
  justify-content: center;
  position: relative;
  min-height: 38px;
}
.clock-label h2 {
  font-size: 12px;
  letter-spacing: 2px;
}
.clock-label .status-dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  background: #e6b64c;
  border-radius: 50%;
  margin-right: 10px;
}
.clock-label {
  display: flex;
  align-items: center;
}
.currency-switch {
  position: absolute;
  right: 0;
  top: 0;
  border-color: #536557;
}
.currency-switch button {
  font-size: 10px;
}
.currency-switch button[aria-pressed="true"] {
  background: #e2b34c;
  color: #172018;
}
.clock-amount {
  justify-content: center;
  margin: 22px 0 19px;
  gap: 14px;
}
.clock-amount > span:first-child {
  color: #e8bd61;
  font:
    bold 24px Arial,
    sans-serif;
}
.clock-amount > span:last-child {
  font-size: clamp(26px, 6.4cqw, 74px);
  font-weight: 750;
  letter-spacing: 0.01em;
}
.clock-amount.compact > span:last-child {
  font-size: clamp(22px, 5.1cqw, 60px);
}
.clock-under {
  justify-content: center;
  color: #c2cec5;
  flex-wrap: wrap;
  gap: 12px 22px;
  font-size: 12px;
}
.clock-card button:hover {
  color: #edbc52;
}
.clock-divider {
  background: #3e4c42;
  margin: 23px 0 20px;
}
.clock-small-label {
  color: #b8c6bb;
  font-size: 9px;
}
.clock-bottom strong {
  color: #e6b64c;
  font-size: 22px;
  font-weight: 600;
}
.clock-source {
  color: #c5d0c8;
  font-size: 11px;
}
.clock-source .text-button {
  color: white;
}
.estimate-note {
  max-width: none;
  margin: 12px 0 22px;
  font-size: 11px;
}
.metric-grid,
.activity-grid,
.fiscal-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  border: 0;
  margin: 0 0 20px;
}
.metric-card,
.metric-card:first-child,
.metric-card:last-child,
.metric-card:nth-child(n) {
  background: #fff;
  border: 1px solid var(--line);
  border-top: 3px solid var(--green);
  padding: 22px;
}
.metric-label {
  display: block;
  text-transform: uppercase;
  font-size: 10px;
  letter-spacing: 0.55px;
  line-height: 1.6;
}
.metric-value {
  font-size: 29px;
  font-weight: 750;
  letter-spacing: -0.8px;
  line-height: 1.2;
  margin: 14px 0 10px;
  color: var(--accent);
}
.metric-note {
  display: block;
  font-size: 11px;
  line-height: 1.7;
  color: var(--muted);
}
.activity-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.activity-grid .metric-card {
  border-top: 1px solid var(--line);
}
.activity-grid .metric-card:nth-child(2) .metric-value {
  color: #9a6410;
}
.data-link {
  font-size: 20px;
  color: var(--green);
}
.data-link button {
  padding: 0;
  text-align: left;
}
.panel {
  background: #fff;
  border: 1px solid var(--line);
  padding: 25px;
}
.panel h2,
.chamber-record h2,
.fund-record h2,
.fund-reading h2,
.method-sections h2,
.leader-row h3 {
  font-family: Arial, Helvetica, sans-serif;
  font-weight: 700;
  font-size: 23px;
  letter-spacing: -0.5px;
}
.household-panel {
  display: grid;
  grid-template-columns: 1.7fr 1fr 1fr;
  gap: 30px;
  align-items: center;
  margin-bottom: 22px;
}
.household-panel h2 {
  font-size: 18px;
  margin: 9px 0;
}
.household-panel p {
  font-size: 11px;
  line-height: 1.7;
  color: var(--muted);
  margin-bottom: 0;
}
.household-panel label {
  font-size: 12px;
  font-weight: 700;
}
.household-panel input {
  display: block;
  width: 100%;
  margin: 16px 0 0;
  accent-color: var(--green);
}
.household-panel strong {
  display: block;
  font-size: 27px;
  color: var(--green);
  margin-bottom: 6px;
  overflow-wrap: anywhere;
}
.detail-grid {
  grid-template-columns: 1.65fr 1fr;
  gap: 20px;
}
.context-panel {
  padding: 25px;
  display: flex;
  border: 1px solid var(--line);
}
.context-stat strong {
  font:
    700 40px Arial,
    sans-serif;
  color: var(--green);
}
.context-panel > p {
  font-size: 12px;
}
.source-strip {
  border-top: 1px solid var(--line);
}
.fiscal-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 22px;
}
.fiscal-card .metric-value {
  color: var(--green);
  font-size: 34px;
}
.indicator-source {
  display: block;
  font-size: 10px;
  line-height: 1.7;
  margin-top: 20px;
  padding-top: 13px;
  border-top: 1px solid var(--line);
}
.indicator-source small {
  display: block;
  color: var(--muted);
  margin-top: 4px;
  overflow-wrap: anywhere;
}
.annual-panel {
  margin: 22px 0;
}
.annual-panel h2 {
  margin: 8px 0 22px;
}
.compare-toolbar {
  border-color: var(--line);
}
.comparison-table {
  background: #fff;
}
.comparison-table th {
  color: #35463b;
}
.comparison-table td:first-child {
  white-space: normal;
  min-width: 180px;
}
.comparison-table td {
  font-size: 12px;
}
.comparison-table a {
  line-height: 1.6;
}
.creditor-table {
  max-height: 450px;
}
.creditor-table th {
  position: sticky;
  top: 0;
}
.creditor-bar {
  margin: 24px 0;
}
.creditor-bar > div:first-child {
  display: flex;
  justify-content: space-between;
  gap: 15px;
  font-size: 13px;
}
.creditor-bar small {
  color: var(--muted);
  margin-left: 7px;
  font-weight: 400;
}
.bar-track {
  height: 10px;
  background: #edf0ed;
  margin-top: 12px;
}
.bar-track span {
  display: block;
  height: 100%;
  background: var(--green);
}
.creditor-bar:nth-child(2) .bar-track span {
  background: var(--gold);
}
.creditor-bar:nth-child(3) .bar-track span {
  background: var(--accent);
}
.data-empty {
  padding: 22px;
  background: var(--wash);
  color: var(--muted);
  font-size: 14px;
  line-height: 1.7;
}
.chamber-record,
.fund-record {
  padding: 25px;
  background: white;
  border: 1px solid var(--line);
  border-top: 3px solid var(--green);
}
.representation-counts dd,
.budget-amount {
  font-family: Arial, Helvetica, sans-serif;
  font-weight: 700;
  color: var(--green);
}
.method-sections article {
  background: #fff;
  padding: 26px;
  border: 1px solid var(--line);
  margin-bottom: 16px;
}
.method-intro {
  font:
    600 23px/1.5 Arial,
    sans-serif;
  border-color: var(--line);
}
@media (min-width: 761px) {
  #country-sections {
    display: none;
  }
}
@media (max-width: 1250px) {
  .topbar {
    flex-wrap: wrap;
    gap: 12px 24px;
  }
  .topbar nav {
    margin-left: auto;
    gap: 15px;
  }
  .edition {
    display: none;
  }
  .brand {
    font-size: 22px;
  }
}
@media (max-width: 1000px) {
  .topbar nav {
    width: 100%;
    margin: 0;
    overflow-x: auto;
  }
  .nav-button.active:after {
    bottom: 0;
  }
  .continent-note {
    display: none;
  }
  .country-toolbar {
    justify-content: space-between;
  }
  .clock-top {
    justify-content: flex-start;
  }
  .household-panel {
    grid-template-columns: 1.5fr 1fr;
  }
  .household-panel > div:last-child {
    grid-column: 2;
    grid-row: 1;
  }
  .household-panel label {
    grid-column: 1/-1;
  }
  .detail-grid {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 760px) {
  .topbar {
    padding: 18px 18px 8px;
    gap: 10px;
  }
  .brand {
    font-size: 22px;
    letter-spacing: 1px;
  }
  .topbar nav {
    justify-content: flex-start;
    gap: 22px;
    width: 100%;
  }
  .nav-button {
    font-size: 12px;
    min-height: 40px;
    padding: 10px 0;
  }
  .app-shell {
    padding: 0 16px;
  }
  .country-toolbar {
    gap: 12px;
    align-items: flex-end;
    padding: 18px 0;
  }
  .country-picker {
    display: block;
    min-width: 0;
    flex: 1;
  }
  .country-picker label {
    display: block;
    margin-bottom: 8px;
    font-size: 9px;
  }
  .country-picker select {
    min-width: 0;
    width: 100%;
    font-size: 14px;
  }
  .country-toolbar .button {
    font-size: 10px;
    max-width: 115px;
    padding: 8px;
    line-height: 1.5;
  }
  .sidebar {
    padding: 16px;
  }
  .sidebar .country-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    max-height: 260px;
  }
  .sidebar .country-option {
    display: grid;
    grid-template-columns: 20px 1fr;
    min-width: 0;
  }
  .sidebar .list-name {
    font-size: 11px;
  }
  .sidebar .region-filters {
    gap: 15px;
  }
  main {
    padding-top: 20px;
  }
  .country-sections {
    display: none;
  }
  h1 {
    font-size: 30px;
  }
  .breadcrumb {
    font-size: 9px;
  }
  .page-heading {
    gap: 12px;
    margin-bottom: 20px;
  }
  .page-heading p {
    font-size: 11px;
  }
  #share-country {
    font-size: 10px;
    padding: 7px;
  }
  .clock-card {
    padding: 20px 16px;
  }
  .clock-top {
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
  }
  .clock-label h2 {
    font-size: 10px;
    letter-spacing: 1.1px;
  }
  .currency-switch {
    position: static;
  }
  .clock-amount {
    gap: 8px;
    margin: 23px 0 18px;
  }
  .clock-amount > span:first-child {
    font-size: 14px;
  }
  .clock-amount > span:last-child {
    font-size: 6.7cqw;
    letter-spacing: -0.025em;
  }
  .clock-amount.compact > span:last-child {
    font-size: 5.25cqw;
  }
  .clock-under {
    font-size: 10px;
    gap: 8px;
  }
  .clock-bottom {
    gap: 15px;
  }
  .clock-bottom strong {
    font-size: 17px;
  }
  .clock-source {
    font-size: 9px;
    max-width: 49%;
  }
  .clock-small-label {
    font-size: 8px;
  }
  .clock-card.is-unavailable .clock-amount > span:last-child {
    font:
      700 25px Arial,
      sans-serif;
  }
  .metric-grid,
  .activity-grid,
  .fiscal-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 16px;
  }
  .metric-card:nth-child(n) {
    padding: 16px;
  }
  .metric-label {
    font-size: 9px;
  }
  .metric-value {
    font-size: 25px;
    letter-spacing: -0.7px;
    margin: 12px 0 8px;
  }
  .metric-note {
    font-size: 10px;
  }
  .activity-grid .metric-card:last-child {
    grid-column: 1/-1;
  }
  .data-link {
    font-size: 19px;
  }
  .household-panel {
    gap: 20px;
    padding: 18px;
    grid-template-columns: 1.4fr 1fr;
  }
  .household-panel h2 {
    font-size: 17px;
  }
  .household-panel strong {
    font-size: 22px;
  }
  .panel {
    padding: 18px;
  }
  .panel h2 {
    font-size: 21px;
  }
  .context-panel {
    padding: 18px;
  }
  .annual-panel {
    margin: 16px 0;
  }
  .fiscal-card .metric-value {
    font-size: 26px;
  }
  .indicator-source {
    font-size: 9px;
  }
  .debt-summary {
    grid-template-columns: 1fr;
  }
  .debt-summary .metric-value {
    font-size: 30px;
  }
  .creditor-bar > div:first-child {
    font-size: 11px;
  }
  .creditor-bar strong {
    text-align: right;
  }
  .comparison-table td,
  .comparison-table button {
    font-size: 11px;
  }
  .comparison-table td:first-child {
    min-width: 155px;
  }
  .method-sections article {
    padding: 18px;
    gap: 14px;
  }
  .method-number {
    font-size: 10px;
  }
  .chamber-record,
  .fund-record {
    padding: 18px;
  }
  .record-links {
    font-size: 12px;
  }
  .comparison-note {
    font-size: 11px;
  }
}
@media (max-width: 380px) {
  .page-heading {
    flex-wrap: wrap;
  }
  .fiscal-grid {
    grid-template-columns: 1fr;
  }
  .household-panel {
    grid-template-columns: 1fr;
  }
  .household-panel > div:last-child {
    grid-column: 1;
    grid-row: auto;
  }
}
/* Keep currency amounts intact in narrow cards, including long local-unit labels. */
.metric-card {
  container-type: inline-size;
}
.metric-value {
  font-size: clamp(18px, 13cqw, 29px);
  overflow-wrap: normal;
}
.fiscal-card .metric-value {
  font-size: clamp(18px, 14cqw, 34px);
}
.data-link {
  font-size: 20px;
}
