/* =========================================================
   梧桐里 · 主站登录 / 功能站门户
   视觉：暗色星云 + 薄荷叶片 + 玻璃卡片
   ========================================================= */

:root {
  --bg: #070c0b;
  --bg-deep: #040807;
  --ink: #eef5f1;
  --ink-soft: #d8e3dd;
  --muted: #a3b3ab;
  --muted-2: #74857d;
  --line: rgba(255, 255, 255, 0.09);
  --line-strong: rgba(255, 255, 255, 0.14);
  --mint: #8fe3c8;
  --mint-strong: #b4f3df;
  --mint-deep: #4fb79b;
  --mint-ink: #06231b;
  --gold: #e6c48a;
  --danger: #ff9f93;
  --card-bg: linear-gradient(155deg, rgba(22, 33, 29, 0.78), rgba(9, 14, 12, 0.84));
  --sans: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", system-ui, -apple-system, "Segoe UI", sans-serif;
  --serif: "Songti SC", "Noto Serif CJK SC", "Source Han Serif SC", "STSong", "SimSun", serif;
  --mono: ui-monospace, "SF Mono", "Cascadia Code", "Roboto Mono", Menlo, Consolas, monospace;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100svh;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

button,
input {
  font: inherit;
}

a {
  color: inherit;
}

a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--mint);
  outline-offset: 3px;
}

img {
  max-width: 100%;
}

[hidden] {
  display: none !important;
}

::selection {
  background: rgba(143, 227, 200, 0.28);
  color: #fff;
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 100;
  padding: 8px 14px;
  border-radius: 10px;
  background: var(--mint);
  color: var(--mint-ink);
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
  transform: translateY(-160%);
  transition: transform 0.2s ease;
}

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

.svg-sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.icon {
  width: 20px;
  height: 20px;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* =========================================================
   背景场
   ========================================================= */

.scene {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  background: var(--bg-deep);
  pointer-events: none;
}

.scene__nebula {
  position: absolute;
  inset: -7%;
  background: url("nebula.jpg") center / cover no-repeat;
  opacity: 0.46;
  filter: saturate(0.7) brightness(0.64) contrast(1.06);
  transform: scale(1.04);
  animation: nebula-drift 52s ease-in-out infinite alternate;
}

.scene__wash {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(58% 48% at 72% 16%, rgba(74, 190, 158, 0.2), transparent 64%),
    radial-gradient(46% 42% at 20% 82%, rgba(198, 132, 82, 0.14), transparent 66%),
    radial-gradient(90% 90% at 50% 48%, transparent 34%, rgba(3, 7, 6, 0.62) 100%),
    linear-gradient(180deg, rgba(4, 8, 7, 0.28), rgba(4, 8, 7, 0.9));
}

.scene__aurora {
  position: absolute;
  inset: 0;
  opacity: 0.55;
  filter: blur(90px);
}

.scene__aurora::before,
.scene__aurora::after {
  content: "";
  position: absolute;
  width: 44vw;
  height: 44vw;
  min-width: 320px;
  min-height: 320px;
  border-radius: 50%;
}

.scene__aurora::before {
  top: -14%;
  right: 4%;
  background: rgba(64, 174, 143, 0.2);
  animation: aurora-a 24s ease-in-out infinite alternate;
}

.scene__aurora::after {
  bottom: -22%;
  left: 2%;
  background: rgba(190, 126, 82, 0.15);
  animation: aurora-b 30s ease-in-out infinite alternate;
}

.scene__leaf {
  position: absolute;
  right: -10vw;
  bottom: -14vh;
  width: min(760px, 74vw);
  opacity: 0.055;
  mix-blend-mode: screen;
  transform: rotate(-11deg);
  filter: blur(0.5px);
}

.scene__leaf img {
  display: block;
  width: 100%;
  height: auto;
}

.scene__grain {
  position: absolute;
  inset: 0;
  opacity: 0.045;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.82' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.6'/%3E%3C/svg%3E");
}

.scene__vignette {
  position: absolute;
  inset: 0;
  background: radial-gradient(120% 100% at 50% 42%, transparent 38%, rgba(2, 5, 4, 0.55) 100%);
}

@keyframes nebula-drift {
  from {
    transform: scale(1.04) translate3d(-0.6%, -0.4%, 0);
  }
  to {
    transform: scale(1.08) translate3d(0.8%, 0.6%, 0);
  }
}

@keyframes aurora-a {
  from {
    transform: translate3d(0, 0, 0) scale(1);
  }
  to {
    transform: translate3d(-4%, 5%, 0) scale(1.12);
  }
}

@keyframes aurora-b {
  from {
    transform: translate3d(0, 0, 0) scale(1.05);
  }
  to {
    transform: translate3d(5%, -4%, 0) scale(0.94);
  }
}

/* =========================================================
   骨架
   ========================================================= */

.shell {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  min-height: 100svh;
}

.view {
  min-height: 100vh;
  min-height: 100svh;
}

.view--login {
  display: flex;
  flex-direction: column;
}

.view--portal {
  display: flex;
  flex-direction: column;
}

/* =========================================================
   品牌
   ========================================================= */

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--ink);
  width: fit-content;
}

