:root {
  color-scheme: light;
  --ph-bg: #f3f2ed;
  --ph-surface: #ffffff;
  --ph-surface-soft: #ecebe5;
  --ph-ink: #12131a;
  --ph-muted: #63656f;
  --ph-line: #d9d8d1;
  --ph-line-strong: #b9b8b1;
  --ph-violet: #5d51ff;
  --ph-violet-dark: #4337de;
  --ph-violet-soft: #e7e4ff;
  --ph-cyan: #47d7df;
  --ph-coral: #ff715b;
  --ph-lime: #d8ff66;
  --ph-warm: #fff1d8;
  --ph-danger: #b9364b;
  --ph-success: #137858;
  --ph-shadow: 0 22px 60px rgba(28, 27, 23, 0.09);
  --ph-radius-lg: 30px;
  --ph-radius-md: 20px;
  --ph-radius-sm: 12px;
  --ph-max: 1240px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body.platform-body {
  min-width: 320px;
  margin: 0;
  background:
    radial-gradient(circle at 5% 1%, rgba(93, 81, 255, 0.12), transparent 27rem),
    radial-gradient(circle at 96% 15%, rgba(71, 215, 223, 0.13), transparent 25rem),
    var(--ph-bg);
  color: var(--ph-ink);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

button,
input,
select {
  color: inherit;
  font: inherit;
}

a {
  color: inherit;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.22em;
}

a:hover {
  text-decoration-thickness: 2px;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

:focus-visible {
  outline: 3px solid var(--ph-cyan);
  outline-offset: 3px;
}

.ph-page {
  width: min(100%, 1600px);
  min-height: 100vh;
  margin: 0 auto;
  overflow: hidden;
}

.ph-skip-link {
  position: fixed;
  z-index: 100;
  top: 0.75rem;
  left: 0.75rem;
  padding: 0.65rem 0.9rem;
  border-radius: 0.5rem;
  background: var(--ph-ink);
  color: #fff;
  transform: translateY(-160%);
}

.ph-skip-link:focus {
  transform: translateY(0);
}

.ph-header {
  position: relative;
  z-index: 10;
  display: flex;
  width: min(calc(100% - 3rem), var(--ph-max));
  min-height: 82px;
  margin: 0 auto;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  border-bottom: 1px solid rgba(18, 19, 26, 0.14);
}

.ph-brand {
  display: inline-flex;
  align-items: center;
  color: var(--ph-ink);
  text-decoration: none;
}

.ph-brand-mark {
  display: grid;
  width: 2.15rem;
  height: 2.15rem;
  margin-right: 0.55rem;
  place-items: center;
  border-radius: 0.65rem 0.65rem 0.65rem 0.15rem;
  background: var(--ph-ink);
  color: var(--ph-lime);
  font-size: 1.35rem;
  font-weight: 850;
  line-height: 1;
}

.ph-brand-name {
  font-size: 1.25rem;
  font-weight: 850;
  letter-spacing: -0.04em;
}

.ph-brand-domain {
  color: var(--ph-muted);
  font-size: 0.88rem;
  font-weight: 650;
}

.ph-header-nav,
.ph-footer nav,
.ph-heading-actions,
.ph-hero-actions,
.ph-inline-links,
.ph-row-actions {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.ph-header-nav > a:not(.ph-button) {
  color: #3c3e48;
  font-size: 0.9rem;
  font-weight: 650;
  text-decoration: none;
}

.ph-header-nav > a:not(.ph-button):hover {
  color: var(--ph-violet-dark);
}

.ph-button {
  display: inline-flex;
  min-height: 48px;
  padding: 0.78rem 1.1rem;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  border: 1px solid transparent;
  border-radius: 0.75rem;
  cursor: pointer;
  font-weight: 760;
  line-height: 1.1;
  text-align: center;
  text-decoration: none;
  transition: transform 160ms ease, box-shadow 160ms ease, background-color 160ms ease;
}

.ph-button:not(:disabled):hover {
  transform: translateY(-2px);
}

.ph-button:disabled,
.ph-button[aria-disabled="true"] {
  cursor: not-allowed;
  opacity: 0.48;
}

.ph-button-primary {
  background: var(--ph-violet);
  box-shadow: 0 8px 22px rgba(93, 81, 255, 0.24);
  color: #fff;
}

.ph-button-primary:not(:disabled):hover {
  background: var(--ph-violet-dark);
  box-shadow: 0 12px 28px rgba(93, 81, 255, 0.31);
}

.ph-button-secondary {
  border-color: var(--ph-line-strong);
  background: rgba(255, 255, 255, 0.65);
  color: var(--ph-ink);
}

.ph-button-secondary:hover {
  background: #fff;
}

.ph-button-dark {
  background: var(--ph-ink);
  color: #fff;
}

.ph-button-dark:hover {
  box-shadow: 0 10px 24px rgba(18, 19, 26, 0.22);
}

.ph-button-small {
  min-height: 40px;
  padding: 0.62rem 0.92rem;
  font-size: 0.88rem;
}

.ph-hero {
  position: relative;
  display: grid;
  width: min(calc(100% - 3rem), var(--ph-max));
  min-height: 680px;
  margin: 0 auto;
  padding: 6rem 0 5rem;
  grid-template-columns: minmax(0, 1.18fr) minmax(340px, 0.82fr);
  align-items: center;
  gap: clamp(3rem, 7vw, 7.5rem);
}

.ph-hero::before {
  position: absolute;
  z-index: -1;
  top: 5rem;
  left: 48%;
  width: 240px;
  height: 240px;
  border: 1px solid rgba(93, 81, 255, 0.23);
  border-radius: 50%;
  content: "";
  transform: translateX(-50%);
}

.ph-eyebrow,
.ph-kicker {
  margin: 0 0 0.8rem;
  color: var(--ph-violet-dark);
  font-size: 0.72rem;
  font-weight: 840;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.ph-eyebrow {
  display: flex;
  align-items: center;
  gap: 0.58rem;
}

.ph-eyebrow > span {
  width: 1.75rem;
  height: 2px;
  background: var(--ph-violet);
}

.ph-hero h1,
.ph-dashboard-heading h1 {
  max-width: 830px;
  margin: 0;
  font-size: clamp(3.6rem, 7.2vw, 7rem);
  font-weight: 830;
  letter-spacing: -0.075em;
  line-height: 0.92;
}

.ph-hero h1 em {
  position: relative;
  color: var(--ph-violet);
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 500;
  letter-spacing: -0.055em;
}

.ph-hero h1 em::after {
  position: absolute;
  right: 0.02em;
  bottom: -0.04em;
  left: 0.04em;
  height: 0.12em;
  border-radius: 999px;
  background: var(--ph-lime);
  content: "";
  transform: rotate(-1.5deg);
}

.ph-hero-lede {
  max-width: 680px;
  margin: 2rem 0 0;
  color: #4e505a;
  font-size: clamp(1.05rem, 1.8vw, 1.27rem);
  line-height: 1.65;
}

.ph-hero-actions {
  margin-top: 2.25rem;
  flex-wrap: wrap;
}

.ph-hero-note {
  margin: 1rem 0 0;
  color: var(--ph-muted);
  font-size: 0.86rem;
}

.ph-flow-card {
  position: relative;
  padding: 1.2rem;
  border: 1px solid rgba(18, 19, 26, 0.12);
  border-radius: var(--ph-radius-lg);
  background: rgba(255, 255, 255, 0.76);
  box-shadow: var(--ph-shadow);
  backdrop-filter: blur(18px);
}

.ph-flow-card::after {
  position: absolute;
  z-index: -1;
  right: -2.2rem;
  bottom: -2.2rem;
  width: 7rem;
  height: 7rem;
  border-radius: 1.6rem;
  background: var(--ph-cyan);
  content: "";
  transform: rotate(9deg);
}

.ph-flow-header {
  display: flex;
  padding: 0.35rem 0.35rem 1rem;
  align-items: center;
  justify-content: space-between;
  color: var(--ph-muted);
  font-size: 0.76rem;
  font-weight: 720;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.ph-live-dot {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--ph-success);
}

.ph-live-dot::before {
  width: 0.48rem;
  height: 0.48rem;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 0 4px rgba(19, 120, 88, 0.12);
  content: "";
}

.ph-flow-list {
  display: grid;
  margin: 0;
  padding: 0;
  gap: 0.65rem;
  list-style: none;
}

.ph-flow-list li {
  display: grid;
  min-height: 118px;
  padding: 1.15rem;
  grid-template-columns: 3rem 1fr;
  gap: 0.8rem;
  border: 1px solid var(--ph-line);
  border-radius: 1.15rem;
  background: #fff;
}

.ph-flow-list li:nth-child(2) {
  margin-left: 1rem;
  background: var(--ph-violet-soft);
  border-color: #c9c4ff;
}

.ph-flow-list li:nth-child(3) {
  margin-left: 2rem;
}

.ph-flow-number {
  color: var(--ph-violet-dark);
  font-size: 0.75rem;
  font-weight: 850;
  letter-spacing: 0.08em;
}

.ph-flow-list strong {
  font-size: 1rem;
}

.ph-flow-list p {
  margin: 0.35rem 0 0;
  color: var(--ph-muted);
  font-size: 0.86rem;
  line-height: 1.5;
}

.ph-capabilities {
  padding: 6.5rem max(1.5rem, calc((100% - var(--ph-max)) / 2));
  background: var(--ph-ink);
  color: #fff;
}

.ph-section-intro {
  display: grid;
  margin-bottom: 3rem;
  grid-template-columns: 0.6fr 1.4fr;
  align-items: start;
  gap: 2rem;
}

.ph-section-intro .ph-kicker,
.ph-agent-callout .ph-kicker,
.ph-feature-card-dark .ph-kicker {
  color: var(--ph-lime);
}

.ph-section-intro h2,
.ph-agent-callout h2,
.ph-panel-heading h2 {
  margin: 0;
  font-size: clamp(2rem, 4.1vw, 4rem);
  font-weight: 790;
  letter-spacing: -0.055em;
  line-height: 1.02;
}

.ph-capability-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.ph-capability-card {
  position: relative;
  display: flex;
  min-height: 360px;
  padding: 1.6rem;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: var(--ph-radius-md);
  background: #1c1d25;
}

.ph-capability-card::after {
  position: absolute;
  right: -2.5rem;
  bottom: -3rem;
  width: 9rem;
  height: 9rem;
  border-radius: 50%;
  content: "";
  opacity: 0.18;
}

.ph-accent-violet::after { background: var(--ph-violet); }
.ph-accent-cyan::after { background: var(--ph-cyan); }
.ph-accent-coral::after { background: var(--ph-coral); }

.ph-card-index {
  color: #9b9ca7;
  font-size: 0.75rem;
  font-weight: 800;
}

.ph-capability-card h3 {
  margin: auto 0 0.9rem;
  font-size: 2rem;
  letter-spacing: -0.04em;
}

.ph-capability-card p {
  margin: 0;
  color: #bfc0c8;
  font-size: 0.94rem;
}

.ph-capability-card a {
  margin-top: 1.5rem;
  color: #fff;
  font-size: 0.9rem;
  font-weight: 720;
}

.ph-agent-callout {
  display: grid;
  width: min(calc(100% - 3rem), var(--ph-max));
  margin: 5.5rem auto;
  padding: clamp(2rem, 5vw, 4.5rem);
  grid-template-columns: 1fr 0.8fr;
  align-items: end;
  gap: 2.5rem 4rem;
  border-radius: var(--ph-radius-lg);
  background: var(--ph-lime);
}

.ph-agent-callout .ph-kicker {
  color: #3e4f00;
}

.ph-agent-callout p {
  margin: 0;
  color: #3b401f;
  font-size: 1.02rem;
}

.ph-agent-callout .ph-button {
  width: max-content;
  grid-column: 2;
}

.ph-dashboard-heading {
  display: flex;
  width: min(calc(100% - 3rem), var(--ph-max));
  margin: 0 auto;
  padding: 4.6rem 0 2.7rem;
  align-items: end;
  justify-content: space-between;
  gap: 2rem;
}

.ph-dashboard-heading h1 {
  font-size: clamp(2.6rem, 5vw, 5.2rem);
}

.ph-dashboard-heading > div > p:last-child {
  margin: 1.1rem 0 0;
  color: var(--ph-muted);
  font-size: 1.03rem;
}

.ph-heading-actions {
  flex: 0 0 auto;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.ph-dashboard {
  display: grid;
  width: min(calc(100% - 3rem), var(--ph-max));
  margin: 0 auto 5rem;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 1rem;
}

.ph-dashboard-nav,
.ph-dashboard-content {
  border: 1px solid rgba(18, 19, 26, 0.11);
  border-radius: var(--ph-radius-md);
  background: rgba(255, 255, 255, 0.83);
  box-shadow: 0 16px 48px rgba(28, 27, 23, 0.06);
  backdrop-filter: blur(16px);
}

.ph-dashboard-nav {
  display: flex;
  min-height: 680px;
  padding: 0.8rem;
  flex-direction: column;
}

.ph-user-mini {
  display: flex;
  padding: 0.7rem 0.65rem 1rem;
  align-items: center;
  gap: 0.72rem;
  border-bottom: 1px solid var(--ph-line);
}

.ph-user-mini > span:last-child {
  display: grid;
  min-width: 0;
}

.ph-user-mini strong {
  overflow: hidden;
  font-size: 0.88rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ph-user-mini small {
  color: var(--ph-muted);
  font-size: 0.7rem;
}

.ph-user-avatar {
  display: grid;
  width: 2.35rem;
  height: 2.35rem;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 0.75rem;
  background: var(--ph-violet-soft);
  color: var(--ph-violet-dark);
  font-weight: 850;
}

.ph-tab-list {
  display: grid;
  margin-top: 0.85rem;
  gap: 0.22rem;
}

.ph-tab {
  display: flex;
  min-height: 42px;
  padding: 0.62rem 0.7rem;
  align-items: center;
  gap: 0.65rem;
  border-radius: 0.65rem;
  color: #4c4e57;
  font-size: 0.85rem;
  font-weight: 670;
  text-decoration: none;
}

.ph-tab:hover {
  background: var(--ph-surface-soft);
  color: var(--ph-ink);
}

.ph-tab.is-active {
  background: var(--ph-ink);
  color: #fff;
}

.ph-tab-dot {
  width: 0.42rem;
  height: 0.42rem;
  flex: 0 0 auto;
  border: 1px solid currentColor;
  border-radius: 50%;
  opacity: 0.7;
}

.ph-tab.is-active .ph-tab-dot {
  border-color: var(--ph-lime);
  background: var(--ph-lime);
  opacity: 1;
}

.ph-agent-mini {
  display: grid;
  margin-top: auto;
  padding: 0.85rem;
  gap: 0.15rem;
  border-radius: 0.85rem;
  background: var(--ph-violet-soft);
  color: var(--ph-violet-dark);
  text-decoration: none;
}

.ph-agent-mini span {
  font-size: 0.68rem;
}

.ph-agent-mini strong {
  font-size: 0.78rem;
}

.ph-dashboard-content {
  min-width: 0;
  min-height: 680px;
  padding: clamp(1.25rem, 3vw, 2.2rem);
}

.ph-dashboard[data-tabs-ready] .ph-tab-panel:not(.is-active) {
  display: none;
}

.ph-tab-panel {
  animation: ph-panel-in 210ms ease-out;
}

@keyframes ph-panel-in {
  from { opacity: 0; transform: translateY(5px); }
  to { opacity: 1; transform: translateY(0); }
}

.ph-panel-heading,
.ph-card-heading {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 2rem;
}

.ph-panel-heading {
  margin-bottom: 1.7rem;
}

.ph-panel-heading h2 {
  font-size: clamp(1.8rem, 3.4vw, 3.1rem);
}

.ph-panel-heading > div > p:last-child {
  max-width: 680px;
  margin: 0.7rem 0 0;
  color: var(--ph-muted);
}

.ph-status-pill,
.ph-show-state {
  display: inline-flex;
  width: max-content;
  align-items: center;
  white-space: nowrap;
  font-size: 0.68rem;
  font-weight: 760;
}

.ph-status-pill {
  padding: 0.42rem 0.62rem;
  gap: 0.42rem;
  border: 1px solid #b9dfd1;
  border-radius: 999px;
  background: #e6f5ef;
  color: var(--ph-success);
}

.ph-status-pill span {
  width: 0.38rem;
  height: 0.38rem;
  border-radius: 50%;
  background: currentColor;
}

.ph-identity-card {
  display: grid;
  padding: 1.2rem 1.3rem;
  grid-template-columns: 1fr 1fr;
  align-items: end;
  gap: 2rem;
  border: 1px solid #ccc7ff;
  border-radius: var(--ph-radius-sm);
  background: linear-gradient(115deg, var(--ph-violet-soft), #f6f4ff);
}

.ph-field-label {
  display: block;
  margin-bottom: 0.38rem;
  color: var(--ph-violet-dark);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.ph-field-label small {
  margin-left: 0.3rem;
  color: #77719c;
  font-size: 0.6rem;
  font-weight: 650;
  letter-spacing: 0;
  text-transform: none;
}

.ph-id-row,
.ph-secret-value {
  display: flex;
  align-items: center;
  gap: 0.55rem;
}

.ph-id-row code {
  color: var(--ph-ink);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 1.45rem;
  font-weight: 780;
}

.ph-copy-button {
  min-height: 32px;
  padding: 0.35rem 0.62rem;
  border: 1px solid var(--ph-line-strong);
  border-radius: 0.5rem;
  background: #fff;
  cursor: pointer;
  font-size: 0.72rem;
  font-weight: 760;
}

.ph-copy-button:hover {
  border-color: var(--ph-violet);
  color: var(--ph-violet-dark);
}

.ph-identity-card p {
  margin: 0;
  color: #615d7f;
  font-size: 0.8rem;
}

.ph-stat-grid {
  display: grid;
  margin-top: 1rem;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.7rem;
}

.ph-stat-grid-compact {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 0 0 1.4rem;
}

.ph-stat-card {
  display: grid;
  min-width: 0;
  padding: 1rem;
  gap: 0.18rem;
  border: 1px solid var(--ph-line);
  border-radius: var(--ph-radius-sm);
  background: #fff;
}

.ph-stat-card span {
  color: var(--ph-muted);
  font-size: 0.72rem;
  font-weight: 720;
}

.ph-stat-card strong {
  overflow: hidden;
  font-size: clamp(1.55rem, 3vw, 2.15rem);
  letter-spacing: -0.05em;
  text-overflow: ellipsis;
}

.ph-stat-card small {
  color: #898a91;
  font-size: 0.66rem;
}

.ph-overview-grid {
  display: grid;
  margin-top: 1rem;
  grid-template-columns: minmax(0, 1.45fr) minmax(250px, 0.55fr);
  gap: 0.8rem;
}

.ph-content-card,
.ph-feature-card,
.ph-credential-form,
.ph-credential-rules {
  border: 1px solid var(--ph-line);
  border-radius: var(--ph-radius-sm);
  background: #fff;
}

.ph-content-card {
  padding: 1.1rem;
}

.ph-card-heading {
  margin-bottom: 0.75rem;
  align-items: end;
}

.ph-card-heading h3,
.ph-content-card > h3,
.ph-feature-card h3,
.ph-credential-layout h3 {
  margin: 0;
  font-size: 1.15rem;
  letter-spacing: -0.025em;
}

.ph-card-heading a,
.ph-content-card > a,
.ph-feature-card a,
.ph-text-link,
.ph-agent-mini,
.ph-principle-grid a {
  color: var(--ph-violet-dark);
  font-size: 0.76rem;
  font-weight: 750;
}

.ph-recent-list {
  display: grid;
  gap: 0.45rem;
}

.ph-recent-show {
  display: flex;
  padding: 0.7rem;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  border-radius: 0.7rem;
  background: #f7f7f4;
}

.ph-recent-main {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 0.72rem;
  text-decoration: none;
}

.ph-recent-main > span:last-child {
  display: grid;
  min-width: 0;
}

.ph-show-monogram {
  display: grid;
  width: 2.25rem;
  height: 2.25rem;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 0.62rem;
  background: var(--ph-ink);
  color: var(--ph-lime);
  font-weight: 820;
}

.ph-recent-main strong,
.ph-recent-main small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ph-recent-main strong {
  font-size: 0.84rem;
}

.ph-recent-main small {
  color: var(--ph-muted);
  font-size: 0.68rem;
}

.ph-recent-meta {
  display: grid;
  flex: 0 0 auto;
  justify-items: end;
  gap: 0.22rem;
}

.ph-recent-meta > a {
  color: var(--ph-violet-dark);
  font-size: 0.67rem;
  font-weight: 720;
}

.ph-show-state {
  padding: 0.25rem 0.45rem;
  border-radius: 999px;
}

.ph-state-draft { background: var(--ph-violet-soft); color: var(--ph-violet-dark); }
.ph-state-private { background: #eceef2; color: #50535d; }
.ph-state-unlisted { background: var(--ph-warm); color: #855800; }
.ph-state-published { background: #dff5ea; color: var(--ph-success); }

.ph-empty-state {
  display: flex;
  min-height: 125px;
  padding: 1rem;
  align-items: center;
  gap: 0.9rem;
  border: 1px dashed var(--ph-line-strong);
  border-radius: 0.8rem;
  background: #fafaf7;
}

.ph-empty-mark {
  display: grid;
  width: 2.6rem;
  height: 2.6rem;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 0.8rem;
  background: var(--ph-violet-soft);
  color: var(--ph-violet-dark);
  font-size: 1.5rem;
}

.ph-empty-state h3,
.ph-empty-state h4 {
  margin: 0;
}

.ph-empty-state p {
  margin: 0.2rem 0 0;
  color: var(--ph-muted);
  font-size: 0.78rem;
}

.ph-empty-state .ph-button {
  margin-left: auto;
  flex: 0 0 auto;
}

.ph-pulse-card {
  background: var(--ph-ink);
  color: #fff;
}

.ph-pulse-card .ph-kicker {
  color: var(--ph-lime);
}

.ph-pulse-card > p:not(.ph-kicker) {
  color: #c9cad1;
  font-size: 0.82rem;
}

.ph-pulse-card > a {
  color: var(--ph-lime);
}

.ph-check-list {
  display: grid;
  margin: 1.15rem 0;
  padding: 0;
  gap: 0.55rem;
  list-style: none;
}

.ph-check-list li {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  color: #e1e2e7;
  font-size: 0.75rem;
}

.ph-check-list span {
  display: grid;
  width: 1.25rem;
  height: 1.25rem;
  place-items: center;
  border: 1px solid #656772;
  border-radius: 50%;
  color: var(--ph-lime);
  font-size: 0.58rem;
}

.ph-show-table {
  display: grid;
  margin-bottom: 1rem;
  gap: 0.65rem;
}

.ph-show-row {
  display: flex;
  padding: 1rem;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  border: 1px solid var(--ph-line);
  border-radius: var(--ph-radius-sm);
  background: #fff;
}

.ph-show-row h3 {
  margin: 0.38rem 0 0;
  font-size: 1rem;
}

.ph-show-row p {
  margin: 0.25rem 0 0;
  color: var(--ph-muted);
  font-size: 0.76rem;
}

.ph-row-actions {
  flex: 0 0 auto;
  gap: 0.8rem;
}

.ph-row-actions a,
.ph-inline-links a {
  color: var(--ph-violet-dark);
  font-size: 0.75rem;
  font-weight: 740;
}

.ph-empty-wide {
  width: 100%;
}

.ph-feature-split,
.ph-credential-layout {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.8rem;
}

.ph-feature-card,
.ph-credential-form,
.ph-credential-rules {
  padding: clamp(1.2rem, 3vw, 2rem);
}

.ph-feature-number {
  display: block;
  margin-bottom: 2.4rem;
  color: var(--ph-violet);
  font-size: clamp(3rem, 7vw, 5.5rem);
  font-weight: 820;
  letter-spacing: -0.07em;
  line-height: 1;
}

.ph-feature-card p {
  color: var(--ph-muted);
  font-size: 0.86rem;
}

.ph-feature-card-dark {
  border-color: var(--ph-ink);
  background: var(--ph-ink);
  color: #fff;
}

.ph-feature-card-dark p {
  color: #c2c3ca;
}

.ph-feature-card-dark a {
  color: var(--ph-lime);
}

.ph-feature-card-warm {
  border-color: #f0d6a8;
  background: var(--ph-warm);
}

.ph-principle-grid,
.ph-privacy-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.8rem;
}

.ph-principle-grid article,
.ph-privacy-grid article {
  padding: 1.25rem;
  border: 1px solid var(--ph-line);
  border-radius: var(--ph-radius-sm);
  background: #fff;
}

.ph-principle-grid strong,
.ph-privacy-grid h3 {
  font-size: 1rem;
}

.ph-principle-grid p,
.ph-privacy-grid p {
  margin: 0.4rem 0 0;
  color: var(--ph-muted);
  font-size: 0.79rem;
}

.ph-privacy-icon {
  display: grid;
  width: 2rem;
  height: 2rem;
  margin-bottom: 1.5rem;
  place-items: center;
  border-radius: 0.6rem;
  background: var(--ph-violet-soft);
  color: var(--ph-violet-dark);
  font-size: 0.72rem;
  font-weight: 850;
}

.ph-privacy-grid h3 {
  margin: 0;
}

.ph-safety-note {
  display: flex;
  margin-top: 0.8rem;
  padding: 1rem 1.2rem;
  align-items: center;
  gap: 1.2rem;
  border-radius: var(--ph-radius-sm);
  background: var(--ph-warm);
}

.ph-safety-note strong {
  flex: 0 0 auto;
  font-size: 0.8rem;
}

.ph-safety-note p {
  margin: 0;
  color: #765c2d;
  font-size: 0.76rem;
}

.ph-credential-form label,
.ph-credential-form legend {
  color: #555760;
  font-size: 0.74rem;
  font-weight: 730;
}

.ph-form-heading {
  display: flex;
  margin-bottom: 1.3rem;
  align-items: start;
  gap: 0.75rem;
}

.ph-form-heading p {
  margin: 0.25rem 0 0;
  color: var(--ph-muted);
  font-size: 0.74rem;
}

.ph-lock-mark {
  display: block;
  width: 2.2rem;
  height: 2.2rem;
  flex: 0 0 auto;
  border: 7px solid var(--ph-violet-soft);
  border-radius: 50% 50% 0.45rem 0.45rem;
  background: var(--ph-violet);
}

.ph-credential-form > label:not(.ph-check) {
  display: block;
  margin: 0.8rem 0 0.3rem;
}

.ph-credential-form input[type="text"],
.ph-credential-form select {
  width: 100%;
  min-height: 44px;
  padding: 0.65rem 0.75rem;
  border: 1px solid var(--ph-line-strong);
  border-radius: 0.65rem;
  background: #fff;
}

.ph-credential-form input:disabled,
.ph-credential-form select:disabled {
  background: #efefeb;
  color: #8a8b91;
}

.ph-credential-form fieldset {
  display: grid;
  margin: 1rem 0;
  padding: 0.85rem;
  gap: 0.45rem;
  border: 1px solid var(--ph-line);
  border-radius: 0.65rem;
}

.ph-check {
  display: flex;
  align-items: center;
  gap: 0.55rem;
}

.ph-check input {
  width: 1rem;
  height: 1rem;
  accent-color: var(--ph-violet);
}

.ph-credential-form .ph-button {
  width: 100%;
}

.ph-form-status {
  margin: 0.7rem 0 0;
  color: var(--ph-muted);
  font-size: 0.7rem;
}

.ph-form-status.is-error {
  color: var(--ph-danger);
}

.ph-credential-rules {
  background: var(--ph-violet-soft);
  border-color: #cbc6ff;
}

.ph-credential-rules h3 {
  max-width: 360px;
  font-size: clamp(1.55rem, 3vw, 2.3rem);
  line-height: 1.08;
}

.ph-credential-rules ul {
  display: grid;
  margin: 1.5rem 0;
  padding: 0;
  gap: 0.65rem;
  list-style: none;
}

.ph-credential-rules li {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.8rem;
  font-weight: 650;
}

.ph-credential-rules li span {
  display: grid;
  width: 1.3rem;
  height: 1.3rem;
  place-items: center;
  border-radius: 50%;
  background: var(--ph-violet);
  color: #fff;
  font-size: 0.63rem;
}

.ph-credential-rules > p:last-child {
  margin: 0;
  color: #666184;
  font-size: 0.75rem;
}

.ph-secret-dialog {
  width: min(calc(100% - 2rem), 620px);
  padding: 0;
  border: 0;
  border-radius: var(--ph-radius-md);
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.32);
}

.ph-secret-dialog::backdrop {
  background: rgba(18, 19, 26, 0.67);
  backdrop-filter: blur(4px);
}

.ph-secret-dialog-inner {
  padding: clamp(1.5rem, 5vw, 3rem);
}

.ph-secret-dialog h2 {
  margin: 0;
  font-size: clamp(1.8rem, 5vw, 3rem);
  letter-spacing: -0.05em;
  line-height: 1;
}

.ph-secret-dialog p:not(.ph-kicker) {
  color: var(--ph-muted);
}

.ph-secret-value {
  margin: 1.2rem 0;
  padding: 0.85rem;
  border: 1px solid var(--ph-line-strong);
  border-radius: 0.7rem;
  background: #f5f5f1;
}

.ph-secret-value code {
  min-width: 0;
  flex: 1;
  overflow-wrap: anywhere;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.86rem;
}

.ph-secret-dialog .ph-button-dark {
  width: 100%;
  margin-top: 1rem;
}

.ph-agent-bootstrap {
  display: grid;
  gap: 0.6rem;
  margin-top: 1.15rem;
}

.ph-agent-bootstrap label {
  color: var(--ph-ink);
  font-size: 0.76rem;
  font-weight: 760;
}

.ph-secret-command {
  display: grid;
  margin: 0;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.7rem;
}

.ph-secret-command code {
  display: block;
  max-height: 7.4rem;
  overflow: auto;
  white-space: pre-wrap;
}

.ph-footer {
  display: flex;
  width: min(calc(100% - 3rem), var(--ph-max));
  min-height: 110px;
  margin: 0 auto;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  border-top: 1px solid var(--ph-line-strong);
  color: var(--ph-muted);
  font-size: 0.76rem;
}

.ph-footer > div {
  display: flex;
  align-items: baseline;
  gap: 0.65rem;
}

.ph-footer strong {
  color: var(--ph-ink);
  font-size: 0.9rem;
}

.ph-footer a {
  text-decoration: none;
}

@media (max-width: 1050px) {
  .ph-hero {
    grid-template-columns: 1fr 0.8fr;
    gap: 3rem;
  }

  .ph-overview-grid {
    grid-template-columns: 1fr;
  }

  .ph-pulse-card {
    min-height: auto;
  }
}

@media (max-width: 860px) {
  .ph-header-nav > a:not(.ph-button):nth-child(2) {
    display: none;
  }

  .ph-hero {
    min-height: auto;
    padding: 4.5rem 0;
    grid-template-columns: 1fr;
  }

  .ph-flow-card {
    width: min(100%, 600px);
  }

  .ph-section-intro,
  .ph-agent-callout {
    grid-template-columns: 1fr;
  }

  .ph-capability-grid {
    grid-template-columns: 1fr;
  }

  .ph-capability-card {
    min-height: 250px;
  }

  .ph-agent-callout .ph-button {
    grid-column: auto;
  }

  .ph-dashboard-heading {
    align-items: start;
    flex-direction: column;
  }

  .ph-heading-actions {
    justify-content: flex-start;
  }

  .ph-dashboard {
    /* A plain ``1fr`` keeps the grid track's automatic min-content width.
       The horizontally scrollable tab row can then force the entire dashboard
       wider than a phone viewport. */
    grid-template-columns: minmax(0, 1fr);
  }

  .ph-dashboard-nav {
    min-height: auto;
    min-width: 0;
    overflow: hidden;
  }

  .ph-user-mini,
  .ph-agent-mini {
    display: none;
  }

  .ph-tab-list {
    display: flex;
    margin: 0;
    padding-bottom: 0.2rem;
    overflow-x: auto;
    scrollbar-width: thin;
  }

  .ph-tab {
    flex: 0 0 auto;
  }

  .ph-stat-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .ph-feature-split,
  .ph-credential-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 620px) {
  .ph-header,
  .ph-hero,
  .ph-dashboard-heading,
  .ph-dashboard,
  .ph-agent-callout,
  .ph-footer {
    width: min(calc(100% - 1.5rem), var(--ph-max));
  }

  .ph-header {
    min-height: 68px;
  }

  .ph-header-nav {
    gap: 0.55rem;
  }

  .ph-header-nav > a:not(.ph-button) {
    display: none;
  }

  .ph-brand-domain {
    display: none;
  }

  .ph-hero {
    padding-top: 3.5rem;
  }

  .ph-hero h1 {
    font-size: clamp(3.1rem, 17vw, 5.2rem);
  }

  .ph-hero-actions,
  .ph-heading-actions {
    display: grid;
    width: 100%;
    grid-template-columns: 1fr;
  }

  .ph-hero-actions .ph-button,
  .ph-heading-actions .ph-button {
    width: 100%;
  }

  .ph-flow-list li:nth-child(2),
  .ph-flow-list li:nth-child(3) {
    margin-left: 0;
  }

  .ph-flow-card::after {
    display: none;
  }

  .ph-capabilities {
    padding-top: 4rem;
    padding-bottom: 4rem;
  }

  .ph-agent-callout {
    margin: 3.5rem auto;
  }

  .ph-dashboard-heading {
    padding: 3.2rem 0 2rem;
  }

  .ph-dashboard-content {
    padding: 1rem;
  }

  .ph-panel-heading,
  .ph-card-heading {
    align-items: start;
    flex-direction: column;
    gap: 0.8rem;
  }

  .ph-identity-card {
    grid-template-columns: 1fr;
    gap: 0.7rem;
  }

  .ph-stat-grid,
  .ph-stat-grid-compact,
  .ph-principle-grid,
  .ph-privacy-grid {
    grid-template-columns: 1fr;
  }

  .ph-recent-show,
  .ph-show-row,
  .ph-empty-state,
  .ph-safety-note {
    align-items: start;
    flex-direction: column;
  }

  .ph-recent-meta {
    width: 100%;
    align-items: center;
    grid-template-columns: 1fr auto;
    justify-items: start;
  }

  .ph-row-actions,
  .ph-empty-state .ph-button {
    width: 100%;
    margin-left: 0;
  }

  .ph-footer {
    padding: 1.5rem 0;
    align-items: start;
    flex-direction: column;
    gap: 1rem;
  }

  .ph-footer nav {
    flex-wrap: wrap;
  }
}

.ph-login-card {
  display: grid;
  gap: 1rem;
  align-content: start;
}

.ph-message-stack {
  width: min(1160px, calc(100% - 2rem));
  margin: 1rem auto 0;
  display: grid;
  gap: 0.5rem;
}

.ph-message {
  margin: 0;
  padding: 0.8rem 1rem;
  border: 1px solid var(--ph-line);
  border-radius: 0.75rem;
  background: #fff;
  color: var(--ph-ink);
}

.ph-message.is-error {
  border-color: color-mix(in srgb, var(--ph-coral) 55%, var(--ph-line));
  color: var(--ph-coral);
}

.ph-wechat-container {
  min-height: 300px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid var(--ph-line);
  border-radius: 1rem;
  background: #fff;
  color: var(--ph-muted);
  text-align: center;
}

.ph-wechat-container iframe {
  width: 100%;
  max-width: 320px;
  min-height: 300px;
  border: 0;
}

.ph-wechat-container .is-error {
  max-width: 24rem;
  padding: 2rem;
  color: var(--ph-coral);
}

.ph-login-fallback {
  margin: 0;
  color: var(--ph-muted);
  font-size: 0.9rem;
  line-height: 1.55;
}

body.platform-body.is-login {
  background: #e9edef;
}

.ph-auth {
  display: grid;
  width: min(calc(100% - 3rem), var(--ph-max));
  min-height: calc(100dvh - 170px);
  margin: 0 auto;
  padding: 54px 0 64px;
  grid-template-columns: minmax(0, 1.15fr) minmax(360px, 0.7fr);
  align-items: center;
  gap: 72px;
}

.ph-auth-context {
  min-width: 0;
}

.ph-auth h1 {
  max-width: 760px;
  margin: 0;
  font-size: 64px;
  font-weight: 830;
  line-height: 1.03;
}

.ph-auth h1 em {
  color: #4d3d59;
  font-family: Georgia, "Songti SC", serif;
  font-style: normal;
  font-weight: 560;
}

.ph-auth-lede {
  max-width: 680px;
  margin: 24px 0 0;
  color: #4d5358;
  font-size: 17px;
  line-height: 1.75;
}

.ph-auth-mobile-jump {
  display: none;
  width: max-content;
  margin-top: 18px;
}

.ph-auth-route {
  display: grid;
  max-width: 680px;
  margin-top: 32px;
  grid-template-columns: auto minmax(36px, 1fr) auto minmax(36px, 1fr) auto;
  align-items: center;
  gap: 10px;
}

.ph-auth-node {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
  border: 1px solid #adb4b8;
  border-radius: 6px;
  padding: 0 11px;
  background: rgba(255, 255, 255, 0.66);
  color: #32373b;
  font-size: 12px;
  font-weight: 720;
  white-space: nowrap;
}

.ph-auth-node b {
  margin-right: 7px;
  color: #747b80;
  font-size: 10px;
}

.ph-auth-node.is-trusted {
  border-color: #16191b;
  background: #16191b;
  color: #fff;
}

.ph-auth-node.is-trusted b { color: #b9f36b; }

.ph-auth-track {
  position: relative;
  height: 2px;
  overflow: hidden;
  background: #b9bfc2;
}

.ph-auth-track i {
  position: absolute;
  top: 0;
  left: -40%;
  width: 38%;
  height: 2px;
  background: #5d51ff;
  animation: ph-auth-pass 1.8s cubic-bezier(.4, 0, .2, 1) infinite;
}

.ph-auth-track:nth-of-type(4) i { animation-delay: .86s; }

@keyframes ph-auth-pass {
  0% { transform: translateX(0); }
  58%, 100% { transform: translateX(370%); }
}

.ph-auth-facts {
  display: grid;
  max-width: 680px;
  margin: 28px 0 0;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border-block: 1px solid #c7cccf;
}

.ph-auth-facts div {
  min-width: 0;
  padding: 14px 0;
}

.ph-auth-facts div:nth-child(odd) { padding-right: 22px; }
.ph-auth-facts div:nth-child(even) { padding-left: 22px; border-left: 1px solid #c7cccf; }
.ph-auth-facts div:nth-child(n + 3) { border-top: 1px solid #c7cccf; }

.ph-auth-facts dt {
  color: #737a7e;
  font-size: 11px;
}

.ph-auth-facts dd {
  margin: 4px 0 0;
  overflow: hidden;
  color: #272b2e;
  font-size: 14px;
  font-weight: 680;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ph-auth-manifesto {
  max-width: 680px;
  margin-top: 30px;
  border-left: 3px solid #5d51ff;
  padding-left: 16px;
}

.ph-auth-manifesto strong {
  display: block;
  margin-bottom: 7px;
  color: #262b2e;
  font-size: 15px;
}

.ph-auth-manifesto p {
  margin: 4px 0 0;
  color: #636a6e;
  font-size: 12px;
  line-height: 1.65;
}

.ph-auth-panel {
  width: 100%;
  max-width: 430px;
  justify-self: end;
  border: 1px solid #c7cccf;
  border-radius: 8px;
  padding: 22px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 24px 66px rgba(31, 38, 42, 0.14);
}

.ph-auth-panel-head {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  align-items: center;
  gap: 11px;
  margin-bottom: 20px;
}

.ph-trusted-mark {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border-radius: 50%;
  background: #16704a;
  color: #fff;
  font-weight: 820;
}

.ph-auth-panel-head strong,
.ph-auth-panel-head small {
  display: block;
}

.ph-auth-panel-head strong { font-size: 15px; }
.ph-auth-panel-head small { margin-top: 2px; color: #6d7377; font-size: 11px; }

.ph-auth-wechat-button {
  display: none;
  width: 100%;
}

.ph-button-wechat {
  background: #087f45;
  color: #fff;
}

.ph-auth-method-title {
  display: flex;
  margin-bottom: 9px;
  align-items: center;
  justify-content: space-between;
}

.ph-auth-method-title strong { font-size: 13px; }
.ph-auth-method-title span { color: #16704a; font-size: 11px; font-weight: 700; }

.ph-auth-qr .ph-wechat-container {
  min-height: 254px;
  border-radius: 6px;
}

.ph-auth-qr .ph-wechat-container iframe { min-height: 254px; }

.ph-auth-mobile-note {
  display: none;
  margin: 0;
  border-left: 3px solid #16704a;
  padding: 10px 12px;
  background: #f2f7f4;
  color: #3f4944;
  font-size: 12px;
  line-height: 1.65;
}

.ph-auth-divider {
  display: grid;
  margin: 18px 0;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 10px;
  color: #7a8084;
  font-size: 11px;
}

.ph-auth-divider::before,
.ph-auth-divider::after {
  height: 1px;
  background: #d7dbdd;
  content: "";
}

.ph-phone-login {
  display: grid;
  gap: 8px;
}

.ph-phone-login label {
  color: #555c60;
  font-size: 11px;
  font-weight: 650;
}

.ph-phone-login input {
  width: 100%;
  height: 44px;
  min-width: 0;
  border: 1px solid #c4c9cc;
  border-radius: 6px;
  padding: 0 11px;
  background: #fff;
  outline: none;
}

.ph-phone-login input:focus {
  border-color: #5d51ff;
  box-shadow: 0 0 0 3px rgba(93, 81, 255, 0.12);
}

.ph-phone-code-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
}

.ph-phone-code-row .ph-button { min-height: 44px; padding-inline: 12px; }
.ph-phone-login > .ph-button { width: 100%; margin-top: 4px; }

.ph-auth-privacy {
  margin: 16px 0 0;
  color: #777d81;
  font-size: 10px;
  line-height: 1.65;
}

.ph-auth[data-wechat="true"] .ph-auth-wechat-button { display: inline-flex; }
.ph-auth[data-wechat="true"] .ph-auth-qr,
.ph-auth[data-wechat="true"] .ph-auth-divider,
.ph-auth[data-wechat="true"] .ph-phone-login { display: none; }

@media (max-width: 900px) {
  .ph-auth {
    grid-template-columns: minmax(0, 1fr);
    gap: 36px;
  }

  .ph-auth-panel { max-width: none; justify-self: stretch; }
}

@media (max-width: 620px) {
  .ph-auth {
    width: min(calc(100% - 1.5rem), var(--ph-max));
    padding: 34px 0 44px;
  }

  .ph-auth h1 { font-size: 42px; }

  .ph-auth:not([data-wechat="true"]) .ph-auth-qr { display: none; }
  .ph-auth:not([data-wechat="true"]) .ph-auth-mobile-note { display: block; }
  .ph-auth-lede { font-size: 15px; }
  .ph-auth-mobile-jump { display: inline-flex; }
  .ph-auth-route { gap: 5px; }
  .ph-auth-node { min-height: 38px; padding: 0 7px; }
  .ph-auth-node b { display: none; }
  .ph-auth-facts { grid-template-columns: minmax(0, 1fr); }
  .ph-auth-facts div:nth-child(n) { border-top: 1px solid #c7cccf; border-left: 0; padding: 11px 0; }
  .ph-auth-facts div:first-child { border-top: 0; }
  .ph-auth-panel { padding: 18px; }
}

.ph-credential-inventory {
  margin-top: 1.25rem;
  padding: 1.2rem;
  border: 1px solid var(--ph-line);
  border-radius: 1rem;
  background: #fff;
}

.ph-credential-list {
  display: grid;
  gap: 0.7rem;
  margin-top: 1rem;
}

.ph-credential-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem;
  border: 1px solid var(--ph-line);
  border-radius: 0.8rem;
  background: var(--ph-paper);
}

.ph-credential-row p,
.ph-credential-row small,
.ph-empty-inline {
  margin: 0.3rem 0 0;
  color: var(--ph-muted);
  overflow-wrap: anywhere;
}

.ph-credential-row.is-inactive {
  opacity: 0.68;
}

@media (max-width: 680px) {
  .ph-credential-row {
    align-items: stretch;
    flex-direction: column;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}

@media (max-width: 620px) {
  .ph-secret-command {
    grid-template-columns: minmax(0, 1fr);
  }

  .ph-secret-command .ph-copy-button {
    width: 100%;
  }
}
