/* Sidebar */
.sidebar {
  /* §12 R9: 节奏整体收短到 0.28s，更接近"门帘左右拉过"的覆盖手感 */
  --sidebar-toggle-ease: cubic-bezier(0.22, 1, 0.36, 1);
  --sidebar-toggle-duration: 0.28s;
  /* Codex 在 feat/haz174 上加了 sidebar 可拖拽，--sidebar-width 由 JS 写 inline var；
     未注入时回退 216px，与 main R1–R13 行为一致。 */
  width: var(--sidebar-width, 216px);
  flex: 0 0 var(--sidebar-width, 216px);
  background: var(--color-sidebar);
  border-right: 1px solid var(--color-border);
  display: flex;
  flex-direction: column;
  z-index: 10;
  position: relative;
  overflow: visible;
  transition:
    width var(--sidebar-toggle-duration) var(--sidebar-toggle-ease),
    flex-basis var(--sidebar-toggle-duration) var(--sidebar-toggle-ease),
    background-color var(--duration-base) var(--ease-out),
    border-color var(--duration-base) var(--ease-out);
}

.sidebar-header {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  padding: 24px 20px;
  transition: padding var(--sidebar-toggle-duration) var(--sidebar-toggle-ease);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  transition:
    gap var(--sidebar-toggle-duration) var(--sidebar-toggle-ease),
    transform var(--sidebar-toggle-duration) var(--sidebar-toggle-ease);
}

.logo-mark {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  background: var(--primary);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.2rem;
}

/* HAZ brand logo refresh：旧 [圆形图标 + Ahamoment + 内容运营工作台] 模块整块换成
   横向一体 lockup。侧栏展开时显示 lockup-image，折叠时显示 mark-image，
   不保留任何旧文字副标。 */
.brand-lockup {
  text-decoration: none;
  color: inherit;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  min-width: 0;
  width: 134px;
  height: 28px;
  flex: 0 0 auto;
  overflow: hidden;
}

.brand-lockup-image {
  display: block;
  height: 28px;
  width: 134px;
  max-width: none;
  object-fit: contain;
  object-position: left center;
  flex: 0 0 134px;
  transition: opacity 0.14s ease;
}

.brand-mark-image {
  display: none;
  width: 32px;
  height: 32px;
  flex: 0 0 32px;
  object-fit: contain;
  object-position: center;
}

body.sidebar-collapsed .brand-lockup-image {
  display: none;
}

body.sidebar-collapsed .brand-mark-image {
  display: block;
}

.sidebar-nav {
  flex: 1;
  padding: 0 10px;
  overflow-y: auto;
  transition:
    padding var(--sidebar-toggle-duration) var(--sidebar-toggle-ease),
    opacity 0.18s ease;
}

.sidebar-nav ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  /* §12: 侧栏项间距收紧，让高亮 chip 之间更近一档 */
  gap: 1px;
}

.sidebar-nav li {
  min-width: 0;
}

.sidebar-feedback-item {
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid color-mix(in srgb, var(--color-border) 72%, transparent);
}

.nav-item {
  display: flex;
  align-items: center;
  /* §12: chip 内 icon↔文字间距收紧一档 */
  gap: 8px;
  width: 100%;
  /* §12: 高亮 chip 自身缩小一档（视觉更克制，仍然能凸显选中） */
  padding: 6px 10px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  background: transparent;
  color: var(--text-muted);
  font-weight: 500;
  cursor: pointer;
  font: inherit;
  font-size: var(--text-control);
  text-align: left;
  /* §12 R8: chip 内部裁掉溢出，让 nav-label 在父侧栏收窄时不会自己换行/抖动 */
  overflow: hidden;
  transition:
    width 0.24s var(--sidebar-toggle-ease),
    min-height 0.24s var(--sidebar-toggle-ease),
    padding 0.24s var(--sidebar-toggle-ease),
    background var(--duration-base) var(--ease-out),
    border-color var(--duration-base) var(--ease-out),
    color var(--duration-base) var(--ease-out),
    transform 0.16s var(--sidebar-toggle-ease);
}

/* §12 R8/R9（main 上线版本）：nav-label 保持自然宽度 + nowrap，不被 flex 压缩。
   覆盖效果靠 mask-size 动画：一条左对齐的渐变 mask，收起时 mask 从 100% 收到 0%，
   文字从右往左被渐变盖掉；展开时反过来。opacity 只做最后一层兜底淡入淡出。 */
.nav-label {
  flex: 0 1 auto;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  opacity: 1;
  pointer-events: auto;
  -webkit-mask-image: none;
  mask-image: none;
  transition: opacity 0.12s ease;
}

.nav-icon {
  width: 18px;
  height: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 18px;
}

.nav-icon svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  stroke-width: 1.8;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.sidebar-feedback-button {
  color: color-mix(in srgb, var(--primary) 78%, var(--text-muted));
  background: color-mix(in srgb, var(--primary-soft) 20%, transparent);
}

.sidebar-feedback-button:hover,
.sidebar-feedback-button:focus-visible {
  color: var(--text-main);
  border-color: color-mix(in srgb, var(--primary) 30%, var(--color-border));
  background: color-mix(in srgb, var(--primary-soft) 44%, var(--color-card));
}


.sidebar-footer {
  padding: 16px;
  border-top: 1px solid var(--color-border);
  transition: padding 0.24s var(--sidebar-toggle-ease);
}

.sidebar-shell-toggle {
  position: absolute;
  top: 50%;
  right: -15px;
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  /* §12 嵌入式：去厚描边与重阴影，仅保留 1px hairline + 与侧栏融合的底色 */
  border: 1px solid color-mix(in srgb, var(--color-border) 70%, transparent);
  border-radius: 999px;
  background: color-mix(in srgb, var(--color-card) 96%, var(--color-sidebar));
  color: var(--text-muted);
  cursor: pointer;
  box-shadow: none;
  transform: translateY(-50%);
  transition:
    right var(--sidebar-toggle-duration) var(--sidebar-toggle-ease),
    background var(--duration-base) var(--ease-out),
    border-color var(--duration-base) var(--ease-out),
    color var(--duration-base) var(--ease-out),
    box-shadow var(--duration-base) var(--ease-out),
    transform 0.24s var(--sidebar-toggle-ease);
}

.sidebar-shell-toggle:hover,
.sidebar-shell-toggle:focus-visible {
  background: var(--secondary);
  border-color: color-mix(in srgb, var(--color-border-strong) 80%, transparent);
  color: var(--text-main);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 10%, transparent);
  transform: translateY(-50%);
}

.sidebar-shell-toggle:active {
  transform: translateY(-50%) scale(0.96);
}

.sidebar-shell-toggle svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: transform 0.26s var(--sidebar-toggle-ease);
}

body.sidebar-collapsed .sidebar {
  width: 64px;
  flex: 0 0 64px;
  flex-basis: 64px;
}

body.sidebar-collapsed .sidebar-header {
  align-items: center;
  gap: 8px;
  padding: 16px 10px 14px;
}

body.sidebar-collapsed .brand {
  justify-content: center;
  gap: 0;
}

body.sidebar-collapsed .brand-lockup {
  width: 32px;
  height: 32px;
  flex-basis: auto;
}

/* HAZ brand logo refresh：旧 .brand > div（含 "Ahamoment / 内容运营工作台"）已删除，
   折叠态下不再需要相关 mask/opacity 收纳；仅保留兜底兼容 */
body.sidebar-collapsed .brand > div {
  display: none;
}

body.sidebar-collapsed .user-details,
body.sidebar-collapsed .auth-logout {
  display: none;
}

body.sidebar-collapsed .sidebar-shell-toggle {
  right: -15px;
}

body.sidebar-collapsed .sidebar-shell-toggle svg {
  transform: rotate(180deg);
}

body.sidebar-collapsed .sidebar-nav {
  padding: 0 8px;
  overflow: visible;
}

body.sidebar-collapsed .sidebar-nav ul {
  align-items: center;
}

body.sidebar-collapsed .sidebar-feedback-item {
  width: 42px;
  margin-top: 8px;
  padding-top: 8px;
}

body.sidebar-collapsed .nav-item {
  position: relative;
  width: 42px;
  min-height: 42px;
  justify-content: center;
  padding: 9px;
  /* §12 R9: 收起态把 gap 收 0；否则 nav-label 即使 width:0，flex gap 8px 还会占位，
     把 icon 推到 chip 偏左 4px，看起来高亮没居中。 */
  gap: 0;
}

body.sidebar-collapsed .nav-label {
  opacity: 0;
  pointer-events: none;
  flex-basis: 0;
  flex-grow: 0;
  flex-shrink: 0;
  min-width: 0;
  width: 0;
  -webkit-mask-image: none;
  mask-image: none;
  transition:
    opacity 0.08s ease,
    flex-basis 0s linear 0.12s,
    width 0s linear 0.12s;
}

body.sidebar-collapsed .nav-item.active::before {
  content: "";
  position: absolute;
  left: -8px;
  top: 10px;
  bottom: 10px;
  width: 3px;
  border-radius: 999px;
  background: var(--primary);
}

body.sidebar-collapsed .nav-item:hover::after,
body.sidebar-collapsed .nav-item:focus-visible::after {
  display: none;
  content: none;
}

body.sidebar-collapsed .sidebar-footer {
  padding: 10px 8px;
}

body.sidebar-collapsed .login-entry {
  justify-content: center;
  padding: 6px;
}

@media (prefers-reduced-motion: reduce) {
  .sidebar,
  .sidebar-header,
  .brand,
  .brand > div,
  .brand-lockup-image,
  .brand-mark-image,
  .sidebar-nav,
  .sidebar-footer,
  .sidebar-shell-toggle,
  .sidebar-shell-toggle svg,
  .nav-item {
    transition-duration: 0.01ms !important;
  }
}

.user-info,
.login-entry {
  display: flex;
  align-items: center;
  gap: 10px;
}

.login-entry {
  width: 100%;
  color: var(--text-main);
  text-decoration: none;
  border: 1px solid transparent;
  border-radius: var(--radius-md);
  padding: 8px;
  background: transparent;
  min-width: 0;
}

.login-entry:hover {
  background: var(--secondary);
  border-color: var(--color-border);
}

.muted-entry {
  color: var(--text-muted);
}

.authed-entry {
  align-items: flex-start;
  padding-right: 6px;
}

.user-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--secondary);
  border: 1px solid var(--color-border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  overflow: hidden;
  flex: 0 0 32px;
}

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

.user-details {
  min-width: 0;
  flex: 1;
}

.user-details-inline {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
}

