:root {
  --app-shell-accent: #2f6fed;
  --app-shell-accent-soft: #eef4ff;
  --app-shell-text: #111827;
  --app-shell-muted: #6b7280;
  --app-shell-line: rgba(15, 23, 42, 0.10);
  --app-shell-shadow: 0 18px 48px rgba(15, 23, 42, 0.18);
}

.appShellHeaderLeft {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.appShellMenuWrap {
  position: relative;
  z-index: 1000;
  flex: 0 0 auto;
}

.appShellMenuButton {
  width: 44px !important;
  height: 44px !important;
  min-width: 44px !important;
  min-height: 44px !important;
  padding: 0 !important;
  border: 1px solid rgba(255, 255, 255, 0.30) !important;
  border-radius: 12px !important;
  background: rgba(255, 255, 255, 0.12) !important;
  color: #fff !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  cursor: pointer !important;
  touch-action: manipulation;
}

.appShellMenuButton:hover {
  background: rgba(255, 255, 255, 0.20) !important;
}

.appShellMenuButton:focus-visible,
.appShellDropdown a:focus-visible,
.appShellDropdown button:focus-visible {
  outline: 3px solid rgba(255, 255, 255, 0.88);
  outline-offset: 2px;
}

.appShellMenuIcon {
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
}

.appShellMenuIcon span {
  display: block;
  width: 18px;
  height: 2px;
  border-radius: 999px;
  background: currentColor;
}

.appShellDropdown {
  position: absolute !important;
  top: calc(100% + 10px) !important;
  left: 0 !important;
  right: auto !important;
  width: min(320px, calc(100vw - 24px)) !important;
  min-width: 280px !important;
  max-height: min(720px, calc(100vh - 92px)) !important;
  overflow-y: auto !important;
  padding: 8px !important;
  border: 1px solid var(--app-shell-line) !important;
  border-radius: 16px !important;
  background: #fff !important;
  box-shadow: var(--app-shell-shadow) !important;
  color: var(--app-shell-text) !important;
  z-index: 1010 !important;
}

.appShellDropdown[hidden] {
  display: none !important;
}

.appShellMenuSectionLabel {
  padding: 8px 14px 4px;
  color: var(--app-shell-muted);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.appShellMenuItem,
.appShellLogout {
  display: flex !important;
  align-items: center !important;
  width: 100% !important;
  min-height: 44px !important;
  padding: 10px 14px !important;
  border: 0 !important;
  border-radius: 12px !important;
  background: #fff !important;
  color: var(--app-shell-text) !important;
  font: inherit !important;
  font-size: 14px !important;
  font-weight: 750 !important;
  line-height: 1.35 !important;
  text-align: left !important;
  text-decoration: none !important;
  cursor: pointer !important;
}

.appShellMenuItem:hover,
.appShellLogout:hover {
  background: #f8fbff !important;
}

.appShellMenuItem.current {
  background: var(--app-shell-accent-soft) !important;
  color: var(--app-shell-accent) !important;
  pointer-events: none !important;
}

.appShellMenuDivider {
  height: 1px;
  margin: 8px 6px;
  background: var(--app-shell-line);
}

.appShellLogout {
  color: #b91c1c !important;
}

.appShellFooter {
  margin-top: 32px !important;
  padding: 24px 16px 28px !important;
  border-top: 1px solid var(--app-shell-line) !important;
  background: transparent !important;
  color: var(--app-shell-muted) !important;
}

.appShellFooterInner {
  width: 100%;
  max-width: 980px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 18px;
}

.appShellFooterLinks {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 14px;
  font-size: 13px;
}

.appShellFooterLinks a {
  color: var(--app-shell-accent) !important;
  font-weight: 650;
  text-decoration: none !important;
}

.appShellFooterLinks a:hover {
  text-decoration: underline !important;
}

.appShellFooterCopy {
  font-size: 12px;
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 4px 12px;
}

.appShellFooterCompany a,
.appShellCompanyLogoLink {
  color: var(--app-shell-accent) !important;
  font-weight: 650;
  text-decoration: none !important;
}

.appShellFooterCompany a:hover,
.appShellCompanyLogoLink:hover {
  text-decoration: underline !important;
}

.appShellCompanyLogoLink {
  display: inline-flex;
}

@media (max-width: 640px) {
  .appShellDropdown {
    position: fixed !important;
    top: 68px !important;
    left: 12px !important;
    width: calc(100vw - 24px) !important;
    max-height: calc(100vh - 80px) !important;
  }

  .appShellFooterInner {
    display: grid;
  }

  .appShellFooterLinks {
    gap: 12px 16px;
  }

  .appShellFooterCopy {
    justify-content: flex-start;
  }
}
