﻿:root {
  /* 52Hz mobile visual tokens: warm coastal paper + deep teal + coral accent. */
  --hz-teal-700: #347E79;
  --hz-teal-600: #3E9595;
  --hz-teal-500: #4FA9A2;
  --hz-teal-400: #65B7B0;
  --hz-teal-100: #E8F5F2;
  --hz-coral-600: #B86F4D;
  --hz-coral-500: #D58B66;
  --hz-coral-100: #FBE4D7;
  --hz-cream-0: #FFFDF6;
  --hz-cream-1: #FBF7EF;
  --hz-cream-2: #FFF3EA;
  --hz-ink: #263631;
  --hz-ink-strong: #202832;
  --hz-muted: #6F7D76;
  --hz-muted-soft: rgba(38, 54, 49, 0.56);
  --hz-line: rgba(52, 126, 121, 0.14);
  --hz-line-strong: rgba(52, 126, 121, 0.22);
  --hz-surface: rgba(255, 255, 255, 0.9);
  --hz-surface-soft: rgba(255, 255, 255, 0.72);
  --hz-radius-card: 30px;
  --hz-radius-card-sm: 24px;
  --hz-radius-control: 22px;
  --hz-radius-pill: 999px;
  --hz-shadow-card:
    0 18px 40px rgba(57, 83, 76, 0.1),
    0 8px 18px rgba(213, 139, 102, 0.05),
    inset 0 1px 0 rgba(255, 255, 255, 0.94);
  --hz-shadow-card-soft:
    0 12px 26px rgba(57, 83, 76, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
  --hz-shadow-button:
    0 16px 30px rgba(52, 126, 121, 0.2),
    0 7px 16px rgba(213, 139, 102, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.5);
  --hz-ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --hz-motion-fast: 160ms;
  --hz-motion-normal: 380ms;
  --hz-page-bg:
    radial-gradient(circle at 12% 22%, rgba(101, 183, 176, 0.22), transparent 28%),
    radial-gradient(circle at 88% 42%, rgba(213, 139, 102, 0.18), transparent 30%),
    radial-gradient(circle at 50% 78%, rgba(255, 243, 234, 0.78), transparent 38%),
    linear-gradient(180deg, var(--hz-cream-0) 0%, #F8FFF9 44%, var(--hz-cream-2) 100%);
  --hz-card-bg:
    radial-gradient(circle at 92% 12%, rgba(213, 139, 102, 0.1), transparent 24%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.92), rgba(241, 255, 251, 0.72));
  --hz-chip-bg: rgba(251, 228, 215, 0.78);
  --hz-button-bg:
    radial-gradient(ellipse at 30% 10%, rgba(255, 255, 255, 0.42), transparent 38%),
    linear-gradient(135deg, var(--hz-teal-500) 0%, var(--hz-teal-500) 62%, var(--hz-teal-400) 100%);

  /* Legacy aliases kept so older pages inherit the same system gradually. */
  --whale-blue: var(--hz-teal-500);
  --sea-mint: var(--hz-teal-100);
  --coral: var(--hz-coral-500);
  --violet: #8fa6b3;
  --cream: var(--hz-cream-2);
  --ice: var(--hz-cream-1);
  --ink: var(--hz-ink);
  --muted: var(--hz-muted);
  --line: var(--hz-line);
  --card: var(--hz-surface);
  --shadow: var(--hz-shadow-card-soft);
  --sage: var(--hz-teal-500);
  --dinner-primary: #D99A4E;
  --dinner-secondary: #F7D8A9;
  --dinner-bg: #FFF4E4;
  --dinner-soft: #FBE9D2;
  --dinner-text: var(--hz-ink);
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--ice);
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "PingFang SC",
    "Microsoft YaHei", sans-serif;
  letter-spacing: 0;
  background:
    radial-gradient(circle at 0% 4%, rgba(199, 216, 192, 0.78), transparent 30%),
    radial-gradient(circle at 92% 14%, rgba(255, 244, 207, 0.7), transparent 28%),
    radial-gradient(circle at 78% 86%, rgba(255, 154, 61, 0.14), transparent 28%),
    linear-gradient(145deg, #fffdf7 0%, #fbfaf4 48%, #f6f8f4 100%);
  overflow-x: hidden;
}

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

input[type="hidden"] {
  display: none;
}

button {
  cursor: pointer;
}

.aurora {
  position: fixed;
  z-index: 0;
  width: 260px;
  height: 260px;
  border-radius: 50%;
  filter: blur(36px);
  opacity: 0.36;
  pointer-events: none;
}

.aurora-one {
  top: -70px;
  left: calc(50% - 330px);
  background: var(--sea-mint);
}

.aurora-two {
  right: calc(50% - 340px);
  bottom: 40px;
  background: var(--coral);
}

.phone-shell {
  position: relative;
  z-index: 1;
  width: min(100%, 430px);
  min-height: 100vh;
  margin: 0 auto;
  background: rgba(250, 249, 246, 0.72);
  box-shadow: 0 0 0 1px rgba(32, 36, 45, 0.06);
}

.view {
  display: none;
  padding: 24px 32px 76px;
}

.view.active {
  display: block;
}

.login-view {
  position: relative;
  padding-top: 34px;
  overflow: hidden;
}

.login-view::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 560px;
  z-index: 0;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(255, 253, 248, 0) 0%, rgba(255, 253, 248, 0.04) 58%, rgba(250, 249, 246, 0.9) 100%),
    url("./assets/home-campus-bg.svg") center -96px / 112% auto no-repeat;
  opacity: 1;
}

.login-view::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 560px;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 50% 28%, rgba(255, 255, 255, 0.68), transparent 27%),
    linear-gradient(180deg, rgba(255, 253, 248, 0.04) 0%, rgba(255, 253, 248, 0.18) 52%, rgba(250, 249, 246, 1) 100%);
}

.login-view > * {
  position: relative;
  z-index: 1;
}

.top-login-btn {
  position: absolute;
  top: 18px;
  right: 18px;
  z-index: 3;
  min-height: 34px;
  padding: 0 13px;
  border: 0;
  border-radius: 999px;
  color: rgba(82, 103, 88, 0.92);
  font-size: 13px;
  font-weight: 800;
  background: rgba(255, 255, 255, 0.38);
  box-shadow: none;
  backdrop-filter: blur(12px);
}

#chatView {
  min-height: 100vh;
  padding-bottom: 18px;
}

#chatView.active {
  display: flex;
  flex-direction: column;
}

.brand-block {
  padding: 22px 4px 28px;
  text-align: center;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 88px;
  height: 88px;
  margin: 0 auto 14px;
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.34);
  box-shadow:
    0 18px 45px rgba(87, 183, 183, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.5);
  overflow: hidden;
}

.brand-mark img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.eyebrow {
  margin: 0 0 7px;
  color: var(--whale-blue);
  font-size: 12px;
  font-weight: 700;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 10px;
  font-size: clamp(38px, 11vw, 52px);
  line-height: 1.03;
}

.art-brand {
  margin: 10px auto 8px;
  font-family: "STXingkai", "华文行楷", "FZYaoti", "方正姚体", "KaiTi", "PingFang SC",
    "Microsoft YaHei", sans-serif;
  font-size: clamp(54px, 14.8vw, 76px);
  font-weight: 700;
  line-height: 0.98;
  letter-spacing: 0.08em;
  background: linear-gradient(112deg, #3E9595 0%, #57B7B7 42%, #8FD0D0 66%, #FF9A3D 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 0 20px 42px rgba(87, 183, 183, 0.16);
  filter: drop-shadow(0 1px 0 rgba(255, 255, 255, 0.9));
  transform: translateX(0.04em) skew(-2deg);
}

.brand-roman {
  margin-bottom: 22px;
  color: #66896f;
  font-size: 12px;
  font-weight: 950;
  letter-spacing: 0.24em;
  opacity: 0.86;
}

.hero-cta {
  width: min(82%, 320px);
  margin: 28px auto 0;
  background: linear-gradient(135deg, #57B7B7 0%, #57B7B7 58%, #3E9595 100%);
  box-shadow:
    0 18px 38px rgba(95, 127, 101, 0.24),
    inset 0 1px 0 rgba(255, 255, 255, 0.26);
}

.hero-note {
  margin: 18px 0 0;
  color: rgba(101, 111, 119, 0.78);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-align: center;
}

h2 {
  margin-bottom: 0;
  font-size: 24px;
  line-height: 1.16;
}

.match-heading {
  font-size: 28px;
  font-weight: 950;
  color: var(--ink);
  letter-spacing: 0;
}

.heading-with-icon {
  display: flex;
  align-items: center;
  gap: 13px;
}

.section-icon {
  display: grid;
  place-items: center;
  width: 50px;
  height: 50px;
  flex: 0 0 auto;
  border: 1px solid rgba(32, 36, 45, 0.08);
  border-radius: 17px;
  background:
    radial-gradient(circle at 70% 18%, rgba(255, 154, 61, 0.14), transparent 32%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.95), rgba(199, 216, 192, 0.28));
  box-shadow: 0 14px 30px rgba(32, 36, 45, 0.08);
}

.section-icon svg {
  width: 28px;
  height: 28px;
  fill: none;
  stroke: var(--whale-blue);
  stroke-width: 3.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.result-icon {
  background:
    radial-gradient(circle at 72% 18%, rgba(143, 166, 179, 0.18), transparent 32%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.95), rgba(255, 154, 61, 0.12));
}

.community-title-icon {
  background:
    radial-gradient(circle at 70% 20%, rgba(199, 216, 192, 0.34), transparent 34%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.96), rgba(143, 166, 179, 0.12));
}

.profile-title-icon {
  background:
    radial-gradient(circle at 70% 18%, rgba(255, 154, 61, 0.14), transparent 32%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.96), rgba(199, 216, 192, 0.26));
}

.page-subtitle {
  margin: 7px 0 0;
  color: var(--whale-blue);
  font-size: 13px;
  font-weight: 850;
  line-height: 1.4;
}

.compact-subtitle {
  margin-top: 3px;
}

h3 {
  margin-bottom: 10px;
  font-size: 20px;
  line-height: 1.25;
}

.brand-copy {
  max-width: none;
  margin: 0 auto;
  color: #5d6862;
  font-size: clamp(12px, 3.3vw, 14px);
  line-height: 1.7;
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.unlock-gender-card {
  padding: 16px 20px;
  margin-bottom: 14px;
  text-align: center;
}

.unlock-gender-label {
  font-size: 13px;
  color: var(--muted);
  margin: 0 0 10px;
  font-weight: 600;
}

.unlock-gender-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.unlock-gender-btn {
  border: 1px solid rgba(87, 183, 183, 0.22);
  border-radius: 14px;
  padding: 11px 6px;
  color: #57B7B7;
  font-size: 14px;
  font-weight: 800;
  background: linear-gradient(135deg, rgba(87, 183, 183, 0.12), rgba(255, 154, 61, 0.08));
  transition: all 0.15s;
}

.unlock-gender-btn.selected {
  color: #fff;
  border-color: transparent;
  background: linear-gradient(135deg, #57B7B7, #FF9A3D);
  box-shadow: 0 6px 16px rgba(87, 183, 183, 0.3);
}

.portrait-avatar.unlock-mystery-avatar {
  position: relative;
  width: 104px;
  height: 104px;
  border: 1px solid rgba(255, 255, 255, 0.84);
  border-radius: 30px;
  background:
    radial-gradient(circle at 34% 18%, rgba(255, 255, 255, 0.9), transparent 36%),
    linear-gradient(145deg, rgba(232, 252, 247, 0.9), rgba(255, 232, 218, 0.74));
  box-shadow:
    0 18px 36px rgba(62, 149, 149, 0.16),
    0 8px 18px rgba(213, 139, 102, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.95);
  overflow: visible;
}

.portrait-avatar.unlock-mystery-avatar::before {
  content: "";
  position: absolute;
  inset: -12px;
  z-index: -1;
  border-radius: 36px;
  background:
    radial-gradient(circle, rgba(87, 183, 183, 0.24), transparent 58%);
  opacity: 0.8;
  animation: unlock-soft-pulse 3.2s ease-in-out infinite;
}

.portrait-avatar.unlock-mystery-avatar::after {
  content: "";
  position: absolute;
  right: -7px;
  bottom: -7px;
  width: 34px;
  height: 34px;
  border: 2px solid rgba(255, 255, 255, 0.92);
  border-radius: 50%;
  background:
    linear-gradient(145deg, #57B7B7, #3E9595);
  box-shadow: 0 10px 20px rgba(43, 135, 127, 0.2);
}

.unlock-preview {
  align-items: center;
  min-height: 168px;
  margin-bottom: 22px;
  padding: 22px;
  border-radius: 32px;
  background:
    radial-gradient(circle at 86% 16%, rgba(255, 154, 61, 0.14), transparent 25%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.92), rgba(241, 255, 251, 0.72));
  box-shadow:
    0 22px 44px rgba(68, 120, 113, 0.12),
    0 10px 22px rgba(213, 139, 102, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.96);
}

.unlock-teaser {
  margin-bottom: 28px;
  padding: 22px;
  border-radius: 30px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.9), rgba(255, 252, 246, 0.78));
}

#unlockView {
  position: relative;
  min-height: 100vh;
  padding: 0 24px max(40px, env(safe-area-inset-bottom));
  overflow: hidden;
  background:
    radial-gradient(circle at 12% 22%, rgba(143, 215, 206, 0.26), transparent 27%),
    radial-gradient(circle at 88% 40%, rgba(255, 177, 128, 0.24), transparent 31%),
    radial-gradient(circle at 50% 78%, rgba(255, 247, 226, 0.78), transparent 38%),
    linear-gradient(180deg, #fffdf6 0%, #f8fff9 44%, #fff2ea 100%);
}

#unlockView::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.52), rgba(255, 255, 255, 0.08) 46%, rgba(255, 246, 235, 0.38)),
    url("./assets/home-campus-bg.svg") center -76px / 126% auto no-repeat;
  opacity: 0.2;
}

#unlockView > * {
  position: relative;
  z-index: 1;
}

#unlockView .unlock-top-bar {
  align-items: center;
  margin: 0 -24px 22px;
  padding: 32px 24px 24px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.82), rgba(232, 252, 247, 0.44));
  box-shadow: 0 16px 34px rgba(68, 120, 113, 0.08);
}

.unlock-kicker {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  margin: 0 0 10px;
  padding: 0 12px;
  border-radius: 999px;
  color: #b86f4d;
  font-size: 11px;
  font-weight: 950;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  background: rgba(255, 228, 211, 0.76);
}

#unlockView .unlock-top-bar h2 {
  color: #202832;
  font-size: clamp(28px, 8vw, 36px);
  font-weight: 950;
  line-height: 1.08;
}

#unlockView .page-subtitle {
  max-width: 320px;
  margin-top: 10px;
  color: #4fb8b5;
  font-size: 14px;
  font-weight: 900;
}

.unlock-status-pill,
.unlock-teaser-eyebrow {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  margin: 0 0 12px;
  padding: 0 11px;
  border-radius: 999px;
  color: #3E9595;
  font-size: 12px;
  font-weight: 950;
  background:
    linear-gradient(145deg, rgba(232, 252, 247, 0.92), rgba(255, 246, 232, 0.58));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.84);
}

.unlock-preview h3,
.unlock-teaser h3 {
  margin: 0;
  color: #202832;
  font-size: 25px;
  font-weight: 950;
  line-height: 1.22;
}

.unlock-preview #unlockPortraitCopy {
  margin: 12px 0 0;
  color: rgba(32, 40, 50, 0.58);
  font-size: 15px;
  font-weight: 800;
  line-height: 1.62;
}

.unlock-teaser-eyebrow {
  color: #b86f4d;
  background: rgba(255, 228, 211, 0.78);
}

.unlock-preview-list {
  display: grid;
  gap: 14px;
  margin-top: 18px;
}

.unlock-preview-item {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  align-items: start;
  gap: 12px;
}

.unlock-preview-item > span {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 32% 18%, rgba(255, 255, 255, 0.62), transparent 40%),
    linear-gradient(145deg, rgba(232, 252, 247, 0.95), rgba(255, 239, 229, 0.72));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.86);
}

.unlock-preview-item > span::after {
  content: "";
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #57B7B7;
  box-shadow: 0 0 0 5px rgba(87, 183, 183, 0.12);
}

.unlock-preview-item p {
  margin: 0;
}

.unlock-preview-item strong {
  display: block;
  margin-bottom: 4px;
  color: #202832;
  font-size: 15px;
  font-weight: 950;
}

.unlock-preview-item small {
  display: block;
  color: rgba(32, 40, 50, 0.58);
  font-size: 13px;
  font-weight: 750;
  line-height: 1.52;
}

.unlock-actions {
  display: grid;
  gap: 0;
  margin-top: 0;
}

.unlock-full-btn {
  position: relative;
  min-height: 58px;
  border-radius: 24px;
  font-size: 18px;
  transition: transform 0.14s ease, box-shadow 0.18s ease, opacity 0.18s ease;
}

.unlock-full-btn:active {
  transform: translateY(1px) scale(0.985);
  box-shadow:
    0 10px 20px rgba(43, 135, 127, 0.16),
    inset 0 1px 0 rgba(255, 255, 255, 0.58);
}

.unlock-full-btn.is-loading {
  opacity: 0.88;
  cursor: wait;
}

.unlock-btn-spinner {
  display: none;
  width: 17px;
  height: 17px;
  margin-left: 10px;
  border: 2px solid rgba(255, 255, 255, 0.5);
  border-top-color: #fff;
  border-radius: 50%;
  animation: ai-spin 0.8s linear infinite;
  vertical-align: -3px;
}

.unlock-full-btn.is-loading .unlock-btn-spinner {
  display: inline-block;
}

.unlock-note {
  margin: 20px auto 0;
  color: rgba(32, 40, 50, 0.48);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.6;
  text-align: center;
}

#unlockView.active .unlock-reveal {
  animation: quiz-rise-in 0.42s cubic-bezier(0.22, 1, 0.36, 1) both;
}

#unlockView.active .unlock-preview {
  animation-delay: 0.08s;
}

#unlockView.active .unlock-teaser {
  animation-delay: 0.16s;
}

#unlockView.active .unlock-actions {
  animation-delay: 0.24s;
}

#unlockView.active .unlock-note {
  animation-delay: 0.3s;
}

@keyframes unlock-soft-pulse {
  0%,
  100% {
    opacity: 0.55;
    transform: scale(0.98);
  }
  50% {
    opacity: 0.86;
    transform: scale(1.04);
  }
}

@media (max-width: 370px) {
  #unlockView {
    padding-left: 18px;
    padding-right: 18px;
  }

  #unlockView .unlock-top-bar {
    margin-left: -18px;
    margin-right: -18px;
    padding-left: 18px;
    padding-right: 18px;
  }

  .unlock-preview {
    grid-template-columns: 86px minmax(0, 1fr);
    gap: 14px;
    padding: 18px;
  }

  .portrait-avatar.unlock-mystery-avatar {
    width: 86px;
    height: 86px;
    border-radius: 26px;
  }

  .unlock-preview h3,
  .unlock-teaser h3 {
    font-size: 21px;
  }
}

.glass-card,
.login-card,
.form-card,
.quiz-card {
  border: 1px solid rgba(32, 36, 45, 0.08);
  border-radius: 22px;
  background: var(--card);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.login-card,
.form-card,
.quiz-card,
.analysis-card,
.settings-card,
.match-result,
.status-card {
  padding: 18px;
}

label {
  display: block;
  margin-bottom: 14px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 700;
}

input,
select,
textarea {
  width: 100%;
  margin-top: 8px;
  border: 1px solid transparent;
  border-radius: 16px;
  outline: none;
  background: rgba(246, 246, 242, 0.95);
  color: var(--ink);
  transition: border 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

input,
select {
  height: 48px;
  padding: 0 14px;
}

textarea {
  min-height: 96px;
  resize: vertical;
  padding: 14px;
  line-height: 1.55;
}

.ios-select {
  position: relative;
  margin-top: 8px;
}

.ios-select-trigger {
  position: relative;
  width: 100%;
  min-height: 52px;
  border: 1px solid transparent;
  border-radius: 16px;
  padding: 0 44px 0 14px;
  color: var(--ink);
  font-weight: 800;
  text-align: left;
  background: rgba(246, 246, 242, 0.95);
  transition: border 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.ios-select-trigger::after {
  content: "";
  position: absolute;
  right: 18px;
  top: 50%;
  width: 8px;
  height: 8px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: translateY(-65%) rotate(45deg);
  opacity: 0.78;
  transition: transform 0.2s ease;
}

.ios-select.open .ios-select-trigger {
  border-color: rgba(87, 183, 183, 0.42);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 0 0 4px rgba(87, 183, 183, 0.1);
}

/* ── 表单字段校验微提示 ─────────────────────────── */
.field-error-hint {
  display: block;
  overflow: hidden;
  max-height: 0;
  margin-top: 0;
  font-size: 11.5px;
  font-weight: 700;
  color: var(--coral);
  opacity: 0;
  transform: translateY(-3px);
  transition:
    max-height 220ms ease,
    opacity 200ms ease,
    transform 200ms ease,
    margin-top 200ms ease;
  pointer-events: none;
}

.field-error-hint.visible {
  max-height: 2em;
  margin-top: 5px;
  opacity: 1;
  transform: translateY(0);
}

/* 触发器红框：输入框 & select 按钮 */
label.field-error > input[type="text"],
label.field-error .ios-select-trigger {
  border-color: rgba(255, 154, 61, 0.7) !important;
  box-shadow: 0 0 0 3px rgba(255, 154, 61, 0.14);
}

/* ── 用户协议 & 隐私政策勾选行 ──────────────────── */
.agree-row {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin: 14px 0 0;
  cursor: pointer;
}
.agree-row input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  display: inline-grid;
  place-items: center;
  flex: 0 0 19px;
  width: 19px;
  min-width: 19px;
  max-width: 19px;
  height: 19px;
  min-height: 19px;
  max-height: 19px;
  aspect-ratio: 1 / 1;
  margin: 1px 0 0;
  padding: 0;
  box-sizing: border-box;
  border: 1px solid rgba(79, 169, 162, 0.34);
  border-radius: 5px;
  background: rgba(255, 255, 255, 0.78);
  background-clip: border-box;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.78);
  cursor: pointer;
  transition: background 0.14s ease, border-color 0.14s ease, box-shadow 0.14s ease, transform 0.14s ease;
}
.agree-row input[type="checkbox"]:checked {
  border-color: var(--hz-teal-500, #4FA9A2);
  background: var(--hz-teal-500, #4FA9A2);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.24),
    0 6px 14px rgba(79, 169, 162, 0.18);
}
.agree-row input[type="checkbox"]:checked::after {
  content: "";
  width: 6px;
  height: 10px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: translateY(-1px) rotate(45deg);
}
.agree-row input[type="checkbox"]:active {
  transform: scale(0.96);
}
.agree-row > span {
  font-size: 12.5px;
  color: var(--muted);
  line-height: 1.55;
  font-weight: 400;
}
.agree-link {
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--whale-blue);
  text-decoration: none;
  font-weight: 600;
  font: inherit;
  cursor: pointer;
}
.agree-link:active {
  opacity: 0.65;
}

.policy-modal {
  width: min(100%, 360px);
  max-height: calc(100vh - 56px);
  overflow-y: auto;
  padding: 24px;
}

.policy-body {
  display: grid;
  gap: 12px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.policy-body h3 {
  margin: 8px 0 0;
  color: var(--ink);
  font-size: 15px;
}

.policy-body p {
  margin: 0;
}

.ios-select.locked {
  pointer-events: none;
}

.ios-select.locked .ios-select-trigger {
  color: var(--muted);
  background: rgba(30, 36, 48, 0.04);
}

.ios-select.locked .ios-select-trigger::after {
  display: none;
}

.ios-select.open .ios-select-trigger::after {
  transform: translateY(-35%) rotate(225deg);
}

.ios-select-menu {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(100% + 8px);
  z-index: 30;
  display: none;
  max-height: 270px;
  padding: 8px;
  border: 1px solid rgba(255, 255, 255, 0.76);
  border-radius: 18px;
  overflow-y: auto;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 18px 45px rgba(30, 36, 48, 0.12);
  backdrop-filter: blur(18px);
}

.ios-select.open .ios-select-menu {
  display: grid;
  gap: 4px;
}

.ios-select-menu button {
  width: 100%;
  min-height: 44px;
  border: 0;
  border-radius: 16px;
  padding: 0 12px;
  color: var(--ink);
  font-weight: 750;
  text-align: left;
  background: transparent;
}

.ios-select-menu button:hover,
.ios-select-menu button:focus,
.ios-select-menu button.selected {
  color: #3E9595;
  background: linear-gradient(135deg, rgba(87, 183, 183, 0.22), rgba(255, 154, 61, 0.1));
}

.ios-select-menu::-webkit-scrollbar {
  width: 8px;
}

.ios-select-menu::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: rgba(87, 183, 183, 0.18);
}

input:focus,
select:focus,
textarea:focus {
  border-color: rgba(87, 183, 183, 0.5);
  background: white;
  box-shadow: 0 0 0 4px rgba(87, 183, 183, 0.1);
}

.inline-field {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: end;
}

.inline-field input {
  margin-top: 8px;
}

.hint {
  margin: 2px 0 16px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
}

.primary-btn,
.secondary-btn,
.ghost-btn,
.text-btn,
.icon-btn {
  border: 0;
  border-radius: 999px;
}

.primary-btn {
  width: 100%;
  min-height: 50px;
  padding: 0 20px;
  color: white;
  font-weight: 800;
  background: linear-gradient(135deg, #3E9595, #57B7B7);
  box-shadow: 0 12px 28px rgba(32, 36, 45, 0.18);
}

.secondary-btn {
  min-height: 48px;
  padding: 0 18px;
  color: var(--ink);
  font-weight: 800;
  background: rgba(255, 255, 255, 0.74);
  border: 1px solid var(--line);
}

.ghost-btn {
  height: 48px;
  margin-top: 8px;
  padding: 0 18px;
  color: var(--whale-blue);
  font-weight: 800;
  background: rgba(87, 183, 183, 0.1);
}

.ghost-btn:disabled,
.ghost-btn.cooling {
  cursor: not-allowed;
  color: rgba(32, 36, 45, 0.45);
  background: rgba(87, 183, 183, 0.14);
}

.login-gender-field {
  margin: 0 0 14px;
}

.login-gender-label {
  display: block;
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 6px;
}

.login-gender-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 6px;
}

.login-gender-btn {
  border: 1px solid rgba(87, 183, 183, 0.22);
  border-radius: 14px;
  padding: 11px 6px;
  color: #57B7B7;
  font-size: 14px;
  font-weight: 800;
  background: linear-gradient(135deg, rgba(87, 183, 183, 0.12), rgba(255, 154, 61, 0.08));
  transition: all 0.15s;
}

.login-gender-btn.selected {
  color: #fff;
  border-color: transparent;
  background: linear-gradient(135deg, #57B7B7, #FF9A3D);
  box-shadow: 0 6px 16px rgba(87, 183, 183, 0.3);
}

.login-gender-tip {
  display: block;
  font-size: 11px;
  color: var(--muted);
  letter-spacing: 0.02em;
}

@keyframes ai-spin {
  to { transform: rotate(360deg); }
}

.text-btn {
  padding: 8px 0;
  color: var(--whale-blue);
  font-weight: 800;
  background: transparent;
}

.message-board {
  margin-top: 22px;
}

.section-title,
.top-bar,
.chat-header,
.match-person {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.section-title {
  margin-bottom: 12px;
  padding: 0 2px;
  font-weight: 800;
}

.bubble-list {
  display: grid;
  gap: 10px;
}

.message-card {
  position: relative;
  display: grid;
  grid-template-columns: 42px 1fr;
  gap: 10px;
  align-items: start;
  width: min(94%, 340px);
  padding: 12px;
  border-radius: 18px;
  border: 1px solid rgba(95, 127, 101, 0.08);
  background: rgba(255, 255, 255, 0.7);
  box-shadow: 0 16px 34px rgba(32, 36, 45, 0.08);
  backdrop-filter: blur(10px);
}

.message-card.left {
  justify-self: start;
}

.message-card.right {
  justify-self: end;
  background: rgba(255, 255, 255, 0.7);
}

.user-avatar {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 16px;
  color: white;
  font-weight: 900;
  background: linear-gradient(135deg, #FF9A3D, #8fa6b3);
  box-shadow: 0 10px 22px rgba(143, 166, 179, 0.16);
}

.message-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 5px;
}

.message-meta strong {
  font-size: 14px;
}

.message-card.right .message-meta strong {
  color: #3E9595;
}

.message-meta span {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 2px 8px;
  border-radius: 999px;
  color: #66896f;
  font-size: 11px;
  font-weight: 750;
  background: rgba(87, 183, 183, 0.1);
}

.message-card p {
  margin: 0;
  color: var(--ink);
  font-size: 13px;
  line-height: 1.55;
}

.declaration-board {
  display: grid;
  gap: 14px;
}

.declaration-head {
  display: block;
}

.declaration-head h3 {
  margin: 0 0 5px;
  font-size: 20px;
  line-height: 1.28;
  white-space: nowrap;
  color: var(--ink);
  font-weight: 900;
}

.declaration-head p {
  margin: 0;
  color: var(--sage);
  font-size: 13px;
  font-weight: 850;
  line-height: 1.45;
}

#declarationInput {
  min-height: 86px;
  margin-top: 0;
}

.declaration-submit {
  width: 100%;
  min-height: 48px;
  margin-top: 0;
}

.declaration-list {
  display: grid;
  gap: 10px;
}

.declaration-item {
  padding: 12px 14px;
  border-radius: 18px;
  background: rgba(246, 246, 242, 0.88);
  border: 1px solid rgba(87, 183, 183, 0.12);
}

.declaration-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
}

.declaration-item strong {
  display: block;
  color: var(--sage);
  font-size: 13px;
}

.declaration-item p {
  margin: 0;
  color: var(--ink);
  font-size: 14px;
  line-height: 1.55;
}

.declaration-like {
  flex: 0 0 auto;
  min-height: 22px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 999px;
  padding: 2px 8px;
  color: #3E9595;
  font-size: 11px;
  font-weight: 900;
  background:
    linear-gradient(145deg, rgba(222, 249, 242, 0.9), rgba(255, 244, 229, 0.62));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.94);
}

.declaration-like.liked {
  color: #d56f63;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.95), rgba(255, 232, 221, 0.74));
}

.declaration-more {
  justify-self: center;
  min-width: min(74%, 260px);
  min-height: 44px;
  padding: 0 24px;
  color: var(--sage);
  font-size: 14px;
  font-weight: 900;
  text-align: center;
}

.declaration-more:disabled {
  opacity: 0.55;
  cursor: default;
}

.top-bar {
  position: sticky;
  top: 0;
  z-index: 5;
  margin: -24px -32px 18px;
  padding: 18px 32px;
  background: rgba(250, 249, 246, 0.84);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid rgba(32, 36, 45, 0.06);
}

.match-detail-header {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) 42px;
  align-items: center;
}

.match-detail-header .match-heading {
  text-align: center;
}

.header-spacer {
  width: 42px;
  height: 42px;
}

.pill {
  flex: 0 0 auto;
  max-width: 144px;
  padding: 8px 12px;
  color: var(--whale-blue);
  font-size: 12px;
  font-weight: 800;
  border-radius: 999px;
  background: rgba(87, 183, 183, 0.1);
  text-align: center;
}

.stack {
  display: grid;
  gap: 14px;
}

.two-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.field-name {
  margin-bottom: 12px;
  font-size: 13px;
  font-weight: 800;
}

.chip-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.chip {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 10px 14px;
  color: var(--muted);
  font-weight: 700;
  background: rgba(255, 255, 255, 0.75);
}

.chip.selected {
  color: white;
  border-color: transparent;
  background: linear-gradient(135deg, var(--violet), #57B7B7);
}

.progress-track {
  height: 8px;
  margin-bottom: 16px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(23, 32, 51, 0.08);
}

.progress-fill {
  width: 3.33%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #57B7B7, var(--sea-mint), #f6c8a8);
  transition: width 0.24s ease;
}

/* Mobile quiz: warm editorial frequency test */
#quizView {
  position: relative;
  min-height: 100vh;
  padding: 16px 24px max(34px, env(safe-area-inset-bottom));
  overflow: hidden;
  background:
    radial-gradient(circle at 14% 22%, rgba(143, 215, 206, 0.28), transparent 27%),
    radial-gradient(circle at 86% 36%, rgba(255, 177, 128, 0.24), transparent 30%),
    radial-gradient(circle at 50% 78%, rgba(255, 247, 226, 0.82), transparent 36%),
    linear-gradient(180deg, #fffdf6 0%, #f7fff9 43%, #fff4ec 100%);
}

#quizView::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.52), rgba(255, 255, 255, 0.08) 46%, rgba(255, 246, 235, 0.38)),
    url("./assets/home-campus-bg.svg") center -76px / 126% auto no-repeat;
  opacity: 0.2;
}

#quizView .quiz-top-bar,
#quizView .progress-track,
#quizView .quiz-card,
#quizView .quiz-actions {
  position: relative;
  z-index: 1;
}

#quizView.active .quiz-top-bar {
  animation: quiz-rise-in 0.42s cubic-bezier(0.22, 1, 0.36, 1) both;
}

#quizView.active .progress-track {
  animation: quiz-rise-in 0.44s cubic-bezier(0.22, 1, 0.36, 1) 0.05s both;
}

#quizView .progress-track {
  height: 6px;
  margin: 8px 2px 28px;
  border: 1px solid rgba(255, 255, 255, 0.62);
  background: rgba(82, 103, 88, 0.1);
  box-shadow:
    inset 0 1px 4px rgba(42, 80, 74, 0.06),
    0 10px 24px rgba(68, 120, 113, 0.08);
}

#quizView .progress-fill {
  position: relative;
  background:
    linear-gradient(90deg, #f0a170 0%, #7bcfc7 22%, #57B7B7 64%, #3E9595 100%);
  box-shadow: 0 6px 16px rgba(62, 149, 149, 0.24);
  transition: width 0.34s cubic-bezier(0.22, 1, 0.36, 1);
}

