/* ==========================================================================
   HOME V2 — INÍCIO REDESENHADO (GCP-ACE)
   Ativação: <body data-home="v2">  ·  Reversão: remover o atributo
   Escopo: SOMENTE a aba Início (tab1) + barra de abas inferior + botão de
   informações no topo. Nenhum estilo das telas internas é alterado.
   Paleta V1: as mesmas cores do layout aprovado (verde/laranja/teal/azul/roxo).
   ========================================================================== */

:root,
html,
body[data-home="v2"] {
  --hv2-bg: #0A0F12;
  --hv2-surface: #141C21;
  --hv2-surface-2: #1A242A;
  --hv2-border: #28373E;
  --hv2-border-soft: #1E2A31;
  --hv2-text: #EEF4F2;
  --hv2-muted: #94A5AA;

  --hv2-green: #22C55E;
  --hv2-green-d: #16A34A;
  --hv2-green-soft: rgba(34, 197, 94, 0.14);
  --hv2-orange: #F97316;
  --hv2-orange-soft: rgba(249, 115, 22, 0.14);
  --hv2-teal: #14B8A6;
  --hv2-teal-soft: rgba(20, 184, 166, 0.14);
  --hv2-blue: #3B82F6;
  --hv2-blue-soft: rgba(59, 130, 246, 0.14);
  --hv2-purple: #B98BFF;
  --hv2-purple-soft: rgba(168, 85, 247, 0.14);
  --hv2-indigo: #818CF8;
  --hv2-indigo-soft: rgba(129, 140, 248, 0.14);

  --hv2-r-card: 16px;
  --hv2-r-btn: 12px;
  --hv2-shadow: 0 10px 28px rgba(0, 0, 0, 0.42);
}

/* --------------------------------------------------------------------------
   1. LEGADO OCULTO — partes do dashboard antigo substituídas pela home v2
   (os elementos continuam no DOM porque o JS grava valores neles)
   -------------------------------------------------------------------------- */
body[data-home="v2"] .hub-main-dashboard .hub-hero-grid,
body[data-home="v2"] .hub-main-dashboard .hub-pills-wrap,
body[data-home="v2"] .hub-main-dashboard .hub-section-block,
body[data-home="v2"] .hub-main-dashboard .hub-backup-banner {
  display: none !important;
}

body[data-home="v2"] .main-dashboard > #main-dashboard-title,
body[data-home="v2"] .main-dashboard > .dashboard-grid,
body[data-home="v2"] .main-dashboard > .dashboard-actions,
body[data-home="v2"] .main-dashboard > .mgmt-panel,
body[data-home="v2"] .main-dashboard > #notifSectionInicio,
body[data-home="v2"] .main-dashboard > #backupSectionInicio {
  display: none !important;
}

/* --------------------------------------------------------------------------
   2. ESTRUTURA GERAL DO INÍCIO (fundo #0A0F12 fiel ao modelo V1)
   -------------------------------------------------------------------------- */
html body[data-home="v2"] #tab1,
html body[data-home="v2"] .hub-main-dashboard {
  background-color: #0A0F12 !important;
  color: #EEF4F2 !important;
}

html:not([data-theme="light"]) body[data-home="v2"]:has(#tab1.active),
html:not([data-theme="light"]) body[data-home="v2"]:has(#tab1.active) #app {
  background-color: #0A0F12 !important;
  background-image: none !important;
}

body[data-home="v2"] .hub-main-dashboard {
  max-width: 960px;
  margin: 0 auto;
  padding: 4px 16px 8px;
  display: block;
}

body[data-home="v2"] .hv2-greet {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  margin: 10px 0 14px;
}

body[data-home="v2"] .hv2-greet-title {
  margin: 0 !important;
  font-size: 22px !important;
  line-height: 1.2 !important;
  font-weight: 800 !important;
  color: #EEF4F2 !important;
  letter-spacing: -0.2px;
}

body[data-home="v2"] .hv2-greet-date {
  margin: 4px 0 0 !important;
  font-size: 12px !important;
  font-weight: 700 !important;
  color: #94A5AA !important;
  text-transform: uppercase;
  letter-spacing: 0.6px;
}

/* --------------------------------------------------------------------------
   3. BLOCO DE HOJE (card principal)
   -------------------------------------------------------------------------- */
body[data-home="v2"] .hv2-block {
  position: relative;
  background-color: #141C21 !important;
  border: 2px solid #26533C !important;
  border-radius: 16px !important;
  padding: 16px;
  box-shadow: 0 0 0 1px rgba(34, 197, 94, 0.10), 0 12px 34px rgba(34, 197, 94, 0.16) !important;
}

body[data-home="v2"] .hv2-block-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 10px;
}

