
/* V438I - Profit Intelligence */
.v438i-profit-health,
.v438i-attention,
.v438i-bridge,
.v438i-forecast{
  margin-bottom:12px;
  padding:14px;
  border:1px solid var(--border);
  border-radius:12px;
  background:var(--card);
}
.v438i-section-head{
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  gap:12px;
  margin-bottom:11px;
}
.v438i-section-head>div>span{
  display:block;
  font-size:8px;
  font-weight:800;
  letter-spacing:.08em;
  color:var(--muted-foreground);
}
.v438i-section-head h2,
.v438i-section-head h3{
  margin:3px 0 0;
  font-size:13px;
}
.v438i-section-head>small{
  max-width:420px;
  text-align:right;
  font-size:8.5px;
  color:var(--muted-foreground);
}
.v438i-health-grid{
  display:grid;
  grid-template-columns:repeat(7,minmax(0,1fr));
  gap:8px;
}
.v438i-health-grid article,
.v438i-attention-grid article,
.v438i-forecast-grid article{
  min-height:94px;
  padding:11px;
  border:1px solid var(--border);
  border-radius:9px;
  background:var(--background);
}
.v438i-health-grid span,
.v438i-attention-grid span,
.v438i-forecast-grid span{
  display:block;
  font-size:8px;
  font-weight:750;
  color:var(--muted-foreground);
}
.v438i-health-grid b,
.v438i-attention-grid b,
.v438i-forecast-grid b{
  display:block;
  margin-top:6px;
  font-size:17px;
  line-height:1.05;
  font-variant-numeric:tabular-nums;
}
.v438i-health-grid small,
.v438i-attention-grid small,
.v438i-forecast-grid small{
  display:block;
  margin-top:6px;
  font-size:7.4px;
  line-height:1.35;
  color:var(--muted-foreground);
}
.v438i-health-grid small.up,
.v438i-compare-list .up{color:#15803d}
.v438i-health-grid small.down,
.v438i-compare-list .down{color:#b91c1c}
.v438i-net-card,
.v438i-debt-card{
  position:relative;
  overflow:hidden;
}
.v438i-net-card:after,
.v438i-debt-card:after{
  content:"";
  position:absolute;
  left:0;right:0;bottom:0;height:3px;
}
.v438i-net-card:after{background:#16a34a}
.v438i-debt-card:after{background:#7c3aed}

.v438i-attention-grid{
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:8px;
}
.v438i-attention-grid article{
  position:relative;
  overflow:hidden;
}
.v438i-attention-grid article:after{
  content:"";
  position:absolute;
  left:0;right:0;bottom:0;height:3px;
}
.v438i-attention-grid .loss:after{background:#dc2626}
.v438i-attention-grid .margin:after{background:#f59e0b}
.v438i-attention-grid .operating:after{background:#ea580c}
.v438i-attention-grid .supplier:after{background:#7c3aed}

.v438i-bridge-flow{
  display:grid;
  grid-template-columns:repeat(5,minmax(0,1fr) auto) minmax(0,1fr);
  align-items:center;
  gap:7px;
}
.v438i-bridge-flow article{
  min-width:0;
  padding:10px;
  border:1px solid var(--border);
  border-radius:9px;
  background:var(--background);
}
.v438i-bridge-flow article span{
  display:block;
  font-size:7.5px;
  color:var(--muted-foreground);
}
.v438i-bridge-flow article b{
  display:block;
  margin-top:5px;
  font-size:12px;
  font-variant-numeric:tabular-nums;
  overflow-wrap:anywhere;
}
.v438i-bridge-flow i{
  font-style:normal;
  font-size:16px;
  font-weight:700;
  color:var(--muted-foreground);
}
.v438i-bridge-flow .positive b{color:#15803d}
.v438i-bridge-flow .result{
  border-color:#86efac;
  background:#f0fdf4;
}
.v438i-bridge-flow .result b{color:#15803d}

.v438i-analytics-grid{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:9px;
  margin-bottom:12px;
}
.v438i-chart-card,
.v438i-compare-card{
  min-width:0;
  padding:11px;
  border:1px solid var(--border);
  border-radius:10px;
  background:var(--card);
}
.v438i-chart-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:8px;
  margin-bottom:5px;
}
.v438i-chart-head h4{
  margin:0;
  font-size:10.5px;
}
.v438i-chart-head small{
  font-size:7.6px;
  color:var(--muted-foreground);
}
.v438i-compare-list{
  display:flex;
  flex-direction:column;
}
.v438i-compare-list>div{
  display:grid;
  grid-template-columns:1fr auto auto;
  align-items:center;
  gap:8px;
  min-height:42px;
  padding:7px 0;
  border-bottom:1px solid var(--border);
}
.v438i-compare-list>div:last-child{border-bottom:0}
.v438i-compare-list span{font-size:8px;color:var(--muted-foreground)}
.v438i-compare-list b{font-size:9px;font-variant-numeric:tabular-nums}
.v438i-compare-list em{
  min-width:52px;
  text-align:right;
  font-style:normal;
  font-size:8px;
  font-weight:700;
}

.v438i-forecast-grid{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:8px;
}

@media(max-width:1200px){
  .v438i-health-grid{grid-template-columns:repeat(4,minmax(0,1fr))}
  .v438i-bridge-flow{
    grid-template-columns:1fr auto 1fr auto 1fr;
  }
  .v438i-bridge-flow article:nth-of-type(n+4),
  .v438i-bridge-flow i:nth-of-type(n+4){
    margin-top:7px;
  }
}

@media(max-width:760px){
  .v438i-profit-health,
  .v438i-attention,
  .v438i-bridge,
  .v438i-forecast{
    margin-bottom:9px;
    padding:10px;
    border-radius:10px;
  }
  .v438i-section-head{
    flex-direction:column;
    align-items:flex-start;
    gap:4px;
    margin-bottom:8px;
  }
  .v438i-section-head>small{
    max-width:none;
    text-align:left;
    font-size:7px;
  }
  .v438i-section-head h2,
  .v438i-section-head h3{font-size:11px}

  .v438i-health-grid{
    grid-template-columns:1fr 1fr!important;
    gap:6px;
  }
  .v438i-health-grid article{
    min-height:88px;
    padding:9px;
  }
  .v438i-health-grid article:last-child:nth-child(odd){
    grid-column:1/-1;
  }
  .v438i-health-grid b,
  .v438i-attention-grid b,
  .v438i-forecast-grid b{
    font-size:14px;
    overflow-wrap:anywhere;
  }

  .v438i-attention-grid{
    grid-template-columns:1fr 1fr;
    gap:6px;
  }
  .v438i-attention-grid article{
    min-height:84px;
    padding:9px;
  }

  .v438i-bridge-flow{
    display:flex;
    flex-direction:column;
    align-items:stretch;
    gap:5px;
  }
  .v438i-bridge-flow article{
    padding:9px;
  }
  .v438i-bridge-flow i{
    align-self:center;
    transform:rotate(90deg);
    font-size:13px;
  }

  .v438i-analytics-grid{
    grid-template-columns:1fr;
    gap:7px;
    margin-bottom:9px;
  }
  .v438i-chart-card,
  .v438i-compare-card{
    padding:8px;
  }
  .v438i-chart-card .recharts-responsive-container{
    height:210px!important;
    min-height:210px!important;
  }
  .v438i-chart-head h4{font-size:9.5px}
  .v438i-chart-head small{font-size:6.9px}

  .v438i-forecast-grid{
    grid-template-columns:1fr;
    gap:6px;
  }
  .v438i-forecast-grid article{
    min-height:76px;
    padding:9px;
  }
}

@media(max-width:390px){
  .v438i-health-grid,
  .v438i-attention-grid{
    grid-template-columns:1fr!important;
  }
  .v438i-health-grid article:last-child:nth-child(odd){
    grid-column:auto;
  }
}