#quizView .progress-fill::before {
  content: "";
  position: absolute;
  top: 50%;
  left: -1px;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: #f1a170;
  box-shadow:
    0 0 0 4px rgba(255, 255, 255, 0.74),
    0 8px 18px rgba(219, 133, 91, 0.22);
  transform: translateY(-50%);
}

#quizView .quiz-top-bar {
  align-items: center;
  gap: 12px;
  margin: -16px -24px 10px;
  padding: 18px 24px 16px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.82), rgba(232, 252, 247, 0.44));
  box-shadow: 0 16px 34px rgba(68, 120, 113, 0.08);
}

#quizView .quiz-top-bar .back-btn {
  flex: 0 0 44px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  color: #26332d;
}

#quizView .quiz-header-titles {
  flex: 1;
  min-width: 0;
}

#quizView .quiz-header-titles h2 {
  font-size: clamp(21px, 5.5vw, 22px);
  font-weight: 950;
  line-height: 1.12;
  letter-spacing: 0;
  color: #202832;
}

#quizView .page-subtitle {
  margin-top: 8px;
  color: #4fb8b5;
  font-size: 13px;
  font-weight: 900;
}

#quizView .quiz-top-bar .pill {
  min-width: 78px;
  max-width: none;
  padding: 10px 13px;
  color: #43a5a2;
  font-size: 15px;
  font-weight: 950;
  letter-spacing: 0.03em;
  border: 1px solid rgba(255, 255, 255, 0.72);
  background:
    radial-gradient(circle at 28% 18%, rgba(255, 255, 255, 0.74), transparent 42%),
    linear-gradient(145deg, rgba(232, 252, 247, 0.92), rgba(255, 246, 232, 0.54));
  box-shadow:
    0 14px 28px rgba(68, 120, 113, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

#quizView .quiz-card {
  min-height: 0;
  padding: 24px 18px 20px;
  border-color: rgba(255, 255, 255, 0.82);
  border-radius: 24px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.93), rgba(250, 255, 249, 0.78)),
    radial-gradient(circle at 90% 14%, rgba(255, 154, 61, 0.12), transparent 24%);
  box-shadow:
    0 18px 38px rgba(68, 120, 113, 0.1),
    0 8px 20px rgba(255, 154, 61, 0.06),
    inset 0 1px 0 rgba(255, 255, 255, 0.96);
}

#quizView .quiz-card-enter {
  animation: quiz-card-in 0.34s cubic-bezier(0.22, 1, 0.36, 1) both;
}

#quizView .quiz-question-tag {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  margin: 0 0 15px;
  padding: 0 12px;
  border-radius: 999px;
  color: #b86f4d;
  font-size: 12px;
  font-weight: 950;
  letter-spacing: 0.05em;
  background: rgba(255, 228, 211, 0.82);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
}

#quizView .quiz-card h3 {
  margin: 0;
  color: #202832;
  font-size: clamp(22px, 6vw, 27px);
  font-weight: 950;
  line-height: 1.28;
  letter-spacing: 0;
}

#quizView .answer-list {
  display: grid;
  gap: 12px;
  margin-top: 24px;
}

#quizView .answer-option {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr) 22px;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 68px;
  border: 1px solid rgba(32, 36, 45, 0.09);
  border-radius: 22px;
  padding: 12px 14px;
  color: #232a34;
  text-align: left;
  line-height: 1.45;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.92), rgba(255, 253, 247, 0.82));
  box-shadow:
    0 10px 20px rgba(68, 120, 113, 0.06),
    inset 0 1px 0 rgba(255, 255, 255, 0.88);
  transition:
    transform 0.14s ease,
    background 0.18s ease,
    border-color 0.18s ease,
    box-shadow 0.18s ease,
    color 0.18s ease;
  cursor: pointer;
}

#quizView .answer-option.answer-enter {
  animation: quiz-option-in 0.32s cubic-bezier(0.22, 1, 0.36, 1) both;
  animation-delay: var(--answer-delay, 0ms);
}

#quizView .answer-option:active {
  transform: translateY(1px) scale(0.985);
}

#quizView .answer-option:focus-visible {
  outline: 3px solid rgba(87, 183, 183, 0.22);
  outline-offset: 3px;
}

#quizView .answer-letter {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  color: #4c6967;
  font-size: 15px;
  font-weight: 950;
  background:
    linear-gradient(145deg, rgba(232, 252, 247, 0.9), rgba(255, 246, 232, 0.64));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.84);
  transition: color 0.18s ease, background 0.18s ease, transform 0.18s ease;
}

#quizView .answer-copy {
  min-width: 0;
  font-size: 16px;
  font-weight: 850;
}

#quizView .answer-check {
  position: relative;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 1px solid rgba(62, 149, 149, 0.18);
  background: rgba(255, 255, 255, 0.58);
  opacity: 0.58;
  transition: opacity 0.18s ease, background 0.18s ease, border-color 0.18s ease;
}

#quizView .answer-check::after {
  content: "";
  position: absolute;
  left: 6px;
  top: 3px;
  width: 5px;
  height: 10px;
  border: solid white;
  border-width: 0 2px 2px 0;
  opacity: 0;
  transform: rotate(45deg) scale(0.7);
  transition: opacity 0.18s ease, transform 0.18s ease;
}

#quizView .answer-option.selected {
  border-color: rgba(69, 176, 170, 0.58);
  color: #173d3a;
  background:
    radial-gradient(circle at 94% 16%, rgba(255, 154, 61, 0.16), transparent 24%),
    linear-gradient(145deg, rgba(229, 252, 247, 0.96), rgba(255, 247, 237, 0.78));
  box-shadow:
    0 16px 28px rgba(62, 149, 149, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.96);
}

#quizView .answer-option.selected .answer-letter {
  color: white;
  background:
    radial-gradient(circle at 30% 18%, rgba(255, 255, 255, 0.42), transparent 40%),
    linear-gradient(135deg, #57B7B7, #3E9595);
  transform: scale(1.02);
}

#quizView .answer-option.selected .answer-check {
  border-color: transparent;
  background: #f0a170;
  opacity: 1;
  box-shadow: 0 7px 16px rgba(219, 133, 91, 0.24);
}

#quizView .answer-option.selected .answer-check::after {
  opacity: 1;
  transform: rotate(45deg) scale(1);
}

#quizView .answer-option.just-picked {
  transform: translateY(1px) scale(0.985);
}

#quizView .quiz-actions {
  display: grid;
  grid-template-columns: 0.78fr 1.22fr;
  gap: 12px;
  margin-top: 30px;
  padding-bottom: env(safe-area-inset-bottom);
}

#quizView .quiz-actions-enter {
  animation: quiz-rise-in 0.38s cubic-bezier(0.22, 1, 0.36, 1) 0.08s both;
}

#quizView .quiz-actions .primary-btn,
#quizView .quiz-actions .secondary-btn {
  min-height: 58px;
  border-radius: 22px;
  font-size: 17px;
  transition: transform 0.14s ease, opacity 0.18s ease, box-shadow 0.18s ease;
}

#quizView .quiz-actions .primary-btn:active,
#quizView .quiz-actions .secondary-btn:active {
  transform: translateY(1px) scale(0.985);
}

#quizView .quiz-actions .primary-btn.awaiting-answer {
  opacity: 0.74;
  box-shadow:
    0 10px 22px rgba(43, 135, 127, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.58);
}

#quizView .quiz-actions .primary-btn[aria-busy="true"] {
  opacity: 0.82;
  cursor: wait;
}

#quizView .quiz-actions .secondary-btn:disabled {
  color: rgba(32, 40, 50, 0.34);
  opacity: 0.48;
  cursor: default;
  transform: none;
}

@keyframes quiz-rise-in {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes quiz-card-in {
  from {
    opacity: 0;
    transform: translateY(12px) scale(0.992);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes quiz-option-in {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 370px) {
  #quizView {
    padding-left: 18px;
    padding-right: 18px;
  }

  #quizView .quiz-top-bar {
    margin-left: -18px;
    margin-right: -18px;
    padding-left: 18px;
    padding-right: 18px;
  }

  #quizView .quiz-top-bar .back-btn {
    flex-basis: 40px;
    width: 40px;
    height: 40px;
  }

  #quizView .quiz-top-bar .pill {
    min-width: 70px;
    padding: 9px 10px;
    font-size: 13px;
  }

  #quizView .quiz-card {
    padding: 21px 15px 18px;
  }

  #quizView .answer-option {
    grid-template-columns: 36px minmax(0, 1fr) 20px;
    min-height: 62px;
    padding: 10px 12px;
  }

  #quizView .answer-letter {
    width: 36px;
    height: 36px;
  }

  #quizView .answer-copy {
    font-size: 15px;
  }

  #quizView .quiz-actions .primary-btn,
  #quizView .quiz-actions .secondary-btn {
    min-height: 54px;
    font-size: 16px;
  }
}

@media (prefers-reduced-motion: reduce) {
  #quizView.active .quiz-top-bar,
  #quizView.active .progress-track,
  #quizView .quiz-card-enter,
  #quizView .answer-option.answer-enter,
  #quizView .quiz-actions-enter {
    animation: none;
  }

  #quizView .progress-fill,
  #quizView .answer-option,
  #quizView .answer-letter,
  #quizView .answer-check,
  #quizView .answer-check::after,
  #quizView .quiz-actions .primary-btn,
  #quizView .quiz-actions .secondary-btn {
    transition-duration: 0.01ms;
  }

  #unlockView.active .unlock-reveal,
  .portrait-avatar.unlock-mystery-avatar::before,
  .unlock-btn-spinner {
    animation: none;
  }
}

.portrait-hero {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 16px;
  align-items: center;
  padding: 18px;
  cursor: pointer;
}

.portrait-hero:focus-visible {
  outline: 3px solid rgba(87, 183, 183, 0.24);
  outline-offset: 3px;
}

.portrait-title-btn {
  display: block;
  margin: 0 0 10px;
  border: 0;
  padding: 0;
  color: var(--ink);
  font-size: 22px;
  font-weight: 900;
  line-height: 1.22;
  text-align: left;
  background: transparent;
}

.portrait-title-btn::after {
  content: "点击查看完整画像";
  display: block;
  margin-top: 6px;
  min-width: max-content;
  color: var(--whale-blue);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.4;
  white-space: nowrap;
}

.portrait-avatar,
.small-avatar,
.mini-avatar {
  display: grid;
  place-items: center;
  color: white;
  font-weight: 900;
  background: linear-gradient(135deg, #57B7B7, var(--violet));
  box-shadow: 0 16px 35px rgba(87, 183, 183, 0.23);
}

.portrait-avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;   /* 头像框已是 2:3，与图片比例一致，cover 完美填满不裁人不留白 */
  border-radius: inherit;
  display: block;
}

.portrait-avatar {
  width: 96px;
  height: 144px;   /* 2:3 比例，与头像源图（1024×1536）一致 */
  border-radius: 30px;
  font-size: 34px;
  overflow: hidden;
}

.small-avatar,
.mini-avatar {
  width: 50px;
  height: 50px;
  border-radius: 18px;
  flex: 0 0 auto;
  overflow: hidden;
}

/* 容器内有头像图时，去掉绿色渐变底与阴影，避免图片四周露出绿色框 */
.portrait-avatar:has(.portrait-avatar-img),
.small-avatar:has(.portrait-avatar-img),
.mini-avatar:has(.portrait-avatar-img) {
  background: transparent;
  box-shadow: none;
}

/* 个人中心右上角头像：与画像头像统一 2:3 比例 */
#profileAvatarSmall {
  width: 44px;
  height: 66px;
  border-radius: 14px;
}

.insight-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin: 14px 0;
}

.insight-card {
  min-height: 116px;
  padding: 16px;
}

.insight-card span {
  display: block;
  margin-bottom: 14px;
  color: var(--muted);
  font-size: 13px;
}

.insight-card strong {
  display: block;
  font-size: 18px;
  line-height: 1.32;
}

.analysis-card p,
.status-card p,
.ad-card p,
.qr-card p,
.portrait-hero p {
  color: var(--muted);
  line-height: 1.7;
}

.schedule-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px;
}

.schedule-button {
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.7);
  color: inherit;
  text-align: left;
}

.schedule-button h3 {
  margin: 0;
}

.schedule-hint {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.6;
}

.result-waiting-card {
  margin-bottom: 14px;
  border: 0;
  color: white;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.result-waiting-card[data-match-type="dating"] {
  background:
    radial-gradient(circle at 84% 12%, rgba(255, 255, 255, 0.22), transparent 34%),
    linear-gradient(135deg, #FF9A3D, #f2c58f);
}

.result-waiting-card[data-match-type="friendship"] {
  background:
    radial-gradient(circle at 84% 12%, rgba(255, 255, 255, 0.2), transparent 34%),
    linear-gradient(135deg, #8FD0D0, #57B7B7);
}

.result-waiting-card .waiting-main,
.result-waiting-card .waiting-time {
  color: white;
}

.result-waiting-card .big-countdown.ready,
.result-waiting-card .card-countdown.ready {
  color: white;
  background:
    radial-gradient(circle at 18% 20%, rgba(255, 255, 255, 0.42), transparent 24%),
    linear-gradient(135deg, var(--coral) 0%, #d46fb1 48%, var(--violet) 100%);
  background-size: 140% 140%;
  box-shadow: 0 14px 30px rgba(143, 166, 179, 0.22);
}

.result-waiting-list {
  display: grid;
  gap: 14px;
  margin-bottom: 14px;
}

.waiting-copy {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.waiting-type-icon {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 1px solid rgba(255, 255, 255, 0.82);
  border-radius: 14px;
  box-shadow: 0 12px 28px rgba(87, 183, 183, 0.16);
}

.waiting-type-icon svg {
  width: 23px;
  height: 23px;
  fill: none;
  stroke: var(--sage);
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.love-result-icon {
  background:
    radial-gradient(circle at 72% 18%, rgba(255, 154, 61, 0.22), transparent 32%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.96), rgba(255, 244, 207, 0.35));
}

.buddy-result-icon {
  background:
    radial-gradient(circle at 70% 18%, rgba(199, 216, 192, 0.42), transparent 32%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.98), rgba(143, 166, 179, 0.2));
}

.love-result-icon svg {
  stroke: #FF9A3D;
}

.buddy-result-icon svg {
  stroke: #57B7B7;
}

.waiting-title {
  display: grid;
  gap: 4px;
  margin: 0;
}

.waiting-title span {
  display: block;
}

.waiting-main {
  color: var(--ink);
  font-size: 19px;
  font-weight: 900;
  line-height: 1.28;
  white-space: nowrap;
}

.waiting-time {
  color: var(--ink);
  font-size: 17px;
  font-weight: 900;
  line-height: 1.28;
}

.waiting-sub {
  color: var(--sage);
  font-size: 13px;
  font-weight: 850;
}

.countdown {
  position: relative;
  isolation: isolate;
  display: inline-flex;
  align-items: baseline;
  justify-content: center;
  gap: 1px;
  flex: 0 0 auto;
  min-width: 144px;
  padding: 12px 15px;
  overflow: hidden;
  color: white;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
  border-radius: 18px;
  background:
    radial-gradient(circle at 18% 20%, rgba(255, 255, 255, 0.42), transparent 24%),
    linear-gradient(135deg, var(--coral) 0%, #d46fb1 48%, var(--violet) 100%);
  background-size: 140% 140%;
  animation:
    countdownBreath 3.6s ease-in-out infinite,
    countdownGradient 8s ease-in-out infinite;
}

.countdown-days {
  display: inline-flex;
  align-items: baseline;
  gap: 2px;
  margin-right: 6px;
  font-size: 1.08em;
  line-height: 1;
}

.countdown-days small {
  font-size: 0.72em;
  font-weight: 950;
}

.countdown-clock,
.countdown-second {
  line-height: 1;
}

.countdown-second {
  display: inline-block;
  min-width: 1.38em;
  transform-origin: 50% 70%;
}

.countdown-second.tick {
  animation: secondTick 0.52s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.countdown.ready {
  min-width: 160px;
  align-items: center;
  padding-inline: 18px;
  font-size: 15px;
  letter-spacing: 0;
  white-space: nowrap;
  cursor: pointer;
}

/* 倒计时归零但未参加匹配时的提示 */
.not-joined-label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0;
  white-space: normal;
  text-align: center;
  line-height: 1.4;
  opacity: 0.65;
  padding-inline: 6px;
}

.countdown::before {
  content: "";
  position: absolute;
  inset: -45% -70%;
  z-index: -1;
  background: linear-gradient(110deg, transparent 35%, rgba(255, 255, 255, 0.5) 48%, transparent 62%);
  transform: translateX(-36%);
  animation: countdownShine 3.8s ease-in-out infinite;
}

.countdown::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  border: 0;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.28), inset 0 -10px 18px rgba(92, 125, 131, 0.08);
}

.big-countdown {
  min-width: 168px;
  padding: 18px 19px;
  border-radius: 22px;
  font-size: 21px;
  text-align: center;
  box-shadow: 0 14px 30px rgba(143, 166, 179, 0.22);
}

.big-countdown .countdown-second {
  min-width: 1.45em;
}

@keyframes countdownBreath {
  0%,
  100% {
    transform: translateY(0) scale(1);
    box-shadow: 0 14px 30px rgba(143, 166, 179, 0.22);
  }
  50% {
    transform: translateY(-1px) scale(1.018);
    box-shadow: 0 18px 38px rgba(143, 166, 179, 0.3);
  }
}

@keyframes countdownGradient {
  0%,
  100% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
}

@keyframes countdownShine {
  0%,
  38% {
    transform: translateX(-42%) rotate(0.001deg);
    opacity: 0;
  }
  52% {
    opacity: 0.65;
  }
  72%,
  100% {
    transform: translateX(42%) rotate(0.001deg);
    opacity: 0;
  }
}

@keyframes secondTick {
  0% {
    opacity: 0;
    transform: translateY(8px) scale(0.92);
    filter: blur(2px);
  }
  58% {
    opacity: 1;
    transform: translateY(-2px) scale(1.08);
    filter: blur(0);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
  }
}

@media (prefers-reduced-motion: reduce) {
  .countdown,
  .countdown::before,
  .countdown-second.tick {
    animation: none;
  }
}

.status-card {
  margin-bottom: 18px;
}

.history-card {
  margin-bottom: 18px;
  display: grid;
  gap: 14px;
  padding: 18px;
  border: 1px solid rgba(32, 36, 45, 0.08);
  background: var(--card);
  position: relative;
  z-index: 6;
  pointer-events: auto;
}

.match-history-card {
  margin-top: 2px;
}

.history-head {
  display: block;
  padding: 0;
  margin-bottom: 0;
}

.history-head h3 {
  margin: 0 0 3px;
  color: var(--ink);
  font-size: 20px;
  font-weight: 950;
  line-height: 1.28;
  white-space: nowrap;
  letter-spacing: 0;
}

.history-head p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
  line-height: 1.35;
}

.history-head span {
  flex: 0 0 auto;
  padding: 7px 11px;
  border-radius: 999px;
  color: var(--sage);
  background: rgba(87, 183, 183, 0.1);
  font-size: 12px;
  font-weight: 900;
}

.history-list {
  display: grid;
  gap: 10px;
  padding: 0;
  position: relative;
  z-index: 2;
}

.history-item {
  position: relative;
  z-index: 7;
  display: grid;
  gap: 3px;
  width: 100%;
  padding: 13px 15px;
  border: 1px solid rgba(87, 183, 183, 0.12);
  border-radius: 18px;
  text-align: left;
  text-decoration: none;
  background: rgba(246, 246, 242, 0.88);
  cursor: pointer;
  pointer-events: auto;
  transition:
    transform 160ms ease,
    border-color 160ms ease,
    box-shadow 160ms ease;
}

.history-item:active {
  transform: scale(0.985);
}

.history-item:hover {
  border-color: rgba(87, 183, 183, 0.24);
  box-shadow: 0 16px 34px rgba(93, 113, 96, 0.1);
}

.history-item span {
  color: var(--ink);
  font-size: 15px;
  font-weight: 900;
  line-height: 1.25;
}

.history-item small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
  line-height: 1.25;
}

.history-unread-badge {
  position: absolute;
  top: 12px;
  right: 14px;
  display: inline-grid;
  place-items: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
  color: #fff;
  background: var(--coral);
  box-shadow: 0 4px 10px rgba(255, 154, 61, 0.35);
}

.history-empty-card {
  width: 100%;
  padding: 18px 16px;
  border: 1px solid rgba(87, 183, 183, 0.1);
  border-radius: 18px;
  color: rgba(112, 119, 131, 0.86);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.45;
  text-align: center;
  background:
    linear-gradient(145deg, rgba(246, 246, 242, 0.78), rgba(238, 244, 239, 0.52));
}

.non-campus-notice {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  margin-bottom: 4px;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(87, 183, 183, 0.14), rgba(87, 183, 183, 0.06));
  border: 1px solid rgba(87, 183, 183, 0.28);
  font-size: 13px;
  color: var(--ink);
  line-height: 1.5;
}

.non-campus-notice::before {
  content: "🌊";
  flex-shrink: 0;
  font-size: 15px;
}

.match-options {
  display: grid;
  gap: 12px;
  margin: 14px 0;
}

.match-choice {
  position: relative;
  min-height: 126px;
  border: 0;
  border-radius: 22px;
  padding: 24px 190px 22px 84px;
  color: white;
  text-align: left;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.match-choice.friendship.prefs-open {
  padding-bottom: 24px;
}

.match-choice.friendship.prefs-open .check-ring {
  top: 76px;
}

.match-choice.friendship.prefs-open .match-side-controls {
  top: 24px;
  transform: none;
}

.choice-title,
.match-choice strong {
  display: block;
}

.choice-title {
  margin-bottom: 9px;
  font-size: 20px;
  font-weight: 900;
}

.match-choice strong {
  font-size: 14px;
  opacity: 0.92;
}

.match-choice em {
  display: block;
  margin-top: 9px;
  max-width: 220px;
  font-style: normal;
  font-size: 13px;
  line-height: 1.45;
  opacity: 0.9;
}

.check-ring {
  position: absolute;
  left: 28px;
  top: 50%;
  transform: translateY(-50%);
  width: 38px;
  height: 38px;
  border: 1px solid rgba(255, 255, 255, 0.68);
  border-radius: 999px;
  background:
    radial-gradient(circle at 30% 24%, rgba(255, 255, 255, 0.95), transparent 18%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.82), rgba(255, 255, 255, 0.34));
  box-shadow: 0 14px 28px rgba(32, 36, 45, 0.13), inset 0 1px 0 rgba(255, 255, 255, 0.72);
  cursor: pointer;
}

.match-choice.joined .check-ring {
  border-color: rgba(255, 255, 255, 0.86);
  background:
    radial-gradient(circle at 30% 24%, rgba(255, 255, 255, 0.98), transparent 18%),
    linear-gradient(145deg, #fffdf7, rgba(246, 246, 242, 0.86));
}

.match-choice.joined .check-ring::after {
  content: "";
  position: absolute;
  left: 12px;
  top: 12px;
  width: 13px;
  height: 8px;
  border-left: 2.5px solid #57B7B7;
  border-bottom: 2.5px solid #57B7B7;
  border-radius: 2px;
  transform: rotate(-45deg);
}

.joined-label {
  position: absolute;
  right: 16px;
  top: 16px;
  display: block;
  padding: 7px 10px;
  border-radius: 999px;
  color: rgba(32, 36, 45, 0.62);
  font-size: 12px;
  background: rgba(255, 255, 255, 0.92);
}

.match-side-controls {
  position: absolute;
  right: 18px;
  top: 50%;
  transform: translateY(-50%);
  display: grid;
  justify-items: center;
  gap: 7px;
}

.match-side-controls .joined-label,
.match-side-controls .buddy-prefs-toggle {
  position: static;
  display: inline-grid;
  place-items: center;
  width: 74px;
  min-height: 32px;
  padding: 0 10px;
  border-radius: 999px;
  line-height: 1;
}

.match-pill-row {
  display: flex;
  justify-content: center;
  gap: 8px;
}

.buddy-prefs-toggle {
  padding: 6px 10px;
  border: 0;
  border-radius: 999px;
  color: #3E9595;
  font-size: 12px;
  font-weight: 900;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 8px 18px rgba(32, 36, 45, 0.08);
}

.card-countdown {
  min-width: 168px;
  padding: 18px 19px;
  border-radius: 22px;
  font-size: 21px;
  cursor: pointer;
}

.dating-countdown {
  background:
    radial-gradient(circle at 18% 20%, rgba(255, 255, 255, 0.4), transparent 24%),
    linear-gradient(135deg, #d98996 0%, #b98aa5 52%, #8fa6b3 100%);
}

.friendship-countdown {
  background:
    radial-gradient(circle at 18% 20%, rgba(255, 255, 255, 0.4), transparent 24%),
    linear-gradient(135deg, #d98996 0%, #b98aa5 52%, #8fa6b3 100%);
}

.match-detail-hint {
  margin: -2px 0 0;
  color: rgba(255, 255, 255, 0.92);
  font-size: 12px;
  font-weight: 850;
  text-align: right;
}

.match-choice.joined .joined-label {
  color: #57B7B7;
}

.match-choice.dating {
  background:
    radial-gradient(circle at 84% 12%, rgba(255, 255, 255, 0.22), transparent 34%),
    linear-gradient(135deg, #FF9A3D, #f2c58f);
}

.match-choice.friendship {
  background:
    radial-gradient(circle at 84% 12%, rgba(255, 255, 255, 0.2), transparent 34%),
    linear-gradient(135deg, #8FD0D0, #57B7B7);
}

.buddy-options {
  display: grid;
  gap: 12px;
  width: calc(100% + 176px);
  margin: 18px 0 0 -34px;
  padding: 13px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.16);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18);
}

.buddy-options p {
  margin: 0 0 8px;
  color: rgba(255, 255, 255, 0.92);
  font-size: 12px;
  font-weight: 850;
  text-align: center;
}

.mini-choice-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
}

.mini-chip {
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 999px;
  padding: 7px 10px;
  color: white;
  font-size: 12px;
  font-weight: 850;
  background: rgba(255, 255, 255, 0.12);
}

.mini-chip.selected {
  color: #3E9595;
  border-color: rgba(255, 255, 255, 0.88);
  background: rgba(255, 255, 255, 0.9);
}

.buddy-confirm-btn {
  width: 100%;
  min-height: 42px;
  border: 0;
  border-radius: 999px;
  color: #3E9595;
  font-size: 13px;
  font-weight: 950;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 10px 22px rgba(32, 36, 45, 0.08);
}

.buddy-category-field {
  display: grid;
  gap: 8px;
}

.buddy-category-field input {
  height: 42px;
  margin: 0;
  border-radius: 999px;
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.28);
  background: rgba(255, 255, 255, 0.12);
}

.buddy-category-field input::placeholder {
  color: rgba(255, 255, 255, 0.76);
}

.buddy-category-field input:focus {
  border-color: rgba(255, 255, 255, 0.82);
  background: rgba(255, 255, 255, 0.18);
  box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.08);
}

/* ── 搭子偏好弹窗 ─────────────────────────────────── */
.buddy-pref-sheet {
  position: relative;
  background: #fff;
  border-radius: 24px;
  padding: 24px 22px 28px;
  width: min(calc(100% - 40px), 360px);
  max-height: 88vh;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 20px;
  box-shadow: 0 8px 40px rgba(30, 36, 48, 0.14), 0 2px 8px rgba(30, 36, 48, 0.06);
}

.buddy-pref-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

/* 搭子偏好弹窗的关闭按钮在 flex header 里，覆盖绝对定位回归流内 */
.buddy-pref-header .modal-close {
  position: static;
  flex-shrink: 0;
  align-self: flex-start;
}

.buddy-pref-header-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.buddy-pref-title {
  font-size: 20px;
  font-weight: 900;
  color: var(--ink);
  margin: 0;
  letter-spacing: 0.01em;
}

.buddy-pref-subtitle {
  font-size: 13px;
  color: var(--muted);
  margin: 0;
}

.buddy-pref-body {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.buddy-pref-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.buddy-pref-label {
  font-size: 13px;
  font-weight: 700;
  color: var(--ink);
  opacity: 0.65;
  margin: 0;
  letter-spacing: 0.02em;
}

.pref-chips-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.pref-chip {
  padding: 7px 16px;
  border: 1.5px solid #e0e0e0;
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  font-size: 13.5px;
  font-weight: 500;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s, color 0.15s;
  line-height: 1;
}

.pref-chip.selected {
  border-color: #57B7B7;
  background: rgba(87, 183, 183, 0.12);
  color: #3d9e96;
  font-weight: 700;
}

.buddy-pref-category {
  padding-top: 4px;
}

.pref-text-input {
  width: 100%;
  height: 42px;
  padding: 0 14px;
  border: 1.5px solid #e0e0e0;
  border-radius: 12px;
  font-size: 14px;
  color: var(--ink);
  background: #fafafa;
  box-sizing: border-box;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.pref-text-input:focus {
  border-color: #57B7B7;
  box-shadow: 0 0 0 3px rgba(87, 183, 183, 0.18);
  outline: none;
}

.pref-text-input::placeholder {
  color: #aaa;
}

.buddy-pref-confirm-btn {
  width: 100%;
  margin-top: 4px;
}

/* 已过期按钮（历史匹配，24h 窗口关闭） */
.btn-disabled,
.btn-disabled:disabled {
  background: #d1d5db !important;
  color: #9ca3af !important;
  box-shadow: none !important;
  cursor: not-allowed;
}

/* 对方开场白预览气泡 */
.peer-greeting-bubble {
  margin: 0 0 6px;
  padding: 10px 14px;
  background: rgba(87, 183, 183, 0.12);
  border: 1px solid rgba(87, 183, 183, 0.3);
  border-radius: 4px 14px 14px 14px;
  font-size: 14px;
  color: var(--ink);
  line-height: 1.5;
}

/* 对方婉拒状态卡 */
.peer-declined-card {
  text-align: center;
  padding: 32px 24px 24px;
}
.peer-declined-icon {
  font-size: 36px;
  margin-bottom: 12px;
  line-height: 1;
}
.peer-declined-card h3 {
  margin: 0 0 10px;
  font-size: 17px;
  color: var(--ink);
}
.peer-declined-card p {
  margin: 0 0 22px;
  font-size: 14px;
  color: var(--muted);
  line-height: 1.6;
}
.peer-declined-card .primary-btn {
  width: 100%;
}

.ad-card {
  margin-bottom: 14px;
  padding: 0;
  border: 1px solid rgba(87, 183, 183, 0.16);
  border-radius: 20px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.5);
}

.ad-card img {
  display: block;
  width: 100%;
  min-height: 120px;
  object-fit: cover;
}

.reason-list {
  display: grid;
  gap: 10px;
  margin: 18px 0;
}

.match-report-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin: 18px 0;
}

.match-report-grid h4 {
  margin: 0 0 9px;
  color: var(--whale-blue);
  font-size: 13px;
  font-weight: 900;
}

.report-list {
  display: grid;
  gap: 9px;
}

.reason,
.personality-point {
  padding: 12px 13px;
  border-radius: 18px;
  color: var(--ink);
  background: rgba(87, 183, 183, 0.08);
  line-height: 1.5;
  font-size: 13px;
}

.chat-confirm {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

/* 暂不聊天隐藏时，开始聊天/继续聊天按钮居中铺满 */
.chat-confirm:has(#declineChatBtn.hidden) {
  grid-template-columns: 1fr;
}
.chat-confirm:has(#declineChatBtn.hidden) #startChatBtn {
  width: 100%;
}

.greeting-box {
  grid-column: 1 / -1;
  display: grid;
  gap: 8px;
  padding: 14px;
  border: 1px solid rgba(87, 183, 183, 0.12);
  border-radius: 22px;
  background: rgba(87, 183, 183, 0.06);
}

.greeting-box label {
  color: var(--whale-blue);
  font-size: 13px;
  font-weight: 900;
}

.greeting-box textarea {
  min-height: 74px;
  margin: 0;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.78);
  resize: none;
}

.incoming-greeting {
  grid-column: 1 / -1;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  width: fit-content;
  margin: 0 0 4px;
  padding: 11px 14px;
  border-radius: 18px 18px 18px 6px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
  background: rgba(87, 183, 183, 0.08);
  box-shadow: inset 0 0 0 1px rgba(87, 183, 183, 0.08);
}

.message-dot,
.message-badge {
  display: inline-grid;
  place-items: center;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 999px;
  color: white;
  background: var(--coral);
  box-shadow: 0 8px 18px rgba(255, 154, 61, 0.28);
}

.badge-btn {
  position: relative;
}

.message-badge {
  position: absolute;
  right: 18px;
  top: -8px;
  border: 2px solid rgba(255, 255, 255, 0.92);
  font-size: 11px;
}

.chat-confirm .primary-btn,
.chat-confirm .secondary-btn {
  min-width: 0;
}

.full-width {
  width: 100%;
}

.chat-header {
  position: sticky;
  top: 0;
  z-index: 45;
  margin: -24px -32px 18px;
  padding: 18px 32px;
  background: rgba(250, 249, 246, 0.84);
  backdrop-filter: blur(18px);
  justify-content: flex-start;
  align-items: center;
  gap: 12px;
}

.chat-title-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  flex: 1;
}

.chat-title-wrap h2 {
  margin: 0;
  font-size: 24px;
  font-weight: 950;
  line-height: 1.15;
}

.chat-title-icon {
  width: 46px;
  height: 46px;
  border-radius: 16px;
}

.chat-title-icon svg {
  width: 27px;
  height: 27px;
}

.chat-header p {
  display: none;
}

.chat-menu {
  position: relative;
  flex: 0 0 auto;
  z-index: 70;
}

.menu-btn {
  font-size: 20px;
  font-weight: 900;
}

.chat-menu-panel {
  position: fixed;
  right: max(18px, calc((100vw - 430px) / 2 + 18px));
  top: 86px;
  z-index: 120;
  display: grid;
  gap: 6px;
  min-width: 128px;
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, 0.9);
  border-radius: 22px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.98), rgba(238, 252, 248, 0.94));
  box-shadow:
    0 22px 48px rgba(42, 70, 64, 0.24),
    0 8px 18px rgba(255, 154, 61, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(24px);
}

.chat-menu-panel.hidden {
  display: none;
}

.chat-menu-panel button {
  min-height: 40px;
  border: 0;
  border-radius: 16px;
  color: var(--ink);
  font-weight: 800;
  text-align: left;
  padding: 0 12px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.92);
}

