@media (max-width:1200px){
  .stats-grid{grid-template-columns:repeat(3,minmax(0,1fr))}
  .project-pulse{grid-template-columns:repeat(2,minmax(0,1fr))}
  .pulse-count-grid{grid-template-columns:repeat(3,minmax(0,1fr))}
}
@media (max-width:860px){
  .app-shell{padding:14px}
  .hero-panel{flex-direction:column;gap:14px;padding:17px}
  .hero-copy{max-width:none;width:100%}
  .topbar-actions{justify-content:flex-start;width:100%}
  .two-col,.contractor-layout{grid-template-columns:1fr}
  .section-heading{align-items:flex-start;flex-direction:column;gap:6px}
  .section-note{text-align:left;max-width:none}
  .stats-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .tabs{top:5px}
  .project-pulse{grid-template-columns:1fr}
  .pulse-count-grid{grid-template-columns:repeat(5,minmax(0,1fr))}
}
@media (max-width:620px){
  body{background:#f7f9fc}
  .app-shell{padding:9px;overflow-x:hidden}
  .hero-panel{padding:14px 13px 13px;margin-bottom:9px;border-left-width:4px;border-radius:10px}
  h1{font-size:28px;margin-bottom:4px}
  h2{font-size:21px}
  .subtitle{font-size:11.5px;line-height:1.4}
  .topbar-actions{display:grid;grid-template-columns:1fr 1fr;gap:6px}
  .status-pill{grid-column:1/-1;justify-content:center;min-height:38px}
  .button{width:100%;min-height:40px;padding:9px 10px}
  .stats-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:6px;margin-bottom:9px}
  .stat-card{min-height:76px;padding:8px 9px;border-radius:9px}
  .stat-label{font-size:9.2px}
  .stat-marker{width:7px;height:7px}
  .stat-value{font-size:19px;margin:4px 0 2px}
  .stat-foot{font-size:8.6px}
  .tabs{margin-bottom:10px;border-radius:9px;padding:3px;gap:3px}
  .tab{flex:1;padding:9px 8px;font-size:10.8px;text-align:center}
  .section-heading{margin-bottom:8px}
  .section-heading .eyebrow{font-size:9px}
  .section-note{font-size:10.5px;line-height:1.35}
  .card{padding:10px;border-radius:10px}
  .card-heading{margin-bottom:9px;gap:7px}
  .card-heading h3{font-size:14px}
  .card-heading p{font-size:9.8px}
  .mini-tag{font-size:8.5px;padding:4px 6px}
  .project-pulse-shell{padding:9px}
  .project-pulse{gap:8px}
  .pulse-card{padding:10px;border-radius:10px}
  .pulse-title{margin-bottom:8px}
  .pulse-project-name{font-size:15px}
  .score-pill{font-size:8.8px;padding:4px 6px}
  .pulse-section-label{margin:8px 0 5px;font-size:8px}
  .delivery-list{gap:5px}
  .delivery-row{padding:7px}
  .delivery-head{grid-template-columns:minmax(0,1fr) auto;gap:3px 6px;margin-bottom:4px}
  .delivery-label{font-size:9.4px}
  .delivery-count{grid-column:1;font-size:8.3px;white-space:normal}
  .delivery-rate{grid-column:2;grid-row:1/3;align-self:center;font-size:9.4px}
  .metric-track{height:5px}
  .pulse-count-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:5px}
  .pulse-metric:last-child{grid-column:span 2}
  .pulse-metric{padding:6px}
  .pulse-metric span{font-size:7.8px}
  .pulse-metric strong{font-size:11px}
  .quality-summary{padding:7px}
  .ncr-detail{font-size:8px;white-space:normal}
  .ncr-rate{font-size:12px}
  .contractor-card,.quality-card{padding:10px}
  .accordion-list,.quality-groups{gap:6px}
  .contractor-detail{border-radius:9px}
  .contractor-detail summary{grid-template-columns:minmax(0,1fr) auto;gap:5px 7px;padding:10px}
  .contractor-name{font-size:12.5px}
  .contractor-meta{grid-column:1;font-size:9.5px}
  .contractor-detail summary .score-pill{grid-column:2;grid-row:1}
  .chevron{grid-column:2;grid-row:2;font-size:15px;justify-self:end}
  .detail-body{padding:0 10px 9px}
  .contractor-project-row{grid-template-columns:minmax(82px,1fr) minmax(76px,1.25fr) 40px;gap:6px;padding:8px 0;font-size:9.5px}
  .quality-group{padding:10px;border-radius:9px}
  .quality-group-head strong{font-size:12px}
  .quality-item{padding:7px 0;font-size:10px}
  footer{flex-direction:column;gap:4px;padding-top:12px}
}
@media (max-width:370px){
  .stats-grid{grid-template-columns:1fr 1fr;gap:5px}
  .stat-card{padding:7px 8px;min-height:72px}
  .stat-value{font-size:18px}
  .pulse-count-grid{grid-template-columns:1fr 1fr}
  .contractor-project-row{grid-template-columns:1fr 1fr 36px;font-size:9px}
}