.user-name {
  font-weight: 600;
  font-size: 0.85rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.user-role {
  font-size: 0.75rem;
  color: var(--text-muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.user-details-inline .user-role {
  font-size: 0.84rem;
}

.auth-logout {
  border: 0;
  background: transparent;
  color: var(--text-muted);
  font-size: 0.75rem;
  padding: 4px 2px;
  cursor: pointer;
  flex: 0 0 auto;
}

.auth-logout:hover {
  color: var(--text-main);
}

.sidebar-account {
  position: relative;
  width: 100%;
}

.sidebar-account-trigger {
  width: 100%;
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 18px;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  padding: 7px 10px;
  border: 1px solid transparent;
  border-radius: 12px;
  background: transparent;
  color: var(--nav-text);
  cursor: pointer;
  font: inherit;
  font-size: var(--text-control);
  font-weight: 500;
  text-align: left;
  list-style: none;
  user-select: none;
  transition:
    background var(--duration-base) var(--ease-out),
    border-color var(--duration-base) var(--ease-out),
    color var(--duration-base) var(--ease-out),
    transform 0.16s var(--sidebar-toggle-ease);
}

.sidebar-account-trigger::-webkit-details-marker {
  display: none;
}

.sidebar-account:hover .sidebar-account-trigger {
  background: var(--nav-hover-bg);
  color: var(--nav-hover-text);
  border-color: var(--nav-hover-border);
}

.sidebar-account[open] .sidebar-account-trigger {
  background: var(--nav-hover-bg);
  color: var(--nav-hover-text);
  border-color: var(--nav-hover-border);
}

.sidebar-account-trigger:focus,
.sidebar-account-trigger:focus-visible,
.sidebar-account-trigger:active {
  outline: none;
  box-shadow: none;
}

.sidebar-account-trigger:active {
  transform: translateY(0);
  background: var(--ghost-active-bg);
}

.sidebar-account-copy {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
  min-width: 0;
}

.sidebar-account-name {
  display: inline-block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.84rem;
  font-weight: 600;
  color: currentColor;
}

.sidebar-account-role-inline {
  display: inline-block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--text-muted);
  font-size: 0.84rem;
  font-weight: 500;
}

.sidebar-account-separator {
  color: var(--text-subtle);
  flex: 0 0 auto;
}

.sidebar-account-chevron {
  color: currentColor;
  opacity: 0.82;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.16s var(--ease-out), color 0.16s var(--ease-out);
}

.sidebar-account[open] .sidebar-account-chevron {
  transform: rotate(180deg);
}

.sidebar-account-menu {
  position: absolute;
  left: 0;
  right: auto;
  width: min(300px, calc(100vw - 32px));
  bottom: calc(100% + 8px);
  z-index: 120;
  display: grid;
  gap: 1px;
  padding: 10px;
  border: 1px solid var(--color-border);
  border-radius: 16px;
  background: color-mix(in srgb, var(--color-card) 96%, white);
  box-shadow: 0 18px 44px rgba(33, 32, 30, 0.18), 0 2px 8px rgba(33, 32, 30, 0.08);
  font-family: Geist, -apple-system, system-ui, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  opacity: 0;
  transform: translateY(8px) scale(0.985);
  transform-origin: left bottom;
  pointer-events: none;
  visibility: hidden;
  transition:
    opacity 0.14s var(--ease-out),
    transform 0.16s var(--ease-out),
    visibility 0s linear 0.16s;
}

.sidebar-account[open] .sidebar-account-menu {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
  visibility: visible;
  transition-delay: 0s;
}

.sidebar-account-menu-email {
  padding: 4px 10px 8px;
  font-size: 0.93rem;
  line-height: 1.15;
  letter-spacing: 0;
  color: var(--text-muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sidebar-account-menu-item {
  width: 100%;
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  min-height: 34px;
  padding: 5px 8px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--text-main);
  cursor: default;
  font-family: Geist, -apple-system, system-ui, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif !important;
  font-size: 0.95rem;
  line-height: 1.15;
  letter-spacing: 0;
  text-align: left;
}

.sidebar-account-menu-item > span:nth-child(2) {
  font-family: inherit !important;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sidebar-account-menu-item:hover,
.sidebar-account-menu-item:focus-visible {
  background: var(--secondary);
  outline: none;
}

.sidebar-account-menu-icon {
  width: 20px;
  height: 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--text-main);
}

.sidebar-account-menu-icon svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
  overflow: visible;
}

.sidebar-account-menu-shortcut,
.sidebar-account-menu-arrow {
  color: var(--text-subtle);
  font-size: 0.95rem;
  line-height: 1;
  letter-spacing: 0;
}

.sidebar-account-menu-separator {
  height: 1px;
  margin: 6px 4px;
  background: var(--color-border);
}

.auth-gate {
  min-height: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  place-items: center;
  padding: 32px 16px;
  min-width: 0;
}

.auth-gate-panel {
  width: 100%;
  max-width: 680px;
  min-width: 0;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  background: var(--color-card);
  padding: 28px;
  box-shadow: var(--shadow-sm);
}

.email-auth-panel {
  max-width: 560px;
}

.auth-product-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-bottom: 22px;
  min-width: 0;
}

/* HAZ brand logo refresh：登录卡上方旧 [圆形图标 + Ahamoment 字标] 整块替换为
   横向一体 lockup（图标+字标已在同一张 PNG 里），不再保留旧元素。 */
.auth-product-logo-lockup {
  /* 单 img 元素，让它自然居中 */
  justify-content: center;
}

.auth-product-lockup {
  display: block;
  height: clamp(36px, 4vw, 52px);
  width: auto;
  max-width: min(80%, 360px);
  object-fit: contain;
}

/* HAZ login refresh：登录卡上方改用「纯字标」变体（无左边灯泡 mark），整块左对齐。 */
.auth-product-logo-wordmark {
  justify-content: flex-start;
  align-items: flex-end;
  margin-bottom: 18px;
}

.auth-product-wordmark {
  display: block;
  height: clamp(28px, 2.6vw, 36px);
  width: auto;
  max-width: min(70%, 280px);
  object-fit: contain;
}

.auth-hero-copy {
  text-align: center;
  margin-bottom: 28px;
}

.auth-hero-copy h2 {
  color: #262421;
  font-size: clamp(30px, 3vw, 44px);
  line-height: 1.12;
  font-weight: 800;
  margin-bottom: 14px;
}

.auth-hero-copy p {
  max-width: 440px;
  margin: 0 auto;
  color: #878278;
  font-size: 16px;
  line-height: 1.75;
}

.password-auth-panel {
  min-height: 558px;
}

.auth-eyebrow {
  display: block;
  color: var(--text-muted);
  font-size: 0.75rem;
  margin-bottom: 10px;
}

.auth-gate h2 {
  font-size: 1.35rem;
  line-height: 1.25;
  margin-bottom: 10px;
}

.auth-gate p {
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 18px;
}

.auth-gate-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
}

.access-request-form {
  display: grid;
  gap: 12px;
  margin-top: 16px;
}

.access-request-form label {
  display: grid;
  gap: 6px;
  color: var(--text-main);
  font-size: 0.82rem;
  font-weight: 600;
}

.access-request-form input,
.access-request-form textarea {
  width: 100%;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  background: var(--color-bg);
  color: var(--text-main);
  font: inherit;
  font-weight: 400;
  line-height: 1.45;
  padding: 10px 11px;
  resize: vertical;
}

.access-request-form input:focus,
.access-request-form textarea:focus {
  outline: 2px solid rgba(201, 100, 66, 0.18);
  border-color: var(--color-border-strong);
}

.email-login-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 15px;
  margin-top: 0;
  min-width: 0;
}

.password-auth-form {
  min-height: 310px;
  align-content: start;
}

.email-login-form label,
.auth-field-label {
  display: grid;
  gap: 8px;
  color: var(--text-main);
  font-size: 13px;
  font-weight: 750;
  min-width: 0;
  max-width: 100%;
}

.auth-field-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  min-width: 0;
}

.auth-field-title {
  color: #34322f;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0;
}

.auth-field-note {
  color: #a29e96;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.auth-input-shell {
  position: relative;
  display: flex;
  align-items: center;
  min-width: 0;
  min-height: 58px;
  border: 1px solid rgba(233, 214, 207, 0.9);
  border-radius: 14px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(250, 249, 245, 0.9));
  box-shadow:
    0 14px 34px rgba(106, 63, 46, 0.05),
    inset 0 1px 0 rgba(255, 255, 255, 0.92);
  transform: translateY(0);
  transition:
    transform 0.26s cubic-bezier(0.22, 1, 0.36, 1),
    border-color var(--duration-base) var(--ease-out),
    box-shadow var(--duration-base) var(--ease-out),
    background var(--duration-base) var(--ease-out);
}

.auth-input-shell:hover {
  border-color: rgba(215, 189, 179, 0.98);
  box-shadow:
    0 18px 42px rgba(106, 63, 46, 0.07),
    inset 0 1px 0 rgba(255, 255, 255, 0.94);
  transform: translateY(-1px);
}

.auth-input-shell:focus-within {
  border-color: #e9b7a3;
  background: #fff;
  box-shadow:
    0 0 0 4px rgba(201, 100, 66, 0.11),
    0 18px 42px rgba(106, 63, 46, 0.09),
    inset 0 1px 0 rgba(255, 255, 255, 0.98);
  transform: translateY(-1px);
}

.auth-input-shell svg {
  width: 20px;
  height: 20px;
  flex: 0 0 20px;
  margin-left: 18px;
  padding: 8px;
  box-sizing: content-box;
  border-radius: 12px;
  background: #fcf6f4;
  stroke: #878277;
  stroke-width: 1.9;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition:
    background 0.24s var(--ease-out),
    stroke 0.24s var(--ease-out),
    transform 0.24s var(--ease-out);
}

.auth-input-shell:hover svg,
.auth-input-shell:focus-within svg {
  background: #fbf2ee;
  stroke: #c96442;
  transform: scale(1.03);
}

.auth-invite-shell {
  border-color: rgba(236, 190, 172, 0.84);
  background:
    linear-gradient(180deg, rgba(254, 252, 251, 0.96), rgba(253, 247, 244, 0.82));
  box-shadow:
    0 16px 36px rgba(201, 100, 66, 0.07),
    inset 0 1px 0 rgba(255, 255, 255, 0.92);
}

.auth-invite-shell svg {
  background: #fbf1ed;
  stroke: #c96442;
}

.auth-invite-input {
  font-weight: 720;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.auth-input {
  width: 100%;
  min-width: 0;
  max-width: 100%;
  min-height: 54px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--text-main);
  font: inherit;
  font-weight: 500;
  line-height: 1.45;
  padding: 0 16px;
}

.auth-input:focus {
  outline: none;
}

.auth-input::placeholder {
  color: #b0ada6;
}

.password-register-field.is-reserved {
  visibility: hidden;
  pointer-events: none;
}

.email-code-input {
  letter-spacing: 0.04em;
  padding-right: 132px;
}

.auth-inline-send {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  min-height: 32px;
  border: 0;
  background: transparent;
  color: #c96442;
  font: inherit;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
}

.auth-inline-send:disabled {
  color: #b6b3ac;
  cursor: default;
}

.auth-landing .email-login-form {
  width: min(100%, 430px);
  margin-inline: auto;
  gap: 14px;
}

.auth-landing .auth-input-shell {
  border-color: rgba(233, 214, 207, 0.92) !important;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.88), rgba(253, 250, 249, 0.74));
}

.auth-landing .auth-input {
  border: 0 !important;
  background: transparent !important;
  outline: 0 !important;
  box-shadow: none !important;
  color: #2d2b28 !important;
  caret-color: #c96442 !important;
}

.auth-landing .auth-input:focus {
  border-color: transparent !important;
  outline: 0 !important;
}

.auth-landing .auth-input::placeholder {
  color: #b4b1ab;
  font-weight: 500;
}

.auth-landing .auth-code-shell {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  column-gap: 6px;
  padding-right: 8px;
}

.auth-landing .email-code-input {
  min-width: 0;
  width: auto;
  padding-right: 10px !important;
  letter-spacing: 0.08em;
}

.auth-landing .auth-inline-send {
  position: static !important;
  top: auto !important;
  right: auto !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  align-self: center;
  transform: none !important;
  appearance: none;
  margin: 0;
  min-height: 36px;
  height: 36px;
  padding: 0 14px;
  box-sizing: border-box;
  border: 1px solid rgba(243, 216, 206, 0.85);
  border-radius: 11px;
  background: linear-gradient(180deg, #ffffff, #fdf7f4);
  box-shadow: 0 8px 18px rgba(201, 100, 66, 0.08);
  color: #c96442;
  line-height: 1;
  white-space: nowrap;
  transition:
    transform 0.22s cubic-bezier(0.22, 1, 0.36, 1),
    border-color 0.22s var(--ease-out),
    background 0.22s var(--ease-out),
    box-shadow 0.22s var(--ease-out),
    color 0.22s var(--ease-out),
    opacity 0.22s var(--ease-out);
}

.auth-landing .auth-inline-send:not(:disabled):hover {
  border-color: rgba(201, 100, 66, 0.38);
  background: #fcf4f1;
  box-shadow: 0 10px 22px rgba(201, 100, 66, 0.13);
  transform: translateY(-1px) !important;
}

.auth-landing .auth-inline-send:not(:disabled):active {
  transform: translateY(0) scale(0.98) !important;
}

.auth-landing .auth-inline-send:disabled {
  border-color: #f1e6e2;
  background: #faf9f5;
  box-shadow: none;
  color: #b8b5ae;
  opacity: 0.92;
}

.auth-form-actions {
  margin-bottom: 0;
}

.auth-submit-btn {
  width: 100%;
  min-height: 58px;
  border-style: solid;
  border-width: 13.63px;
  border-color: transparent;
  border-radius: 12px;
  background: linear-gradient(135deg, #dd8c6c 0%, #d36e46 100%);
  color: #fff;
  font-size: 19px;
  font-weight: 800;
  box-shadow: 0 18px 34px rgba(201, 100, 66, 0.26);
  transition:
    transform 0.24s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 0.24s var(--ease-out),
    filter 0.24s var(--ease-out);
}

.auth-submit-btn:hover,
.auth-submit-btn:focus-visible {
  transform: translateY(-1px);
  box-shadow: 0 22px 40px rgba(201, 100, 66, 0.3);
}

.auth-submit-btn:active {
  transform: translateY(0) scale(0.99);
}

.auth-mode-switch {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin: 16px 0 12px;
  padding: 4px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  background: var(--secondary);
}

.auth-mode-tab {
  min-height: 34px;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--text-muted);
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}

.auth-mode-tab.active {
  border-color: var(--color-border);
  background: var(--color-card);
  color: var(--primary-accent);
  box-shadow: var(--shadow-sm);
}

.access-code-input {
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.password-recovery-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  margin-top: 10px;
  min-width: 0;
}

.password-reset-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto;
  gap: 8px;
  align-items: end;
  margin-top: 10px;
  min-width: 0;
}

