/* ======================================================
   OFFCANVAS (All Departments / Blog Menu)
   - Orange hover + white text (even if anchor/button styling differs)
   - Responsive toggle icon (tablet/mobile)
   - Tablet/Mobile: remove toggle border + move to left
====================================================== */

:root{
  --stm-orange: #ff7a00;
  --stm-oc-bg: #ffffff;
  --stm-oc-text: #0f172a;
  --stm-oc-muted: #64748b;
  --stm-oc-border: rgba(15, 23, 42, 0.10);
}

/* Toggle button (icon only) */
.stm-oc-toggle{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width: 40px;
  height: 40px;
  border: 1px solid rgba(0,0,0,.10);
  border-radius: 10px;
  background:#fff;
  cursor:pointer;
  margin-left: 10px; /* Desktop after logo */
}

.stm-oc-toggle__icon{
  width: 18px;
  height: 18px;
  display:block;
  background-repeat:no-repeat;
  background-position:center;
  background-size:contain;

  background-image:
    linear-gradient(#111827,#111827),
    linear-gradient(#111827,#111827),
    linear-gradient(#111827,#111827);
  background-size: 18px 2px, 18px 2px, 18px 2px;
  background-position: center 5px, center 9px, center 13px;
}

.stm-oc-toggle:hover{ border-color: rgba(0,0,0,.18); }
.stm-oc-toggle:focus-visible{ outline: 2px solid var(--stm-orange); outline-offset: 2px; }

/* ======================================================
   Responsive: Tablet + Mobile
   - toggle goes LEFT side
   - remove border
   - responsive icon sizing
====================================================== */
@media (max-width: 1024px){
  .stm-oc-toggle{
    width: 34px;
    height: 34px;
    border: 0 !important;
    border-radius: 10px;
    margin-left: 0;
    margin-right: 10px; /* before logo */
    background: transparent;
  }
  .stm-oc-toggle:hover{ border-color: transparent; }

  .stm-oc-toggle__icon{
    width: 18px;
    height: 18px;
    background-size: 18px 2px, 18px 2px, 18px 2px;
    background-position: center 5px, center 9px, center 13px;
  }
}

@media (max-width: 768px){
  .stm-oc-toggle{
    width: 32px;
    height: 32px;
    border: 0 !important;
    margin-left: 0;
    margin-right: 10px;
    background: transparent;
  }
  .stm-oc-toggle__icon{
    width: 17px;
    height: 17px;
    background-size: 17px 2px, 17px 2px, 17px 2px;
    background-position: center 5px, center 9px, center 13px;
  }
}

@media (max-width: 480px){
  .stm-oc-toggle{
    width: 30px;
    height: 30px;
    border: 0 !important;
    margin-left: 0;
    margin-right: 8px;
    background: transparent;
  }
  .stm-oc-toggle__icon{
    width: 16px;
    height: 16px;
    background-size: 16px 2px, 16px 2px, 16px 2px;
    background-position: center 4px, center 8px, center 12px;
  }
}

/* Body lock (NO SHIFT handled via JS padding-right) */
body.stm-oc-open{ overflow:hidden; }

/* Shell */
.stm-oc{
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: block !important;
  pointer-events: none;
  opacity: 0;
  transition: opacity .18s ease;
}

/* open via class OR body state */
.stm-oc.is-open,
body.stm-oc-open .stm-oc{
  pointer-events: auto;
  opacity: 1;
}

/* Overlay */
.stm-oc__overlay{
  position:absolute;
  inset:0;
  background: rgba(2,6,23,.55);
  z-index: 1;
}

/* Panel */
.stm-oc__panel{
  position:absolute;
  top:0;
  left:0;
  z-index: 2;
  pointer-events: auto;

  height:100%;
  width: 320px;
  max-width: 86vw;
  background: var(--stm-oc-bg);
  box-shadow: 0 18px 55px rgba(0,0,0,.22);
  transform: translate3d(-105%,0,0);
  transition: transform .20s ease;
  display:flex;
  flex-direction:column;
}

/* open by class OR body state */
.stm-oc.is-open .stm-oc__panel,
body.stm-oc-open .stm-oc__panel{
  transform: translate3d(0,0,0);
}

/* Head */
.stm-oc__head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding: 14px 14px;
  border-bottom: 1px solid var(--stm-oc-border);
}

.stm-oc__title{
  font-weight: 1000;
  font-size: 14px;
  color: var(--stm-oc-text);
  text-transform: uppercase;
  letter-spacing: .3px;
}

.stm-oc__close{
  width: 36px;
  height: 36px;
  border-radius: 10px;
  border: 1px solid rgba(0,0,0,.10);
  background:#fff;
  cursor:pointer;
  font-size: 22px;
  line-height: 1;
}
.stm-oc__close:hover{ border-color: rgba(0,0,0,.18); }
.stm-oc__close:focus-visible{ outline: 2px solid var(--stm-orange); outline-offset: 2px; }

/* Nav container */
.stm-oc__nav{
  padding: 10px 10px 16px;
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
}

/* Menu */
.stm-oc__menu{ list-style:none; margin:0; padding:0; }
.stm-oc__item{ margin: 0; padding: 0; }

/* Link / parent button */
.stm-oc__link,
.stm-oc__parent{
  width:100%;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap: 10px;
  text-align:left;

  padding: 11px 12px;
  border-radius: 12px;
  border: 1px solid transparent;
  background: transparent;

  color: var(--stm-oc-text);
  font-weight: 500;
  font-size: 14px;

  cursor:pointer;
  text-decoration:none;
}

/* ✅ HARD FIX: ensure anchors behave like buttons (hover hit area) */
.stm-oc__link{
  display:block;
}

/* ✅ MAIN HOVER (button/link) */
.stm-oc__link:hover,
.stm-oc__parent:hover{
  background: var(--stm-orange);
  color:#fff;
}

/* ✅ INSURANCE: if markup ever renders text inside LI, LI hover still works */
.stm-oc__item:hover > .stm-oc__link,
.stm-oc__item:hover > .stm-oc__parent{
  background: var(--stm-orange);
  color:#fff;
}

/* Focus */
.stm-oc__link:focus-visible,
.stm-oc__parent:focus-visible{
  outline: 2px solid var(--stm-orange);
  outline-offset: 2px;
  background: var(--stm-orange);
  color:#fff;
}

/* Sub-menu */
.stm-oc__sub{
  list-style:none;
  margin: 0 0 10px;
  padding: 0 0 0 10px;
  display:none;
  max-height: none;
  overflow: visible;
  border-left: 2px solid rgba(0,0,0,.06);
}

/* Sub-menu link */
.stm-oc__sub .stm-oc__link{
  font-size: 14px;
  font-weight: 500;
  color: var(--stm-oc-text);
  padding: 9px 14px;
}

/* ✅ Sub hover same */
.stm-oc__sub .stm-oc__link:hover,
.stm-oc__sub .stm-oc__link:focus-visible{
  background: var(--stm-orange);
  color:#fff;
}

/* Chevron */
.stm-oc__chev{
  width: 10px;
  height: 10px;
  display:inline-block;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(-45deg);
  opacity: .9;
}

/* Open state */
.stm-oc__item.is-sub-open > .stm-oc__sub{ display:block; }
.stm-oc__item.is-sub-open > .stm-oc__parent .stm-oc__chev{ transform: rotate(45deg); }

/* Admin note */
.stm-oc__note{
  padding: 10px 12px;
  font-size: 13px;
  color: var(--stm-oc-muted);
  background: rgba(15,23,42,.03);
  border-radius: 12px;
}
