/* Hamburgos Finanças — v1.22.0
   Consolidação visual/responsiva.
   Esta folha é carregada por último e usa o escopo .hf-v122 para eliminar
   conflitos dos patches móveis anteriores sem alterar as regras financeiras. */

/* =========================================================
   Componente novo: status do mês (sem herança dos patches antigos)
   ========================================================= */
.hf-v122 .hf-month-status{
  --hf-status-color:#0f766e;
  --hf-status-bg:#eaf7f5;
  --hf-status-border:#cde7e2;
  display:inline-flex;
  align-items:center;
  justify-content:flex-start;
  gap:8px;
  inline-size:max-content;
  max-inline-size:100%;
  min-inline-size:0;
  margin:0;
  padding:7px 12px 7px 8px;
  border:1px solid var(--hf-status-border);
  border-radius:999px;
  color:var(--hf-status-color);
  background:var(--hf-status-bg);
  box-sizing:border-box;
  white-space:nowrap;
  vertical-align:middle;
}
.hf-v122 .hf-month-status.tone-empty{--hf-status-color:#0f7d75;--hf-status-bg:#edf8f6;--hf-status-border:#d4e9e5}
.hf-v122 .hf-month-status.tone-positive{--hf-status-color:#157b4b;--hf-status-bg:#edf9f2;--hf-status-border:#caead8}
.hf-v122 .hf-month-status.tone-negative{--hf-status-color:#bd4141;--hf-status-bg:#fff1f1;--hf-status-border:#f1cccc}
.hf-v122 .hf-month-status.tone-warning{--hf-status-color:#946300;--hf-status-bg:#fff7e5;--hf-status-border:#ead89e}
.hf-v122 .hf-month-status.tone-neutral{--hf-status-color:#0f766e;--hf-status-bg:#eaf7f5;--hf-status-border:#cde7e2}
.hf-v122 .hf-month-status-icon{
  display:grid;
  place-items:center;
  flex:0 0 22px;
  width:22px;
  height:22px;
  border-radius:50%;
  background:#fff;
  color:currentColor;
  font-size:.82rem;
  font-weight:900;
  line-height:1;
}
.hf-v122 .hf-month-status-text{
  display:block;
  min-width:0;
  margin:0;
  padding:0;
  color:currentColor;
  font-size:.88rem;
  font-weight:850;
  line-height:1.1;
  letter-spacing:0;
  white-space:nowrap;
}


/* Tons do resumo mensal sem reutilizar a classe genérica .empty. */
.hf-v122 .financial-glance.tone-empty{
  border-color:#d8e5e3;
  border-left:4px solid #78918d;
  background:linear-gradient(135deg,#fff 0%,#f7faf9 100%);
}
.hf-v122 .financial-glance.tone-positive{
  border-color:#bfe7d0;
  border-left:4px solid #20a464;
  background:linear-gradient(135deg,#fff 0%,#f0fbf5 100%);
}
.hf-v122 .financial-glance.tone-negative{
  border-color:#f1cdcd;
  border-left:4px solid #df4b4b;
  background:linear-gradient(135deg,#fff 0%,#fff5f5 100%);
}
.hf-v122 .financial-glance.tone-warning{
  border-color:#efdca8;
  border-left:4px solid #d89a18;
  background:linear-gradient(135deg,#fff 0%,#fffaf0 100%);
}
.hf-v122 .financial-glance.tone-neutral{
  border-color:#c9e4df;
  border-left:4px solid #0f9488;
  background:linear-gradient(135deg,#fff 0%,#f3fbfa 100%);
}
.hf-v122 .financial-glance-metrics .metric-result.tone-positive{--metric-color:#1d9b5e;--metric-bg:#eefaf3;border-color:#cde9d7;background:#f7fcf9}
.hf-v122 .financial-glance-metrics .metric-result.tone-negative{--metric-color:#dc4e4e;--metric-bg:#fff1f1;border-color:#f0d0d0;background:#fff9f9}
.hf-v122 .financial-glance-metrics .metric-result.tone-warning{--metric-color:#cf8a10;--metric-bg:#fff7e7;border-color:#eedda9;background:#fffaf2}
.hf-v122 .financial-glance-metrics .metric-result.tone-neutral{--metric-color:#397f78;--metric-bg:#eef7f6}
.hf-v122 .financial-glance-metrics .metric-result.tone-empty{--metric-color:#397f78;--metric-bg:#eef7f6}

/* =========================================================
   Desktop: pequenos alinhamentos sem mudar o visual aprovado
   ========================================================= */
.hf-v122 .financial-glance-heading{
  min-width:0;
}
.hf-v122 .financial-glance-heading .eyebrow{
  margin:0;
}

/* =========================================================
   Responsividade global
   ========================================================= */
@media (max-width:900px){
  :root{
    --hf22-gutter:14px;
    --hf22-radius:20px;
  }

  html{
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    overflow-x:hidden!important;
  }
  body.hf-v122,
  body.hf-v122.sidebar-collapsed,
  body.hf-v122.sidebar-open,
  body.hf-v122.sidebar-mobile-open{
    position:relative!important;
    left:0!important;
    right:auto!important;
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    margin:0!important;
    padding-left:0!important;
    padding-right:0!important;
    transform:none!important;
    overflow-x:hidden!important;
    overscroll-behavior-x:none;
  }
  body.hf-v122 *,body.hf-v122 *::before,body.hf-v122 *::after{box-sizing:border-box}

  /* Topbar */
  body.hf-v122 .topbar,
  body.hf-v122.sidebar-collapsed .topbar,
  body.hf-v122.sidebar-open .topbar{
    position:sticky!important;
    top:0!important;
    left:0!important;
    right:auto!important;
    z-index:850!important;
    display:flex!important;
    align-items:center!important;
    justify-content:space-between!important;
    gap:9px!important;
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    height:auto!important;
    min-height:68px!important;
    margin:0!important;
    padding:8px 12px!important;
    padding-top:max(8px,env(safe-area-inset-top))!important;
    transform:none!important;
    overflow:hidden!important;
  }
  body.hf-v122 .sidebar-header-fill{display:none!important;width:0!important;height:0!important}
  body.hf-v122 .sidebar-mobile-toggle{
    display:grid!important;
    place-items:center!important;
    position:relative!important;
    inset:auto!important;
    flex:0 0 46px!important;
    width:46px!important;
    min-width:46px!important;
    height:46px!important;
    margin:0!important;
    border-radius:14px!important;
  }
  body.hf-v122 .topbar .brand{
    display:flex!important;
    align-items:center!important;
    flex:1 1 auto!important;
    gap:9px!important;
    width:auto!important;
    min-width:0!important;
    max-width:calc(100% - 108px)!important;
    margin:0!important;
    overflow:hidden!important;
  }
  body.hf-v122 .topbar .brand-mark.brand-mark-image{
    flex:0 0 50px!important;
    width:50px!important;
    min-width:50px!important;
    height:46px!important;
    border-radius:10px!important;
    overflow:hidden!important;
  }
  body.hf-v122 .topbar .brand-mark.brand-mark-image img{
    width:100%!important;
    height:100%!important;
    object-fit:contain!important;
    display:block!important;
  }
  body.hf-v122 .topbar .brand>span:last-child{
    display:block!important;
    min-width:0!important;
    max-width:100%!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
    white-space:nowrap!important;
    font-size:.92rem!important;
    line-height:1.1!important;
  }
  body.hf-v122 .topbar nav{
    position:static!important;
    flex:0 0 42px!important;
    width:42px!important;
    min-width:42px!important;
    margin:0!important;
    transform:none!important;
  }
  body.hf-v122 .topbar .account-link{
    display:grid!important;
    place-items:center!important;
    width:42px!important;
    min-width:42px!important;
    height:42px!important;
    padding:0!important;
    border-radius:50%!important;
    overflow:hidden!important;
  }
  body.hf-v122 .topbar .account-link img,
  body.hf-v122 .topbar .mini-avatar{
    width:38px!important;
    min-width:38px!important;
    height:38px!important;
    border-radius:50%!important;
  }
  body.hf-v122 .topbar .account-link>span:last-child{display:none!important}

  /* Menu lateral */
  body.hf-v122 .app-sidebar,
  body.hf-v122.sidebar-collapsed .app-sidebar{
    position:fixed!important;
    top:0!important;
    bottom:0!important;
    left:0!important;
    right:auto!important;
    z-index:1000!important;
    width:min(86vw,320px)!important;
    min-width:0!important;
    max-width:320px!important;
    margin:0!important;
    padding-top:max(10px,env(safe-area-inset-top))!important;
    padding-bottom:max(10px,env(safe-area-inset-bottom))!important;
    transform:translateX(-105%)!important;
    box-shadow:24px 0 60px rgba(14,45,42,.18)!important;
  }
  body.hf-v122.sidebar-open .app-sidebar,
  body.hf-v122 .app-sidebar.open,
  body.hf-v122 .app-sidebar.is-open{transform:translateX(0)!important}
  body.hf-v122 .sidebar-backdrop{
    display:none!important;
    position:fixed!important;
    inset:0!important;
    z-index:980!important;
    opacity:0!important;
    visibility:hidden!important;
    pointer-events:none!important;
    background:rgba(10,35,33,.44)!important;
    backdrop-filter:none!important;
    -webkit-backdrop-filter:none!important;
    transition:opacity .12s ease!important;
  }
  body.hf-v122.sidebar-open .sidebar-backdrop,
  body.hf-v122 .sidebar-backdrop.open,
  body.hf-v122 .sidebar-backdrop.is-open{
    display:block!important;
    opacity:1!important;
    visibility:visible!important;
    pointer-events:auto!important;
  }
  body.hf-v122 .sidebar-item,body.hf-v122 .sidebar-new{min-height:46px!important}

  /* Área principal */
  body.hf-v122 .dashboard,
  body.hf-v122 main.dashboard,
  body.hf-v122 .invoice-dashboard,
  body.hf-v122 .account-dashboard,
  body.hf-v122.sidebar-collapsed .dashboard,
  body.hf-v122.sidebar-open .dashboard{
    position:relative!important;
    inset:auto!important;
    left:0!important;
    right:auto!important;
    float:none!important;
    display:block!important;
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    margin:0!important;
    padding:18px var(--hf22-gutter) calc(92px + env(safe-area-inset-bottom))!important;
    transform:none!important;
    overflow:visible!important;
  }
  body.hf-v122 .dashboard>*,
  body.hf-v122 .invoice-dashboard>*,
  body.hf-v122 .account-dashboard>*{min-width:0!important;max-width:100%!important}

  /* Cabeçalhos */
  body.hf-v122 .page-head,
  body.hf-v122 .overview-head,
  body.hf-v122 .movements-head,
  body.hf-v122 .invoice-page-head,
  body.hf-v122 .settings-head{
    display:flex!important;
    flex-direction:column!important;
    align-items:stretch!important;
    gap:12px!important;
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    margin:0 0 16px!important;
    padding:0!important;
  }
  body.hf-v122 .page-head h1,
  body.hf-v122 .overview-head h1,
  body.hf-v122 .movements-head h1,
  body.hf-v122 .invoice-page-head h1,
  body.hf-v122 .settings-head h1{
    width:100%!important;
    max-width:100%!important;
    margin:2px 0 6px!important;
    font-size:clamp(2rem,8.7vw,2.45rem)!important;
    line-height:1.04!important;
    letter-spacing:-.045em!important;
    word-break:normal!important;
    overflow-wrap:normal!important;
    hyphens:none!important;
  }
  body.hf-v122 .page-head .muted,
  body.hf-v122 .overview-head .muted,
  body.hf-v122 .movements-head .muted,
  body.hf-v122 .invoice-page-head .muted,
  body.hf-v122 .settings-head .muted{
    width:100%!important;
    max-width:none!important;
    margin:0!important;
    font-size:.96rem!important;
    line-height:1.5!important;
  }

  body.hf-v122 .head-actions,
  body.hf-v122 .overview-actions,
  body.hf-v122 .movements-head-actions,
  body.hf-v122 .accounts-head-actions,
  body.hf-v122 .invoice-head-actions{
    display:grid!important;
    grid-template-columns:minmax(0,1fr)!important;
    gap:10px!important;
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
  }
  body.hf-v122 .head-actions>*,
  body.hf-v122 .overview-actions>*,
  body.hf-v122 .movements-head-actions>*,
  body.hf-v122 .accounts-head-actions>*,
  body.hf-v122 .invoice-head-actions>*{width:100%!important;min-width:0!important;max-width:100%!important}
  body.hf-v122 .overview-primary,
  body.hf-v122 .head-actions .primary,
  body.hf-v122 .invoice-new-purchase,
  body.hf-v122 .invoice-manage-link{min-height:50px!important;justify-content:center!important}

  /* Contexto pessoal/família */
  body.hf-v122 .space-switch{
    display:grid!important;
    grid-template-columns:minmax(0,1fr) 48px!important;
    gap:8px!important;
    align-items:end!important;
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
  }
  body.hf-v122 .space-switch .space-label{grid-column:1/-1!important}
  body.hf-v122 .space-switch .space-menu{width:100%!important;min-width:0!important;max-width:100%!important}
  body.hf-v122 .space-switch .space-menu summary{
    width:100%!important;
    min-width:0!important;
    min-height:50px!important;
    padding:0 12px!important;
  }
  body.hf-v122 .space-switch .space-menu summary>span:nth-child(2){
    min-width:0!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
    white-space:nowrap!important;
  }
  body.hf-v122 .space-switch .family-only-manage{
    display:grid!important;
    place-items:center!important;
    width:48px!important;
    min-width:48px!important;
    height:50px!important;
    padding:0!important;
  }
  body.hf-v122 .space-switch .family-only-manage span:last-child{display:none!important}
  body.hf-v122 .space-options{
    left:0!important;
    right:auto!important;
    width:min(100%,360px)!important;
    max-width:calc(100vw - (var(--hf22-gutter) * 2))!important;
  }

  /* Mês */
  body.hf-v122 .overview-month-wrap,
  body.hf-v122 .invoice-month-picker,
  body.hf-v122 .pretty-month-picker{
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
  }
  body.hf-v122 .pretty-month-picker summary{
    width:100%!important;
    min-width:0!important;
    min-height:52px!important;
    padding:0 12px 0 14px!important;
  }
  body.hf-v122 .month-popover,
  body.hf-v122 .pretty-month-picker .month-popover{
    left:0!important;
    right:auto!important;
    width:min(360px,calc(100vw - (var(--hf22-gutter) * 2)))!important;
    max-width:calc(100vw - (var(--hf22-gutter) * 2))!important;
  }

  /* Painéis e grids */
  body.hf-v122 .panel,
  body.hf-v122 .settings-card,
  body.hf-v122 .dashboard-focus-card,
  body.hf-v122 .financial-glance{
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    margin-left:0!important;
    margin-right:0!important;
    border-radius:var(--hf22-radius)!important;
  }
  body.hf-v122 .summary-grid,
  body.hf-v122 .card-grid,
  body.hf-v122 .analytics-grid,
  body.hf-v122 .dashboard-focus-grid,
  body.hf-v122 .settings-grid,
  body.hf-v122 .admin-grid,
  body.hf-v122 .invoice-card-grid,
  body.hf-v122 .family-overview-grid,
  body.hf-v122 .planning-grid,
  body.hf-v122 .account-forms-grid{
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    grid-template-columns:1fr!important;
    gap:12px!important;
  }

  /* Dashboard: resumo mensal */
  body.hf-v122 .financial-glance{
    padding:16px!important;
    margin:0 0 12px!important;
    overflow:hidden!important;
  }
  body.hf-v122 .financial-glance-head{
    display:flex!important;
    flex-direction:column!important;
    align-items:flex-start!important;
    gap:12px!important;
    width:100%!important;
    padding:0 0 14px!important;
    border-bottom:1px solid rgba(126,158,153,.18)!important;
  }
  body.hf-v122 .financial-glance-heading{
    display:flex!important;
    flex-direction:column!important;
    align-items:flex-start!important;
    gap:9px!important;
    width:100%!important;
    min-width:0!important;
  }
  body.hf-v122 .financial-glance-heading .eyebrow{
    width:100%!important;
    margin:0!important;
    font-size:.72rem!important;
    line-height:1.25!important;
  }
  body.hf-v122 .hf-month-status{
    align-self:flex-start!important;
    flex:0 0 auto!important;
    inline-size:max-content!important;
    width:max-content!important;
    min-width:0!important;
    max-width:100%!important;
    padding:7px 12px 7px 8px!important;
    gap:8px!important;
    border-radius:999px!important;
    overflow:hidden!important;
  }
  body.hf-v122 .hf-month-status-icon{
    width:22px!important;
    min-width:22px!important;
    height:22px!important;
    flex:0 0 22px!important;
  }
  body.hf-v122 .hf-month-status-text{
    width:auto!important;
    min-width:0!important;
    max-width:none!important;
    font-size:.92rem!important;
    line-height:1.1!important;
    white-space:nowrap!important;
    overflow:visible!important;
    text-overflow:clip!important;
  }
  body.hf-v122 .financial-month-message{
    display:block!important;
    width:100%!important;
    max-width:none!important;
    margin:0!important;
    padding:0!important;
    border:0!important;
    background:transparent!important;
    color:#617b77!important;
    text-align:left!important;
    font-size:.96rem!important;
    line-height:1.5!important;
  }
  body.hf-v122 .financial-glance-metrics{
    display:grid!important;
    grid-template-columns:1fr!important;
    gap:12px!important;
    width:100%!important;
    margin-top:14px!important;
  }
  body.hf-v122 .financial-glance-metrics article{
    width:100%!important;
    min-width:0!important;
    min-height:0!important;
    padding:14px!important;
    display:grid!important;
    grid-template-columns:44px minmax(0,1fr)!important;
    align-items:center!important;
    gap:12px!important;
  }
  body.hf-v122 .financial-metric-icon{
    width:44px!important;
    height:44px!important;
    flex:0 0 44px!important;
  }
  body.hf-v122 .financial-glance-metrics article>div{
    min-width:0!important;
    display:grid!important;
    gap:3px!important;
    text-align:left!important;
  }
  body.hf-v122 .financial-glance-metrics article>div>span{
    font-size:.72rem!important;
    line-height:1.25!important;
  }
  body.hf-v122 .financial-glance-metrics article strong{
    font-size:1.3rem!important;
    line-height:1.08!important;
  }
  body.hf-v122 .financial-glance-metrics article small{
    font-size:.8rem!important;
    line-height:1.4!important;
    white-space:normal!important;
  }

  /* Cards do dashboard */
  body.hf-v122 .dashboard-focus-card{padding:16px!important}
  body.hf-v122 .dashboard-focus-head{
    display:flex!important;
    flex-direction:column!important;
    align-items:stretch!important;
    gap:10px!important;
    margin-bottom:12px!important;
  }
  body.hf-v122 .dashboard-focus-head .secondary{width:100%!important;min-height:44px!important;justify-content:center!important}
  body.hf-v122 .planning-overview-total{grid-template-columns:1fr!important;gap:8px!important}
  body.hf-v122 .grouped-accounts-panel,body.hf-v122 .overview-recent-panel{margin-top:12px!important}
  body.hf-v122 .bank-account-grid,body.hf-v122 .overview-recent-list{grid-template-columns:1fr!important}

  /* Movimentações */
  body.hf-v122 .movements-toolbar,
  body.hf-v122 .movement-filters{
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
  }
  body.hf-v122 .movement-summary-strip{grid-template-columns:1fr!important;gap:10px!important}
  body.hf-v122 .movement-filters{grid-template-columns:1fr!important;gap:10px!important}
  body.hf-v122 .movement-filter-buttons{display:grid!important;grid-template-columns:1fr!important;gap:8px!important}
  body.hf-v122 .movement-filter-buttons>*{width:100%!important;min-height:44px!important;text-align:center!important}
  body.hf-v122 .movement-row-v2,
  body.hf-v122 .transfer-row-v2,
  body.hf-v122 .invoice-transaction-row{
    grid-template-columns:42px minmax(0,1fr)!important;
    gap:10px!important;
    align-items:start!important;
  }
  body.hf-v122 .movement-value,
  body.hf-v122 .invoice-transaction-value,
  body.hf-v122 .transfer-row-v2>b,
  body.hf-v122 .transfer-row-v2>.amount{
    grid-column:2!important;
    justify-self:start!important;
    text-align:left!important;
  }
  body.hf-v122 .movement-row-actions{grid-column:2!important;justify-self:start!important;display:flex!important;flex-wrap:wrap!important;gap:6px!important}
  body.hf-v122 .movement-copy,body.hf-v122 .movement-title-line,body.hf-v122 .invoice-transaction-main{min-width:0!important}
  body.hf-v122 .movement-copy strong,body.hf-v122 .movement-title-line strong,body.hf-v122 .invoice-transaction-main strong{white-space:normal!important;overflow-wrap:anywhere!important}

  /* Contas e cartões */
  body.hf-v122 .invoice-head-actions,
  body.hf-v122 .invoice-space-switch{display:grid!important;grid-template-columns:1fr!important;gap:10px!important;width:100%!important}
  body.hf-v122 .invoice-space-switch label,
  body.hf-v122 .invoice-space-switch select,
  body.hf-v122 .invoice-family-manage,
  body.hf-v122 .invoice-new-purchase,
  body.hf-v122 .invoice-manage-link{width:100%!important;min-width:0!important;max-width:100%!important}
  body.hf-v122 .invoice-toolbar{
    display:grid!important;
    grid-template-columns:1fr!important;
    gap:12px!important;
    width:100%!important;
    padding:14px!important;
  }
  body.hf-v122 .month-nav{
    display:grid!important;
    grid-template-columns:42px minmax(0,1fr) 42px!important;
    align-items:center!important;
    gap:8px!important;
    width:100%!important;
  }
  body.hf-v122 .month-nav a{display:grid!important;place-items:center!important;width:42px!important;min-width:42px!important;height:42px!important}
  body.hf-v122 .month-nav>div{min-width:0!important;text-align:center!important}
  body.hf-v122 .month-nav>div strong{display:block!important;white-space:normal!important;overflow-wrap:normal!important;font-size:1.2rem!important;line-height:1.1!important}
  body.hf-v122 .invoice-summary-grid{grid-template-columns:1fr!important;gap:10px!important}
  body.hf-v122 .invoice-card-grid{grid-template-columns:1fr!important;gap:12px!important}
  body.hf-v122 .invoice-credit-card,body.hf-v122 .invoice-detail-panel{width:100%!important;min-width:0!important;max-width:100%!important}
  body.hf-v122 .invoice-credit-brand span,body.hf-v122 .invoice-credit-card h3{white-space:normal!important;overflow-wrap:anywhere!important}

  /* Configurações */
  body.hf-v122 .settings-grid,body.hf-v122 .admin-grid{grid-template-columns:1fr!important;gap:12px!important}
  body.hf-v122 .settings-card,body.hf-v122 .panel.settings-card{padding:16px!important}
  body.hf-v122 .profile-summary{padding:12px!important;gap:10px!important}
  body.hf-v122 .profile-avatar{width:54px!important;height:54px!important;flex:0 0 54px!important}
  body.hf-v122 .form-row.two{grid-template-columns:1fr!important}
  body.hf-v122 .profile-action-row,body.hf-v122 .security-button-row{display:grid!important;grid-template-columns:1fr!important;gap:8px!important}
  body.hf-v122 .profile-action-row>*,body.hf-v122 .security-button-row>*{width:100%!important}
  body.hf-v122 .default-space-options,body.hf-v122 .twofactor-manage-grid,body.hf-v122 .totp-qr-setup{grid-template-columns:1fr!important}
  body.hf-v122 .totp-qr-frame{width:min(250px,100%)!important;max-width:100%!important;margin-inline:auto!important}
  body.hf-v122 .recovery-code-grid{grid-template-columns:1fr 1fr!important}
  body.hf-v122 .app-version-card{display:flex!important;flex-direction:column!important;align-items:stretch!important;gap:12px!important}
  body.hf-v122 .app-version-badge{width:100%!important;min-width:0!important;text-align:left!important}

  /* Modais */
  body.hf-v122 dialog,
  body.hf-v122 #familyDialog,
  body.hf-v122 #accountsDialog,
  body.hf-v122 #newTransaction,
  body.hf-v122 #editTransaction,
  body.hf-v122 .planning-dialog,
  body.hf-v122 .movement-dialog{
    width:calc(100dvw - 14px)!important;
    max-width:calc(100dvw - 14px)!important;
    min-width:0!important;
    max-height:calc(100dvh - 14px)!important;
    margin:auto!important;
    padding:0!important;
    border-radius:20px!important;
  }
  body.hf-v122 dialog::backdrop{backdrop-filter:blur(2px)!important;-webkit-backdrop-filter:blur(2px)!important}
  body.hf-v122 .modal-form,
  body.hf-v122 .family-modal,
  body.hf-v122 .planning-modal,
  body.hf-v122 .movement-modal,
  body.hf-v122 .movement-modal-v2,
  body.hf-v122 .accounts-modal{
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    max-height:calc(100dvh - 14px)!important;
    padding:16px!important;
    overflow-x:hidden!important;
    overflow-y:auto!important;
    overscroll-behavior:contain!important;
  }
  body.hf-v122 .modal-head h2,body.hf-v122 .movement-modal-head h2,body.hf-v122 .planning-head h2{font-size:1.4rem!important;line-height:1.1!important}
  body.hf-v122 .movement-type-selector{grid-template-columns:1fr!important;gap:8px!important}
  body.hf-v122 .movement-form-grid,body.hf-v122 .installment-fields,body.hf-v122 .recurring-fields{grid-template-columns:1fr!important;gap:10px!important}
  body.hf-v122 .movement-field.wide{grid-column:auto!important}
  body.hf-v122 .purchase-mode-switch{grid-template-columns:1fr!important;gap:6px!important}
  body.hf-v122 .movement-field input,
  body.hf-v122 .movement-field select,
  body.hf-v122 .movement-field textarea,
  body.hf-v122 .form-grid input,
  body.hf-v122 .form-grid select,
  body.hf-v122 .form-grid textarea,
  body.hf-v122 .planning-create input,
  body.hf-v122 .planning-create select,
  body.hf-v122 .settings-form input,
  body.hf-v122 .settings-form select,
  body.hf-v122 .settings-form textarea{font-size:16px!important}

  /* Planejamento */
  body.hf-v122 .planning-head{display:flex!important;flex-direction:column!important;align-items:stretch!important;gap:10px!important}
  body.hf-v122 .planning-head-actions{display:grid!important;grid-template-columns:minmax(0,1fr) 42px!important;gap:8px!important;width:100%!important}
  body.hf-v122 .planning-summary,body.hf-v122 .planning-grid{grid-template-columns:1fr!important;gap:10px!important}
  body.hf-v122 .planning-create{grid-template-columns:1fr!important;gap:10px!important;padding-top:14px!important}
  body.hf-v122 .planning-create-title{grid-column:auto!important}
  body.hf-v122 .planning-create .primary{width:100%!important;min-height:48px!important}
  body.hf-v122 .planning-category-picker{position:relative!important;min-width:0!important}
  body.hf-v122 .planning-category-picker.is-open .category-color-menu{
    position:absolute!important;
    top:calc(100% + 6px)!important;
    bottom:auto!important;
    left:0!important;
    right:auto!important;
    z-index:80!important;
    display:grid!important;
    grid-template-columns:1fr!important;
    width:100%!important;
    max-width:100%!important;
    max-height:min(250px,38dvh)!important;
    overflow:auto!important;
  }

  /* Família */
  body.hf-v122 #familyDialog .family-modal{padding:16px!important}
  body.hf-v122 .member-list,body.hf-v122 .family-permission-list,body.hf-v122 .permission-toggle-grid{grid-template-columns:1fr!important;gap:8px!important}
  body.hf-v122 .member-item,body.hf-v122 .family-permission-card{min-width:0!important;padding:10px!important}
  body.hf-v122 .invite-box{grid-template-columns:1fr!important}
  body.hf-v122 .invite-box .primary{width:100%!important}

  /* Cadastro/gestão de contas */
  body.hf-v122 #accountsDialog .account-form-columns{grid-template-columns:1fr!important;gap:14px!important}
  body.hf-v122 #accountsDialog .account-form-column{min-width:0!important;padding:0!important;border:0!important}
  body.hf-v122 #accountsDialog .account-form-column+.account-form-column{border-top:1px solid #e4efed!important;padding-top:14px!important}
  body.hf-v122 #accountsDialog .account-manager-list.account-manager-pairs{grid-template-columns:1fr!important}
  body.hf-v122 #accountsDialog .account-manager-pairs .manager-bank-pair{grid-template-columns:1fr!important;min-width:0!important}
  body.hf-v122 #accountsDialog .account-manager-pairs .manager-pair-pane{min-width:0!important;padding:14px!important}
  body.hf-v122 #accountsDialog .day-grid{grid-template-columns:1fr 1fr!important}
  body.hf-v122 #accountsDialog .account-save-button,body.hf-v122 #accountsDialog .account-create-submit{width:100%!important}

  /* Autenticação */
  body.hf-v122.auth-body{
    min-height:100dvh!important;
    padding:14px!important;
    padding-bottom:max(14px,env(safe-area-inset-bottom))!important;
  }
  body.hf-v122 .auth-shell{width:100%!important;grid-template-columns:1fr!important;gap:0!important}
  body.hf-v122 .auth-intro{display:none!important}
  body.hf-v122 .auth-card{width:100%!important;max-width:470px!important;padding:24px 18px!important;border-radius:22px!important;justify-self:center!important}
  body.hf-v122 .social-row{grid-template-columns:1fr!important}
  body.hf-v122 .recovery-shell{width:min(100%,470px)!important;padding:20px 0!important;gap:14px!important}
  body.hf-v122 .recovery-card{padding:22px 18px!important;border-radius:22px!important}

  body.hf-v122 img,body.hf-v122 svg,body.hf-v122 canvas,body.hf-v122 video{max-width:100%!important}
  body.hf-v122 input,body.hf-v122 select,body.hf-v122 textarea,body.hf-v122 button{max-width:100%}
}

@media (min-width:600px) and (max-width:900px){
  body.hf-v122 .financial-glance-metrics,
  body.hf-v122 .invoice-summary-grid,
  body.hf-v122 .movement-summary-strip{grid-template-columns:repeat(2,minmax(0,1fr))!important}
  body.hf-v122 .planning-overview-total{grid-template-columns:repeat(2,minmax(0,1fr))!important}
}

@media (max-width:420px){
  :root{--hf22-gutter:11px}
  body.hf-v122 .topbar .brand-mark.brand-mark-image{flex-basis:46px!important;width:46px!important;min-width:46px!important;height:42px!important}
  body.hf-v122 .topbar .brand>span:last-child{font-size:.84rem!important}
  body.hf-v122 .page-head h1,
  body.hf-v122 .overview-head h1,
  body.hf-v122 .movements-head h1,
  body.hf-v122 .invoice-page-head h1,
  body.hf-v122 .settings-head h1{font-size:2rem!important}
  body.hf-v122 .hf-month-status{padding:6px 10px 6px 7px!important;gap:7px!important}
  body.hf-v122 .hf-month-status-icon{width:20px!important;min-width:20px!important;height:20px!important;flex-basis:20px!important}
  body.hf-v122 .hf-month-status-text{font-size:.86rem!important}
  body.hf-v122 .financial-month-message{font-size:.92rem!important}
  body.hf-v122 .financial-glance-metrics article{grid-template-columns:40px minmax(0,1fr)!important;padding:12px!important;gap:10px!important}
  body.hf-v122 .financial-metric-icon{width:40px!important;height:40px!important;flex-basis:40px!important}
  body.hf-v122 .financial-glance-metrics article strong{font-size:1.18rem!important}
  body.hf-v122 .financial-glance-metrics article small{font-size:.76rem!important}
  body.hf-v122 .recovery-code-grid{grid-template-columns:1fr!important}
}
