:root {
  --app-navy: #0b1739;
  --app-blue: #2157d5;
  --app-cyan: #25b6d2;
  --app-bg: #f4f7fb;
  --app-text: #17213c;
  --app-muted: #6b7690;
  --app-border: #dfe6f1;
  --app-success: #067647;
  --app-danger: #b42318;
}

* {
  box-sizing: border-box;
}

.farox-app-body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--app-text);
  background: var(--app-bg);
}

.app-topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 12px clamp(18px, 4vw, 52px);
  color: #fff;
  background: rgba(11, 23, 57, .96);
  box-shadow: 0 12px 30px rgba(13, 29, 68, .12);
  backdrop-filter: blur(14px);
}

.app-logo {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: #fff;
  text-decoration: none;
  letter-spacing: .08em;
}

.app-logo-mark {
  width: 27px;
  height: 27px;
  border: 7px solid #fff;
  border-radius: 50%;
  box-shadow: 0 0 0 4px rgba(37, 182, 210, .25);
}

.app-user {
  display: flex;
  align-items: center;
  gap: 11px;
  min-width: 0;
}

.app-user-avatar {
  flex: 0 0 38px;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  color: #102352;
  background: #dff9ff;
  font-size: .8rem;
  font-weight: 900;
}

.app-user-copy {
  min-width: 0;
  display: grid;
}

.app-user-copy strong,
.app-user-copy span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.app-user-copy strong {
  font-size: .88rem;
}

.app-user-copy span {
  color: rgba(255,255,255,.66);
  font-size: .75rem;
}

.app-logout {
  min-height: 38px;
  padding: 0 15px;
  border: 1px solid rgba(255,255,255,.18);
  border-radius: 10px;
  color: #fff;
  background: rgba(255,255,255,.08);
  font: inherit;
  font-size: .82rem;
  font-weight: 750;
  cursor: pointer;
}

.app-content {
  width: min(100% - 32px, 1440px);
  margin: 0 auto;
  padding: clamp(24px, 4vw, 52px) 0;
}

.app-flash {
  margin-bottom: 20px;
  padding: 14px 17px;
  border-radius: 12px;
  font-weight: 650;
}

.app-flash-error {
  color: var(--app-danger);
  background: #fff1f0;
}

.app-flash-success {
  color: var(--app-success);
  background: #ecfdf3;
}

.welcome-panel {
  display: flex;
  justify-content: space-between;
  gap: 28px;
  padding: clamp(24px, 4vw, 42px);
  border: 1px solid var(--app-border);
  border-radius: 24px;
  background:
    radial-gradient(circle at 100% 0%, rgba(37, 182, 210, .12), transparent 30%),
    #fff;
  box-shadow: 0 18px 50px rgba(18, 39, 84, .07);
}

.section-eyebrow {
  margin: 0 0 10px;
  color: var(--app-blue);
  font-size: .76rem;
  font-weight: 900;
  letter-spacing: .15em;
}

.welcome-panel h1 {
  margin: 0;
  font-size: clamp(2rem, 5vw, 3.7rem);
  letter-spacing: -.055em;
}

.welcome-panel p:not(.section-eyebrow) {
  max-width: 760px;
  margin: 14px 0 0;
  color: var(--app-muted);
  line-height: 1.7;
}

.welcome-status {
  align-self: flex-start;
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 999px;
  color: var(--app-success);
  background: #ecfdf3;
  font-size: .82rem;
  font-weight: 800;
}

.status-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #12b76a;
  box-shadow: 0 0 0 4px rgba(18,183,106,.14);
}

.validation-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  margin-top: 22px;
}

.validation-card {
  min-width: 0;
  padding: 22px;
  border: 1px solid var(--app-border);
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 12px 32px rgba(18, 39, 84, .05);
}

.validation-card span,
.validation-card strong,
.validation-card small {
  display: block;
  overflow-wrap: anywhere;
}

.validation-card span {
  color: var(--app-muted);
  font-size: .78rem;
  font-weight: 750;
  text-transform: uppercase;
  letter-spacing: .08em;
}

.validation-card strong {
  margin-top: 12px;
  color: var(--app-navy);
  font-size: clamp(1.35rem, 3vw, 2rem);
}

.validation-card small {
  margin-top: 7px;
  color: var(--app-muted);
  line-height: 1.45;
}

@media (max-width: 991.98px) {
  .validation-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 575.98px) {
  .app-topbar {
    min-height: 64px;
    padding: 10px 14px;
  }

  .app-user-copy {
    display: none;
  }

  .app-logout {
    padding: 0 11px;
  }

  .app-content {
    width: min(100% - 22px, 1440px);
    padding: 20px 0;
  }

  .welcome-panel {
    display: grid;
    padding: 22px;
    border-radius: 19px;
  }

  .validation-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}


/* FAROX v1.0: los estilos globales del shell viven en farox_insight_canvas.css. */
:root {
  --farox-ink: #142033;
  --farox-muted: #6f7b90;
  --farox-line: #e5eaf1;
  --farox-bg: #f7f8fb;
  --farox-surface: #ffffff;
  --farox-violet: #7257ff;
  --farox-pink: #e54fa3;
  --farox-teal: #11b7a5;
  --farox-orange: #f2a33b;
  --farox-navy: #10182f;
  --farox-danger: #b42318;
  --farox-success: #067647;
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  min-height: 100%;
  scroll-behavior: smooth;
}

.farox-body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  color: var(--farox-ink);
  background: linear-gradient(180deg, #fbfbfe, #f4f6fa);
  font-family: Inter, "Segoe UI", Arial, sans-serif;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

button,
input,
select,
textarea {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

.farox-page {
  min-height: 100vh;
}

.farox-header {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  min-height: 72px;
  padding: 15px clamp(18px, 4vw, 54px);
  border-bottom: 1px solid rgba(229, 234, 241, .85);
  background: rgba(255, 255, 255, .88);
  backdrop-filter: blur(18px);
}

.farox-logo {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: var(--farox-navy);
  text-decoration: none;
  font-weight: 950;
  letter-spacing: .08em;
}

.farox-logo-shape {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: conic-gradient(
    from 180deg,
    var(--farox-violet),
    var(--farox-pink),
    var(--farox-teal),
    var(--farox-violet)
  );
  box-shadow: 0 8px 20px rgba(114, 87, 255, .25);
}

.farox-logo-shape::after {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #fff;
  content: "";
}

.farox-header-center {
  display: flex;
  align-items: center;
  gap: 8px;
}

.farox-nav-pill {
  padding: 10px 13px;
  border-radius: 10px;
  color: var(--farox-muted);
  text-decoration: none;
  font-size: .9rem;
  font-weight: 700;
  transition: color .2s ease, background .2s ease;
}

.farox-nav-pill:hover,
.farox-nav-pill.active {
  color: var(--farox-violet);
  background: #f0edff;
}

.farox-header-right {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
}

.farox-icon-button {
  position: relative;
  flex: 0 0 42px;
  width: 42px;
  height: 42px;
  border: 1px solid var(--farox-line);
  border-radius: 12px;
  color: var(--farox-ink);
  background: #fff;
  cursor: pointer;
}

.farox-mobile-menu-button {
  display: none;
}

.farox-notification-count {
  position: absolute;
  top: -5px;
  right: -5px;
  min-width: 20px;
  height: 20px;
  display: grid;
  place-items: center;
  padding: 0 5px;
  border: 2px solid #fff;
  border-radius: 999px;
  color: #fff;
  background: var(--farox-pink);
  font-size: .65rem;
  font-weight: 900;
}

.farox-user {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  padding-left: 7px;
}

.farox-user-avatar {
  flex: 0 0 40px;
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: #fff;
  background: linear-gradient(135deg, var(--farox-violet), var(--farox-pink));
  font-size: .8rem;
  font-weight: 900;
}

.farox-user-details {
  min-width: 0;
  display: grid;
  line-height: 1.25;
}

.farox-user-details strong,
.farox-user-details span {
  max-width: 170px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.farox-user-details strong {
  font-size: .82rem;
}

.farox-user-details span {
  color: var(--farox-muted);
  font-size: .7rem;
}

.farox-logout-button {
  min-height: 38px;
  padding: 0 12px;
  border: 1px solid var(--farox-line);
  border-radius: 10px;
  color: var(--farox-muted);
  background: #fff;
  font-size: .76rem;
  font-weight: 750;
  cursor: pointer;
}

.farox-workspace {
  width: min(100%, 1680px);
  margin: 0 auto;
  padding: clamp(22px, 4vw, 52px);
}

.farox-flash {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  margin-bottom: 20px;
  padding: 14px 16px;
  border-radius: 14px;
  line-height: 1.45;
}

.farox-flash span {
  flex: 0 0 24px;
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  font-weight: 900;
}

.farox-flash p {
  margin: 2px 0 0;
}

.farox-flash-error {
  color: var(--farox-danger);
  background: #fff1f0;
}

.farox-flash-error span {
  background: var(--farox-danger);
}

.farox-flash-success {
  color: var(--farox-success);
  background: #ecfdf3;
}

.farox-flash-success span {
  background: var(--farox-success);
}

.farox-hero {
  display: grid;
  grid-template-columns: 1.2fr .8fr;
  gap: 20px;
  margin-bottom: 24px;
}

.farox-hero-card {
  position: relative;
  min-height: 270px;
  overflow: hidden;
  padding: clamp(26px, 4vw, 48px);
  border-radius: 28px;
  color: #fff;
  background: linear-gradient(135deg, #151c37, #2c2e66 58%, #5a3ed6);
  box-shadow: 0 24px 60px rgba(32, 28, 90, .18);
}

.farox-hero-card::before {
  position: absolute;
  top: -80px;
  right: -90px;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,.2), transparent 62%);
  content: "";
}

.farox-hero-tag {
  position: relative;
  display: inline-flex;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255,255,255,.12);
  font-size: .75rem;
  font-weight: 800;
  letter-spacing: .08em;
}

.farox-hero-card h1 {
  position: relative;
  max-width: 720px;
  margin: 22px 0 0;
  font-size: clamp(2.2rem, 5vw, 4.3rem);
  line-height: 1.02;
  letter-spacing: -.06em;
}

.farox-hero-card > p {
  position: relative;
  max-width: 620px;
  color: rgba(255,255,255,.72);
  line-height: 1.65;
}

.farox-hero-stats {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  margin-top: 30px;
}

.farox-hero-stats div {
  min-width: 120px;
}

.farox-hero-stats strong,
.farox-hero-stats span {
  display: block;
}

.farox-hero-stats strong {
  font-size: 1.5rem;
}

.farox-hero-stats span {
  margin-top: 3px;
  color: rgba(255,255,255,.6);
  font-size: .76rem;
}

.farox-health-card,
.farox-panel {
  border: 1px solid var(--farox-line);
  background: #fff;
  box-shadow: 0 20px 50px rgba(27,35,65,.07);
}

.farox-health-card {
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 16px;
  padding: 24px;
  border-radius: 28px;
}

.farox-panel {
  min-width: 0;
  padding: 22px;
  border-radius: 22px;
  box-shadow: 0 16px 40px rgba(30,42,76,.05);
}

.farox-panel-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
}