.brand__mark {
  width: 38px;
  height: 38px;
  flex: none;
  display: block;
  border-radius: 11px;
  overflow: hidden;
  background: #000;
  border: 1px solid var(--line-strong);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.35), 0 0 22px rgba(111, 211, 180, 0.1);
}

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

.brand__text {
  display: flex;
  flex-direction: column;
  line-height: 1;
  gap: 4px;
}

.brand__text strong {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.14em;
}

.brand__text small {
  font-size: 8px;
  letter-spacing: 0.32em;
  color: var(--muted-2);
  text-transform: uppercase;
}

/* =========================================================
   登录页
   ========================================================= */

.topbar {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 22px 30px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.topbar__right {
  display: flex;
  align-items: center;
  gap: 20px;
}

.topbar__link {
  color: var(--muted);
  font-size: 12px;
  letter-spacing: 0.08em;
  text-decoration: none;
  padding: 7px 2px;
  border-bottom: 1px solid transparent;
  transition: color 0.2s ease, border-color 0.2s ease;
}

.topbar__link:hover {
  color: var(--ink);
  border-color: rgba(143, 227, 200, 0.45);
}

.login-stage {
  width: 100%;
  max-width: 760px;
  margin: auto;
  padding: 24px 24px 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.brand-hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 26px;
}

.brand-hero__mark {
  position: relative;
  width: 66px;
  height: 66px;
  margin-bottom: 14px;
}

.brand-hero__mark img {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 19px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  box-shadow:
    0 18px 40px rgba(0, 0, 0, 0.42),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.brand-hero__glow {
  position: absolute;
  inset: 8% -18% -22%;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgba(111, 211, 180, 0.38), transparent 72%);
  filter: blur(14px);
}

.brand-hero__title {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(42px, 5.6vw, 58px);
  font-weight: 600;
  letter-spacing: 0.16em;
  line-height: 1;
  text-indent: 0.16em;
  color: #f4f9f6;
  text-shadow: 0 4px 40px rgba(0, 0, 0, 0.45);
}

.brand-hero__en {
  margin: 10px 0 0;
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0.48em;
  text-indent: 0.48em;
  text-transform: uppercase;
  color: var(--muted-2);
}

.brand-hero__tagline {
  margin: 14px 0 0;
  font-size: 13.5px;
  line-height: 1.7;
  letter-spacing: 0.03em;
  color: var(--muted);
}

/* ---------- 登录卡片 ---------- */

.login-card {
  position: relative;
  isolation: isolate;
  width: min(100%, 430px);
  padding: 30px 30px 22px;
  border-radius: 26px;
  text-align: left;
  background: rgba(12, 19, 17, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.11);
  box-shadow:
    0 40px 100px rgba(0, 0, 0, 0.52),
    0 2px 0 rgba(255, 255, 255, 0.04) inset,
    0 0 60px rgba(79, 183, 155, 0.035);
}

@supports ((-webkit-backdrop-filter: blur(1px)) or (backdrop-filter: blur(1px))) {
  .login-card {
    background: var(--card-bg);
    -webkit-backdrop-filter: blur(28px) saturate(1.22);
    backdrop-filter: blur(28px) saturate(1.22);
  }
}

.login-card::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(
    145deg,
    rgba(143, 227, 200, 0.34),
    rgba(255, 255, 255, 0.04) 30%,
    rgba(255, 255, 255, 0.02) 68%,
    rgba(230, 196, 138, 0.16)
  );
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  mask-composite: exclude;
  pointer-events: none;
}

