:root {
  --pgh-bg: #f5f8fd;
  --pgh-bg-deep: #dce8fb;
  --pgh-panel: rgba(255, 255, 255, 0.88);
  --pgh-panel-strong: #ffffff;
  --pgh-stroke: rgba(79, 88, 100, 0.14);
  --pgh-stroke-strong: rgba(79, 88, 100, 0.22);
  --pgh-text: #212121;
  --pgh-muted: #4f5864;
  --pgh-soft: #727272;
  --pgh-accent: #3288ff;
  --pgh-accent-soft: #cbe1ff;
  --pgh-success: #4caf74;
  --pgh-shadow: 0 28px 80px rgba(50, 136, 255, 0.12);
  --pgh-card-shadow: 0 18px 42px rgba(79, 88, 100, 0.08);
}

body.pgh-shell-body {
  min-height: 100vh;
  margin: 0;
  font-family: "Avenir Next", "Segoe UI", "Helvetica Neue", Helvetica, Arial, sans-serif;
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.92), transparent 34%),
    radial-gradient(circle at right 12% top 10%, rgba(203, 225, 255, 0.8), transparent 28%),
    linear-gradient(145deg, #eef5ff 0%, #f8fbff 50%, #eaf2ff 100%);
  color: var(--pgh-text);
}

.pgh-shell {
  width: min(1680px, calc(100vw - 32px));
  margin: 16px auto;
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}

.pgh-shell-sidebar {
  position: sticky;
  top: 16px;
  align-self: start;
  min-width: 0;
}

.pgh-main {
  min-width: 0;
}

.pgh-engine-panel {
  background: rgba(255, 255, 255, 0.74);
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 32px;
  box-shadow: var(--pgh-shadow);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  padding: 10px;
}

.pgh-engine-panel .container {
  width: 100%;
  max-width: none;
  padding: 24px 28px 28px;
  box-sizing: border-box;
}

.pgh-nav {
  width: 100%;
  padding: 18px 16px;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 6px;
  font-family: "Avenir Next", "Segoe UI", "Helvetica Neue", Helvetica, Arial, sans-serif;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.68);
  border-radius: 28px;
  box-shadow: 0 18px 52px rgba(50, 136, 255, 0.12);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

.pgh-nav-brand {
  font-weight: 700;
  font-size: 19px;
  color: var(--pgh-text);
  text-decoration: none;
  margin-bottom: 10px;
  padding: 10px 12px 14px;
  letter-spacing: -0.02em;
  border-bottom: 1px solid rgba(79, 88, 100, 0.1);
}

.pgh-nav-links {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.pgh-nav .button_to {
  margin: 0 0 10px;
}

.pgh-logout {
  width: 100%;
  border: 1px solid rgba(79, 88, 100, 0.14);
  border-radius: 16px;
  padding: 11px 14px;
  background: rgba(255, 255, 255, 0.9);
  color: var(--pgh-muted);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-align: left;
  cursor: pointer;
  transition: background 0.18s ease, color 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.pgh-logout:hover {
  background: rgba(255, 255, 255, 1);
  color: var(--pgh-text);
  transform: translateX(2px);
  box-shadow: 0 10px 18px rgba(79, 88, 100, 0.08);
}

.pgh-nav a {
  color: var(--pgh-muted);
  text-decoration: none;
  padding: 11px 14px;
  border-radius: 16px;
  font-size: 13px;
  font-weight: 600;
  transition: background 0.18s ease, color 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.pgh-nav a:hover {
  background: rgba(255, 255, 255, 0.78);
  color: var(--pgh-text);
  transform: translateX(2px);
}

.pgh-nav a.pgh-active {
  background: linear-gradient(135deg, #3288ff 0%, #006bfe 100%);
  color: #fff;
  box-shadow: 0 12px 24px rgba(50, 136, 255, 0.24);
}

@media (max-width: 1024px) {
  .pgh-shell {
    width: min(100vw - 20px, 100%);
    margin: 10px auto;
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .pgh-shell-sidebar {
    position: static;
  }

  .pgh-engine-panel {
    border-radius: 24px;
  }

  .pgh-engine-panel .container {
    padding: 18px 16px 20px;
  }

  .pgh-nav {
    padding: 12px;
    border-radius: 20px;
  }

  .pgh-nav-brand {
    margin-bottom: 6px;
    padding-bottom: 12px;
  }
}