.chat-menu-panel button:hover {
  background: rgba(199, 216, 192, 0.28);
}

.icon-btn {
  display: inline-grid;
  place-items: center;
  width: 42px;
  height: 42px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.8);
}

.icon-btn svg {
  width: 23px;
  height: 23px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.back-btn {
  color: #20242d;
  background: rgba(255, 255, 255, 0.86);
  box-shadow:
    inset 0 0 0 1px rgba(32, 36, 45, 0.04),
    0 10px 22px rgba(32, 36, 45, 0.06);
}

.menu-btn {
  font-size: 24px;
  font-weight: 900;
}

.chat-thread {
  display: grid;
  gap: 14px;
  flex: 1;
  align-content: start;
  padding-bottom: 18px;
}

.chat-line {
  display: flex;
  align-items: flex-end;
  gap: 9px;
}

.them-line {
  justify-content: flex-start;
}

.me-line {
  justify-content: flex-end;
}

.chat-avatar {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  flex: 0 0 auto;
  border-radius: 14px;
  color: white;
  font-size: 13px;
  font-weight: 900;
  box-shadow: 0 10px 22px rgba(32, 36, 45, 0.1);
}

.them-avatar {
  background: linear-gradient(135deg, #8FD0D0, #57B7B7);
}

.me-avatar {
  background: linear-gradient(135deg, #FF9A3D, #f2c58f);
}

.message {
  max-width: 82%;
  padding: 12px 14px;
  border-radius: 20px;
  line-height: 1.55;
  box-shadow: 0 10px 26px rgba(23, 32, 51, 0.07);
}

.message.them {
  justify-self: start;
  background: rgba(255, 255, 255, 0.86);
}

.message.me {
  justify-self: end;
  color: white;
  background: linear-gradient(135deg, #57B7B7, var(--sea-mint));
}

.chat-input {
  position: sticky;
  left: auto;
  bottom: 12px;
  z-index: 25;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  width: 100%;
  max-width: 100%;
  margin-top: auto;
  transform: none;
  padding: 10px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.92), rgba(232, 252, 247, 0.66));
  backdrop-filter: blur(20px);
  box-shadow:
    0 16px 34px rgba(68, 120, 113, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.94);
}

.chat-input input {
  height: 44px;
  margin: 0;
  border-radius: 999px;
}

.chat-input .primary-btn {
  width: auto;
  min-height: 44px;
}

.community-grid {
  display: grid;
  gap: 14px;
}

.qr-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 148px;
  gap: 16px;
  align-items: center;
  padding: 18px;
}

.community-copy h3 {
  margin-bottom: 12px;
}

.community-copy p {
  margin: 0;
  color: var(--muted);
  line-height: 1.75;
}

.qr-block {
  display: grid;
  justify-items: center;
  gap: 9px;
}

.fake-qr {
  display: grid;
  place-items: center;
  width: 118px;
  height: 118px;
  border: 10px solid white;
  border-radius: 18px;
  background:
    linear-gradient(90deg, var(--ink) 10px, transparent 10px) 0 0 / 22px 22px,
    linear-gradient(var(--ink) 10px, transparent 10px) 0 0 / 22px 22px,
    #fff;
  box-shadow: inset 0 0 0 1px var(--line), 0 12px 26px rgba(32, 36, 45, 0.1);
}

.qr-block p {
  margin: 0;
  color: var(--muted);
  width: 148px;
  font-size: 10px;
  font-weight: 750;
  line-height: 1.45;
  text-align: center;
  white-space: nowrap;
}

.settings-card {
  display: grid;
  gap: 0;
  margin-bottom: 14px;
  padding: 0 16px;
}

.settings-card div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 58px;
  border-bottom: 1px solid var(--line);
}

.settings-card div:last-child {
  border-bottom: 0;
}

.settings-card span {
  color: var(--muted);
}

.settings-card strong {
  text-align: right;
}

/* 密码设置行 */
.password-setting-row {
  cursor: pointer;
}

.settings-action-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  border: 0;
  background: transparent;
  color: var(--whale-blue);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  padding: 0;
}

/* 设置密码 Modal 卡片内容 */
.set-password-card {
  text-align: center;
  padding-top: 28px;
}

.set-pw-icon {
  font-size: 36px;
  margin-bottom: 8px;
}

.set-pw-title {
  font-size: 22px;
  font-weight: 900;
  color: var(--ink);
  margin-bottom: 6px;
}

.set-pw-sub {
  margin-bottom: 22px;
}

.set-pw-sub,
.set-password-card label {
  text-align: left;
}

.set-pw-skip {
  display: block;
  width: 100%;
  margin-top: 10px;
  color: var(--muted);
  font-size: 13px;
  text-align: center;
}

/* 修改密码 Modal */
.change-password-modal {
  position: relative;
  width: min(calc(100% - 28px), 420px);
}

.change-password-modal h2 {
  margin-bottom: 20px;
  font-size: 22px;
  font-weight: 900;
}

.stack-sm {
  margin-bottom: 0;
}

#profilePortrait {
  cursor: pointer;
  color: var(--whale-blue);
}

.account-card,
.contact-card {
  margin-bottom: 14px;
  padding: 18px;
}

.account-summary {
  display: grid;
  gap: 6px;
}

.account-summary-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 40px;
  padding: 0 4px;
  border-bottom: 1px solid var(--line);
}

.account-summary-row span {
  color: var(--muted);
  font-weight: 800;
}

.account-summary-row strong {
  color: var(--ink);
  font-size: 16px;
  font-weight: 600;
  text-align: right;
}

.summary-block {
  display: block;
  min-height: auto;
  padding: 10px 4px;
}

.summary-block span {
  display: block;
  margin-bottom: 6px;
}

.summary-block p {
  color: var(--ink);
  line-height: 1.6;
  font-size: 14px;
}

.account-intro-box {
  padding: 4px 4px 8px;
  border-bottom: 1px solid var(--line);
}

.account-interests-row {
  border-bottom: none;
}

.account-intro-label {
  display: block;
  font-size: 13px;
  font-weight: 800;
  color: var(--muted);
  margin-bottom: 6px;
}

.account-intro-text {
  margin: 0;
  width: 100%;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(32, 36, 45, 0.04);
  border: 1px solid rgba(32, 36, 45, 0.07);
  color: var(--ink);
  font-size: 13px;
  font-weight: 500;
  line-height: 1.65;
}

/* Interest chips in account summary */
.account-interest-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.account-interest-chip {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 20px;
  background: linear-gradient(135deg, rgba(87, 183, 183, 0.12), rgba(92, 125, 131, 0.10));
  border: 1px solid rgba(87, 183, 183, 0.22);
  color: var(--sage);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.account-interest-empty {
  font-size: 14px;
  color: var(--muted);
}

.account-card input[readonly] {
  color: var(--muted);
  background: rgba(30, 36, 48, 0.04);
}

.field-note {
  display: block;
  margin-top: 7px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.contact-card h3 {
  margin-bottom: 14px;
}

.contact-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 48px;
  border-top: 1px solid var(--line);
}

.contact-row span {
  color: var(--muted);
}

.contact-row strong {
  text-align: right;
}

/* Profile page product polish: personal frequency dossier */
#profilePageView.profile-page-view {
  padding-bottom: 132px;
}

.profile-page-view .profile-hero {
  position: relative;
  align-items: flex-start;
  min-height: 132px;
  margin: -24px -32px 18px;
  padding: 35px 32px 13px;
  border: 0;
  border-bottom: 0;
  border-radius: 0 0 32px 32px;
  background:
    radial-gradient(circle at 86% 18%, rgba(255, 255, 255, 0.6), transparent 24%),
    radial-gradient(circle at 18% 80%, rgba(213, 139, 102, 0.16), transparent 30%),
    linear-gradient(145deg, rgba(255, 253, 246, 0.94), rgba(232, 245, 242, 0.62) 48%, rgba(255, 243, 234, 0.58));
  box-shadow: none;
  backdrop-filter: none;
  overflow: hidden;
  animation: profile-card-enter var(--hz-motion-normal, 380ms) var(--hz-ease-out, ease-out) both;
}

.profile-page-view .profile-hero::before,
.profile-page-view .profile-hero::after {
  content: "";
  position: absolute;
  pointer-events: none;
  opacity: 0.42;
}

.profile-page-view .profile-hero::before {
  inset: 0;
  background:
    linear-gradient(180deg, rgba(255, 253, 246, 0.08), rgba(255, 253, 246, 0.5)),
    url("./assets/home-campus-bg.svg") center -118px / 126% auto no-repeat;
  opacity: 0.18;
}

.profile-page-view .profile-hero::after {
  right: -34px;
  top: -24px;
  width: 180px;
  height: 150px;
  border-radius: 0 0 0 44px;
  background:
    radial-gradient(circle at 70% 28%, rgba(255, 255, 255, 0.58), transparent 26%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.2), rgba(213, 139, 102, 0.08));
  opacity: 0.45;
}

.profile-page-view .profile-hero-heading,
.profile-page-view #profileAvatarSmall {
  position: relative;
  z-index: 1;
}

.profile-page-view .profile-hero-heading {
  display: grid;
  justify-items: start;
  gap: 0;
  max-width: min(286px, calc(100% - 82px));
  text-align: left;
}

.profile-page-view .profile-title-icon {
  display: none;
}

.profile-page-view .profile-kicker {
  margin: 0 0 4px;
  color: var(--hz-muted, #6F7D76);
  font-size: 11.5px;
  font-weight: 950;
  line-height: 1;
  letter-spacing: 0.18em;
}

.profile-page-view .match-heading {
  color: var(--hz-ink-strong, #202832);
  font-size: 31px;
  font-weight: 950;
  line-height: 1.04;
  letter-spacing: 0;
}

.profile-page-view .page-subtitle {
  margin: 7px 0 0;
  color: var(--hz-teal-700, #347E79);
  font-size: 13px;
  font-weight: 850;
  line-height: 1.48;
}

.profile-page-view #profileAvatarSmall {
  position: absolute;
  right: 32px;
  top: 45px;
  width: 44px;
  height: 44px;
  border: 2px solid rgba(255, 255, 255, 0.9);
  border-radius: 16px;
  background:
    radial-gradient(circle at 68% 18%, rgba(213, 139, 102, 0.18), transparent 34%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.96), rgba(232, 245, 242, 0.82));
  box-shadow:
    0 14px 28px rgba(57, 83, 76, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.92);
}

.profile-page-view #profileAvatarSmall:has(.portrait-avatar-img) {
  background: transparent;
}

.profile-page-view .account-card,
.profile-page-view .settings-card,
.profile-page-view .contact-card {
  position: relative;
  margin: 0 0 20px;
  padding: 22px;
  border: 1px solid rgba(52, 126, 121, 0.12);
  border-radius: var(--hz-radius-card-sm, 24px);
  background: var(--hz-card-bg);
  box-shadow: var(--hz-shadow-card);
  overflow: hidden;
  animation: profile-card-enter var(--hz-motion-normal, 380ms) var(--hz-ease-out, ease-out) both;
}

.profile-page-view .account-card {
  animation-delay: 70ms;
}

.profile-page-view .settings-card {
  animation-delay: 130ms;
}

.profile-page-view .contact-card {
  animation-delay: 190ms;
}

.profile-page-view .account-card::before,
.profile-page-view .settings-card::before,
.profile-page-view .contact-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 3px;
  background: linear-gradient(90deg, var(--hz-coral-500), var(--hz-teal-400), transparent);
  opacity: 0.52;
}

.profile-card-eyebrow {
  margin: 0 0 14px;
  color: var(--hz-teal-600, #3E9595);
  font-size: 13px;
  font-weight: 950;
  letter-spacing: 0.04em;
}

.profile-identity-panel {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 16px;
  padding: 16px;
  border: 1px solid rgba(52, 126, 121, 0.12);
  border-radius: 22px;
  background:
    radial-gradient(circle at 96% 8%, rgba(213, 139, 102, 0.12), transparent 28%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.88), rgba(255, 253, 246, 0.72));
}

.profile-identity-label {
  display: block;
  margin-bottom: 4px;
  color: var(--hz-muted, #6F7D76);
  font-size: 12px;
  font-weight: 850;
}

.profile-nickname {
  display: block;
  color: var(--hz-ink-strong, #202832);
  font-size: 28px;
  font-weight: 950;
  line-height: 1.15;
}

.profile-identity-meta {
  margin: 7px 0 0;
  color: var(--hz-muted, #6F7D76);
  font-size: 13px;
  font-weight: 800;
  line-height: 1.45;
}

.profile-completion-pill {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 11px;
  border-radius: var(--hz-radius-pill, 999px);
  color: var(--hz-coral-600, #B86F4D);
  background: var(--hz-chip-bg, rgba(251, 228, 215, 0.78));
  font-size: 12px;
  font-weight: 950;
}

.profile-detail-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 4px;
}

.profile-page-view .account-summary {
  gap: 14px;
}

.profile-page-view .account-summary-row {
  min-height: 50px;
  padding: 0;
  border-bottom-color: rgba(52, 126, 121, 0.12);
}

.profile-page-view .profile-detail-list .account-summary-row {
  display: grid;
  align-content: center;
  gap: 4px;
  min-height: 66px;
  padding: 10px;
  border: 1px solid rgba(52, 126, 121, 0.12);
  border-radius: 16px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.76), rgba(232, 245, 242, 0.42));
}

.profile-page-view .account-summary-row span,
.profile-page-view .account-intro-label {
  color: var(--hz-muted, #6F7D76);
  font-size: 14px;
  font-weight: 900;
}

.profile-page-view .account-summary-row strong {
  color: var(--hz-ink, #263631);
  font-size: 16px;
  font-weight: 950;
}

.profile-page-view .profile-detail-list .account-summary-row strong {
  font-size: 15px;
  text-align: left;
}

.profile-page-view .account-intro-box {
  padding: 2px 0 10px;
  border-bottom-color: rgba(52, 126, 121, 0.12);
}

.profile-page-view .account-intro-text {
  padding: 11px 13px;
  border-color: rgba(52, 126, 121, 0.12);
  border-radius: 18px;
  color: var(--hz-ink, #263631);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.92), rgba(232, 245, 242, 0.46));
  font-size: 14px;
  font-weight: 800;
}

.profile-page-view .account-interest-tags {
  margin-top: 6px;
  gap: 8px;
}

.profile-page-view .account-interest-chip,
.profile-page-view .account-interest-empty {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: var(--hz-radius-pill, 999px);
  border: 1px solid rgba(52, 126, 121, 0.12);
  background: rgba(255, 255, 255, 0.66);
  color: var(--hz-muted, #6F7D76);
  font-size: 12px;
  font-weight: 900;
}

.profile-page-view #editAccountBtn {
  width: min(100%, 280px);
  justify-self: center;
  margin-top: 4px;
  border-radius: var(--hz-radius-pill, 999px);
  box-shadow: var(--hz-shadow-button);
}

.profile-portrait-button {
  display: grid;
  width: 100%;
  min-height: 104px;
  margin-bottom: 14px;
  padding: 16px;
  border: 1px solid rgba(52, 126, 121, 0.14);
  border-radius: 22px;
  color: var(--hz-ink, #263631);
  text-align: left;
  background:
    radial-gradient(circle at 92% 12%, rgba(101, 183, 176, 0.16), transparent 32%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.9), rgba(255, 253, 246, 0.72));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.profile-portrait-button span,
.profile-status-tile span {
  color: var(--hz-muted, #6F7D76);
  font-size: 12px;
  font-weight: 900;
}

.profile-portrait-button strong {
  margin-top: 4px;
  color: var(--hz-teal-600, #3E9595);
  font-size: 26px;
  font-weight: 950;
  line-height: 1.15;
}

.profile-portrait-button em {
  margin-top: 5px;
  color: var(--hz-teal-500, #4FA9A2);
  font-size: 13px;
  font-style: normal;
  font-weight: 900;
}

.profile-page-view .profile-status-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  min-height: auto;
  margin-bottom: 12px;
  border-bottom: 0;
}

.profile-page-view .profile-status-tile {
  display: grid;
  align-content: center;
  justify-content: start;
  min-height: 82px;
  padding: 13px;
  border: 1px solid rgba(52, 126, 121, 0.12);
  border-radius: 20px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.82), rgba(232, 245, 242, 0.5));
}

.profile-page-view .profile-status-tile strong {
  display: block;
  margin-top: 8px;
  color: var(--hz-ink-strong, #202832);
  font-size: 20px;
  font-weight: 950;
  text-align: left;
}

.profile-page-view .password-setting-row {
  min-height: 56px;
  border-top: 1px solid rgba(52, 126, 121, 0.12);
}

.profile-page-view .password-setting-row > span {
  color: var(--hz-muted, #6F7D76);
  font-weight: 900;
}

.profile-page-view .settings-action-btn {
  min-height: 34px;
  padding: 0 4px 0 12px;
  color: var(--hz-teal-600, #3E9595);
  font-weight: 950;
}

.profile-page-view .logout-setting-row > span,
.profile-page-view .logout-action-btn {
  color: #D95757;
}

.profile-page-view .contact-card h3 {
  margin: 0 0 8px;
  color: var(--hz-ink-strong, #202832);
  font-size: 26px;
  line-height: 1.18;
}

.contact-subtitle {
  margin: 0 0 14px;
  color: var(--hz-muted, #6F7D76);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.55;
}

.profile-page-view .contact-row {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr) auto;
  gap: 10px;
  min-height: 56px;
  border-top-color: rgba(52, 126, 121, 0.12);
}

.profile-page-view .contact-row span {
  color: var(--hz-muted, #6F7D76);
  font-weight: 900;
}

.profile-page-view .contact-row strong {
  min-width: 0;
  color: var(--hz-ink, #263631);
  font-weight: 950;
  text-align: right;
  overflow-wrap: anywhere;
}

.profile-page-view .contact-row-wide {
  grid-template-columns: 48px minmax(0, 1fr);
}

.profile-page-view .contact-action-row {
  width: 100%;
  border: 0;
  border-top: 1px solid rgba(52, 126, 121, 0.12);
  background: transparent;
  grid-template-columns: 48px minmax(0, 1fr) auto;
  text-align: left;
  cursor: pointer;
}

.profile-page-view .contact-action-row strong {
  font-size: 13px;
  line-height: 1.2;
  letter-spacing: 0;
  white-space: nowrap;
  overflow-wrap: normal;
}

.profile-page-view .contact-action-row em {
  justify-self: end;
  color: var(--hz-teal-600, #3E9595);
  font-size: 13px;
  font-style: normal;
  font-weight: 950;
}

.contact-copy-btn {
  min-height: 32px;
  padding: 0 10px;
  border: 1px solid rgba(52, 126, 121, 0.14);
  border-radius: var(--hz-radius-pill, 999px);
  color: var(--hz-teal-600, #3E9595);
  background: rgba(255, 255, 255, 0.72);
  font-size: 12px;
  font-weight: 950;
}

.profile-page-view button,
.profile-page-view .profile-portrait-button,
.profile-page-view .password-setting-row {
  transition:
    transform var(--hz-motion-fast, 160ms) var(--hz-ease-out, ease-out),
    box-shadow var(--hz-motion-fast, 160ms) ease,
    border-color var(--hz-motion-fast, 160ms) ease,
    background var(--hz-motion-fast, 160ms) ease;
}

.profile-page-view button:active,
.profile-page-view .profile-portrait-button:active {
  transform: scale(0.97);
}

.profile-page-view .password-setting-row:active {
  background: rgba(232, 245, 242, 0.34);
}

.profile-page-view button:focus-visible {
  outline: 3px solid rgba(79, 169, 162, 0.2);
  outline-offset: 2px;
}

@keyframes profile-card-enter {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 380px) {
  .profile-page-view .profile-hero {
    min-height: 124px;
    padding-top: 33px;
    padding-bottom: 11px;
    padding-right: 24px;
    padding-left: 24px;
  }

  .profile-page-view #profileAvatarSmall {
    right: 24px;
    top: 43px;
    width: 40px;
    height: 40px;
  }

  .profile-page-view .match-heading {
    font-size: 29px;
  }

  .profile-page-view .account-card,
  .profile-page-view .settings-card,
  .profile-page-view .contact-card {
    padding: 20px;
  }

  .profile-status-grid {
    gap: 8px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .profile-page-view .profile-hero,
  .profile-page-view .account-card,
  .profile-page-view .settings-card,
  .profile-page-view .contact-card {
    animation: none;
  }

  .profile-page-view button,
  .profile-page-view .profile-portrait-button,
  .profile-page-view .password-setting-row {
    transition: none;
  }
}

.tab-bar {
  position: fixed;
  left: 50%;
  bottom: 14px;
  z-index: 20;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  width: min(calc(100% - 28px), 402px);
  padding: 6px;
  border: 1px solid rgba(32, 36, 45, 0.08);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 14px 36px rgba(32, 36, 45, 0.11);
  backdrop-filter: blur(18px);
  transform: translateX(-50%);
}

.tab {
  border: 0;
  border-radius: 18px;
  min-height: 46px;
  padding: 0 4px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  background: transparent;
  white-space: nowrap;
}

.tab.active {
  color: var(--whale-blue);
  background: rgba(87, 183, 183, 0.1);
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 92px;
  z-index: 50;
  max-width: min(360px, calc(100% - 32px));
  padding: 12px 16px;
  border-radius: 999px;
  color: white;
  font-weight: 800;
  text-align: center;
  background: rgba(23, 32, 51, 0.88);
  transform: translateX(-50%);
}

.hidden {
  display: none !important;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: center;
  padding: max(12px, env(safe-area-inset-top)) max(12px, env(safe-area-inset-right)) max(12px, env(safe-area-inset-bottom)) max(12px, env(safe-area-inset-left));
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  background: rgba(30, 36, 48, 0.32);
  backdrop-filter: blur(18px);
}

.portrait-modal {
  position: relative;
  width: min(100%, 390px);
  max-height: calc(100vh - 44px);
  overflow-y: auto;
  border-radius: 34px;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: 0 28px 90px rgba(30, 36, 48, 0.22);
}

.modal-close {
  position: absolute;
  right: 14px;
  top: 14px;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 999px;
  color: var(--ink);
  font-size: 22px;
  line-height: 1;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 10px 24px rgba(30, 36, 48, 0.1);
  cursor: pointer;
}

.share-card {
  max-height: calc(100vh - 44px);
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(87, 183, 183, 0.52) rgba(255, 255, 255, 0.36);
  scrollbar-gutter: stable;
  padding: 28px 22px 20px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 34px;
  background:
    radial-gradient(circle at 12% 12%, rgba(87, 183, 183, 0.28), transparent 32%),
    radial-gradient(circle at 84% 8%, rgba(255, 154, 61, 0.16), transparent 28%),
    linear-gradient(160deg, #fffdf9 0%, #f4faf4 54%, #fff7f8 100%);
}

.share-card::-webkit-scrollbar {
  width: 10px;
}

.share-card::-webkit-scrollbar-track {
  margin: 24px 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.32);
}

.share-card::-webkit-scrollbar-thumb {
  border: 3px solid rgba(255, 255, 255, 0.58);
  border-radius: 999px;
  background: linear-gradient(180deg, rgba(87, 183, 183, 0.68), rgba(92, 125, 131, 0.52));
}

.share-card::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, rgba(87, 183, 183, 0.82), rgba(92, 125, 131, 0.66));
}

.share-topline {
  margin-bottom: 18px;
  color: var(--whale-blue);
  font-size: 13px;
  font-weight: 900;
  text-align: center;
}

.share-visual {
  display: grid;
  place-items: center;
  width: 132px;
  height: 132px;
  margin: 0 auto 16px;
  border-radius: 38px;
  background: rgba(255, 255, 255, 0.65);
  box-shadow: 0 20px 50px rgba(87, 183, 183, 0.18);
  overflow: hidden;
}

.share-visual img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
}

/* 人格类型插画（半幅居中） */
.portrait-illustration-wrap {
  width: 50%;
  margin: 0 auto 16px;
  overflow: hidden;
  border-radius: 12px;
  cursor: zoom-in;
  transition: transform 180ms ease, box-shadow 180ms ease, filter 180ms ease;
}

.portrait-illustration-wrap:focus-visible {
  outline: 3px solid rgba(87, 183, 183, 0.36);
  outline-offset: 5px;
}

.portrait-illustration-wrap:active {
  transform: scale(0.985);
}

.portrait-illustration-wrap img {
  width: 100%;
  height: auto;
  display: block;
}

.portrait-illustration-wrap.is-persona-ui {
  width: min(54%, 320px);
  border-radius: 18px;
  box-shadow: 0 18px 48px rgba(42, 58, 46, 0.12);
}

.portrait-illustration-wrap.is-persona-ui:hover {
  transform: translateY(-2px);
  box-shadow: 0 24px 58px rgba(42, 58, 46, 0.16);
}

.share-card h2 {
  margin-bottom: 10px;
  font-size: 32px;
  line-height: 1.12;
  text-align: center;
}

.share-card > p {
  max-width: 280px;
  margin: 0 auto 16px;
  color: var(--muted);
  line-height: 1.75;
  text-align: center;
}

.share-tags {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin: 16px 0;
}

.share-tags span {
  padding: 8px 11px;
  border-radius: 999px;
  color: #3E9595;
  font-size: 12px;
  font-weight: 900;
  background: rgba(87, 183, 183, 0.22);
}

.modal-insight-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin: 16px 0;
}

.modal-insight-grid article {
  min-height: 86px;
  padding: 13px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.64);
  box-shadow: inset 0 0 0 1px rgba(32, 36, 45, 0.06);
}

.modal-insight-grid span {
  display: block;
  margin-bottom: 10px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
}

.modal-insight-grid strong {
  font-size: 15px;
  line-height: 1.35;
}

.share-detail {
  padding: 16px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: inset 0 0 0 1px rgba(30, 36, 48, 0.06);
}

.fun-detail {
  margin-top: 10px;
}

.share-detail h3 {
  margin-bottom: 8px;
  font-size: 17px;
}

.share-detail p {
  margin: 0;
  color: var(--muted);
  line-height: 1.75;
}

/* 画像弹窗改版：隐藏标签 chip / 四宫格 / 有趣解析块 / 性格详情小标题，
   仅保留 detail 富文本（性格揭秘报告） */
.portrait-modal .share-tags,
.portrait-modal .modal-insight-grid,
.portrait-modal .fun-detail,
.portrait-modal .share-detail h3 {
  display: none;
}

/* detail 富文本：保留 AI 输出的换行与 emoji 分段排版 */
#modalPortraitDetail {
  white-space: pre-wrap;
  text-align: left;
  line-height: 1.9;
  color: #2c3340;
  font-size: 14.5px;
}

.share-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 14px;
  color: var(--muted);
  font-size: 12px;
}

.share-footer-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.share-retake-btn {
  min-height: 34px;
  padding: 0 13px;
  border: 1px solid rgba(87, 183, 183, 0.36);
  border-radius: 999px;
  color: var(--whale-blue);
  font-size: 12px;
  font-weight: 800;
  background: rgba(255, 255, 255, 0.72);
  cursor: pointer;
  transition: background 160ms, border-color 160ms;
}

.share-retake-btn:hover {
  background: rgba(255, 255, 255, 0.92);
  border-color: rgba(87, 183, 183, 0.56);
}

.share-footer strong {
  color: var(--whale-blue);
  font-size: 17px;
  letter-spacing: 0.08em;
  line-height: 1;
}

.share-generate-btn {
  min-height: 34px;
  padding: 0 14px;
  border: 1px solid rgba(255, 255, 255, 0.78);
  border-radius: 999px;
  color: white;
  font-size: 12px;
  font-weight: 900;
  background:
    linear-gradient(135deg, #e98f86 0%, #d9a3a3 42%, #57B7B7 100%);
  box-shadow:
    0 10px 22px rgba(87, 183, 183, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.44);
}

.report-modal {
  position: relative;
  width: min(100%, 380px);
  max-height: calc(100vh - 36px);
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  padding: 22px;
  border-radius: 28px;
}

/* 首次加入匹配确认弹窗 */
.first-join-modal {
  text-align: center;
}

.first-join-modal h2 {
  font-size: 18px;
  font-weight: 900;
  margin-bottom: 8px;
}

.first-join-modal p {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 20px;
  line-height: 1.6;
}

/* 非开放高校阻拦落地页 */
.non-campus-gate {
  background: linear-gradient(160deg, #f4fff9 0%, #f0faf7 50%, #fffdf8 100%);
  border-radius: 28px;
  padding: 36px 28px 28px;
  width: min(calc(100% - 48px), 340px);
  max-height: calc(100vh - 32px);
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  box-shadow:
    0 8px 40px rgba(87, 183, 183, 0.18),
    0 2px 12px rgba(30, 36, 48, 0.08);
  border: 1px solid rgba(87, 183, 183, 0.2);
}

.gate-whale-wrap {
  width: 160px;
  margin: 0 auto 20px;
}

.gate-whale-img {
  width: 100%;
  height: auto;
  display: block;
  /* transparent PNG — floats on card background with no clipping */
  border-radius: 0;
  object-fit: contain;
}

.gate-body {
  padding: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
}

.gate-title {
  font-size: 26px;
  font-weight: 900;
  color: var(--ink);
  margin: 0 0 4px;
  letter-spacing: 0.02em;
}

.gate-school-notice {
  font-size: 15px;
  font-weight: 700;
  color: var(--ink);
  margin: 0 0 8px;
  opacity: 0.75;
}

.gate-sub {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.65;
  margin: 0 0 22px;
}

.gate-qr-block {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  background: rgba(87, 183, 183, 0.07);
  border: 1px solid rgba(87, 183, 183, 0.22);
  border-radius: 18px;
  padding: 18px 24px 16px;
  width: 100%;
  margin-bottom: 20px;
}

.gate-qr-img {
  width: 92px;
  height: 92px;
  background: white;
  border-radius: 10px;
  padding: 6px;
  box-shadow: 0 2px 10px rgba(74, 128, 112, 0.12);
}

.gate-qr-img svg {
  width: 100%;
  height: 100%;
  display: block;
}

.gate-qr-text {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.7;
  text-align: center;
  margin: 0;
}

.gate-back-btn {
  font-size: 12px;
  color: var(--muted);
  background: none;
  border: none;
  padding: 6px 16px;
  cursor: pointer;
  opacity: 0.55;
  letter-spacing: 0.02em;
  transition: opacity 0.15s;
}

.gate-back-btn:active {
  opacity: 0.3;
}

.share-preview-modal {
  display: flex;
  flex-direction: column;
  width: min(calc(100% - 32px), 430px);
  max-height: min(88vh, 760px);
  overflow: hidden;
  border-radius: 30px;
}

.share-preview-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-shrink: 0;
  padding: 18px 18px 10px 22px;
}

.share-preview-header h2 {
  margin: 0;
  color: var(--ink);
  font-size: 22px;
  font-weight: 800;
  line-height: 1.2;
}

.share-preview-close-btn {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 999px;
  font-size: 20px;
  line-height: 1;
  color: var(--ink);
  cursor: pointer;
  background: linear-gradient(145deg, rgba(255,255,255,0.9), rgba(232,252,247,0.56));
  box-shadow: 0 10px 22px rgba(68,120,113,0.1), inset 0 1px 0 rgba(255,255,255,0.9);
}

.share-preview-scroll {
  flex: 1;
  min-height: 0;
  padding: 0 20px 20px;
  overflow: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(87, 183, 183, 0.4) transparent;
}

.share-preview-modal p {
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
}

.share-preview-modal img {
  display: block;
  width: 100%;
  border-radius: 24px;
  box-shadow:
    0 20px 46px rgba(68, 120, 113, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.5);
}

.portrait-image-preview-backdrop {
  z-index: 260;
  background: rgba(36, 40, 38, 0.46);
}

.portrait-image-preview-card {
  position: relative;
  display: grid;
  place-items: center;
  width: min(calc(100% - 28px), 560px);
  max-height: calc(100dvh - 36px);
  padding: 18px;
  border-radius: 34px;
  overflow: visible;
  animation: modalCardIn 220ms cubic-bezier(.2,.8,.2,1);
}

.portrait-image-preview-card .share-preview-close-btn {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
}

.portrait-image-preview-card img {
  display: block;
  width: auto;
  max-width: 100%;
  max-height: calc(100dvh - 92px);
  object-fit: contain;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow:
    0 26px 68px rgba(34, 46, 42, 0.24),
    0 0 0 1px rgba(255, 255, 255, 0.7);
}

@keyframes modalCardIn {
  from { opacity: 0; transform: translateY(10px) scale(0.985); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.share-save-hint {
  margin: 10px 0 0 !important;
  font-size: 13px !important;
  color: var(--muted) !important;
  text-align: center;
}

.share-save-btn {
  display: flex;
  align-items: center;      /* 垂直居中 */
  justify-content: center;  /* 水平居中 */
  margin: 10px 0 2px;
  text-align: center;
  text-decoration: none;
  width: 100%;
  box-sizing: border-box;
}

.login-modal-card {
  position: relative;
  width: min(calc(100% - 30px), 420px);
}

.login-modal-card .modal-close {
  top: 18px;
  right: 18px;
}

.login-modal-card .login-card {
  margin: 0;
  padding-top: 64px;   /* 为右上角关闭按钮（bottom ≈ 56px）留出净空 */
  box-shadow: 0 28px 80px rgba(38, 52, 45, 0.22);
}

.edit-profile-modal {
  position: relative;
  width: min(calc(100% - 28px), 460px);
  max-height: calc(100vh - 36px);
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(87, 183, 183, 0.38) rgba(255, 255, 255, 0.3);
}

.edit-profile-modal::-webkit-scrollbar {
  width: 8px;
}

.edit-profile-modal::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: rgba(87, 183, 183, 0.34);
}

.edit-profile-modal form {
  display: grid;
  gap: 14px;
}

.edit-profile-modal .chip-grid {
  margin-top: 10px;
}

.edit-profile-modal.match-onboarding-profile {
  width: min(calc(100% - 20px), 430px);
  max-height: min(88vh, 690px);
  padding: 22px 22px 18px;
  border-radius: 30px;
}

.edit-profile-modal.match-onboarding-profile h2 {
  margin: 0 44px 6px 0;
  font-size: 24px;
  line-height: 1.16;
}

.edit-profile-modal.match-onboarding-profile > p {
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 13.5px;
  font-weight: 750;
  line-height: 1.55;
}

.edit-profile-modal.match-onboarding-profile form {
  gap: 10px;
}

.edit-profile-modal.match-onboarding-profile form > label,
.edit-profile-modal.match-onboarding-profile .two-grid label {
  display: grid;
  gap: 7px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 900;
}

.edit-profile-modal.match-onboarding-profile input,
.edit-profile-modal.match-onboarding-profile textarea,
.edit-profile-modal.match-onboarding-profile .ios-select-trigger {
  min-height: 48px;
  border-radius: 18px;
  font-size: 15px;
}

.edit-profile-modal.match-onboarding-profile input,
.edit-profile-modal.match-onboarding-profile .ios-select-trigger {
  padding: 0 16px;
}

.edit-profile-modal.match-onboarding-profile textarea {
  min-height: 90px;
  padding: 14px 16px;
  resize: vertical;
}

.edit-profile-modal.match-onboarding-profile .field-note {
  display: none;
}

.edit-profile-modal.match-onboarding-profile .field-name {
  margin: 0 0 8px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 900;
}

.edit-profile-modal.match-onboarding-profile .chip-grid {
  flex-wrap: nowrap;
  gap: 8px;
  max-width: 100%;
  margin: 0 -2px;
  padding: 0 2px 6px;
  overflow-x: auto;
  scrollbar-width: none;
}

.edit-profile-modal.match-onboarding-profile .chip-grid::-webkit-scrollbar {
  display: none;
}

.edit-profile-modal.match-onboarding-profile .chip {
  flex: 0 0 auto;
  padding: 8px 12px;
  font-size: 13px;
  font-weight: 850;
}

.edit-profile-modal.match-onboarding-profile .primary-btn {
  min-height: 52px;
  margin-top: 2px;
  border-radius: 22px;
}

@media (max-width: 420px), (max-height: 760px) {
  .edit-profile-modal.match-onboarding-profile {
    width: min(calc(100% - 14px), 410px);
    max-height: calc(100vh - 18px);
    padding: 18px 18px 16px;
  }

  .edit-profile-modal.match-onboarding-profile h2 {
    font-size: 22px;
  }

  .edit-profile-modal.match-onboarding-profile > p {
    font-size: 12.5px;
    line-height: 1.46;
  }

  .edit-profile-modal.match-onboarding-profile .two-grid {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  .edit-profile-modal.match-onboarding-profile input,
  .edit-profile-modal.match-onboarding-profile .ios-select-trigger {
    min-height: 44px;
  }

  .edit-profile-modal.match-onboarding-profile textarea {
    min-height: 74px;
  }
}

.report-modal h2 {
  margin-bottom: 8px;
  font-size: 26px;
  font-weight: 950;
}

.cancel-match-modal h2 {
  padding-right: 36px;
  font-size: 24px;
  line-height: 1.25;
}

.report-modal > p {
  margin-bottom: 16px;
  color: var(--muted);
  line-height: 1.7;
  white-space: pre-line;
}

.report-modal input[type="file"] {
  height: auto;
  padding: 13px;
}

.modal-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 16px;
}

.modal-actions .primary-btn,
.modal-actions .secondary-btn {
  width: 100%;
  min-width: 0;
}

.cancel-match-modal p {
  font-size: 15px;
}

.support-ticket-modal label,
.deactivate-modal label {
  display: grid;
  gap: 8px;
  margin-top: 14px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
}

.support-ticket-modal input,
.support-ticket-modal select,
.support-ticket-modal textarea,
.deactivate-modal input {
  width: 100%;
  min-height: 48px;
  border-radius: 18px;
  border: 1px solid rgba(80, 130, 130, 0.18);
  background: rgba(255, 255, 255, 0.72);
  padding: 0 14px;
  font-size: 15px;
  font-weight: 700;
  color: var(--ink);
  outline: none;
}

.support-ticket-modal textarea {
  min-height: 118px;
  padding-top: 14px;
  line-height: 1.6;
  resize: vertical;
}

.deactivate-checklist {
  display: grid;
  gap: 8px;
  margin: 14px 0 4px;
  padding: 12px;
  border-radius: 18px;
  background: rgba(255, 154, 61, 0.08);
  border: 1px solid rgba(255, 154, 61, 0.18);
}

.deactivate-checklist span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.deactivate-checklist span::before {
  content: "·";
  color: var(--coral, #E98F86);
  margin-right: 6px;
}

.danger-btn {
  color: #b04a4a;
}

@media (min-width: 680px) {
  body {
    padding: 22px 0;
  }

  .phone-shell {
    min-height: calc(100vh - 44px);
    border-radius: 38px;
    overflow: hidden;
    box-shadow: 0 28px 90px rgba(23, 32, 51, 0.16);
  }

  .view {
    padding-bottom: 76px;
  }
}

@media (max-width: 360px) {
  .view {
    padding-left: 16px;
    padding-right: 16px;
  }

  .top-bar {
    margin-left: -16px;
    margin-right: -16px;
    padding-left: 16px;
    padding-right: 16px;
  }

  .chat-header {
    margin-left: -16px;
    margin-right: -16px;
    padding-left: 16px;
    padding-right: 16px;
  }

  .portrait-hero,
  .qr-card {
    grid-template-columns: 1fr;
  }

  .two-grid,
  .insight-grid,
  .chat-confirm,
  .match-report-grid {
    grid-template-columns: 1fr;
  }
}

/* Homepage refresh: glossy whale-icon visual language */
.login-view {
  background:
    radial-gradient(circle at 50% 8%, rgba(255, 255, 255, 0.92), transparent 28%),
    radial-gradient(circle at 18% 36%, rgba(151, 236, 224, 0.36), transparent 34%),
    radial-gradient(circle at 86% 42%, rgba(247, 190, 156, 0.32), transparent 30%),
    radial-gradient(circle at 18% 72%, rgba(151, 236, 224, 0.22), transparent 24%),
    radial-gradient(circle at 86% 88%, rgba(247, 190, 156, 0.24), transparent 28%),
    linear-gradient(180deg, #fffdf7 0%, #f8fff9 44%, #fff8f0 72%, #fff0ec 100%);
}

.login-view::before {
  height: 585px;
  background:
    linear-gradient(180deg, rgba(255, 253, 248, 0) 0%, rgba(255, 253, 248, 0.14) 56%, rgba(250, 249, 246, 0.9) 100%),
    url("./assets/home-campus-bg.svg") center -54px / 122% auto no-repeat;
  opacity: 0.78;
}

.login-view::after {
  height: 100%;
  background:
    radial-gradient(ellipse at 50% 31%, rgba(255, 255, 255, 0.62) 0%, rgba(255, 255, 255, 0.44) 18%, transparent 38%),
    radial-gradient(circle at 48% 20%, rgba(255, 255, 255, 0.76), transparent 24%),
    radial-gradient(circle at 54% 78%, rgba(98, 217, 206, 0.16), transparent 16%),
    radial-gradient(circle at 22% 76%, rgba(255, 255, 255, 0.34), transparent 18%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.16) 0%, rgba(255, 250, 242, 0.1) 48%, rgba(255, 247, 242, 0.2) 100%);
}

.top-login-btn {
  top: 20px;
  right: 20px;
  min-height: 36px;
  padding: 0 15px;
  color: #51786f;
  font-weight: 850;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.82), rgba(255, 255, 255, 0.48));
  border: 1px solid rgba(255, 255, 255, 0.82);
  box-shadow:
    0 12px 26px rgba(68, 120, 113, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.96);
}

.brand-block {
  padding: 16px 4px 28px;
}

.brand-mark {
  position: relative;
  width: 140px;
  height: 140px;
  margin-bottom: 14px;
  background: transparent;
  box-shadow: none;
  overflow: visible;
}

.brand-mark img {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  display: block;
  /* transparent PNG — no border-radius or object-fit clipping */
  border-radius: 0;
  object-fit: contain;
}

.brand-mark::after {
  content: "";
  position: absolute;
  z-index: 2;
  left: 14px;
  right: 14px;
  bottom: 21px;
  height: 22px;
  background: url("data:image/svg+xml,%3Csvg width='92' height='22' viewBox='0 0 92 22' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M2 12.5C9 12.5 9 12.5 15 12.5C19 12.5 20.4 4.5 24 4.5C28.8 4.5 29.5 19 34 19C38.8 19 40.2 8.2 45 8.2C49.6 8.2 50.6 15.5 55.4 15.5C60.6 15.5 61.4 11 66.5 11H90' stroke='%23F09A8C' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M2 12.5C9 12.5 9 12.5 15 12.5C19 12.5 20.4 4.5 24 4.5C28.8 4.5 29.5 19 34 19C38.8 19 40.2 8.2 45 8.2C49.6 8.2 50.6 15.5 55.4 15.5C60.6 15.5 61.4 11 66.5 11H90' stroke='white' stroke-width='1.1' stroke-linecap='round' stroke-linejoin='round' opacity='.82'/%3E%3C/svg%3E") center / contain no-repeat;
  filter: drop-shadow(0 3px 7px rgba(240, 154, 140, 0.24));
  opacity: 0.86;
  transform-origin: 50% 50%;
  animation: hzSignalBreath 3.8s ease-in-out infinite;
  pointer-events: none;
}

@keyframes hzSignalBreath {
  0%,
  100% {
    opacity: 0.72;
    transform: translateY(0) scaleX(0.98);
  }

  50% {
    opacity: 0.96;
    transform: translateY(-1px) scaleX(1.02);
  }
}

.art-brand {
  position: relative;
  display: inline-block;
  margin: 10px auto 14px;
  font-family: "STXinwei", "华文新魏", "STXingkai", "华文行楷", "FZYaoti", "方正姚体",
    "Microsoft YaHei UI", "PingFang SC", sans-serif;
  font-size: clamp(54px, 14.8vw, 78px);
  font-weight: 800;
  line-height: 1.02;
  letter-spacing: 0.04em;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.68), rgba(255, 255, 255, 0) 34%),
    linear-gradient(112deg, #3E9595 0%, #57B7B7 32%, #8FD0D0 62%, #FF9A3D 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow:
    0 2px 0 rgba(255, 255, 255, 0.78),
    0 16px 28px rgba(38, 154, 145, 0.17);
  -webkit-text-stroke: 1px rgba(255, 255, 255, 0.54);
  filter:
    drop-shadow(0 1px 0 rgba(255, 255, 255, 0.95))
    drop-shadow(0 5px 0 rgba(61, 157, 150, 0.16));
  transform: none;
}

.art-brand::before {
  content: "52Hz";
  position: absolute;
  inset: 0;
  z-index: -1;
  color: rgba(255, 255, 255, 0.9);
  -webkit-text-stroke: 5px rgba(255, 255, 255, 0.64);
  filter: blur(0.4px);
}

.art-brand {
  font-family: "Arial Rounded MT Bold", "SF Pro Rounded", "Microsoft YaHei UI", "YouYuan",
    "幼圆", "PingFang SC", sans-serif;
  font-size: clamp(68px, 18vw, 96px);
  font-weight: 950;
  letter-spacing: 0.01em;
  line-height: 1;
  background:
    radial-gradient(circle at 78% 12%, rgba(255, 255, 255, 0.34), transparent 18%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.32) 0%, rgba(255, 255, 255, 0) 26%),
    linear-gradient(135deg, #3E9595 0%, #57B7B7 46%, #8FD0D0 72%, #FFB870 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-stroke: 0.1px rgba(255, 255, 255, 0.22);
  text-shadow:
    0 1px 0 rgba(255, 255, 255, 0.34),
    0 2px 0 rgba(31, 121, 108, 0.14),
    0 9px 16px rgba(24, 150, 140, 0.18);
  filter:
    drop-shadow(0 1px 0 rgba(255, 255, 255, 0.64))
    drop-shadow(0 7px 12px rgba(24, 150, 140, 0.16));
}

.art-brand::before {
  font-family: inherit;
  font-weight: inherit;
  letter-spacing: inherit;
  color: rgba(8, 127, 120, 0.08);
  -webkit-text-stroke: 1.6px rgba(255, 255, 255, 0.26);
  filter: none;
}

.brand-roman {
  margin-bottom: 18px;
  color: #5fa996;
  font-size: 12px;
  font-weight: 950;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.7);
}

.brand-copy {
  margin-top: 2px;
}

.brand-roman {
  color: #57a396;
  letter-spacing: 0.26em;
}

.brand-copy {
  color: #3E9595;
  font-size: clamp(12px, 3.2vw, 14px);
  font-weight: 600;
  letter-spacing: 0.06em;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.72);
}

.hero-cta {
  min-height: 54px;
  margin-top: 34px;
  border: 1px solid rgba(255, 255, 255, 0.66);
  background:
    radial-gradient(ellipse at 30% 10%, rgba(255, 255, 255, 0.5), transparent 38%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.26), rgba(255, 255, 255, 0) 42%),
    linear-gradient(135deg, #57B7B7 0%, #57B7B7 62%, #8FD0D0 100%);
  box-shadow:
    0 20px 34px rgba(43, 135, 127, 0.22),
    0 8px 18px rgba(255, 154, 61, 0.11),
    inset 0 1px 0 rgba(255, 255, 255, 0.62),
    inset 0 -8px 18px rgba(15, 103, 88, 0.1);
}

.hero-note {
  margin-top: 22px;
  color: rgba(101, 112, 116, 0.72);
  font-size: 12px;
}

.home-path-steps {
  width: min(100%, 420px);
  margin: 20px auto 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.home-path-steps article {
  min-height: 82px;
  padding: 12px 10px;
  border: 1px solid rgba(130, 203, 197, 0.42);
  border-radius: 20px;
  background:
    radial-gradient(circle at 20% 12%, rgba(255, 255, 255, 0.9), transparent 38%),
    rgba(255, 255, 255, 0.58);
  box-shadow: 0 12px 26px rgba(70, 120, 113, 0.1);
  display: grid;
  align-content: center;
  gap: 5px;
}

.home-step-no {
  display: inline-grid;
  place-items: center;
  width: 20px;
  height: 20px;
  margin: 0 auto 1px;
  border-radius: 999px;
  color: #9E6A45;
  font-size: 11px;
  font-weight: 950;
  background: linear-gradient(145deg, rgba(255, 239, 221, 0.95), rgba(255, 255, 255, 0.72));
  box-shadow: inset 0 0 0 1px rgba(232, 161, 125, 0.28);
}

.home-path-steps strong {
  color: #2E5552;
  font-size: 14px;
  font-weight: 900;
}

.home-path-steps span {
  color: rgba(101, 112, 116, 0.76);
  font-size: 11px;
  line-height: 1.35;
}

.password-login-help {
  margin-top: 2px;
  color: rgba(87, 112, 112, 0.72);
  font-size: 12px;
  line-height: 1.45;
}

.hero-login-hint {
  margin-top: 14px;
  font-size: 13px;
  color: rgba(101, 112, 116, 0.72);
  text-align: center;
}

.hero-login-hint a {
  color: #57B7B7;
  font-weight: 700;
  text-decoration: none;
}

.login-view .message-board {
  position: relative;
  margin-top: 8px;
  padding-bottom: 34px;
  isolation: isolate;
}

.login-view .message-board::before {
  content: "";
  position: absolute;
  z-index: 0;
  inset: -38px -18px -90px;
  background:
    radial-gradient(circle at 16% 10%, rgba(87, 183, 183, 0.28), transparent 22%),
    radial-gradient(circle at 90% 28%, rgba(240, 162, 133, 0.26), transparent 26%),
    radial-gradient(circle at 48% 92%, rgba(87, 183, 183, 0.24), transparent 28%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.36), rgba(255, 243, 237, 0.32));
  pointer-events: none;
}

.login-view .message-board::after {
  content: "";
  position: absolute;
  z-index: 0;
  left: -14px;
  right: -14px;
  top: 52px;
  height: 460px;
  opacity: 0.52;
  pointer-events: none;
  background:
    linear-gradient(90deg, transparent 0 12%, rgba(87, 183, 183, 0.36) 12% 13%, transparent 13% 100%),
    linear-gradient(108deg, transparent 0 39%, rgba(240, 162, 133, 0.28) 39% 40%, transparent 40% 100%),
    radial-gradient(circle at 15% 16%, rgba(87, 183, 183, 0.32) 0 18px, transparent 19px),
    radial-gradient(circle at 22% 14%, rgba(87, 183, 183, 0.22) 0 14px, transparent 15px),
    radial-gradient(circle at 86% 20%, rgba(240, 162, 133, 0.3) 0 18px, transparent 19px),
    radial-gradient(circle at 78% 16%, rgba(240, 162, 133, 0.2) 0 12px, transparent 13px),
    radial-gradient(circle at 52% 82%, rgba(87, 183, 183, 0.2) 0 44px, transparent 45px);
}

.login-view .section-title,
.login-view .bubble-list {
  position: relative;
  z-index: 1;
}

.login-view .section-title {
  margin-bottom: 12px;
  padding: 0 4px;
  color: #20242d;
  font-size: 20px;
  font-weight: 950;
}

.login-view .message-card {
  position: relative;
  width: min(94%, 348px);
  padding: 11px 76px 11px 12px;
  border-radius: 22px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.84), rgba(255, 255, 255, 0.58));
  box-shadow:
    0 18px 34px rgba(68, 120, 113, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(16px);
}

.login-view .message-card.right {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.82), rgba(231, 252, 246, 0.54));
}

.login-view .user-avatar {
  width: 40px;
  height: 40px;
  border-radius: 17px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.26), rgba(255, 255, 255, 0) 34%),
    linear-gradient(135deg, #FF9A3D, #57B7B7);
  box-shadow:
    0 10px 20px rgba(255, 154, 61, 0.16),
    inset 0 1px 0 rgba(255, 255, 255, 0.42);
}