.card-head .eyebrow {
  margin: 0 0 8px;
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.28em;
  color: var(--mint);
  text-transform: uppercase;
}

.card-head h2 {
  margin: 0;
  font-size: 28px;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--ink);
}

.card-sub {
  margin: 7px 0 0;
  font-size: 12.5px;
  color: var(--muted);
  letter-spacing: 0.02em;
}

.login-form {
  margin-top: 22px;
  display: grid;
  gap: 15px;
}

.field {
  display: grid;
  gap: 7px;
}

.field-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.field-head label {
  font-size: 12.5px;
  font-weight: 500;
  color: var(--ink-soft);
  letter-spacing: 0.04em;
}

.text-link {
  font-size: 11.5px;
  color: var(--muted-2);
  text-decoration: none;
  transition: color 0.2s ease;
}

.text-link:hover {
  color: var(--mint);
}

.input-shell {
  position: relative;
  display: flex;
  align-items: center;
}

.input-shell > .icon {
  position: absolute;
  left: 14px;
  width: 18px;
  height: 18px;
  color: #7f918a;
  pointer-events: none;
  transition: color 0.2s ease;
}

.input-shell:focus-within > .icon {
  color: var(--mint);
}

.input-shell input {
  width: 100%;
  height: 50px;
  padding: 0 46px 0 42px;
  border-radius: 13px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.042);
  color: var(--ink);
  font-size: 14px;
  letter-spacing: 0.01em;
  outline: none;
  transition:
    border-color 0.2s ease,
    background 0.2s ease,
    box-shadow 0.2s ease;
}

.input-shell input::placeholder {
  color: #65756e;
}

.input-shell input:hover {
  border-color: rgba(255, 255, 255, 0.17);
}

.input-shell input:focus {
  border-color: rgba(143, 227, 200, 0.55);
  background: rgba(255, 255, 255, 0.062);
  box-shadow: 0 0 0 3px rgba(143, 227, 200, 0.1);
}

.eye-btn {
  position: absolute;
  right: 6px;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: #81938b;
  cursor: pointer;
  transition: color 0.2s ease, background 0.2s ease;
}

.eye-btn:hover {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.06);
}

.eye-btn .icon {
  width: 18px;
  height: 18px;
}

.eye-btn [data-eye="off"] {
  display: none;
}

.eye-btn[aria-pressed="true"] [data-eye="on"] {
  display: none;
}

.eye-btn[aria-pressed="true"] [data-eye="off"] {
  display: block;
}

.form-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 20px;
  margin-top: -1px;
}

.check {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--muted);
  cursor: pointer;
  user-select: none;
}

