.page-shell {
  width: min(100%, 820px);
  margin: 0 auto;
  padding:
    max(18px, env(safe-area-inset-top))
    clamp(14px, 4vw, 28px)
    max(30px, env(safe-area-inset-bottom));
}

.page-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 20px;
}

.page-back {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 38px;
  padding: 0 14px 0 11px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--text);
  background: rgba(11, 18, 38, .66);
  text-decoration: none;
  font-size: 12px;
  font-weight: 650;
}

.page-back:hover { border-color: var(--line-strong); }

.page-header { padding: 4px 2px 0; }

.topbar-brand {
  color: var(--faint);
  font-size: 11px;
  font-weight: 750;
  letter-spacing: .14em;
}

.portal-stack {
  display: grid;
  gap: 14px;
  margin-top: 20px;
}

.portal-card {
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.portal-card h2 {
  margin: 0 0 8px;
  font-size: 17px;
  letter-spacing: -.02em;
}

.portal-card > p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.portal-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 16px;
}

.portal-link {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 16px;
  border: 1px solid rgba(126, 150, 255, .38);
  border-radius: 999px;
  color: #e4eaff;
  background: var(--brand-soft);
  text-decoration: none;
  font-size: 12px;
  font-weight: 650;
}

.portal-link.is-ghost {
  border-color: var(--line);
  color: var(--muted);
  background: rgba(255, 255, 255, .035);
}

.faq-list {
  display: grid;
  gap: 12px;
  margin: 14px 0 0;
}

.faq-item {
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.faq-item:first-child {
  padding-top: 0;
  border-top: 0;
}

.faq-item dt {
  color: var(--text);
  font-size: 13px;
  font-weight: 650;
  line-height: 1.5;
}

.faq-item dd {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.7;
}

.profile-card {
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 20px;
  border: 1px solid var(--line-strong);
  border-radius: 18px;
  background:
    linear-gradient(135deg, rgba(109, 140, 255, .18), rgba(21, 165, 139, .07)),
    var(--panel);
  box-shadow: var(--shadow);
}

.profile-avatar {
  display: grid;
  flex: 0 0 auto;
  width: 56px;
  height: 56px;
  place-items: center;
  border: 1px solid rgba(147, 169, 255, .42);
  border-radius: 18px;
  color: #fff;
  background: linear-gradient(145deg, rgba(123, 151, 255, .95), rgba(70, 91, 203, .86));
  font-size: 23px;
  font-weight: 800;
}

.profile-label {
  margin: 0 0 4px;
  color: var(--faint);
  font-size: 10px;
  font-weight: 750;
  letter-spacing: .14em;
}

.profile-name {
  margin: 0;
  font-size: 18px;
  font-weight: 750;
  letter-spacing: -.02em;
}

.profile-note {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
}

.menu-list {
  display: grid;
  margin-top: 10px;
}

.menu-list a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 48px;
  border-top: 1px solid var(--line);
  color: var(--text);
  text-decoration: none;
  font-size: 13px;
  font-weight: 600;
}

.menu-list a:first-child { border-top: 0; }

.menu-list a span:last-child {
  color: var(--faint);
  font-size: 16px;
}

.portal-footer {
  margin-top: 22px;
  color: var(--faint);
  font-size: 10px;
  line-height: 1.6;
  text-align: center;
}

@media (max-width: 359px) {
  .portal-card { padding: 17px; }
  .profile-card { padding: 17px; }
}