.password-reset-form label {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.password-reset-form label span {
  font-size: 12px;
  font-weight: 700;
  color: var(--text-muted);
}

.email-login-status {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 6px;
  min-width: 0;
  margin: 0;
  padding: 10px 12px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  background: var(--secondary);
  color: var(--primary-accent);
  font-size: 12px;
  line-height: 1.5;
}

.email-login-status.ok {
  border-color: #bbf7d0;
  background: #f0fdf4;
  color: #166534;
}

.email-login-status.pending {
  border-color: #f0d3c4;
  background: #faf0ea;
  color: #b05730;
}

.email-login-status.error {
  border-color: #fecaca;
  background: #fef2f2;
  color: #991b1b;
}

.email-login-status code {
  width: fit-content;
  max-width: 100%;
  padding: 2px 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  color: currentColor;
  font-family: var(--font-numeric);
  font-size: 11px;
  overflow-wrap: anywhere;
}

.email-login-status span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.auth-provider-choices {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--color-border);
}

.quota-badge {
  display: grid;
  gap: 3px;
  margin-top: 8px;
  padding: 8px 10px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  background: var(--secondary);
  color: var(--primary-accent);
}

.quota-badge.compact {
  padding: 6px 8px;
}

.user-entitlement-card .quota-badge {
  margin-top: 0;
}

.access-code-redeem-form {
  margin-top: 14px;
}

.ai-status-contact {
  align-self: center;
  justify-self: end;
  min-height: 32px;
  display: inline-flex;
  align-items: center;
  padding: 0 10px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  background: var(--secondary);
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.quota-badge.ok {
  border-color: #bbf7d0;
  background: #f0fdf4;
  color: #166534;
}

.quota-badge.exhausted {
  border-color: #fed7aa;
  background: #fff7ed;
  color: #9a3412;
}

.quota-badge.expired {
  border-color: #fecaca;
  background: #fef2f2;
  color: #991b1b;
}

.quota-badge span,
.quota-badge small {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.quota-badge span {
  font-size: 12px;
  font-weight: 700;
}

.quota-badge small {
  font-size: 11px;
  line-height: 1.35;
}

/* Main Content */
.main-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  height: 100vh;
  overflow: hidden;
  font-size: 13px;
  --radius-sm: 4px;
  --radius-md: 6px;
}

.desktop-titlebar {
  display: none;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 28px;
  background: var(--color-bg);
  border-bottom: 1px solid var(--color-border);
  gap: 16px;
  min-height: 64px;
}

.topbar h1 {
  font-family: var(--font-display);
  font-size: var(--text-page-title);
  font-weight: var(--weight-heavy);
  letter-spacing: -0.025em;
  margin-bottom: 2px;
  line-height: 1.2;
}

.topbar p {
  color: var(--text-muted);
  font-size: var(--text-caption);
  letter-spacing: 0.01em;
}

.topbar-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  min-width: 0;
}

.topbar-redeem {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.topbar-redeem input {
  width: 180px;
  min-width: 120px;
  max-width: 28vw;
  height: 32px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  background: var(--color-card);
  color: var(--text-muted);
  padding: 0 10px;
  font: inherit;
}

.topbar-redeem input:disabled {
  background: #faf9f5;
  opacity: 1;
}

.view-container {
  flex: 1;
  padding: 0 24px 24px 24px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: min(100%, var(--workbench-max));
  margin: 0 auto;
}

.workspace-body {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  align-items: stretch;
  overflow: hidden;
}

.workspace-body .view-container {
  flex: 1 1 auto;
  width: min(100%, var(--workbench-max));
  max-width: var(--workbench-max);
  min-width: 0;
  min-height: 0;
  max-height: 100%;
  margin: 0 auto;
}

body.auth-gate-active {
  background:
    linear-gradient(115deg, rgba(222, 144, 113, 0.08) 0%, transparent 36%),
    linear-gradient(245deg, rgba(20, 184, 166, 0.07) 0%, transparent 32%),
    linear-gradient(135deg, #fefbfa 0%, #f7f3ee 38%, #fdfaf9 72%, #ffffff 100%);
}

body.auth-gate-active .sidebar,
body.auth-gate-active #sidebar-resize-handle,
body.auth-gate-active .topbar,
body.auth-gate-active .desktop-titlebar,
body.auth-gate-active #utility-rail,
body.auth-gate-active #utility-rail-resize-handle {
  display: none !important;
}

body.auth-gate-active .workspace,
body.auth-gate-active .main-content,
body.auth-gate-active .workspace-body {
  height: 100vh;
  min-height: 100vh;
  width: 100%;
}

body.auth-gate-active .workspace-body {
  display: block;
  overflow-y: scroll;
  scrollbar-gutter: stable;
}

body.auth-gate-active .view-container,
body.auth-gate-active .workspace-body .view-container {
  width: 100%;
  max-width: none;
  min-height: 100vh;
  max-height: none;
  padding: 0;
  margin: 0;
  overflow: visible;
}

/* HAZ-188 V2 R2：09-design-overrides 里 `body.profile-page .view-container { padding: 14px 18px 24px }`
   规格 (0,2,1) 等于 `body.auth-gate-active .view-container` 但因源序后置而胜出，
   让 #app 在登录页保留 14/18px 边距，露出 .main-content 的灰底当「框」。
   用 #app ID 选择器把规格抬到 (1,2,1) 一次性盖掉所有 per-page padding 泄漏。 */
body.auth-gate-active #app.view-container {
  padding: 0;
  margin: 0;
}

body.auth-gate-active .auth-gate {
  position: relative;
  min-height: 100vh;
  padding: clamp(36px, 6vh, 68px) 24px 28px;
  overflow: hidden;
  isolation: isolate;
}

body.auth-gate-active .auth-gate::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 50% 22%, rgba(221, 141, 109, 0.18), transparent 38%),
    linear-gradient(90deg, rgba(216, 170, 151, 0.13) 1px, transparent 1px),
    linear-gradient(0deg, rgba(216, 170, 151, 0.11) 1px, transparent 1px);
  background-size: auto, 80px 80px, 80px 80px;
  opacity: 0.9;
  z-index: 0;
  mask-image: linear-gradient(to bottom, transparent, #000 12%, #000 88%, transparent);
}

body.auth-gate-active .auth-gate::after {
  content: "";
  position: absolute;
  inset: -18%;
  pointer-events: none;
  background:
    radial-gradient(circle, rgba(201, 100, 66, 0.28) 0 2px, transparent 2.6px) 8% 18% / 150px 150px,
    radial-gradient(circle, rgba(20, 184, 166, 0.22) 0 1.8px, transparent 2.4px) 72% 14% / 190px 190px,
    radial-gradient(circle, rgba(229, 167, 142, 0.2) 0 2px, transparent 2.8px) 32% 82% / 210px 210px,
    radial-gradient(circle, rgba(245, 158, 11, 0.16) 0 1.5px, transparent 2.2px) 88% 70% / 175px 175px;
  opacity: 0.46;
  filter: blur(0.2px);
  transform: translate3d(0, 0, 0);
  animation: authParticleDrift 22s linear infinite alternate;
  mask-image:
    linear-gradient(to bottom, transparent, #000 12%, #000 86%, transparent),
    linear-gradient(to right, transparent, #000 8%, #000 92%, transparent);
  mask-composite: intersect;
}

.auth-lightfall {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  overflow: hidden;
  contain: paint;
  mix-blend-mode: screen;
}

.auth-lightfall::before,
.auth-lightfall::after {
  content: "";
  position: absolute;
  inset: auto;
  pointer-events: none;
  border-radius: 999px;
  filter: blur(32px);
  opacity: 0.34;
}

.auth-lightfall::before {
  width: min(46vw, 620px);
  height: min(46vw, 620px);
  left: 50%;
  top: 4%;
  transform: translateX(-50%);
  background:
    radial-gradient(circle, rgba(224, 139, 109, 0.36), rgba(215, 121, 84, 0.08) 58%, transparent 72%);
}

.auth-lightfall::after {
  width: min(32vw, 430px);
  height: min(32vw, 430px);
  right: 8%;
  bottom: 4%;
  background:
    radial-gradient(circle, rgba(20, 184, 166, 0.28), rgba(251, 191, 36, 0.09) 54%, transparent 76%);
}

.auth-lightfall span {
  position: absolute;
  left: calc(var(--x) * 1%);
  top: -24vh;
  width: 2px;
  height: var(--ray-length);
  border-radius: 999px;
  opacity: 0;
  background:
    linear-gradient(
      to bottom,
      transparent 0%,
      color-mix(in srgb, var(--ray-color) 8%, transparent) 16%,
      color-mix(in srgb, var(--ray-color) 78%, white) 46%,
      color-mix(in srgb, var(--ray-color) 28%, transparent) 76%,
      transparent 100%
    );
  box-shadow:
    0 0 16px color-mix(in srgb, var(--ray-color) 64%, transparent),
    0 0 44px color-mix(in srgb, var(--ray-color) 26%, transparent);
  transform: translate3d(-12vw, -18vh, 0) rotate(14deg);
  animation: authLightfallDrop var(--duration) linear infinite;
  animation-delay: var(--delay);
  will-change: transform, opacity;
}

@keyframes authLightfallDrop {
  0% {
    opacity: 0;
    transform: translate3d(-10vw, -22vh, 0) rotate(14deg);
  }

  12% {
    opacity: var(--alpha);
  }

  58% {
    opacity: calc(var(--alpha) * 0.82);
  }

  100% {
    opacity: 0;
    transform: translate3d(10vw, 126vh, 0) rotate(14deg);
  }
}

@keyframes authParticleDrift {
  from {
    transform: translate3d(-10px, -6px, 0);
  }

  to {
    transform: translate3d(16px, 12px, 0);
  }
}

@media (prefers-reduced-motion: reduce) {
  body.auth-gate-active .auth-gate::after {
    animation: none;
    transform: none;
  }

  .auth-lightfall span {
    animation: none;
    opacity: calc(var(--alpha) * 0.4);
    transform: translate3d(0, 18vh, 0) rotate(14deg);
  }

  .auth-landing .email-auth-panel,
  .auth-marketing-nav,
  .auth-marketing-brand,
  .auth-marketing-links a,
  .auth-marketing-cta,
  .auth-floating-card,
  .auth-input-shell,
  .auth-input-shell svg,
  .auth-landing .auth-inline-send,
  .auth-submit-btn,
  .auth-landing .email-login-status,
  .auth-landing .email-login-status::before {
    transition: none;
  }
}

.auth-marketing-nav {
  position: relative;
  z-index: 3;
  width: min(100%, 1560px);
  min-height: 58px;
  display: grid;
  grid-template-columns: minmax(180px, auto) minmax(0, 1fr) auto;
  align-items: center;
  gap: clamp(18px, 3vw, 42px);
  margin: 0 auto clamp(26px, 3.6vh, 42px);
  padding: 7px 8px 7px 10px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.5);
  box-shadow: none;
  backdrop-filter: blur(18px) saturate(1.08);
}

.auth-marketing-brand,
.auth-marketing-links a,
.auth-marketing-cta {
  min-height: 42px;
  border: 0;
  border-radius: 999px;
  font: inherit;
  font-weight: 760;
  letter-spacing: 0;
  text-decoration: none;
  transition:
    transform 0.24s cubic-bezier(0.22, 1, 0.36, 1),
    background 0.24s var(--ease-out),
    color 0.24s var(--ease-out),
    box-shadow 0.24s var(--ease-out);
}

.auth-marketing-brand {
  display: inline-flex;
  align-items: center;
  justify-self: start;
  gap: 10px;
  padding: 4px 12px 4px 6px;
  background: transparent;
  color: #2b2926;
  cursor: pointer;
}

.auth-marketing-logo {
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 34px;
  border-radius: 50%;
  overflow: hidden;
  box-shadow:
    0 0 0 1px rgba(33, 32, 30, 0.08),
    0 10px 24px rgba(61, 59, 54, 0.12);
}

.auth-marketing-logo img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.auth-marketing-brand strong {
  color: inherit;
  font-size: 18px;
  font-weight: 830;
}

/* HAZ brand logo refresh：落地/登录页顶部品牌位整块替换为横向 lockup。
   原 [favicon 圆图 + Ahamoment 字标] 两元素并排 → 单张 lockup PNG。 */
.auth-marketing-brand-lockup {
  padding: 0;
  background: transparent;
  box-shadow: none;
}

.auth-marketing-brand-lockup picture,
.auth-marketing-brand-lockup img.auth-marketing-lockup {
  display: block;
}

.auth-marketing-brand-lockup .auth-marketing-lockup {
  height: clamp(26px, 2.4vw, 34px);
  width: auto;
  max-width: min(100%, 220px);
  object-fit: contain;
}

.auth-marketing-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-width: 0;
}

