
.p4-page{
  width:min(1460px,calc(100% - 48px));
  margin:0 auto;
  padding:42px 0 72px;
  color:#e9f4ff;
}

.p4-page *{
  box-sizing:border-box;
}


/* header */

.topbar{
  min-height:74px;
  display:flex;
  align-items:center;
  gap:28px;
  padding:0 28px;
}

.topbar .brand{
  flex:0 0 auto;
  display:flex;
  align-items:center;
  gap:11px;
  min-width:210px;
  text-decoration:none;
}

.topbar .brand-mark-wrap{
  flex:0 0 42px;
  width:42px;
  height:42px;
  display:flex;
  align-items:center;
  justify-content:center;
  overflow:hidden;
  border-radius:11px;
}

.topbar .brand-mark{
  display:block;
  width:42px !important;
  height:42px !important;
  max-width:42px !important;
  object-fit:cover;
}

.topbar .brand > span:last-child{
  display:flex;
  flex-direction:column;
  line-height:1.15;
}

.topbar .brand b{
  font-size:16px;
  white-space:nowrap;
}

.topbar .brand small{
  margin-top:4px;
  font-size:9px;
  white-space:nowrap;
}

.topbar .nav{
  flex:1 1 auto;
  display:flex;
  justify-content:center;
  min-width:0;
}

.topbar .worker-health{
  flex:0 0 auto;
  min-width:205px;
  max-width:220px;
  text-align:right;
}

.topbar .worker-health small{
  display:block;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}


/* shared cards */

.p4-hero>div,
.p4-hero-side,
.p4-controls,
.p4-overview article,
.p4-section,
.p4-panel,
.p4-method{
  border:1px solid rgba(90,142,184,.24);
  background:
    linear-gradient(
      145deg,
      rgba(14,35,55,.94),
      rgba(7,20,34,.97)
    );
  box-shadow:
    0 22px 55px rgba(0,0,0,.20),
    inset 0 1px 0 rgba(255,255,255,.025);
}


/* hero */

.p4-hero{
  display:grid;
  grid-template-columns:minmax(0,1.5fr) minmax(310px,.7fr);
  gap:20px;
}

.p4-hero>div{
  position:relative;
  overflow:hidden;
  padding:46px;
  border-radius:22px;
}

.p4-hero>div:after{
  content:"";
  position:absolute;
  right:-170px;
  top:-230px;
  width:430px;
  height:430px;
  border-radius:50%;
  background:rgba(41,221,213,.08);
  filter:blur(15px);
}

.p4-kicker{
  margin-bottom:12px;
  color:#68e6e0;
  font-size:11px;
  font-weight:800;
  letter-spacing:.13em;
}

.p4-hero h1{
  max-width:850px;
  margin:0;
  font-size:clamp(38px,4.7vw,67px);
  line-height:1.02;
  letter-spacing:-.045em;
}

.p4-hero h1 span{
  color:#75ebe5;
}

.p4-hero>div>p{
  max-width:840px;
  margin:22px 0 0;
  color:#a7bbcd;
  font-size:16px;
  line-height:1.75;
}

.p4-trust{
  display:flex;
  flex-wrap:wrap;
  gap:9px;
  margin-top:28px;
}

.p4-trust span{
  padding:8px 11px;
  border:1px solid rgba(87,155,193,.22);
  border-radius:999px;
  background:#081927;
  color:#9eb4c6;
  font-size:11px;
}

.p4-hero-side{
  display:flex;
  flex-direction:column;
  justify-content:center;
  padding:31px;
  border-radius:22px;
}

.p4-hero-side small{
  color:#65ddd7;
  font-size:10px;
  font-weight:800;
  letter-spacing:.1em;
  text-transform:uppercase;
}

.p4-hero-side strong{
  margin-top:16px;
  font-size:22px;
  line-height:1.35;
}

.p4-hero-side p{
  margin:14px 0;
  color:#7f9aaf;
  font-size:12px;
  line-height:1.65;
}

.p4-hero-side a,
.p4-section-head a,
.p4-panel a{
  color:#6ee8e1;
  text-decoration:none;
  font-size:12px;
  font-weight:700;
}


/* controls */

.p4-controls{
  display:grid;
  grid-template-columns:1.4fr .8fr auto;
  gap:13px;
  align-items:end;
  margin-top:20px;
  padding:18px;
  border-radius:16px;
}

.p4-control{
  display:flex;
  flex-direction:column;
  gap:7px;
}

.p4-control label{
  color:#86a0b6;
  font-size:11px;
  font-weight:700;
}

.p4-control small{
  color:#58728a;
  font-size:10px;
}

.p4-control select{
  min-height:44px;
  padding:0 38px 0 13px;
  border:1px solid #1f3d56;
  border-radius:9px;
  outline:none;
  background:#071724;
  color:#e5f2fc;
  font:inherit;
}

.p4-control select:focus{
  border-color:#39dcd6;
  box-shadow:0 0 0 3px rgba(57,220,214,.08);
}

