/* =============================================================================
   EKM Portal — Home shell + information hierarchy                 UI/UX PR 14b
   -----------------------------------------------------------------------------
   Presentation only. Every rule is scoped to the Home root (#role-home-content /
   #home-content) — nothing here rides body.hp-active, which is on every page.
   Order on Home: hero band (legacy sheets, unchanged) → KPI row → immediate work → While away | Open next
   → Executive Overview → Reference → Culture & personal.
   The legacy sheets (inline v2 block, ekm-os-home-luxury, ekm-home-debox) use
   !important under body.hp-active; the id-scoped selectors below outrank them, so
   !important is used here only where a legacy rule is itself !important.
   Tokens: --type-eyebrow/--type-caption/--type-body-sm, --space-*, --radius-*,
   --c-ink/--c-muted/--c-rule/--c-box/--c-box-border, --c-accent (+ --c-accent-fg).
   ============================================================================= */

/* ---- shared eyebrows / band heads (Home root only) ----------------------- */
:is(#role-home-content,#home-content) .hp-seclabel{font-family:var(--font-ui,-apple-system,sans-serif);font-size:var(--type-eyebrow,0.6875rem)!important;font-weight:600;letter-spacing:.12em;text-transform:uppercase;color:var(--c-muted)}
:is(#role-home-content,#home-content) .hp-band-head{display:flex;align-items:center;gap:var(--space-3,.75rem);margin:var(--space-5,1.25rem) 0 var(--space-3,.75rem);padding-top:var(--space-4,1rem);border-top:0.5px solid var(--c-rule,var(--c-box-border))}
:is(#role-home-content,#home-content) .hp-band-eyebrow{font-family:var(--font-ui,-apple-system,sans-serif);font-size:var(--type-eyebrow,0.6875rem);font-weight:600;letter-spacing:.14em;text-transform:uppercase;color:var(--c-muted)}

/* ---- B. KPI row: one coherent system ------------------------------------ */
:is(#role-home-content,#home-content) .hp-summary-row{display:grid!important;grid-template-columns:repeat(4,minmax(0,1fr))!important;gap:0!important;margin:0!important;padding:0!important;border-top:none!important;border-bottom:0.5px solid var(--c-rule,var(--c-box-border))!important}
:is(#role-home-content,#home-content) .hp-summary-row[data-cols="3"]{grid-template-columns:repeat(3,minmax(0,1fr))!important}
:is(#role-home-content,#home-content) .hp-summary-row[data-cols="5"]{grid-template-columns:repeat(5,minmax(0,1fr))!important}
:is(#role-home-content,#home-content) .hp-summary-card{display:flex!important;flex-direction:column!important;gap:.3rem!important;padding:var(--space-4,1rem) var(--space-4,1rem) var(--space-4,1rem) 0!important;margin:0 var(--space-4,1rem) 0 0!important;border:none!important;border-right:0.5px solid var(--c-rule,var(--c-box-border))!important;border-radius:0!important;box-shadow:none!important;background:transparent!important}
:is(#role-home-content,#home-content) .hp-summary-card:last-child{border-right:none!important;margin-right:0!important}
:is(#role-home-content,#home-content) .hp-summary-card:hover{background:color-mix(in srgb,var(--c-ink,#000) 4%,transparent)!important}
:is(#role-home-content,#home-content) .hp-summary-card:focus-visible{outline:none;box-shadow:var(--focus-ring,0 0 0 2px var(--c-bg),0 0 0 4px var(--c-accent))!important}
:is(#role-home-content,#home-content) .hp-summary-card-head{gap:.4rem}
:is(#role-home-content,#home-content) .hp-summary-card-icon,:is(#role-home-content,#home-content) .hp-summary-card-icon svg{width:13px;height:13px}
:is(#role-home-content,#home-content) .hp-summary-card-label{font-size:var(--type-eyebrow,0.6875rem)!important;font-weight:600!important;letter-spacing:.12em!important;color:var(--c-muted)!important;opacity:1!important}
:is(#role-home-content,#home-content) .hp-summary-card-value{font-family:var(--font-ui,-apple-system,sans-serif)!important;font-size:clamp(1.85rem,2.5vw,2.35rem)!important;font-weight:300!important;line-height:1.05!important;color:var(--c-ink)!important;font-variant-numeric:tabular-nums;margin-top:.15rem}
:is(#role-home-content,#home-content) .hp-summary-card-sub{font-size:var(--type-body-sm,0.8125rem)!important;line-height:1.35!important;color:var(--c-ink)!important}
:is(#role-home-content,#home-content) .hp-summary-card-break{font-size:var(--type-caption,0.75rem)!important;line-height:1.4!important;color:var(--c-muted)!important}
:is(#role-home-content,#home-content) .hp-summary-card-link{margin-top:auto!important;padding-top:.35rem!important;font-size:var(--type-caption,0.75rem)!important;font-weight:500!important;letter-spacing:.01em!important;color:var(--c-accent-fg,var(--c-accent))!important}
:is(#role-home-content,#home-content) .hp-summary-card:hover .hp-summary-card-link{text-decoration:underline;text-underline-offset:2px}
@media(max-width:1100px){
  :is(#role-home-content,#home-content) .hp-summary-row,:is(#role-home-content,#home-content) .hp-summary-row[data-cols="3"],:is(#role-home-content,#home-content) .hp-summary-row[data-cols="5"]{grid-template-columns:repeat(2,minmax(0,1fr))!important}
  :is(#role-home-content,#home-content) .hp-summary-card{border-bottom:0.5px solid var(--c-rule,var(--c-box-border))!important}
  :is(#role-home-content,#home-content) .hp-summary-card:nth-child(2n){border-right:none!important;margin-right:0!important}
  :is(#role-home-content,#home-content) .hp-summary-card:nth-last-child(-n+2):nth-child(odd),:is(#role-home-content,#home-content) .hp-summary-card:last-child{border-bottom:none!important}
}
@media(max-width:560px){
  :is(#role-home-content,#home-content) .hp-summary-row,:is(#role-home-content,#home-content) .hp-summary-row[data-cols="3"],:is(#role-home-content,#home-content) .hp-summary-row[data-cols="5"]{grid-template-columns:1fr!important}
  :is(#role-home-content,#home-content) .hp-summary-card{border-right:none!important;margin-right:0!important;padding:var(--space-3,.75rem) 0!important;border-bottom:0.5px solid var(--c-rule,var(--c-box-border))!important}
  :is(#role-home-content,#home-content) .hp-summary-card:last-child{border-bottom:none!important}
  :is(#role-home-content,#home-content) .hp-summary-card-value{font-size:1.75rem!important}
}

/* ---- C. immediate work (role action zone) ------------------------------- */
:is(#role-home-content,#home-content) .hp-v2-action{min-width:0}
:is(#role-home-content,#home-content) .hp-v2-action .hp-action-zone{margin:0!important}
:is(#role-home-content,#home-content) .hp-v2-action:not(:has(#home-action-zone > *)){display:none}
:is(#role-home-content,#home-content) #home-action-zone > .hp-softbox,
:is(#role-home-content,#home-content) #home-action-zone #home-action-box{background:var(--c-box)!important;border:0.5px solid var(--c-box-border)!important;border-left:3px solid var(--c-accent)!important;border-radius:var(--radius-card,12px)!important;box-shadow:none!important;padding:var(--space-4,1rem) var(--space-5,1.25rem)!important;margin:0 0 var(--space-3,.75rem)!important}
:is(#role-home-content,#home-content) #home-action-zone > .hp-softbox:last-child{margin-bottom:0!important}
:is(#role-home-content,#home-content) #home-action-box .hp-chead{margin-bottom:.6rem!important}
:is(#role-home-content,#home-content) #home-action-box .hp-secline{display:none}
:is(#role-home-content,#home-content) .hp-act-status{font-size:var(--type-eyebrow,0.6875rem);white-space:nowrap}
:is(#role-home-content,#home-content) #home-action-box .eui-btn--sm{min-height:28px;padding:0 var(--space-2,.5rem)}

/* ---- D. While away | Open next ------------------------------------------ */
:is(#role-home-content,#home-content) .hp-primary-triad{gap:var(--space-5,1.25rem)!important;padding-bottom:var(--space-2,.5rem);border-bottom:0.5px solid var(--c-rule,var(--c-box-border))}
:is(#role-home-content,#home-content) .hp-sec-panel{border-bottom:none!important;padding-top:var(--space-2,.5rem)!important}
:is(#role-home-content,#home-content) .hp-sec-panel-title{font-size:var(--type-eyebrow,0.6875rem)!important;letter-spacing:.12em!important;color:var(--c-ink)!important;font-weight:600!important}
:is(#role-home-content,#home-content) .hp-sec-panel-hint{font-family:var(--font-ui,-apple-system,sans-serif);font-size:var(--type-caption,0.75rem);color:var(--c-muted);letter-spacing:0;text-transform:none;font-weight:400;white-space:nowrap}
:is(#role-home-content,#home-content) .hp-sec-panel-hint::before{content:"·";margin-right:.4rem;color:var(--c-muted)}
:is(#role-home-content,#home-content) .hp-sec-panel-count{font-size:var(--type-caption,0.75rem)!important;color:var(--c-muted)!important}
:is(#role-home-content,#home-content) .hp-announce-post{margin-bottom:var(--space-3,.75rem)}
@media(max-width:640px){:is(#role-home-content,#home-content) .hp-sec-panel-hint{display:none}}

/* ---- F. Executive Overview + Reference ----------------------------------- */
:is(#role-home-content,#home-content) .hp-exec-overview{margin:var(--space-4,1rem) 0 0!important}
:is(#role-home-content,#home-content) .hp-exec-overview-label{font-size:var(--type-eyebrow,0.6875rem)!important;font-weight:600!important;letter-spacing:.14em!important;color:var(--c-muted)!important;margin:0 0 var(--space-2,.5rem)!important}
:is(#role-home-content,#home-content) .hp-exec-grid{gap:0!important;border-bottom:0.5px solid var(--c-rule,var(--c-box-border))}
:is(#role-home-content,#home-content) .hp-exec-card{padding:var(--space-3,.75rem) var(--space-4,1rem) var(--space-3,.75rem) 0!important;margin:0 var(--space-4,1rem) 0 0!important;border-right:0.5px solid var(--c-rule,var(--c-box-border))!important;border-radius:0!important}
:is(#role-home-content,#home-content) .hp-exec-card:last-child{border-right:none!important;margin-right:0!important}
:is(#role-home-content,#home-content) .hp-exec-card-label{font-size:var(--type-eyebrow,0.6875rem)!important;letter-spacing:.12em!important;color:var(--c-muted)!important}
:is(#role-home-content,#home-content) .hp-exec-card-value{font-size:clamp(1.5rem,2.2vw,1.95rem)!important;font-weight:300!important}
:is(#role-home-content,#home-content) .hp-exec-card-sub{font-size:var(--type-caption,0.75rem)!important;color:var(--c-muted)!important}
:is(#role-home-content,#home-content) .hp-exec-card-ph{font-size:var(--type-caption,0.75rem)!important}
@media(max-width:1100px){:is(#role-home-content,#home-content) .hp-exec-card:nth-child(2n){border-right:none!important;margin-right:0!important}}
@media(max-width:640px){:is(#role-home-content,#home-content) .hp-exec-card{border-right:none!important;margin-right:0!important}}
:is(#role-home-content,#home-content) .hp-ref-band .hp-ops-support-row{margin:0!important}
:is(#role-home-content,#home-content) .hp-ops-support-action{border-radius:var(--radius-control,8px)!important;padding:.5rem .65rem!important}
:is(#role-home-content,#home-content) .hp-ops-support-action-title{font-size:var(--type-body-sm,0.8125rem)}
:is(#role-home-content,#home-content) .hp-ops-support-meta{font-size:var(--type-caption,0.75rem)!important}

/* ---- G. Culture & personal (lowest priority) ---------------------------- */
:is(#role-home-content,#home-content) .hp-culture-band .hp-band-head{margin-top:var(--space-6,1.5rem)}
:is(#role-home-content,#home-content) .hp-culture-row>.hp-softbox{padding:var(--space-2,.5rem) 0 var(--space-3,.75rem)!important}
:is(#role-home-content,#home-content) .hp-culture-row .hp-chead{margin-bottom:.5rem!important}
:is(#role-home-content,#home-content) .hp-culture-row .hp-seclabel{font-size:var(--type-eyebrow,0.6875rem)!important}
:is(#role-home-content,#home-content) .hp-culture-row .eui-btn--sm{min-height:28px;padding:0 var(--space-2,.5rem)}

/* ---- H. honest unavailable states (UI/UX PR 14c) ------------------------- */
/* Distinct from the calm empty state, without a warning card: a thin status-coloured rule and plain copy. */
:is(#role-home-content,#home-content) .hp-empty-state.hp-empty-state--unavailable{border-left:2px solid var(--status-warning,#B7791F);padding-left:var(--space-3,.75rem);margin:var(--space-2,.5rem) 0}
:is(#role-home-content,#home-content) .hp-empty-state.hp-empty-state--unavailable .hp-empty-state-title{color:var(--c-ink);font-weight:600}
:is(#role-home-content,#home-content) .hp-empty-state.hp-empty-state--unavailable .hp-empty-state-body{color:var(--c-muted)}
:is(#role-home-content,#home-content) .hp-empty-state.hp-empty-state--unavailable a{color:var(--c-accent-fg,var(--c-accent));text-decoration:underline;text-underline-offset:2px}