.login-view .message-meta strong {
  font-size: 14px;
  font-weight: 950;
}

.login-view .message-card.right .message-meta strong {
  color: #287f79;
}

.login-view .message-meta span {
  min-height: 22px;
  color: #4e8d82;
  background:
    linear-gradient(145deg, rgba(222, 249, 242, 0.9), rgba(255, 244, 229, 0.62));
  border: 1px solid rgba(255, 255, 255, 0.72);
}

.login-view .message-card p {
  color: #37424a;
  font-size: 13px;
  line-height: 1.48;
}

.message-like {
  position: absolute;
  top: 12px;
  right: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-height: 28px;
  padding: 4px 9px;
  border-radius: 999px;
  color: #3E9595;
  font-size: 11px;
  font-weight: 900;
  white-space: nowrap;
  background:
    linear-gradient(145deg, rgba(222, 249, 242, 0.9), rgba(255, 244, 229, 0.62));
  border: 1px solid rgba(255, 255, 255, 0.72);
  box-shadow:
    0 8px 16px rgba(47, 143, 129, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.96);
  cursor: pointer;
}

.declaration-like::before {
  content: "♥";
  margin-right: 3px;
  color: #FF9A3D;
  font-weight: 950;
}

.message-like-icon {
  width: 13px;
  height: 13px;
  color: var(--home-gold, #D6A64B);
  overflow: visible;
  display: block;
  transform-box: fill-box;
  transform-origin: center;
  transition: transform 180ms cubic-bezier(.2, .8, .2, 1), filter 180ms ease;
}

.message-like-icon path {
  fill: rgba(214, 166, 75, 0.12);
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: fill 180ms ease, stroke 180ms ease;
}

.login-view .login-card {
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 28px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.88), rgba(230, 252, 247, 0.62));
  box-shadow:
    0 22px 45px rgba(68, 120, 113, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.92);
}

/* Global visual skin synced with the 52Hz homepage */
.phone-shell {
  background:
    radial-gradient(circle at 8% 4%, rgba(255, 154, 61, 0.22), transparent 28%),
    radial-gradient(circle at 94% 14%, rgba(255, 154, 61, 0.2), transparent 28%),
    linear-gradient(180deg, rgba(255, 253, 247, 0.82), rgba(255, 246, 240, 0.72));
}

.view {
  position: relative;
  overflow: hidden;
}

.view:not(.login-view) {
  background:
    radial-gradient(circle at 16% 8%, rgba(255, 154, 61, 0.28), transparent 28%),
    radial-gradient(circle at 88% 22%, rgba(255, 154, 61, 0.2), transparent 30%),
    radial-gradient(circle at 52% 88%, rgba(255, 154, 61, 0.16), transparent 28%),
    linear-gradient(180deg, #fffdf7 0%, #f8fff9 48%, #fff0ec 100%);
}

.view:not(.login-view)::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(255, 253, 248, 0.03) 0%, rgba(255, 253, 248, 0.14) 58%, rgba(250, 249, 246, 0.86) 100%),
    url("./assets/home-campus-bg.svg") center -68px / 128% auto no-repeat;
  opacity: 0.22;
}

.view:not(.login-view)::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse at 50% 10%, rgba(255, 255, 255, 0.48), transparent 28%),
    radial-gradient(circle at 18% 72%, rgba(255, 255, 255, 0.22), transparent 20%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.12), rgba(255, 247, 242, 0.16));
}

.view:not(.login-view) > * {
  position: relative;
  z-index: 1;
}

#communityView {
  min-height: inherit;
  padding: 0;
}

#communityView #treehole-root,
#communityView .treehole-app {
  min-height: 100%;
}

.glass-card:not(.match-choice):not(.result-waiting-card):not(.ad-card),
.form-card,
.quiz-card,
.analysis-card,
.settings-card,
.status-card,
.match-result,
.history-card,
.contact-card,
.qr-card,
.account-card {
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 28px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.86), rgba(232, 252, 247, 0.5));
  box-shadow:
    0 20px 40px rgba(68, 120, 113, 0.1),
    0 8px 18px rgba(255, 154, 61, 0.05),
    inset 0 1px 0 rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(18px);
}

.top-bar,
.chat-header {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.82), rgba(232, 252, 247, 0.5));
  border-bottom: 1px solid rgba(255, 255, 255, 0.62);
  box-shadow: 0 12px 28px rgba(68, 120, 113, 0.08);
  backdrop-filter: blur(18px);
}

input,
select,
textarea,
.ios-select-trigger {
  border: 1px solid rgba(255, 255, 255, 0.74);
  border-radius: 18px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.82), rgba(246, 250, 244, 0.64));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.9),
    0 8px 18px rgba(68, 120, 113, 0.04);
}

input:focus,
select:focus,
textarea:focus,
.ios-select.open .ios-select-trigger {
  border-color: rgba(79, 196, 185, 0.46);
  background: rgba(255, 255, 255, 0.94);
  box-shadow:
    0 0 0 4px rgba(79, 196, 185, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.95);
}

.ios-select-menu {
  border: 1px solid rgba(255, 255, 255, 0.76);
  border-radius: 22px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.94), rgba(232, 252, 247, 0.72));
  box-shadow: 0 20px 42px rgba(68, 120, 113, 0.13);
}

.primary-btn {
  border: 1px solid rgba(255, 255, 255, 0.58);
  background:
    radial-gradient(ellipse at 30% 10%, rgba(255, 255, 255, 0.46), transparent 38%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0) 42%),
    linear-gradient(135deg, #57B7B7 0%, #57B7B7 62%, #8FD0D0 100%);
  box-shadow:
    0 16px 30px rgba(43, 135, 127, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.58);
}

.secondary-btn,
.ghost-btn,
.text-btn {
  border: 1px solid rgba(255, 255, 255, 0.7);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.82), rgba(232, 252, 247, 0.5));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.tab-bar {
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 28px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.9), rgba(232, 252, 247, 0.62));
  box-shadow:
    0 18px 38px rgba(68, 120, 113, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.94);
}

.tab.active {
  color: #3E9595;
  background:
    linear-gradient(145deg, rgba(222, 249, 242, 0.9), rgba(255, 244, 229, 0.62));
}

.section-icon,
.portrait-avatar,
.small-avatar,
.mini-avatar,
.share-visual {
  box-shadow:
    0 16px 32px rgba(68, 120, 113, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.44);
}

.modal-backdrop {
  background:
    radial-gradient(circle at 24% 18%, rgba(255, 154, 61, 0.18), transparent 26%),
    radial-gradient(circle at 80% 78%, rgba(255, 154, 61, 0.16), transparent 28%),
    rgba(32, 36, 45, 0.34);
  backdrop-filter: blur(12px);
}

.portrait-modal,
.report-modal,
.edit-profile-modal,
.login-modal-card .login-card {
  border: 1px solid rgba(255, 255, 255, 0.74);
  border-radius: 32px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.9), rgba(232, 252, 247, 0.66));
  box-shadow:
    0 28px 80px rgba(38, 52, 45, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(20px);
}

.modal-close,
.icon-btn {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.9), rgba(232, 252, 247, 0.56));
  border: 1px solid rgba(255, 255, 255, 0.72);
  box-shadow:
    0 10px 22px rgba(68, 120, 113, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.match-choice {
  border: 1px solid rgba(255, 255, 255, 0.62);
  box-shadow:
    0 22px 42px rgba(68, 120, 113, 0.13),
    0 8px 18px rgba(255, 154, 61, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.36),
    inset 0 -18px 32px rgba(23, 32, 51, 0.06);
  overflow: hidden;
}

.match-choice::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  background:
    radial-gradient(ellipse at 18% 6%, rgba(255, 255, 255, 0.34), transparent 34%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0) 42%);
}

.match-choice.dating {
  background:
    radial-gradient(circle at 84% 12%, rgba(255, 255, 255, 0.24), transparent 34%),
    radial-gradient(circle at 18% 12%, rgba(255, 255, 255, 0.18), transparent 28%),
    linear-gradient(135deg, #FF9A3D 0%, #f2b48f 58%, #f2c58f 100%);
}

.match-choice.friendship {
  background:
    radial-gradient(circle at 84% 12%, rgba(255, 255, 255, 0.22), transparent 34%),
    radial-gradient(circle at 18% 12%, rgba(255, 255, 255, 0.18), transparent 28%),
    linear-gradient(135deg, #8FD0D0 0%, #5FB5B5 52%, #57B7B7 100%);
}

.match-side-controls {
  filter: drop-shadow(0 10px 18px rgba(32, 36, 45, 0.1));
}

.join-badge,
.buddy-pref-toggle,
.match-choice .countdown {
  border: 1px solid rgba(255, 255, 255, 0.62);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.58),
    0 10px 18px rgba(32, 36, 45, 0.08);
}

/* Match page layout polish */
#matchView .top-bar {
  padding: 16px 32px 18px;
}

#matchView .heading-with-icon {
  gap: 11px;
}

#matchView .section-icon svg {
  width: 28px;
  height: 28px;
}

#matchView .match-heading {
  font-size: 28px;
  line-height: 1.04;
}

#matchView .page-subtitle {
  margin-top: 5px;
  font-size: 13px;
  line-height: 1.45;
}

#matchView .match-options {
  gap: 18px;
  margin-top: 18px;
}

#matchView .match-choice {
  min-height: 122px;
  padding: 22px 168px 20px 78px;
  border-radius: 24px;
}

#matchView .choice-title {
  margin-bottom: 7px;
  font-size: 19px;
  line-height: 1.1;
}

#matchView .match-choice strong {
  font-size: 13px;
}

#matchView .match-choice em {
  max-width: 210px;
  margin-top: 10px;
  font-size: 13px;
  line-height: 1.5;
}

#matchView .match-side-controls {
  right: 14px;
  gap: 5px;
}

#matchView .card-countdown {
  min-width: 148px;
  padding: 14px 15px;
  border-radius: 20px;
  font-size: 18px;
}

#matchView .card-countdown.ready {
  min-width: 178px;
  padding-inline: 17px;
  font-size: 13px;
}

#matchView .match-detail-hint {
  margin-top: -1px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 10px;
  font-weight: 750;
  letter-spacing: 0.02em;
}

#matchView .match-pill-row {
  gap: 7px;
}

#matchView .match-side-controls .joined-label,
#matchView .match-side-controls .buddy-prefs-toggle {
  width: 68px;
  min-height: 29px;
  font-size: 12px;
}

#matchView .check-ring {
  left: 24px;
  width: 42px;
  height: 42px;
  border-width: 2px;
  border-color: rgba(255, 255, 255, 0.96);
  background:
    radial-gradient(circle at 32% 24%, rgba(255, 255, 255, 0.96), transparent 18%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.72), rgba(236, 249, 244, 0.48));
  box-shadow:
    0 8px 18px rgba(32, 36, 45, 0.12),
    0 0 0 7px rgba(255, 255, 255, 0.13),
    inset 0 1px 0 rgba(255, 255, 255, 0.92);
}

#matchView .match-choice:not(.joined) .check-ring::before {
  content: "";
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.56);
  box-shadow: 0 0 0 5px rgba(255, 255, 255, 0.12);
}

#matchView .match-choice.joined .check-ring::after {
  left: 13px;
  top: 13px;
}

#matchView .portrait-hero {
  grid-template-columns: 86px 1fr;
  gap: 18px;
  align-items: center;
  margin-top: 26px;
  padding: 20px;
  border-radius: 28px;
}

#matchView .portrait-avatar {
  width: 86px;
  height: 129px;   /* 2:3 比例 */
  border-radius: 27px;
  font-size: 31px;
}

#matchView .portrait-title-btn {
  margin-bottom: 7px;
  font-size: 21px;
  line-height: 1.16;
}

#matchView .portrait-title-btn::after {
  margin-top: 5px;
  font-size: 11px;
}

#matchView .portrait-hero p:not(.eyebrow) {
  max-width: 250px;
  font-size: 14px;
  line-height: 1.72;
}

.portrait-retake-btn {
  width: auto;
  min-height: 34px;
  margin-top: 12px;
  padding: 0 18px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.76);
  color: white;
  font-size: 12px;
  font-weight: 900;
  background:
    linear-gradient(135deg, #e98f86 0%, #d9a3a3 42%, #57B7B7 100%);
  box-shadow:
    0 12px 24px rgba(87, 183, 183, 0.16),
    0 6px 14px rgba(255, 154, 61, 0.16),
    inset 0 1px 0 rgba(255, 255, 255, 0.42);
}

.check-ring {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.96), rgba(232, 252, 247, 0.68));
  border: 1px solid rgba(255, 255, 255, 0.78);
  box-shadow:
    0 12px 24px rgba(32, 36, 45, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.92);
}

.result-waiting-card {
  border: 1px solid rgba(255, 255, 255, 0.62);
  border-radius: 24px;
  box-shadow:
    0 22px 42px rgba(68, 120, 113, 0.13),
    0 8px 18px rgba(255, 154, 61, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.36),
    inset 0 -18px 32px rgba(23, 32, 51, 0.06);
  overflow: hidden;
}

.result-waiting-card::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  background:
    radial-gradient(ellipse at 18% 6%, rgba(255, 255, 255, 0.34), transparent 34%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0) 42%);
}

.result-waiting-card[data-match-type="dating"] {
  background:
    radial-gradient(circle at 84% 12%, rgba(255, 255, 255, 0.24), transparent 34%),
    radial-gradient(circle at 18% 12%, rgba(255, 255, 255, 0.18), transparent 28%),
    linear-gradient(135deg, #FF9A3D 0%, #f2b48f 58%, #f2c58f 100%);
}

.result-waiting-card[data-match-type="friendship"] {
  background:
    radial-gradient(circle at 84% 12%, rgba(255, 255, 255, 0.22), transparent 34%),
    radial-gradient(circle at 18% 12%, rgba(255, 255, 255, 0.18), transparent 28%),
    linear-gradient(135deg, #8FD0D0 0%, #5FB5B5 52%, #57B7B7 100%);
}

.result-waiting-card .big-countdown,
.result-waiting-card .card-countdown {
  border: 1px solid rgba(255, 255, 255, 0.62);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.58),
    0 10px 18px rgba(32, 36, 45, 0.08);
}

/* Result page refinement */
#activityView::before {
  opacity: 0.15;
  background:
    linear-gradient(180deg, rgba(255, 253, 248, 0.1) 0%, rgba(255, 253, 248, 0.28) 58%, rgba(250, 249, 246, 0.9) 100%),
    url("./assets/home-campus-bg.svg") center -86px / 118% auto no-repeat;
}

#activityView::after {
  background:
    radial-gradient(ellipse at 50% 6%, rgba(255, 255, 255, 0.58), transparent 28%),
    radial-gradient(circle at 15% 68%, rgba(255, 154, 61, 0.1), transparent 24%),
    radial-gradient(circle at 88% 76%, rgba(255, 154, 61, 0.08), transparent 22%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.2), rgba(255, 249, 244, 0.18));
}

#activityView .result-waiting-list {
  gap: 16px;
  margin: 18px 0 22px;
}

#activityView .result-waiting-card {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 118px;
  padding: 20px 178px 20px 76px;
  border-radius: 24px;
  cursor: pointer;
  transition:
    transform 160ms ease,
    box-shadow 160ms ease,
    filter 160ms ease;
}

#activityView .result-waiting-card:hover {
  filter: saturate(1.03);
  box-shadow:
    0 24px 46px rgba(68, 120, 113, 0.15),
    0 8px 20px rgba(255, 154, 61, 0.09),
    inset 0 1px 0 rgba(255, 255, 255, 0.38),
    inset 0 -18px 32px rgba(23, 32, 51, 0.06);
}

#activityView .result-waiting-card:active {
  transform: scale(0.99);
}

#activityView .result-waiting-card .result-ring {
  position: absolute;
  left: 22px;
  top: 50%;
  transform: translateY(-50%);
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 30% 24%, rgba(255, 255, 255, 0.98), transparent 18%),
    linear-gradient(145deg, #fffdf7, rgba(246, 246, 242, 0.86));
  border: 1px solid rgba(255, 255, 255, 0.86);
  box-shadow:
    0 4px 12px rgba(32, 36, 45, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.92);
}

#activityView .result-waiting-card .result-ring svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: #c97a7a;
  stroke-width: 2.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

#activityView .result-waiting-card[data-match-type="friendship"] .result-ring svg {
  stroke: #3E9595;
}

#activityView .result-waiting-card .choice-title {
  margin-bottom: 7px;
  font-size: 19px;
  line-height: 1.1;
}

#activityView .result-waiting-card strong,
#activityView .result-waiting-card em {
  display: block;
}

#activityView .result-waiting-card strong {
  font-size: 13px;
  opacity: 0.92;
}

#activityView .result-waiting-card em {
  max-width: 210px;
  margin-top: 10px;
  font-size: 13px;
  font-style: normal;
  opacity: 0.9;
}

