/* subopen1 – subcontractor dashboard graphics, crew readiness, Work shifts myself, office hours card (js/v2-subopen.js).
   Navy #332E57 + gold #D9A03C like the rest of the app. Phone-first (390 px). Motion only when allowed. */
.so-hero { --so-ind: #332E57; --so-gold: #D9A03C; margin: 0 0 14px; }
.so-banner { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; background: linear-gradient(135deg, #332E57 0%, #46407a 100%);
  color: #fff; border-radius: 14px 14px 0 0; padding: 14px 16px 16px; border-bottom: 4px solid #D9A03C; }
.so-bt { min-width: 0; }
.so-kicker { display: block; font-size: 11px; font-weight: 700; letter-spacing: .6px; text-transform: uppercase; color: #f0d9a8; }
.so-banner h1 { margin: 2px 0 2px; font-size: 22px; line-height: 1.2; color: #fff; overflow-wrap: anywhere; }
.so-sub { font-size: 13px; color: #d9d5ea; }
.so-status { flex: 0 0 auto; font-size: 12px; font-weight: 800; padding: 4px 10px; border-radius: 999px; white-space: nowrap; margin-top: 2px; }
.so-st-ok { background: #e3f3e8; color: #1f6b3a; } .so-st-bad { background: #fbe9e7; color: #a5281b; } .so-st-temp { background: #f3eefa; color: #5e3f8f; }
.so-kpis { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; background: #f4f2fa; border-radius: 0 0 14px 14px; padding: 10px; }
@media (min-width: 900px) { .so-kpis { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
a.so-kpi { display: flex; flex-direction: column; min-width: 0; background: #fff; border-radius: 12px; padding: 10px 11px; text-decoration: none; color: #222;
  box-shadow: 0 1px 2px rgba(51,46,87,.10); border: 1px solid #e6e3f0; position: relative; }
a.so-kpi:hover, a.so-kpi:focus { text-decoration: none; border-color: #D9A03C; color: #222; }
.so-kl { font-size: 11px; font-weight: 700; color: #332E57; text-transform: uppercase; letter-spacing: .3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
a.so-kpi b { font-size: 30px; line-height: 1.1; font-weight: 800; color: #332E57; font-variant-numeric: tabular-nums; letter-spacing: -.5px; }
a.so-kpi small { font-size: 12px; color: #5b567a; overflow-wrap: anywhere; }
.so-live { margin-top: 4px; font-size: 12px; font-weight: 700; color: #1f6b3a; }
.so-kr { align-items: flex-start; }
.so-kr .so-ring { width: 64px; height: 64px; margin: 4px 0 2px; }
.so-ring { display: block; }
.so-rbg { fill: none; stroke: #ece9f6; stroke-width: 12; }
.so-rfg { fill: none; stroke: #D9A03C; stroke-width: 12; stroke-linecap: round; }
.so-full .so-rfg { stroke: #332E57; }
.so-rbig { font-size: 21px; font-weight: 800; fill: #332E57; }
.so-rsm { font-size: 10px; font-weight: 600; fill: #5b567a; }
.so-bars { display: flex; align-items: flex-end; gap: 3px; height: 40px; margin-top: 6px; }
.so-bc { flex: 1 1 0; display: flex; flex-direction: column; align-items: center; height: 100%; justify-content: flex-end; min-width: 0; }
.so-bc i { display: block; width: 100%; max-width: 12px; background: #332E57; border-radius: 3px 3px 1px 1px; transform-origin: bottom; }
.so-bc em { font-style: normal; font-size: 9px; line-height: 12px; color: #5b567a; font-weight: 600; }
.so-bc::before { content: ''; flex: 1 1 auto; }
.so-today i { background: #D9A03C; } .so-today em { color: #7a5410; font-weight: 800; }
.so-fut em { opacity: .5; }
.so-recs { display: block; margin: 8px 0 0; padding: 9px 12px; border-radius: 10px; background: #fdf6e8; border-left: 4px solid #D9A03C; color: #5c3f0c; font-size: 14px; text-decoration: none; }
/* cards */
.so-card { border-top: 4px solid #332E57; }
.so-hd { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; margin: 0 0 8px; }
.so-h { margin: 0; font-size: 16px; color: #332E57; }
.so-tag { display: inline-block; font-size: 11px; font-weight: 700; padding: 1px 9px; border-radius: 999px; background: #ece9f6; color: #332E57; }
.so-tag-on { background: #e3f3e8; color: #1f6b3a; } .so-tag-off { background: #f0eef5; color: #6b6785; }
.so-stack { display: flex; height: 14px; border-radius: 7px; overflow: hidden; gap: 2px; background: #f0eef7; }
.so-stack i { display: block; min-width: 6px; transform-origin: left; }
.so-s-ready { background: #332E57; } .so-s-confirm { background: #D9A03C; } .so-s-wait { background: #e9d8b4; } .so-s-blocked { background: #c0392b; } .so-s-off { background: #c9c6d6; }
.so-leg { list-style: none; margin: 8px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 13px; }
.so-leg li { display: flex; align-items: center; gap: 5px; }
.so-k { display: inline-block; width: 10px; height: 10px; border-radius: 3px; }
.so-note { margin: 8px 0 0; }
.so-people { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0 0; }
.so-pp { display: grid; grid-template-columns: 34px 1fr; grid-template-rows: auto auto; column-gap: 7px; align-items: center; background: #faf9fd; border: 1px solid #e6e3f0;
  border-radius: 10px; padding: 5px 9px 5px 5px; min-width: 0; max-width: 100%; }
.so-pp b { grid-row: 1 / span 2; width: 34px; height: 34px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 13px; color: #fff; background: #332E57; }
.so-pp span { font-size: 13px; font-weight: 700; color: #222; }
.so-pp small { font-size: 11px; color: #5b567a; }
.so-p-confirm b { background: #D9A03C; } .so-p-wait b { background: #b8a26e; } .so-p-blocked b { background: #c0392b; } .so-p-off b { background: #a29fb5; }
/* work shifts myself */
.so-self.so-on { border-top-color: #D9A03C; }
.so-selfrow { display: flex; gap: 12px; align-items: flex-end; flex-wrap: wrap; justify-content: space-between; }
.so-selfst { flex: 1 1 180px; min-width: 0; }
.so-selfh { flex: 0 0 auto; display: flex; flex-direction: column; min-width: 120px; }
.so-selfh b { font-size: 26px; line-height: 1.1; color: #332E57; font-variant-numeric: tabular-nums; }
.so-pill { display: inline-block; font-size: 13px; font-weight: 700; padding: 4px 10px; border-radius: 999px; margin: 0 0 4px; }
.so-pill.so-p-ready { background: #e3f3e8; color: #1f6b3a; } .so-pill.so-p-blocked { background: #fdf6e8; color: #7a5410; }
.so-selfbtn { margin-top: 10px; gap: 6px; flex-wrap: wrap; align-items: center; }
.so-selfbtn .so-off { margin-left: auto; font-size: 13px; color: #6b6785; }
.so-wbar { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; background: #fdf6e8; border: 1px solid #ecd3a0; border-radius: 10px;
  padding: 7px 10px; margin: 0 0 10px; font-size: 13px; color: #5c3f0c; }
.so-wbar .linklike { font-size: 13px; font-weight: 700; color: #332E57; margin: 0; padding: 0; }
a.menu-item.so-back { border-left: 4px solid #D9A03C; }
.so-open { margin: 2px 0 8px; padding: 6px 10px; border-radius: 8px; background: #eef7f1; color: #1f6b3a; font-weight: 600; }
.so-crewnote { margin: 8px 0 12px; }
/* office */
.so-office { margin: 10px 0 0; }
.so-otiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin: 6px 0 8px; }
.so-otiles > div { background: #f4f2fa; border-radius: 10px; padding: 8px 10px; display: flex; flex-direction: column; border-left: 4px solid #D9A03C; }
.so-otiles b { font-size: 24px; color: #332E57; font-variant-numeric: tabular-nums; }
.so-otiles small { font-size: 12px; color: #5b567a; }
@media (max-width: 360px) { a.so-kpi b { font-size: 26px; } .so-banner h1 { font-size: 19px; } }
@media (prefers-reduced-motion: no-preference) {
  .so-bc i { animation: soGrow .5s cubic-bezier(.2,.8,.2,1) both; }
  .so-stack i { animation: soGrowX .5s ease-out both; }
  .so-rfg { animation: soFade .6s ease-out both; }
  @keyframes soGrow { from { transform: scaleY(0); } to { transform: scaleY(1); } }
  @keyframes soGrowX { from { transform: scaleX(0); } to { transform: scaleX(1); } }
  @keyframes soFade { from { opacity: 0; } to { opacity: 1; } }
}