.auth-marketing-links a {
  display: inline-flex;
  align-items: center;
  padding: 0 14px;
  background: transparent;
  color: #66625a;
  cursor: pointer;
  white-space: nowrap;
  transition:
    color 0.12s ease,
    background 0.12s ease,
    opacity 0.12s ease;
}

.auth-marketing-brand:hover,
.auth-marketing-brand:focus-visible,
.auth-marketing-links a.active {
  outline: none;
  background: rgba(253, 249, 247, 0.92);
  color: #2b2926;
  transform: translateY(-1px);
}

.auth-marketing-links a:hover,
.auth-marketing-links a:focus-visible {
  outline: none;
  color: #2b2926;
  background: transparent;
  transform: none;
}

.auth-marketing-links a:active {
  color: #2b2926;
  opacity: 0.72;
}

.auth-marketing-brand-lockup:hover,
.auth-marketing-brand-lockup:focus-visible {
  background: transparent;
  color: inherit;
  transform: none;
}

.auth-marketing-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  justify-self: end;
  padding: 0 22px;
  background: #1d1c1a;
  color: #ffffff;
  box-shadow: 0 14px 28px rgba(29, 28, 26, 0.18);
  white-space: nowrap;
}

.auth-marketing-cta:hover,
.auth-marketing-cta:focus-visible {
  outline: none;
  background: #2b2a27;
  color: #ffffff;
  transform: translateY(-1px);
  box-shadow: 0 18px 34px rgba(29, 28, 26, 0.24);
}

.auth-landing-grid {
  position: relative;
  z-index: 2;
  width: min(100%, 1280px);
  margin-inline: auto;
  display: grid;
  grid-template-columns: minmax(220px, 330px) minmax(420px, 560px) minmax(220px, 330px);
  align-items: center;
  justify-content: center;
  gap: clamp(28px, 5vw, 86px);
}

.auth-landing .email-auth-panel {
  min-height: 740px;
  padding: clamp(38px, 4.5vw, 58px);
  border-color: rgba(218, 197, 188, 0.82);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.84);
  box-shadow: 0 28px 90px rgba(117, 112, 103, 0.18);
  backdrop-filter: blur(22px);
  transform: translateZ(0);
  transition:
    border-color 0.28s var(--ease-out),
    box-shadow 0.28s var(--ease-out),
    background 0.28s var(--ease-out);
}

body.auth-gate-active .auth-gate-panel:not(.email-auth-panel) {
  box-shadow: 0 24px 70px rgba(33, 32, 30, 0.12);
}

.auth-side-column {
  display: grid;
  gap: 36px;
  min-width: 0;
}

.auth-side-left {
  order: 1;
  transform: translateY(-8px);
}

.auth-side-right {
  order: 3;
  transform: translateY(18px);
}

.auth-landing .email-auth-panel {
  order: 2;
}

.auth-floating-card {
  width: 100%;
  border: 1px solid rgba(240, 226, 220, 0.78);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.66);
  box-shadow: 0 24px 70px rgba(117, 112, 103, 0.1);
  backdrop-filter: blur(20px);
  color: #3a3834;
  transform: translateZ(0);
  transition:
    transform 0.32s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 0.32s var(--ease-out),
    border-color 0.32s var(--ease-out),
    background 0.32s var(--ease-out);
}

.auth-floating-card:hover {
  border-color: rgba(233, 207, 196, 0.92);
  background: rgba(255, 255, 255, 0.76);
  box-shadow: 0 28px 80px rgba(117, 112, 103, 0.14);
  transform: translateY(-2px);
}

.auth-panel-kicker {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  margin-bottom: 14px;
  padding: 0 9px;
  border: 1px solid rgba(119, 115, 106, 0.14);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.62);
  color: #827d73;
  font-size: 11px;
  font-weight: 850;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.auth-source-artifact-card,
.auth-operating-card,
.auth-draft-preview-card,
.auth-publish-check-card {
  position: relative;
  overflow: hidden;
  padding: 24px;
}

.auth-source-artifact-card {
  min-height: 286px;
  background:
    linear-gradient(150deg, rgba(255, 255, 255, 0.88), rgba(250, 249, 245, 0.68)),
    radial-gradient(circle at 100% 0%, rgba(201, 100, 66, 0.13), transparent 42%);
}

.auth-source-artifact-card::after {
  content: "";
  position: absolute;
  right: 20px;
  bottom: 22px;
  width: 88px;
  height: 112px;
  border: 1px solid rgba(201, 100, 66, 0.12);
  border-radius: 16px;
  background:
    linear-gradient(180deg, rgba(201, 100, 66, 0.16), transparent 42%),
    repeating-linear-gradient(to bottom, rgba(107, 103, 95, 0.12) 0 1px, transparent 1px 13px);
  opacity: 0.72;
  transform: rotate(5deg);
}

.auth-artifact-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.auth-artifact-toolbar b {
  display: inline-flex;
  align-items: center;
  min-height: 25px;
  padding: 0 10px;
  border-radius: 999px;
  background: #1d1c1a;
  color: #ffffff;
  font-size: 11px;
  font-weight: 850;
}

.auth-source-artifact-card h3,
.auth-draft-preview-card h3 {
  position: relative;
  z-index: 1;
  margin: 16px 0 12px;
  color: #272522;
  font-size: 21px;
  line-height: 1.32;
  font-weight: 880;
  letter-spacing: 0;
}

.auth-source-artifact-card p,
.auth-draft-preview-card p,
.auth-publish-check-card p,
.auth-operating-flow p {
  position: relative;
  z-index: 1;
  margin: 0;
  color: #827d73;
  font-size: 13px;
  line-height: 1.72;
}

.auth-artifact-meta {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 24px;
  padding-right: 70px;
}

.auth-artifact-meta span,
.auth-draft-tabs span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border: 1px solid rgba(233, 215, 208, 0.86);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.74);
  color: #6f6b62;
  font-size: 12px;
  font-weight: 780;
}

.auth-operating-card {
  background:
    linear-gradient(155deg, rgba(29, 28, 26, 0.94), rgba(58, 56, 52, 0.86)),
    radial-gradient(circle at 0 0, rgba(230, 171, 147, 0.2), transparent 36%);
  box-shadow: 0 30px 96px rgba(29, 28, 26, 0.22);
}

.auth-operating-card .auth-panel-kicker {
  border-color: rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.68);
}

.auth-operating-card > strong,
.auth-publish-check-card > strong {
  display: block;
  color: #ffffff;
  font-size: 16px;
  line-height: 1.35;
  font-weight: 860;
}

.auth-operating-flow {
  display: grid;
  gap: 12px;
  margin-top: 18px;
}

.auth-operating-flow div {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  column-gap: 11px;
  row-gap: 3px;
  align-items: start;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.055);
}

.auth-operating-flow span {
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.88);
  font-size: 11px;
  font-weight: 900;
}

.auth-operating-flow em {
  color: #ffffff;
  font-style: normal;
  font-size: 14px;
  font-weight: 850;
}

.auth-operating-flow p {
  grid-column: 2;
  color: rgba(255, 255, 255, 0.62);
  font-size: 12px;
}

.auth-draft-preview-card {
  min-height: 324px;
  background:
    linear-gradient(160deg, rgba(255, 255, 255, 0.86), rgba(253, 249, 247, 0.68)),
    radial-gradient(circle at 0 100%, rgba(20, 184, 166, 0.13), transparent 40%);
}

.auth-draft-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-bottom: 18px;
}

.auth-draft-tabs span:first-child {
  border-color: rgba(201, 100, 66, 0.22);
  background: rgba(201, 100, 66, 0.09);
  color: #c96442;
}

.auth-draft-preview-card blockquote {
  margin: 22px 0 0;
  padding: 16px 17px;
  border-left: 3px solid #c96442;
  border-radius: 0 16px 16px 0;
  background: rgba(255, 255, 255, 0.72);
  color: #47443f;
  font-size: 13px;
  line-height: 1.72;
  font-weight: 760;
}

.auth-publish-check-card {
  background:
    linear-gradient(150deg, rgba(39, 38, 35, 0.92), rgba(33, 32, 30, 0.86)),
    radial-gradient(circle at 100% 12%, rgba(201, 100, 66, 0.22), transparent 36%);
  box-shadow: 0 30px 96px rgba(29, 28, 26, 0.22);
}

.auth-publish-check-card .auth-panel-kicker {
  border-color: rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.68);
}

.auth-check-list {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}

.auth-check-list span {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 38px;
  padding: 0 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.065);
  color: rgba(255, 255, 255, 0.78);
  font-size: 12px;
  font-weight: 790;
}

.auth-check-list i {
  width: 15px;
  height: 15px;
  flex: 0 0 15px;
  border-radius: 50%;
  background: #67e8f9;
  box-shadow: 0 0 0 5px rgba(103, 232, 249, 0.11);
}

.auth-publish-check-card p {
  margin-top: 16px;
  color: rgba(255, 255, 255, 0.62);
}

.auth-overview-card {
  padding: 24px;
}

.auth-card-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
}

.auth-card-heading strong,
.auth-floating-card > strong {
  display: block;
  color: #3f3c37;
  font-size: 15px;
  font-weight: 800;
}

.auth-brief-card > strong {
  color: #ffffff;
}

.auth-operating-card > strong,
.auth-publish-check-card > strong {
  color: #ffffff;
}

.auth-operating-card:hover,
.auth-publish-check-card:hover {
  border-color: rgba(255, 255, 255, 0.16);
  background:
    linear-gradient(155deg, rgba(29, 28, 26, 0.94), rgba(58, 56, 52, 0.86)),
    radial-gradient(circle at 0 0, rgba(230, 171, 147, 0.2), transparent 36%);
}

.auth-publish-check-card:hover {
  background:
    linear-gradient(150deg, rgba(39, 38, 35, 0.92), rgba(33, 32, 30, 0.86)),
    radial-gradient(circle at 100% 12%, rgba(201, 100, 66, 0.22), transparent 36%);
}

.auth-reference-home {
  padding-top: clamp(28px, 4vh, 44px) !important;
  height: 100vh;
  max-height: 100vh;
  overflow-y: scroll !important;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
  /* HAZ 分层修复：home 不再自带渐变。html 根画布（styles.css:34）提供唯一全幅浅色渐变，
     home 透明露出它 → 单层背景、无接缝；配合 #app 撑满，内容在整个视口居中。 */
  background: transparent;
}

.auth-content-route {
  padding-top: clamp(28px, 4vh, 44px) !important;
}

.auth-reference-home .auth-marketing-nav {
  /* HAZ-188 V2 R2 老板要求 hero 向右 / login 卡向左 → 整体内收：shell 上限 1760 → 1560，
     nav 同步收到 1560，给视口两侧各留约 180px 视觉气口，不再贴边。 */
  width: min(100%, 1560px);
  margin-bottom: clamp(28px, 4.8vh, 58px);
}

