@media (max-width: 760px) {
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-table tbody td:is([data-field="country"],[data-field="tax_percent"],[data-field="tax_amount"],[data-field="net_dividend"],[data-field="withdraw"]) { display: none !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividend-mobile-metadata {
    grid-column: 1 / -1; grid-row: 2; display: flex; flex-wrap: wrap; align-items: center; gap: 4px 0; min-width: 0; color: #abc6d7; font-size: 8px; line-height: 16px;
  }
  .dividend-mobile-metadata > * { padding: 0 5px; border-left: 1px solid #244552; white-space: nowrap; }
  .dividend-mobile-metadata > :first-child { padding-left: 0; border-left: 0; }
  .dividend-mobile-metadata .dividend-mobile-net { color: #00dce8; }
  .dividend-mobile-metadata label { display: inline-flex; align-items: center; gap: 4px; cursor: pointer; }
  .dividend-mobile-metadata input { appearance: auto !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section,
  html body #dividends-section#dividends-section#dividends-section#dividends-section :is(.dividends-page-actions,.dividends-page-header,.dividends-history-card,.dividends-table-shell,#dividends-monthly-table,#dividends-monthly-table-body) {
    width: 100% !important; max-width: 100% !important; min-width: 0 !important; box-sizing: border-box !important; margin-inline: 0 !important;
  }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividends-chart-controls .dividends-chart-period-switch {
    display: grid !important; grid-template-columns: repeat(3,minmax(0,1fr)) !important;
  }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividends-chart-controls .chart-type-switch {
    display: grid !important; grid-template-columns: repeat(2,minmax(0,1fr)) !important;
  }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .allocation-switch {
    height: auto !important; padding: 0 !important; overflow: visible !important; min-width: 0 !important;
  }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .allocation-option {
    width: 100% !important; min-width: 0 !important; padding: 0 3px !important; margin: 0 !important; box-sizing: border-box !important;
  }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .allocation-option .option-label { font-size: inherit !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividends-switch {
    display: grid !important; grid-template-columns: repeat(2,minmax(0,1fr)) !important;
  }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .switch-glow { display: none !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-chart-filter select { max-width: 60px !important; box-sizing: border-box !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-table td::after { border: 0 !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-table input[type="checkbox"] { width: 16px !important; height: 16px !important; margin: 0 !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-table .action-menu-toggle {
    width: 25px !important; min-width: 25px !important; height: 31px !important; padding: 0 !important; border: 0 !important; background: transparent !important;
  }
  html body #dividends-section#dividends-section#dividends-section#dividends-section.dividends-page.active { display: flex !important; flex-direction: column !important; gap: 10px !important; min-width: 0 !important; padding: 10px !important; background: #031923 !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividends-summary-strip { display: none !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividends-chart-card { order: 1 !important; padding: 12px !important; border: 1px solid #18516a !important; border-radius: 9px !important; background: linear-gradient(145deg,#062332,#031923) !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividends-chart-card-header { display: grid !important; grid-template-columns: minmax(0,1fr) !important; gap: 0 !important; align-items: center !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividends-chart-card-header h2 { display: none !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividends-chart-controls { display: grid !important; grid-column: 1 / -1 !important; grid-template-columns: minmax(0,1.7fr) minmax(0,1fr) !important; gap: 6px !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #monthly-broker-filter-wrap { display: block !important; min-width: 0 !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #monthly-broker-filter { width: 100% !important; min-height: 32px !important; padding: 0 7px !important; border: 1px solid #255066 !important; border-radius: 6px !important; background: #0a2532 !important; color: #dbeaf0 !important; font-size: 11px !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividends-chart-period-switch { grid-column: 1 !important; grid-row: 1 !important; min-height: 32px !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .chart-type-switch { grid-column: 2 !important; grid-row: 1 !important; min-height: 32px !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividends-chart-controls .allocation-option { min-height: 32px !important; font-size: 11px !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividends-chart-controls .allocation-option.active { border: 1px solid #00dce8 !important; border-radius: 6px !important; color: #00dce8 !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividends-chart-canvas-wrap { height: 185px !important; min-height: 185px !important; max-height: 185px !important; margin-top: 8px !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividendsChart { max-height: 185px !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividends-page-header--actions-only { order: 2 !important; margin: 0 !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividends-page-action-row { display: grid !important; grid-template-columns: repeat(2,minmax(0,1fr)) !important; grid-template-rows: auto auto auto !important; gap: 6px !important; align-items: center !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividends-page-action-row > * { min-width: 0 !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-chart-filter { grid-column: 1 !important; grid-row: 1 !important; display: flex !important; gap: 4px !important; align-items: center !important; width: 100% !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-chart-filter label { white-space: nowrap !important; font-size: 10px !important; color: #c2d5e2 !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-show-above-select { min-width: 0 !important; width: 100% !important; height: 31px !important; padding: 0 3px !important; border: 1px solid #28536a !important; border-radius: 6px !important; background: #092631 !important; color: #e5f1f5 !important; font-size: 11px !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #monthly-broker-filter-wrap { grid-column: 2 !important; grid-row: 1 !important; width: 100% !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #monthly-broker-filter { width: 100% !important; height: 31px !important; min-height: 31px !important; padding: 0 20px 0 6px !important; font-size: 11px !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #add-dividend-import { grid-column: 1 !important; grid-row: 2 !important; height: 31px !important; padding: 0 4px !important; border: 1px solid #00dce8 !important; border-radius: 6px !important; color: #00dce8 !important; font-size: 11px !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #add-dividend-btn { grid-column: 2 !important; grid-row: 2 !important; height: 31px !important; padding: 0 4px !important; border-radius: 6px !important; font-size: 11px !important; white-space: nowrap !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividends-switch { grid-column: 1 / -1 !important; grid-row: 3 !important; width: 100% !important; min-height: 33px !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividends-switch .allocation-option { min-height: 33px !important; font-size: 12px !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividends-switch .allocation-option.active { border: 1px solid #00dce8 !important; border-radius: 6px !important; color: #00dce8 !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividends-history-card { order: 3 !important; padding: 0 !important; border: 0 !important; background: transparent !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividends-table-shell { width: 100% !important; max-width: 100% !important; overflow: visible !important; border: 0 !important; background: transparent !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-table { display: block !important; width: 100% !important; min-width: 0 !important; background: transparent !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-table colgroup,
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-table thead { display: none !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-table tbody { display: flex !important; flex-direction: column !important; gap: 7px !important; width: 100% !important; background: transparent !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-table tbody tr { display: grid !important; grid-template-columns: 21px 75px minmax(0,1fr) auto 25px !important; grid-template-rows: 31px auto !important; align-items: center !important; gap: 2px 6px !important; width: 100% !important; min-width: 0 !important; min-height: 62px !important; padding: 7px 8px !important; box-sizing: border-box !important; border: 1px solid #205064 !important; border-radius: 8px !important; background: #051e2b !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-table tbody td { display: block !important; min-width: 0 !important; width: auto !important; padding: 0 !important; border: 0 !important; background: transparent !important; color: #dce9f0 !important; font-size: 11px !important; white-space: nowrap !important; overflow: hidden !important; text-overflow: ellipsis !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-table tbody td.select-td { grid-column: 1 !important; grid-row: 1 !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-table tbody td[data-field="nr"] { display: none !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-table tbody td[data-field="date"] { grid-column: 2 !important; grid-row: 1 !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-table tbody td[data-field="symbol"] { grid-column: 3 !important; grid-row: 1 !important; font-size: 14px !important; font-weight: 750 !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-table tbody td[data-field="gross_dividend"] { grid-column: 4 !important; grid-row: 1 !important; text-align: right !important; color: #00dce8 !important; font-size: 14px !important; font-weight: 800 !important; overflow: visible !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-table tbody td[data-field="gross_dividend"]::after { content: ' ' attr(data-mobile-currency); margin-left: 4px; font-size: 10px; font-weight: 500; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-table tbody td[data-field="currency"] { display: none !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-table tbody td.action-buttons { grid-column: 5 !important; grid-row: 1 !important; overflow: visible !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-table tbody td[data-field="country"] { grid-column: 1 / 3 !important; grid-row: 2 !important; color: #abc6d7 !important; font-size: 10px !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-table tbody td[data-field="country"]::before { content: attr(data-mobile-flag) ' '; font-size: 16px; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-table tbody td[data-field="tax_percent"] { grid-column: 3 !important; grid-row: 2 !important; font-size: 10px !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-table tbody td[data-field="tax_percent"]::before { content: 'Tax '; color: #a5bfd0; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-table tbody td[data-field="tax_amount"] { display: none !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-table tbody td[data-field="net_dividend"] { grid-column: 4 !important; grid-row: 2 !important; color: #00dce8 !important; text-align: right !important; font-size: 10px !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-table tbody td[data-field="net_dividend"]::before { content: 'Net '; color: #abc6d7; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-table tbody td[data-field="withdraw"] { grid-column: 5 !important; grid-row: 2 !important; overflow: visible !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-table tbody tr:has(input:not([type="checkbox"]),select) { display: table-row !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-table tbody tr:has(.action-menu-panel.open) { z-index: 10 !important; position: relative !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #monthly-pagination-wrapper { order: 4 !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section.annual-view #dividends-monthly-table { display: none !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section.annual-view #dividends-monthly-chart-filter { display: none !important; }
}
.dividend-mobile-metadata { display: none; }

@media (max-width: 760px) {
  /* Reference-style single toolbar row: Show above, broker, import, add. */
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividends-page-action-row {
    display: grid !important;
    grid-template-columns: minmax(0, 1.05fr) minmax(52px, .72fr) minmax(0, 1.35fr) minmax(0, .9fr) minmax(0, 1.28fr) !important;
    grid-template-rows: 38px 38px !important;
    gap: 6px !important;
    align-items: stretch !important;
  }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-chart-filter {
    display: contents !important;
  }
  html body #dividends-section#dividends-section#dividends-section#dividends-section.annual-view #dividends-monthly-chart-filter { display: none !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-chart-filter label {
    grid-column: 1 !important;
    grid-row: 1 !important;
    align-self: center !important;
    overflow: hidden !important;
    font-size: 10px !important;
    text-overflow: clip !important;
  }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-show-above-select {
    grid-column: 2 !important;
    grid-row: 1 !important;
    min-width: 0 !important;
    width: 100% !important;
    height: 38px !important;
    padding: 0 2px !important;
    font-size: 12px !important;
  }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #monthly-broker-filter-wrap {
    grid-column: 3 !important;
    grid-row: 1 !important;
    width: 100% !important;
    min-width: 0 !important;
  }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #monthly-broker-filter {
    height: 38px !important;
    min-height: 38px !important;
    padding: 0 15px 0 6px !important;
    font-size: 12px !important;
  }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #add-dividend-import {
    grid-column: 4 !important;
    grid-row: 1 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 3px !important;
    width: 100% !important;
    height: 38px !important;
    min-width: 0 !important;
    padding: 0 3px !important;
    font-size: 12px !important;
  }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #add-dividend-import svg { width: 13px !important; height: 13px !important; flex: 0 0 13px !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #add-dividend-btn {
    grid-column: 5 !important;
    grid-row: 1 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 3px !important;
    width: 100% !important;
    height: 38px !important;
    min-width: 0 !important;
    padding: 0 3px !important;
    font-size: 12px !important;
  }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividends-page-action-row .dividends-switch {
    grid-column: 1 / -1 !important;
    grid-row: 2 !important;
    min-height: 38px !important;
    height: 38px !important;
  }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividends-page-action-row .dividends-switch .allocation-option { min-height: 38px !important; font-size: 13px !important; }

  /* Keep all dividend detail fields in the second, aligned row of each card. */
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividend-mobile-metadata {
    display: grid !important;
    grid-template-columns: minmax(0, 1.12fr) minmax(0, .55fr) minmax(0, 1fr) minmax(0, 1.12fr) minmax(0, .9fr) !important;
    align-items: center !important;
    gap: 0 !important;
    overflow: hidden !important;
    color: #526f8a !important;
    min-height: 34px !important;
    font-size: 10px !important;
    line-height: 1.2 !important;
  }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividend-mobile-metadata > * {
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    min-width: 0 !important;
    height: 100% !important;
    padding: 0 4px !important;
    border-left: 1px solid #d7e6ef !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividend-mobile-metadata > :first-child { padding-left: 0 !important; border-left: 0 !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividend-mobile-metadata small { color: #607c99 !important; font-size: 10px !important; line-height: 1.15 !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividend-mobile-metadata strong { color: #173353 !important; font-size: 12px !important; font-weight: 700 !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividend-mobile-country { display: block !important; align-content: center !important; font-size: 11px !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividend-mobile-net strong { color: #008f80 !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividend-mobile-withdraw { position: relative !important; flex-direction: row !important; align-items: center !important; gap: 4px !important; font-size: 10px !important; cursor: pointer !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividend-mobile-withdraw input { position: absolute !important; width: 1px !important; height: 1px !important; margin: 0 !important; opacity: 0 !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividend-mobile-withdraw-switch { position: relative !important; display: inline-block !important; flex: 0 0 27px !important; width: 27px !important; height: 16px !important; border-radius: 999px !important; background: #8797a5 !important; transition: background .16s ease !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividend-mobile-withdraw-switch::after { content: ""; position: absolute; top: 2px; left: 2px; width: 12px; height: 12px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(0,0,0,.2); transition: transform .16s ease; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividend-mobile-withdraw input:checked + .dividend-mobile-withdraw-switch { background: #00a99e !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividend-mobile-withdraw input:checked + .dividend-mobile-withdraw-switch::after { transform: translateX(11px); }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividend-mobile-withdraw input:focus-visible + .dividend-mobile-withdraw-switch { outline: 2px solid #008fbd; outline-offset: 2px; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section #dividends-monthly-table tbody tr { grid-template-rows: 36px 40px !important; min-height: 82px !important; padding: 6px 8px !important; }
}

@media (max-width: 380px) {
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividend-mobile-metadata { grid-template-columns: minmax(0,1.05fr) minmax(0,.5fr) minmax(0,.95fr) minmax(0,1fr) minmax(0,.82fr) !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividend-mobile-metadata strong { font-size: 11px !important; }
  html body #dividends-section#dividends-section#dividends-section#dividends-section .dividend-mobile-metadata small { font-size: 9px !important; }
}