#activityView .result-waiting-card .match-side-controls {
  right: 14px;
  gap: 5px;
}

#activityView .result-waiting-card .card-countdown {
  min-width: 122px;
  padding: 14px 15px;
  font-size: 18px;
  background:
    radial-gradient(circle at 18% 20%, rgba(255, 255, 255, 0.4), transparent 24%),
    linear-gradient(135deg, #d98996 0%, #b98aa5 52%, #8fa6b3 100%);
  border: 1px solid rgba(255, 255, 255, 0.62);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.58),
    0 10px 18px rgba(32, 36, 45, 0.08);
}

#activityView .result-waiting-card .card-countdown.ready {
  min-width: 0;
  padding: 13px 16px;
  font-size: 13px;
  white-space: nowrap;
  line-height: 1.3;
}

#activityView .history-card {
  margin-inline: 0;
  padding: 22px;
  border-radius: 30px;
  gap: 16px;
}

#activityView .history-head h3 {
  font-size: 21px;
  line-height: 1.2;
}

#activityView .history-head p {
  color: rgba(101, 112, 126, 0.92);
  font-size: 13px;
  font-weight: 800;
}

#activityView .history-list {
  gap: 12px;
}

#activityView .history-item,
#activityView .history-empty-card {
  border-radius: 19px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.72), rgba(246, 250, 244, 0.55));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.82),
    0 10px 22px rgba(68, 120, 113, 0.04);
}

#activityView .history-empty-card {
  display: grid;
  place-items: center;
  min-height: 76px;
  padding: 20px 18px;
  color: rgba(101, 112, 126, 0.82);
  font-size: 14px;
  font-weight: 850;
}

/* 52Hz树洞 — declaration board (now in communityView) */
#communityView .declaration-board {
  margin-inline: 0;
  padding: 22px;
  border-radius: 30px;
  gap: 16px;
}

#communityView .declaration-head h3 {
  font-size: 21px;
  line-height: 1.2;
}

#communityView .declaration-head p {
  color: rgba(101, 112, 126, 0.92);
  font-size: 13px;
  font-weight: 800;
}

#communityView #declarationInput {
  min-height: 78px;
  padding: 18px;
  resize: vertical;
}

#communityView .declaration-submit {
  min-height: 46px;
}

#communityView .declaration-list {
  gap: 12px;
}

#communityView .declaration-item {
  padding: 15px 16px;
  border-radius: 19px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.72), rgba(246, 250, 244, 0.55));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.82),
    0 10px 22px rgba(68, 120, 113, 0.04);
}

#communityView .declaration-item strong {
  color: var(--ink);
  font-size: 13px;
  font-weight: 900;
}

#communityView .declaration-item p {
  color: var(--muted);
  font-size: 14px;
}

#communityView .declaration-more {
  width: min(86%, 340px);
  min-height: 48px;
  border-radius: 999px;
  color: var(--ink);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.78), rgba(232, 252, 247, 0.52));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.9),
    0 12px 24px rgba(68, 120, 113, 0.06);
}

/* 搭子社群 section heading within tree hole page */
.community-section-head {
  margin: 28px 0 4px;
}

.community-section-head h3 {
  font-size: 18px;
  font-weight: 950;
  color: var(--ink);
  margin-bottom: 3px;
}

.community-section-head p {
  font-size: 13px;
  color: var(--muted);
  font-weight: 800;
}

#activityView .ad-card {
  margin: 18px 0 20px;
  border-radius: 28px;
  border: 1px solid rgba(255, 255, 255, 0.74);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.72), rgba(255, 236, 226, 0.58));
  box-shadow:
    0 18px 36px rgba(68, 120, 113, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.86);
  backdrop-filter: blur(18px);
}

#activityView .ad-card img {
  min-height: 112px;
}

.activity-hero-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 14px 0 12px;
  padding: 13px 18px;
  border-radius: 28px;
  color: white;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.62);
  background:
    radial-gradient(circle at 86% 10%, rgba(255, 247, 230, 0.46), transparent 32%),
    radial-gradient(circle at 18% 10%, rgba(241, 232, 255, 0.28), transparent 30%),
    radial-gradient(circle at 92% 82%, rgba(255, 209, 102, 0.72), transparent 36%),
    linear-gradient(135deg, var(--dinner-primary) 0%, #8f66ff 46%, var(--dinner-secondary) 100%);
  box-shadow:
    0 22px 42px rgba(68, 120, 113, 0.13),
    0 10px 22px rgba(124, 77, 255, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.36),
    inset 0 -18px 32px rgba(23, 32, 51, 0.08);
}

.activity-hero-card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  background:
    radial-gradient(ellipse at 18% 6%, rgba(255, 255, 255, 0.34), transparent 34%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0) 42%),
    linear-gradient(110deg, transparent 36%, rgba(255, 247, 230, 0.22) 49%, transparent 64%);
}

.activity-hero-card::after {
  content: "";
  position: absolute;
  inset: auto -28px -42px auto;
  width: 180px;
  height: 120px;
  border: 2px solid rgba(255, 255, 255, 0.22);
  border-radius: 50%;
  transform: rotate(-12deg);
}

.activity-hero-copy {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 8px;
  min-width: 0;
}

.activity-hero-copy h3 {
  margin: 0;
  color: white;
  font-size: 20px;
  font-weight: 950;
  line-height: 1.15;
  letter-spacing: 0;
  white-space: nowrap;   /* 标题保持一行，不与右侧日期徽章重叠 */
}

.activity-title-period {
  display: block;
  margin-top: 1px;
}

.activity-hero-copy .activity-slogan {
  margin: 0;
  color: rgba(255, 255, 255, 0.96);
  font-size: 13px;
  font-weight: 950;
  line-height: 1.55;
  text-shadow: 0 1px 0 rgba(32, 36, 45, 0.12);
}

.activity-hero-copy .activity-fee-note {
  width: fit-content;
  margin: 2px 0 0;
  padding: 7px 10px;
  border: 1px solid rgba(255, 255, 255, 0.38);
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.96);
  background: rgba(255, 247, 230, 0.18);
  font-size: 11px;
  font-weight: 950;
  line-height: 1.1;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.22);
}

.activity-hero-side {
  position: relative;
  z-index: 1;
  display: grid;
  justify-items: center;
  gap: 2px;
  min-width: 112px;
  padding: 10px 14px;
  border: 1px solid rgba(255, 255, 255, 0.36);
  border-radius: 20px;
  background: rgba(255, 247, 230, 0.22);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.28);
  backdrop-filter: blur(14px);
}

.activity-hero-side .activity-date {
  color: rgba(255, 255, 255, 0.9);
  font-size: 12px;
  font-weight: 950;
  line-height: 1.15;
  white-space: nowrap;
}

.activity-hero-side .activity-weekdays {
  color: rgba(255, 255, 255, 0.78);
  font-size: 10px;
  font-weight: 900;
  line-height: 1.2;
  white-space: nowrap;
}

.activity-hero-side strong {
  color: white;
  font-size: 23px;
  font-weight: 950;
  line-height: 1.1;
}

.activity-hero-side small {
  color: rgba(255, 255, 255, 0.84);
  font-size: 10px;
  font-weight: 850;
  text-align: center;
  line-height: 1.35;
}

.activity-status-btn {
  position: relative;
  z-index: 1;
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  min-height: 48px;
  margin-top: 2px;
  padding: 0 16px 0 18px;
  border: 0;
  border-radius: 999px;
  color: var(--dinner-text);
  background:
    linear-gradient(145deg, rgba(255, 247, 230, 0.96), rgba(241, 232, 255, 0.9));
  box-shadow:
    0 12px 24px rgba(49, 36, 63, 0.13),
    inset 0 1px 0 rgba(255, 255, 255, 0.94);
}

.activity-status-btn span,
.activity-status-btn b {
  font-size: 13px;
  font-weight: 950;
  line-height: 1;
}

.activity-status-btn b::after {
  content: "›";
  margin-left: 7px;
  font-size: 17px;
  line-height: 0;
}

/* ── 盲盒饭局活动卡（重构版）────────────────────────────── */
.activity-hero-top {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.activity-subtitle {
  margin: 6px 0 0;
  color: rgba(255, 255, 255, 0.96);
  font-size: 12.5px;
  font-weight: 850;
  letter-spacing: 0.3px;
  text-shadow: 0 1px 0 rgba(32, 36, 45, 0.12);
}

.activity-tags {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;           /* 三个小卡横排 */
  align-items: center;
  gap: 7px;
}

.activity-tag {
  padding: 5px 11px;
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 999px;
  background: rgba(255, 247, 230, 0.2);
  color: rgba(255, 255, 255, 0.97);
  font-size: 11px;
  font-weight: 900;
  line-height: 1.1;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.22);
}

.activity-boundary-note {
  position: relative;
  z-index: 1;
  margin: 0;
  color: rgba(255, 255, 255, 0.94);
  font-size: 12px;
  font-weight: 750;
  line-height: 1.5;
}

.activity-hero-actions {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 12px;
}

.activity-primary-btn {
  flex: 1;
  min-height: 48px;
  border: 0;
  border-radius: 999px;
  color: var(--dinner-text, #3a2b52);
  background: linear-gradient(145deg, rgba(255, 247, 230, 0.98), rgba(241, 232, 255, 0.94));
  font-size: 14px;
  font-weight: 950;
  cursor: pointer;
  box-shadow: 0 12px 24px rgba(49, 36, 63, 0.16), inset 0 1px 0 rgba(255, 255, 255, 0.94);
}

.activity-flow-link {
  flex-shrink: 0;
  padding: 0 6px;
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.96);
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ── 信任流程卡 ──────────────────────────────────────── */
.activity-flow-card {
  display: flex;
  align-items: stretch;
  justify-content: space-between;
  gap: 6px;
  margin: 0 0 16px;
  padding: 16px 14px;
  border-radius: 22px;
  border: 1px solid var(--line, #e6efe9);
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 10px 24px rgba(68, 120, 113, 0.08);
}

.activity-flow-step {
  display: grid;
  justify-items: center;
  gap: 3px;
  text-align: center;
  flex: 1;
}

.activity-flow-ico { font-size: 22px; line-height: 1; }
.activity-flow-step strong { font-size: 13px; font-weight: 900; color: var(--ink, #25433b); }
.activity-flow-step small { font-size: 10.5px; color: var(--muted, #7a8d86); line-height: 1.3; }
.activity-flow-arrow { align-self: center; color: var(--brand, #38b59b); font-weight: 900; }

.signup-step-no {
  display: inline-block;
  margin-right: 6px;
  color: var(--brand, #38b59b);
  font-weight: 950;
}

/* ── 我的饭局 sheet ──────────────────────────────────── */
.my-dinner-body { display: grid; gap: 14px; padding: 4px 2px 8px; }
.my-dinner-flow { margin: 0; padding-left: 0; list-style: none; display: grid; gap: 12px; counter-reset: step; }
.my-dinner-flow li { position: relative; padding-left: 38px; }
.my-dinner-flow li::before {
  counter-increment: step; content: counter(step);
  position: absolute; left: 0; top: 0;
  width: 26px; height: 26px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--brand-soft, #e8f7f2); color: var(--brand, #38b59b);
  font-weight: 950; font-size: 13px;
}
.my-dinner-flow li strong { display: block; font-size: 14px; color: var(--ink, #25433b); }
.my-dinner-flow li span { font-size: 12px; color: var(--muted, #7a8d86); line-height: 1.45; }

.my-dinner-status-card {
  padding: 16px; border-radius: 18px;
  background: var(--brand-soft, #e8f7f2);
  display: grid; gap: 6px;
}
.my-dinner-badge {
  width: fit-content; padding: 4px 12px; border-radius: 999px;
  background: var(--brand, #38b59b); color: #fff; font-size: 12px; font-weight: 900;
}
.my-dinner-status-card p { margin: 0; font-weight: 850; color: var(--ink, #25433b); }
.my-dinner-status-card small { color: var(--muted, #7a8d86); font-size: 12px; }
/* 状态卡 + 右侧群码 */
.my-dinner-status-card.my-dinner-status-flex { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; }
.my-dinner-status-text { flex: 1; min-width: 0; display: grid; gap: 6px; align-content: start; }
.my-dinner-status-qr { flex: 0 0 auto; width: 116px; display: grid; gap: 6px; justify-items: center; text-align: center; }
.my-dinner-status-qr .my-dinner-qr { width: 116px; height: 116px; }
.my-dinner-status-qr small { font-size: 11px; line-height: 1.4; color: var(--muted, #7a8d86); }
.my-dinner-qr-pending {
  width: 116px; height: 116px; display: grid; place-items: center;
  border: 1px dashed rgba(56,181,155,.4); border-radius: 12px;
  background: rgba(56,181,155,.06); font-size: 30px;
}

.my-dinner-block { padding: 14px 16px; border-radius: 16px; border: 1px solid var(--line, #e6efe9); background: #fff; display: grid; gap: 6px; }
.my-dinner-block h4 { margin: 0; font-size: 12px; color: var(--muted, #7a8d86); font-weight: 800; }
.my-dinner-table { margin: 0; font-size: 28px; font-weight: 950; color: var(--brand, #38b59b); }
.my-dinner-identity { margin: 0; font-size: 18px; font-weight: 950; color: var(--ink, #25433b); }
.my-dinner-role { margin: 0; font-size: 13px; color: var(--ink, #25433b); }
.my-dinner-task { margin: 4px 0 0; font-size: 12.5px; color: var(--muted, #7a8d86); line-height: 1.5; }
/* 身份卡：左文案 + 右抽题按钮 */
.my-dinner-role-card { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.my-dinner-role-text { display: grid; gap: 6px; min-width: 0; }
.my-dinner-draw-actions { display: grid; gap: 8px; flex-shrink: 0; align-content: center; }
.topic-draw-btn-mini { white-space: nowrap; padding: 9px 14px; border: 0; border-radius: 999px; background: var(--brand, #38b59b); color: #fff; font-size: 13px; font-weight: 850; cursor: pointer; box-shadow: 0 8px 18px -8px rgba(56,181,155,.6); transition: transform .15s ease, opacity .15s ease; }
.topic-draw-btn-mini:active { transform: scale(.96); }
.topic-draw-btn-mini:disabled { opacity: .5; }
.my-dinner-qr { width: 180px; height: 180px; object-fit: contain; align-self: center; border-radius: 12px; background: #fff; }
.my-dinner-welcome { margin: 0; font-size: 12px; color: var(--muted, #7a8d86); white-space: pre-line; line-height: 1.5; }
.my-dinner-hint { margin: 0; font-size: 12.5px; color: var(--muted, #7a8d86); line-height: 1.5; }
.detail-row { display: flex; justify-content: space-between; gap: 12px; padding: 7px 0; border-bottom: 1px solid var(--line, #eef3f0); }
.detail-row:last-child { border-bottom: 0; }
.detail-row span { color: var(--muted, #7a8d86); font-size: 13px; }
.detail-row strong { color: var(--ink, #25433b); font-size: 13px; font-weight: 850; text-align: right; }

.activity-signup-sheet {
  position: relative;
  width: min(calc(100% - 28px), 430px);
  max-height: 88vh;
  overflow-y: auto;
  display: grid;
  gap: 18px;
  padding: 22px 18px 24px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 28px;
  background:
    radial-gradient(circle at 88% 4%, rgba(87, 183, 183, 0.16), transparent 30%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.94), rgba(246, 250, 244, 0.86));
  box-shadow: 0 24px 58px rgba(32, 36, 45, 0.16);
}

.activity-signup-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.activity-signup-header .modal-close {
  position: static;
  flex: 0 0 auto;
}

.activity-signup-header .eyebrow {
  margin: 0 0 5px;
  color: #57B7B7;
  font-size: 11px;
  font-weight: 950;
  letter-spacing: 0.08em;
}

.activity-signup-header h2 {
  margin: 0 0 7px;
  color: var(--ink);
  font-size: 23px;
  font-weight: 950;
  line-height: 1.15;
}

.activity-signup-header p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 780;
  line-height: 1.55;
}

.activity-signup-form {
  display: grid;
  gap: 16px;
}

.signup-form-section {
  display: grid;
  gap: 12px;
  padding: 15px;
  border: 1px solid rgba(87, 183, 183, 0.12);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.64);
}

.signup-form-section h3 {
  margin: 0;
  color: var(--ink);
  font-size: 16px;
  font-weight: 950;
  line-height: 1.2;
}

.activity-profile-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.activity-profile-summary div {
  display: grid;
  gap: 5px;
  min-width: 0;
  padding: 11px 10px;
  border: 1px solid rgba(87, 183, 183, 0.12);
  border-radius: 16px;
  background: linear-gradient(145deg, rgba(232, 252, 247, 0.56), rgba(255, 255, 255, 0.72));
}

.activity-profile-summary span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
  line-height: 1;
}

.activity-profile-summary strong {
  color: var(--ink);
  font-size: 13px;
  font-weight: 950;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.signup-grid {
  display: grid;
  gap: 10px;
}

.signup-grid.two {
  grid-template-columns: 1fr 1fr;
}

.activity-signup-form label {
  display: grid;
  gap: 7px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 850;
}

.activity-signup-form input[type="text"],
.activity-signup-form input[type="tel"] {
  width: 100%;
  min-height: 42px;
  margin: 0;
  padding: 0 13px;
  border: 1px solid rgba(87, 183, 183, 0.16);
  border-radius: 14px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.78);
}

.signup-chip-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  min-width: 0;
}

.signup-chip-group p {
  flex: 0 0 100%;
  margin: 0 0 1px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 850;
  line-height: 1.35;
}

.signup-chip-group.signup-error p {
  color: var(--coral);
}

.signup-chip-group .pref-chip {
  min-height: 32px;
  padding: 0 11px;
  font-size: 12px;
  font-weight: 850;
}

.signup-static-field {
  display: grid;
  gap: 8px;
}

.signup-static-field p {
  margin: 0;
  color: var(--ink);
  font-size: 13px;
  font-weight: 850;
  line-height: 1.35;
}

.signup-static-field strong {
  display: grid;
  place-items: center;
  width: fit-content;
  min-height: 34px;
  padding: 0 13px;
  border: 1px solid rgba(87, 183, 183, 0.28);
  border-radius: 999px;
  color: #2f6f70;
  background: rgba(87, 183, 183, 0.12);
  font-size: 13px;
  font-weight: 950;
  line-height: 1;
}

.activity-rule-check {
  grid-template-columns: 18px 1fr;
  align-items: flex-start;
  gap: 9px !important;
  color: var(--muted) !important;
  font-size: 12px !important;
  line-height: 1.55;
}

.activity-rule-check input {
  width: 16px;
  height: 16px;
  margin: 2px 0 0;
  accent-color: #57B7B7;
}

.activity-random-role-note {
  margin: 0;
  padding: 12px 13px;
  border: 1px solid rgba(87, 183, 183, 0.16);
  border-radius: 16px;
  color: #2f6f70;
  background: rgba(87, 183, 183, 0.1);
  font-size: 13px;
  font-weight: 850;
  line-height: 1.55;
}

.activity-submit-btn {
  min-height: 48px;
}

@media (max-width: 430px) {
  .signup-grid.two {
    grid-template-columns: 1fr;
  }

  .activity-profile-summary {
    grid-template-columns: 1fr;
  }
}

#activityView .activity-groups-head {
  margin-top: 20px;
}

#activityView .activity-groups-card {
  margin-bottom: 16px;
  border-radius: 28px;
  border: 1px solid rgba(255, 255, 255, 0.74);
  box-shadow:
    0 18px 36px rgba(68, 120, 113, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.86);
}

/* Match detail page polish */
#matchDetailView .top-bar {
  margin-bottom: 22px;
  padding: 18px 18px 19px;
}

#matchDetailView .match-heading {
  font-size: 28px;
  line-height: 1.08;
  letter-spacing: 0;
}

#matchDetailView .back-btn {
  width: 48px;
  height: 48px;
  border-radius: 50%;
}

#matchDetailView .match-result {
  margin-inline: 2px;
  padding: 22px;
  border-radius: 30px;
}

#matchDetailView .match-person {
  align-items: flex-start;
  justify-content: flex-start;
  gap: 18px;
  margin-bottom: 20px;
}

#matchDetailView .mini-avatar {
  width: 58px;
  height: 58px;
  border-radius: 18px;
  font-size: 23px;
  background:
    linear-gradient(145deg, rgba(87, 183, 183, 0.9), rgba(143, 166, 179, 0.86));
  box-shadow:
    0 14px 28px rgba(68, 120, 113, 0.13),
    inset 0 1px 0 rgba(255, 255, 255, 0.34);
}

#matchDetailView .match-person h3 {
  margin-bottom: 8px;
  font-size: 22px;
  line-height: 1.22;
}

#matchDetailView .match-person p {
  color: var(--ink);
  font-size: 15px;
  line-height: 1.55;
}

#matchDetailView .match-report-grid {
  gap: 16px;
  margin: 12px 0 22px;
}

#matchDetailView .match-report-grid h4 {
  margin-bottom: 11px;
  color: #57B7B7;
  font-size: 13px;
}

#matchDetailView .report-list {
  gap: 10px;
}

#matchDetailView .reason,
#matchDetailView .personality-point {
  min-height: 58px;
  padding: 12px 13px;
  border: 1px solid rgba(255, 255, 255, 0.62);
  border-radius: 18px;
  background:
    linear-gradient(145deg, rgba(246, 250, 244, 0.78), rgba(232, 252, 247, 0.45));
  color: #20242d;
  font-size: 13px;
  line-height: 1.55;
}

#matchDetailView .chat-confirm {
  gap: 12px;
}

#matchDetailView .incoming-greeting {
  margin-bottom: 2px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.78), rgba(232, 252, 247, 0.55));
}

/* Community master card */
.community-master-card {
  margin-inline: 0;
  padding: 0;
  overflow: hidden;
  border-radius: 24px;
}

.community-list-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 92px;
  gap: 14px;
  align-items: center;
  padding: 18px 18px;
  border-bottom: 1px solid rgba(101, 112, 126, 0.09);
}

.community-list-item:last-of-type {
  border-bottom: none;
}

.community-list-item .community-copy .eyebrow {
  margin-bottom: 5px;
  font-size: 11px;
  letter-spacing: 0.08em;
}

.community-list-item .community-copy h3 {
  margin-bottom: 7px;
  font-size: 17px;
  font-weight: 950;
  line-height: 1.2;
}

.community-list-item .community-copy p {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.6;
  margin: 0;
}

.community-master-card .fake-qr {
  width: 80px;
  height: 80px;
  border-radius: 14px;
  background-size: 54px 54px;
}

.community-master-card .qr-block {
  overflow: hidden;
  min-width: 0;
  align-self: center;
}

.community-master-card .qr-block p {
  width: auto;
  max-width: 100%;
  font-size: 9px;
  text-align: center;
  margin-top: 5px;
  word-break: break-all;
  white-space: normal;
  overflow: hidden;
}

.community-more-btn {
  display: block;
  width: 100%;
  padding: 13px 20px;
  border: none;
  border-top: 1px solid rgba(101, 112, 126, 0.09);
  background: rgba(255, 255, 255, 0.46);
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
  text-align: center;
  transition: background 160ms ease, color 160ms ease;
}

.community-more-btn:hover {
  background: rgba(255, 255, 255, 0.7);
  color: var(--ink);
}

/* Per-group color tints */
.community-card-love {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.9), rgba(255, 232, 228, 0.48)) !important;
}
.community-card-love .eyebrow { color: #c97268; }

.community-card-food {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.9), rgba(255, 242, 218, 0.52)) !important;
}
.community-card-food .eyebrow { color: #b8854e; }

.community-card-study {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.9), rgba(218, 234, 248, 0.52)) !important;
}
.community-card-study .eyebrow { color: #5f8aaa; }

.community-card-activity {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.9), rgba(220, 245, 228, 0.52)) !important;
}
.community-card-activity .eyebrow { color: #4e8a62; }

/* 52Hz树洞 — social feed */
#communityView .declaration-list {
  gap: 10px;
  max-height: 500px;
  overflow-y: auto;
  padding-right: 4px;
  scrollbar-width: thin;
  scrollbar-color: rgba(87, 183, 183, 0.28) transparent;
}

#communityView .declaration-list::-webkit-scrollbar {
  width: 4px;
}

#communityView .declaration-list::-webkit-scrollbar-track {
  background: transparent;
}

#communityView .declaration-list::-webkit-scrollbar-thumb {
  background: rgba(87, 183, 183, 0.28);
  border-radius: 4px;
}

.feed-post {
  padding: 14px 16px;
  border-radius: 18px;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.82), rgba(246, 250, 244, 0.6));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.9),
    0 6px 16px rgba(68, 120, 113, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.7);
}

.feed-post-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}

.feed-own-badge {
  display: inline-block;
  padding: 1px 7px;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(87, 183, 183, 0.18), rgba(92, 125, 131, 0.14));
  border: 1px solid rgba(87, 183, 183, 0.26);
  color: var(--sage);
  font-size: 11px;
  font-weight: 900;
  margin-left: 6px;
  vertical-align: middle;
}

.feed-post-own {
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.88), rgba(228, 243, 232, 0.62));
  border-color: rgba(87, 183, 183, 0.18);
}

.feed-author {
  font-size: 13px;
  font-weight: 900;
  color: var(--ink);
}

.feed-like-btn,
.comment-like-btn {
  display: flex;
  align-items: center;
  gap: 4px;
  background: none;
  border: none;
  cursor: pointer;
  color: rgba(101, 112, 126, 0.65);
  font-size: 13px;
  font-weight: 800;
  padding: 2px 0;
  transition: color 140ms ease;
}

.feed-like-btn svg,
.comment-like-btn svg {
  width: 15px;
  height: 15px;
  flex-shrink: 0;
}

.feed-like-btn svg path,
.comment-like-btn svg path {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linejoin: round;
  transition: fill 140ms ease, stroke 140ms ease;
}

.feed-like-btn.liked,
.comment-like-btn.liked {
  color: #FF9A3D;
}

.feed-like-btn.liked svg path,
.comment-like-btn.liked svg path {
  fill: #FF9A3D;
  stroke: #FF9A3D;
}

.feed-content {
  font-size: 14px;
  color: var(--ink);
  line-height: 1.65;
  margin: 0 0 10px;
}

.feed-footer {
  display: flex;
  align-items: center;
}

.feed-reply-toggle {
  display: flex;
  align-items: center;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  color: rgba(101, 112, 126, 0.6);
  font-size: 12px;
  font-weight: 800;
  padding: 2px 0;
  transition: color 140ms ease;
}

.feed-reply-toggle:hover {
  color: var(--sage);
}

.feed-reply-toggle .comment-count::after {
  content: " ↓";
  opacity: 0.55;
  font-size: 11px;
}

.feed-reply-toggle.expanded .comment-count::after {
  content: " ↑";
}

.feed-reply-toggle svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linejoin: round;
}

.feed-comments {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid rgba(101, 112, 126, 0.1);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.feed-comments-scroll {
  display: grid;
  gap: 8px;
  max-height: 180px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(87, 183, 183, 0.28) transparent;
}

.feed-comments-scroll::-webkit-scrollbar {
  width: 3px;
}

.feed-comments-scroll::-webkit-scrollbar-track {
  background: transparent;
}

.feed-comments-scroll::-webkit-scrollbar-thumb {
  background: rgba(87, 183, 183, 0.28);
  border-radius: 2px;
}

.feed-comments-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 2px;
}

.comments-title {
  font-size: 12px;
  font-weight: 800;
  color: rgba(101, 112, 126, 0.65);
}

.feed-collapse-btn {
  font-size: 12px;
  font-weight: 800;
  color: rgba(101, 112, 126, 0.55);
  background: none;
  border: none;
  cursor: pointer;
  padding: 2px 0;
  transition: color 140ms ease;
}

.feed-collapse-btn:hover {
  color: var(--sage);
}

.feed-comment {
  padding: 9px 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.64);
  border: 1px solid rgba(255, 255, 255, 0.72);
}

.feed-comment-header {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 4px;
}

.comment-author {
  flex: 1;
  min-width: 0;
}

.comment-reply-btn {
  padding: 0;
  border: none;
  background: none;
  font-size: 11px;
  font-weight: 800;
  color: var(--sage);
  cursor: pointer;
  opacity: 0.75;
  transition: opacity 120ms ease;
}

.comment-reply-btn:hover {
  opacity: 1;
}

.comment-author {
  font-size: 12px;
  font-weight: 900;
  color: var(--ink);
  opacity: 0.78;
}

.comment-like-btn {
  font-size: 12px;
}

.comment-like-btn svg {
  width: 13px;
  height: 13px;
}

.comment-content {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.55;
  margin: 0;
}

.feed-comment-input {
  display: flex;
  gap: 8px;
  align-items: center;
  padding-top: 2px;
}

.comment-text-input {
  flex: 1;
  padding: 8px 13px;
  border-radius: 999px;
  border: 1px solid rgba(101, 112, 126, 0.15);
  background: rgba(255, 255, 255, 0.82);
  font-size: 13px;
  color: var(--ink);
  outline: none;
  transition: border-color 160ms ease, box-shadow 160ms ease;
}

.comment-text-input:focus {
  border-color: rgba(87, 183, 183, 0.4);
  box-shadow: 0 0 0 3px rgba(87, 183, 183, 0.1);
}

.feed-send-btn {
  flex-shrink: 0;
  padding: 8px 14px;
  border-radius: 999px;
  border: none;
  background: linear-gradient(135deg, #57B7B7, #8fa6b3);
  color: white;
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
  transition: opacity 140ms ease;
}

.feed-send-btn:active {
  opacity: 0.8;
}

/* Elegant QR placeholder — scan-frame style */
.fake-qr {
  display: grid;
  place-items: center;
  width: 108px;
  height: 108px;
  border: 0;
  border-radius: 18px;
  background:
    url("data:image/svg+xml,%3Csvg width='72' height='72' viewBox='0 0 72 72' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M6 22 L6 6 L22 6' stroke='%236f8f72' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M50 6 L66 6 L66 22' stroke='%236f8f72' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M6 50 L6 66 L22 66' stroke='%236f8f72' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M50 66 L66 66 L66 50' stroke='%236f8f72' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3Ccircle cx='36' cy='33' r='5' stroke='%236f8f72' stroke-width='2.8'/%3E%3Cpath d='M29 44c1.4-3.2 3.8-5 7-5s5.6 1.8 7 5' stroke='%236f8f72' stroke-width='2.8' stroke-linecap='round'/%3E%3C/svg%3E")
    center / 72px 72px no-repeat,
    linear-gradient(145deg, rgba(255, 255, 255, 0.92), rgba(232, 252, 247, 0.68));
  box-shadow:
    inset 0 0 0 1px rgba(87, 183, 183, 0.13),
    inset 0 1px 0 rgba(255, 255, 255, 0.9),
    0 8px 18px rgba(68, 120, 113, 0.07);
}

.qr-block p {
  color: rgba(112, 119, 131, 0.78);
  font-size: 10px;
}

/* Profile page: My declarations card */
.my-declarations-card {
  margin-inline: 0;
  margin-bottom: 14px;
  padding: 20px 20px 16px;
}

.my-declarations-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

.my-declarations-head .eyebrow {
  margin-bottom: 4px;
}

.my-declarations-head h3 {
  margin: 0 0 5px;
  font-size: 19px;
  font-weight: 950;
  line-height: 1.18;
}

.my-declarations-subtitle {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  line-height: 1.4;
}

.my-likes-badge {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  border-radius: 999px;
  color: #d56f63;
  font-size: 13px;
  font-weight: 900;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.95), rgba(255, 232, 221, 0.74));
  border: 1px solid rgba(255, 255, 255, 0.72);
  box-shadow: 0 6px 14px rgba(255, 154, 61, 0.1), inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.my-declaration-list {
  display: grid;
  gap: 10px;
}

.my-declaration-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 13px 14px;
  border-radius: 18px;
  border: 1px solid rgba(87, 183, 183, 0.08);
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.72), rgba(246, 250, 244, 0.55));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.82), 0 8px 18px rgba(68, 120, 113, 0.05);
}

.my-declaration-text {
  flex: 1;
  margin: 0;
  color: var(--ink);
  font-size: 14px;
  line-height: 1.55;
}

.my-declaration-actions {
  display: flex;
  align-items: center;
  gap: 7px;
  flex-shrink: 0;
  padding-top: 2px;
}

.my-declaration-like {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  min-height: 24px;
  padding: 2px 8px;
  border-radius: 999px;
  color: #d56f63;
  font-size: 12px;
  font-weight: 900;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.95), rgba(255, 232, 221, 0.74));
  border: 1px solid rgba(255, 255, 255, 0.72);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.92);
}

.my-declaration-comments {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  min-height: 24px;
  padding: 2px 8px;
  border-radius: 999px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.95), rgba(230, 240, 235, 0.74));
  border: 1px solid rgba(255, 255, 255, 0.72);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.92);
  cursor: pointer;
  transition: background 140ms ease;
}

.my-declaration-comments:hover {
  background: linear-gradient(145deg, rgba(255, 255, 255, 1), rgba(210, 235, 220, 0.9));
  color: var(--sage);
}

/* ── My Post Detail Bottom Sheet ── */
.post-detail-backdrop {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

.post-detail-overlay {
  position: absolute;
  inset: 0;
  background: rgba(30, 36, 48, 0.28);
  backdrop-filter: blur(10px);
}

.post-detail-sheet {
  position: relative;
  z-index: 1;
  width: min(100%, 430px);
  max-height: 78vh;
  overflow: hidden;
  border-radius: 28px 28px 0 0;
  padding: 20px 20px 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 -12px 40px rgba(30, 36, 48, 0.14);
}

.post-detail-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.post-detail-label {
  font-size: 15px;
  font-weight: 950;
  color: var(--ink);
}

.detail-close-btn {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  padding: 0;
  border: 1px solid rgba(32, 36, 45, 0.1);
  border-radius: 50%;
  background: rgba(32, 36, 45, 0.06);
  color: var(--ink);
  font-size: 16px;
  font-weight: 400;
  line-height: 1;
  cursor: pointer;
  transition: background 140ms ease;
}

.detail-close-btn:hover {
  background: rgba(32, 36, 45, 0.12);
}

.post-detail-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 14px 16px;
  border-radius: 18px;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.9), rgba(236, 248, 242, 0.7));
  border: 1px solid rgba(87, 183, 183, 0.14);
}

