.personal-page {
  --personal-surface: #fff;
  --personal-text: #202b42;
  --personal-muted: #626d81;
  --personal-line: #e2e6ed;
  --personal-hover: #f3f5fb;
  --personal-selected: #f7f9ff;
  --personal-accent: #345de7;
  --personal-danger: #a83546;
  --personal-danger-hover: #fff4f5;
  max-width: 620px;
  margin-inline: auto;
  color: var(--personal-text);
}

.personal-head {
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 3px 0 18px;
  min-height: 44px;
}

.personal-head h1 {
  font-size: clamp(23px, 3vw, 29px);
  font-weight: 700;
  letter-spacing: -.025em;
  line-height: 1.25;
}

.personal-back {
  display: grid;
  place-items: center;
  flex: none;
  inline-size: 44px;
  block-size: 44px;
  margin-inline-start: -8px;
  padding: 0;
  border: 0;
  border-radius: 12px;
  background: transparent;
  color: inherit;
}

.personal-group + .personal-group { margin-block-start: 21px; }

.personal-group h2 {
  margin: 0 0 7px 3px;
  color: var(--personal-muted);
  font-size: 13px;
  font-weight: 650;
}

.personal-row {
  display: flex;
  align-items: center;
  gap: 11px;
  width: 100%;
  min-height: 57px;
  padding: 12px 13px;
  border: 1px solid var(--personal-line);
  border-radius: var(--radius);
  background: var(--personal-surface);
  color: inherit;
  text-align: start;
}

.personal-row > strong, .personal-row-main { flex: 1; min-width: 0; }
.personal-row-main { display: grid; gap: 2px; }
.personal-row strong { font-size: 14px; font-weight: 650; overflow-wrap: anywhere; }
.personal-row small { color: var(--personal-muted); font-size: 12px; }
.personal-row-value { flex: none; }
.personal-row > .icon { color: var(--personal-muted); }

.personal-organization {
  border: 1px solid var(--personal-line);
  border-radius: var(--radius);
  background: var(--personal-surface);
}

.personal-organization .personal-row {
  min-height: 48px;
  padding-block: 9px;
  border: 0;
  border-radius: 0;
}

.personal-organization .personal-row + .personal-row { border-top: 1px solid var(--personal-line); }
.personal-organization .personal-row:first-child { border-radius: var(--radius) var(--radius) 0 0; }
.personal-organization .personal-row:last-child { border-radius: 0 0 var(--radius) var(--radius); }
.personal-organization .personal-row:focus-visible { outline-offset: -3px; }
.personal-organization-current .personal-row-main { overflow-wrap: anywhere; }