.p4-update{
  min-height:44px;
  padding:0 20px;
  border:1px solid rgba(67,230,221,.5);
  border-radius:9px;
  background:linear-gradient(180deg,#153e54,#102f43);
  color:#c8fffb;
  font-weight:800;
  cursor:pointer;
}

.p4-update:disabled{
  opacity:.6;
  cursor:wait;
}

.p4-warning{
  margin-top:14px;
  padding:14px 16px;
  border:1px solid rgba(255,179,71,.35);
  border-radius:11px;
  background:rgba(106,65,16,.22);
  color:#ffd99d;
}


/* stats */

.p4-overview{
  display:grid;
  grid-template-columns:repeat(4,1fr);
  gap:12px;
  margin-top:16px;
}

.p4-overview article{
  min-height:125px;
  padding:20px;
  border-radius:15px;
}

.p4-overview small{
  color:#7590a7;
  font-size:11px;
}

.p4-overview strong{
  display:block;
  margin:8px 0 7px;
  font-size:25px;
  letter-spacing:-.03em;
}

.p4-overview span{
  color:#607d94;
  font-size:11px;
  line-height:1.5;
}


/* provider grid */

.p4-section,
.p4-method{
  margin-top:18px;
  padding:25px;
  border-radius:18px;
}

.p4-section-head{
  display:flex;
  justify-content:space-between;
  gap:25px;
  align-items:flex-start;
  margin-bottom:21px;
}

.p4-section-head h2,
.p4-panel h2,
.p4-method h2{
  margin:0;
  font-size:23px;
  letter-spacing:-.025em;
}

.p4-section-head p,
.p4-panel p{
  max-width:780px;
  margin:8px 0 0;
  color:#7895aa;
  font-size:13px;
  line-height:1.6;
}

.p4-provider-grid{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(330px,1fr));
  gap:14px;
}

.p4-provider{
  position:relative;
  padding:22px;
  border:1px solid #1d3a51;
  border-radius:15px;
  background:
    radial-gradient(
      circle at 100% 0,
      rgba(55,218,210,.09),
      transparent 42%
    ),
    #081927;
}

.p4-provider.eligible{
  border-color:rgba(61,211,201,.3);
}

.p4-provider-head{
  display:flex;
  justify-content:space-between;
  gap:15px;
  align-items:flex-start;
}

.p4-provider h3{
  margin:0;
  font-size:22px;
  letter-spacing:-.02em;
}

.p4-state{
  padding:5px 8px;
  border-radius:999px;
  font-size:9px;
  font-weight:900;
  text-transform:uppercase;
  letter-spacing:.05em;
}

.p4-state.ready{
  background:rgba(36,139,91,.18);
  color:#61e9a6;
}

.p4-state.collecting{
  background:rgba(163,115,25,.18);
  color:#ffd16d;
}

.p4-protocol{
  margin-top:5px;
  color:#7694a9;
  font-size:12px;
}

.p4-provider-score{
  display:flex;
  align-items:flex-end;
  gap:8px;
  margin-top:22px;
}

.p4-provider-score strong{
  color:#7aeee7;
  font-size:38px;
  line-height:1;
  letter-spacing:-.05em;
}

.p4-provider-score span{
  padding-bottom:4px;
  color:#708da3;
  font-size:11px;
}

.p4-provider-metrics{
  display:grid;
  grid-template-columns:repeat(3,1fr);
  gap:8px;
  margin-top:21px;
}

.p4-provider-metrics div{
  padding:12px;
  border:1px solid #19354a;
  border-radius:10px;
  background:#071724;
}

.p4-provider-metrics small{
  display:block;
  margin-bottom:6px;
  color:#647f95;
  font-size:9px;
}

.p4-provider-metrics strong{
  font-size:12px;
}

.p4-provider-foot{
  display:flex;
  justify-content:space-between;
  gap:10px;
  align-items:center;
  margin-top:15px;
  color:#607d92;
  font-size:10px;
}

.p4-placeholder{
  grid-column:1/-1;
  padding:28px;
  border:1px dashed #25465d;
  border-radius:13px;
  color:#6f8ba0;
}


/* lower panels */

.p4-two-col{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:18px;
}

.p4-panel{
  margin-top:18px;
  padding:25px;
  border-radius:18px;
}

.p4-panel a{
  display:inline-block;
  margin-top:17px;
}


/* metric definitions */

.p4-method-grid{
  display:grid;
  grid-template-columns:repeat(4,1fr);
  gap:12px;
  margin-top:20px;
}

.p4-method-grid article{
  padding:17px;
  border:1px solid #1a364b;
  border-radius:12px;
  background:#081927;
}

.p4-method-grid article>span{
  color:#51dcd7;
  font-size:10px;
  font-weight:900;
}

.p4-method-grid h3{
  margin:11px 0 7px;
  font-size:14px;
}

.p4-method-grid p{
  margin:0;
  color:#7692a7;
  font-size:11px;
  line-height:1.6;
}


@media(max-width:1100px){

  .topbar{
    gap:14px;
    padding-left:18px;
    padding-right:18px;
  }

  .topbar .brand{
    min-width:auto;
  }

  .topbar .brand small,
  .topbar .worker-health{
    display:none;
  }

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

  .p4-overview{
    grid-template-columns:1fr 1fr;
  }

  .p4-method-grid{
    grid-template-columns:1fr 1fr;
  }

}


@media(max-width:720px){

  .p4-page{
    width:min(100% - 24px,1460px);
    padding-top:20px;
  }

  .p4-hero>div{
    padding:27px 22px;
  }

  .p4-hero h1{
    font-size:38px;
  }

  .p4-controls,
  .p4-overview,
  .p4-two-col,
  .p4-method-grid{
    grid-template-columns:1fr;
  }

  .p4-provider-grid{
    grid-template-columns:1fr;
  }

  .p4-provider-metrics{
    grid-template-columns:1fr 1fr 1fr;
  }

  .p4-section-head{
    display:block;
  }

}