.check input {
  appearance: none;
  -webkit-appearance: none;
  width: 16px;
  height: 16px;
  margin: 0;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 5px;
  background: rgba(255, 255, 255, 0.03);
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.check input::after {
  content: "";
  width: 8px;
  height: 4px;
  border-left: 2px solid var(--mint-ink);
  border-bottom: 2px solid var(--mint-ink);
  transform: rotate(-45deg) translate(0.5px, -1px) scale(0);
  transition: transform 0.15s ease;
}

.check input:checked {
  border-color: var(--mint);
  background: var(--mint);
}

.check input:checked::after {
  transform: rotate(-45deg) translate(0.5px, -1px) scale(1);
}

.check input:focus-visible {
  outline: 2px solid var(--mint);
  outline-offset: 2px;
}

.primary-btn {
  position: relative;
  height: 52px;
  margin-top: 2px;
  border: 0;
  border-radius: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: linear-gradient(135deg, #b9f3e1 0%, #7bdabc 46%, #4fb79b 100%);
  color: var(--mint-ink);
  font-size: 14.5px;
  font-weight: 650;
  letter-spacing: 0.08em;
  cursor: pointer;
  box-shadow:
    0 14px 34px rgba(79, 183, 155, 0.24),
    inset 0 1px 0 rgba(255, 255, 255, 0.52);
  transition:
    transform 0.2s var(--ease-out),
    box-shadow 0.2s ease,
    filter 0.2s ease;
}

.primary-btn:hover {
  transform: translateY(-1px);
  filter: saturate(1.05) brightness(1.02);
  box-shadow:
    0 18px 42px rgba(79, 183, 155, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.58);
}

.primary-btn:active {
  transform: translateY(0) scale(0.996);
}

.primary-btn:focus-visible {
  outline: 2px solid var(--mint-strong);
  outline-offset: 3px;
}

.primary-btn .btn-icon {
  width: 18px;
  height: 18px;
  transition: transform 0.2s var(--ease-out);
}

.primary-btn:hover .btn-icon {
  transform: translateX(3px);
}

.primary-btn.is-loading {
  pointer-events: none;
}

.primary-btn.is-loading .btn-label,
.primary-btn.is-loading .btn-icon {
  opacity: 0;
}

.primary-btn.is-loading .btn-spinner {
  display: block;
  position: absolute;
}

.btn-spinner {
  display: none;
  width: 17px;
  height: 17px;
  border: 2px solid rgba(6, 35, 27, 0.22);
  border-top-color: var(--mint-ink);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}

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

.form-error {
  min-height: 18px;
  margin: -2px 0 -4px;
  font-size: 12px;
  line-height: 1.5;
  color: var(--danger);
  opacity: 0;
  transition: opacity 0.18s ease;
}

.form-error.is-visible {
  opacity: 1;
}

.login-card.is-shaking {
  animation: shake 0.45s cubic-bezier(0.36, 0.07, 0.19, 0.97) both;
}

@keyframes shake {
  10%,
  90% {
    transform: translateX(-2px);
  }
  20%,
  80% {
    transform: translateX(4px);
  }
  30%,
  50%,
  70% {
    transform: translateX(-6px);
  }
  40%,
  60% {
    transform: translateX(6px);
  }
}

.card-foot {
  margin-top: 18px;
  padding-top: 15px;
  border-top: 1px solid rgba(255, 255, 255, 0.07);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 11px;
  color: var(--muted-2);
  letter-spacing: 0.02em;
  text-align: center;
}

.card-foot a {
  color: var(--muted);
  text-decoration: none;
  border-bottom: 1px dotted rgba(255, 255, 255, 0.22);
  transition: color 0.2s ease, border-color 0.2s ease;
}

.card-foot a:hover {
  color: var(--mint);
  border-color: rgba(143, 227, 200, 0.5);
}

.foot-sep {
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--muted-2);
  opacity: 0.6;
}

/* ---------- 功能站条 ---------- */

.site-strip-head {
  width: 100%;
  max-width: 680px;
  margin: 26px 0 9px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--muted-2);
}

.site-strip-hint {
  letter-spacing: 0.08em;
  font-weight: 400;
  text-transform: none;
  color: rgba(163, 179, 171, 0.55);
}

.site-strip {
  width: 100%;
  max-width: 680px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  text-align: left;
}

.site-chip {
  --accent: var(--mint);
  position: relative;
  display: flex;
  align-items: center;
  gap: 9px;
  min-height: 55px;
  padding: 10px 11px;
  border-radius: 13px;
  border: 1px solid rgba(255, 255, 255, 0.075);
  background: rgba(255, 255, 255, 0.032);
  color: var(--ink);
  text-decoration: none;
  transition:
    transform 0.2s var(--ease-out),
    border-color 0.2s ease,
    background 0.2s ease;
}

.site-chip .icon {
  width: 17px;
  height: 17px;
  color: var(--accent);
  opacity: 0.92;
}

.site-chip__text {
  display: flex;
  flex-direction: column;
  min-width: 0;
  line-height: 1.25;
}

.site-chip__text strong {
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: 0.04em;
}

.site-chip__text small {
  margin-top: 2px;
  font-size: 9px;
  color: var(--muted-2);
  letter-spacing: 0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.site-chip:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.055);
}

@supports (border-color: color-mix(in srgb, white 30%, transparent)) {
  .site-chip:hover {
    border-color: color-mix(in srgb, var(--accent) 32%, transparent);
  }
}

.site-chip:hover .site-chip__text small {
  color: var(--muted);
}

.chip-dot {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--mint);
  box-shadow: 0 0 8px rgba(143, 227, 200, 0.8);
}

.site-chip[data-app="chat"] {
  --accent: #8bb8ff;
}

.site-chip[data-app="df"] {
  --accent: #e8c07a;
}