.personal-styles {
  display: grid;
  gap: 12px;
  min-inline-size: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

.personal-style { position: relative; display: block; cursor: pointer; }

.personal-radio, .personal-badge-switch input {
  position: absolute;
  inline-size: 1px;
  block-size: 1px;
  padding: 0;
  margin: 0;
  overflow: hidden;
  clip-path: inset(50%);
}

.personal-style-card {
  display: grid;
  gap: 5px;
  min-width: 0;
  padding: 13px;
  border: 1px solid var(--personal-line);
  border-radius: var(--radius);
  background: var(--personal-surface);
  transition: border-color .18s ease, background-color .18s ease;
}

.personal-style-title { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.personal-style-title > strong { font-size: 16px; font-weight: 680; }
.personal-style-description { color: var(--personal-muted); font-size: 13px; }
.personal-style-card > .bn-preview { margin-block-start: 8px; }

.personal-style-indicator {
  display: grid;
  flex: none;
  place-items: center;
  width: 19px;
  height: 19px;
  border: 1.5px solid var(--personal-muted);
  border-radius: 50%;
}

.personal-style-indicator::after {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--personal-accent);
  content: "";
  visibility: hidden;
}

.personal-radio:checked + .personal-style-card {
  border-color: var(--personal-accent);
  background: var(--personal-selected);
}

.personal-radio:checked + .personal-style-card .personal-style-indicator { border-color: var(--personal-accent); }
.personal-radio:checked + .personal-style-card .personal-style-indicator::after { visibility: visible; }
.personal-radio:focus-visible + .personal-style-card { outline: 3px solid var(--personal-accent); outline-offset: 3px; }

.personal-row + .personal-badge-appearance { margin-block-start: 12px; }

.personal-badge-switch { position: relative; cursor: pointer; }
.personal-badge-track {
  display: flex;
  align-items: center;
  flex: none;
  inline-size: 40px;
  block-size: 24px;
  padding: 3px;
  border: 1px solid var(--personal-muted);
  border-radius: 99px;
  background: var(--personal-hover);
}
.personal-badge-track::after {
  content: "";
  inline-size: 16px;
  block-size: 16px;
  border-radius: 50%;
  background: var(--personal-muted);
}
.personal-badge-switch input:checked + .personal-badge-track {
  border-color: var(--personal-accent);
  background: var(--personal-accent);
}
.personal-badge-switch input:checked + .personal-badge-track::after {
  transform: translateX(16px);
  background: var(--personal-surface);
}
.personal-badge-switch input:focus-visible + .personal-badge-track {
  outline: 3px solid var(--personal-accent);
  outline-offset: 3px;
}
.personal-badge-styles {
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 8px;
  min-inline-size: 0;
  margin: 0;
  padding: 0 12px 12px;
  border: 0;
}
.personal-badge-styles legend {
  padding: 5px 0 8px;
  font-size: 13px;
  color: var(--personal-muted);
}
.personal-badge-follow { grid-column: 1 / -1; }
.personal-badge-option .personal-style-card { gap: 8px; padding: 10px; }
.personal-badge-option .personal-style-title { gap: 4px; }
.personal-badge-option .personal-style-title > strong { font-size: 14px; }
.personal-badge-option .personal-style-indicator { width: 16px; height: 16px; }
.personal-badge-option .personal-style-indicator::after { width: 7px; height: 7px; }
.personal-badge-preview { display: flex; align-items: center; gap: 4px; }
.personal-badge-preview img { object-fit: contain; }

@media (min-width: 880px) {
  .personal-badge-styles { grid-template-columns: repeat(4, minmax(0,1fr)); }
}

.personal-session { margin-block-start: 24px; }
.personal-signout {
  width: 100%;
  min-height: 50px;
  padding: 10px 13px;
  border: 1px solid var(--personal-line);
  border-radius: var(--radius);
  background: var(--personal-surface);
  color: var(--personal-danger);
  font-weight: 650;
}
.personal-signout-error { margin-block-start: 8px; color: var(--personal-danger); font-size: 13px; }

@media (hover: hover) {
  .personal-back:hover, .personal-row:hover { background: var(--personal-hover); }
  .personal-style:hover .personal-radio:not(:checked) + .personal-style-card { background: var(--personal-hover); }
  .personal-signout:hover:enabled { background: var(--personal-danger-hover); }
}

@media (prefers-color-scheme: dark) and (max-width: 760px) {
  .personal-page {
    --personal-surface: #20252e;
    --personal-text: #eef1f7;
    --personal-muted: #b1b9c8;
    --personal-line: #37404e;
    --personal-hover: #2a313d;
    --personal-selected: #232d43;
    --personal-accent: #9ab3ff;
    --personal-danger: #ffabb7;
    --personal-danger-hover: #382a33;
  }
}

.personal-profile {
  --profile-start: #eaf1ff;
  --profile-end: #f7faff;
  --profile-edge: #d3dff4;
  --profile-rule: #d9e3f3;
  --profile-ink: #263b66;
  --profile-muted: #536686;
  --profile-button: #fff;
  margin: 0 0 23px;
  padding: 20px 20px 11px;
  color: var(--profile-ink);
  background: linear-gradient(115deg,var(--profile-start),var(--profile-end));
  border: 1px solid var(--profile-edge);
  border-radius: 18px;
}
.profile-account, .profile-campus { display: flex; align-items: center; gap: 12px; }
.profile-account {
  width: 100%; min-height: 48px; padding: 0 0 16px; border: 0; border-radius: 5px;
  color: inherit; font: inherit; background: transparent; text-align: start;
}
.profile-account:only-child { padding-bottom: 8px; }
.profile-account > .icon { color: var(--profile-muted); }
.profile-monogram {
  display: grid; flex: none; place-items: center; width: 47px; height: 47px;
  border-radius: 15px; background: #3655ad; color: white;
  font-size: 22px; font-weight: 670; line-height: 1;
}
.profile-account-name, .profile-campus-name { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.profile-account-name strong { display: block; margin: 0; font-size: 21px; line-height: 1.22; letter-spacing: -.02em; }
.profile-account-name small { display: block; margin: 4px 0 0; color: var(--profile-muted); font-size: 12px; line-height: 1.4; }
.profile-account-name .profile-role { display: flex; align-items: center; gap: 5px; }
.profile-campus { min-height: 54px; gap: 9px; border-top: 1px solid var(--profile-rule); padding-top: 7px; }
.profile-campus-icon { flex: none; display: flex; color: var(--profile-muted); }
.profile-campus-name strong { font-size: 14px; font-weight: 650; }
.profile-campus-name small { display: block; margin-top: 1px; font-size: 12px; color: var(--profile-muted); }
.profile-switch {
  display: inline-flex; flex: none; align-items: center; justify-content: center; gap: 5px;
  min-height: 42px; padding: 5px 10px; border-radius: 10px; border: 0;
  font: inherit; font-size: 12px; font-weight: 600; color: var(--profile-ink); background: transparent;
}
.profile-switch:is(:hover,:focus-visible) { background: var(--profile-button); }
.personal-page[data-personal-page="me"] .personal-row { min-height: 50px; }
.personal-page[data-personal-page="me"] .personal-row:only-child { border-radius: var(--radius); }
@media (max-width: 360px) {
  .personal-profile { padding-inline: 14px; }
  .profile-switch { padding-inline: 4px; }
}
@media (prefers-color-scheme:dark) and (max-width:760px) {
  .personal-profile {
    --profile-start: #26374e; --profile-end: #222b38; --profile-edge: #3a4c63;
    --profile-rule: #3a495d; --profile-ink: #e4edff; --profile-muted: #b6c5da; --profile-button: #344760;
  }
}