body[data-home="v2"] .hv2-block-tag,
body[data-home="v2"] .hv2-block-resume {
  display: inline-block;
  padding: 5px 10px;
  border-radius: 8px;
  background-color: rgba(34, 197, 94, 0.16) !important;
  color: #86EFAC !important;
  font-size: 10px !important;
  font-weight: 800 !important;
  letter-spacing: 0.6px;
}

body[data-home="v2"] .hv2-block-time {
  color: #F97316 !important;
  font-size: 12px !important;
  font-weight: 800 !important;
}

body[data-home="v2"] .hv2-block-main {
  display: flex;
  align-items: baseline;
  gap: 8px;
}

body[data-home="v2"] .hv2-block-num {
  font-size: 34px !important;
  font-weight: 800 !important;
  line-height: 1 !important;
  color: #EEF4F2 !important;
}

body[data-home="v2"] .hv2-block-unit {
  font-size: 13px !important;
  font-weight: 700 !important;
  color: #94A5AA !important;
}

body[data-home="v2"] .hv2-block-subgoals {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 10px;
}

body[data-home="v2"] .hv2-block-subgoal {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 11px;
  border-radius: 10px;
  background-color: #10181C !important;
  border: 1px solid #22332B !important;
}

body[data-home="v2"] #hv2BlockQuestoesRow {
  border-color: #1E3538 !important;
}

body[data-home="v2"] .hv2-subgoal-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

body[data-home="v2"] .hv2-dot-green {
  background-color: #22C55E !important;
}

body[data-home="v2"] .hv2-dot-teal {
  background-color: #14B8A6 !important;
}

body[data-home="v2"] .hv2-subgoal-num {
  font-size: 16px !important;
  font-weight: 800 !important;
  line-height: 1 !important;
  color: #86EFAC !important;
}

body[data-home="v2"] #hv2BlockQuestoesNum {
  color: #5EEAD4 !important;
}

body[data-home="v2"] .hv2-subgoal-unit {
  font-size: 12px !important;
  font-weight: 700 !important;
  color: #EEF4F2 !important;
}

body[data-home="v2"] .hv2-block-sub {
  margin: 10px 0 0 !important;
  font-size: 12px !important;
  color: #94A5AA !important;
}

body[data-home="v2"] .hv2-steps {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 14px 0 16px;
  flex-wrap: wrap;
}

body[data-home="v2"] .hv2-step {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11.5px !important;
  font-weight: 700 !important;
  color: #94A5AA !important;
}

body[data-home="v2"] .hv2-step::before {
  content: "";
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background-color: #33454D !important;
}

body[data-home="v2"] .hv2-step.on {
  color: #EEF4F2 !important;
}

body[data-home="v2"] .hv2-step.on::before {
  background-color: #22C55E !important;
}

body[data-home="v2"] .hv2-step-line {
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background-color: #33454D !important;
}