.site-chip[data-app="ls"] {
  --accent: #e39a9a;
}

.site-chip[data-status="soon"] .chip-dot {
  background: var(--gold);
  box-shadow: 0 0 8px rgba(230, 196, 138, 0.75);
}

.site-foot {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 16px 30px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  font-size: 10.5px;
  color: rgba(116, 133, 125, 0.75);
  letter-spacing: 0.04em;
}

.foot-badge {
  padding: 4px 9px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
  font-size: 9.5px;
  letter-spacing: 0.12em;
  color: var(--muted-2);
}

/* =========================================================
   门户
   ========================================================= */

.portal-shell {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 30px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.portal-head {
  min-height: 88px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.065);
}

.portal-user {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 5px 5px 5px 7px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.075);
  background: rgba(255, 255, 255, 0.035);
}

.avatar {
  width: 34px;
  height: 34px;
  flex: none;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: linear-gradient(145deg, var(--mint-strong), var(--mint-deep));
  color: var(--mint-ink);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.02em;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.12) inset;
}

.user-meta {
  display: flex;
  flex-direction: column;
  min-width: 0;
  max-width: 190px;
  line-height: 1.25;
}

.user-meta strong {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.02em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.user-meta small {
  margin-top: 2px;
  font-size: 9.5px;
  color: var(--muted-2);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.icon-btn {
  width: 34px;
  height: 34px;
  flex: none;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  transition: color 0.2s ease, background 0.2s ease;
}

.icon-btn:hover {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.08);
}

.icon-btn:focus-visible {
  outline: 2px solid var(--mint);
  outline-offset: 2px;
}

.icon-btn .icon {
  width: 17px;
  height: 17px;
}

.portal-hero {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 32px;
  margin: 46px 0 34px;
}

.eyebrow {
  margin: 0;
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--mint);
}

.portal-hero h1 {
  margin: 11px 0 7px;
  font-family: var(--serif);
  font-size: clamp(34px, 4.2vw, 50px);
  font-weight: 600;
  line-height: 1.16;
  letter-spacing: 0.02em;
  color: #f4f9f6;
  overflow-wrap: anywhere;
}

.portal-sub {
  margin: 0;
  font-size: 13.5px;
  color: var(--muted);
  letter-spacing: 0.02em;
}

.hero-quote {
  flex: none;
  margin: 0 0 6px;
  padding-right: 17px;
  border-right: 1px solid rgba(143, 227, 200, 0.22);
  font-family: var(--serif);
  font-size: 12.5px;
  line-height: 1.9;
  letter-spacing: 0.06em;
  color: var(--muted-2);
  text-align: right;
}

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

.app-card {
  --accent: var(--mint);
  position: relative;
  isolation: isolate;
  display: flex;
  flex-direction: column;
  min-height: 208px;
  padding: 23px 23px 18px;
  border-radius: 21px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.055), rgba(255, 255, 255, 0.016));
  color: var(--ink);
  text-decoration: none;
  overflow: hidden;
  transition:
    transform 0.28s var(--ease-out),
    border-color 0.28s ease,
    box-shadow 0.28s ease,
    background 0.28s ease;
}

.app-card::before {
  content: "";
  position: absolute;
  z-index: -1;
  top: -55%;
  left: -20%;
  width: 65%;
  height: 100%;
  border-radius: 50%;
  background: var(--accent);
  opacity: 0.07;
  filter: blur(52px);
  transition: opacity 0.3s ease;
}

.app-card:hover {
  transform: translateY(-4px);
  border-color: rgba(255, 255, 255, 0.16);
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.075), rgba(255, 255, 255, 0.022));
  box-shadow:
    0 26px 60px rgba(0, 0, 0, 0.4),
    0 0 0 1px rgba(255, 255, 255, 0.035) inset;
}

@supports (border-color: color-mix(in srgb, white 30%, transparent)) {
  .app-card:hover {
    border-color: color-mix(in srgb, var(--accent) 34%, transparent);
  }
}

.app-card:hover::before {
  opacity: 0.13;
}

.app-card:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.app-card[data-app="chat"] {
  --accent: #8bb8ff;
}

.app-card[data-app="df"] {
  --accent: #e8c07a;
}

.app-card[data-app="ls"] {
  --accent: #e39a9a;
}