.post-detail-text {
  font-size: 15px;
  color: var(--ink);
  line-height: 1.65;
  font-weight: 600;
}

.post-detail-stats {
  display: flex;
  gap: 12px;
  align-items: center;
}

.post-detail-stat-like,
.post-detail-stat-comment {
  display: inline-flex;
  align-items: center;
  font-size: 12px;
  color: var(--muted);
  font-weight: 800;
}

.post-detail-divider {
  height: 1px;
  background: rgba(101, 112, 126, 0.1);
  margin: 0 -4px;
}

.post-detail-comments {
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
  scrollbar-width: thin;
  scrollbar-color: rgba(87, 183, 183, 0.28) transparent;
}

.post-detail-comments::-webkit-scrollbar { width: 3px; }
.post-detail-comments::-webkit-scrollbar-thumb { background: rgba(87, 183, 183, 0.28); border-radius: 2px; }

.detail-no-comments {
  text-align: center;
  color: var(--muted);
  font-size: 13px;
  padding: 16px 0;
}

.detail-comment {
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.72);
}

.detail-comment-head {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 4px;
}

.detail-comment-author {
  flex: 1;
  font-size: 12px;
  font-weight: 900;
  color: var(--ink);
}

.detail-comment-body {
  font-size: 13px;
  color: var(--ink);
  line-height: 1.6;
}

.detail-comment-like {
  display: flex;
  align-items: center;
  gap: 3px;
  padding: 2px 6px;
  border-radius: 999px;
  border: none;
  background: none;
  font-size: 12px;
  color: var(--muted);
  cursor: pointer;
}

.detail-comment-like svg {
  width: 13px;
  height: 13px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
}

.detail-comment-like.liked { color: #FF9A3D; }
.detail-comment-like.liked svg { fill: #FF9A3D; stroke: #FF9A3D; }

.post-detail-input-row {
  display: flex;
  gap: 8px;
  align-items: center;
  padding-top: 4px;
  border-top: 1px solid rgba(101, 112, 126, 0.09);
}

.my-declaration-delete {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border: 0;
  border-radius: 999px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 900;
  line-height: 26px;
  padding: 0;
  background: rgba(32, 36, 45, 0.06);
  cursor: pointer;
  transition: background 160ms ease, color 160ms ease;
}

.my-declaration-delete:hover {
  background: rgba(255, 154, 61, 0.14);
  color: #d56f63;
}

.my-declaration-empty {
  padding: 20px 16px;
  border-radius: 18px;
  color: rgba(112, 119, 131, 0.82);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.55;
  text-align: center;
  background: linear-gradient(145deg, rgba(246, 246, 242, 0.78), rgba(238, 244, 239, 0.52));
}

/* ── 话题卡 / 反馈（我的饭局 sheet 内）── */
.topic-draw-actions { display: grid; gap: 10px; }
.topic-draw-btn { width: 100%; }
.topic-drawn-list { display: grid; gap: 10px; }
.topic-card-item { padding: 12px 14px; border-radius: 12px; background: var(--brand-soft, #e8f7f2); display: grid; gap: 5px; }
.topic-cat-tag { width: fit-content; padding: 2px 10px; border-radius: 999px; background: var(--brand, #38b59b); color: #fff; font-size: 11px; font-weight: 800; }
.topic-card-item p { margin: 0; font-size: 14px; color: var(--ink, #25433b); line-height: 1.5; }
.topic-card-title { font-weight: 850; }
.topic-sub-list { margin: 2px 0 0; padding-left: 18px; display: grid; gap: 4px; }
.topic-sub-list li { font-size: 13.5px; color: var(--ink, #25433b); line-height: 1.5; }
.topic-card-item small { color: var(--muted, #7a8d86); font-size: 11px; }
.topic-pick-card-meta { display: block; margin-top: 8px; font-size: 11.5px; font-weight: 800; color: var(--brand-deep, #2f7e79); }

/* ── 开盲盒 · 三选一 抽题弹窗 ── */
.topic-pick-sheet {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  width: min(92vw, 430px); max-height: 88vh; overflow-y: auto;
  padding: 24px 18px 18px; border-radius: 24px;
  background:
    radial-gradient(circle at 85% -5%, rgba(213,139,102,.16), transparent 38%),
    radial-gradient(circle at 0% 105%, rgba(95,168,163,.16), transparent 40%),
    #fff;
  box-shadow: 0 30px 70px -20px rgba(40,70,60,.45);
}
.topic-pick-sheet .modal-close { position: absolute; right: 14px; top: 12px; }
.topic-pick-head { text-align: center; margin-bottom: 16px; }
.topic-pick-head .eyebrow { color: var(--brand-deep, #2f7e79); font-weight: 900; letter-spacing: .16em; }
.topic-pick-head h2 { margin: 4px 0 0; font-size: 22px; font-weight: 950; color: var(--ink, #25433b); }
.topic-pick-sub { margin: 6px 0 0; font-size: 12.5px; color: var(--muted, #7a8d86); }
.topic-pick-cards { display: grid; gap: 12px; perspective: 1000px; }
.topic-pick-loading { text-align: center; color: var(--muted, #7a8d86); font-size: 14px; padding: 28px 0; }
.topic-pick-card {
  position: relative; text-align: left; cursor: pointer;
  padding: 16px 16px 40px; border: 1px solid rgba(56,181,155,.2); border-radius: 18px;
  background: linear-gradient(150deg, #ffffff, #f3fbf8);
  box-shadow: 0 10px 24px -14px rgba(40,70,60,.4);
  transform-origin: center; backface-visibility: hidden;
  animation: topicReveal .52s cubic-bezier(.2,.8,.25,1) backwards;
  animation-delay: calc(var(--i, 0) * .13s);
  transition: transform .16s ease, box-shadow .2s ease, border-color .2s ease;
}
.topic-pick-card:hover { border-color: rgba(56,181,155,.5); box-shadow: 0 16px 30px -14px rgba(40,70,60,.5); }
.topic-pick-card:active { transform: scale(.97); }
.topic-pick-card-cat {
  display: inline-flex; padding: 3px 11px; border-radius: 999px;
  background: var(--brand, #38b59b); color: #fff; font-size: 11px; font-weight: 800;
}
.topic-pick-card-text { display: block; margin-top: 10px; font-size: 16px; font-weight: 650; line-height: 1.5; color: var(--ink, #25433b); }
.topic-pick-card-pick {
  position: absolute; right: 14px; bottom: 12px;
  font-size: 12px; font-weight: 850; color: var(--brand-deep, #2f7e79);
}
.topic-pick-actions { display: flex; justify-content: center; margin-top: 16px; }
.topic-pick-actions .secondary-btn { padding: 11px 26px; }
/* 翻开看详情：三问内容 + 确认/返回 */
.topic-detail { animation: topicReveal .42s cubic-bezier(.2,.8,.25,1) both; }
.topic-detail .topic-pick-card-cat { display: inline-flex; }
.topic-detail-title { margin: 12px 0 4px; font-size: 19px; font-weight: 950; color: var(--ink, #25433b); line-height: 1.4; }
.topic-detail-subs { margin: 8px 0 0; padding-left: 22px; display: grid; gap: 12px; }
.topic-detail-subs li { font-size: 15.5px; line-height: 1.55; color: var(--ink, #25433b); }
.topic-detail-subs li::marker { color: var(--brand, #38b59b); font-weight: 900; }
.topic-detail-single { margin: 12px 0 0; font-size: 18px; font-weight: 650; line-height: 1.5; color: var(--ink, #25433b); }
.topic-detail-actions { display: grid; grid-template-columns: 1fr 1.3fr; gap: 10px; margin-top: 22px; }
.topic-detail-actions .secondary-btn, .topic-detail-actions .primary-btn { width: 100%; padding: 13px 0; }
@keyframes topicReveal {
  from { opacity: 0; transform: rotateY(-78deg) translateY(8px); }
  to { opacity: 1; transform: none; }
}
/* 换一批：卡片淡出 + 骰子转一下 */
.topic-shuffling { animation: topicShuffleOut .2s ease both; }
@keyframes topicShuffleOut { to { opacity: 0; transform: scale(.96) translateY(6px); } }
#topicPickReroll.rerolling, #webTopicPickReroll.rerolling { animation: rerollSpin .42s ease; }
@keyframes rerollSpin { 50% { transform: rotate(180deg) scale(1.04); } 100% { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) {
  .topic-pick-card, .topic-shuffling { animation: none; }
  #topicPickReroll.rerolling, #webTopicPickReroll.rerolling { animation: none; }
}

.fb-stars { display: flex; gap: 4px; }
.fb-stars button { border: 0; background: none; font-size: 26px; line-height: 1; color: #d8e0db; cursor: pointer; padding: 0; }
.fb-stars button.on { color: #ffb43d; }
.fb-check { display: flex; align-items: center; gap: 9px; font-size: 14px; color: var(--ink, #25433b); margin-top: 4px; }
.fb-comment { width: 100%; border: 1px solid var(--line, #e6efe9); border-radius: 12px; padding: 11px; font-family: inherit; font-size: 14px; resize: vertical; }

.login-mode-toggle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  padding: 5px;
  margin: 2px 0 4px;
  border-radius: 999px;
  background: rgba(32, 36, 45, 0.06);
}
.login-mode-btn {
  border: 0;
  border-radius: 999px;
  padding: 9px 10px;
  color: var(--muted, #7a8d86);
  background: transparent;
  font: inherit;
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
}
.login-mode-btn.active {
  color: var(--brand-deep, #1d8c7d);
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 8px 18px rgba(32, 36, 45, 0.08);
}

/* ══ 活动社群 / 合作推广（CMS 驱动）══════════════════════════ */
.community-qr-img {
  width: 88px; height: 88px; border-radius: 12px; object-fit: cover; display: block;
}
.community-list-item--locked .qr-block p {
  white-space: normal;
  color: var(--home-muted, #6F7D76);
}
.community-qr-locked {
  width: 88px;
  height: 88px;
  border: 1px solid rgba(52, 126, 121, 0.16);
  border-radius: 16px;
  color: var(--home-brand-deep, #347E79);
  background:
    radial-gradient(circle at 72% 24%, rgba(213, 139, 102, 0.14), transparent 34%),
    linear-gradient(145deg, rgba(232, 245, 242, 0.86), rgba(255, 253, 246, 0.72));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.82),
    0 12px 24px rgba(57, 83, 76, 0.08);
  font: inherit;
  font-size: 11px;
  font-weight: 900;
  line-height: 1.35;
  cursor: pointer;
  transition: transform 0.18s cubic-bezier(.2, .8, .2, 1), box-shadow 0.18s ease, background 0.18s ease;
}
.community-qr-locked:hover {
  transform: translateY(-2px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.88),
    0 16px 28px rgba(57, 83, 76, 0.12);
}
.community-qr-locked:active {
  transform: scale(0.97);
}
.community-empty-hint { color: var(--muted, #8a8f98); font-size: 13px; text-align: center; padding: 12px 0; }
.contact-promo-intro { margin: 8px 0 0; font-size: 14px; color: #4a5258; }
.contact-promo-detail { margin: 8px 0 0; font-size: 13px; line-height: 1.6; color: #6a727a; }
.contact-promo-media { display: flex; gap: 14px; align-items: center; margin-top: 14px; flex-wrap: wrap; }
.contact-promo-image { width: 130px; height: 90px; object-fit: cover; border-radius: 12px; }
.contact-promo-qr { text-align: center; }
.contact-promo-qr img { width: 90px; height: 90px; object-fit: cover; border-radius: 12px; }
.contact-promo-qr small { display: block; margin-top: 6px; font-size: 11px; color: #9aa0a6; }

/* ══ Mobile home: warm editorial product surface ═══════════ */
#loginView {
  --home-bg: #FBF7EF;
  --home-card: #FFFDFC;
  --home-ink: #263631;
  --home-muted: #6F7D76;
  --home-brand: #4FA9A2;
  --home-brand-deep: #347E79;
  --home-warm: #E8A17D;
  --home-gold: #D6A64B;
  --home-line: rgba(52, 126, 121, 0.14);
  --home-shadow: 0 12px 30px rgba(57, 83, 76, 0.09);
  padding: 24px 20px 72px;
  color: var(--home-ink);
  background:
    linear-gradient(rgba(251, 247, 239, 0.92), rgba(251, 247, 239, 0.96)),
    repeating-linear-gradient(0deg, rgba(38, 54, 49, 0.018) 0 1px, transparent 1px 4px),
    var(--home-bg);
}

body:has(#loginView.active) .aurora {
  opacity: 0.08;
  filter: blur(54px);
}

#loginView::before {
  height: 560px;
  background: url("./assets/home-campus-bg.svg") center -72px / 116% auto no-repeat;
  opacity: 0.14;
}

#loginView::after {
  height: 560px;
  background: linear-gradient(180deg, rgba(251, 247, 239, 0.12), rgba(251, 247, 239, 0.7) 82%, var(--home-bg));
}

#loginView .brand-block {
  min-height: 540px;
  padding: 4px 0 0;
}

#loginView .brand-mark {
  width: 112px;
  height: 112px;
  margin: 0 auto 10px;
}

#loginView .brand-mark::after {
  left: 13px;
  right: 13px;
  bottom: 15px;
  height: 17px;
  opacity: 0.62;
  animation: none;
  filter: none;
}

#loginView .art-brand {
  margin: 4px auto 6px;
  font-family: "Arial Rounded MT Bold", "SF Pro Rounded", "Microsoft YaHei UI", "PingFang SC", sans-serif;
  font-size: clamp(62px, 17vw, 72px);
  font-weight: 900;
  line-height: 1;
  letter-spacing: 0;
  background: linear-gradient(135deg, var(--home-brand-deep), #65B7B0);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-stroke: 0;
  text-shadow: none;
  filter: drop-shadow(0 7px 13px rgba(52, 126, 121, 0.12));
}

#loginView .art-brand::before {
  display: none;
}

#loginView .brand-roman {
  margin: 0 0 10px;
  color: rgba(52, 126, 121, 0.72);
  font-size: 10px;
  font-weight: 850;
  letter-spacing: 0.3em;
  text-shadow: none;
}

#loginView .brand-copy {
  margin: 0;
  color: #D58B66;
  font-size: 13px;
  font-weight: 750;
  line-height: 1.42;
  letter-spacing: 0.04em;
  white-space: normal;
  text-shadow: none;
}

#loginView .brand-subcopy {
  margin: 4px 0 0;
  color: var(--home-brand-deep);
  font-size: 12px;
  font-weight: 760;
  line-height: 1.35;
  letter-spacing: 0.08em;
}

#loginView .hero-cta {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  width: min(100%, 350px);
  min-height: 52px;
  margin: 28px auto 0;
  border: 1px solid rgba(52, 126, 121, 0.16);
  border-radius: 16px;
  color: #FFFDF8;
  background: var(--home-brand);
  box-shadow: 0 12px 24px rgba(52, 126, 121, 0.2);
  transition:
    transform 160ms cubic-bezier(.2, .8, .2, 1),
    box-shadow 160ms cubic-bezier(.2, .8, .2, 1),
    background-color 160ms ease,
    opacity 160ms ease;
}

#loginView .hero-cta:hover {
  background: #469E98;
}

#loginView .hero-cta:active {
  transform: translateY(1px) scale(0.985);
  box-shadow: 0 6px 14px rgba(52, 126, 121, 0.16);
}

#loginView .hero-cta:focus-visible,
#loginView .message-like:focus-visible,
#loginView .hero-login-hint a:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px rgba(79, 169, 162, 0.24);
}

#loginView .hero-cta:disabled {
  cursor: wait;
  opacity: 0.48;
  box-shadow: none;
}

.hero-cta-spinner {
  display: none;
  width: 16px;
  height: 16px;
  border: 2px solid rgba(255, 253, 248, 0.42);
  border-top-color: #FFFDF8;
  border-radius: 50%;
  animation: homeSpinner 700ms linear infinite;
}

.hero-cta.is-loading .hero-cta-spinner {
  display: inline-block;
}

@keyframes homeSpinner {
  to { transform: rotate(360deg); }
}

#loginView .hero-login-hint {
  min-height: 44px;
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--home-muted);
  font-size: 13px;
}

#loginView .hero-login-hint a {
  position: relative;
  min-height: 44px;
  margin-left: 4px;
  display: inline-flex;
  align-items: center;
  color: var(--home-brand-deep);
  font-weight: 800;
  border-radius: 6px;
}

#loginView .hero-login-hint a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 8px;
  height: 1px;
  background: currentColor;
  transform: scaleX(0.32);
  transform-origin: left;
  opacity: 0.45;
  transition: transform 160ms ease, opacity 160ms ease;
}

#loginView .hero-login-hint a:hover::after,
#loginView .hero-login-hint a:focus-visible::after {
  transform: scaleX(1);
  opacity: 0.82;
}

#loginView .home-browse-btn {
  width: min(100%, 350px);
  min-height: 42px;
  margin: 12px auto 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(52, 126, 121, 0.16);
  border-radius: 999px;
  color: var(--home-brand-deep);
  background:
    radial-gradient(circle at 18% 0%, rgba(255, 255, 255, 0.9), transparent 42%),
    linear-gradient(135deg, rgba(238, 249, 247, 0.86), rgba(255, 250, 242, 0.78));
  box-shadow:
    0 8px 20px rgba(57, 83, 76, 0.06),
    inset 0 1px 0 rgba(255, 255, 255, 0.76);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.02em;
  transition:
    transform 160ms cubic-bezier(.2, .8, .2, 1),
    border-color 160ms ease,
    color 160ms ease,
    box-shadow 160ms ease;
}

#loginView .home-browse-btn:hover,
#loginView .home-browse-btn:focus-visible {
  border-color: rgba(52, 126, 121, 0.32);
  color: #287D78;
  box-shadow:
    0 12px 24px rgba(57, 83, 76, 0.09),
    inset 0 1px 0 rgba(255, 255, 255, 0.86);
}

#loginView .home-browse-btn:focus-visible {
  outline: none;
  box-shadow:
    0 0 0 3px rgba(79, 169, 162, 0.2),
    0 12px 24px rgba(57, 83, 76, 0.09);
}

#loginView .home-browse-btn:active {
  transform: translateY(1px) scale(0.985);
}

#loginView .hero-note {
  max-width: 310px;
  margin: 8px auto 0;
  color: var(--home-muted);
  font-size: 12px;
  font-weight: 550;
  line-height: 1.6;
  letter-spacing: 0;
}

#loginView .home-path-steps {
  width: min(100%, 350px);
  min-height: 80px;
  margin: 20px auto 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  border: 1px solid var(--home-line);
  border-radius: 16px;
  background: rgba(255, 253, 252, 0.86);
  box-shadow: 0 8px 22px rgba(57, 83, 76, 0.06);
  overflow: hidden;
}

#loginView .home-path-steps article {
  position: relative;
  min-width: 0;
  min-height: 96px;
  padding: 12px 7px 11px;
  display: grid;
  align-content: center;
  gap: 4px;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

#loginView .home-step-no {
  width: 20px;
  height: 20px;
  margin-bottom: 1px;
  color: #9A6746;
  font-size: 11px;
  line-height: 1;
  background:
    radial-gradient(circle at 35% 20%, rgba(255, 255, 255, 0.9), transparent 42%),
    linear-gradient(145deg, rgba(255, 228, 205, 0.96), rgba(255, 246, 238, 0.82));
  box-shadow:
    inset 0 0 0 1px rgba(232, 161, 125, 0.26),
    0 5px 12px rgba(172, 116, 78, 0.08);
}

#loginView .home-path-steps article + article::before {
  content: "";
  position: absolute;
  left: 0;
  top: 16px;
  bottom: 16px;
  width: 1px;
  background: var(--home-line);
}

#loginView .home-path-steps strong {
  color: var(--home-ink);
  font-size: 13px;
  font-weight: 850;
}

#loginView .home-path-steps span {
  color: var(--home-muted);
  font-size: 10.2px;
  line-height: 1.38;
  overflow-wrap: anywhere;
}

#loginView .message-board {
  margin-top: 40px;
  padding-bottom: 28px;
  isolation: isolate;
}

#loginView .message-board::before,
#loginView .message-board::after {
  display: none;
}

#loginView .section-title {
  position: relative;
  margin: 0 0 16px;
  padding: 0 0 0 15px;
  color: var(--home-ink);
  font-size: 20px;
  font-weight: 900;
}

#loginView .section-title::before {
  content: "";
  position: absolute;
  left: 0;
  top: 4px;
  width: 5px;
  height: 20px;
  border-radius: 3px;
  background: var(--home-warm);
}

#loginView .bubble-list {
  gap: 12px;
}

#loginView .message-card,
#loginView .message-card.right {
  position: relative;
  width: 100%;
  min-height: 88px;
  padding: 14px 54px 14px 14px;
  grid-template-columns: 40px minmax(0, 1fr);
  gap: 11px;
  border: 1px solid var(--home-line);
  border-radius: 16px;
  background: var(--home-card);
  box-shadow: var(--home-shadow);
  backdrop-filter: none;
}

#loginView .user-avatar {
  width: 40px;
  height: 40px;
  border-radius: 14px;
  color: #FFFDF8;
  background: var(--home-brand);
  box-shadow: none;
}

#loginView .message-card:nth-child(even) .user-avatar {
  background: var(--home-warm);
}

#loginView .message-meta {
  gap: 7px;
  margin-bottom: 6px;
}

#loginView .message-meta strong,
#loginView .message-card.right .message-meta strong {
  color: var(--home-ink);
  font-size: 14px;
  font-weight: 850;
}

#loginView .message-meta span {
  min-height: 21px;
  padding: 2px 8px;
  color: var(--home-brand-deep);
  font-size: 10.5px;
  font-weight: 750;
  border: 0;
  background: rgba(79, 169, 162, 0.1);
}

#loginView .message-card p {
  margin: 0;
  color: #43524D;
  font-size: 13px;
  line-height: 1.6;
}

#loginView .message-like {
  position: absolute;
  top: 11px;
  right: 11px;
  width: auto;
  height: 30px;
  min-height: 30px;
  padding: 0 9px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  border: 1px solid rgba(79, 169, 162, 0.16);
  border-radius: 999px;
  color: #6E7043;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.88), rgba(230, 252, 247, 0.76));
  box-shadow:
    0 8px 18px rgba(54, 128, 122, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.95);
  transition:
    transform 160ms cubic-bezier(.2, .8, .2, 1),
    color 160ms ease,
    background 180ms ease,
    box-shadow 180ms ease;
}

#loginView .message-like-count {
  min-width: 8px;
  font-size: 10.5px;
  font-weight: 900;
  line-height: 1;
}

#loginView .message-like:active {
  transform: translateY(1px) scale(0.96);
}

#loginView .message-like.is-liked {
  color: #FFF8E4;
  background:
    linear-gradient(135deg, rgba(222, 174, 82, 0.95), rgba(195, 128, 75, 0.92));
  box-shadow:
    0 10px 22px rgba(214, 166, 75, 0.22),
    inset 0 1px 0 rgba(255, 255, 255, 0.35);
}

#loginView .message-like.is-liked .message-like-icon {
  color: #FFF8E4;
  transform: scale(1.08);
  filter: drop-shadow(0 4px 8px rgba(255, 241, 191, 0.34));
}

#loginView .message-like.is-liked .message-like-icon path {
  fill: rgba(255, 248, 228, 0.38);
  stroke: currentColor;
}

#loginView .message-like.is-popping {
  animation: messageLikePop 420ms cubic-bezier(.16, 1, .3, 1) both;
}

#loginView .message-like.is-popping::after {
  content: "";
  position: absolute;
  inset: -8px;
  border-radius: 999px;
  pointer-events: none;
  background:
    radial-gradient(circle at 18% 28%, rgba(214, 166, 75, 0.95) 0 2px, transparent 3px),
    radial-gradient(circle at 84% 22%, rgba(232, 161, 125, 0.8) 0 2px, transparent 3px),
    radial-gradient(circle at 72% 84%, rgba(255, 255, 255, 0.9) 0 2px, transparent 3px);
  animation: messageLikeSpark 520ms ease-out both;
}

@keyframes messageLikePop {
  0% { transform: scale(0.94); }
  52% { transform: scale(1.11); }
  100% { transform: scale(1); }
}

@keyframes messageLikeSpark {
  0% { opacity: 0; transform: scale(0.72); }
  38% { opacity: 1; transform: scale(1.02); }
  100% { opacity: 0; transform: scale(1.35); }
}

#loginView.home-motion-ready [data-home-reveal-bound="1"] {
  opacity: 0;
  transition:
    opacity 420ms cubic-bezier(.2, .8, .2, 1),
    transform 420ms cubic-bezier(.2, .8, .2, 1);
  transition-delay: var(--home-reveal-delay, 0ms);
  will-change: opacity, transform;
}

#loginView.home-motion-ready [data-reveal-direction="up"] {
  transform: translateY(12px);
}

#loginView.home-motion-ready [data-reveal-direction="left"] {
  transform: translateX(-14px);
}

#loginView.home-motion-ready [data-reveal-direction="right"] {
  transform: translateX(14px);
}

#loginView.home-motion-ready [data-home-reveal-bound="1"].is-visible {
  opacity: 1;
  transform: translate(0, 0);
}

#loginView.home-motion-ready .brand-mark {
  transition-duration: 480ms;
}

@media (max-width: 370px) {
  #loginView {
    padding-left: 18px;
    padding-right: 18px;
  }

  #loginView .brand-mark {
    width: 104px;
    height: 104px;
  }

  #loginView .art-brand {
    font-size: 60px;
  }

  #loginView .home-path-steps article {
    padding-left: 6px;
    padding-right: 6px;
  }

  #loginView .home-path-steps span {
    font-size: 10px;
  }
}

@media (prefers-reduced-motion: reduce) {
  #loginView.home-motion-ready [data-home-reveal-bound="1"] {
    opacity: 1;
    transform: none;
    transition: none;
  }

  #loginView .hero-cta,
  #loginView .home-browse-btn,
  #loginView .message-like,
  #loginView .hero-login-hint a::after {
    transition-duration: 0.01ms;
  }

  .hero-cta-spinner {
    animation-duration: 1.4s;
  }
}

/* Unlock page final mobile polish. Keep this after legacy media rules. */
@media (max-width: 430px) {
  #unlockView .unlock-top-bar {
    padding-top: 24px;
    padding-bottom: 18px;
  }

  #unlockView .unlock-top-bar h2 {
    font-size: clamp(27px, 7.6vw, 32px);
  }

  #unlockView .page-subtitle {
    font-size: 13px;
  }

  #unlockView .unlock-preview {
    display: grid;
    grid-template-columns: 102px minmax(0, 1fr);
    gap: 18px;
    min-height: 154px;
    padding: 18px;
  }

  #unlockView .unlock-teaser {
    padding: 19px 18px;
  }

  #unlockView .unlock-preview h3,
  #unlockView .unlock-teaser h3 {
    font-size: 24px;
  }

  #unlockView .unlock-preview-list {
    gap: 12px;
    margin-top: 15px;
  }

  #unlockView .unlock-preview-item {
    grid-template-columns: 30px minmax(0, 1fr);
    gap: 10px;
  }

  #unlockView .unlock-preview-item > span {
    width: 30px;
    height: 30px;
  }

  #unlockView .unlock-preview-item strong {
    font-size: 14px;
  }

  #unlockView .unlock-preview-item small {
    font-size: 12px;
    line-height: 1.42;
  }

  #unlockView .unlock-actions {
    margin-top: -4px;
  }
}

@media (max-width: 370px) {
  #unlockView .unlock-preview {
    grid-template-columns: 86px minmax(0, 1fr);
    gap: 14px;
    min-height: 146px;
    padding: 16px;
  }

  #unlockView .portrait-avatar.unlock-mystery-avatar {
    width: 86px;
    height: 86px;
    border-radius: 26px;
  }

  #unlockView .unlock-status-pill,
  #unlockView .unlock-teaser-eyebrow {
    min-height: 26px;
    margin-bottom: 10px;
    padding: 0 10px;
    font-size: 11px;
  }

  #unlockView .unlock-preview h3,
  #unlockView .unlock-teaser h3 {
    font-size: 21px;
  }

  #unlockView .unlock-preview #unlockPortraitCopy {
    margin-top: 8px;
    font-size: 13px;
    line-height: 1.45;
  }

  #unlockView .unlock-full-btn {
    min-height: 54px;
    font-size: 16px;
  }
}

/* ══ 52Hz mobile visual system: home → quiz → unlock ══════════
   Keep this layer last so future mobile pages can opt into the same tokens. */
body {
  color: var(--hz-ink);
  background: var(--hz-page-bg);
}

.aurora-one {
  background: var(--hz-teal-100);
}

.aurora-two {
  background: var(--hz-coral-500);
}

.phone-shell {
  background: rgba(251, 247, 239, 0.72);
  box-shadow: 0 0 0 1px rgba(52, 126, 121, 0.08);
}

#loginView,
#quizView,
#unlockView {
  color: var(--hz-ink);
  background: var(--hz-page-bg);
}

#loginView {
  --home-bg: var(--hz-cream-1);
  --home-card: var(--hz-surface);
  --home-ink: var(--hz-ink);
  --home-muted: var(--hz-muted);
  --home-brand: var(--hz-teal-500);
  --home-brand-deep: var(--hz-teal-700);
  --home-warm: var(--hz-coral-500);
  --home-gold: #D6A64B;
  --home-line: var(--hz-line);
  --home-shadow: var(--hz-shadow-card-soft);
}

#loginView::before,
#quizView::before,
#unlockView::before {
  background:
    linear-gradient(180deg, rgba(255, 253, 246, 0.42), rgba(255, 253, 246, 0.08) 48%, rgba(255, 243, 234, 0.38)),
    url("./assets/home-campus-bg.svg") center -76px / 122% auto no-repeat;
  opacity: 0.18;
}

#loginView .brand-copy {
  color: var(--hz-coral-500);
}

#loginView .brand-subcopy,
#loginView .hero-login-hint a,
#loginView .home-path-steps strong,
#loginView .section-title span,
#quizView .page-subtitle,
#unlockView .page-subtitle {
  color: var(--hz-teal-700);
}

.primary-btn,
#loginView .hero-cta,
#quizView .quiz-actions .primary-btn,
#unlockView .unlock-full-btn {
  border: 1px solid rgba(255, 255, 255, 0.62);
  border-radius: var(--hz-radius-control);
  color: #FFFDF8;
  background: var(--hz-button-bg);
  box-shadow: var(--hz-shadow-button);
  transition:
    transform var(--hz-motion-fast) var(--hz-ease-out),
    box-shadow var(--hz-motion-fast) var(--hz-ease-out),
    opacity var(--hz-motion-fast) ease,
    background var(--hz-motion-fast) ease;
}

.primary-btn:active,
#loginView .hero-cta:active,
#quizView .quiz-actions .primary-btn:active,
#unlockView .unlock-full-btn:active {
  transform: translateY(1px) scale(0.985);
  box-shadow:
    0 8px 16px rgba(52, 126, 121, 0.16),
    inset 0 1px 0 rgba(255, 255, 255, 0.5);
}

.secondary-btn,
#quizView .quiz-actions .secondary-btn {
  border: 1px solid rgba(255, 255, 255, 0.76);
  border-radius: var(--hz-radius-control);
  color: var(--hz-ink);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.86), rgba(232, 245, 242, 0.58));
  box-shadow: var(--hz-shadow-card-soft);
}

#loginView .home-path-steps,
#quizView .quiz-card,
#unlockView .unlock-preview,
#unlockView .unlock-teaser {
  border: 1px solid rgba(255, 255, 255, 0.84);
  border-radius: var(--hz-radius-card);
  background: var(--hz-card-bg);
  box-shadow: var(--hz-shadow-card);
}

#loginView .home-path-steps {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.9), rgba(255, 253, 246, 0.82));
}

#quizView .quiz-card {
  border-radius: var(--hz-radius-card);
}

#quizView .quiz-top-bar,
#unlockView .unlock-top-bar {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.84), rgba(232, 245, 242, 0.46));
  border-bottom: 1px solid rgba(255, 255, 255, 0.64);
  box-shadow: 0 12px 28px rgba(57, 83, 76, 0.08);
}

#loginView .home-step-no,
#quizView .quiz-question-tag,
#unlockView .unlock-kicker,
#unlockView .unlock-teaser-eyebrow {
  color: var(--hz-coral-600);
  background: var(--hz-chip-bg);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
}

#quizView .quiz-top-bar .pill,
#unlockView .unlock-status-pill {
  color: var(--hz-teal-700);
  background:
    linear-gradient(145deg, rgba(232, 245, 242, 0.95), rgba(255, 253, 246, 0.68));
  border: 1px solid rgba(255, 255, 255, 0.74);
  box-shadow: var(--hz-shadow-card-soft);
}

#quizView .progress-track {
  border-color: rgba(255, 255, 255, 0.64);
  background: rgba(52, 126, 121, 0.12);
}

#quizView .progress-fill {
  background:
    linear-gradient(90deg, var(--hz-coral-500) 0%, var(--hz-teal-400) 22%, var(--hz-teal-500) 64%, var(--hz-teal-700) 100%);
  box-shadow: 0 6px 16px rgba(52, 126, 121, 0.22);
}

#quizView .progress-fill::before {
  background: var(--hz-coral-500);
  box-shadow:
    0 0 0 4px rgba(255, 255, 255, 0.74),
    0 8px 18px rgba(213, 139, 102, 0.22);
}

#quizView .answer-option {
  border-color: rgba(52, 126, 121, 0.12);
  border-radius: var(--hz-radius-card-sm);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.92), rgba(255, 253, 246, 0.82));
  box-shadow: var(--hz-shadow-card-soft);
}

#quizView .answer-letter,
#unlockView .unlock-preview-item > span {
  color: rgba(38, 54, 49, 0.78);
  background:
    radial-gradient(circle at 32% 18%, rgba(255, 255, 255, 0.62), transparent 40%),
    linear-gradient(145deg, rgba(232, 245, 242, 0.95), rgba(255, 243, 234, 0.72));
}

#quizView .answer-option.selected {
  border-color: rgba(52, 126, 121, 0.5);
  color: var(--hz-ink);
  background:
    radial-gradient(circle at 94% 16%, rgba(213, 139, 102, 0.14), transparent 24%),
    linear-gradient(145deg, rgba(232, 245, 242, 0.98), rgba(255, 253, 246, 0.8));
  box-shadow:
    0 16px 28px rgba(52, 126, 121, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.96);
}

