/* FoodCare FoodBorne Pathogen Guide 0.20.14
 * Compact in-frame Risk Analysis workspace and reliable legislation loading state.
 */

/* --------------------------------------------------------------------------
 * 1. The active Risk Analysis workspace is always static and contained by the
 *    application frame. No fixed/sticky positioning is permitted here.
 * ----------------------------------------------------------------------- */
body.fbp-analysis-context .fbp-analysis-shell,
body.fbp-analysis-context .fbp-analysis-shell.fbp-analysis-sticky-active,
body.fbp-analysis-context .fbp-analysis-shell.fbp-fixed-desktop,
body.admin-bar.fbp-analysis-context .fbp-analysis-shell.fbp-analysis-sticky-active{
  position:static!important;
  inset:auto!important;
  top:auto!important;
  right:auto!important;
  bottom:auto!important;
  left:auto!important;
  z-index:auto!important;
  transform:none!important;
  box-sizing:border-box!important;
  width:calc(100% - 28px)!important;
  max-width:calc(100% - 28px)!important;
  min-width:0!important;
  margin:12px 14px 18px!important;
  padding:0!important;
  overflow:hidden!important;
  border:1px solid #c9d7e9!important;
  border-top:4px solid #214b98!important;
  border-radius:14px!important;
  background:#f4f7fc!important;
  box-shadow:0 10px 25px rgba(24,54,104,.10)!important;
}
body.fbp-analysis-context .fbp-analysis-shell-spacer{
  display:none!important;
  width:0!important;
  height:0!important;
  min-height:0!important;
  margin:0!important;
  padding:0!important;
}

/* --------------------------------------------------------------------------
 * 2. One compact horizontal information/action row.
 *    R + title + product + save state + methodology + exit.
 * ----------------------------------------------------------------------- */
