.op-host {
  display: contents;
}

.app-sidebar {
  width: 260px;
  position: fixed;
  top: 0;
  left: 0;
  height: 100vh;
  background: linear-gradient(180deg, #0091e6 0%, #004f8c 100%);
  color: #fff;
  z-index: 100;
}

.sidebar-brand {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}

.sidebar-brand-title {
  font-weight: 700;
  font-size: 1.1rem;
  line-height: 1.2;
}

.sidebar-brand-subtitle {
  color: rgba(255, 255, 255, 0.7);
}

.sidebar-nav {
  flex: 1 1 auto;
  overflow-y: auto;
  padding: 1rem 0;
}

.sidebar-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  width: 100%;
  padding: 0.75rem 1.5rem;
  color: rgba(255, 255, 255, 0.85);
  text-decoration: none;
  font-weight: 600;
  border-left: 4px solid transparent;
  background: none;
  border-top: none;
  border-right: none;
  border-bottom: none;
  transition: background-color 0.15s ease-out;
}
.sidebar-link .icon {
  fill: currentColor;
  flex-shrink: 0;
}
.sidebar-link:hover {
  background-color: rgba(255, 255, 255, 0.08);
  color: #fff;
}
.sidebar-link.active {
  background-color: rgba(255, 255, 255, 0.16);
  border-left-color: #fff;
  color: #fff;
}

.sidebar-link-toggle,
.sidebar-link-pulsante {
  cursor: pointer;
  font-family: inherit;
  font-size: inherit;
}

.sidebar-chevron {
  fill: currentColor;
  flex-shrink: 0;
  transition: transform 0.15s ease-out;
}

.sidebar-chevron-open {
  transform: rotate(90deg);
}

.sidebar-subnav {
  display: flex;
  flex-direction: column;
  padding: 0.25rem 0 0.5rem;
  background-color: rgba(0, 0, 0, 0.12);
}

.sidebar-sublink {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.5rem 1.5rem 0.5rem 2.75rem;
  color: rgba(255, 255, 255, 0.75);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 600;
}
.sidebar-sublink .icon {
  fill: currentColor;
  flex-shrink: 0;
}
.sidebar-sublink:hover {
  background-color: rgba(255, 255, 255, 0.08);
  color: #fff;
}
.sidebar-sublink.active {
  color: #fff;
  background-color: rgba(255, 255, 255, 0.12);
}

.sidebar-sublink-accent {
  color: #ffd54a;
}
.sidebar-sublink-accent:hover, .sidebar-sublink-accent.active {
  color: #ffd54a;
}

.sidebar-separatore {
  margin: 0.75rem 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.2);
}

.sidebar-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.4rem;
  height: 1.4rem;
  padding: 0 0.4rem;
  border-radius: 1rem;
  background-color: #fff;
  color: #004f8c;
  font-size: 0.75rem;
  font-weight: 700;
  line-height: 1;
}

.sidebar-footer {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
}

.sidebar-avatar {
  flex-shrink: 0;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.8rem;
}

.sidebar-username {
  font-weight: 600;
}

.sidebar-logout {
  background: none;
  border: none;
  padding: 0;
  color: rgba(255, 255, 255, 0.75);
  font-size: 0.85rem;
  text-decoration: underline;
}
.sidebar-logout:hover {
  color: #fff;
}

.app-sidebar-mobile {
  position: sticky;
  top: 0;
  z-index: 1030;
  width: 100%;
  align-items: center;
  gap: 0.75rem;
  min-height: 3.5rem;
  padding: 0.25rem 0.75rem;
  background: linear-gradient(90deg, #0091e6 0%, #004f8c 100%);
  color: #fff;
}

.menu-mobile-pulsante,
.menu-mobile-chiudi {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 2.75rem;
  min-width: 2.75rem;
  padding: 0.5rem 0.75rem;
  border: 1px solid rgba(255, 255, 255, 0.6);
  border-radius: 0.375rem;
  background: transparent;
  color: #fff;
  font-weight: 600;
  justify-content: center;
}
.menu-mobile-pulsante .icon,
.menu-mobile-chiudi .icon {
  fill: currentColor;
}
.menu-mobile-pulsante:hover, .menu-mobile-pulsante:focus-visible,
.menu-mobile-chiudi:hover,
.menu-mobile-chiudi:focus-visible {
  background-color: rgba(255, 255, 255, 0.15);
}
.menu-mobile-pulsante:focus-visible,
.menu-mobile-chiudi:focus-visible {
  outline: 3px solid #fff;
  outline-offset: 2px;
}

.menu-mobile-voce-attiva {
  flex: 1 1 auto;
  min-width: 0;
  font-weight: 600;
}

.menu-mobile-logo {
  height: 1.75rem;
  width: auto;
  flex-shrink: 0;
}

.menu-mobile-velo {
  position: fixed;
  inset: 0;
  z-index: 1095;
  background-color: rgba(0, 0, 0, 0.5);
}

.menu-mobile-pannello {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  z-index: 1096;
  width: min(20rem, 88vw);
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, #0091e6 0%, #004f8c 100%);
  color: #fff;
  box-shadow: 0 0 1.5rem rgba(0, 0, 0, 0.3);
  overscroll-behavior: contain;
}
.menu-mobile-pannello .sidebar-nav {
  padding: 0.5rem 0;
}
.menu-mobile-pannello .sidebar-link,
.menu-mobile-pannello .sidebar-sublink {
  min-height: 2.75rem;
}

.menu-mobile-testa {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.75rem 0.75rem 0.75rem 1.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}

.sidebar-tema {
  display: inline-flex;
  margin-top: 0.5rem;
  border: 1px solid rgba(255, 255, 255, 0.6);
  border-radius: 6px;
  overflow: hidden;
}
.sidebar-tema button {
  border: 0;
  background: transparent;
  color: #fff;
  font-size: 0.75rem;
  padding: 0.25rem 0.5rem;
  min-height: 1.75rem;
  cursor: pointer;
}
.sidebar-tema button + button {
  border-left: 1px solid rgba(255, 255, 255, 0.4);
}
.sidebar-tema button[aria-pressed=true] {
  background: #fff;
  color: #004f8c;
  font-weight: 700;
}
.sidebar-tema button:focus-visible {
  outline: 2px solid #fff;
  outline-offset: -2px;
}
