/* PoloStake 10.62: ajustes do dashboard restritos à apresentação mobile. */
@media (max-width: 899px) {
  html body:has(.live-dashboard) .live-main-col .live-welcome {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto !important;
    grid-template-rows: auto auto auto !important;
    align-items: center !important;
    gap: 4px 10px !important;
    min-height: 0 !important; height: auto !important; max-height: none !important;
    padding: 16px !important;
  }
  html body:has(.live-dashboard) .live-welcome > div:first-child,
  html body:has(.live-dashboard) .live-welcome .live-botbox,
  html body:has(.live-dashboard) .live-welcome .live-botbox > div:first-child {
    display: contents !important;
  }
  html body:has(.live-dashboard) .live-welcome .eyebrow {
    grid-column: 1 !important; grid-row: 1 !important;
    font-size: 8px !important; letter-spacing: .1em !important; margin: 0 !important;
  }
  html body:has(.live-dashboard) .live-welcome h1 {
    grid-column: 1 !important; grid-row: 2 !important;
    font-size: clamp(18px, 5vw, 23px) !important; line-height: 1.2 !important;
    margin: 0 !important; min-width: 0 !important; overflow-wrap: anywhere !important;
  }
  html body:has(.live-dashboard) .live-welcome p,
  html body:has(.live-dashboard) .live-welcome .hero-signature,
  html body:has(.live-dashboard) .live-welcome .live-robot,
  html body:has(.live-dashboard) .live-welcome .live-botmeta > div:not(:first-child) {
    display: none !important;
  }
  html body:has(.live-dashboard) .live-welcome .live-botstatus {
    grid-column: 2 !important; grid-row: 1 / 3 !important;
    gap: 8px !important; margin: 0 !important;
  }
  html body:has(.live-dashboard) .live-welcome .live-botstatus i {
    width: 24px !important; height: 24px !important; flex: 0 0 24px !important;
  }
  html body:has(.live-dashboard) .live-welcome .live-botstatus span { font-size: 8px !important; }
  html body:has(.live-dashboard) .live-welcome .live-botstatus strong { font-size: 20px !important; line-height: 1.2 !important; }
  html body:has(.live-dashboard) .live-welcome .live-botmeta {
    grid-column: 1 / -1 !important; grid-row: 3 !important;
    margin: 10px 0 0 !important; padding: 0 !important; border: 0 !important;
    font-size: 10px !important; line-height: 1.4 !important;
  }
  html body:has(.live-dashboard) .live-welcome .live-botmeta > div:first-child {
    display: flex !important; justify-content: center !important;
    gap: 12px !important; flex-wrap: wrap !important;
  }
  html body:has(.live-dashboard) .live-welcome .live-botmeta span { width: auto !important; }
  html body:has(.live-dashboard) .live-main-col .live-kpis {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 8px !important; align-items: stretch !important;
  }
  html body:has(.live-dashboard) .live-main-col .live-kpis > .live-kpi {
    grid-column: auto !important; grid-row: 1 !important;
    width: 100% !important; min-width: 0 !important;
    min-height: 180px !important; height: auto !important; max-height: none !important;
    padding: 10px 8px !important; border-radius: 12px !important;
    display: flex !important; flex-direction: column !important;
  }
  html body:has(.live-dashboard) .live-main-col .live-kpis > .live-risk {
    grid-column: 1 / -1 !important; grid-row: 2 !important;
    min-height: 0 !important; height: auto !important; max-height: none !important;
    padding: 18px 16px !important;
  }
  html body:has(.live-dashboard) .live-risk .risk-grid > div:last-child { grid-column: 1 / -1 !important; }
  html body:has(.live-dashboard) .live-kpi .scope-wrap {
    min-height: 32px !important; margin: 0 0 4px !important; justify-content: center !important;
  }
  html body:has(.live-dashboard) .live-kpi .scope-label { display: none !important; }
  html body:has(.live-dashboard) .live-kpi .scope-switch {
    max-width: 100% !important; min-height: 32px !important; gap: 4px !important;
  }
  html body:has(.live-dashboard) .live-kpi .scope-text { font-size: 8px !important; }
  html body:has(.live-dashboard) .live-kpi .kpi-head {
    min-height: 24px !important; gap: 3px !important; margin: 0 !important;
  }
  html body:has(.live-dashboard) .live-kpi .kpi-head span { font-size: 9px !important; line-height: 1.3 !important; letter-spacing: 0 !important; }
  html body:has(.live-dashboard) .live-kpi .kpi-icon { display: none !important; }
  html body:has(.live-dashboard) .live-kpi .privacy-eye-kpi { padding: 0 !important; width: 24px !important; min-width: 24px !important; }
  html body:has(.live-dashboard) .live-kpi .kpi-val {
    font-size: clamp(16px, 4.8vw, 23px) !important; line-height: 1.2 !important;
    margin: 6px 0 !important; overflow-wrap: anywhere !important;
  }
  html body:has(.live-dashboard) .live-kpi .kpi-sub {
    font-size: 10px !important; line-height: 1.35 !important; overflow-wrap: anywhere !important;
  }
  html body:has(.live-dashboard) .live-kpi .ops-extremes { margin-top: 10px !important; gap: 5px !important; }
  html body:has(.live-dashboard) .live-kpi .ops-extremes small { font-size: 7px !important; line-height: 1.3 !important; }
  html body:has(.live-dashboard) .live-kpi .ops-extremes b { font-size: 10px !important; overflow-wrap: anywhere !important; }
}