.farox-panel-heading h2 {
  margin: 0;
  font-size: 1rem;
}

.farox-panel-heading span {
  color: var(--farox-muted);
  font-size: .74rem;
}

.farox-health-state {
  color: var(--farox-teal);
  font-size: .9rem;
}

.farox-ring-wrapper {
  display: grid;
  place-items: center;
}

.farox-ring {
  position: relative;
  width: 190px;
  height: 190px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background:
    conic-gradient(
      var(--farox-teal) 0 calc(var(--farox-health-value) * 1%),
      #eaf0f3 calc(var(--farox-health-value) * 1%) 100%
    );
}

.farox-ring::before {
  width: 136px;
  height: 136px;
  border-radius: 50%;
  background: #fff;
  box-shadow: inset 0 0 0 1px var(--farox-line);
  content: "";
}

.farox-ring-label {
  position: absolute;
  text-align: center;
}

.farox-ring-label strong,
.farox-ring-label span {
  display: block;
}

.farox-ring-label strong {
  font-size: 2.2rem;
}

.farox-ring-label span {
  color: var(--farox-muted);
  font-size: .75rem;
}

.farox-filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}

.farox-filter-button {
  min-height: 40px;
  padding: 8px 14px;
  border: 1px solid var(--farox-line);
  border-radius: 999px;
  color: var(--farox-muted);
  background: #fff;
  font-size: .8rem;
  font-weight: 700;
  cursor: pointer;
}

.farox-filter-button.active {
  color: #fff;
  border-color: var(--farox-navy);
  background: var(--farox-navy);
}

.farox-filter-context {
  cursor: default;
}

.farox-metric-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 14px;
}

.farox-metric {
  min-width: 0;
  padding: 18px;
  border: 1px solid var(--farox-line);
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 10px 30px rgba(25,36,65,.04);
}

.farox-metric-label {
  color: var(--farox-muted);
  font-size: .74rem;
  font-weight: 750;
}

.farox-metric strong,
.farox-metric small {
  display: block;
  overflow-wrap: anywhere;
}

.farox-metric strong {
  margin-top: 14px;
  font-size: 1.7rem;
  letter-spacing: -.04em;
}

.farox-metric small {
  margin-top: 8px;
  font-size: .72rem;
  font-weight: 800;
}

.farox-metric-violet small { color: var(--farox-violet); }
.farox-metric-pink small { color: var(--farox-pink); }
.farox-metric-teal small { color: var(--farox-teal); }
.farox-metric-orange small { color: var(--farox-orange); }

.farox-canvas-grid {
  display: grid;
  grid-template-columns: 1.15fr .85fr .75fr;
  gap: 16px;
  margin-top: 18px;
}

.farox-line-chart {
  position: relative;
  height: 250px;
  overflow: hidden;
  border-radius: 14px;
  background:
    linear-gradient(
      to bottom,
      transparent 24%,
      #f2f4f8 25%,
      transparent 26%,
      transparent 49%,
      #f2f4f8 50%,
      transparent 51%,
      transparent 74%,
      #f2f4f8 75%,
      transparent 76%
    );
}

.farox-line-chart svg {
  width: 100%;
  height: 100%;
}

.farox-chart-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 12px;
  color: var(--farox-muted);
  font-size: .75rem;
}

.farox-chart-legend i {
  width: 10px;
  height: 10px;
  display: inline-block;
  margin-right: 5px;
  border-radius: 50%;
}

.farox-legend-violet { background: var(--farox-violet); }
.farox-legend-pink { background: var(--farox-pink); }

.farox-source-list {
  display: grid;
  gap: 12px;
}

.farox-source {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 14px;
  border-radius: 15px;
  background: #fafbfe;
}

.farox-source-icon {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: #fff;
  font-weight: 900;
}

