/* AOP canonical global header shell v24.
   This file intentionally styles ONLY the global AOP header/navigation.
   It is used by both /aop/ pages and applications outside /aop/. */

:root{
  --aop-shell-page:#f3f7fb;
  --aop-shell-card:#ffffff;
  --aop-shell-line:#ccd8e8;
  --aop-shell-soft-line:#e5edf6;
  --aop-shell-blue:#003f7f;
  --aop-shell-blue-soft:#eef5ff;
  --aop-shell-muted:#50627a;
  --aop-shell-shadow:0 3px 12px rgba(15,23,42,.06);
  --aop-shell-width:min(1540px,calc(100% - 36px));
}

.aop-header,.aop-header *{box-sizing:border-box}
.aop-header{
  font-family:Arial,Helvetica,sans-serif!important;
  padding:22px 0 10px!important;
  margin:0!important;
  background:rgba(243,247,251,.96)!important;
  position:sticky!important;
  top:0!important;
  z-index:1000!important;
  backdrop-filter:blur(6px);
  -webkit-backdrop-filter:blur(6px);
  color:#0f1f33;
}
.aop-header .site-shell{
  width:var(--aop-shell-width)!important;
  max-width:none!important;
  margin:0 auto!important;
  padding:0!important;
}
.aop-header-card{
  width:100%!important;
  margin:0!important;
  background:var(--aop-shell-card)!important;
  border:1px solid var(--aop-shell-line)!important;
  border-radius:16px!important;
  box-shadow:var(--aop-shell-shadow)!important;
  padding:14px 18px 13px 18px!important;
}
.aop-brand{
  display:flex!important;
  align-items:center!important;
  gap:16px!important;
  min-width:0!important;
  margin:0!important;
  padding:0!important;
}
.aop-logo-link{display:block!important;flex:0 0 auto!important;margin:0!important;padding:0!important}
.aop-logo{
  display:block!important;
  max-width:178px!important;
  width:auto!important;
  height:auto!important;
  margin:0!important;
}
.aop-title-block{
  display:flex!important;
  flex-direction:column!important;
  justify-content:center!important;
  min-width:0!important;
  min-height:62px!important;
  margin:0!important;
  padding:0!important;
}
.aop-title{
  margin:0!important;
  padding:0!important;
  color:var(--aop-shell-blue)!important;
  font-family:Arial,Helvetica,sans-serif!important;
  font-size:31px!important;
  line-height:1.06!important;
  font-weight:800!important;
  letter-spacing:-.015em!important;
  text-align:left!important;
}
.aop-subtitle{
  margin:4px 0 0 0!important;
  padding:0!important;
  color:var(--aop-shell-muted)!important;
  font-family:Arial,Helvetica,sans-serif!important;
  font-size:15px!important;
  line-height:1.25!important;
  font-weight:400!important;
  text-align:left!important;
  max-width:1000px!important;
}
.aop-nav{
  display:flex!important;
  gap:8px!important;
  flex-wrap:wrap!important;
  align-items:stretch!important;
  justify-content:flex-start!important;
  margin:14px 0 0 0!important;
  padding:12px 0 0 0!important;
  border-top:1px solid var(--aop-shell-soft-line)!important;
}
.aop-nav a{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  min-height:36px!important;
  margin:0!important;
  padding:9px 13px!important;
  border:1px solid #d5e2f3!important;
  border-radius:10px!important;
  background:var(--aop-shell-blue-soft)!important;
  color:var(--aop-shell-blue)!important;
  font-family:Arial,Helvetica,sans-serif!important;
  font-size:14px!important;
  line-height:1.15!important;
  font-weight:800!important;
  text-decoration:none!important;
  white-space:nowrap!important;
}
.aop-nav a.active,.aop-nav a:hover,.aop-nav a:focus{
  background:var(--aop-shell-blue)!important;
  border-color:var(--aop-shell-blue)!important;
  color:#fff!important;
  outline:none!important;
}

/* Applications outside /aop/ use the exact same canonical classes above. */
.aop-external-shell{width:100%!important}