#quizView .answer-option.selected .answer-letter,
#quizView .answer-option.selected .answer-check {
  background:
    radial-gradient(circle at 30% 18%, rgba(255, 255, 255, 0.42), transparent 40%),
    linear-gradient(135deg, var(--hz-teal-500), var(--hz-teal-700));
}

#quizView .answer-option.selected .answer-check {
  box-shadow: 0 7px 16px rgba(52, 126, 121, 0.22);
}

#unlockView .unlock-preview-item > span::after {
  background: var(--hz-teal-500);
  box-shadow: 0 0 0 5px rgba(79, 169, 162, 0.12);
}

#loginView .home-path-steps article + article::before {
  background: var(--hz-line);
}

#quizView.active .quiz-top-bar,
#quizView.active .progress-track,
#quizView .quiz-card-enter,
#quizView .answer-option.answer-enter,
#quizView .quiz-actions-enter,
#unlockView.active .unlock-reveal {
  animation-duration: var(--hz-motion-normal);
  animation-timing-function: var(--hz-ease-out);
}

/* ══ Auth modal token components ════════════════════════════════ */
#loginModal,
#setPasswordModal,
#changePasswordModal {
  background:
    radial-gradient(circle at 22% 18%, rgba(79, 169, 162, 0.2), transparent 28%),
    radial-gradient(circle at 82% 82%, rgba(213, 139, 102, 0.18), transparent 30%),
    rgba(32, 40, 50, 0.32);
  backdrop-filter: blur(16px);
}

#loginModal .login-modal-card,
#setPasswordModal .login-modal-card {
  width: min(calc(100% - 24px), 420px);
  max-height: calc(100vh - 36px);
  animation: auth-modal-in var(--hz-motion-normal) var(--hz-ease-out) both;
}

#loginModal .login-card,
#setPasswordModal .login-card,
#changePasswordModal .edit-profile-modal {
  position: relative;
  max-height: calc(100vh - 36px);
  margin: 0;
  padding: 26px 22px 22px;
  overflow-y: auto;
  border: 1px solid rgba(255, 255, 255, 0.84);
  border-radius: var(--hz-radius-card);
  color: var(--hz-ink);
  background: var(--hz-card-bg);
  box-shadow:
    0 26px 70px rgba(32, 40, 50, 0.22),
    var(--hz-shadow-card);
  backdrop-filter: blur(20px);
  scrollbar-width: thin;
  scrollbar-color: rgba(79, 169, 162, 0.34) rgba(255, 255, 255, 0.24);
}

#loginModal .login-card {
  padding-top: 28px;
}

#loginModal .modal-close,
#changePasswordModal .modal-close,
#policyModal .modal-close {
  top: 18px;
  right: 18px;
  width: 42px;
  height: 42px;
  margin: 0;
  border: 1px solid rgba(255, 255, 255, 0.78);
  border-radius: 50%;
  color: var(--hz-ink);
  font-size: 28px;
  line-height: 1;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.9), rgba(232, 245, 242, 0.58));
  box-shadow: var(--hz-shadow-card-soft);
  transition: transform var(--hz-motion-fast) var(--hz-ease-out), box-shadow var(--hz-motion-fast) var(--hz-ease-out);
}

#loginModal .modal-close:active,
#changePasswordModal .modal-close:active,
#policyModal .modal-close:active {
  transform: scale(0.96);
  box-shadow: 0 6px 14px rgba(57, 83, 76, 0.08);
}

.auth-card-head {
  padding-right: 48px;
  margin-bottom: 20px;
}

.auth-kicker {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  margin: 0 0 10px;
  padding: 0 12px;
  border-radius: var(--hz-radius-pill);
  color: var(--hz-coral-600);
  font-size: 11px;
  font-weight: 950;
  letter-spacing: 0.1em;
  background: var(--hz-chip-bg);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
}

.auth-card-head h2 {
  margin: 0;
  color: var(--hz-ink-strong);
  font-size: 24px;
  font-weight: 950;
  line-height: 1.16;
}

.auth-card-head p {
  margin: 8px 0 0;
  color: var(--hz-teal-700);
  font-size: 13px;
  font-weight: 850;
  line-height: 1.5;
}

#loginModal .login-card label:not(.agree-row),
#setPasswordModal .login-card label,
#changePasswordModal .edit-profile-modal label {
  margin-bottom: 13px;
  color: var(--hz-ink);
  font-size: 13px;
  font-weight: 900;
}

#loginModal .login-card input,
#setPasswordModal .login-card input,
#changePasswordModal .edit-profile-modal input {
  height: 54px;
  margin-top: 8px;
  border: 1px solid rgba(255, 255, 255, 0.78);
  border-radius: var(--hz-radius-control);
  color: var(--hz-ink);
  font-size: 15px;
  font-weight: 850;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.88), rgba(255, 253, 246, 0.72));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.88),
    0 8px 18px rgba(57, 83, 76, 0.05);
}

#loginModal .login-card input::placeholder,
#setPasswordModal .login-card input::placeholder,
#changePasswordModal .edit-profile-modal input::placeholder {
  color: rgba(38, 54, 49, 0.42);
  font-weight: 780;
}

#loginModal .login-card input:focus,
#setPasswordModal .login-card input:focus,
#changePasswordModal .edit-profile-modal input:focus {
  border-color: rgba(79, 169, 162, 0.5);
  background: rgba(255, 255, 255, 0.94);
  box-shadow:
    0 0 0 4px rgba(79, 169, 162, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.95);
}

.login-mode-toggle {
  position: relative;
  gap: 6px;
  padding: 6px;
  margin: 2px 0 14px;
  border: 1px solid rgba(255, 255, 255, 0.52);
  border-radius: var(--hz-radius-pill);
  background:
    linear-gradient(145deg, rgba(232, 245, 242, 0.7), rgba(255, 243, 234, 0.32));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.64);
}

.login-mode-btn {
  min-height: 42px;
  border-radius: var(--hz-radius-pill);
  color: var(--hz-muted);
  font-size: 14px;
  font-weight: 950;
  background: transparent;
  transition:
    color var(--hz-motion-fast) ease,
    background var(--hz-motion-fast) ease,
    box-shadow var(--hz-motion-fast) ease,
    transform var(--hz-motion-fast) var(--hz-ease-out);
}

.login-mode-btn.active {
  color: var(--hz-teal-700);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.94), rgba(255, 253, 246, 0.82));
  box-shadow: var(--hz-shadow-card-soft);
}

.login-mode-btn:active {
  transform: scale(0.985);
}

#loginModal .inline-field {
  grid-template-columns: minmax(0, 1fr) 78px;
  gap: 10px;
  align-items: end;
}

#loginModal .inline-field .ghost-btn,
#sendCodeBtn {
  height: 54px;
  margin-top: 8px;
  padding: 0 14px;
  border: 1px solid rgba(255, 255, 255, 0.76);
  border-radius: var(--hz-radius-control);
  color: var(--hz-teal-700);
  font-size: 14px;
  font-weight: 950;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.88), rgba(232, 245, 242, 0.58));
  box-shadow: var(--hz-shadow-card-soft);
  transition: transform var(--hz-motion-fast) var(--hz-ease-out), opacity var(--hz-motion-fast) ease;
}

#sendCodeBtn:active {
  transform: scale(0.985);
}

#sendCodeBtn:disabled,
#sendCodeBtn.cooling {
  color: rgba(38, 54, 49, 0.42);
  opacity: 0.72;
  cursor: not-allowed;
}

#loginModal .hint {
  margin: 8px 0 16px;
  color: var(--hz-muted-soft);
  font-size: 12px;
  font-weight: 760;
}

#loginGenderWrap {
  margin: 2px 0 15px;
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: var(--hz-radius-card-sm);
  background: rgba(255, 255, 255, 0.38);
}

.login-gender-label {
  color: var(--hz-ink);
  font-size: 13px;
  font-weight: 950;
}

.login-gender-row {
  gap: 10px;
  margin: 9px 0 7px;
}

.login-gender-btn {
  position: relative;
  min-height: 50px;
  border: 1px solid rgba(79, 169, 162, 0.18);
  border-radius: var(--hz-radius-control);
  color: var(--hz-teal-500);
  font-size: 15px;
  font-weight: 950;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.78), rgba(232, 245, 242, 0.46));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.login-gender-btn.selected {
  color: var(--hz-teal-700);
  border-color: rgba(79, 169, 162, 0.42);
  background:
    radial-gradient(circle at 92% 12%, rgba(213, 139, 102, 0.14), transparent 30%),
    linear-gradient(145deg, rgba(232, 245, 242, 0.95), rgba(255, 253, 246, 0.74));
  box-shadow: var(--hz-shadow-card-soft);
}

.login-gender-btn.selected::after {
  content: "";
  position: absolute;
  top: 10px;
  right: 12px;
  width: 7px;
  height: 12px;
  border: solid var(--hz-teal-700);
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.login-gender-tip,
.password-login-help {
  color: var(--hz-muted-soft);
  font-size: 12px;
  font-weight: 720;
}

#loginModal .agree-row {
  align-items: flex-start;
  gap: 10px;
  margin: 6px 0 10px;
}

#loginModal .agree-row input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  display: inline-grid;
  place-items: center;
  flex: 0 0 19px;
  width: 19px;
  min-width: 19px;
  max-width: 19px;
  height: 19px;
  min-height: 19px;
  max-height: 19px;
  aspect-ratio: 1 / 1;
  margin: 1px 0 0;
  padding: 0;
  box-sizing: border-box;
  border: 1px solid rgba(79, 169, 162, 0.34);
  border-radius: 5px;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

#agreeCheckbox {
  width: 19px !important;
  min-width: 19px !important;
  max-width: 19px !important;
  height: 19px !important;
  min-height: 19px !important;
  max-height: 19px !important;
}

#loginModal .agree-row input[type="checkbox"]:checked {
  border-color: var(--hz-teal-500);
  background: var(--hz-teal-500);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.24),
    0 6px 14px rgba(79, 169, 162, 0.18);
}

#loginModal .agree-row input[type="checkbox"]:checked::after {
  content: "";
  width: 6px;
  height: 10px;
  border: solid white;
  border-width: 0 2px 2px 0;
  transform: translateY(-1px) rotate(45deg);
}

#loginModal .agree-row > span {
  color: var(--hz-muted-soft);
  font-size: 12px;
  font-weight: 720;
}

.agree-link {
  color: var(--hz-teal-700);
  font-weight: 850;
}

.agree-link:active {
  opacity: 0.68;
}

#loginModal .field-error-hint.visible,
#setPasswordModal .field-error-hint.visible,
#changePasswordModal .field-error-hint.visible {
  color: var(--hz-coral-600);
  font-weight: 820;
}

#loginModal .auth-submit-btn,
#setPasswordModal .auth-submit-btn {
  min-height: 56px;
  margin-top: 2px;
  font-size: 17px;
}

.auth-submit-btn.is-loading {
  opacity: 0.86;
  cursor: wait;
}

.auth-btn-spinner {
  display: none;
  width: 17px;
  height: 17px;
  margin-left: 10px;
  border: 2px solid rgba(255, 255, 255, 0.48);
  border-top-color: white;
  border-radius: 50%;
  animation: ai-spin 0.8s linear infinite;
  vertical-align: -3px;
}

.auth-submit-btn.is-loading .auth-btn-spinner {
  display: inline-block;
}

#setPasswordModal .set-password-card {
  display: grid;
  gap: 0;
  text-align: left;
}

#setPasswordModal .set-pw-title {
  margin: 0 0 8px;
  color: var(--hz-ink-strong);
  font-size: 24px;
  font-weight: 950;
  line-height: 1.15;
  text-align: left;
}

#setPasswordModal .set-pw-sub {
  margin: 0 0 20px;
  color: var(--hz-teal-700);
  font-size: 13px;
  font-weight: 850;
  line-height: 1.5;
  text-align: left;
}

#setPasswordModal .set-pw-skip {
  width: 100%;
  min-height: 48px;
  margin-top: 11px;
  color: var(--hz-muted);
  font-size: 14px;
  font-weight: 900;
}

@keyframes auth-modal-in {
  from {
    opacity: 0;
    transform: translateY(12px) scale(0.992);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@media (max-width: 370px) {
  #loginModal,
  #setPasswordModal {
    padding: 14px;
  }

  #loginModal .login-card,
  #setPasswordModal .login-card {
    padding: 20px 16px 18px;
  }

  .auth-card-head h2,
  #setPasswordModal .set-pw-title {
    font-size: 21px;
  }

  .auth-card-head {
    margin-bottom: 14px;
  }

  .auth-card-head p {
    font-size: 12px;
    line-height: 1.42;
  }

  #loginModal .login-card label:not(.agree-row),
  #setPasswordModal .login-card label {
    margin-bottom: 10px;
  }

  #loginModal .login-card input,
  #setPasswordModal .login-card input {
    height: 50px;
  }

  .login-mode-toggle {
    margin-bottom: 10px;
  }

  .login-mode-btn {
    min-height: 38px;
    font-size: 13px;
  }

  #loginModal .inline-field {
    grid-template-columns: minmax(0, 1fr) 70px;
    gap: 8px;
  }

  #loginModal .inline-field .ghost-btn,
  #sendCodeBtn {
    height: 50px;
    padding: 0 10px;
  }

  #loginModal .auth-submit-btn,
  #setPasswordModal .auth-submit-btn {
    min-height: 52px;
  }

  #loginModal .agree-row {
    margin-bottom: 8px;
  }
}

@media (prefers-reduced-motion: reduce) {
  #loginModal .login-modal-card,
  #setPasswordModal .login-modal-card,
  .auth-btn-spinner {
    animation: none;
  }
}

/* Match page product polish: keep 52Hz mobile visual tokens */
#matchView {
  color: var(--hz-ink);
}

#matchView .match-page-header {
  position: relative;
  min-height: 132px;
  padding: 30px 32px 18px;
  overflow: hidden;
  border-bottom: 0;
  border-radius: 0 0 32px 32px;
  background:
    radial-gradient(circle at 86% 18%, rgba(255, 255, 255, 0.6), transparent 24%),
    radial-gradient(circle at 18% 80%, rgba(213, 139, 102, 0.16), transparent 30%),
    linear-gradient(145deg, rgba(255, 253, 246, 0.94), rgba(232, 245, 242, 0.62) 48%, rgba(255, 243, 234, 0.58));
  box-shadow: none;
  backdrop-filter: none;
  animation: hz-page-header-enter var(--hz-motion-normal, 380ms) var(--hz-ease-out, ease-out) both;
}

#matchView .match-page-header::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(255, 253, 246, 0.08), rgba(255, 253, 246, 0.5)),
    url("./assets/home-campus-bg.svg") center -118px / 126% auto no-repeat;
  opacity: 0.18;
}

#matchView .match-page-header::after {
  content: "";
  position: absolute;
  right: -34px;
  top: -24px;
  width: 180px;
  height: 150px;
  border-radius: 0 0 0 44px;
  pointer-events: none;
  background:
    radial-gradient(circle at 70% 28%, rgba(255, 255, 255, 0.58), transparent 26%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.2), rgba(213, 139, 102, 0.08));
  opacity: 0.45;
}

#matchView .match-page-title {
  position: relative;
  z-index: 1;
  display: grid;
  justify-items: start;
  max-width: 286px;
  text-align: left;
}

#matchView .match-kicker {
  margin: 0 0 4px;
  color: var(--hz-muted);
  font-size: 11.5px;
  font-weight: 950;
  line-height: 1;
  letter-spacing: 0.18em;
}

#matchView .match-page-title .match-heading {
  margin: 0;
  color: var(--hz-ink-strong);
  font-size: 31px;
  font-weight: 950;
  line-height: 1.04;
  letter-spacing: 0;
}

#matchView .match-page-title .page-subtitle {
  margin: 7px 0 0;
  color: var(--hz-teal-700);
  font-size: 13px;
  font-weight: 850;
  line-height: 1.48;
}

#matchView .match-options {
  gap: 16px;
  margin: 22px 0 0;
}

#matchView .match-choice,
#matchView .history-card,
#matchView .portrait-hero {
  animation: match-card-enter var(--hz-motion-normal) var(--hz-ease-out) both;
}

#matchView .match-choice:nth-of-type(1) {
  animation-delay: 40ms;
}

#matchView .match-choice:nth-of-type(2) {
  animation-delay: 90ms;
}

#matchView .history-card {
  animation-delay: 140ms;
}

#matchView .portrait-hero {
  animation-delay: 190ms;
}

#matchView .match-choice {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  justify-items: center;
  gap: 7px;
  min-height: 0;
  padding: 24px 22px 20px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.82);
  border-radius: var(--hz-radius-card-sm);
  color: var(--hz-ink);
  background: var(--hz-card-bg);
  box-shadow: var(--hz-shadow-card);
  cursor: pointer;
  text-align: center;
  transition:
    transform var(--hz-motion-fast) var(--hz-ease-out),
    box-shadow var(--hz-motion-fast) var(--hz-ease-out),
    border-color var(--hz-motion-fast) ease,
    filter var(--hz-motion-fast) ease;
}

#matchView .match-choice::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 4px;
  border-radius: inherit;
  opacity: 0.95;
}

#matchView .match-choice::after {
  background:
    radial-gradient(circle at 90% 8%, rgba(255, 255, 255, 0.72), transparent 28%),
    radial-gradient(circle at 16% 88%, rgba(255, 255, 255, 0.44), transparent 26%);
}

#matchView .match-choice.dating {
  background:
    radial-gradient(circle at 88% 14%, rgba(213, 139, 102, 0.24), transparent 34%),
    radial-gradient(circle at 10% 84%, rgba(251, 228, 215, 0.68), transparent 36%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.96), rgba(255, 241, 231, 0.82));
}

#matchView .match-choice.friendship {
  background:
    radial-gradient(circle at 88% 14%, rgba(101, 183, 176, 0.28), transparent 34%),
    radial-gradient(circle at 10% 84%, rgba(232, 245, 242, 0.92), transparent 38%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.96), rgba(222, 243, 239, 0.84));
}

#matchView .match-choice.dating::before {
  background: linear-gradient(90deg, var(--hz-coral-500), rgba(213, 139, 102, 0.2));
}

#matchView .match-choice.friendship::before {
  background: linear-gradient(90deg, var(--hz-teal-500), rgba(101, 183, 176, 0.2));
}

#matchView .match-choice:hover,
#matchView .match-choice:focus-visible {
  border-color: var(--hz-line-strong);
  box-shadow:
    0 22px 46px rgba(57, 83, 76, 0.12),
    0 8px 18px rgba(213, 139, 102, 0.07),
    inset 0 1px 0 rgba(255, 255, 255, 0.92);
}

#matchView .match-choice:active {
  transform: scale(0.982);
  box-shadow:
    0 12px 26px rgba(57, 83, 76, 0.09),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

#matchView .match-choice.match-focus-pulse {
  animation:
    match-card-enter var(--hz-motion-normal) var(--hz-ease-out) both,
    match-focus-pulse 720ms var(--hz-ease-out) 1;
}

#matchView .check-ring {
  position: absolute;
  left: 24px;
  top: 25px;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  transform: none;
  border: 1px solid rgba(255, 255, 255, 0.82);
  background:
    radial-gradient(circle at 32% 24%, rgba(255, 255, 255, 0.98), transparent 18%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.9), rgba(232, 245, 242, 0.62));
  box-shadow: var(--hz-shadow-card-soft);
}

#matchView .match-choice:not(.joined) .check-ring::before {
  width: 16px;
  height: 16px;
  background: rgba(79, 169, 162, 0.14);
  box-shadow: 0 0 0 9px rgba(79, 169, 162, 0.08);
}

#matchView .match-choice.dating:not(.joined) .check-ring::before {
  background: rgba(213, 139, 102, 0.16);
  box-shadow: 0 0 0 9px rgba(213, 139, 102, 0.08);
}

#matchView .match-choice.joined .check-ring::after {
  left: 14px;
  top: 14px;
  border-color: var(--hz-teal-700);
}

#matchView .choice-title {
  margin: 0;
  padding-inline: 52px;
  color: var(--hz-ink-strong);
  font-size: 24px;
  font-weight: 950;
  line-height: 1.08;
}

#matchView .match-choice strong {
  width: 100%;
  color: var(--hz-muted);
  font-size: 14px;
  font-weight: 900;
  line-height: 1.35;
  opacity: 1;
}

#matchView .match-choice em {
  width: 100%;
  max-width: none;
  margin: 1px 0 0;
  color: var(--hz-muted);
  font-size: 14px;
  font-weight: 820;
  line-height: 1.45;
  opacity: 1;
}

#matchView .match-side-controls {
  position: static;
  width: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  justify-items: stretch;
  gap: 8px 12px;
  margin-top: 11px;
  transform: none;
  filter: none;
}

#matchView .card-countdown {
  grid-column: 1 / -1;
  display: flex;
  position: relative;
  align-items: center;
  justify-content: center;
  gap: 2px;
  min-width: 0;
  width: 100%;
  min-height: 50px;
  padding: 0 16px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: var(--hz-radius-control);
  color: var(--hz-ink-strong);
  font-size: 21px;
  font-weight: 950;
  font-variant-numeric: tabular-nums;
  line-height: 1;
  letter-spacing: 0.01em;
  background:
    radial-gradient(circle at 14% 22%, rgba(255, 255, 255, 0.72), transparent 22%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.86), rgba(232, 245, 242, 0.54));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.9),
    0 10px 22px rgba(57, 83, 76, 0.06);
  isolation: isolate;
  overflow: hidden;
}

#matchView .dating-countdown {
  background:
    radial-gradient(circle at 14% 22%, rgba(255, 255, 255, 0.72), transparent 22%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.9), rgba(251, 228, 215, 0.78));
}

#matchView .friendship-countdown {
  background:
    radial-gradient(circle at 14% 22%, rgba(255, 255, 255, 0.74), transparent 22%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.9), rgba(210, 239, 235, 0.76));
}

#matchView .card-countdown::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.56;
  background:
    linear-gradient(
      105deg,
      transparent 0%,
      transparent 32%,
      rgba(255, 255, 255, 0.76) 46%,
      rgba(101, 183, 176, 0.16) 54%,
      transparent 68%,
      transparent 100%
    );
  transform: translateX(-115%);
  animation: match-time-flow 3.2s linear infinite;
}

#matchView .dating-countdown::before {
  background:
    linear-gradient(
      105deg,
      transparent 0%,
      transparent 32%,
      rgba(255, 255, 255, 0.8) 46%,
      rgba(213, 139, 102, 0.16) 54%,
      transparent 68%,
      transparent 100%
    );
}

#matchView .card-countdown > span {
  position: relative;
  z-index: 1;
}

#matchView .countdown-days {
  display: inline-flex;
  align-items: baseline;
  justify-content: center;
}

#matchView .card-countdown small {
  margin-left: 2px;
  color: var(--hz-muted);
  font-size: 12px;
  font-weight: 900;
}

#matchView .countdown-clock,
#matchView .countdown-second {
  display: inline-flex;
  align-items: center;
  height: 1em;
  color: var(--hz-ink-strong);
}

#matchView .countdown.ready {
  min-width: 0;
  color: var(--hz-teal-700);
  font-size: 14px;
}

#matchView .dating-countdown.ready {
  color: var(--hz-coral-600);
}

#matchView .not-joined-label {
  color: var(--hz-muted-soft);
  font-size: 13px;
  font-weight: 850;
  opacity: 1;
}

#matchView .match-detail-hint {
  grid-column: 1 / -1;
  margin: 0;
  color: var(--hz-muted-soft);
  font-size: 11px;
  font-weight: 850;
  letter-spacing: 0;
  text-align: center;
}

#matchView .match-pill-row {
  grid-column: 1 / -1;
  justify-content: center;
  gap: 8px;
}

#matchView .match-side-controls .joined-label,
#matchView .match-side-controls .buddy-prefs-toggle {
  width: auto;
  min-width: 86px;
  min-height: 36px;
  padding: 0 16px;
  border: 1px solid rgba(255, 255, 255, 0.78);
  border-radius: var(--hz-radius-pill);
  color: var(--hz-teal-700);
  font-size: 13px;
  font-weight: 950;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.92), rgba(232, 245, 242, 0.66));
  box-shadow: var(--hz-shadow-card-soft);
  transition:
    transform var(--hz-motion-fast) var(--hz-ease-out),
    box-shadow var(--hz-motion-fast) var(--hz-ease-out),
    border-color var(--hz-motion-fast) ease;
}

#matchView .match-side-controls .buddy-prefs-toggle {
  display: inline-grid;
}

#matchView .match-choice.dating .joined-label {
  color: var(--hz-coral-600);
}

#matchView .match-choice.joined .joined-label {
  color: var(--hz-teal-700);
  background:
    radial-gradient(circle at 92% 20%, rgba(213, 139, 102, 0.12), transparent 26%),
    linear-gradient(145deg, rgba(232, 245, 242, 0.94), rgba(255, 253, 246, 0.82));
}

#matchView .match-side-controls .buddy-prefs-toggle:active,
#matchView .history-empty-action:active,
#matchView .portrait-retake-btn:active {
  transform: scale(0.97);
}

#matchView .history-card {
  margin: 16px 0 0;
  padding: 20px;
  border-radius: var(--hz-radius-card);
  background: var(--hz-card-bg);
  box-shadow: var(--hz-shadow-card);
}

#matchView .history-head h3 {
  color: var(--hz-ink-strong);
  font-size: 24px;
  font-weight: 950;
}

#matchView .history-head p {
  margin-top: 4px;
  color: var(--hz-muted);
  font-size: 13px;
  font-weight: 850;
}

#matchView .history-list {
  gap: 10px;
}

#matchView .history-empty-card {
  display: grid;
  justify-items: center;
  min-height: 0;
  padding: 16px 16px;
  border: 1px solid var(--hz-line);
  border-radius: var(--hz-radius-card-sm);
  color: var(--hz-muted);
  text-align: center;
  background:
    radial-gradient(circle at 50% 0%, rgba(101, 183, 176, 0.1), transparent 36%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.78), rgba(255, 253, 246, 0.58));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.86),
    0 10px 22px rgba(57, 83, 76, 0.04);
}

#matchView .history-empty-orbit {
  position: relative;
  width: 30px;
  height: 30px;
  margin-bottom: 7px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 50%, var(--hz-teal-500) 0 5px, transparent 6px),
    radial-gradient(circle at 50% 50%, rgba(101, 183, 176, 0.16) 0 16px, transparent 17px);
}

#matchView .history-empty-orbit::after {
  content: "";
  position: absolute;
  right: 1px;
  top: 5px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--hz-coral-500);
  box-shadow: 0 0 0 5px rgba(213, 139, 102, 0.12);
}

#matchView .history-empty-card strong {
  color: var(--hz-ink);
  font-size: 16px;
  font-weight: 950;
  line-height: 1.25;
}

#matchView .history-empty-card p {
  max-width: 230px;
  margin: 5px 0 11px;
  color: var(--hz-muted-soft);
  font-size: 13px;
  font-weight: 760;
  line-height: 1.45;
}

#matchView .history-empty-action {
  width: auto;
  min-height: 34px;
  padding: 0 18px;
  border-radius: var(--hz-radius-pill);
  color: var(--hz-teal-700);
  font-size: 13px;
  font-weight: 950;
  transition:
    transform var(--hz-motion-fast) var(--hz-ease-out),
    box-shadow var(--hz-motion-fast) var(--hz-ease-out);
}

#matchView .history-item {
  padding: 15px 16px 15px 18px;
  border-color: var(--hz-line);
  border-radius: 20px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.84), rgba(255, 253, 246, 0.6));
}

#matchView .history-item::before {
  content: "";
  position: absolute;
  left: 0;
  top: 16px;
  bottom: 16px;
  width: 4px;
  border-radius: 999px;
  background: var(--hz-teal-500);
}

#matchView .history-item span {
  color: var(--hz-ink);
}

#matchView .history-item small {
  color: var(--hz-muted);
}

#matchView .portrait-hero {
  grid-template-columns: 78px minmax(0, 1fr);
  gap: 16px;
  align-items: center;
  margin-top: 28px;
  padding: 20px;
  border-radius: var(--hz-radius-card);
  background:
    radial-gradient(circle at 84% 10%, rgba(101, 183, 176, 0.14), transparent 26%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.9), rgba(255, 253, 246, 0.68));
  box-shadow: var(--hz-shadow-card);
  transition:
    transform var(--hz-motion-fast) var(--hz-ease-out),
    box-shadow var(--hz-motion-fast) var(--hz-ease-out);
}

#matchView .portrait-hero:active {
  transform: scale(0.986);
}

#matchView .portrait-avatar {
  width: 78px;
  height: 104px;
  border-radius: 24px;
}

#matchView .portrait-hero .eyebrow {
  margin-bottom: 5px;
  color: var(--hz-muted);
  font-size: 12px;
  font-weight: 950;
  letter-spacing: 0.02em;
}

#matchView .portrait-title-btn {
  margin: 0 0 5px;
  color: var(--hz-ink-strong);
  font-size: 24px;
  font-weight: 950;
}

#matchView .portrait-title-btn::after {
  content: "点击查看完整画像";
  display: block;
  width: fit-content;
  margin-top: 5px;
  color: var(--hz-teal-700);
  font-size: 12px;
  font-weight: 900;
  line-height: 1.2;
}

#matchView .portrait-hero p:not(.eyebrow) {
  max-width: none;
  color: var(--hz-muted);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.55;
}

#matchView .portrait-retake-btn {
  min-height: 34px;
  margin-top: 12px;
  padding: 0 17px;
  color: var(--hz-ink);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.88), rgba(232, 245, 242, 0.58));
  box-shadow: var(--hz-shadow-card-soft);
}

@keyframes match-card-enter {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes hz-page-header-enter {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes match-focus-pulse {
  0%,
  100% {
    box-shadow: var(--hz-shadow-card);
  }
  45% {
    box-shadow:
      0 0 0 5px rgba(101, 183, 176, 0.16),
      0 24px 48px rgba(57, 83, 76, 0.14),
      inset 0 1px 0 rgba(255, 255, 255, 0.94);
  }
}

@keyframes match-time-flow {
  0% {
    transform: translateX(-115%);
  }
  100% {
    transform: translateX(115%);
  }
}

@media (max-width: 370px) {
  #matchView .match-page-header {
    min-height: 124px;
    padding: 28px 28px 16px;
    border-radius: 0 0 28px 28px;
  }

  #matchView .match-page-title .match-heading {
    font-size: 29px;
  }

  #matchView .match-page-title .page-subtitle {
    font-size: 13px;
  }

  #matchView .match-choice {
    grid-template-columns: minmax(0, 1fr);
    gap: 7px;
    padding: 20px 18px 18px;
  }

  #matchView .check-ring {
    left: 18px;
    top: 22px;
    width: 40px;
    height: 40px;
  }

  #matchView .match-choice.joined .check-ring::after {
    left: 12px;
    top: 12px;
  }

  #matchView .choice-title,
  #matchView .portrait-title-btn {
    font-size: 22px;
  }

  #matchView .choice-title {
    padding-inline: 46px;
  }

  #matchView .card-countdown {
    min-height: 48px;
    font-size: 19px;
  }

  #matchView .history-card {
    padding: 20px 18px;
  }
}

@media (prefers-reduced-motion: reduce) {
  #matchView .match-page-header,
  #matchView .match-choice,
  #matchView .history-card,
  #matchView .portrait-hero,
  #matchView .match-choice.match-focus-pulse,
  #matchView .card-countdown::before {
    animation: none;
  }

  #matchView .match-choice,
  #matchView .history-empty-action,
  #matchView .portrait-retake-btn,
  #matchView .portrait-hero {
    transition: none;
  }
}

/* Activity page product polish: warm dining palette on 52Hz tokens */
#activityView {
  --activity-amber-700: #9D6330;
  --activity-amber-500: #D99A4E;
  --activity-amber-200: #F7D8A9;
  --activity-cream: #FFF4E4;
  color: var(--hz-ink);
}

#activityView .activity-page-header {
  position: relative;
  min-height: 132px;
  padding: 30px 32px 18px;
  overflow: hidden;
  border-bottom: 0;
  border-radius: 0 0 32px 32px;
  background:
    radial-gradient(circle at 84% 16%, rgba(255, 255, 255, 0.62), transparent 24%),
    radial-gradient(circle at 18% 82%, rgba(217, 154, 78, 0.18), transparent 32%),
    linear-gradient(145deg, rgba(255, 253, 246, 0.94), rgba(255, 244, 228, 0.72) 52%, rgba(232, 245, 242, 0.52));
  box-shadow: none;
  backdrop-filter: none;
  animation: hz-page-header-enter var(--hz-motion-normal, 380ms) var(--hz-ease-out, ease-out) both;
}

#activityView .activity-page-header::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(255, 253, 246, 0.12), rgba(255, 253, 246, 0.52)),
    url("./assets/home-campus-bg.svg") center -118px / 126% auto no-repeat;
  opacity: 0.16;
}

#activityView .activity-page-title {
  position: relative;
  z-index: 1;
  display: grid;
  justify-items: start;
  max-width: 300px;
  text-align: left;
}

#activityView .activity-page-kicker {
  margin: 0 0 4px;
  color: var(--hz-muted);
  font-size: 11.5px;
  font-weight: 950;
  line-height: 1;
  letter-spacing: 0.18em;
}

#activityView .activity-page-title .match-heading {
  margin: 0;
  color: var(--hz-ink-strong);
  font-size: 31px;
  font-weight: 950;
  line-height: 1.04;
}

#activityView .activity-page-title .page-subtitle {
  margin: 7px 0 0;
  color: var(--hz-teal-700);
  font-size: 13px;
  font-weight: 850;
  line-height: 1.48;
}

#activityView .activity-hero-card,
#activityView .activity-flow-card,
#activityView .activity-groups-head,
#activityView .activity-groups-card,
#activityView #mobilePromoCard {
  animation: activity-card-enter var(--hz-motion-normal) var(--hz-ease-out) both;
}

#activityView .activity-hero-card {
  animation-delay: 40ms;
}

#activityView .activity-flow-card {
  animation-delay: 90ms;
}

#activityView .activity-groups-head {
  animation-delay: 140ms;
}