.auth-reference-shell {
  position: relative;
  z-index: 2;
  /* HAZ-188 V2 R2：老板对 V2 R1 反馈「card 太靠右、hero 太靠左」，整体收 200px。
     shell 上限 1760 → 1560，给视口左右各留约 180px 自然 margin（margin:0 auto 居中），
     两栏因此都向中间收，gap 维持 ~100 保持「保持一定的距离」的呼吸。
     内部 hero copy / features / preview clamps 同步下调，避免 hero 列变窄后内容超出列宽。 */
  width: min(100%, 1560px);
  min-height: min(760px, calc(100vh - 154px));
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(420px, 510px);
  align-items: center;
  gap: clamp(46px, 6vw, 100px);
  margin: 0 auto;
}

.auth-reference-showcase {
  min-width: 0;
  width: min(100%, 995.83px);
  align-self: stretch;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 12px 0 3px 52px;
  margin-right: -28px;
}

.auth-reference-copy {
  max-width: clamp(640px, 34vw, 852px);
}

.auth-reference-copy h1 {
  margin: 0;
  color: #2d2b27;
  font-family: "汉仪瑞意宋", "Hanyi RuiYi Song", "Songti SC", "STSong", "SimSun", "Noto Serif SC", serif;
  font-size: clamp(44px, 4.2vw, 66px);
  line-height: 1.04;
  font-weight: 900;
  letter-spacing: 0;
  white-space: nowrap;
}

.auth-reference-copy p {
  max-width: clamp(580px, 30vw, 712px);
  margin: 24px 0 0;
  color: rgba(54, 55, 69, 0.76);
  /* HAZ-188 V2 副本字号 18 → clamp(17, 1vw + 6, 20)，宽屏稍放大 */
  font-size: clamp(17px, calc(0.6vw + 11px), 20px);
  line-height: 1.78;
  font-weight: 660;
}

.auth-reference-features {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(22px, 4vw, 48px);
  max-width: clamp(712px, 40vw, 912px);
  margin-top: clamp(38px, 4.4vh, 56px);
}

.auth-reference-features div {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);
  column-gap: 14px;
  row-gap: 3px;
  align-items: center;
}

.auth-reference-features span {
  width: 52px;
  height: 52px;
  grid-row: span 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  font-size: 25px;
  font-weight: 900;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.84), 0 16px 34px rgba(54, 55, 69, 0.08);
}

.auth-reference-features span svg {
  width: 23px;
  height: 23px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.15;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.auth-reference-features span.blue {
  color: #5a8ad2;
  background: rgba(90, 138, 210, 0.12);
}

.auth-reference-features span.green {
  color: #008cc5;
  background: rgba(0, 140, 197, 0.12);
}

.auth-reference-features span.purple {
  color: #363745;
  background: rgba(54, 55, 69, 0.08);
}

.auth-reference-features strong,
.auth-reference-features em {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.auth-reference-features strong {
  color: #363745;
  font-size: 15px;
  font-weight: 870;
}

.auth-reference-features em {
  color: rgba(54, 55, 69, 0.58);
  font-size: 13px;
  font-style: normal;
  font-weight: 710;
}

.auth-workbench-preview {
  position: relative;
  /* HAZ-188 V2 R2 shell 收到 1560 → preview 上限收到 940，避免 hero 列 ~950 被 1100 撑出列。
     宽度 890 → 940；高度上限 420 保留作为视觉锚点。 */
  width: clamp(min(100%, 890px), 50vw, 940px);
  min-height: clamp(378px, 22vw, 420px);
  display: grid;
  grid-template-columns: clamp(180px, 11vw, 210px) minmax(0, 1fr);
  gap: 20px;
  box-sizing: border-box;
  margin-top: clamp(42px, 5vh, 64px);
  padding: 22px 24px 24px;
  border: 1px solid rgba(90, 138, 210, 0.22);
  border-radius: 28px;
  background:
    linear-gradient(140deg, rgba(255, 255, 255, 0.88), rgba(250, 248, 251, 0.66)),
    rgba(250, 248, 251, 0.64);
  box-shadow: 0 34px 100px rgba(54, 55, 69, 0.12), 0 12px 32px rgba(0, 140, 197, 0.06);
  backdrop-filter: blur(20px);
  transform: perspective(1250px) rotateX(1.6deg) rotateY(-2.8deg) rotateZ(3.9deg) translate3d(12px, -10px, 0);
  transform-origin: 18% 10%;
  transform-style: preserve-3d;
  overflow: hidden;
}

.auth-workbench-preview::after {
  content: "";
  position: absolute;
  z-index: 5;
  left: -6%;
  right: -8%;
  bottom: -2px;
  height: 34%;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(250, 248, 251, 0), rgba(250, 248, 251, 0.72) 54%, rgba(250, 248, 251, 0.96) 100%),
    radial-gradient(ellipse at 48% 100%, rgba(90, 138, 210, 0.18), transparent 64%);
  backdrop-filter: blur(3px);
}

.auth-workbench-preview aside {
  display: grid;
  align-content: start;
  gap: 6px;
  padding: 22px 12px 20px;
  border: 1px solid rgba(90, 138, 210, 0.16);
  border-radius: 20px;
  background: rgba(250, 248, 251, 0.78);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.86);
  transform: translateZ(22px);
}

.auth-preview-brand {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 14px;
  color: rgba(54, 55, 69, 0.46);
  font-size: 13px;
  font-weight: 850;
}

.auth-preview-brand img {
  width: 24px;
  height: 24px;
  border-radius: 50%;
}

.auth-workbench-preview aside span {
  min-height: 34px;
  display: flex;
  align-items: center;
  padding: 0 12px;
  border-radius: 10px;
  color: rgba(54, 55, 69, 0.68);
  font-size: 13px;
  font-weight: 790;
}

.auth-workbench-preview aside span.active {
  background: rgba(90, 138, 210, 0.14);
  color: #5a8ad2;
}

.auth-workbench-preview main {
  min-width: 0;
  padding: 22px 24px 24px;
  border: 1px solid rgba(90, 138, 210, 0.12);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.42);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
  transform: translateZ(34px);
}

.auth-workbench-preview nav {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 22px;
  flex-wrap: wrap;
}

.auth-workbench-preview nav b,
.auth-workbench-preview nav span {
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  padding: 0 12px;
  border-radius: 10px;
  color: rgba(54, 55, 69, 0.58);
  font-size: 12px;
  font-weight: 820;
}

.auth-workbench-preview nav b {
  background: #fcf4f1;
  color: #c96442;
}

.auth-preview-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: 18px;
}

.auth-preview-card {
  min-height: 116px;
  padding: 18px;
  border: 1px solid rgba(245, 231, 225, 0.9);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 18px 52px rgba(130, 125, 116, 0.08);
  transform: translateZ(18px);
}

.auth-preview-card.large {
  min-height: 204px;
}

.auth-preview-card small {
  display: block;
  color: #a19d95;
  font-size: 12px;
  font-weight: 770;
}

.auth-preview-card h3 {
  margin: 13px 0 8px;
  color: #3a3834;
  font-size: 17px;
  line-height: 1.4;
  font-weight: 880;
}

.auth-preview-card p {
  margin: 0;
  color: #938e85;
  font-size: 13px;
  line-height: 1.65;
}

.auth-preview-card div:not(.auth-waveform) {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.auth-preview-card div:not(.auth-waveform) span {
  min-height: 26px;
  display: inline-flex;
  align-items: center;
  padding: 0 10px;
  border-radius: 999px;
  background: #fcf4f1;
  color: #cf8263;
  font-size: 12px;
  font-weight: 790;
}

.auth-preview-card.audio {
  display: grid;
  align-content: center;
}

.auth-waveform {
  height: 38px;
  display: flex;
  align-items: center;
  gap: 5px;
  margin-top: 14px;
}

.auth-waveform i {
  width: 4px;
  height: 16px;
  border-radius: 999px;
  background: #eab8a4;
}

.auth-waveform i:nth-child(2),
.auth-waveform i:nth-child(5) {
  height: 28px;
}

.auth-waveform i:nth-child(3),
.auth-waveform i:nth-child(6) {
  height: 22px;
}

.auth-reference-login-card {
  width: 100%;
  max-width: 481.55px;
  justify-self: end;
  min-height: 705.14px !important;
  padding: clamp(38px, 4.2vw, 44px) !important;
  border-radius: 24px !important;
  border-color: rgba(234, 217, 211, 0.9) !important;
  background: rgba(255, 255, 255, 0.88) !important;
  box-shadow: 0 34px 100px rgba(106, 102, 94, 0.16) !important;
  margin-right: 48px;
}

.auth-reference-login-card .auth-product-logo {
  justify-content: center;
  margin-bottom: 28px;
}

.auth-reference-login-card .auth-hero-copy {
  margin-bottom: 34px;
}

.auth-reference-login-card .auth-hero-copy h2 {
  font-size: 27px;
}

.auth-reference-login-card .auth-policy-links {
  margin-top: 13px;
}

.auth-reference-login-card .email-login-form {
  margin-top: -13px;
}

/* HAZ login refresh：登录卡左对齐变体——欢迎回来 + 上方字标 + 副标 整块靠左。
   表单不动；副标自然左对齐；policy-links 也跟着左对齐保持视觉一致。 */
.auth-reference-login-card-left .auth-product-logo {
  justify-content: flex-start;
}
.auth-reference-login-card-left .auth-hero-copy,
.auth-reference-login-card-left .auth-hero-copy-left {
  text-align: left;
}
.auth-reference-login-card-left .auth-hero-copy h2 {
  margin-left: 0;
}
.auth-reference-login-card-left .auth-hero-copy p {
  margin-left: 0;
  margin-right: 0;
  max-width: 100%;
}
.auth-reference-login-card-left .auth-policy-links {
  width: 100%;
  justify-content: center;
  justify-self: center;
  text-align: center;
}

.auth-card-heading span {
  padding: 6px 10px;
  border: 1px solid #f4e9e4;
  border-radius: 9px;
  color: #8d887f;
  font-size: 12px;
  font-weight: 700;
}

.auth-overview-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.auth-overview-grid div {
  min-height: 90px;
  padding: 12px;
  border-radius: 14px;
  background: rgba(250, 249, 245, 0.72);
}

.auth-overview-grid span,
.auth-source-row em,
.auth-activity-row small,
.auth-calendar-days span {
  color: #9d9990;
  font-style: normal;
  font-size: 12px;
  font-weight: 700;
}

.auth-overview-grid strong {
  display: block;
  margin: 5px 0 8px;
  color: #45423d;
  font-size: 26px;
  font-weight: 800;
}

.auth-overview-grid svg {
  width: 100%;
  height: 28px;
}

.auth-overview-grid path {
  fill: none;
  stroke: #df9375;
  stroke-width: 2.5;
  stroke-linecap: round;
}

.auth-overview-grid div:nth-child(2) path {
  stroke: #e3a288;
}

.auth-overview-grid div:nth-child(3) path {
  stroke: #54ca8f;
}

.auth-overview-grid div:nth-child(4) path {
  stroke: #f4ae3e;
}

.auth-source-card,
.auth-activity-card,
.auth-calendar-card {
  padding: 24px;
}

.auth-source-row,
.auth-activity-row {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  min-height: 38px;
  margin-top: 13px;
}

.auth-activity-row {
  grid-template-columns: 32px minmax(0, 1fr);
}

.source-icon {
  width: 26px;
  height: 26px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 800;
}

.source-icon.blue {
  color: #c96442;
  background: #fbf1ed;
}

.source-icon.purple {
  color: #de9274;
  background: #fbf2ef;
}

.source-icon.amber {
  color: #e38b18;
  background: #fff4df;
}

.source-icon.green {
  color: #13a06f;
  background: #e7fbf1;
}

.auth-source-row b {
  color: #aeaba4;
  font-size: 13px;
  font-weight: 800;
}

.auth-activity-row b {
  display: block;
  color: #646059;
  font-size: 13px;
  font-weight: 800;
}

.auth-activity-row small {
  display: block;
  margin-top: 2px;
}

.auth-card-link {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid #f5ece8;
  color: #df9375;
  font-size: 13px;
  font-weight: 800;
}

.auth-calendar-days {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 8px;
  margin: 20px 0;
  text-align: center;
}

.auth-calendar-days b {
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  justify-self: center;
  border-radius: 50%;
  color: #68645c;
  font-size: 12px;
  font-weight: 800;
}

.auth-calendar-days b.active {
  color: #fff;
  background: #df9375;
  box-shadow: 0 10px 22px rgba(223, 147, 117, 0.25);
}

.auth-calendar-list {
  display: grid;
  gap: 14px;
}

.auth-calendar-list span {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #878277;
  font-size: 13px;
  font-weight: 700;
}

.auth-calendar-list i {
  width: 8px;
  height: 8px;
  flex: 0 0 8px;
  border-radius: 50%;
}

.auth-calendar-list i.blue {
  background: #df9375;
}

.auth-calendar-list i.purple {
  background: #e3a288;
}

.auth-calendar-list i.green {
  background: #54ca8f;
}

.auth-policy-links {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0;
  margin-top: 54px;
  color: #98938a;
  font-size: 14px;
  font-weight: 700;
}

.auth-policy-links button {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  cursor: pointer;
}

.auth-policy-links button:hover,
.auth-policy-links button:focus-visible {
  color: #c96442;
  outline: none;
}

.auth-policy-links button + button::before {
  content: "";
  width: 1px;
  height: 13px;
  margin: 0 18px;
  background: #e7d7d1;
}

.auth-info-backdrop {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(253, 248, 246, 0.44);
  backdrop-filter: blur(10px);
}

.auth-info-dialog {
  width: min(100%, 430px);
  border: 1px solid rgba(233, 214, 207, 0.9);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 28px 90px rgba(97, 63, 49, 0.2);
  padding: 24px;
  color: #3a3834;
}

.auth-info-dialog header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.auth-info-dialog header span {
  color: #c96442;
  font-size: 12px;
  font-weight: 850;
}

.auth-info-close {
  width: 32px;
  height: 32px;
  border: 1px solid #f3e3dd;
  border-radius: 10px;
  background: #fefbf9;
  color: #7e7970;
  font: inherit;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
}

.auth-info-dialog h3 {
  margin: 0 0 10px;
  color: #272522;
  font-size: 22px;
  line-height: 1.25;
  font-weight: 850;
}

.auth-info-dialog p {
  margin: 0;
  color: #827d73;
  font-size: 14px;
  line-height: 1.75;
}

.auth-info-dialog ul {
  display: grid;
  gap: 10px;
  margin: 18px 0 20px;
  padding: 0;
  list-style: none;
}

.auth-info-dialog li {
  position: relative;
  padding-left: 18px;
  color: #5c5851;
  font-size: 13px;
  line-height: 1.65;
}

.auth-info-dialog li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.68em;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #c96442;
  box-shadow: 0 0 0 4px rgba(201, 100, 66, 0.1);
}