@media(max-width:1100px){
  .aop-title{font-size:28px!important}
  .aop-logo{max-width:162px!important}
  .aop-subtitle{font-size:14px!important}
}
@media(max-width:980px){
  .aop-header .site-shell{width:calc(100% - 16px)!important}
}
@media(max-width:720px){
  .aop-header{position:static!important;padding:8px 0 4px!important}
  .aop-header .site-shell{width:calc(100% - 12px)!important}
  .aop-header-card{padding:10px!important;border-radius:13px!important}
  .aop-brand{display:grid!important;grid-template-columns:112px minmax(0,1fr)!important;gap:10px!important;align-items:center!important}
  .aop-logo{max-width:112px!important;width:100%!important}
  .aop-title-block{min-height:0!important}
  .aop-title{font-size:22px!important;line-height:1.04!important}
  .aop-subtitle{display:none!important}
  .aop-nav{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:6px!important;margin-top:10px!important;padding-top:9px!important}
  .aop-nav a{width:100%!important;min-width:0!important;min-height:0!important;padding:8px 5px!important;font-size:12px!important;line-height:1.15!important;white-space:normal!important}
}
@media(max-width:370px){
  .aop-brand{grid-template-columns:96px minmax(0,1fr)!important}
  .aop-logo{max-width:96px!important}
  .aop-title{font-size:20px!important}
  .aop-nav a{font-size:11.5px!important}
}