.app-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.app-icon {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: var(--accent);
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(255, 255, 255, 0.09);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 0 26px rgba(255, 255, 255, 0.02);
  transition: background 0.25s ease, border-color 0.25s ease;
}

@supports (background: color-mix(in srgb, white 10%, transparent)) {
  .app-icon {
    background: color-mix(in srgb, var(--accent) 11%, transparent);
    border-color: color-mix(in srgb, var(--accent) 18%, transparent);
    box-shadow:
      inset 0 1px 0 rgba(255, 255, 255, 0.08),
      0 0 28px color-mix(in srgb, var(--accent) 9%, transparent);
  }
}

.app-icon .icon {
  width: 22px;
  height: 22px;
}

.app-arrow {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--muted-2);
  transition:
    background 0.25s ease,
    color 0.25s ease,
    border-color 0.25s ease,
    transform 0.25s var(--ease-out);
}

.app-arrow .icon {
  width: 15px;
  height: 15px;
}

.app-card:hover .app-arrow {
  background: var(--accent);
  border-color: transparent;
  color: #06110e;
  transform: translate(1px, -1px);
}

.app-body {
  margin-top: auto;
  padding-top: 24px;
}

.app-body h2 {
  margin: 0;
  display: flex;
  align-items: baseline;
  gap: 9px;
  font-size: 20px;
  font-weight: 600;
  letter-spacing: 0.04em;
}

.app-en {
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0.2em;
  color: var(--muted-2);
}

.app-body p {
  margin: 6px 0 0;
  font-size: 12.5px;
  line-height: 1.6;
  color: var(--muted);
}

.app-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: 16px;
  padding-top: 13px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.app-url {
  font-size: 10px;
  color: var(--muted-2);
  letter-spacing: 0.02em;
}

.app-status {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 10px;
  color: var(--muted);
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.app-status i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--mint);
  box-shadow: 0 0 8px rgba(143, 227, 200, 0.8);
}

.app-status[data-status="soon"] {
  color: rgba(230, 196, 138, 0.85);
}

.app-status[data-status="soon"] i {
  background: var(--gold);
  box-shadow: 0 0 8px rgba(230, 196, 138, 0.75);
}

.portal-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 42px;
  padding: 17px 0 23px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  font-size: 10.5px;
  color: var(--muted-2);
  letter-spacing: 0.05em;
}

.portal-clock {
  font-variant-numeric: tabular-nums;
  color: var(--muted);
}

/* =========================================================
   视图切换 / 提示
   ========================================================= */

.view.is-leaving {
  opacity: 0;
  transform: translateY(-8px);
  transition: opacity 0.3s ease, transform 0.3s ease;
  pointer-events: none;
}

.view.is-entering {
  animation: view-in 0.55s var(--ease-out) both;
}

@keyframes view-in {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 28px;
  z-index: 60;
  max-width: min(88vw, 420px);
  padding: 10px 17px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(15, 24, 21, 0.92);
  color: var(--ink-soft);
  font-size: 12px;
  letter-spacing: 0.02em;
  text-align: center;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  opacity: 0;
  transform: translate(-50%, 10px);
  pointer-events: none;
  transition: opacity 0.22s ease, transform 0.22s var(--ease-out);
}

.toast.is-visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

/* =========================================================
   响应式
   ========================================================= */

@media (max-width: 900px) {
  .login-stage {
    max-width: 700px;
  }

  .site-strip-head,
  .site-strip {
    max-width: 620px;
  }

  .portal-hero {
    margin-top: 38px;
  }
}