.farox-source-sara {
  background: linear-gradient(135deg, var(--farox-violet), #9d89ff);
}

.farox-source-evida {
  background: linear-gradient(135deg, var(--farox-teal), #5adacb);
}

.farox-source-traxio {
  background: linear-gradient(135deg, var(--farox-orange), #ffc56a);
}

.farox-source-farox,
.farox-source-manual {
  background: linear-gradient(135deg, #56627a, #8e99ac);
}

.farox-source-copy {
  min-width: 0;
}

.farox-source-copy strong,
.farox-source-copy small {
  display: block;
  overflow-wrap: anywhere;
}

.farox-source-copy strong {
  font-size: .86rem;
}

.farox-source-copy small {
  margin-top: 3px;
  color: var(--farox-muted);
  font-size: .72rem;
}

.farox-source-status {
  padding: 6px 8px;
  border-radius: 999px;
  color: #087d6f;
  background: #eaf9f5;
  font-size: .68rem;
  font-weight: 800;
  white-space: nowrap;
}

.farox-source-status.off {
  color: #7b8595;
  background: #f1f2f5;
}

.farox-source-status.pending {
  color: #9b6814;
  background: #fff5df;
}

.farox-empty-state {
  display: grid;
  gap: 5px;
  padding: 18px;
  border: 1px dashed var(--farox-line);
  border-radius: 15px;
  color: var(--farox-muted);
}

.farox-empty-state strong {
  color: var(--farox-ink);
}

.farox-timeline {
  display: grid;
}

.farox-event {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 12px;
  padding-bottom: 18px;
}

.farox-event:not(:last-child)::before {
  position: absolute;
  top: 18px;
  bottom: 0;
  left: 7px;
  width: 2px;
  background: #edf0f5;
  content: "";
}

.farox-event-dot {
  z-index: 1;
  width: 16px;
  height: 16px;
  border: 4px solid #fff;
  border-radius: 50%;
  background: var(--farox-violet);
  box-shadow: 0 0 0 2px #dcd5ff;
}

.farox-event-teal { background: var(--farox-teal); }
.farox-event-orange { background: var(--farox-orange); }
.farox-event-pink { background: var(--farox-pink); }

.farox-event time,
.farox-event strong,
.farox-event small {
  display: block;
}

.farox-event time {
  color: var(--farox-muted);
  font-size: .7rem;
}

.farox-event strong {
  margin-top: 3px;
  font-size: .85rem;
}

.farox-event small {
  margin-top: 3px;
  color: var(--farox-muted);
  font-size: .72rem;
  line-height: 1.4;
}

.farox-bottom-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 16px;
}

.farox-heatmap {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 7px;
}

.farox-heatmap span {
  aspect-ratio: 1;
  border-radius: 7px;
  background: #eeeeef;
}

.farox-heatmap span:nth-child(3n) { background: #d8d0ff; }
.farox-heatmap span:nth-child(4n) { background: #a995ff; }
.farox-heatmap span:nth-child(7n) { background: var(--farox-violet); }

.farox-goal-list {
  display: grid;
  gap: 13px;
}

.farox-goal {
  padding: 14px;
  border: 1px solid var(--farox-line);
  border-radius: 15px;
}

.farox-goal-heading {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  font-size: .82rem;
  font-weight: 750;
}

.farox-goal-bar {
  height: 8px;
  overflow: hidden;
  margin-top: 10px;
  border-radius: 999px;
  background: #eef1f6;
}

.farox-goal-bar i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--farox-violet), var(--farox-pink));
}

.farox-mobile-navigation,
.farox-mobile-overlay {
  display: none;
}

@media (max-width: 1250px) {
  .farox-metric-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .farox-canvas-grid {
    grid-template-columns: 1fr 1fr;
  }

  .farox-timeline-panel {
    grid-column: 1 / -1;
  }
}

@media (max-width: 991.98px) {
  .farox-header-center {
    display: none;
  }

  .farox-mobile-menu-button {
    display: inline-grid;
    place-items: center;
  }

  .farox-hero {
    grid-template-columns: 1fr;
  }

  .farox-canvas-grid,
  .farox-bottom-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .farox-timeline-panel {
    grid-column: auto;
  }

  .farox-mobile-navigation {
    position: fixed;
    top: 0;
    right: 0;
    z-index: 80;
    width: min(88vw, 360px);
    height: 100vh;
    height: 100dvh;
    display: flex;
    flex-direction: column;
    padding: 20px;
    border-left: 1px solid var(--farox-line);
    background: #fff;
    box-shadow: -24px 0 60px rgba(21, 32, 60, .18);
    transform: translateX(105%);
    transition: transform .25s ease;
  }

  .farox-mobile-overlay {
    position: fixed;
    inset: 0;
    z-index: 70;
    display: block;
    background: rgba(16, 24, 47, .45);
    opacity: 0;
    pointer-events: none;
    transition: opacity .25s ease;
  }

  .farox-mobile-menu-open {
    overflow: hidden;
  }

  .farox-mobile-menu-open .farox-mobile-navigation {
    transform: translateX(0);
  }

  .farox-mobile-menu-open .farox-mobile-overlay {
    opacity: 1;
    pointer-events: auto;
  }

  .farox-mobile-navigation-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding-bottom: 18px;
    border-bottom: 1px solid var(--farox-line);
  }

  .farox-mobile-close {
    width: 42px;
    height: 42px;
    border: 1px solid var(--farox-line);
    border-radius: 12px;
    color: var(--farox-ink);
    background: #fff;
    font-size: 1.5rem;
    cursor: pointer;
  }

  .farox-mobile-links {
    display: grid;
    gap: 5px;
    overflow: auto;
    padding: 18px 0;
  }

  .farox-mobile-link {
    min-height: 46px;
    display: flex;
    align-items: center;
    padding: 0 14px;
    border-radius: 11px;
    color: var(--farox-muted);
    text-decoration: none;
    font-weight: 750;
  }

  .farox-mobile-link:hover,
  .farox-mobile-link.active {
    color: var(--farox-violet);
    background: #f0edff;
  }

  .farox-mobile-user {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: auto;
    padding-top: 18px;
    border-top: 1px solid var(--farox-line);
  }

  .farox-mobile-user strong,
  .farox-mobile-user span {
    display: block;
  }

  .farox-mobile-user strong {
    font-size: .85rem;
  }

  .farox-mobile-user span {
    margin-top: 3px;
    color: var(--farox-muted);
    font-size: .72rem;
  }
}

@media (max-width: 767.98px) {
  .farox-workspace {
    padding: 18px 14px;
  }

  .farox-header {
    min-height: 64px;
    padding: 11px 14px;
  }

  .farox-search-button,
  .farox-user-details {
    display: none;
  }

  .farox-user {
    gap: 7px;
  }

  .farox-logout-button {
    padding: 0 9px;
  }

  .farox-hero-card {
    min-height: auto;
    padding: 28px 23px;
  }

  .farox-health-card,
  .farox-panel {
    padding: 20px;
  }

  .farox-metric-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 480px) {
  .farox-workspace {
    padding: 15px 11px;
  }

  .farox-header {
    padding: 10px 11px;
  }

  .farox-notification-button {
    display: none;
  }

  .farox-metric-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .farox-filter-bar {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .farox-filter-button {
    width: 100%;
  }

  .farox-filter-context {
    grid-column: 1 / -1;
  }

  .farox-hero-card,
  .farox-health-card {
    border-radius: 22px;
  }

  .farox-panel {
    border-radius: 18px;
  }

  .farox-source {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .farox-source-status {
    grid-column: 2;
    justify-self: start;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition: none !important;
    animation: none !important;
  }
}

/* ============================================================
   FAROX — IDENTIDAD VISUAL OFICIAL
   ============================================================ */

.farox-logo {
  flex: 0 0 auto;
  min-width: 0;
  gap: 9px;
}

.farox-header-isotipo {
  flex: 0 0 42px;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  object-fit: cover;
  mix-blend-mode: multiply;
}

.farox-header-wordmark {
  width: 118px;
  height: auto;
  display: block;
  object-fit: contain;
  mix-blend-mode: multiply;
}

.farox-mobile-brand {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 11px;
  color: var(--farox-navy);
  text-decoration: none;
}

.farox-mobile-brand-isotipo {
  flex: 0 0 46px;
  width: 46px;
  height: 46px;
  border-radius: 13px;
  object-fit: cover;
  mix-blend-mode: multiply;
}

.farox-mobile-brand strong,
.farox-mobile-brand span {
  display: block;
}

.farox-mobile-brand strong {
  font-size: 1rem;
  font-weight: 950;
  letter-spacing: .08em;
}

.farox-mobile-brand span {
  max-width: 185px;
  margin-top: 3px;
  color: var(--farox-muted);
  font-size: .67rem;
  line-height: 1.3;
}

@media (max-width: 1180px) {
  .farox-header-wordmark {
    width: 102px;
  }

  .farox-header-center {
    gap: 3px;
  }

  .farox-nav-pill {
    padding-right: 9px;
    padding-left: 9px;
  }
}

@media (max-width: 767.98px) {
  .farox-header-isotipo {
    flex-basis: 38px;
    width: 38px;
    height: 38px;
  }

  .farox-header-wordmark {
    width: 88px;
  }
}

@media (max-width: 480px) {
  .farox-header-wordmark {
    display: none;
  }
}

/* ========================================================================== 
   FAROX Dashboard Ejecutivo v1.0
   ========================================================================== */
.fx-dashboard-heading{display:flex;align-items:flex-start;justify-content:space-between;gap:24px;margin-bottom:22px}.fx-eyebrow,.fx-panel-kicker{display:block;color:var(--farox-violet);font-size:.7rem;font-weight:900;letter-spacing:.13em}.fx-dashboard-heading h1{margin:7px 0 0;font-size:clamp(1.8rem,4vw,3.25rem);line-height:1.05;letter-spacing:-.045em}.fx-dashboard-heading p{max-width:760px;margin:10px 0 0;color:var(--farox-muted);line-height:1.6}.fx-update-status{display:flex;align-items:center;gap:11px;flex:0 0 auto;padding:12px 14px;border:1px solid var(--farox-line);border-radius:14px;background:#fff}.fx-update-status div{display:grid}.fx-update-status strong{font-size:.76rem}.fx-update-status small{margin-top:2px;color:var(--farox-muted);font-size:.68rem}.fx-live-dot{width:10px;height:10px;border-radius:50%;background:var(--farox-teal);box-shadow:0 0 0 5px rgba(17,183,165,.12)}
.fx-filter-shell{margin-bottom:20px;padding:12px;border:1px solid var(--farox-line);border-radius:18px;background:rgba(255,255,255,.9);box-shadow:0 10px 30px rgba(30,42,76,.04)}.fx-filter-form{display:flex;align-items:stretch;gap:12px}.fx-period-tabs{display:flex;gap:6px;padding:4px;border-radius:13px;background:#f2f4f8}.fx-period-button{display:flex;align-items:center;min-height:38px;padding:0 14px;border-radius:10px;color:var(--farox-muted);text-decoration:none;font-size:.78rem;font-weight:800}.fx-period-button.active{color:#fff;background:var(--farox-navy);box-shadow:0 8px 18px rgba(16,24,47,.18)}.fx-filter-context{display:grid;min-width:150px;padding:5px 14px;border-left:1px solid var(--farox-line)}.fx-filter-context span{color:var(--farox-muted);font-size:.67rem}.fx-filter-context strong{margin-top:3px;font-size:.8rem;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.fx-kpi-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:16px;margin-bottom:20px}.fx-kpi-card{position:relative;min-width:0;overflow:hidden;padding:20px;border:1px solid var(--farox-line);border-radius:20px;background:#fff;box-shadow:0 14px 36px rgba(30,42,76,.05)}.fx-kpi-card:before{position:absolute;top:0;left:0;width:100%;height:4px;content:""}.fx-kpi-violet:before{background:var(--farox-violet)}.fx-kpi-teal:before{background:var(--farox-teal)}.fx-kpi-orange:before{background:var(--farox-orange)}.fx-kpi-pink:before{background:var(--farox-pink)}.fx-kpi-card-top,.fx-kpi-footer{display:flex;align-items:center;justify-content:space-between;gap:10px}.fx-kpi-name{color:var(--farox-muted);font-size:.76rem;font-weight:800}.fx-kpi-source{padding:4px 7px;border-radius:999px;color:var(--farox-violet);background:#f0edff;font-size:.62rem;font-weight:900}.fx-kpi-value{display:block;margin:16px 0 13px;font-size:clamp(1.75rem,3vw,2.6rem);letter-spacing:-.04em}.fx-kpi-footer span{font-size:.73rem;font-weight:800}.fx-kpi-footer small{color:var(--farox-muted);font-size:.62rem}
.fx-dashboard-grid{display:grid;gap:20px;margin-bottom:20px}.fx-dashboard-grid-main{grid-template-columns:minmax(320px,.75fr) minmax(0,1.25fr)}.fx-dashboard-grid-secondary,.fx-dashboard-grid-tertiary{grid-template-columns:repeat(2,minmax(0,1fr))}.fx-panel{min-width:0}.fx-panel-header{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;margin-bottom:20px}.fx-panel-header h2{margin:5px 0 0;font-size:1.05rem}.fx-panel-note{color:var(--farox-muted);font-size:.7rem}.fx-status-pill{padding:7px 10px;border-radius:999px;font-size:.68rem;font-weight:900}.fx-status-good{color:#067647;background:#ecfdf3}.fx-status-warning{color:#b54708;background:#fffaeb}.fx-status-danger{color:#b42318;background:#fef3f2}.fx-health-body{display:flex;align-items:center;gap:26px}.fx-health-ring{flex:0 0 150px;width:150px;height:150px;display:grid;place-items:center;border-radius:50%;background:conic-gradient(var(--farox-teal) calc(var(--health-value)*1%),#edf1f5 0)}.fx-health-ring:before{position:absolute}.fx-health-ring>div{width:108px;height:108px;display:grid;place-content:center;text-align:center;border-radius:50%;background:#fff}.fx-health-ring strong{font-size:2rem}.fx-health-ring span{color:var(--farox-muted);font-size:.68rem}.fx-health-summary{flex:1;display:grid;gap:10px}.fx-health-summary div{display:flex;justify-content:space-between;gap:14px;padding-bottom:10px;border-bottom:1px solid var(--farox-line)}.fx-health-summary span{color:var(--farox-muted);font-size:.74rem}.fx-health-summary strong{font-size:.86rem}
.fx-bar-chart{height:230px;display:flex;align-items:flex-end;gap:12px;padding:20px 8px 0;border-bottom:1px solid var(--farox-line);background:repeating-linear-gradient(to top,transparent 0,transparent 44px,#eef1f5 45px)}.fx-bar-group{height:100%;flex:1;min-width:18px;display:grid;grid-template-rows:1fr auto;gap:8px;text-align:center}.fx-bars{display:flex;align-items:flex-end;justify-content:center;gap:4px;height:100%}.fx-bar{display:block;width:min(18px,40%);min-height:3px;border-radius:6px 6px 2px 2px}.fx-bar-income{background:linear-gradient(180deg,#8e7aff,var(--farox-violet))}.fx-bar-expense{background:linear-gradient(180deg,#f17aba,var(--farox-pink))}.fx-bar-group small{color:var(--farox-muted);font-size:.6rem}.fx-chart-legend{display:flex;gap:18px;margin-top:14px}.fx-chart-legend span{display:flex;align-items:center;gap:7px;color:var(--farox-muted);font-size:.7rem}.fx-chart-legend i{width:9px;height:9px;border-radius:50%}.fx-legend-income{background:var(--farox-violet)}.fx-legend-expense{background:var(--farox-pink)}
.fx-alert-list,.fx-goal-list,.fx-area-list,.fx-source-list{display:grid;gap:11px}.fx-alert-row{display:grid;grid-template-columns:auto minmax(0,1fr) auto;align-items:center;gap:11px;padding:12px;border:1px solid var(--farox-line);border-radius:14px}.fx-alert-indicator{width:9px;height:38px;border-radius:999px}.fx-alert-critical{background:var(--farox-danger)}.fx-alert-high{background:var(--farox-orange)}.fx-alert-medium{background:#f7c948}.fx-alert-row>div:nth-child(2){min-width:0;display:grid}.fx-alert-row strong,.fx-alert-row small{overflow:hidden;text-overflow:ellipsis}.fx-alert-row strong{font-size:.78rem;white-space:nowrap}.fx-alert-row small{margin-top:3px;color:var(--farox-muted);font-size:.68rem;white-space:nowrap}.fx-alert-meta{display:grid;justify-items:end;gap:3px}.fx-alert-meta span{font-size:.64rem;font-weight:900}.fx-alert-meta time{color:var(--farox-muted);font-size:.6rem}.fx-goal-row{padding:13px;border-radius:14px;background:#f8f9fc}.fx-goal-heading{display:flex;justify-content:space-between;gap:12px}.fx-goal-heading strong{font-size:.76rem}.fx-goal-heading span{font-size:.72rem;font-weight:900}.fx-goal-track,.fx-area-progress{height:8px;overflow:hidden;margin:10px 0;border-radius:999px;background:#e8ecf2}.fx-goal-track i,.fx-area-progress i{display:block;height:100%;border-radius:inherit;background:linear-gradient(90deg,var(--farox-violet),var(--farox-teal))}.fx-goal-row small{color:var(--farox-muted);font-size:.63rem}
.fx-area-row{display:grid;grid-template-columns:minmax(130px,1fr) minmax(120px,1.2fr) auto;align-items:center;gap:14px;padding:12px 0;border-bottom:1px solid var(--farox-line)}.fx-area-row:last-child{border-bottom:0}.fx-area-main{display:grid}.fx-area-main strong{font-size:.76rem}.fx-area-main span{margin-top:3px;color:var(--farox-muted);font-size:.64rem}.fx-area-lights{display:flex;gap:5px}.fx-area-lights span{min-width:25px;padding:4px 6px;border-radius:999px;text-align:center;font-size:.62rem;font-weight:900}.fx-area-lights .green{color:#067647;background:#ecfdf3}.fx-area-lights .yellow{color:#b54708;background:#fffaeb}.fx-area-lights .red{color:#b42318;background:#fef3f2}.fx-source-row{display:grid;grid-template-columns:auto minmax(0,1fr) auto;align-items:center;gap:11px;padding:11px;border:1px solid var(--farox-line);border-radius:14px}.fx-source-badge{width:38px;height:38px;display:grid;place-items:center;border-radius:12px;color:#fff;background:var(--farox-navy);font-size:.7rem;font-weight:900}.fx-source-sara{background:#2463eb}.fx-source-evida{background:#7257ff}.fx-source-traxio{background:#11b7a5}.fx-source-row>div{min-width:0;display:grid}.fx-source-row strong{font-size:.76rem}.fx-source-row small{margin-top:3px;color:var(--farox-muted);font-size:.64rem;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.fx-source-state{padding:5px 8px;border-radius:999px;color:#067647;background:#ecfdf3;font-size:.62rem;font-weight:900}.fx-source-state.pending{color:#b54708;background:#fffaeb}.fx-source-state.off{color:#667085;background:#f2f4f7}
.fx-timeline-panel{margin-bottom:0}.fx-timeline{display:grid}.fx-timeline-item{display:grid;grid-template-columns:110px auto minmax(0,1fr);gap:14px;align-items:start;position:relative;padding:12px 0}.fx-timeline-item:not(:last-child):after{position:absolute;top:31px;bottom:-12px;left:120px;width:1px;background:var(--farox-line);content:""}.fx-timeline-item time{color:var(--farox-muted);font-size:.67rem;text-align:right}.fx-timeline-dot{z-index:1;width:9px;height:9px;margin-top:4px;border-radius:50%;background:var(--farox-violet);box-shadow:0 0 0 5px #f0edff}.fx-timeline-item>div{display:grid}.fx-timeline-item strong{font-size:.76rem}.fx-timeline-item small{margin-top:3px;color:var(--farox-muted);font-size:.66rem}.fx-empty-panel{display:grid;place-items:center;min-height:150px;padding:24px;text-align:center;border:1px dashed #cdd5df;border-radius:16px;background:#fafbfc}.fx-empty-panel strong{font-size:.82rem}.fx-empty-panel span{max-width:420px;margin-top:6px;color:var(--farox-muted);font-size:.7rem;line-height:1.5}.fx-empty-wide{grid-column:1/-1}
@media(max-width:1199.98px){.fx-kpi-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.fx-dashboard-grid-main{grid-template-columns:1fr}.fx-health-body{justify-content:center}.fx-trend-panel{min-height:350px}}
@media(max-width:899.98px){.fx-dashboard-heading{display:grid}.fx-update-status{justify-self:start}.fx-filter-form{flex-wrap:wrap}.fx-filter-context{border-left:0;border-top:1px solid var(--farox-line);flex:1}.fx-dashboard-grid-secondary,.fx-dashboard-grid-tertiary{grid-template-columns:1fr}}
@media(max-width:575.98px){.farox-workspace{padding:18px 13px 28px}.fx-dashboard-heading h1{font-size:2rem}.fx-update-status{width:100%}.fx-period-tabs{width:100%;overflow-x:auto}.fx-period-button{flex:1;justify-content:center;white-space:nowrap}.fx-filter-context{min-width:calc(50% - 6px);padding:8px}.fx-kpi-grid{grid-template-columns:1fr}.fx-kpi-card{padding:17px}.fx-health-body{display:grid}.fx-health-ring{margin:auto}.fx-alert-row{grid-template-columns:auto minmax(0,1fr)}.fx-alert-meta{grid-column:2;justify-items:start}.fx-area-row{grid-template-columns:1fr}.fx-source-row{grid-template-columns:auto minmax(0,1fr)}.fx-source-state{grid-column:2;justify-self:start}.fx-timeline-item{grid-template-columns:auto minmax(0,1fr)}.fx-timeline-item time{grid-column:2;text-align:left}.fx-timeline-item:not(:last-child):after{left:4px;top:42px}.fx-timeline-dot{grid-row:1/span 2}.fx-bar-chart{gap:6px;padding-left:0;padding-right:0}.fx-bar-group small{font-size:.54rem}}


/* ==========================================================================
   FAROX v1.0 — APP SHELL CORPORATIVO
   Sidebar reutilizable + Topbar + responsividad
   ========================================================================== */

:root {
  --fx-corporate-950: #071a2f;
  --fx-corporate-900: #0b2545;
  --fx-corporate-800: #123b66;
  --fx-corporate-700: #18558f;
  --fx-corporate-600: #1f6fb2;
  --fx-corporate-100: #eaf3fb;
  --fx-sidebar-width: 276px;
  --fx-sidebar-collapsed-width: 82px;

  /* Sustitución total del morado por azul corporativo */
  --farox-violet: #1f6fb2;
  --farox-pink: #2b88c9;
  --farox-navy: #0b2545;
  --farox-teal: #0f9d8a;
  --farox-orange: #e79a2f;
}

.farox-body {
  overflow-x: hidden;
  background: #f4f7fb;
}

.fx-app-shell {
  min-height: 100vh;
  min-height: 100dvh;
  display: grid;
  grid-template-columns: var(--fx-sidebar-width) minmax(0, 1fr);
  transition: grid-template-columns .22s ease;
}

.fx-app-column {
  min-width: 0;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
}

.fx-sidebar {
  position: sticky;
  top: 0;
  z-index: 60;
  min-width: 0;
  height: 100vh;
  height: 100dvh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  color: #dbe8f5;
  background:
    radial-gradient(circle at 20% 0%, rgba(31, 111, 178, .28), transparent 34%),
    linear-gradient(180deg, var(--fx-corporate-900), var(--fx-corporate-950));
  box-shadow: 12px 0 30px rgba(4, 20, 38, .12);
}

.fx-sidebar-brand {
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 13px 16px;
  border-bottom: 1px solid rgba(255,255,255,.09);
}

.fx-sidebar-logo {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  overflow: hidden;
  text-decoration: none;
}

.fx-sidebar-isotipo {
  flex: 0 0 44px;
  width: 44px;
  height: 44px;
  border-radius: 13px;
  object-fit: cover;
  background: #fff;
  box-shadow: 0 8px 20px rgba(0,0,0,.2);
}

.fx-sidebar-wordmark {
  width: 116px;
  height: auto;
  object-fit: contain;
  filter: brightness(0) invert(1);
}

.fx-sidebar-collapse {
  flex: 0 0 34px;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 10px;
  color: #dbe8f5;
  background: rgba(255,255,255,.06);
  cursor: pointer;
}

.fx-sidebar-collapse svg,
.fx-topbar-menu-button svg,
.fx-topbar-icon-button svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.fx-sidebar-scroll {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  scrollbar-width: thin;
  scrollbar-color: rgba(255,255,255,.22) transparent;
}

.fx-sidebar-nav {
  display: grid;
  gap: 4px;
  padding: 18px 12px;
}

.fx-sidebar-section-title {
  display: block;
  padding: 0 11px 8px;
  color: #7fa1c2;
  font-size: .62rem;
  font-weight: 900;
  letter-spacing: .14em;
  white-space: nowrap;
}

.fx-sidebar-admin-title {
  margin-top: 18px;
}

.fx-sidebar-link {
  position: relative;
  min-height: 44px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 12px;
  border-radius: 11px;
  color: #c7d8e9;
  text-decoration: none;
  font-size: .82rem;
  font-weight: 700;
  transition: background .18s ease, color .18s ease, transform .18s ease;
}

.fx-sidebar-link:hover {
  color: #fff;
  background: rgba(255,255,255,.08);
}

.fx-sidebar-link.active {
  color: #fff;
  background: linear-gradient(90deg, rgba(31,111,178,.98), rgba(24,85,143,.82));
  box-shadow: 0 8px 20px rgba(2, 15, 30, .22);
}

.fx-sidebar-link.is-placeholder {
  cursor: default;
}

.fx-sidebar-icon {
  flex: 0 0 22px;
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
}

.fx-sidebar-icon svg {
  width: 20px;
  height: 20px;
}

.fx-sidebar-label {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.fx-sidebar-active-dot {
  width: 6px;
  height: 6px;
  margin-left: auto;
  border-radius: 50%;
  background: #82d5ff;
  box-shadow: 0 0 0 4px rgba(130,213,255,.14);
}

.fx-sidebar-footer {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 15px 18px;
  border-top: 1px solid rgba(255,255,255,.09);
  background: rgba(0,0,0,.08);
}

.fx-sidebar-suite-dot {
  flex: 0 0 10px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #28c99f;
  box-shadow: 0 0 0 5px rgba(40,201,159,.13);
}

.fx-sidebar-footer div {
  min-width: 0;
  display: grid;
}

.fx-sidebar-footer strong {
  color: #fff;
  font-size: .72rem;
}

.fx-sidebar-footer small {
  margin-top: 2px;
  color: #83a1bf;
  font-size: .62rem;
  white-space: nowrap;
}

.fx-topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  padding: 12px clamp(18px, 2.6vw, 38px);
  border-bottom: 1px solid #dfe7f0;
  background: rgba(255,255,255,.94);
  backdrop-filter: blur(16px);
}

.fx-topbar-left,
.fx-topbar-right,
.fx-topbar-user {
  min-width: 0;
  display: flex;
  align-items: center;
}

.fx-topbar-left {
  gap: 12px;
}

.fx-topbar-right {
  gap: 9px;
}

.fx-topbar-context {
  min-width: 0;
  display: grid;
}

.fx-topbar-context span {
  color: #718096;
  font-size: .65rem;
  font-weight: 800;
  letter-spacing: .1em;
}

.fx-topbar-context strong {
  margin-top: 2px;
  color: #10233f;
  font-size: .9rem;
}

.fx-topbar-menu-button,
.fx-topbar-icon-button {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border: 1px solid #dfe7f0;
  border-radius: 12px;
  color: #183a5d;
  background: #fff;
  cursor: pointer;
}

.fx-topbar-menu-button {
  display: none;
}

.fx-topbar-icon-button {
  position: relative;
}

.fx-topbar-notification-count {
  position: absolute;
  top: -5px;
  right: -5px;
  min-width: 20px;
  height: 20px;
  display: grid;
  place-items: center;
  padding: 0 5px;
  border: 2px solid #fff;
  border-radius: 999px;
  color: #fff;
  background: #c2413b;
  font-size: .62rem;
  font-weight: 900;
}

.fx-topbar-user {
  gap: 10px;
  margin-left: 5px;
  padding-left: 12px;
  border-left: 1px solid #e2e8f0;
}

.fx-topbar-avatar {
  flex: 0 0 40px;
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: #fff;
  background: linear-gradient(135deg, #18558f, #2f7fbd);
  font-size: .78rem;
  font-weight: 900;
}

.fx-topbar-user-copy {
  min-width: 0;
  display: grid;
  line-height: 1.25;
}

.fx-topbar-user-copy strong,
.fx-topbar-user-copy span {
  max-width: 210px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.fx-topbar-user-copy strong {
  color: #142033;
  font-size: .8rem;
}

.fx-topbar-user-copy span {
  margin-top: 2px;
  color: #718096;
  font-size: .68rem;
}

.fx-topbar-logout-form {
  margin: 0;
}

.fx-topbar-logout {
  min-height: 38px;
  padding: 0 13px;
  border: 1px solid #dfe7f0;
  border-radius: 10px;
  color: #4c5d72;
  background: #fff;
  font-size: .74rem;
  font-weight: 800;
  cursor: pointer;
}

.fx-topbar-logout:hover,
.fx-topbar-icon-button:hover,
.fx-topbar-menu-button:hover {
  color: #18558f;
  border-color: #bdd3e8;
  background: #f4f9fd;
}

.farox-workspace {
  width: 100%;
  max-width: 1680px;
  margin: 0 auto;
  padding: clamp(22px, 3vw, 42px);
}

.fx-sidebar-overlay {
  display: none;
}

/* Elimina visualmente los tonos morados heredados */
.fx-eyebrow,
.fx-panel-kicker {
  color: var(--fx-corporate-600);
}

.fx-kpi-violet:before,
.fx-kpi-pink:before {
  background: var(--fx-corporate-600);
}

.fx-kpi-source {
  color: var(--fx-corporate-700);
  background: var(--fx-corporate-100);
}

.fx-bar-income {
  background: linear-gradient(180deg, #60a5d8, #1f6fb2);
}

.fx-bar-expense {
  background: linear-gradient(180deg, #f0ad64, #d77822);
}

.fx-legend-income,
.fx-timeline-dot {
  background: #1f6fb2;
}

.fx-legend-expense {
  background: #d77822;
}

.fx-timeline-dot {
  box-shadow: 0 0 0 5px #e8f3fb;
}

.fx-goal-track i,
.fx-area-progress i {
  background: linear-gradient(90deg, #1f6fb2, #0f9d8a);
}

.fx-source-evida {
  background: #1f6fb2;
}

.fx-sidebar-collapsed .fx-app-shell {
  grid-template-columns: var(--fx-sidebar-collapsed-width) minmax(0, 1fr);
}

.fx-sidebar-collapsed .fx-sidebar-wordmark,
.fx-sidebar-collapsed .fx-sidebar-label,
.fx-sidebar-collapsed .fx-sidebar-section-title,
.fx-sidebar-collapsed .fx-sidebar-footer div,
.fx-sidebar-collapsed .fx-sidebar-active-dot {
  display: none;
}

.fx-sidebar-collapsed .fx-sidebar-brand {
  justify-content: center;
  padding-inline: 10px;
}

.fx-sidebar-collapsed .fx-sidebar-logo {
  justify-content: center;
}

.fx-sidebar-collapsed .fx-sidebar-isotipo {
  flex-basis: 42px;
  width: 42px;
  height: 42px;
}

.fx-sidebar-collapsed .fx-sidebar-collapse {
  position: absolute;
  top: 60px;
  right: -14px;
  z-index: 3;
  border-color: #d9e3ed;
  color: #0b2545;
  background: #fff;
  box-shadow: 0 7px 18px rgba(9,29,49,.18);
  transform: rotate(180deg);
}

.fx-sidebar-collapsed .fx-sidebar-nav {
  padding-inline: 10px;
}

.fx-sidebar-collapsed .fx-sidebar-link {
  justify-content: center;
  padding-inline: 0;
}

.fx-sidebar-collapsed .fx-sidebar-footer {
  justify-content: center;
  padding-inline: 0;
}

@media (max-width: 1199.98px) {
  :root {
    --fx-sidebar-width: 250px;
  }

  .fx-topbar-user-copy strong,
  .fx-topbar-user-copy span {
    max-width: 150px;
  }
}

@media (max-width: 991.98px) {
  .fx-app-shell,
  .fx-sidebar-collapsed .fx-app-shell {
    display: block;
  }

  .fx-sidebar {
    position: fixed;
    left: 0;
    top: 0;
    z-index: 90;
    width: min(88vw, 300px);
    transform: translateX(-105%);
    transition: transform .22s ease;
  }

  .fx-sidebar-open {
    overflow: hidden;
  }

  .fx-sidebar-open .fx-sidebar {
    transform: translateX(0);
  }

  .fx-sidebar-collapsed .fx-sidebar-wordmark,
  .fx-sidebar-collapsed .fx-sidebar-label,
  .fx-sidebar-collapsed .fx-sidebar-section-title,
  .fx-sidebar-collapsed .fx-sidebar-footer div,
  .fx-sidebar-collapsed .fx-sidebar-active-dot {
    display: initial;
  }

  .fx-sidebar-collapsed .fx-sidebar-label,
  .fx-sidebar-collapsed .fx-sidebar-footer div {
    display: grid;
  }

  .fx-sidebar-collapsed .fx-sidebar-section-title {
    display: block;
  }

  .fx-sidebar-collapsed .fx-sidebar-brand {
    justify-content: space-between;
    padding: 13px 16px;
  }

  .fx-sidebar-collapsed .fx-sidebar-collapse {
    position: static;
    border-color: rgba(255,255,255,.14);
    color: #dbe8f5;
    background: rgba(255,255,255,.06);
    box-shadow: none;
    transform: none;
  }

  .fx-sidebar-collapsed .fx-sidebar-link {
    justify-content: flex-start;
    padding-inline: 12px;
  }

  .fx-sidebar-collapsed .fx-sidebar-footer {
    justify-content: flex-start;
    padding: 15px 18px;
  }

  .fx-topbar-menu-button {
    display: grid;
  }

  .fx-sidebar-overlay {
    position: fixed;
    inset: 0;
    z-index: 80;
    display: block;
    border: 0;
    background: rgba(5, 19, 34, .52);
    opacity: 0;
    pointer-events: none;
    transition: opacity .22s ease;
  }

  .fx-sidebar-open .fx-sidebar-overlay {
    opacity: 1;
    pointer-events: auto;
  }
}

@media (max-width: 767.98px) {
  .fx-topbar {
    min-height: 66px;
    padding: 10px 13px;
  }

  .fx-topbar-search,
  .fx-topbar-user-copy {
    display: none;
  }

  .fx-topbar-user {
    padding-left: 8px;
  }

  .fx-topbar-context span {
    display: none;
  }

  .farox-workspace {
    padding: 18px 13px 28px;
  }
}

@media (max-width: 480px) {
  .fx-topbar-context {
    display: none;
  }

  .fx-topbar-right {
    margin-left: auto;
  }

  .fx-topbar-logout {
    padding-inline: 10px;
  }

  .fx-topbar-avatar {
    flex-basis: 36px;
    width: 36px;
    height: 36px;
  }
}


/* ==========================================================================
   FAROX — LOGOTIPO OFICIAL TRANSPARENTE EN SIDEBAR
   ========================================================================== */

.fx-sidebar-brand {
  min-height: 76px;
  gap: 8px;
  padding: 10px 11px;
}

.fx-sidebar-logo {
  flex: 1 1 auto;
  min-width: 0;
  height: 54px;
  display: flex;
  align-items: center;
  gap: 0;
  overflow: hidden;
}

.fx-sidebar-logo-expanded {
  display: block;
  width: min(168px, 100%);
  max-height: 52px;
  object-fit: contain;
  object-position: left center;
  filter: drop-shadow(0 5px 10px rgba(0, 0, 0, .22));
}

.fx-sidebar-logo-collapsed {
  display: none;
  width: 46px;
  height: 46px;
  object-fit: contain;
  filter: drop-shadow(0 5px 10px rgba(0, 0, 0, .22));
}

.fx-sidebar-isotipo,
.fx-sidebar-brand-copy,
.fx-sidebar-wordmark,
.fx-sidebar-brand-mark {
  display: none !important;
}

.fx-sidebar-collapse {
  flex: 0 0 32px;
  width: 32px;
  height: 32px;
}

.fx-sidebar-collapsed .fx-sidebar-logo-expanded {
  display: none;
}

.fx-sidebar-collapsed .fx-sidebar-logo-collapsed {
  display: block;
}

.fx-sidebar-collapsed .fx-sidebar-brand {
  justify-content: center;
  padding-inline: 8px;
}

.fx-sidebar-collapsed .fx-sidebar-logo {
  flex: 0 0 48px;
  width: 48px;
  height: 52px;
  justify-content: center;
}

@media (max-width: 991.98px) {
  .fx-sidebar-collapsed .fx-sidebar-logo-expanded {
    display: block;
  }

  .fx-sidebar-collapsed .fx-sidebar-logo-collapsed {
    display: none;
  }

  .fx-sidebar-collapsed .fx-sidebar-brand {
    justify-content: space-between;
    padding: 10px 11px;
  }

  .fx-sidebar-collapsed .fx-sidebar-logo {
    flex: 1 1 auto;
    width: auto;
    height: 54px;
    justify-content: flex-start;
  }
}


/* ==========================================================================
   FAROX — CORRECCIÓN DE RECOMENDACIONES EJECUTIVAS
   Limita los SVG de farox_nav_icon para evitar diagramas sobredimensionados.
   ========================================================================== */

.fx-insights-panel {
  width: 100%;
  margin-top: 20px;
  overflow: hidden;
}

.fx-insights-panel .fx-panel-header {
  margin-bottom: 16px;
}

.fx-insights-grid-contained {
  width: 100%;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.fx-insights-grid-contained .fx-insight-card {
  min-width: 0;
  min-height: 92px;
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
  padding: 14px;
  overflow: hidden;
  border: 1px solid var(--farox-line, #e4e7ec);
  border-radius: 12px;
  background: #ffffff;
  box-shadow: 0 3px 10px rgba(16, 24, 40, .035);
}

.fx-insights-grid-contained .fx-insight-icon {
  flex: 0 0 42px;
  width: 42px;
  height: 42px;
  max-width: 42px;
  max-height: 42px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border-radius: 10px;
}

.fx-insights-grid-contained .fx-insight-icon svg {
  width: 21px !important;
  height: 21px !important;
  min-width: 21px !important;
  min-height: 21px !important;
  max-width: 21px !important;
  max-height: 21px !important;
  display: block !important;
  overflow: visible;
  fill: none !important;
  stroke: currentColor !important;
  stroke-width: 1.8 !important;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.fx-insights-grid-contained .fx-insight-card > div {
  min-width: 0;
}

.fx-insights-grid-contained .fx-insight-card strong {
  display: block;
  color: var(--farox-ink, #172033);
  font-size: .78rem;
  font-weight: 750;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.fx-insights-grid-contained .fx-insight-card p {
  margin: 5px 0 0;
  color: var(--farox-muted, #667085);
  font-size: .69rem;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.fx-insights-grid-contained .fx-insight-warning .fx-insight-icon {
  color: #b54708;
  background: #fffaeb;
}

.fx-insights-grid-contained .fx-insight-danger .fx-insight-icon {
  color: #b42318;
  background: #fef3f2;
}

.fx-insights-grid-contained .fx-insight-info .fx-insight-icon {
  color: #175cd3;
  background: #eff8ff;
}

.fx-insights-grid-contained .fx-insight-neutral .fx-insight-icon {
  color: #475467;
  background: #f2f4f7;
}

.fx-insights-grid-contained .fx-insight-success .fx-insight-icon {
  color: #067647;
  background: #ecfdf3;
}

@media (max-width: 991.98px) {
  .fx-insights-grid-contained {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 575.98px) {
  .fx-insights-grid-contained .fx-insight-card {
    grid-template-columns: 38px minmax(0, 1fr);
    min-height: 84px;
    gap: 10px;
    padding: 12px;
  }

  .fx-insights-grid-contained .fx-insight-icon {
    width: 38px;
    height: 38px;
    max-width: 38px;
    max-height: 38px;
  }

  .fx-insights-grid-contained .fx-insight-icon svg {
    width: 19px !important;
    height: 19px !important;
    min-width: 19px !important;
    min-height: 19px !important;
    max-width: 19px !important;
    max-height: 19px !important;
  }
}

:root {
  --farox-navy: #07163f;
  --farox-blue: #126be8;
  --farox-cyan: #06cde0;
  --farox-violet: #7138f1;
  --farox-pink: #e3279a;
  --farox-orange: #ff9418;
  --farox-ink: #111d3c;
  --farox-muted: #65718a;
  --farox-surface: #ffffff;
  --farox-border: #dce3ef;
  --farox-danger: #b42318;
  --farox-danger-bg: #fff1f0;
  --farox-success: #067647;
  --farox-success-bg: #ecfdf3;
}

* {
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  min-width: 320px;
  min-height: 100%;
}

.farox-login-body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  overflow-x: hidden;
  color: var(--farox-ink);
  background: #f4f7fb;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

.login-shell {
  width: 100%;
  min-height: 100vh;
  min-height: 100dvh;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(420px, .8fr);
}

.login-brand-panel {
  position: relative;
  isolation: isolate;
  display: flex;
  align-items: center;
  overflow: hidden;
  padding: clamp(36px, 5vw, 78px);
  color: var(--farox-ink);
  background:
    radial-gradient(circle at 8% 10%, rgba(6, 205, 224, .14), transparent 30%),
    radial-gradient(circle at 92% 88%, rgba(18, 107, 232, .11), transparent 30%),
    linear-gradient(145deg, #ffffff 0%, #fbfdff 55%, #f4f8ff 100%);
}

.brand-content {
  position: relative;
  z-index: 3;
  width: min(100%, 940px);
  margin: 0 auto;
}

.brand-logo {
  display: block;
  width: min(100%, 900px);
  height: auto;
  margin: 0 auto;
  object-fit: contain;
  mix-blend-mode: multiply;
}

.brand-copy {
  max-width: 720px;
  margin: 24px auto 0;
  color: var(--farox-muted);
  font-size: clamp(1rem, 1.25vw, 1.18rem);
  line-height: 1.65;
  text-align: center;
}

.brand-ecosystem {
  width: min(100%, 830px);
  margin: 24px auto 0;
  padding: 12px 18px 6px;
  border: 1px solid rgba(18, 107, 232, .08);
  border-radius: 22px;
  background: rgba(255,255,255,.82);
  box-shadow: 0 18px 45px rgba(19, 53, 112, .08);
  backdrop-filter: blur(12px);
}

.brand-ecosystem-image {
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
  mix-blend-mode: multiply;
}

.brand-accent {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
}

.brand-accent-one {
  top: -170px;
  right: -140px;
  width: 430px;
  height: 430px;
  background: radial-gradient(circle, rgba(18, 107, 232, .12), transparent 68%);
}

.brand-accent-two {
  bottom: -210px;
  left: -150px;
  width: 520px;
  height: 520px;
  background: radial-gradient(circle, rgba(6, 205, 224, .12), transparent 68%);
}

.brand-grid {
  position: absolute;
  inset: 0;
  z-index: -1;
  opacity: .13;
  background-image:
    linear-gradient(rgba(7, 22, 63, .04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(7, 22, 63, .04) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: linear-gradient(to right, transparent, black 20%, black 80%, transparent);
}

.login-form-panel {
  min-width: 0;
  display: grid;
  place-items: center;
  padding:
    max(28px, env(safe-area-inset-top))
    max(28px, env(safe-area-inset-right))
    max(28px, env(safe-area-inset-bottom))
    max(28px, env(safe-area-inset-left));
  background:
    radial-gradient(circle at 100% 0%, rgba(18, 107, 232, .07), transparent 30%),
    linear-gradient(180deg, #f7f9fd, #eef3fa);
}

.login-card {
  width: min(100%, 470px);
  padding: clamp(28px, 4vw, 48px);
  border: 1px solid rgba(220, 227, 239, .96);
  border-radius: 28px;
  background: rgba(255, 255, 255, .98);
  box-shadow: 0 28px 80px rgba(15, 32, 70, .13);
}

.mobile-brand {
  display: none;
}

.login-kicker {
  margin: 0 0 12px;
  color: var(--farox-blue);
  font-size: .78rem;
  font-weight: 850;
  letter-spacing: .16em;
  text-transform: uppercase;
}

.login-header h1 {
  margin: 0;
  color: var(--farox-navy);
  font-size: clamp(2rem, 4vw, 2.65rem);
  line-height: 1.08;
  letter-spacing: -.045em;
}

.login-header > p:last-child {
  margin: 12px 0 0;
  color: var(--farox-muted);
  line-height: 1.65;
}

.login-alert {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  margin: 24px 0 0;
  padding: 14px 16px;
  border-radius: 14px;
  font-size: .93rem;
  line-height: 1.45;
}

.login-alert span {
  flex: 0 0 24px;
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  font-weight: 900;
}

.login-alert p {
  margin: 2px 0 0;
}

.login-alert-error {
  color: var(--farox-danger);
  background: var(--farox-danger-bg);
}

.login-alert-error span {
  color: #fff;
  background: var(--farox-danger);
}

.login-alert-success {
  color: var(--farox-success);
  background: var(--farox-success-bg);
}

.login-alert-success span {
  color: #fff;
  background: var(--farox-success);
}

.login-form {
  display: grid;
  gap: 22px;
  margin-top: 30px;
}

.field-group {
  display: grid;
  gap: 9px;
}

.field-group label {
  color: #283553;
  font-size: .9rem;
  font-weight: 750;
}

.input-wrap {
  position: relative;
}

.input-wrap input {
  width: 100%;
  min-height: 54px;
  padding: 0 16px 0 49px;
  border: 1px solid var(--farox-border);
  border-radius: 14px;
  outline: none;
  color: var(--farox-ink);
  background: #fbfcfe;
  font: inherit;
  transition: border-color .2s ease, box-shadow .2s ease, background .2s ease;
}

.input-wrap input:focus {
  border-color: var(--farox-blue);
  background: #fff;
  box-shadow: 0 0 0 4px rgba(18, 107, 232, .11);
}

.input-icon {
  position: absolute;
  top: 50%;
  left: 16px;
  z-index: 1;
  width: 20px;
  height: 20px;
  color: #8792aa;
  transform: translateY(-50%);
  pointer-events: none;
}

.input-icon svg {
  width: 100%;
  height: 100%;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.login-submit {
  min-height: 54px;
  border: 0;
  border-radius: 14px;
  color: #fff;
  background: linear-gradient(105deg, #126be8, #7138f1 52%, #e3279a);
  box-shadow: 0 14px 30px rgba(80, 55, 210, .24);
  font: inherit;
  font-weight: 850;
  cursor: pointer;
  transition: transform .2s ease, box-shadow .2s ease;
}

.login-submit:hover {
  transform: translateY(-1px);
  box-shadow: 0 18px 34px rgba(80, 55, 210, .30);
}

.login-submit:focus-visible {
  outline: 3px solid rgba(6, 205, 224, .45);
  outline-offset: 3px;
}

.login-footer {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  margin-top: 28px;
  padding-top: 22px;
  border-top: 1px solid #e8edf5;
  color: #7a859c;
  font-size: .78rem;
}

.login-footer p {
  margin: 0;
}

.login-footer span {
  flex: 0 0 auto;
}

@media (max-width: 1199.98px) {
  .login-shell {
    grid-template-columns: minmax(0, .95fr) minmax(410px, 1.05fr);
  }

  .login-brand-panel {
    padding: 30px;
  }

  .brand-ecosystem {
    width: min(100%, 720px);
  }
}

@media (max-width: 991.98px) {
  .login-shell {
    grid-template-columns: minmax(300px, .78fr) minmax(390px, 1.22fr);
  }

  .login-brand-panel {
    padding: 24px;
  }

  .brand-copy {
    font-size: .94rem;
  }

  .brand-ecosystem {
    padding: 8px 10px 3px;
    border-radius: 18px;
  }
}

@media (max-width: 767.98px) {
  .login-shell {
    display: block;
  }

  .login-brand-panel {
    display: none;
  }

  .login-form-panel {
    width: 100%;
    min-height: 100vh;
    min-height: 100dvh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding:
      max(18px, env(safe-area-inset-top))
      max(18px, env(safe-area-inset-right))
      max(18px, env(safe-area-inset-bottom))
      max(18px, env(safe-area-inset-left));
  }

  .login-card {
    width: 100%;
    max-width: 470px;
    padding: 28px 22px;
    border-radius: 22px;
  }

  .mobile-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 32px;
  }

  .mobile-brand-image {
    flex: 0 0 54px;
    width: 54px;
    height: 54px;
    border-radius: 15px;
    object-fit: cover;
    mix-blend-mode: multiply;
  }

  .mobile-brand strong,
  .mobile-brand span {
    display: block;
  }

  .mobile-brand strong {
    color: var(--farox-navy);
    font-size: 1.08rem;
    font-weight: 950;
    letter-spacing: .08em;
  }

  .mobile-brand span {
    margin-top: 3px;
    color: var(--farox-muted);
    font-size: .7rem;
  }

  .login-footer {
    display: grid;
    gap: 11px;
    text-align: center;
  }
}

@media (max-width: 380px) {
  .login-form-panel {
    padding: 10px;
  }

  .login-card {
    padding: 23px 16px;
    border-radius: 18px;
  }

  .mobile-brand {
    margin-bottom: 25px;
  }

  .mobile-brand-image {
    flex-basis: 48px;
    width: 48px;
    height: 48px;
  }

  .input-wrap input,
  .login-submit {
    min-height: 52px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition: none !important;
    animation: none !important;
  }
}
/*
 * This is a manifest file that'll be compiled into application.css, which will include all the files
 * listed below.
 *
 * Any CSS (and SCSS, if configured) file within this directory, lib/assets/stylesheets, or any plugin's
 * vendor/assets/stylesheets directory can be referenced here using a relative path.
 *
 * You're free to add application-wide styles to this file and they'll appear at the bottom of the
 * compiled file so the styles you add here take precedence over styles defined in any other CSS
 * files in this directory. Styles in this file should be added after the last require_* statement.
 * It is generally better to create a new file per style scope.
 *


 */