@page{size:A4 portrait;margin:6mm}
@media print{
  *{-webkit-print-color-adjust:exact!important;print-color-adjust:exact!important;animation:none!important;transition:none!important;box-shadow:none!important}
  html,body{width:auto!important;height:auto!important;background:#fff!important;color:#13233b!important;overflow:visible!important}
  body{margin:0!important;padding:0!important;font-size:7pt!important}
  .app-shell{max-width:none!important;width:198mm!important;min-height:285mm!important;margin:0!important;padding:0!important;display:flex!important;flex-direction:column!important}
  .hero-panel{display:flex!important;flex-direction:row!important;align-items:center!important;justify-content:space-between!important;margin:0 0 2mm!important;border-radius:1.5mm!important;padding:2.4mm 3mm!important;min-height:12mm!important;border-left-width:3px!important}
  .hero-copy{max-width:none!important}.hero-panel h1{font-size:15pt!important;line-height:1!important;margin:0!important}.hero-panel .eyebrow,.hero-panel .subtitle{display:none!important}.topbar-actions{display:none!important}
  .stats-grid{grid-template-columns:repeat(6,minmax(0,1fr))!important;gap:1.3mm!important;margin:0 0 2.2mm!important}
  .stat-card{min-height:16.5mm!important;border-radius:1.5mm!important;padding:1.7mm 1.8mm!important;border-top-width:2px!important}
  .stat-top{gap:1mm!important}.stat-label{font-size:6.1pt!important;line-height:1.1!important}.stat-marker{width:1.5mm!important;height:1.5mm!important;border-radius:.35mm!important}.stat-value{font-size:11.4pt!important;line-height:1!important;margin:1.1mm 0 .65mm!important}.stat-foot{font-size:5.7pt!important;line-height:1.1!important}
  .tabs,footer{display:none!important}
  main{display:flex!important;flex-direction:column!important;gap:2mm!important;margin:0!important;padding:0!important;flex:1!important}
  .tab-panel,.tab-panel.active{display:block!important;margin:0!important;padding:0!important}
  .report-page,.report-page-overview,.report-page-contractors{break-before:auto!important;break-after:auto!important;page-break-before:auto!important;page-break-after:auto!important;break-inside:avoid!important}
  .report-page-overview>.section-heading{display:none!important}.print-page-heading{display:none!important}
  .report-page-overview{min-height:83mm!important}
  .card{border-radius:1.5mm!important;padding:2mm!important;border-top-width:2px!important}
  .card-heading{margin-bottom:1.4mm!important}.card-heading h3{font-size:9pt!important;margin:0!important}.card-heading p{font-size:5.8pt!important;line-height:1.15!important;margin-top:.4mm!important}.mini-tag{display:none!important}
  .project-pulse-shell{padding:2mm!important;min-height:81mm!important}.pulse-heading{margin-bottom:1.4mm!important}
  .project-pulse{grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:1.4mm!important;align-items:stretch!important}
  .pulse-card{border-radius:1.5mm!important;padding:1.8mm!important;border-top-width:2px!important;transform:none!important;min-height:72mm!important;display:flex!important;flex-direction:column!important}
  .pulse-title{margin-bottom:1.2mm!important;gap:.8mm!important}.pulse-project-name{font-size:9pt!important}.score-pill{font-size:5.8pt!important;padding:.7mm 1mm!important;border-radius:.9mm!important}
  .pulse-section-label{font-size:5.25pt!important;letter-spacing:.06em!important;margin:1.35mm 0 .75mm!important;gap:.55mm!important}.pulse-section-label::before{width:1mm!important;height:1mm!important}
  .delivery-list{gap:.8mm!important}.delivery-row{padding:1mm 1.15mm!important;border-radius:1mm!important}.delivery-head{gap:.6mm!important;margin-bottom:.55mm!important}.delivery-label{font-size:5.9pt!important}.delivery-count{font-size:5.2pt!important}.delivery-rate{font-size:5.9pt!important}.metric-track{height:1mm!important}
  .pulse-count-grid{grid-template-columns:repeat(5,minmax(0,1fr))!important;gap:.65mm!important}.pulse-metric{padding:.9mm .75mm!important;border-radius:.9mm!important}.pulse-metric span{font-size:4.65pt!important;margin-bottom:.3mm!important;line-height:1.05!important}.pulse-metric strong{font-size:6.7pt!important;line-height:1.05!important}
  .quality-summary{padding:1.05mm!important;border-radius:1mm!important;margin-top:auto!important}.ncr-line{gap:.65mm!important}.ncr-title{font-size:5.8pt!important;margin-bottom:.2mm!important}.ncr-detail{font-size:4.8pt!important}.ncr-rate{font-size:7.7pt!important}.ncr-stack{height:1mm!important;margin:.65mm 0 .8mm!important}.sla-row{gap:.5mm!important}.sla-label{font-size:5.3pt!important}.sla-rate{font-size:5.6pt!important}.sla-track{height:1mm!important}
  .report-page-contractors{margin-top:0!important;min-height:157mm!important;display:flex!important;flex-direction:column!important}
  .report-page-contractors>.section-heading{display:flex!important;align-items:center!important;justify-content:space-between!important;margin:0 0 1.2mm!important;min-height:8mm!important;border-top:1px solid #dce4ee!important;padding-top:1.2mm!important}
  .report-page-contractors>.section-heading .eyebrow,.report-page-contractors>.section-heading .section-note{display:none!important}.report-page-contractors>.section-heading h2{font-size:10pt!important;margin:0!important;line-height:1!important}
  .contractor-layout{grid-template-columns:1.65fr .9fr!important;gap:1.4mm!important;align-items:stretch!important;flex:1!important}
  .contractor-card,.quality-card{padding:1.6mm!important;min-height:145mm!important;display:flex!important;flex-direction:column!important}
  .contractor-card .card-heading,.quality-card .card-heading{margin-bottom:1.1mm!important}.contractor-card .card-heading h3,.quality-card .card-heading h3{font-size:7.8pt!important}
  .accordion-list,.quality-groups{gap:.8mm!important}
  .contractor-detail{border-radius:1mm!important;border-left-width:2px!important;break-inside:avoid!important}
  .contractor-detail summary{padding:1mm 1.15mm!important;grid-template-columns:1fr auto!important;gap:.75mm!important}
  .contractor-name{font-size:6.7pt!important;line-height:1.05!important}.contractor-meta{font-size:5.2pt!important;line-height:1!important}.contractor-detail summary .score-pill{font-size:5.2pt!important;padding:.55mm .8mm!important}.contractor-detail summary .chevron{display:none!important}
  .detail-body{display:block!important;padding:0 1.15mm .85mm!important}
  .contractor-project-row{grid-template-columns:minmax(24mm,1fr) 1.6fr 10.5mm!important;gap:1mm!important;padding:.7mm 0!important;font-size:5.5pt!important;line-height:1.05!important}.contractor-project-row .bar-track{height:.9mm!important}
  .quality-groups{flex:1!important}.quality-group{border-radius:1mm!important;padding:1.1mm!important;border-left-width:2px!important;break-inside:avoid!important}.quality-group-head{margin-bottom:.55mm!important}.quality-group-head strong{font-size:6.6pt!important}.count-badge{font-size:5.1pt!important;padding:.55mm .8mm!important;border-radius:.8mm!important}.quality-item{padding:.75mm 0!important;font-size:5.5pt!important;line-height:1.1!important}
}