@media (max-width: 760px) {
  .topbar {
    padding: 18px 20px 0;
  }

  .topbar__link {
    font-size: 11.5px;
  }

  .login-stage {
    padding: 18px 18px 16px;
  }

  .brand-hero {
    margin-bottom: 22px;
  }

  .brand-hero__mark {
    width: 56px;
    height: 56px;
    border-radius: 16px;
  }

  .brand-hero__mark img {
    border-radius: 16px;
  }

  .brand-hero__title {
    font-size: 40px;
    letter-spacing: 0.14em;
    text-indent: 0.14em;
  }

  .brand-hero__tagline {
    margin-top: 12px;
    font-size: 12.5px;
  }

  .login-card {
    padding: 24px 20px 20px;
    border-radius: 22px;
  }

  .card-head h2 {
    font-size: 25px;
  }

  .login-form {
    margin-top: 19px;
    gap: 13px;
  }

  .input-shell input {
    height: 48px;
  }

  .site-strip-head {
    margin-top: 22px;
    max-width: 100%;
  }

  .site-strip {
    max-width: 100%;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 7px;
  }

  .site-chip {
    min-height: 52px;
  }

  .site-foot {
    padding: 14px 20px 18px;
    font-size: 10px;
  }

  .portal-shell {
    padding: 0 20px;
  }

  .portal-head {
    min-height: 78px;
  }

  .portal-user {
    gap: 7px;
  }

  .user-meta {
    max-width: 112px;
  }

  .user-meta small {
    display: none;
  }

  .portal-hero {
    margin: 32px 0 26px;
  }

  .portal-hero h1 {
    font-size: 32px;
  }

  .hero-quote {
    display: none;
  }

  .app-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 10px;
  }

  .app-card {
    min-height: 180px;
    padding: 20px 20px 16px;
  }

  .app-body {
    padding-top: 18px;
  }

  .portal-foot {
    margin-top: 30px;
    padding-bottom: 18px;
    flex-wrap: wrap;
  }
}

@media (max-width: 420px) {
  .brand__text strong {
    font-size: 13px;
  }

  .brand__mark {
    width: 34px;
    height: 34px;
    border-radius: 10px;
  }

  .login-stage {
    padding-left: 15px;
    padding-right: 15px;
  }

  .brand-hero__title {
    font-size: 36px;
  }

  .brand-hero__en {
    font-size: 8px;
    letter-spacing: 0.4em;
    text-indent: 0.4em;
  }

  .login-card {
    padding: 22px 17px 18px;
  }

  .site-chip {
    padding: 9px 10px;
  }

  .site-chip__text small {
    font-size: 8.5px;
  }

  .portal-hero h1 {
    font-size: 29px;
  }

  .app-card {
    min-height: 172px;
  }

  .portal-user {
    padding-left: 5px;
  }

  .avatar {
    width: 30px;
    height: 30px;
    font-size: 12px;
  }

  .user-meta {
    max-width: 92px;
  }

  .icon-btn {
    width: 30px;
    height: 30px;
  }
}

@media (max-height: 960px) and (min-width: 761px) {
  .topbar {
    padding-top: 16px;
  }

  .login-stage {
    padding-top: 12px;
  }

  .brand-hero {
    margin-bottom: 18px;
  }

  .brand-hero__mark {
    width: 58px;
    height: 58px;
    margin-bottom: 10px;
  }

  .brand-hero__title {
    font-size: 50px;
  }

  .brand-hero__en {
    margin-top: 8px;
  }

  .brand-hero__tagline {
    margin-top: 10px;
    font-size: 13px;
  }

  .login-card {
    padding: 26px 28px 18px;
  }

  .login-form {
    margin-top: 18px;
    gap: 13px;
  }

  .input-shell input {
    height: 48px;
  }

  .card-foot {
    margin-top: 14px;
    padding-top: 12px;
  }

  .site-strip-head {
    margin-top: 18px;
  }

  .site-chip {
    min-height: 50px;
    padding: 8px 10px;
  }

  .site-foot {
    padding-top: 12px;
    padding-bottom: 14px;
  }
}

@media (max-height: 820px) and (min-width: 761px) {
  .topbar {
    padding-top: 14px;
  }

  .login-stage {
    padding-top: 8px;
  }

  .brand-hero {
    margin-bottom: 14px;
  }

  .brand-hero__mark {
    width: 52px;
    height: 52px;
    margin-bottom: 8px;
  }

  .brand-hero__title {
    font-size: 44px;
  }

  .brand-hero__tagline {
    margin-top: 8px;
    font-size: 12.5px;
  }

  .login-card {
    padding-top: 23px;
    padding-bottom: 16px;
  }

  .login-form {
    margin-top: 15px;
    gap: 11px;
  }

  .input-shell input {
    height: 46px;
  }

  .site-strip-head {
    margin-top: 14px;
  }

  .site-chip {
    min-height: 46px;
  }

  .site-foot {
    padding-bottom: 12px;
  }
}

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

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}