#activityView .activity-groups-card {
  animation-delay: 180ms;
}

#activityView #mobilePromoCard {
  animation-delay: 230ms;
}

#activityView .activity-hero-card {
  margin: 22px 0 14px;
  padding: 22px;
  gap: 14px;
  border: 1px solid rgba(255, 255, 255, 0.76);
  border-radius: var(--hz-radius-card-sm);
  color: var(--hz-ink);
  background:
    radial-gradient(circle at 86% 18%, rgba(255, 253, 246, 0.74), transparent 30%),
    radial-gradient(circle at 86% 78%, rgba(217, 154, 78, 0.34), transparent 32%),
    radial-gradient(circle at 14% 12%, rgba(101, 183, 176, 0.15), transparent 26%),
    linear-gradient(145deg, #FFF8EC 0%, #F5C985 58%, #EAA75C 100%);
  box-shadow:
    0 22px 46px rgba(112, 78, 43, 0.13),
    0 8px 18px rgba(52, 126, 121, 0.06),
    inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

#activityView .activity-hero-card::before {
  background:
    radial-gradient(ellipse at 18% 6%, rgba(255, 255, 255, 0.36), transparent 34%),
    linear-gradient(110deg, transparent 32%, rgba(255, 255, 255, 0.24) 48%, transparent 64%);
}

#activityView .activity-hero-card::after {
  border-color: rgba(255, 253, 246, 0.32);
}

#activityView .activity-hero-top {
  align-items: flex-start;
}

#activityView .activity-hero-copy h3 {
  color: var(--hz-ink-strong);
  font-size: 27px;
  line-height: 1.12;
  text-shadow: none;
}

#activityView .activity-hero-side {
  min-width: 92px;
  padding: 11px 13px;
  border-color: rgba(255, 255, 255, 0.6);
  color: var(--hz-ink);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.56), rgba(255, 244, 228, 0.42));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.66),
    0 10px 22px rgba(112, 78, 43, 0.08);
}

#activityView .activity-hero-side .activity-date,
#activityView .activity-hero-side .activity-weekdays,
#activityView .activity-hero-side small {
  color: rgba(38, 54, 49, 0.68);
}

#activityView .activity-hero-side strong {
  color: var(--hz-ink-strong);
}

#activityView .activity-tags {
  gap: 8px;
}

#activityView .activity-tag {
  border-color: rgba(255, 255, 255, 0.58);
  color: var(--activity-amber-700);
  background: rgba(255, 253, 246, 0.56);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.68),
    0 6px 14px rgba(112, 78, 43, 0.06);
}

#activityView .activity-boundary-note {
  color: rgba(38, 54, 49, 0.72);
  font-size: 12.5px;
  font-weight: 820;
}

#activityView .activity-hero-actions {
  gap: 10px;
  margin-top: 2px;
}

#activityView .activity-primary-btn {
  min-height: 48px;
  color: #fff;
  background: var(--hz-button-bg);
  box-shadow: var(--hz-shadow-button);
  transition:
    transform var(--hz-motion-fast) var(--hz-ease-out),
    box-shadow var(--hz-motion-fast) var(--hz-ease-out),
    opacity var(--hz-motion-fast) ease;
}

#activityView .activity-primary-btn:active,
#activityView .activity-flow-link:active,
#activityView .community-more-btn:active,
#activityView .activity-contact-btn:active {
  transform: scale(0.97);
}

#activityView .activity-primary-btn:disabled {
  color: rgba(38, 54, 49, 0.56);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.78), rgba(255, 244, 228, 0.58));
  box-shadow: none;
  cursor: not-allowed;
}

#activityView .activity-primary-btn.is-loading,
#activityView .activity-submit-btn.is-loading {
  opacity: 0.84;
  cursor: wait;
}

#activityView .activity-flow-link {
  min-height: 42px;
  padding: 0 16px;
  border: 1px solid rgba(255, 255, 255, 0.64);
  border-radius: var(--hz-radius-pill);
  color: var(--hz-ink);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.72), rgba(255, 244, 228, 0.46));
  box-shadow: var(--hz-shadow-card-soft);
  text-decoration: none;
  transition:
    transform var(--hz-motion-fast) var(--hz-ease-out),
    box-shadow var(--hz-motion-fast) var(--hz-ease-out);
}

#activityView .activity-flow-card {
  gap: 8px;
  margin: 0 0 28px;
  padding: 16px 14px;
  border: 1px solid rgba(255, 255, 255, 0.76);
  border-radius: var(--hz-radius-card-sm);
  background: var(--hz-card-bg);
  box-shadow: var(--hz-shadow-card-soft);
}

#activityView .activity-flow-step {
  gap: 6px;
}

#activityView .activity-flow-ico {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  color: var(--hz-teal-700);
  background:
    radial-gradient(circle at 72% 22%, rgba(217, 154, 78, 0.16), transparent 24%),
    linear-gradient(145deg, rgba(232, 245, 242, 0.92), rgba(255, 253, 246, 0.8));
  box-shadow: var(--hz-shadow-card-soft);
}

#activityView .activity-flow-ico svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

#activityView .activity-flow-step strong {
  color: var(--hz-ink);
  font-size: 13px;
}

#activityView .activity-flow-step small {
  color: var(--hz-muted);
  font-size: 10.5px;
  line-height: 1.35;
}

#activityView .activity-flow-arrow {
  color: var(--hz-teal-500);
  font-size: 23px;
  font-weight: 950;
}

#activityView .activity-groups-head {
  margin: 0 0 14px;
}

#activityView .activity-groups-head h3 {
  color: var(--hz-ink-strong);
  font-size: 23px;
  line-height: 1.15;
}

#activityView .activity-groups-head p {
  margin-top: 6px;
  color: var(--hz-muted);
}

#activityView .activity-groups-card {
  margin-bottom: 28px;
  border-radius: var(--hz-radius-card-sm);
  background: var(--hz-card-bg);
}

#activityView .community-list-item {
  grid-template-columns: minmax(0, 1fr) 96px;
  gap: 16px;
  padding: 20px;
}

#activityView .community-list-item .community-copy h3 {
  color: var(--hz-ink-strong);
  font-size: 19px;
}

#activityView .community-list-item .community-copy p {
  color: var(--hz-muted);
  font-size: 13px;
}

#activityView .community-master-card .fake-qr,
#activityView .community-qr-img {
  width: 88px;
  height: 88px;
  border-radius: 18px;
}

#activityView .community-more-btn {
  min-height: 46px;
  color: var(--hz-teal-700);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.78), rgba(232, 245, 242, 0.48));
  transition:
    transform var(--hz-motion-fast) var(--hz-ease-out),
    background var(--hz-motion-fast) ease,
    color var(--hz-motion-fast) ease;
}

#activityView .community-extra:not(.hidden) {
  animation: activity-card-enter var(--hz-motion-normal) var(--hz-ease-out) both;
}

#activityView #mobilePromoCard {
  display: grid;
  gap: 12px;
  margin-bottom: 112px;
  padding: 22px;
  border-radius: var(--hz-radius-card-sm);
  background:
    radial-gradient(circle at 82% 18%, rgba(217, 154, 78, 0.12), transparent 28%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.9), rgba(255, 244, 228, 0.58));
  box-shadow: var(--hz-shadow-card);
}

#activityView #mobilePromoCard .eyebrow {
  color: var(--hz-teal-700);
}

#activityView #mobilePromoCard h3 {
  margin: 0;
  color: var(--hz-ink-strong);
  font-size: 24px;
  line-height: 1.2;
}

#activityView .activity-promo-copy {
  margin: 0;
  color: var(--hz-muted);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.6;
}

#activityView .activity-contact-btn {
  width: fit-content;
  min-height: 38px;
  padding: 0 18px;
  border-radius: var(--hz-radius-pill);
  color: var(--hz-teal-700);
  font-size: 13px;
  font-weight: 950;
  transition: transform var(--hz-motion-fast) var(--hz-ease-out);
}

#activityView .contact-promo-media {
  margin-top: 4px;
}

#activityView .contact-promo-image {
  width: 150px;
  height: 104px;
  border-radius: 18px;
  box-shadow: var(--hz-shadow-card-soft);
}

@keyframes activity-card-enter {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 370px) {
  #activityView .activity-page-header {
    min-height: 124px;
    padding: 28px 28px 16px;
  }

  #activityView .activity-page-title .match-heading {
    font-size: 29px;
  }

  #activityView .activity-page-title .page-subtitle {
    font-size: 13px;
  }

  #activityView .activity-hero-card {
    padding: 20px 18px;
  }

  #activityView .activity-hero-copy h3 {
    font-size: 24px;
  }

  #activityView .activity-flow-card {
    padding: 14px 10px;
  }
}

@media (prefers-reduced-motion: reduce) {
  #activityView .activity-page-header,
  #activityView .activity-hero-card,
  #activityView .activity-flow-card,
  #activityView .activity-groups-head,
  #activityView .activity-groups-card,
  #activityView #mobilePromoCard,
  #activityView .community-extra:not(.hidden) {
    animation: none;
  }

  #activityView .activity-primary-btn,
  #activityView .activity-flow-link,
  #activityView .community-more-btn,
  #activityView .activity-contact-btn {
    transition: none;
  }
}

/* 验证码弹窗 */
.captcha-modal-card { text-align: center; max-width: 360px; }
.captcha-modal-card .cf-turnstile { display: flex; justify-content: center; margin-top: 12px; }
.captcha-modal-sub { color: var(--muted, #8a8f98); font-size: 13px; margin: 6px 0 4px; }
.captcha-modal-status { margin-top: 10px; font-size: 13px; color: #2BB673; font-weight: 600; min-height: 18px; }

#captchaModal { z-index: 9000; }

/* 倒计时归零「查看详情」副标题 + 历史记录挪入过渡 */
.countdown.ready .cd-sub { display:block; font-size:11px; font-weight:400; opacity:.7; margin-top:2px; }
.history-item { animation: histItemIn .32s ease both; }
@keyframes histItemIn { from { opacity:0; transform: translateY(-6px); } to { opacity:1; transform:none; } }

/* 本期未成「缘分未到」态 */
.countdown.concluded { color: var(--muted,#8a8f98); font-weight:600; cursor:pointer; }
.countdown.concluded .cd-sub { color: var(--brand,#57B7B7); }

/* 更换头像弹窗 */
.account-action-row { display:flex; gap:10px; }
.account-action-row .secondary-btn, .account-action-row .primary-btn { flex:1; }
.avatar-modal-card .avatar-grid { display:grid; grid-template-columns: repeat(3, 1fr); gap:10px; max-height:56vh; overflow-y:auto; margin-top:10px; }
.avatar-tile { display:flex; flex-direction:column; align-items:center; gap:4px; padding:8px; border:2px solid transparent; border-radius:14px; background:rgba(255,255,255,.5); cursor:pointer; }
.avatar-tile img, .avatar-tile .avatar-def { width:60px; height:60px; border-radius:50%; object-fit:cover; display:flex; align-items:center; justify-content:center; background:#e6f3f1; font-size:22px; }
.avatar-tile small { font-size:11px; color:#7a8a86; text-align:center; line-height:1.2; }
.avatar-tile.sel { border-color:#57B7B7; background:#e6f3f1; }

/* 人设选择弹窗 */
#personaModal { z-index: 9100; }
.persona-modal-card {
  width: min(92vw, 430px);
  max-height: calc(100vh - 32px);
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  padding: 24px;
  border-radius: 30px;
  background:
    radial-gradient(circle at 78% 8%, rgba(255, 154, 61, .16), transparent 32%),
    radial-gradient(circle at 18% 18%, rgba(87, 183, 183, .14), transparent 34%),
    rgba(255, 253, 246, .9);
  box-shadow: 0 24px 70px rgba(42, 58, 46, .18), inset 0 1px 0 rgba(255,255,255,.86);
  border: 1px solid rgba(87, 183, 183, .18);
  animation: personaModalIn .32s cubic-bezier(.2,.8,.2,1) both;
}
.persona-modal-head { display: grid; gap: 6px; margin-bottom: 18px; }
.persona-eyebrow {
  width: fit-content;
  padding: 5px 12px;
  border-radius: 999px;
  color: var(--warm-deep, #E87522);
  background: rgba(253, 235, 216, .86);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.persona-modal-head h2 {
  margin: 0;
  color: var(--ink);
  font-size: 25px;
  line-height: 1.18;
  letter-spacing: 0;
}
.persona-modal-head p,
.persona-modal-hint,
.persona-empty {
  margin: 0;
  color: var(--muted, #6F7A70);
  font-size: 13px;
  line-height: 1.55;
}
.persona-options { display: grid; gap: 12px; }
.persona-card {
  position: relative;
  display: grid;
  grid-template-columns: 74px 1fr;
  grid-template-areas:
    "avatar badge"
    "avatar title"
    "avatar copy";
  align-items: center;
  column-gap: 14px;
  width: 100%;
  padding: 13px 14px;
  border: 1.5px solid rgba(87, 183, 183, .16);
  border-radius: 22px;
  color: var(--ink);
  text-align: left;
  background: rgba(255, 255, 255, .7);
  box-shadow: 0 12px 28px rgba(70, 120, 113, .07);
  cursor: pointer;
  animation: personaCardIn .38s cubic-bezier(.2,.8,.2,1) both;
  animation-delay: var(--persona-delay, 0ms);
  transition: transform .18s cubic-bezier(.2,.8,.2,1), border-color .18s ease, box-shadow .18s ease, background .18s ease;
}
.persona-card:active { transform: scale(.985); }
.persona-card.is-selected {
  border-color: rgba(87, 183, 183, .75);
  background:
    radial-gradient(circle at 85% 16%, rgba(255, 154, 61, .16), transparent 34%),
    rgba(230, 243, 241, .82);
  box-shadow: 0 18px 34px rgba(87, 183, 183, .16);
}
.persona-card.is-selected::after {
  content: "✓";
  position: absolute;
  right: 14px;
  top: 14px;
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: #fff;
  background: linear-gradient(135deg, var(--brand, #57B7B7), var(--brand-deep, #3E9595));
  font-size: 14px;
  font-weight: 900;
}
.persona-card-avatar {
  grid-area: avatar;
  width: 74px;
  aspect-ratio: 1 / 1;
  border-radius: 22%;
  object-fit: cover;
  background: #fff;
  border: 3px solid rgba(255,255,255,.9);
  box-shadow: 0 12px 28px rgba(42, 58, 46, .14), inset 0 1px 0 rgba(255,255,255,.9);
}
.persona-card-badge {
  grid-area: badge;
  width: fit-content;
  margin-bottom: 3px;
  padding: 3px 9px;
  border-radius: 999px;
  color: var(--warm-deep, #E87522);
  background: rgba(253, 235, 216, .92);
  font-size: 11px;
  font-weight: 900;
}
.persona-card strong {
  grid-area: title;
  padding-right: 34px;
  color: var(--ink);
  font-size: 18px;
  line-height: 1.25;
}
.persona-card small {
  grid-area: copy;
  margin-top: 3px;
  color: var(--muted, #6F7A70);
  font-size: 12px;
  line-height: 1.4;
}
.persona-submit-btn { width: 100%; margin-top: 16px; }
.persona-modal-hint { margin-top: 12px; text-align: center; }

@supports (height: 100dvh) {
  .portrait-modal,
  .non-campus-gate,
  .report-modal,
  .edit-profile-modal,
  .persona-modal-card,
  #loginModal .login-modal-card .login-card,
  #setPasswordModal .login-modal-card .login-card {
    max-height: calc(100dvh - 24px);
  }

  .edit-profile-modal.match-onboarding-profile,
  .activity-signup-sheet,
  .buddy-pref-sheet,
  .topic-pick-sheet,
  .letter-modal {
    max-height: min(88dvh, calc(100dvh - 20px));
  }

  .post-detail-sheet {
    max-height: min(78dvh, calc(100dvh - 18px));
  }
}

@media (max-width: 420px), (max-height: 760px) {
  .modal-backdrop {
    place-items: center;
    padding: max(8px, env(safe-area-inset-top)) max(8px, env(safe-area-inset-right)) max(8px, env(safe-area-inset-bottom)) max(8px, env(safe-area-inset-left));
  }

  .persona-modal-card {
    width: min(calc(100vw - 16px), 410px);
    padding: 18px;
    border-radius: 26px;
  }

  .persona-modal-head {
    gap: 4px;
    margin-bottom: 12px;
  }

  .persona-modal-head h2 {
    font-size: 22px;
  }

  .persona-options {
    gap: 9px;
  }

  .persona-card {
    grid-template-columns: 60px 1fr;
    column-gap: 11px;
    padding: 10px 12px;
    border-radius: 19px;
  }

  .persona-card-avatar {
    width: 60px;
  }

  .persona-card strong {
    font-size: 16px;
  }

  .persona-modal-hint {
    font-size: 12px;
    line-height: 1.45;
  }
}
.portrait-avatar.is-ios-avatar {
  width: 108px;
  height: 108px;
  border-radius: 24px;
  background: rgba(255,255,255,.7);
  box-shadow: 0 16px 34px rgba(70,120,113,.16), 0 0 0 5px rgba(255,255,255,.72);
}
#profileAvatarSmall.is-ios-avatar {
  width: 54px;
  height: 54px;
  border-radius: 15px;
}
@keyframes personaModalIn {
  from { opacity: 0; transform: translateY(12px) scale(.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes personaCardIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Hzid 公开身份号 */
.profile-hzid { margin-top:4px; padding:2px 8px; border:1px dashed #c9d6d2; border-radius:8px; background:transparent; font-size:12px; color:#5a7a72; letter-spacing:.5px; cursor:pointer; font-family:inherit; }
.profile-hzid:active { background:#eef5f3; }

/* 对话已结束提示：内容居中 + 单按钮满宽 */
.chat-ended-card { text-align: center; }
.chat-ended-card h2 { padding-right: 0; }
.chat-ended-card .modal-actions { grid-template-columns: 1fr; }
.quiz-skip-login {
  display: block;
  margin: 18px auto 0;
  padding: 10px 18px;
  border: 0;
  background: transparent;
  color: var(--text-muted, #72817d);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  transition: color 180ms ease, transform 180ms ease;
}
.quiz-skip-login:active { transform: scale(.97); }
.quiz-skip-login:hover { color: var(--primary, #3ba7a2); }
.activity-event-switcher {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding: 0 2px 14px;
  scrollbar-width: none;
}
.activity-event-switcher::-webkit-scrollbar { display: none; }

.profile-page-view.is-guest-preview > article:not(.profile-guest-gate) {
  filter: blur(4px);
  opacity: .28;
  pointer-events: none;
}

.profile-guest-gate {
  margin: 20px 24px;
  padding: 24px;
  text-align: center;
}

.profile-guest-gate h3 { margin: 8px 0 10px; }
.profile-guest-gate p { color: var(--text-muted); line-height: 1.7; }
.activity-event-chip {
  flex: 0 0 auto;
  border: 1px solid rgba(64, 153, 148, .22);
  border-radius: 999px;
  padding: 9px 14px;
  background: rgba(255, 255, 255, .72);
  color: #657672;
  font: inherit;
  font-weight: 700;
}
.activity-event-chip.active {
  background: rgba(75, 174, 168, .14);
  border-color: rgba(57, 157, 151, .45);
  color: #278d88;
}

.policy-body .policy-meta{color:#9aa39a;font-size:12px;margin:0 0 10px}

/* 验证码弹窗：标题/副标题移到验证码下方，缩小、不喧宾夺主 */
.captcha-caption { text-align: center; margin: 12px 0 2px; }
.captcha-caption h3 { font-size: 15px; font-weight: 700; margin: 0 0 3px; color: #2A3A2E; }
.captcha-caption .captcha-modal-sub { font-size: 12px; line-height: 1.5; color: #8a948c; margin: 0; }

/* 验证码弹窗：外框贴合验证码区域 + 小巧关闭按钮 */
.captcha-modal-card { width: fit-content; max-width: 94vw; padding: 30px 14px 14px; margin: 0 auto; }
.captcha-modal-card .modal-close { width: 26px; height: 26px; line-height: 24px; font-size: 16px; top: 6px; right: 8px; padding: 0; }
.captcha-modal-card #loginCaptcha { display: flex; justify-content: center; }

/* ── 其他院校：开放院校提示条 + 小窗 ── */
.open-schools-bar {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  width: fit-content; max-width: 100%; margin: 14px auto 4px; padding: 10px 18px;
  background: rgba(87,183,183,.10); border: 1px solid rgba(87,183,183,.28);
  border-radius: 999px; cursor: pointer; font-size: 13px; color: #2A3A2E;
}
.open-schools-bar b { color: #3E9595; font-weight: 700; white-space: nowrap; }
.open-schools-bar:active { filter: brightness(.97); }

.schools-modal, .unlock-modal { text-align: center; max-width: 340px; }
.schools-modal h2, .unlock-modal h2 { font-size: 19px; margin: 4px 0 8px; }
.schools-sub { color: #6F7A70; font-size: 13px; margin: 0 0 12px; }
.schools-list { list-style: none; margin: 0 0 14px; padding: 0; display: grid; gap: 8px; }
.schools-list li {
  padding: 11px 14px; border-radius: 12px; font-weight: 700; color: #2A3A2E;
  background: linear-gradient(160deg,#fff 0%, #E6F3F1 140%); border: 1px solid rgba(80,130,130,.16);
}
.schools-modal .schools-foot { color: #3E9595; font-weight: 600; font-size: 12px; line-height: 1.6; margin: 8px 0 0; }
.unlock-foot { color: #8a948c; font-size: 12px; line-height: 1.6; margin: 4px 0 0; }
.unlock-emoji { font-size: 40px; margin: 6px 0 2px; }
.unlock-sub { color: #6F7A70; font-size: 13.5px; line-height: 1.6; margin: 0 0 16px; }
.unlock-modal .primary-btn { width: 100%; margin-bottom: 10px; }

/* ── 活动页：其他院校「暂未开放」 ── */
.activity-locked-banner {
  display: flex; align-items: center; gap: 11px; margin: 4px 16px 14px;
  padding: 13px 15px; border-radius: 14px;
  background: rgba(255,170,90,.10); border: 1px solid rgba(230,150,70,.26);
}
.activity-locked-emoji { font-size: 22px; line-height: 1; }
.activity-locked-copy { flex: 1; min-width: 0; }
.activity-locked-copy strong { display: block; font-size: 14px; color: #6a4a22; }
.activity-locked-copy p { margin: 3px 0 0; font-size: 12.5px; color: #8a724f; line-height: 1.5; }
.activity-locked-link {
  flex-shrink: 0; align-self: flex-start; background: none; border: none;
  color: #d6892f; font-weight: 700; font-size: 12.5px; cursor: pointer; padding: 2px 0;
}
.activity-hero-card.is-locked { opacity: .55; filter: grayscale(.35); }

/* ── 个人中心：其他院校匹配项灰卡 ── */
.profile-status-tile.is-locked { opacity: .5; position: relative; cursor: pointer; }
.profile-status-tile.is-locked::after {
  content: "🔒"; position: absolute; top: 6px; right: 8px; font-size: 11px; opacity: .7;
}

/* ── 内测信「广告位」banner + 弹窗 ── */
.letter-promo-banner {
  display: flex; align-items: center; gap: 11px;
  width: 100%; margin: 16px 0 0; padding: 13px 16px;
  background: linear-gradient(135deg, rgba(87,183,183,.14), rgba(255,154,61,.12));
  border: 1px solid rgba(87,183,183,.30); border-radius: 16px;
  cursor: pointer; text-align: left;
}
.letter-promo-banner:active { filter: brightness(.97); }
.letter-promo-icon { font-size: 26px; line-height: 1; flex-shrink: 0; }
.letter-promo-text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.letter-promo-text b { font-size: 14px; color: #2A3A2E; }
.letter-promo-text small { font-size: 12px; color: #6F7A70; }
.letter-promo-arrow { flex-shrink: 0; color: #3E9595; font-size: 20px; font-weight: 700; }

.letter-modal { max-width: 360px; max-height: 82vh; display: flex; flex-direction: column; padding: 22px 4px 18px; text-align: left; }
.letter-scroll { overflow-y: auto; padding: 0 18px; -webkit-overflow-scrolling: touch; }
.letter-title { font-size: 18px; text-align: center; margin: 0 0 16px; padding: 0 30px; }
.letter-scroll p { font-size: 13.5px; line-height: 1.85; color: #3a4a40; margin: 0 0 12px; }
.letter-scroll p b { color: #2A3A2E; }
.letter-scroll .letter-emph { color: #3E9595; font-weight: 600; }
.letter-scroll .letter-green { color: #3E9595; font-weight: 700; }
.letter-scroll .letter-wechat { font-size: 17px; color: #3E9595; letter-spacing: 1px; }
.letter-sign { text-align: right; color: #6F7A70; margin-top: 4px; }

/* 聊天气泡头像：图片填满头像框（圆角跟随容器）*/
.chat-avatar:has(img) { color: transparent; box-shadow: none; }
.chat-avatar img { width: 100%; height: 100%; object-fit: cover; border-radius: inherit; display: block; }

/* ── 全局弹窗居中规范：所有弹窗卡片默认上下居中，长内容在卡片内滚动 ── */
.modal-backdrop:not(.hidden) {
  display: grid;
  place-items: center;
  align-content: center;
  justify-content: center;
  padding:
    max(14px, env(safe-area-inset-top))
    max(14px, env(safe-area-inset-right))
    max(14px, env(safe-area-inset-bottom))
    max(14px, env(safe-area-inset-left));
}

.modal-backdrop > .glass-card,
.modal-backdrop > .portrait-modal,
.modal-backdrop > .report-modal,
.modal-backdrop > .edit-profile-modal,
.modal-backdrop > .login-modal-card,
.modal-backdrop > .persona-modal-card,
.modal-backdrop > .activity-signup-sheet,
.modal-backdrop > .buddy-pref-sheet,
.modal-backdrop > .topic-pick-sheet,
.modal-backdrop > .post-detail-sheet,
.modal-backdrop > .share-preview-modal,
.modal-backdrop > .portrait-image-preview-card,
.modal-backdrop > .non-campus-gate {
  margin: auto;
}

.report-modal,
.edit-profile-modal,
.portrait-modal,
.persona-modal-card,
.activity-signup-sheet,
.buddy-pref-sheet,
.topic-pick-sheet,
.post-detail-sheet,
.share-preview-modal,
.portrait-image-preview-card,
.non-campus-gate,
#loginModal .login-modal-card,
#setPasswordModal .login-modal-card,
#loginModal .login-card,
#setPasswordModal .login-card,
#changePasswordModal .edit-profile-modal {
  max-height: calc(100dvh - 28px);
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

.report-modal:not(.letter-modal):not(.policy-modal),
.captcha-modal-card,
.persona-modal-card,
.avatar-modal-card,
.schools-modal,
.unlock-modal,
.first-join-modal,
.chat-ended-card,
.cancel-match-modal {
  align-content: center;
}

#loginModal .login-card {
  display: grid;
  align-content: center;
}

@media (max-width: 420px), (max-height: 760px) {
  .modal-backdrop:not(.hidden) {
    place-items: center;
    padding:
      max(10px, env(safe-area-inset-top))
      max(8px, env(safe-area-inset-right))
      max(10px, env(safe-area-inset-bottom))
      max(8px, env(safe-area-inset-left));
  }

  .report-modal,
  .edit-profile-modal,
  .portrait-modal,
  .persona-modal-card,
  .activity-signup-sheet,
  .buddy-pref-sheet,
  .topic-pick-sheet,
  .post-detail-sheet,
  .share-preview-modal,
  .portrait-image-preview-card,
  .non-campus-gate,
  #loginModal .login-modal-card,
  #setPasswordModal .login-modal-card,
  #loginModal .login-card,
  #setPasswordModal .login-card,
  #changePasswordModal .edit-profile-modal {
    max-height: calc(100dvh - 20px);
  }
}

/* 匹配前资料弹窗：压回手机安全宽度，避免表单控件撑出卡片 */
#editProfileModal .edit-profile-modal.match-onboarding-profile {
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  width: min(calc(100vw - 32px), 376px);
  max-height: min(86dvh, 640px);
  padding: 20px 18px 16px;
  overflow: hidden;
  border-radius: 30px;
}

#editProfileModal .edit-profile-modal.match-onboarding-profile .modal-close {
  top: 16px;
  right: 16px;
  width: 42px;
  height: 42px;
}

#editProfileModal .edit-profile-modal.match-onboarding-profile h2 {
  margin: 0 52px 6px 0;
  font-size: 24px;
  line-height: 1.14;
}

#editProfileModal .edit-profile-modal.match-onboarding-profile > p {
  margin: 0 42px 14px 0;
  color: rgba(35, 57, 51, 0.68);
  font-size: 13px;
  line-height: 1.5;
}

#editProfileModal .edit-profile-modal.match-onboarding-profile form {
  display: grid;
  gap: 10px;
  min-height: 0;
  margin: 0 -2px;
  padding: 0 2px 2px;
  overflow-y: auto;
  overflow-x: hidden;
  scrollbar-width: thin;
}

#editProfileModal .edit-profile-modal.match-onboarding-profile form > label,
#editProfileModal .edit-profile-modal.match-onboarding-profile .two-grid label {
  min-width: 0;
  margin: 0;
  gap: 7px;
  color: #233933;
  font-size: 13px;
  font-weight: 900;
}

#editProfileModal .edit-profile-modal.match-onboarding-profile .two-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 0;
}

#editProfileModal .edit-profile-modal.match-onboarding-profile input,
#editProfileModal .edit-profile-modal.match-onboarding-profile textarea,
#editProfileModal .edit-profile-modal.match-onboarding-profile .ios-select,
#editProfileModal .edit-profile-modal.match-onboarding-profile .ios-select-trigger {
  box-sizing: border-box;
  width: 100%;
  max-width: 100%;
  min-width: 0;
}

#editProfileModal .edit-profile-modal.match-onboarding-profile input,
#editProfileModal .edit-profile-modal.match-onboarding-profile textarea,
#editProfileModal .edit-profile-modal.match-onboarding-profile .ios-select-trigger {
  margin-top: 0;
  border: 1px solid rgba(219, 235, 231, 0.9);
  background: rgba(255, 255, 255, 0.78);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.76);
}

#editProfileModal .edit-profile-modal.match-onboarding-profile input,
#editProfileModal .edit-profile-modal.match-onboarding-profile .ios-select-trigger {
  min-height: 46px;
  padding: 0 14px;
  border-radius: 17px;
}

#editProfileModal .edit-profile-modal.match-onboarding-profile textarea {
  min-height: 78px;
  max-height: 118px;
  padding: 13px 14px;
  border-radius: 18px;
}

#editProfileModal .edit-profile-modal.match-onboarding-profile .field-name {
  margin: 0 0 7px;
  color: #233933;
  font-size: 13px;
  font-weight: 900;
}

#editProfileModal .edit-profile-modal.match-onboarding-profile .chip-grid {
  flex-wrap: wrap;
  gap: 8px;
  max-height: 84px;
  margin: 0;
  padding: 0 2px 2px;
  overflow-x: hidden;
  overflow-y: auto;
}

#editProfileModal .edit-profile-modal.match-onboarding-profile .chip {
  flex: 0 0 auto;
  min-height: 36px;
  padding: 7px 12px;
  border-color: rgba(219, 235, 231, 0.9);
  color: rgba(35, 57, 51, 0.66);
  font-size: 13px;
  font-weight: 900;
  background: rgba(255, 255, 255, 0.78);
  transition: transform 0.14s ease, color 0.16s ease, background 0.16s ease, box-shadow 0.16s ease;
}

#editProfileModal .edit-profile-modal.match-onboarding-profile .chip:active {
  transform: scale(0.96);
}

#editProfileModal .edit-profile-modal.match-onboarding-profile .chip.selected {
  color: #fff;
  border-color: transparent;
  background: linear-gradient(135deg, #4ba6a2 0%, #76c9c2 100%);
  box-shadow: 0 10px 20px rgba(87, 183, 183, 0.18);
}

#editProfileModal .edit-profile-modal.match-onboarding-profile .primary-btn {
  position: sticky;
  bottom: 0;
  z-index: 3;
  min-height: 50px;
  margin-top: 4px;
  border-radius: 20px;
  box-shadow:
    0 -10px 22px rgba(255, 253, 247, 0.88),
    0 14px 28px rgba(43, 135, 127, 0.18);
}

@media (max-width: 370px), (max-height: 700px) {
  #editProfileModal .edit-profile-modal.match-onboarding-profile {
    width: min(calc(100vw - 24px), 352px);
    max-height: calc(100dvh - 24px);
    padding: 17px 15px 14px;
    border-radius: 27px;
  }

  #editProfileModal .edit-profile-modal.match-onboarding-profile h2 {
    font-size: 22px;
  }

  #editProfileModal .edit-profile-modal.match-onboarding-profile > p {
    margin-right: 34px;
    font-size: 12.5px;
  }

  #editProfileModal .edit-profile-modal.match-onboarding-profile input,
  #editProfileModal .edit-profile-modal.match-onboarding-profile .ios-select-trigger {
    min-height: 43px;
  }

  #editProfileModal .edit-profile-modal.match-onboarding-profile textarea {
    min-height: 68px;
  }

#editProfileModal .edit-profile-modal.match-onboarding-profile .chip-grid {
    max-height: 74px;
  }
}

/* 匹配页画像卡：头像统一为 1:1 iOS 风格 */
#matchView #portraitHeroCard {
  grid-template-columns: 96px minmax(0, 1fr);
}

#matchView #portraitHeroCard #portraitAvatar {
  width: 96px;
  height: 96px;
  aspect-ratio: 1 / 1;
  border: 3px solid rgba(255, 255, 255, 0.88);
  border-radius: 22%;
  background: rgba(255, 255, 255, 0.72);
  box-shadow:
    0 16px 34px rgba(70, 120, 113, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

#matchView #portraitHeroCard #portraitAvatar .portrait-avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  border-radius: inherit;
}

#matchView #portraitHeroCard > div:last-child {
  min-width: 0;
}

@media (max-width: 370px), (max-height: 700px) {
  #matchView #portraitHeroCard {
    grid-template-columns: 82px minmax(0, 1fr);
    gap: 13px;
  }

  #matchView #portraitHeroCard #portraitAvatar {
    width: 82px;
    height: 82px;
  }
}