.auth-info-confirm {
  width: 100%;
  justify-content: center;
}

.auth-content-route {
  height: 100vh;
  max-height: 100vh;
  overflow-y: scroll !important;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
}

.auth-content-page {
  position: relative;
  z-index: 2;
  width: min(100%, 920px);
  min-width: 0;
  margin: 0 auto;
  color: #2b2926;
}

.auth-content-changelog {
  width: min(100%, 1120px);
  display: grid;
  grid-template-columns: 230px minmax(0, 1fr);
  gap: 56px;
  align-items: start;
}

.auth-content-rail {
  position: sticky;
  top: 96px;
  min-height: 220px;
  padding: 20px 0;
  border-right: 1px solid rgba(226, 209, 203, 0.72);
}

.auth-content-rail-title {
  display: block;
  margin: 0 0 18px;
  color: #938e85;
  font-size: 13px;
  font-weight: 830;
}

.auth-changelog-timeline {
  display: grid;
  gap: 22px;
}

.auth-changelog-month {
  display: grid;
  gap: 10px;
}

.auth-changelog-month > strong {
  color: #9f9b93;
  font-size: 13px;
  font-weight: 820;
}

.auth-changelog-month-list {
  position: relative;
  display: grid;
  gap: 2px;
}

.auth-changelog-month-list::before {
  content: "";
  position: absolute;
  left: 6px;
  top: 17px;
  bottom: 17px;
  width: 1px;
  background: #eddfda;
}

.auth-changelog-timeline-item {
  position: relative;
  display: grid;
  grid-template-columns: 14px 28px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  min-height: 34px;
  width: 100%;
  padding: 0 8px 0 0;
  border: 0;
  border-radius: 12px;
  background: transparent;
  color: #9f9b93;
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition:
    color 0.2s var(--ease-out),
    background 0.2s var(--ease-out),
    transform 0.2s var(--ease-out);
}

.auth-changelog-timeline-item:hover,
.auth-changelog-timeline-item:focus-visible,
.auth-changelog-timeline-item.active {
  outline: none;
  background: rgba(255, 255, 255, 0.58);
  color: #2b2926;
}

.auth-changelog-timeline-item:hover {
  transform: translateX(2px);
}

.auth-changelog-dot {
  position: relative;
  z-index: 1;
  width: 11px;
  height: 11px;
  border: 1px solid #cdcbc7;
  border-radius: 50%;
  background: #ffffff;
  box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.72);
}

.auth-changelog-timeline-item.active .auth-changelog-dot {
  border-color: #1d1c1a;
  background: #1d1c1a;
}

.auth-changelog-day {
  color: #3b3935;
  font-size: 16px;
  font-weight: 850;
  line-height: 1;
}

.auth-changelog-timeline-item em {
  color: #b3b0aa;
  font-size: 13px;
  font-style: normal;
  white-space: nowrap;
}

.auth-content-main {
  min-width: 0;
  padding: 76px 0 68px;
}

.auth-content-page.auth-content-changelog > .auth-content-main {
  max-height: calc(100vh - 146px);
  padding-right: 18px;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
}

.auth-page-hero {
  max-width: 760px;
  margin-bottom: 54px;
}

.auth-page-hero,
.auth-changelog-entry,
.auth-release-section li,
.auth-product-feature-grid article,
.auth-usecase-grid article,
.auth-docs-step-list article,
.auth-docs-module-grid article,
.auth-docs-notes li,
.auth-resource-list article,
.auth-page-band {
  overflow-wrap: anywhere;
  word-break: normal;
}

.auth-page-hero span {
  display: inline-flex;
  margin-bottom: 18px;
  color: #7e7970;
  font-size: 14px;
  font-weight: 850;
}

.auth-page-hero h1 {
  margin: 0;
  color: #21201e;
  font-size: 58px;
  line-height: 1.06;
  font-weight: 860;
  letter-spacing: 0;
}

.auth-page-hero p {
  max-width: 640px;
  margin: 22px 0 0;
  color: #827d73;
  font-size: 18px;
  line-height: 1.75;
}

.auth-product-feature-grid,
.auth-usecase-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 40px;
}

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

.auth-product-feature-grid article,
.auth-usecase-grid article,
.auth-resource-list article,
.auth-page-band {
  border: 1px solid rgba(216, 213, 202, 0.86);
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.84), rgba(250, 249, 245, 0.72));
  box-shadow:
    0 22px 70px rgba(109, 105, 97, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.78);
  backdrop-filter: blur(18px) saturate(1.05);
}

.auth-product-feature-grid article,
.auth-usecase-grid article {
  min-height: 210px;
  padding: 22px;
}

.auth-product-feature-grid b {
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 26px;
  border-radius: 50%;
  background: #1d1c1a;
  color: #ffffff;
  font-size: 14px;
  font-weight: 850;
}

.auth-product-feature-grid h2,
.auth-usecase-grid h2,
.auth-resource-list h2,
.auth-page-band h2 {
  margin: 0 0 12px;
  color: #272522;
  font-size: 20px;
  line-height: 1.35;
  font-weight: 850;
}

.auth-product-feature-grid p,
.auth-usecase-grid p,
.auth-resource-list p,
.auth-page-band p {
  margin: 0;
  color: #827d73;
  font-size: 14px;
  line-height: 1.75;
}

.auth-docs-section {
  display: grid;
  gap: 18px;
  max-width: 860px;
  margin-bottom: 44px;
}

.auth-docs-section-heading {
  display: grid;
  gap: 8px;
}

.auth-docs-section-heading span {
  color: #7e7970;
  font-size: 13px;
  font-weight: 850;
  text-transform: uppercase;
}

.auth-docs-section-heading h2 {
  margin: 0;
  color: #272522;
  font-size: 30px;
  line-height: 1.25;
  font-weight: 870;
}

.auth-docs-step-list {
  display: grid;
  gap: 10px;
}

.auth-docs-step-list article {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  gap: 16px;
  padding: 18px 20px;
  border: 1px solid rgba(216, 213, 202, 0.86);
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.84), rgba(250, 249, 245, 0.72));
  box-shadow:
    0 18px 54px rgba(109, 105, 97, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.78);
  backdrop-filter: blur(18px) saturate(1.05);
}

.auth-docs-step-list b {
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: #1d1c1a;
  color: #ffffff;
  font-size: 14px;
  font-weight: 850;
}

.auth-docs-step-list h3,
.auth-docs-module-grid h3 {
  margin: 0 0 8px;
  color: #272522;
  font-size: 18px;
  line-height: 1.35;
  font-weight: 850;
}

.auth-docs-step-list p,
.auth-docs-module-grid p {
  margin: 0;
  color: #827d73;
  font-size: 14px;
  line-height: 1.75;
}

.auth-docs-module-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.auth-docs-module-grid article {
  min-height: 150px;
  padding: 20px;
  border: 1px solid rgba(216, 213, 202, 0.86);
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.84), rgba(250, 249, 245, 0.72));
  box-shadow:
    0 18px 54px rgba(109, 105, 97, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.78);
  backdrop-filter: blur(18px) saturate(1.05);
}

.auth-docs-notes {
  padding: 26px;
  border: 1px solid rgba(216, 213, 202, 0.86);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.68);
}

.auth-docs-notes ul {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.auth-docs-notes li {
  position: relative;
  padding-left: 18px;
  color: #79746b;
  font-size: 15px;
  line-height: 1.75;
}

.auth-docs-notes li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.82em;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #c96442;
}

.auth-usecase-grid article span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  margin-bottom: 28px;
  padding: 0 11px;
  border-radius: 999px;
  background: rgba(90, 138, 210, 0.12);
  color: #5a8ad2;
  font-size: 12px;
  font-weight: 850;
}

.auth-page-band {
  padding: 28px;
}

.auth-resource-list {
  display: grid;
  gap: 12px;
  max-width: 760px;
}

.auth-resource-list article {
  padding: 24px 26px;
}

.auth-changelog-feed {
  display: grid;
  gap: 76px;
  max-width: 760px;
}

.auth-changelog-entry {
  scroll-margin-top: 110px;
}

.auth-release-meta {
  display: inline-flex;
  align-items: baseline;
  gap: 16px;
  margin-bottom: 14px;
  color: #9c988f;
}

.auth-release-meta b {
  color: #1f1e1d;
  font-size: 16px;
  font-weight: 870;
}

.auth-release-meta time {
  color: #aca9a2;
  font-size: 14px;
}

.auth-changelog-entry > h2 {
  margin: 0 0 28px;
  color: #1f1e1d;
  font-size: 28px;
  line-height: 1.3;
  font-weight: 870;
}

.auth-release-section + .auth-release-section {
  margin-top: 22px;
}

.auth-release-section h3 {
  margin: 0 0 10px;
  color: #938e85;
  font-size: 15px;
  font-weight: 840;
}

.auth-release-section ul {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.auth-release-section li {
  position: relative;
  padding-left: 18px;
  color: #79746b;
  font-size: 16px;
  line-height: 1.75;
}

.auth-release-section li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.78em;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #bbb8b2;
}

.auth-content-actions {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 68px;
  padding-top: 22px;
  border-top: 1px solid rgba(216, 213, 202, 0.8);
}

.auth-content-primary {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 20px;
  border-radius: 999px;
  background: #1d1c1a;
  color: #ffffff;
  font-size: 14px;
  font-weight: 820;
  text-decoration: none;
  box-shadow: 0 16px 32px rgba(29, 28, 26, 0.16);
}

.auth-content-primary:hover,
.auth-content-primary:focus-visible {
  outline: none;
  background: #2b2a27;
}

.auth-content-actions span {
  color: #9f9b93;
  font-size: 13px;
  font-weight: 760;
}

.auth-page-copyright {
  position: relative;
  z-index: 1;
  margin-top: 28px;
  color: #a09c94;
  font-size: 13px;
  font-weight: 700;
}

