.ccmax-cache-cell { max-width: 230px; min-width: 0; text-align: right; font-size: 11px; line-height: 1.4; font-variant-numeric: tabular-nums; }
.ccmax-cache-items { display: grid; gap: 3px; min-width: 0; }
.ccmax-cache-item { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 2px 7px; min-width: 0; }
.ccmax-cache-tokens { display: inline-flex; flex-wrap: nowrap; justify-content: space-between; gap: 2px 5px; min-width: 0; }
.ccmax-cache-label-long { display: none; }
.ccmax-cache-label-short { display: inline; }
.ccmax-cache-label, .ccmax-cache-read, .ccmax-cache-note, .ccmax-cache-unknown { color: var(--muted-foreground); }
.ccmax-cache-points, .ccmax-cache-tokens > span:last-child { overflow-wrap: anywhere; }
.ccmax-cache-read { margin-top: 3px; }
.ccmax-cache-note { font-size: 11px; line-height: 1.5; margin-top: 5px; }
.ccmax-billing-modal { width: min(860px, calc(100vw - 24px)); max-width: 860px; max-height: 88dvh; overflow: hidden; background: var(--background); z-index: 80; }
.ccmax-billing-scroll { overflow-y: auto; max-height: 70dvh; min-width: 0; }
.ccmax-billing-section { border: 1px solid var(--border); border-radius: 10px; padding: 12px; margin-top: 12px; }
.ccmax-billing-section:first-child { margin-top: 0; }
.ccmax-billing-section h4 { font-weight: 600; font-size: 13px; margin-bottom: 9px; }
.ccmax-billing-row { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; font-size: 12px; line-height: 1.6; margin: 3px 0; }
.ccmax-billing-row > span:first-child { color: var(--muted-foreground); }
.ccmax-billing-row > span:last-child { text-align: right; overflow-wrap: anywhere; }
.ccmax-billing-section .ccmax-cache-cell { max-width: none; font-size: 12px; margin-top: 9px; }
.ccmax-billing-section .ccmax-cache-items { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
.ccmax-billing-section .ccmax-cache-item { display: grid; border: 1px solid var(--border); border-radius: 8px; padding: 9px; }
.ccmax-billing-section .ccmax-cache-label-long { display: inline; }
.ccmax-billing-section .ccmax-cache-label-short { display: none; }
.ccmax-billing-breakdown { width: 100%; border-collapse: collapse; font-size: 12px; font-variant-numeric: tabular-nums; margin-top: 10px; }
.ccmax-billing-breakdown th, .ccmax-billing-breakdown td { padding: 9px 8px; border-bottom: 1px solid var(--border); text-align: right; overflow-wrap: anywhere; }
.ccmax-billing-breakdown th:first-child { text-align: left; }
.ccmax-billing-breakdown thead { color: var(--muted-foreground); }
.ccmax-billing-detail-button { margin-top: 4px; font-size: 11px; text-decoration: underline; text-underline-offset: 3px; }
.ccmax-cache-net { padding-top: 8px; margin-top: 8px; border-top: 1px solid var(--border); }
.ccmax-cache-net.is-positive strong { color: #22c55e; }
.ccmax-cache-net.is-negative strong { color: #f59e0b; }
.ccmax-cache-savings-summary { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 14px; padding: 10px 12px; margin: 10px 0; border: 1px solid var(--border); border-radius: 8px; font-size: 12px; font-variant-numeric: tabular-nums; }
.ccmax-cache-savings-summary > span { color: var(--muted-foreground); font-size: 11px; }
@media (max-width: 720px) {
  td:has(> .ccmax-cache-cell) { grid-column: 1 / -1; }
  .ccmax-cache-cell { max-width: none; text-align: left; }
  .ccmax-cache-items { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .ccmax-cache-item { display: grid; align-items: start; gap: 4px; border: 1px solid var(--border); border-radius: 8px; padding: 8px; }
  .ccmax-cache-tokens { display: grid; gap: 3px; }
  .ccmax-cache-label-long { display: inline; }
  .ccmax-cache-label-short { display: none; }
  .ccmax-billing-modal { padding: 16px; }
  .ccmax-billing-breakdown thead { display: none; }
  .ccmax-billing-breakdown tbody { display: grid; gap: 8px; }
  .ccmax-billing-breakdown tr { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 6px; border: 1px solid var(--border); border-radius: 8px; padding: 10px; }
  .ccmax-billing-breakdown th, .ccmax-billing-breakdown td { border: 0; padding: 0; text-align: left; }
  .ccmax-billing-breakdown th { grid-column: 1 / -1; }
  .ccmax-billing-breakdown td::before { content: attr(data-label); display: block; color: var(--muted-foreground); font-size: 10px; }
}