body.fbp-analysis-context .fbp-analysis-shell-head{
  display:flex!important;
  align-items:center!important;
  justify-content:space-between!important;
  flex-wrap:nowrap!important;
  gap:12px!important;
  width:100%!important;
  min-width:0!important;
  min-height:56px!important;
  margin:0!important;
  padding:9px 12px!important;
  border:0!important;
  border-radius:10px 10px 0 0!important;
  background:linear-gradient(180deg,#fff 0%,#f5f8fd 100%)!important;
  color:#173b82!important;
  box-sizing:border-box!important;
}
body.fbp-analysis-context .fbp-analysis-identity{
  display:flex!important;
  align-items:center!important;
  flex:1 1 auto!important;
  gap:10px!important;
  min-width:0!important;
  margin:0!important;
}
body.fbp-analysis-context .fbp-analysis-mark{
  display:grid!important;
  place-items:center!important;
  flex:0 0 36px!important;
  width:36px!important;
  height:36px!important;
  margin:0!important;
  border-radius:10px!important;
  background:linear-gradient(145deg,#173b82,#2c5fb9)!important;
  color:#fff!important;
  font-size:17px!important;
  line-height:1!important;
  font-weight:900!important;
  box-shadow:0 5px 13px rgba(31,76,157,.20)!important;
}
body.fbp-analysis-context .fbp-analysis-copy{
  display:flex!important;
  align-items:center!important;
  flex:1 1 auto!important;
  flex-wrap:nowrap!important;
  gap:8px!important;
  min-width:0!important;
  margin:0!important;
}
body.fbp-analysis-context .fbp-analysis-title{
  flex:0 0 auto!important;
  margin:0!important;
  color:#173b82!important;
  opacity:1!important;
  font-size:13px!important;
  line-height:1.2!important;
  letter-spacing:.035em!important;
  text-transform:uppercase!important;
  font-weight:900!important;
  white-space:nowrap!important;
}
body.fbp-analysis-context .fbp-analysis-context-row{
  display:flex!important;
  align-items:center!important;
  flex:1 1 auto!important;
  flex-wrap:nowrap!important;
  gap:7px!important;
  min-width:0!important;
  margin:0!important;
}
body.fbp-analysis-context .fbp-analysis-context-name{
  display:inline-flex!important;
  align-items:center!important;
  flex:0 1 auto!important;
  min-width:90px!important;
  max-width:min(360px,28vw)!important;
  min-height:29px!important;
  margin:0!important;
  padding:5px 10px!important;
  border:1px solid #c7d5e9!important;
  border-radius:999px!important;
  background:#eaf1fb!important;
  color:#23498b!important;
  font-size:13px!important;
  line-height:1.2!important;
  font-weight:820!important;
  white-space:nowrap!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
}
body.fbp-analysis-context .fbp-analysis-save-state{
  display:inline-flex!important;
  align-items:center!important;
  flex:0 0 auto!important;
  gap:6px!important;
  min-height:29px!important;
  margin:0!important;
  padding:5px 10px!important;
  border:1px solid #badcc8!important;
  border-radius:999px!important;
  background:#e9f7ee!important;
  color:#17643d!important;
  font-size:13px!important;
  line-height:1.2!important;
  font-weight:850!important;
  white-space:nowrap!important;
}
body.fbp-analysis-context .fbp-analysis-dirty .fbp-analysis-save-state{
  border-color:#efd083!important;
  background:#fff4d5!important;
  color:#7b5200!important;
}
body.fbp-analysis-context .fbp-analysis-save-state:before{
  content:""!important;
  flex:0 0 7px!important;
  width:7px!important;
  height:7px!important;
  border-radius:50%!important;
  background:currentColor!important;
}
body.fbp-analysis-context .fbp-analysis-shell-actions{
  display:flex!important;
  align-items:center!important;
  justify-content:flex-end!important;
  flex:0 0 auto!important;
  gap:8px!important;
  min-width:0!important;
  margin:0!important;
  white-space:nowrap!important;
}
body.fbp-analysis-context .fbp-analysis-shell-actions a,
body.fbp-analysis-context .fbp-analysis-shell-actions button{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  min-width:0!important;
  min-height:36px!important;
  margin:0!important;
  padding:7px 11px!important;
  border-radius:9px!important;
  font-size:13px!important;
  line-height:1.2!important;
  font-weight:850!important;
  text-decoration:none!important;
  white-space:nowrap!important;
  box-shadow:none!important;
}
body.fbp-analysis-context .fbp-analysis-shell-actions .fbp-methodology-button-persistent{
  border:1px solid #9fb5d8!important;
  background:#fff!important;
  color:#214b91!important;
}
body.fbp-analysis-context .fbp-analysis-shell-actions .fbp-methodology-button-persistent:hover,
body.fbp-analysis-context .fbp-analysis-shell-actions .fbp-methodology-button-persistent:focus-visible{
  border-color:#527bbd!important;
  background:#edf4ff!important;
  outline:none!important;
}
body.fbp-analysis-context .fbp-analysis-shell-actions .fbp-exit-analysis{
  border:1px solid #ddb1ba!important;
  background:#fff7f8!important;
  color:#a21f34!important;
}
body.fbp-analysis-context .fbp-analysis-shell-actions .fbp-exit-analysis:hover,
body.fbp-analysis-context .fbp-analysis-shell-actions .fbp-exit-analysis:focus-visible{
  border-color:#bd6275!important;
  background:#fff0f2!important;
  outline:none!important;
}

/* --------------------------------------------------------------------------
 * 3. Tabs remain below the header and inside exactly the same frame.
 * ----------------------------------------------------------------------- */
body.fbp-analysis-context .fbp-analysis-shell > .fbp-analysis-nav{
  display:grid!important;
  grid-template-columns:repeat(7,minmax(0,1fr))!important;
  gap:6px!important;
  width:100%!important;
  max-width:100%!important;
  min-width:0!important;
  margin:0!important;
  padding:7px!important;
  border:0!important;
  border-top:1px solid #d8e1ee!important;
  border-radius:0 0 10px 10px!important;
  background:#eef3fa!important;
  overflow:hidden!important;
  box-sizing:border-box!important;
}
body.fbp-analysis-context .fbp-analysis-shell > .fbp-analysis-nav button{
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  width:100%!important;
  min-width:0!important;
  max-width:100%!important;
  min-height:43px!important;
  margin:0!important;
  padding:7px 7px!important;
  border:1px solid #cad7e8!important;
  border-radius:9px!important;
  background:#fff!important;
  color:#2a4775!important;
  font-size:13px!important;
  line-height:1.16!important;
  font-weight:780!important;
  text-align:center!important;
  white-space:normal!important;
  overflow-wrap:anywhere!important;
  box-shadow:none!important;
}
body.fbp-analysis-context .fbp-analysis-shell > .fbp-analysis-nav button:hover,
body.fbp-analysis-context .fbp-analysis-shell > .fbp-analysis-nav button:focus-visible{
  border-color:#7f9fce!important;
  background:#f5f8ff!important;
  color:#173b82!important;
  outline:none!important;
}
body.fbp-analysis-context .fbp-analysis-shell > .fbp-analysis-nav button.active{
  border-color:#214b98!important;
  background:#214b98!important;
  color:#fff!important;
  box-shadow:0 4px 11px rgba(33,75,152,.18)!important;
}

/* Moderate desktop: keep the row horizontal, but allow the identity area to
 * shrink safely without pushing actions or tabs outside the workspace. */
@media (max-width:1420px) and (min-width:921px){
  body.fbp-analysis-context .fbp-analysis-shell-head{gap:8px!important;padding-inline:9px!important}
  body.fbp-analysis-context .fbp-analysis-identity{gap:7px!important}
  body.fbp-analysis-context .fbp-analysis-copy{gap:6px!important}
  body.fbp-analysis-context .fbp-analysis-context-name{max-width:21vw!important}
  body.fbp-analysis-context .fbp-analysis-shell-actions{gap:5px!important}
  body.fbp-analysis-context .fbp-analysis-shell-actions a,
  body.fbp-analysis-context .fbp-analysis-shell-actions button{padding-inline:8px!important}
}

/* Tablet/mobile: static natural flow. The tabs scroll only inside the shell;
 * the page itself never becomes wider. */
@media (max-width:920px){
  body.fbp-analysis-context .fbp-analysis-shell{
    width:calc(100% - 16px)!important;
    max-width:calc(100% - 16px)!important;
    margin:8px!important;
  }
  body.fbp-analysis-context .fbp-analysis-shell-head{
    display:grid!important;
    grid-template-columns:1fr!important;
    gap:8px!important;
    padding:9px!important;
  }
  body.fbp-analysis-context .fbp-analysis-identity{width:100%!important}
  body.fbp-analysis-context .fbp-analysis-copy{flex-wrap:wrap!important}
  body.fbp-analysis-context .fbp-analysis-context-row{flex-wrap:wrap!important}
  body.fbp-analysis-context .fbp-analysis-context-name{max-width:calc(100vw - 105px)!important}
  body.fbp-analysis-context .fbp-analysis-shell-actions{
    display:grid!important;
    grid-template-columns:1fr 1fr!important;
    width:100%!important;
  }
  body.fbp-analysis-context .fbp-analysis-shell-actions>*{
    width:100%!important;
    white-space:normal!important;
    text-align:center!important;
  }
  body.fbp-analysis-context .fbp-analysis-shell > .fbp-analysis-nav{
    display:flex!important;
    flex-wrap:nowrap!important;
    overflow-x:auto!important;
    overflow-y:hidden!important;
    scrollbar-width:thin!important;
    overscroll-behavior-inline:contain!important;
    scroll-snap-type:x proximity!important;
  }
  body.fbp-analysis-context .fbp-analysis-shell > .fbp-analysis-nav button{
    flex:0 0 158px!important;
    width:auto!important;
    scroll-snap-align:start!important;
  }
}
@media (max-width:560px){
  body.fbp-analysis-context .fbp-analysis-title{width:100%!important;white-space:normal!important}
  body.fbp-analysis-context .fbp-analysis-context-name{max-width:calc(100vw - 82px)!important}
  body.fbp-analysis-context .fbp-analysis-shell-actions{grid-template-columns:1fr!important}
}

/* --------------------------------------------------------------------------
 * 4. Legislation loading state. It is created before the tab changes, remains
 *    visible for a readable minimum duration, and is constrained to the view.
 * ----------------------------------------------------------------------- */
.fbp-tool-view[data-view="regulations"] .fbp-reg-explorer{position:relative!important;min-height:320px!important}
.fbp-reg-loading-v2014{
  position:absolute!important;
  inset:0!important;
  z-index:120!important;
  display:grid!important;
  place-items:start center!important;
  padding:86px 18px 28px!important;
  border-radius:14px!important;
  background:rgba(248,251,255,.94)!important;
  backdrop-filter:blur(2px)!important;
}
.fbp-reg-loading-v2014[hidden]{display:none!important}
.fbp-reg-loading-v2014 .fbp-loading-panel{
  display:flex!important;
  align-items:center!important;
  gap:14px!important;
  width:min(560px,calc(100% - 24px))!important;
  max-width:560px!important;
  margin:0!important;
  padding:17px 19px!important;
  border:1px solid #c9d8ed!important;
  border-radius:14px!important;
  background:#fff!important;
  box-shadow:0 14px 34px rgba(26,57,111,.14)!important;
  color:#173b82!important;
}
.fbp-reg-loading-v2014 .fbp-loading-copy{display:grid!important;gap:4px!important;min-width:0!important}
.fbp-reg-loading-v2014 .fbp-loading-copy strong{font-size:15px!important;line-height:1.25!important}
.fbp-reg-loading-v2014 .fbp-loading-copy span{font-size:13px!important;line-height:1.42!important;color:#61718a!important}
.fbp-reg-loading-v2014 .fbp-loading-spinner{
  position:relative!important;
  flex:0 0 40px!important;
  width:40px!important;
  height:40px!important;
  border:4px solid #dce7f6!important;
  border-top-color:#214b98!important;
  border-radius:50%!important;
  animation:fbpSpin2014 .8s linear infinite!important;
}
.fbp-reg-loading-v2014 .fbp-loading-spinner:after{
  content:""!important;
  position:absolute!important;
  inset:7px!important;
  border:3px solid transparent!important;
  border-bottom-color:#f3a313!important;
  border-radius:50%!important;
  animation:fbpSpin2014 .55s linear infinite reverse!important;
}
@keyframes fbpSpin2014{to{transform:rotate(360deg)}}
@media (prefers-reduced-motion:reduce){
  .fbp-reg-loading-v2014 .fbp-loading-spinner,
  .fbp-reg-loading-v2014 .fbp-loading-spinner:after{animation-duration:1.8s!important}
}

/* High-specificity containment guard against the legacy :not([hidden]) rule
 * in public-workspace-v2012.css. */
body.fbp-guide-page.fbp-analysis-context .fbp-workspace > .fbp-analysis-shell:not([hidden]),
body.fbp-guide-page.fbp-analysis-context .fbp-workspace > .fbp-analysis-shell.fbp-analysis-sticky-active:not([hidden]),
body.fbp-guide-page.fbp-analysis-context .fbp-workspace > .fbp-analysis-shell.fbp-fixed-desktop:not([hidden]){
  position:static!important;
  inset:auto!important;
  top:auto!important;
  right:auto!important;
  bottom:auto!important;
  left:auto!important;
  z-index:auto!important;
  transform:none!important;
  box-sizing:border-box!important;
  width:calc(100% - 28px)!important;
  max-width:calc(100% - 28px)!important;
  min-width:0!important;
  margin:12px 14px 18px!important;
  overflow:hidden!important;
}
@media (max-width:920px){
  body.fbp-guide-page.fbp-analysis-context .fbp-workspace > .fbp-analysis-shell:not([hidden]),
  body.fbp-guide-page.fbp-analysis-context .fbp-workspace > .fbp-analysis-shell.fbp-analysis-sticky-active:not([hidden]),
  body.fbp-guide-page.fbp-analysis-context .fbp-workspace > .fbp-analysis-shell.fbp-fixed-desktop:not([hidden]){
    width:calc(100% - 16px)!important;
    max-width:calc(100% - 16px)!important;
    margin:8px!important;
  }
}