/* 登录卡内版权说明放在 policy-links 下方，做成居中的轻量矩形信息块。 */
.auth-page-copyright-card {
  width: fit-content;
  max-width: 100%;
  margin: 4px auto 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  text-align: center;
  font-size: 12px;
  color: #938e85;
  font-weight: 650;
  letter-spacing: 0.01em;
}

/* auth-content-route（独立条款 / 隐私 / 帮助 子页）的版权同样靠右下，
   保持落地页全局一致。 */
.auth-page-copyright-content {
  width: min(100%, 1460px);
  justify-self: center;
  margin: clamp(8px, 1.5vh, 16px) auto 0;
  padding-right: clamp(2px, 1vw, 16px);
  text-align: right;
}

/* HAZ login refresh：版权改为页面底部居中。auth-gate 是 grid，把版权拉到最后一行 1/-1。 */
.auth-gate .auth-page-copyright-bottom-center {
  grid-column: 1 / -1;
  justify-self: center;
  text-align: center;
  margin: clamp(12px, 2vh, 24px) auto 16px;
  font-size: 12px;
  color: #8a8580;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.auth-landing .email-login-status {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #98938a;
  text-align: center;
  margin-top: 2px;
  transition:
    color 0.24s var(--ease-out),
    transform 0.24s var(--ease-out),
    opacity 0.24s var(--ease-out);
}

.auth-landing .email-login-status::before {
  content: "";
  width: 17px;
  height: 17px;
  flex: 0 0 17px;
  margin-right: 8px;
  background: currentColor;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M12 2.5 20 6v6.1c0 4.6-3.2 8.9-8 10.4-4.8-1.5-8-5.8-8-10.4V6l8-3.5Zm0 2.2L6 7.2v4.9c0 3.6 2.3 6.9 6 8.1 3.7-1.2 6-4.5 6-8.1V7.2l-6-2.5Zm3.7 6.1-4.4 4.6-2.1-2.1 1.2-1.2 1 1 3.2-3.4 1.1 1.1Z'/%3E%3C/svg%3E") center / contain no-repeat;
  transition:
    transform 0.24s var(--ease-out),
    opacity 0.24s var(--ease-out);
}

.auth-landing .email-login-status.error {
  color: #b42318;
}

.auth-landing .email-login-status.ok {
  color: #167a52;
}

.auth-landing .email-login-status.pending {
  color: #d77b57;
}

.auth-landing .email-login-status.error::before,
.auth-landing .email-login-status.ok::before,
.auth-landing .email-login-status.pending::before {
  transform: scale(1.04);
}

.auth-landing .email-login-status.pending::before {
  animation: auth-email-status-pulse 1s ease-in-out infinite;
}

@keyframes auth-email-status-pulse {
  0%,
  100% {
    opacity: 0.62;
    transform: scale(0.92);
  }
  50% {
    opacity: 1;
    transform: scale(1.08);
  }
}

.auth-landing .email-login-status code {
  display: none;
}

@media (max-width: 1180px) {
  .auth-marketing-nav {
    width: min(100%, 720px);
    grid-template-columns: minmax(0, auto) minmax(0, 1fr) auto;
  }

  .auth-marketing-links {
    justify-content: flex-end;
  }

  .auth-marketing-links a:nth-child(3),
  .auth-marketing-links a:nth-child(5) {
    display: none;
  }

  .auth-landing-grid {
    grid-template-columns: minmax(0, 560px);
  }

  .auth-side-column {
    display: none;
  }

  .auth-content-page {
    width: min(100%, 840px);
  }

  .auth-content-changelog {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .auth-content-rail {
    position: relative;
    top: auto;
    min-height: 0;
    padding: 0;
    border-right: 0;
  }

  .auth-changelog-timeline {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 6px;
    scrollbar-width: thin;
  }

  .auth-changelog-month {
    min-width: max-content;
    gap: 8px;
  }

  .auth-changelog-month-list {
    display: flex;
    gap: 8px;
  }

  .auth-changelog-month-list::before,
  .auth-changelog-dot {
    display: none;
  }

  .auth-changelog-timeline-item {
    display: inline-grid;
    grid-template-columns: auto auto;
    gap: 9px;
    justify-content: center;
    min-width: 118px;
    min-height: 34px;
    padding: 0 12px;
    border: 1px solid #f3e3dd;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.76);
    text-align: center;
  }

  .auth-changelog-timeline-item:hover {
    transform: none;
  }

  .auth-changelog-month > strong {
    min-height: 20px;
  }

  .auth-changelog-timeline-item.active {
    border-color: #1d1c1a;
    color: #1d1c1a;
  }

  .auth-content-main {
    padding: 24px 0 48px;
  }

  .auth-content-page.auth-content-changelog > .auth-content-main {
    max-height: none;
    padding-right: 0;
    overflow-y: visible;
    scrollbar-gutter: auto;
  }

  .auth-product-feature-grid {
    grid-template-columns: 1fr;
  }

  .auth-docs-module-grid {
    grid-template-columns: 1fr;
  }

  .auth-usecase-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 640px) {
  body.auth-gate-active .auth-gate {
    align-items: start;
    padding: 12px 14px 24px;
    overflow-y: auto;
  }

  body.auth-gate-active .auth-content-route {
    min-width: 0;
    width: 100%;
    padding-left: 10px;
    padding-right: 10px;
  }

  .auth-marketing-nav {
    width: 100%;
    min-height: 54px;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
    margin-bottom: 18px;
    padding: 6px;
    border-radius: 17px;
  }

  .auth-marketing-links {
    display: none;
  }

  .auth-marketing-brand {
    min-width: 0;
    padding-right: 8px;
  }

  .auth-marketing-brand strong {
    min-width: 0;
    overflow: hidden;
    font-size: 16px;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .auth-marketing-logo {
    width: 32px;
    height: 32px;
    flex-basis: 32px;
  }

  .auth-marketing-cta {
    min-height: 40px;
    padding: 0 14px;
    font-size: 13px;
  }

  .auth-landing-grid {
    width: 100%;
    align-items: start;
  }

  .auth-landing .email-auth-panel {
    min-height: 0;
    width: 100%;
    padding: 28px 20px 30px;
    border-radius: 18px;
    box-shadow: 0 22px 64px rgba(117, 112, 103, 0.16);
  }

  .auth-product-logo {
    gap: 12px;
    margin-bottom: 18px;
  }

  .auth-brand-logo {
    width: 46px;
    height: 46px;
    flex-basis: 46px;
  }

  .auth-product-logo strong {
    font-size: 23px;
  }

  .auth-hero-copy {
    margin-bottom: 20px;
  }

  .auth-hero-copy h2 {
    font-size: 28px;
    line-height: 1.15;
    margin-bottom: 10px;
  }

  .auth-hero-copy p {
    font-size: 14px;
    line-height: 1.65;
  }

  .auth-landing .email-login-form {
    width: 100%;
    gap: 13px;
  }

  .auth-field-row {
    gap: 8px;
  }

  .auth-input-shell {
    min-height: 54px;
    border-radius: 13px;
  }

  .auth-input-shell svg {
    margin-left: 14px;
  }

  .auth-input {
    min-height: 50px;
    padding-inline: 12px;
  }

  .auth-landing .auth-code-shell {
    grid-template-columns: auto minmax(0, 1fr) auto;
    column-gap: 4px;
    padding-right: 6px;
  }

  .auth-landing .auth-inline-send {
    height: 34px;
    min-height: 34px;
    padding: 0 12px;
    font-size: 13px;
  }

  .auth-submit-btn {
    min-height: 54px;
    font-size: 16px;
  }

  .auth-landing .email-login-status {
    align-items: flex-start;
    min-height: 34px;
    font-size: 12px;
    line-height: 1.55;
    text-align: left;
  }

  .auth-policy-links {
    margin-top: 30px;
    row-gap: 8px;
  }

  .auth-content-page {
    width: 100%;
    max-width: 100%;
  }

  .auth-content-changelog {
    gap: 12px;
  }

  .auth-content-route .auth-marketing-nav {
    margin-bottom: 16px;
  }

  .auth-content-rail-title {
    margin-bottom: 10px;
    font-size: 12px;
  }

  .auth-changelog-timeline-item {
    min-height: 34px;
    padding: 0 12px;
    font-size: 13px;
  }

  .auth-content-main {
    padding: 10px 0 36px;
    max-width: 100%;
  }

  .auth-page-hero {
    margin-bottom: 28px;
  }

  .auth-page-hero span {
    margin-bottom: 12px;
    font-size: 12px;
  }

  .auth-page-hero h1 {
    font-size: 36px;
    line-height: 1.12;
  }

  .auth-page-hero p {
    margin-top: 16px;
    font-size: 15px;
    line-height: 1.7;
  }

  .auth-usecase-grid,
  .auth-product-feature-grid {
    grid-template-columns: 1fr;
  }

  .auth-product-feature-grid article,
  .auth-usecase-grid article {
    min-height: 0;
    padding: 20px;
    border-radius: 16px;
  }

  .auth-page-band,
  .auth-resource-list article {
    padding: 20px;
    border-radius: 16px;
  }

  .auth-changelog-feed {
    gap: 48px;
  }

  .auth-changelog-entry > h2 {
    margin-bottom: 20px;
    font-size: 23px;
  }

  .auth-release-section li {
    font-size: 14px;
  }

  .auth-content-actions {
    align-items: stretch;
    flex-direction: column;
    margin-top: 42px;
  }
}

@media (max-width: 420px) {
  body.auth-gate-active .auth-gate {
    padding-inline: 10px;
  }

  .auth-landing .email-auth-panel {
    padding: 22px 16px 26px;
  }

  .auth-product-logo {
    justify-content: flex-start;
  }

  .auth-hero-copy {
    text-align: left;
  }

  .auth-hero-copy h2 {
    font-size: 26px;
  }

  .auth-hero-copy p {
    margin-inline: 0;
  }

  .auth-field-note {
    font-size: 11px;
  }

  .auth-landing .auth-inline-send {
    padding: 0 10px;
  }
}

.utility-rail {
  min-width: 0;
  min-height: 0;
  display: none;
  flex-direction: column;
  border-left: 1px solid var(--color-border);
  background: var(--color-bg);
  overflow: hidden;
}

.desktop-resize-handle {
  display: none;
}

body.electron-shell .workspace-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 6px minmax(228px, 284px);
}

body.electron-shell .workspace-body .view-container {
  width: 100%;
  max-width: none;
  margin: 0;
}

body.electron-shell .utility-rail {
  display: flex;
}

.utility-rail-header {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 64px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--color-border);
}

.utility-rail-actions {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex: 0 0 auto;
}