/* AOP unified page-title standard v25 - based on Onboarding title treatment. */
.aop-page-title-card{
  background:#fff!important;
  border:1px solid var(--aop-shell-line,#ccd8e8)!important;
  border-radius:16px!important;
  box-shadow:var(--aop-shell-shadow,0 3px 12px rgba(15,23,42,.06))!important;
  padding:18px 20px!important;
  margin-bottom:16px!important;
}
.aop-page-title-block{
  display:block!important;
  margin:0 0 14px 0!important;
  padding:0 0 10px 0!important;
  border:0!important;
  border-bottom:1px solid var(--aop-shell-soft-line,#e5edf6)!important;
  background:transparent!important;
  box-shadow:none!important;
}
.aop-page-title-block:last-child{margin-bottom:0!important}
.aop-page-title-block h1,
.aop-page-title-block h2,
.aop-page-title-card > h1:first-child,
.aop-page-title-card .hero-main > h1:first-child{
  margin:0!important;padding:0!important;border:0!important;background:transparent!important;
  color:var(--aop-shell-blue,#003f7f)!important;
  font-family:Arial,Helvetica,sans-serif!important;
  font-size:21px!important;line-height:1.22!important;font-weight:650!important;
  letter-spacing:0!important;text-align:left!important;
}
.aop-page-title-block p,
.aop-page-title-card .hero-main > p:first-of-type{
  margin:5px 0 0!important;padding:0!important;
  color:var(--aop-shell-muted,#50627a)!important;
  font-family:Arial,Helvetica,sans-serif!important;
  font-size:15px!important;line-height:1.35!important;font-weight:400!important;
}
.aop-page-title-row{display:flex!important;align-items:flex-start!important;justify-content:space-between!important;gap:18px!important}
.aop-page-title-row .aop-page-title-block{flex:1 1 auto!important;min-width:0!important}
.aop-page-title-actions{flex:0 0 auto!important;display:flex!important;gap:8px!important;flex-wrap:wrap!important;justify-content:flex-end!important}
@media(max-width:720px){
  .aop-page-title-card{padding:14px!important;border-radius:14px!important}
  .aop-page-title-row{display:block!important}
  .aop-page-title-actions{justify-content:flex-start!important;margin-top:10px!important}
}


/* AOP store/view context v26 */
.aop-context-row{display:flex!important;align-items:center!important;justify-content:flex-end!important;gap:12px!important;margin:-2px 0 0 0!important;padding:0!important;font-family:Arial,Helvetica,sans-serif!important}
.aop-store-context{display:inline-flex!important;align-items:center!important;gap:4px!important;padding:6px 10px!important;border:1px solid #d5e2f3!important;border-radius:9px!important;background:#f8fbff!important;color:#173b64!important;font-size:13px!important;line-height:1.1!important}
.aop-store-context-label{color:#60748c!important;font-weight:400!important}.aop-store-code{color:#60748c!important;font-weight:700!important}
.aop-store-switcher{display:flex!important;align-items:center!important;gap:6px!important;margin:0!important}.aop-store-switcher label{font-size:12px!important;font-weight:700!important;color:#50627a!important}.aop-store-switcher select{height:30px!important;padding:4px 28px 4px 8px!important;border:1px solid #cbd8e8!important;border-radius:8px!important;background:#fff!important;color:#003f7f!important;font-family:Arial,Helvetica,sans-serif!important;font-size:12px!important;font-weight:700!important}
@media(max-width:720px){.aop-context-row{justify-content:flex-start!important;flex-wrap:wrap!important;margin-top:8px!important}.aop-store-context{font-size:12px!important}.aop-store-switcher{width:100%!important}.aop-store-switcher select{max-width:240px!important;width:100%!important}}

/* Store-aware AOP attention badges */
.aop-nav a{gap:6px}
.aop-nav-badge{display:inline-flex;align-items:center;justify-content:center;min-width:20px;height:20px;padding:0 6px;border-radius:999px;background:#b42318;color:#fff;font-size:11px;font-weight:900;line-height:1;box-shadow:0 0 0 1px rgba(255,255,255,.45)}
.aop-nav a.active .aop-nav-badge{background:#fff;color:#9b1c13;box-shadow:none}
.aop-attention{border:1px solid #e5c46f;background:#fff9e7;border-radius:12px;padding:13px 15px;margin:0 0 18px}
.aop-attention h3{margin:0 0 8px;color:#6f4c00;font-size:17px}.aop-attention-list{display:flex;flex-direction:column;gap:8px}.aop-attention-item{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:9px 10px;background:#fff;border:1px solid #ead9aa;border-radius:9px}.aop-attention-copy{min-width:0}.aop-attention-copy strong{color:#26364a}.aop-attention-copy small{display:block;color:#657488;margin-top:2px}.aop-attention-actions{display:flex;gap:7px;flex-wrap:wrap;flex:0 0 auto}@media(max-width:720px){.aop-attention-item{display:block}.aop-attention-actions{margin-top:8px}.aop-nav-badge{height:18px;min-width:18px;font-size:10px}}


/* Phone header v28: predictable rows, compact identity and touch controls. */
@media (max-width:720px) {
  .aop-header .aop-brand {
    display:flex!important;
    flex-direction:column!important;
    align-items:center!important;
    gap:6px!important;
  }
  .aop-header .aop-logo {max-width:112px!important}
  .aop-header .aop-title-block {width:100%!important;min-height:0!important}
  .aop-header .aop-title {font-size:20px!important;line-height:1.15!important;text-align:center!important}
  .aop-header .aop-context-row {display:flex!important;flex-direction:column!important;align-items:stretch!important;gap:8px!important;margin-top:10px!important}
  .aop-header .aop-context-has-switcher > .aop-store-context {display:none!important}
  .aop-header .aop-store-context {align-self:flex-start}
  .aop-header .aop-user-context {display:grid!important;grid-template-columns:minmax(0,1fr) auto!important;align-items:center!important;gap:8px!important;width:100%!important;min-width:0!important;margin-left:0!important;justify-content:normal!important;font-size:12px!important}
  .aop-header .aop-user-identity {grid-column:1;grid-row:1;min-width:0;line-height:1.35;overflow-wrap:anywhere}
  .aop-header .aop-user-identity small {font-size:11px}
  .aop-header .aop-sign-out {grid-column:2;grid-row:1;display:flex;align-items:center;justify-content:center;min-height:40px;padding:7px 10px!important;font-size:12px;white-space:nowrap}
  .aop-header .aop-user-preview {grid-column:1 / -1;display:grid!important;grid-template-columns:minmax(0,1fr)!important;gap:4px!important;width:100%;min-width:0}
  .aop-header .aop-user-preview > strong {font-size:11px!important}
  .aop-header .aop-user-preview form {display:grid!important;grid-template-columns:minmax(0,1fr) auto!important;gap:6px!important;min-width:0;width:100%}
  .aop-header .aop-user-preview select {width:100%!important;max-width:100%!important;min-width:0;min-height:40px;font-size:16px!important;padding:7px 8px!important}
  .aop-header .aop-user-preview button {min-height:40px;min-width:64px;padding:7px 10px!important;white-space:nowrap}
  .aop-header .aop-user-preview-status {grid-column:1 / -1;justify-content:space-between;gap:6px!important;width:100%}
  .aop-header .aop-user-preview-status button {min-height:40px}
  .aop-header .aop-store-switcher {display:grid!important;grid-template-columns:minmax(0,1fr)!important;gap:4px!important;width:100%!important}
  .aop-header .aop-store-switcher label {font-size:11px!important;line-height:1.2;white-space:nowrap}
  .aop-header .aop-store-switcher select {width:100%!important;max-width:none!important;min-width:0;height:40px!important;font-size:16px!important;padding:6px 28px 6px 8px!important}
  body.aop-home .dashboard-section {margin-top:16px}
  body.aop-home .dashboard-section:first-of-type {margin-top:8px}
  body.aop-home .dashboard-section-heading {margin-bottom:9px;gap:5px}
  body.aop-home .dashboard-section-heading h2 {font-size:20px}
  body.aop-home .dashboard-section-heading p {font-size:13px;line-height:1.35}
  body.aop-home .dashboard-grid {gap:10px}
  body.aop-home .dashboard-card {padding:13px 14px;border-radius:12px}
  body.aop-home .dashboard-card h3 {font-size:17px;margin-bottom:5px}
  body.aop-home .dashboard-card p {font-size:13px;line-height:1.35}
}
