/* Oficinapp — Inicio (tarjetas de dinero y actividad), Resumen y Cobros. */

.rsum { display: grid; gap: 16px; }
.rsum__top { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between; }
.rsum__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; align-items: start; }
@media (max-width: 900px) { .rsum__grid { grid-template-columns: minmax(0, 1fr); } }

/* Tarjeta azul marino con cifra grande */
.rhero { display: flex; justify-content: space-between; gap: 16px; background: var(--navy-900); color: #fff; border-radius: var(--radius-xl); padding: 22px 24px; text-decoration: none; }
a.rhero:hover { box-shadow: var(--shadow-elevated); }
.rhero--col { flex-direction: column; }
.rhero__row { display: flex; justify-content: space-between; gap: 16px; }
.rhero__label { color: #D5DEEA; font-size: 15px; font-weight: 500; }
.rhero__value { font-size: 38px; font-weight: 800; letter-spacing: -1px; line-height: 1.15; font-variant-numeric: tabular-nums; }
.rhero__value.is-neg { color: #FF8A8A; }
.rhero__sub { color: #D5DEEA; font-size: 13px; }
.rhero__delta { display: flex; align-items: center; gap: 4px; margin-top: 8px; font-weight: 700; color: #D5DEEA; }
.rhero__delta span { font-weight: 400; color: #D5DEEA; }
.rhero__delta.is-up { color: #4ADE80; }
.rhero__delta.is-down { color: #FF8A8A; }
.rhero__icon { color: #fff; opacity: .9; flex: none; align-self: flex-start; }
.rhero__split { display: flex; align-items: center; gap: 24px; border-top: 1px solid rgba(255,255,255,.15); padding-top: 14px; }
.rhero__overdue { color: #FF6B6B; font-size: 22px; font-weight: 800; font-variant-numeric: tabular-nums; }
.rbar { flex: 1; height: 10px; border-radius: 999px; background: rgba(255,255,255,.18); overflow: hidden; }
.rbar span { display: block; height: 100%; background: #F04438; border-radius: 999px; min-width: 0; }
.rspark { flex: none; align-self: center; }

/* Filas Ingresos / Gastos / IVA */
.rrows { padding: 8px 20px 16px; }
.rrow { display: flex; align-items: center; gap: 14px; padding: 14px 0; border-top: 1px solid var(--gray-100); color: inherit; text-decoration: none; }
.rrow:first-child { border-top: 0; }
.rrow__icon { width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; color: #fff; flex: none; }
.rrow__label { flex: 1; min-width: 0; font-size: 15px; font-weight: 500; color: var(--navy-900); }
.rrow__label small { display: block; font-size: 12px; font-weight: 400; color: var(--gray-500); }
.rrow__value { font-size: 18px; font-weight: 700; color: var(--navy-900); font-variant-numeric: tabular-nums; white-space: nowrap; }

/* Gráficos */
.rchart { width: 100%; height: auto; display: block; }
.rchart__axis, .rchart__label { font: 12px Inter, system-ui, sans-serif; fill: var(--gray-500); }
.rlegend { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--gray-500); }
.rlegend i { width: 10px; height: 10px; border-radius: 50%; display: inline-block; margin-left: 8px; }
.rcat { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
.rdonut { width: 180px; height: 180px; flex: none; }
.rdonut__value { font: 700 17px Inter, system-ui, sans-serif; fill: var(--navy-900); }
.rdonut__sub { font: 12px Inter, system-ui, sans-serif; fill: var(--gray-500); }
.rcat__list { list-style: none; margin: 0; padding: 0; flex: 1; min-width: 220px; display: grid; gap: 10px; }
.rcat__list li { display: grid; grid-template-columns: 12px minmax(0, 1fr) auto 44px; gap: 10px; align-items: center; font-size: 13px; }
.rcat__list i { width: 12px; height: 12px; border-radius: 50%; }
.rcat__name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--navy-900); }
.rcat__list .num { text-align: right; }

/* Cobros */
.rdot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--orange-500); vertical-align: 2px; }
.rinv { display: grid; gap: 12px; }
.rinv__card { display: flex; justify-content: space-between; gap: 12px; padding: 16px 20px; }
.rinv__main { display: flex; flex-direction: column; gap: 2px; min-width: 0; color: inherit; text-decoration: none; flex: 1; }
.rinv__num { font-weight: 700; color: var(--navy-900); font-size: 16px; }
.rinv__cust { color: var(--gray-500); }
.rinv__amount { font-size: 20px; font-weight: 800; color: var(--navy-900); font-variant-numeric: tabular-nums; }
.rinv__due { display: inline-flex; align-items: center; gap: 6px; color: var(--gray-500); font-size: 13px; }
.rinv__due.is-late { color: var(--danger); }
.rinv__side { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; flex: none; }
.rinv__remind { border-radius: 999px; }
.rvf { display: inline-flex; align-items: center; gap: 4px; color: var(--success); font-weight: 600; font-size: 13px; }

/* Inicio (panel web) */
.home-money { display: grid; grid-template-columns: minmax(0, 2fr) repeat(3, minmax(0, 1fr)); gap: 16px; margin-bottom: 16px; }
@media (max-width: 1100px) { .home-money { grid-template-columns: repeat(2, minmax(0, 1fr)); } .home-money .rhero { grid-column: 1 / -1; } }
@media (max-width: 560px) { .home-money { grid-template-columns: minmax(0, 1fr); } }
.home-money .kpi__value { font-size: 24px; white-space: nowrap; }
.home-money .kpi__delta.is-up { color: var(--success); font-weight: 600; }
.home-money .kpi__delta.is-down { color: var(--danger); font-weight: 600; }
.ract__icon { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; flex: none; }
