/* Portal shell */
.portalShell {
  min-height: calc(100vh - 56px);
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr);
  overflow: hidden;
  background: var(--portal-bg);
  border: 1px solid var(--portal-border);
  border-radius: 20px;
  box-shadow: var(--portal-shadow);
}

.portalSidebar {
  position: sticky;
  top: 0;
  min-height: calc(100vh - 56px);
  display: flex;
  flex-direction: column;
  padding: 22px 16px;
  color: #cbd5e1;
  background:
    radial-gradient(circle at top left, rgba(59, 130, 246, 0.18), transparent 18rem),
    #111827;
}

.sidebarBrand,
.brandBlock {
  display: flex;
  align-items: center;
  gap: 12px;
}

.sidebarBrand {
  padding: 0 8px 22px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.16);
}

.sidebarBrand strong {
  display: block;
  color: #fff;
  font-size: 0.96rem;
}

.sidebarBrand span:last-child {
  display: block;
  margin-top: 2px;
  color: #94a3b8;
  font-size: 0.75rem;
}

.brandMark {
  display: inline-grid;
  place-items: center;
  flex: 0 0 42px;
  width: 42px;
  height: 42px;
  color: #fff;
  background: linear-gradient(145deg, #3b82f6, #1d4ed8);
  border-radius: 12px;
  font-size: 0.82rem;
  font-weight: 900;
  letter-spacing: 0.04em;
  box-shadow: 0 8px 18px rgba(37, 99, 235, 0.26);
}

.sidebarNav {
  display: grid;
  gap: 6px;
  margin-top: 22px;
}

.sidebarLink {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 44px;
  padding: 10px 12px;
  color: #cbd5e1;
  border-radius: 10px;
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 650;
  transition: background 0.15s ease, color 0.15s ease;
}

.sidebarLink:hover,
.sidebarLink.active {
  color: #fff;
  background: rgba(59, 130, 246, 0.18);
}

.navIcon {
  width: 24px;
  color: #93c5fd;
  font-size: 1.05rem;
  text-align: center;
}

.sidebarStatus {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: auto;
  padding: 14px 12px;
  background: rgba(15, 23, 42, 0.58);
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 12px;
}

.sidebarStatus strong,
.sidebarStatus span {
  display: block;
}

.sidebarStatus strong {
  color: #f8fafc;
  font-size: 0.8rem;
}

.sidebarStatus span:last-child {
  margin-top: 2px;
  color: #94a3b8;
  font-size: 0.72rem;
}

.statusDot {
  display: inline-block;
  flex: 0 0 9px;
  width: 9px;
  height: 9px;
  background: #22c55e;
  border-radius: 50%;
  box-shadow: 0 0 0 4px rgba(34, 197, 94, 0.15);
}

.portalMain {
  min-width: 0;
  padding: 26px;
}

.portalMain .topBar {
  margin-bottom: 22px;
  padding: 0 0 22px;
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--portal-border);
  border-radius: 0;
  box-shadow: none;
  backdrop-filter: none;
}

.topBarActions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.eyebrow {
  display: block;
  margin-bottom: 6px;
  color: var(--portal-primary);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.dashboardMeta {
  position: relative;
  z-index: 1;
  display: block;
  margin-top: 10px;
  color: var(--portal-muted);
  font-size: 0.76rem;
}

.cardHeading {
  margin-bottom: 18px;
}

.cardHeading h2,
.cardHeading p {
  margin-bottom: 0;
}

.loginHeader {
  width: min(1100px, 100%);
  margin-inline: auto;
}

.loginIntro {
  margin-bottom: 22px;
}

.loginButton {
  width: 100%;
  margin-top: 22px;
}

.loginFooter {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  margin-top: 20px;
  color: var(--portal-muted);
  font-size: 0.78rem;
}

html {
  scroll-behavior: smooth;
}

@media (max-width: 1080px) {
  .portalShell {
    grid-template-columns: 210px minmax(0, 1fr);
  }

  .portalMain {
    padding: 20px;
  }
}

@media (max-width: 820px) {
  .container {
    width: 100%;
    padding: 0;
  }

  .portalShell {
    display: block;
    min-height: 100vh;
    border: 0;
    border-radius: 0;
  }

  .portalSidebar {
    position: static;
    min-height: auto;
    padding: 14px;
  }

  .sidebarBrand,
  .sidebarStatus {
    display: none;
  }

  .sidebarNav {
    display: flex;
    gap: 6px;
    margin: 0;
    overflow-x: auto;
  }

  .sidebarLink {
    flex: 0 0 auto;
    min-height: 40px;
    padding: 8px 11px;
  }

  .portalMain {
    padding: 16px;
  }

  .topBarActions {
    width: 100%;
  }

  .topBarActions button {
    flex: 1;
  }
}

@media (max-width: 560px) {
  .navIcon {
    display: none;
  }

  .sidebarLink {
    font-size: 0.8rem;
  }
}