body[data-home="v2"] .hv2-cta {
  width: 100%;
  min-height: 48px !important;
  border: none !important;
  border-radius: 12px !important;
  background-color: #22C55E !important;
  background-image: linear-gradient(135deg, #22C55E 0%, #16A34A 100%) !important;
  color: #052E16 !important;
  font-size: 14px !important;
  font-weight: 800 !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  cursor: pointer;
  box-shadow: 0 8px 22px rgba(34, 197, 94, 0.32) !important;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

body[data-home="v2"] .hv2-cta:hover {
  transform: translateY(-1px);
  background-color: #2ED267 !important;
  background-image: linear-gradient(135deg, #2ED267 0%, #17B052 100%) !important;
  box-shadow: 0 10px 26px rgba(34, 197, 94, 0.42) !important;
}

body[data-home="v2"] .hv2-cta:focus-visible {
  outline: 3px solid #86EFAC !important;
  outline-offset: 2px !important;
}

body[data-home="v2"] .hv2-block-foot {
  margin: 12px 0 0 !important;
  font-size: 10.5px !important;
  color: #6F8189 !important;
  letter-spacing: 0.3px;
}

/* --------------------------------------------------------------------------
   4. ATALHOS 2×2 (cores por área)
   -------------------------------------------------------------------------- */
body[data-home="v2"] .hv2-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 14px 0 0;
}

body[data-home="v2"] .hv2-tile {
  display: block;
  width: 100%;
  min-height: 76px !important;
  text-align: left;
  background-color: #141C21 !important;
  border: 1px solid #28373E !important;
  border-radius: 14px !important;
  padding: 12px !important;
  color: #EEF4F2 !important;
  cursor: pointer;
  transition: transform 0.15s ease, border-color 0.15s ease, background-color 0.15s ease;
}

body[data-home="v2"] .hv2-tile:hover {
  transform: translateY(-2px);
  background-color: #1A242A !important;
  border-color: #3A4C54 !important;
}

body[data-home="v2"] .hv2-tile:focus-visible {
  outline: 3px solid #22C55E !important;
  outline-offset: 2px !important;
}

body[data-home="v2"] .hv2-tile-head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}

body[data-home="v2"] .hv2-tile-ico {
  width: 30px;
  height: 30px;
  min-width: 30px;
  border-radius: 9px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

body[data-home="v2"] .hv2-tile-txt {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

body[data-home="v2"] .hv2-tile-name {
  font-size: 13px !important;
  font-weight: 800 !important;
  color: #EEF4F2 !important;
  line-height: 1.15;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

body[data-home="v2"] .hv2-tile-desc {
  font-size: 10.5px !important;
  font-weight: 500 !important;
  color: #94A5AA !important;
  margin-top: 2px;
}

body[data-home="v2"] .hv2-bar {
  height: 4px;
  border-radius: 3px;
  background-color: #26353C !important;
  overflow: hidden;
}

body[data-home="v2"] .hv2-bar > i {
  display: block;
  height: 100%;
  border-radius: 3px;
  background-color: #22C55E !important;
  transition: width 0.4s ease;
}

body[data-home="v2"] .hv2-bar-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

body[data-home="v2"] .hv2-bar-row .hv2-bar {
  flex: 1;
}

body[data-home="v2"] .hv2-bar-pct {
  font-size: 10px !important;
  font-weight: 800 !important;
  color: #94A5AA !important;
  min-width: 30px;
  text-align: right;
}

/* cores por área — aplica tanto nos tiles 2×2 (.hv2-tile-ico) quanto nas linhas (.hv2-row-ico) */
body[data-home="v2"] .hv2-c-green .hv2-tile-ico,
body[data-home="v2"] .hv2-c-green .hv2-row-ico {
  background-color: rgba(34, 197, 94, 0.14) !important;
  color: #22C55E !important;
}
body[data-home="v2"] .hv2-c-green .hv2-bar > i {
  background-color: #22C55E !important;
}

body[data-home="v2"] .hv2-c-orange .hv2-tile-ico,
body[data-home="v2"] .hv2-c-orange .hv2-row-ico {
  background-color: rgba(249, 115, 22, 0.14) !important;
  color: #F97316 !important;
}
body[data-home="v2"] .hv2-c-orange .hv2-bar > i {
  background-color: #F97316 !important;
}

body[data-home="v2"] .hv2-c-teal .hv2-tile-ico,
body[data-home="v2"] .hv2-c-teal .hv2-row-ico {
  background-color: rgba(20, 184, 166, 0.14) !important;
  color: #14B8A6 !important;
}
body[data-home="v2"] .hv2-c-teal .hv2-bar > i {
  background-color: #14B8A6 !important;
}

body[data-home="v2"] .hv2-c-blue .hv2-tile-ico,
body[data-home="v2"] .hv2-c-blue .hv2-row-ico {
  background-color: rgba(59, 130, 246, 0.14) !important;
  color: #3B82F6 !important;
}
body[data-home="v2"] .hv2-c-blue .hv2-bar > i {
  background-color: #3B82F6 !important;
}

body[data-home="v2"] .hv2-c-purple .hv2-tile-ico,
body[data-home="v2"] .hv2-c-purple .hv2-row-ico {
  background-color: rgba(168, 85, 247, 0.14) !important;
  color: #B98BFF !important;
}
body[data-home="v2"] .hv2-c-purple .hv2-bar > i {
  background-color: #B98BFF !important;
}

body[data-home="v2"] .hv2-c-indigo .hv2-tile-ico,
body[data-home="v2"] .hv2-c-indigo .hv2-row-ico {
  background-color: rgba(129, 140, 248, 0.14) !important;
  color: #818CF8 !important;
}
body[data-home="v2"] .hv2-c-indigo .hv2-bar > i {
  background-color: #818CF8 !important;
}

/* --------------------------------------------------------------------------
   5. SEQUÊNCIA / META
   -------------------------------------------------------------------------- */
body[data-home="v2"] .hv2-streak {
  display: flex;
  align-items: center;
  gap: 12px;
  background-color: #141C21 !important;
  border: 1px solid #28373E !important;
  border-radius: 14px !important;
  padding: 12px 14px;
  margin-top: 10px;
}

body[data-home="v2"] .hv2-streak-fire {
  color: #F97316 !important;
  display: inline-flex;
}

body[data-home="v2"] .hv2-streak-num {
  font-size: 17px !important;
  font-weight: 800 !important;
  color: #F97316 !important;
  line-height: 1;
}

body[data-home="v2"] .hv2-streak-lbl {
  font-size: 11px !important;
  font-weight: 700 !important;
  color: #94A5AA !important;
}

body[data-home="v2"] .hv2-streak-meta {
  margin-left: auto;
  text-align: right;
  min-width: 120px;
}

body[data-home="v2"] .hv2-streak-meta-txt {
  font-size: 10.5px !important;
  font-weight: 800 !important;
  color: #22C55E !important;
  margin-bottom: 5px;
  display: block;
}

/* --------------------------------------------------------------------------
   6. BOTÃO "VER TODOS OS MÓDULOS"
   -------------------------------------------------------------------------- */
body[data-home="v2"] .hv2-more {
  width: 100%;
  margin-top: 12px;
  min-height: 52px !important;
  background-color: #10181C !important;
  border: 1px dashed #28373E !important;
  border-radius: 13px !important;
  color: #EEF4F2 !important;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  transition: border-color 0.15s ease, background-color 0.15s ease;
}

body[data-home="v2"] .hv2-more:hover {
  border-color: #22C55E !important;
  background-color: #12201A !important;
}

body[data-home="v2"] .hv2-more b {
  font-size: 12.5px !important;
  font-weight: 800 !important;
  color: #EEF4F2 !important;
}

body[data-home="v2"] .hv2-more span {
  font-size: 10.5px !important;
  font-weight: 500 !important;
  color: #94A5AA !important;
}

/* --------------------------------------------------------------------------
   7. SEGUNDA DOBRA — números, grupos, constância, simulados
   -------------------------------------------------------------------------- */
body[data-home="v2"] .hv2-fold2 {
  margin-top: 22px;
  scroll-margin-top: 84px;
}

body[data-home="v2"] .hv2-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  background-color: #141C21 !important;
  border: 1px solid #28373E !important;
  border-radius: 14px !important;
  padding: 12px 6px;
}

body[data-home="v2"] .hv2-stat {
  text-align: center;
  position: relative;
}

body[data-home="v2"] .hv2-stat + .hv2-stat::before {
  content: "";
  position: absolute;
  left: 0;
  top: 4px;
  bottom: 4px;
  width: 1px;
  background-color: #28373E !important;
}

body[data-home="v2"] .hv2-stat b {
  display: block;
  font-size: 16px !important;
  font-weight: 800 !important;
  line-height: 1.1;
}

body[data-home="v2"] .hv2-stat span {
  display: block;
  font-size: 10px !important;
  color: #94A5AA !important;
  margin-top: 4px;
}

body[data-home="v2"] .hv2-group-title {
  margin: 18px 0 8px !important;
  font-size: 10.5px !important;
  font-weight: 800 !important;
  letter-spacing: 1px;
  color: #94A5AA !important;
  text-transform: uppercase;
}

body[data-home="v2"] .hv2-row {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  background-color: #141C21 !important;
  border: 1px solid #28373E !important;
  border-radius: 13px !important;
  padding: 12px !important;
  margin-bottom: 8px;
  color: #EEF4F2 !important;
  cursor: pointer;
  text-align: left;
  transition: background-color 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
}

body[data-home="v2"] .hv2-row:hover {
  background-color: #1A242A !important;
  border-color: #3A4C54 !important;
  transform: translateX(2px);
}

body[data-home="v2"] .hv2-row:focus-visible {
  outline: 3px solid #22C55E !important;
  outline-offset: 2px !important;
}

body[data-home="v2"] .hv2-row-ico {
  width: 34px;
  height: 34px;
  min-width: 34px;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

body[data-home="v2"] .hv2-row-txt {
  flex: 1;
  min-width: 0;
}

body[data-home="v2"] .hv2-row-name {
  display: block;
  font-size: 13px !important;
  font-weight: 800 !important;
  color: #EEF4F2 !important;
}

body[data-home="v2"] .hv2-row-desc {
  display: block;
  font-size: 11px !important;
  font-weight: 500 !important;
  color: #94A5AA !important;
  margin-top: 2px;
}

body[data-home="v2"] .hv2-row-bar {
  margin-top: 7px;
}

body[data-home="v2"] .hv2-row-chev {
  color: #6F8189 !important;
  display: inline-flex;
  min-width: 16px;
  justify-content: flex-end;
}

body[data-home="v2"] .hv2-badge {
  display: none;
  min-width: 22px;
  padding: 2px 7px;
  border-radius: 999px;
  background-color: #A855F7 !important;
  color: #FFFFFF !important;
  font-size: 11px !important;
  font-weight: 800 !important;
  text-align: center;
}

body[data-home="v2"] .hv2-badge[data-show="1"] {
  display: inline-block;
}

/* constância */
body[data-home="v2"] .hv2-heat {
  background-color: #141C21 !important;
  border: 1px solid #28373E !important;
  border-radius: 14px !important;
  padding: 14px;
  margin-top: 6px;
}

body[data-home="v2"] .hv2-heat-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

body[data-home="v2"] .hv2-heat-title {
  font-size: 12.5px !important;
  font-weight: 800 !important;
  color: #EEF4F2 !important;
}

body[data-home="v2"] .hv2-heat-sub {
  font-size: 11px !important;
  font-weight: 800 !important;
  color: #22C55E !important;
}

body[data-home="v2"] .hv2-heat-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 3px;
}

body[data-home="v2"] .hv2-heat-cell {
  aspect-ratio: 2.2 / 1;
  border-radius: 3px;
  background-color: #26353C !important;
}

body[data-home="v2"] .hv2-heat-cell.l1 { background-color: rgba(34, 197, 94, 0.35) !important; }
body[data-home="v2"] .hv2-heat-cell.l2 { background-color: #22C55E !important; }
body[data-home="v2"] .hv2-heat-cell.l3 { background-color: #F97316 !important; }

/* simulados (lista gerada pelo layout-hub.js) */
body[data-home="v2"] .hv2-quiz .hub-quiz-card {
  background-color: #141C21 !important;
  border: 1px solid #28373E !important;
  border-radius: 13px !important;
  padding: 12px 14px !important;
}

body[data-home="v2"] .hv2-quiz .hub-quiz-card:hover {
  background-color: #1A242A !important;
  border-color: #22C55E !important;
}

/* --------------------------------------------------------------------------
   8. TOPO — botões de ação blindados conforme screenshot oficial
   -------------------------------------------------------------------------- */
body[data-home="v2"] .hdr-action-btn {
  width: 40px !important;
  height: 40px !important;
  min-width: 40px !important;
  min-height: 40px !important;
  border-radius: 12px !important;
  padding: 0 !important;
  color: #FFFFFF !important;
}

body[data-home="v2"] .hdr-btn-calendar {
  background-color: #2563EB !important;
  border: 1px solid #1D4ED8 !important;
  color: #FFFFFF !important;
}

body[data-home="v2"] .hdr-btn-calendar:hover {
  background-color: #1D4ED8 !important;
  border-color: #1E40AF !important;
  transform: translateY(-1px);
}

body[data-home="v2"] .hdr-btn-info,
body[data-home="v2"] .hdr-btn-search,
body[data-home="v2"] .hdr-btn-settings {
  background-color: #222328 !important;
  border: 1px solid #38393F !important;
  color: #FFFFFF !important;
}

body[data-home="v2"] .hdr-btn-info:hover,
body[data-home="v2"] .hdr-btn-search:hover,
body[data-home="v2"] .hdr-btn-settings:hover {
  background-color: #2C2D34 !important;
  border-color: #6E6E74 !important;
  transform: translateY(-1px);
}

/* --------------------------------------------------------------------------
   9. BARRA DE ABAS INFERIOR
   -------------------------------------------------------------------------- */
body[data-home="v2"] #app {
  padding-bottom: 86px;
}

body[data-home="v2"] .hv2-tabbar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 380;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  background-color: #0B1114 !important;
  border-top: 1px solid #28373E !important;
  box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.45);
  padding: 6px 4px calc(6px + env(safe-area-inset-bottom, 0px));
}

body[data-home="v2"] .hv2-tab {
  background-color: transparent !important;
  background-image: none !important;
  border: none !important;
  padding: 0 !important;
  min-height: 62px !important;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 4px;
  cursor: pointer;
  color: #FFFFFF !important;
}

body[data-home="v2"] .hv2-tab-ico {
  width: 40px;
  height: 34px;
  border-radius: 11px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background-color: #141C21 !important;
  border: 1px solid #28373E !important;
  transition: background-color 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

body[data-home="v2"] .hv2-tab-lbl {
  font-size: 11px !important;
  font-weight: 800 !important;
  color: #FFFFFF !important;
  letter-spacing: 0.1px;
  white-space: nowrap;
}

body[data-home="v2"] .hv2-tab-dot {
  width: 22px;
  height: 3px;
  border-radius: 2px;
  background-color: transparent !important;
}

/* cores por aba (ícone) */
body[data-home="v2"] .hv2-tab[data-c="green"]  .hv2-tab-ico { color: #22C55E !important; }
body[data-home="v2"] .hv2-tab[data-c="orange"] .hv2-tab-ico { color: #F97316 !important; }
body[data-home="v2"] .hv2-tab[data-c="purple"] .hv2-tab-ico { color: #B98BFF !important; }
body[data-home="v2"] .hv2-tab[data-c="blue"]   .hv2-tab-ico { color: #3B82F6 !important; }

/* ativo */
body[data-home="v2"] .hv2-tab.active .hv2-tab-ico {
  background-color: rgba(34, 197, 94, 0.16) !important;
  border-color: #22C55E !important;
  box-shadow: 0 0 16px rgba(34, 197, 94, 0.35) !important;
}

body[data-home="v2"] .hv2-tab.active[data-c="orange"] .hv2-tab-ico {
  background-color: rgba(249, 115, 22, 0.14) !important;
  border-color: #F97316 !important;
  box-shadow: 0 0 16px rgba(249, 115, 22, 0.35) !important;
}

body[data-home="v2"] .hv2-tab.active[data-c="purple"] .hv2-tab-ico {
  background-color: rgba(168, 85, 247, 0.14) !important;
  border-color: #B98BFF !important;
  box-shadow: 0 0 16px rgba(168, 85, 247, 0.35) !important;
}

body[data-home="v2"] .hv2-tab.active[data-c="blue"] .hv2-tab-ico {
  background-color: rgba(59, 130, 246, 0.14) !important;
  border-color: #3B82F6 !important;
  box-shadow: 0 0 16px rgba(59, 130, 246, 0.35) !important;
}

body[data-home="v2"] .hv2-tab.active .hv2-tab-dot {
  background-color: #22C55E !important;
}

body[data-home="v2"] .hv2-tab.active[data-c="orange"] .hv2-tab-dot { background-color: #F97316 !important; }
body[data-home="v2"] .hv2-tab.active[data-c="purple"] .hv2-tab-dot { background-color: #B98BFF !important; }
body[data-home="v2"] .hv2-tab.active[data-c="blue"]   .hv2-tab-dot { background-color: #3B82F6 !important; }

body[data-home="v2"] .hv2-tab:focus-visible .hv2-tab-ico {
  outline: 3px solid #86EFAC !important;
  outline-offset: 2px !important;
}

/* --------------------------------------------------------------------------
   10. PAINEL "MAIS" (bottom sheet)
   -------------------------------------------------------------------------- */
body[data-home="v2"] .hv2-sheet {
  position: fixed;
  inset: 0;
  z-index: 400;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  background-color: rgba(0, 0, 0, 0.62) !important;
  backdrop-filter: blur(3px);
}

body[data-home="v2"] .hv2-sheet.hidden {
  display: none !important;
}

body[data-home="v2"] .hv2-sheet-card {
  width: 100%;
  max-width: 560px;
  max-height: 82vh;
  overflow-y: auto;
  background-color: #121A1E !important;
  border: 1px solid #28373E !important;
  border-bottom: none !important;
  border-radius: 18px 18px 0 0 !important;
  padding: 16px 16px calc(20px + env(safe-area-inset-bottom, 0px));
  box-shadow: 0 -14px 40px rgba(0, 0, 0, 0.55) !important;
}

body[data-home="v2"] .hv2-sheet-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid #28373E !important;
}

body[data-home="v2"] .hv2-sheet-title {
  margin: 0 !important;
  font-size: 15px !important;
  font-weight: 800 !important;
  color: #EEF4F2 !important;
}

body[data-home="v2"] .hv2-sheet-close {
  background-color: transparent !important;
  border: none !important;
  color: #94A5AA !important;
  font-size: 20px !important;
  line-height: 1 !important;
  cursor: pointer;
  padding: 6px !important;
  min-width: 36px !important;
  min-height: 36px !important;
}

body[data-home="v2"] .hv2-sheet-close:hover {
  color: #FFFFFF !important;
}

body[data-home="v2"] .hv2-sheet .hv2-row:last-child {
  margin-bottom: 0;
}

body[data-home="v2"] .hv2-sheet-note {
  margin: 12px 0 0 !important;
  font-size: 10.5px !important;
  color: #6F8189 !important;
  text-align: center;
}

/* --------------------------------------------------------------------------
   10B. MODAL DE CALENDÁRIO DA PROVA E META DIÁRIA
   -------------------------------------------------------------------------- */
body[data-home="v2"] .hv2-cal-card {
  max-width: 520px;
}

body[data-home="v2"] .hv2-cal-label {
  display: block;
  margin: 0 0 8px !important;
  font-size: 12px !important;
  font-weight: 800 !important;
  color: #94A5AA !important;
  letter-spacing: 0.3px;
}

body[data-home="v2"] .hv2-cal-input-wrap {
  margin-bottom: 10px;
}

body[data-home="v2"] .hv2-cal-date-input {
  width: 100%;
  min-height: 46px;
  padding: 10px 14px;
  border-radius: 12px !important;
  background-color: #141C21 !important;
  border: 1.5px solid #2563EB !important;
  color: #EEF4F2 !important;
  font-size: 15px !important;
  font-weight: 800 !important;
  color-scheme: dark;
  cursor: pointer;
}

body[data-home="v2"] .hv2-cal-presets,
body[data-home="v2"] .hv2-cal-goals {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

body[data-home="v2"] .hv2-cal-chip,
body[data-home="v2"] .hv2-cal-goal {
  flex: 1 1 auto;
  min-height: 36px !important;
  padding: 6px 10px !important;
  border-radius: 10px !important;
  background-color: #1A2329 !important;
  border: 1px solid #28373E !important;
  color: #EEF4F2 !important;
  font-size: 11.5px !important;
  font-weight: 700 !important;
  text-align: center;
  cursor: pointer;
}

body[data-home="v2"] .hv2-cal-chip.active,
body[data-home="v2"] .hv2-cal-goal.active {
  background-color: rgba(34, 197, 94, 0.20) !important;
  border-color: #22C55E !important;
  color: #86EFAC !important;
  font-weight: 800 !important;
}

body[data-home="v2"] .hv2-cal-summary {
  margin-top: 14px;
  padding: 14px;
  border-radius: 14px;
  background-color: #141C21 !important;
  border: 1.5px solid #26533C !important;
}

body[data-home="v2"] .hv2-cal-summary-kicker {
  display: block;
  margin-bottom: 8px;
  font-size: 10px !important;
  font-weight: 800 !important;
  letter-spacing: 0.7px;
  color: #86EFAC !important;
}

body[data-home="v2"] .hv2-cal-countdown-box {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-bottom: 10px;
  margin-bottom: 10px;
  border-bottom: 1px solid #222F36 !important;
}

body[data-home="v2"] .hv2-cal-days-num {
  font-size: 32px !important;
  font-weight: 900 !important;
  line-height: 1 !important;
  color: #86EFAC !important;
}

body[data-home="v2"] .hv2-cal-days-txt {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

body[data-home="v2"] .hv2-cal-days-txt b {
  font-size: 13px !important;
  font-weight: 800 !important;
  color: #EEF4F2 !important;
}

body[data-home="v2"] .hv2-cal-days-txt span {
  font-size: 11px !important;
  color: #94A5AA !important;
}

body[data-home="v2"] .hv2-cal-targets {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

body[data-home="v2"] .hv2-cal-target-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

body[data-home="v2"] .hv2-cal-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 4px;
}

body[data-home="v2"] .hv2-cal-target-row b {
  display: block;
  font-size: 12px !important;
  font-weight: 800 !important;
  color: #EEF4F2 !important;
}

body[data-home="v2"] .hv2-cal-target-row span {
  display: block;
  font-size: 11px !important;
  color: #94A5AA !important;
}

/* --------------------------------------------------------------------------
   11. RESPONSIVO
   -------------------------------------------------------------------------- */
@media (max-width: 359px) {
  body[data-home="v2"] .hv2-tab-lbl { font-size: 10px !important; }
  body[data-home="v2"] .hv2-tile-name { font-size: 12px !important; }
  body[data-home="v2"] .hv2-block-num { font-size: 30px !important; }
}

@media (min-width: 640px) {
  body[data-home="v2"] .hv2-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  body[data-home="v2"] .hv2-greet-title { font-size: 24px !important; }
  body[data-home="v2"] .hv2-heat-grid { gap: 4px; }
  body[data-home="v2"] .hv2-tab-lbl { font-size: 11.5px !important; }
}

@media (min-width: 900px) {
  body[data-home="v2"] .hub-main-dashboard { padding: 8px 24px 8px; }
  body[data-home="v2"] .hv2-block { padding: 20px; }
  body[data-home="v2"] .hv2-block-num { font-size: 40px !important; }
  body[data-home="v2"] .hv2-tile { min-height: 88px !important; }
  body[data-home="v2"] .hv2-tabbar {
    max-width: 720px;
    margin: 0 auto;
    border-radius: 18px 18px 0 0;
    border-left: 1px solid #28373E !important;
    border-right: 1px solid #28373E !important;
  }
}

/* --------------------------------------------------------------------------
   12. ACESSIBILIDADE / PREFERÊNCIAS
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  body[data-home="v2"] .hv2-tile,
  body[data-home="v2"] .hv2-row,
  body[data-home="v2"] .hv2-cta,
  body[data-home="v2"] .hv2-tab-ico,
  body[data-home="v2"] .hv2-bar > i {
    transition: none !important;
  }
  body[data-home="v2"] .hv2-tile:hover,
  body[data-home="v2"] .hv2-row:hover,
  body[data-home="v2"] .hv2-cta:hover {
    transform: none !important;
  }
}

/* --------------------------------------------------------------------------
   13. TEMA CLARO (mantém contraste quando o usuário escolhe "Claro")
   -------------------------------------------------------------------------- */
html[data-theme="light"] body[data-home="v2"] {
  --hv2-bg: #F1F5F3;
  --hv2-surface: #FFFFFF;
  --hv2-surface-2: #F4F8F6;
  --hv2-border: #D6E2DC;
  --hv2-border-soft: #E3ECE7;
  --hv2-text: #12211B;
  --hv2-muted: #5A6B66;
}

html[data-theme="light"] body[data-home="v2"] #tab1,
html[data-theme="light"] body[data-home="v2"] .hub-main-dashboard {
  background-color: #F1F5F3 !important;
  color: #12211B !important;
}

html[data-theme="light"] body[data-home="v2"] .hv2-greet-title,
html[data-theme="light"] body[data-home="v2"] .hv2-block-num,
html[data-theme="light"] body[data-home="v2"] .hv2-step.on,
html[data-theme="light"] body[data-home="v2"] .hv2-tile-name,
html[data-theme="light"] body[data-home="v2"] .hv2-more,
html[data-theme="light"] body[data-home="v2"] .hv2-more b,
html[data-theme="light"] body[data-home="v2"] .hv2-row,
html[data-theme="light"] body[data-home="v2"] .hv2-row-name,
html[data-theme="light"] body[data-home="v2"] .hv2-heat-title,
html[data-theme="light"] body[data-home="v2"] .hv2-sheet-title {
  color: #12211B !important;
}

html[data-theme="light"] body[data-home="v2"] .hv2-greet-date,
html[data-theme="light"] body[data-home="v2"] .hv2-block-unit,
html[data-theme="light"] body[data-home="v2"] .hv2-block-sub,
html[data-theme="light"] body[data-home="v2"] .hv2-step,
html[data-theme="light"] body[data-home="v2"] .hv2-tile-desc,
html[data-theme="light"] body[data-home="v2"] .hv2-bar-pct,
html[data-theme="light"] body[data-home="v2"] .hv2-streak-lbl,
html[data-theme="light"] body[data-home="v2"] .hv2-more span,
html[data-theme="light"] body[data-home="v2"] .hv2-stat span,
html[data-theme="light"] body[data-home="v2"] .hv2-group-title,
html[data-theme="light"] body[data-home="v2"] .hv2-row-desc,
html[data-theme="light"] body[data-home="v2"] .hv2-sheet-close {
  color: #5A6B66 !important;
}

html[data-theme="light"] body[data-home="v2"] .hv2-block {
  background-color: #FFFFFF !important;
  border-color: #9BD8B5 !important;
  box-shadow: 0 0 0 1px rgba(34, 197, 94, 0.12), 0 12px 30px rgba(22, 163, 74, 0.12) !important;
}

html[data-theme="light"] body[data-home="v2"] .hv2-block-tag {
  background-color: rgba(34, 197, 94, 0.16) !important;
  color: #15803D !important;
}

html[data-theme="light"] body[data-home="v2"] .hv2-bar { background-color: #DCE7E1 !important; }
html[data-theme="light"] body[data-home="v2"] .hv2-step::before { background-color: #C4D4CD !important; }
html[data-theme="light"] body[data-home="v2"] .hv2-step-line { background-color: #C4D4CD !important; }
html[data-theme="light"] body[data-home="v2"] .hv2-heat-cell { background-color: #E1EAE5 !important; }
html[data-theme="light"] body[data-home="v2"] .hv2-more { background-color: #FFFFFF !important; border-color: #D6E2DC !important; }
html[data-theme="light"] body[data-home="v2"] .hv2-more:hover { background-color: #F1FBF5 !important; }
html[data-theme="light"] body[data-home="v2"] .hv2-tile,
html[data-theme="light"] body[data-home="v2"] .hv2-row,
html[data-theme="light"] body[data-home="v2"] .hv2-streak,
html[data-theme="light"] body[data-home="v2"] .hv2-stats,
html[data-theme="light"] body[data-home="v2"] .hv2-heat,
html[data-theme="light"] body[data-home="v2"] .hv2-quiz .hub-quiz-card {
  background-color: #FFFFFF !important;
  border-color: #D6E2DC !important;
}
html[data-theme="light"] body[data-home="v2"] .hv2-tile:hover,
html[data-theme="light"] body[data-home="v2"] .hv2-row:hover {
  background-color: #F4F8F6 !important;
}
html[data-theme="light"] body[data-home="v2"] .hv2-tabbar {
  background-color: #0B1114 !important;
  border-top-color: #28373E !important;
}
html[data-theme="light"] body[data-home="v2"] .hv2-tab-lbl { color: #FFFFFF !important; }
html[data-theme="light"] body[data-home="v2"] .hv2-sheet-card {
  background-color: #FFFFFF !important;
  border-color: #D6E2DC !important;
}
html[data-theme="light"] body[data-home="v2"] .hv2-block-foot { color: #6B7C76 !important; }