.utility-rail-header strong,
.utility-row strong {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.utility-rail-eyebrow,
.utility-section-label {
  display: block;
  color: var(--text-muted);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.utility-rail-toggle {
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  background: var(--color-card);
  color: var(--text-muted);
  cursor: pointer;
}

.utility-rail-toggle:hover,
.utility-rail-toggle:focus-visible {
  background: var(--secondary);
  border-color: var(--color-border-strong);
  color: var(--text-main);
}

.utility-rail-toggle svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.utility-rail-mini {
  display: none;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 16px 10px;
  border-bottom: 1px solid var(--color-border);
}

.utility-rail-body {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  padding: 14px 16px 18px;
}

.utility-section {
  display: flex;
  flex-direction: column;
  gap: 9px;
  padding: 0 0 16px;
  margin: 0 0 16px;
  border-bottom: 1px solid var(--color-border);
  flex-shrink: 0 !important;
}

.utility-section:last-child {
  margin-bottom: 0;
  border-bottom: 0;
}

.utility-row {
  display: grid;
  grid-template-columns: 10px minmax(0, 1fr);
  align-items: start;
  gap: 10px;
  min-width: 0;
  flex-shrink: 0 !important;
}

.utility-row small {
  display: block;
  min-width: 0;
  margin-top: 2px;
  color: var(--text-muted);
  font-size: 0.74rem;
  line-height: 1.4;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.utility-dot {
  width: 8px;
  height: 8px;
  margin-top: 6px;
  border-radius: 999px;
  background: var(--text-muted);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--text-muted) 14%, transparent);
}

.utility-dot.ok {
  background: #16a34a;
  box-shadow: 0 0 0 3px rgba(22, 163, 74, 0.14);
}

.utility-dot.warn {
  background: #d97706;
  box-shadow: 0 0 0 3px rgba(217, 119, 6, 0.16);
}

.utility-dot.pending {
  background: #c96442;
  box-shadow: 0 0 0 3px rgba(201, 100, 66, 0.14);
}

.utility-empty {
  min-height: 42px;
  display: flex;
  align-items: center;
  color: var(--text-muted);
  font-size: 0.78rem;
}

body.electron-shell.utility-rail-collapsed .workspace-body {
  grid-template-columns: minmax(0, 1fr) 6px 58px;
}

body.electron-shell.utility-rail-collapsed .utility-rail-header {
  flex-direction: column;
  min-height: auto;
  padding: 12px 10px;
}

body.electron-shell.utility-rail-collapsed .utility-rail-header > div {
  display: none;
}

body.electron-shell.utility-rail-collapsed .utility-rail-toggle {
  transform: rotate(180deg);
}

body.electron-shell.utility-rail-collapsed .utility-rail-mini {
  display: flex;
}

body.electron-shell.utility-rail-collapsed .utility-rail-body {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  padding: 0;
}

@media (max-width: 900px) {
  .workspace-body {
    display: flex;
    flex-direction: column;
    overflow-y: auto;
  }

  .utility-rail {
    flex: 0 0 auto;
    width: 100%;
    border-left: 0;
    border-top: 1px solid var(--color-border);
  }

  .utility-rail-body {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    max-height: none;
    overflow: visible;
  }

  .utility-section {
    margin: 0;
    padding: 0;
    border-bottom: 0;
  }

  body.electron-shell.utility-rail-collapsed .workspace-body {
    grid-template-columns: none;
  }

  body.electron-shell.utility-rail-collapsed .utility-rail {
    min-height: 54px;
  }

  body.electron-shell.utility-rail-collapsed .utility-rail-header {
    flex-direction: row;
  }

  body.electron-shell.utility-rail-collapsed .utility-rail-mini {
    flex-direction: row;
    justify-content: center;
    padding: 8px 12px 12px;
  }
}

@media (max-width: 760px) {
  body.sidebar-collapsed .sidebar {
    width: 100%;
    flex: 0 0 auto;
  }

  body.sidebar-collapsed .sidebar-header {
    padding: 12px 14px;
    align-items: flex-start;
    flex-direction: column;
  }

  body.sidebar-collapsed .brand {
    justify-content: flex-start;
  }

  .sidebar-shell-toggle,
  body.sidebar-collapsed .sidebar-shell-toggle {
    align-self: flex-start;
    margin: 0;
  }

  body.sidebar-collapsed .sidebar-nav {
    overflow-x: auto;
    overflow-y: hidden;
  }

  body.sidebar-collapsed .sidebar-nav ul {
    flex-direction: row;
    align-items: center;
    width: max-content;
  }

  .utility-rail-body {
    grid-template-columns: 1fr;
    padding: 12px 14px;
  }
}

body.reference-workbench-page {
  background: #ffffff;
  --primary: var(--primary-accent);
  --primary-hover: var(--primary-accent-hover);
  --color-bg: #ffffff;
  --color-border: #E7E7E7;
  --secondary: #faf9f5;
  --workbench-max: none;
}

body.reference-workbench-page .main-content {
  background: #ffffff;
}

body.reference-workbench-page .topbar {
  display: none;
}

body.reference-workbench-page .topbar p,
body.reference-workbench-page #refresh-button {
  display: none;
}

body.reference-workbench-page .view-container {
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 16px 24px 24px;
  gap: 12px;
}

body.reference-workbench-page .materials-toolbar,
body.reference-workbench-page .assets-toolbar,
body.reference-workbench-page .copylibrary-toolbar,
body.reference-workbench-page .review-filterbar {
  min-height: 56px;
  border-radius: 0;
  border-width: 0 0 1px;
  padding: 0 0 12px;
  background: #ffffff;
}

body.reference-workbench-page .materials-toolbar::before,
body.reference-workbench-page .assets-toolbar::before,
body.reference-workbench-page .copylibrary-toolbar::before,
body.reference-workbench-page .review-filterbar::before {
  color: var(--text-main);
  font-size: 1.35rem;
  font-weight: 700;
  line-height: 1.1;
  white-space: nowrap;
}

body.reference-workbench-page .materials-toolbar::before {
  content: "资料库";
}

body.reference-workbench-page .assets-toolbar::before {
  content: "资源库";
}

body.reference-workbench-page .copylibrary-toolbar::before {
  content: "文案库";
}

body.reference-workbench-page .review-filterbar::before {
  content: "数据复盘";
}

body.reference-workbench-page .utility-strip,
body.reference-workbench-page .module-card,
body.reference-workbench-page .materials-filter-group,
body.reference-workbench-page .assets-tree-panel,
body.reference-workbench-page .asset-detail-panel,
body.reference-workbench-page .material-detail-panel,
body.reference-workbench-page .review-side-panel .module-card {
  border-color: var(--color-border);
  box-shadow: none;
}

body.reference-workbench-page .upload-dropzone {
  position: absolute;
  width: 1px;
  height: 1px;
  min-height: 0;
  overflow: hidden;
  opacity: 0;
  padding: 0;
  border: 0;
}

body.reference-workbench-page .view-container.is-dragging {
  outline: 2px dashed var(--primary);
  outline-offset: -10px;
  background: var(--surface-muted);
}

body.assets-page .assets-stat-row {
  display: none;
}

@media (max-width: 1180px) {
  .auth-reference-shell {
    width: min(100%, 760px);
    grid-template-columns: minmax(0, 1fr);
    gap: 28px;
  }

  .auth-reference-showcase {
    align-items: center;
    text-align: center;
    width: auto;
    padding-left: 0;
    padding-bottom: 0;
    margin-right: 0;
  }

  .auth-reference-copy {
    max-width: 720px;
  }

  .auth-reference-copy p {
    margin-left: auto;
    margin-right: auto;
  }

  .auth-reference-features {
    width: min(100%, 720px);
  }

  .auth-workbench-preview {
    width: min(100%, 720px);
    margin-top: 38px;
    padding: 18px;
    gap: 16px;
    transform: perspective(900px) rotateX(1.2deg) rotateY(-1.8deg) rotateZ(2.6deg);
  }

  .auth-reference-login-card {
    justify-self: center;
    margin-right: 0;
  }
}

@media (max-width: 640px) {
  .auth-reference-home {
    padding-top: 12px !important;
  }

  .auth-reference-home .auth-marketing-nav {
    margin-bottom: 18px;
  }

  .auth-reference-shell {
    width: 100%;
    min-height: 0;
    gap: 18px;
  }

  .auth-reference-copy h1 {
    font-size: 33px;
    line-height: 1.12;
  }

  .auth-reference-copy p {
    margin-top: 12px;
    font-size: 14px;
    line-height: 1.65;
  }

  .auth-reference-features,
  .auth-workbench-preview {
    display: none;
  }

  .auth-reference-login-card {
    width: 100%;
    min-height: 0 !important;
    padding: 26px 20px 28px !important;
    border-radius: 18px !important;
  }

  .auth-reference-login-card .auth-product-logo {
    margin-bottom: 18px;
  }

  .auth-reference-login-card .auth-hero-copy {
    margin-bottom: 20px;
  }

  .auth-reference-login-card .auth-hero-copy h2 {
    font-size: 25px;
  }
}

/* =====================================================================
   HAZ login refresh：登录/落地页配色恢复成「以前那种蓝」
   slate / 工程蓝：#2563eb 主蓝 + slate-50/100/200 中性 + 蓝色 lightfall
   不走 data-palette（auth 页是独立 gate，不在 dashboard scope）；
   直接 override auth-gate 系列的暖陶土底/lightfall。
   ===================================================================== */
body.auth-gate-active {
  background:
    linear-gradient(115deg, rgba(90, 138, 210, 0.09) 0%, transparent 38%),
    linear-gradient(245deg, rgba(0, 140, 197, 0.06) 0%, transparent 34%),
    linear-gradient(135deg, #faf8fb 0%, #f6f7fb 44%, #f2f8fb 72%, #faf8fb 100%);
}

body.auth-gate-active .auth-gate::before {
  background:
    radial-gradient(circle at 50% 22%, rgba(90, 138, 210, 0.16), transparent 40%),
    linear-gradient(90deg, rgba(54, 55, 69, 0.08) 1px, transparent 1px),
    linear-gradient(0deg, rgba(54, 55, 69, 0.08) 1px, transparent 1px);
  background-size: auto, 80px 80px, 80px 80px;
}

body.auth-gate-active .auth-gate::after {
  background:
    radial-gradient(circle, rgba(90, 138, 210, 0.18) 0 2px, transparent 2.6px) 8% 18% / 150px 150px,
    radial-gradient(circle, rgba(0, 140, 197, 0.16) 0 1.8px, transparent 2.4px) 72% 14% / 190px 190px,
    radial-gradient(circle, rgba(90, 138, 210, 0.14) 0 2px, transparent 2.8px) 32% 82% / 210px 210px,
    radial-gradient(circle, rgba(54, 55, 69, 0.10) 0 1.5px, transparent 2.2px) 88% 70% / 175px 175px;
  opacity: 0.44;
}

.auth-landing .auth-lightfall::before {
  background:
    radial-gradient(circle, rgba(90, 138, 210, 0.28), rgba(90, 138, 210, 0.06) 58%, transparent 72%);
}

.auth-landing .auth-lightfall::after {
  background:
    radial-gradient(circle, rgba(0, 140, 197, 0.24), rgba(0, 140, 197, 0.06) 54%, transparent 76%);
}

/* 登录卡 + marketing nav 边/底用 slate 替陶土米白，保持登录页冷调一致性 */
.auth-landing .auth-reference-login-card {
  border-color: rgba(90, 138, 210, 0.24) !important;
  background: rgba(255, 255, 255, 0.94) !important;
  box-shadow: 0 34px 100px rgba(54, 55, 69, 0.12) !important;
}

.auth-landing .auth-marketing-nav,
.auth-landing .auth-marketing-brand,
.auth-landing .auth-marketing-cta {
  /* 让顶部 nav 透 slate 蓝玻璃感 */
  --auth-marketing-tint: rgba(248, 250, 252, 0.88);
}

/* 登录页主 CTA / "进入工作台" 统一改为中性灰底白字。 */
.auth-landing .auth-marketing-cta,
.auth-landing .auth-content-primary {
  background: #5a8ad2;
  color: #ffffff;
  box-shadow: 0 14px 28px rgba(90, 138, 210, 0.26);
}
.auth-landing .auth-marketing-cta:hover,
.auth-landing .auth-marketing-cta:focus-visible,
.auth-landing .auth-content-primary:hover,
.auth-landing .auth-content-primary:focus-visible {
  background: #008cc5;
  color: #ffffff;
  box-shadow: 0 18px 34px rgba(0, 140, 197, 0.28);
}

/* 登录表单主按钮跟顶部 CTA 保持同一套灰底白字。 */
.auth-landing .email-login-form .primary-btn,
.auth-landing .password-auth-panel .primary-btn {
  background: #5a8ad2 !important;
  border-style: solid !important;
  border-width: 13.63px !important;
  border-color: #5a8ad2 !important;
  color: #ffffff !important;
  box-shadow: 0 18px 34px rgba(90, 138, 210, 0.24) !important;
}
.auth-landing .email-login-form .primary-btn:hover,
.auth-landing .password-auth-panel .primary-btn:hover,
.auth-landing .email-login-form .primary-btn:focus-visible,
.auth-landing .password-auth-panel .primary-btn:focus-visible {
  background: #008cc5 !important;
  border-color: #008cc5 !important;
  color: #ffffff !important;
  box-shadow: 0 22px 40px rgba(0, 140, 197, 0.3) !important;
}
.auth-landing .auth-input-shell:hover,
.auth-landing .auth-input-shell:focus-within {
  border-color: rgba(90, 138, 210, 0.18) !important;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(250, 248, 251, 0.92)) !important;
  box-shadow:
    0 14px 34px rgba(54, 55, 69, 0.05),
    inset 0 1px 0 rgba(255, 255, 255, 0.92) !important;
  transform: none !important;
}

.auth-landing .auth-input-shell:hover svg,
.auth-landing .auth-input-shell:focus-within svg {
  background: rgba(90, 138, 210, 0.08) !important;
  stroke: #5a8ad2 !important;
  transform: none !important;
}

.auth-landing .auth-input:focus,
.auth-landing .email-code-input:focus {
  border-color: transparent !important;
  box-shadow: none !important;
  outline: none !important;
}
