* {
  box-sizing: border-box;
}

:root {
  --primary-color: #2563eb;
  --primary-deep: #1d4ed8;
  --primary-soft: #dbeafe;
  --cyan: #3b82f6;
  --panel-bg: rgba(248, 252, 255, 0.9);
  --card-bg: rgba(255, 255, 255, 0.72);
  --text-main: #111827;
  --text-sub: #475569;
  --text-muted: #64748b;
  --border-color: #b9c9dd;
  --shadow-soft: 0 30px 80px rgba(35, 69, 115, 0.18);
}

html,
body {
  width: 100%;
  height: 100%;
  margin: 0;
}

body.login-page {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  overflow-x: hidden;
  overflow-y: auto;
  color: var(--text-main);
  background:
    radial-gradient(circle at 18% 18%, rgba(147, 197, 253, 0.34), transparent 26%),
    radial-gradient(circle at 78% 82%, rgba(96, 165, 250, 0.34), transparent 30%),
    linear-gradient(135deg, #dbeafe 0%, #eff6ff 55%, #dbeafe 100%);
  position: relative;
}

body.login-page > div {
  position: relative;
  width: 100%;
  min-height: 100vh;
}

.bg-layer {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

.tech-bg {
  position: absolute;
  inset: -20%;
  opacity: 0.42;
  background-image:
    linear-gradient(rgba(37, 99, 235, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(37, 99, 235, 0.06) 1px, transparent 1px);
  background-size: 34px 34px;
  transform: rotate(-6deg);
}

.glow-circle {
  position: absolute;
  width: 780px;
  height: 780px;
  right: -180px;
  bottom: -280px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(37, 99, 235, 0.22) 0%, rgba(37, 99, 235, 0.08) 42%, rgba(255, 255, 255, 0) 72%);
}

.login-shell {
  position: relative;
  z-index: 10;
  width: 100%;
  min-height: 100vh;
}

.form-box {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 34px;
}

.login-layout {
  /* 用 80vw 而非 calc(100vw-68):缩放到 150% 时视口变窄,旧写法只留 34px 边距→卡片几乎占满整屏。
     80vw 让两栏卡在受限宽度下始终留两侧留白(占比 ~80% 而非 95%);大屏由 1214px 上限兜底,100% 观感不变。
     min-height 已去掉,卡片按内容自适应(卡高由 .main-card 的 clamp 随视口高连续收缩)。 */
  width: min(1214px, 80vw);
  /* margin:auto 在 flex 容器里既能上下左右居中,内容比视口高时又把多余空间分配为 0、
     顶部仍可滚动可见(避免 align-items:center 在矮屏裁掉顶部)。小屏媒体查询里的
     align-items:flex-start 会被 auto 外边距覆盖,故矮屏也能正确居中。 */
  margin: auto;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.35);
  border-radius: 30px;
  background: rgba(255, 255, 255, 0.58);
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(18px);
}

.intro-panel,
.login-panel {
  position: relative;
  padding: 44px 60px;
}

.intro-panel {
  overflow: hidden;
  background:
    radial-gradient(circle at 18% 14%, rgba(191, 219, 254, 0.72), transparent 34%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.68), rgba(232, 242, 255, 0.58));
}

.login-panel {
  display: flex;
  align-items: center;
  justify-content: center;
  border-left: 1px solid rgba(148, 163, 184, 0.55);
  background: rgba(255, 255, 255, 0.56);
}

.brand-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 52px;
  padding: 8px 18px 8px 12px;
  border: 1px solid rgba(147, 197, 253, 0.55);
  border-radius: 999px;
  background: rgba(239, 246, 255, 0.9);
  color: #2563eb;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: -0.01em;
  box-shadow: 0 18px 40px rgba(37, 99, 235, 0.14);
}

.logo-icon {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  color: #ffffff;
  background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
}

.logo-image-wrap {
  width: 36px;
  height: 36px;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: visible;
  border-radius: 50%;
  background: transparent;
}

.logo-image {
  display: block;
  width: auto;
  height: auto;
  max-width: 36px;
  max-height: 36px;
  object-fit: contain;
  transform: scale(1.18);
  transform-origin: center;
}

.logo-icon i.icon {
  margin: 0 !important;
  font-size: 16px;
}

.hero-copy {
  margin-top: 0;
  max-width: 560px;
}

.brand-row {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 12px;
}

.brand-logo-wrap {
  width: 44px;
  height: 44px;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.brand-logo {
  width: 44px;
  height: 44px;
  object-fit: contain;
  filter: drop-shadow(0 7px 10px rgba(7, 93, 202, 0.18));
}

.brand-logo-fallback {
  width: 44px;
  height: 44px;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  color: #fff;
  background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
  box-shadow: 0 8px 18px rgba(37, 99, 235, 0.28);
}

.brand-logo-fallback i.icon {
  margin: 0 !important;
  font-size: 22px;
}

.brand-name {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 30px;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.1;
  color: #1e3a8a;
}

/* 品牌名末词蓝渐变高亮；不支持 background-clip:text 的浏览器回退为纯蓝 */
.brand-name-accent {
  color: #2563eb;
  background: linear-gradient(100deg, #2563eb 0%, #3b82f6 55%, #1d4ed8 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-copy p {
  margin: 0;
  max-width: 540px;
  color: var(--text-sub);
  font-size: 15px;
  line-height: 1.8;
}

.security-illustration {
  position: relative;
  /* 两张特性卡用 flex 行铺满面板宽:任意宽度都自适应,不留白、不漂移、不需缩放;
     高度由卡片决定(去掉底部小卡行后整体更矮,小屏可完整显示)。 */
  display: flex;
  gap: 18px;
  padding: 22px;
  margin-top: 26px;
  border: 1px solid rgba(148, 163, 184, 0.58);
  border-radius: 30px;
  background: rgba(241, 248, 255, 0.42);
  overflow: hidden;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.75);
}

.grid-plane {
  position: absolute;
  inset: 0;
  opacity: 0.78;
  background-image:
    linear-gradient(rgba(37, 99, 235, 0.09) 1px, transparent 1px),
    linear-gradient(90deg, rgba(37, 99, 235, 0.09) 1px, transparent 1px);
  background-size: 31px 31px;
  mask-image: linear-gradient(to bottom, #000 0%, transparent 100%);
}

.feature-card,
.mini-card {
  position: absolute;
  border: 1px solid rgba(203, 213, 225, 0.7);
  border-radius: 24px;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.84), rgba(231, 242, 255, 0.7));
  box-shadow: 0 22px 46px rgba(37, 99, 235, 0.12);
  backdrop-filter: blur(16px);
}

.feature-card strong,
.mini-card strong {
  display: block;
  color: #172033;
  font-size: 16px;
  line-height: 1.2;
}

.feature-card small,
.mini-card small {
  display: block;
  color: #526176;
  font-size: 12px;
  line-height: 1.55;
}

.card-icon,
.mini-card i.icon {
  width: 34px;
  height: 34px;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  margin: 0 12px 0 0 !important;
  border-radius: 12px;
  color: #2563eb;
  background: #dbeafe;
}

.card-icon i.icon {
  margin: 0 !important;
}

.main-card {
  position: relative;
  flex: 250 1 0;
  /* 卡高随视口高连续收缩(而非按断点跳变),消除断点底边的溢出带:
     非卡内容(品牌+文案+胶囊+内外边距)约 340px,卡高 = 视口高 - 340,夹在 150~274 之间。
     高屏钉 274 满高,矮屏(含 150%/175% 缩放)平滑变矮,始终不需纵向滚动。 */
  height: clamp(150px, calc(100vh - 368px), 274px);
  padding: 26px 22px;
}

.main-card .card-icon,
.shield-card .card-icon {
  flex: none;
  margin: 0 !important;
  color: #fff;
  background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
  box-shadow: 0 8px 18px rgba(37, 99, 235, 0.3);
}

/* 右上角柔光提升层次(背景层,始终在内容之下);列式布局便于纵向分布内容,消除底部留白 */
.main-card,
.shield-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  background:
    radial-gradient(150% 100% at 100% 0%, rgba(59, 130, 246, 0.16), transparent 52%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.88), rgba(231, 242, 255, 0.72));
}

/* 卡头与副标题整体居中对齐(图标+标题一行居中,副标题居中在其下方) */
.card-top {
  width: 100%;
  text-align: center;
}

.card-head {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-bottom: 8px;
}

.card-top small {
  margin-top: 0;
  line-height: 1.45;
}

/* 左卡:卡头组(上)/ WAF 模块(中)/ 威胁标签(下)三段均匀分布,撑满卡片纵向,消除底部留白 */
.main-card {
  justify-content: space-between;
}

.apk-tile {
  clear: both;
  position: relative;
  overflow: hidden;
  width: 172px;
  height: 96px;
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 20px;
  background: linear-gradient(135deg, #3b82f6 0%, #2563eb 55%, #1d4ed8 100%);
  box-shadow: 0 16px 34px rgba(37, 99, 235, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.45);
}

.apk-tile span {
  position: relative;
  z-index: 2;
  padding-left: 0.18em; /* 抵消字间距在末字 F 后留的空白,让字组视觉居中 */
  font-size: 42px;
  font-weight: 900;
  letter-spacing: 0.18em;
  color: #fff;
  -webkit-text-fill-color: #fff;
  text-shadow: 0 2px 12px rgba(2, 16, 56, 0.3);
}

/* 顶部玻璃高光(静态,质感) */
.apk-tile::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.3), transparent 46%);
  pointer-events: none;
}

/* 斜向流光:周期性快速扫过,其余时间停在画外,无静态接缝 */
.apk-tile::after {
  content: "";
  position: absolute;
  top: -25%;
  left: -75%;
  width: 48%;
  height: 150%;
  transform: skewX(-18deg);
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.5), transparent);
  animation: wafShine 4.5s ease-in-out infinite;
}

@keyframes wafShine {
  0% { left: -75%; }
  16% { left: 135%; }
  100% { left: 135%; }
}

.metric-line {
  display: block;
  width: 168px;
  height: 10px;
  margin-top: 10px;
  border-radius: 99px;
  background: #dbe2ea;
}

.metric-line.primary {
  width: 122px;
  background: linear-gradient(90deg, #3b82f6, #2563eb);
}

.metric-line.short {
  width: 146px;
}

.shield-card {
  position: relative;
  flex: 194 1 0;
  height: clamp(150px, calc(100vh - 368px), 274px);
  padding: 26px 20px;
}

.shield-card strong {
  white-space: nowrap;
}

.shield-card small {
  font-size: 11px;
}

.radar {
  position: absolute;
  left: 50%;
  bottom: 40px;
  width: 120px;
  height: 120px;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #93c5fd;
  border-radius: 50%;
  color: #1d4ed8;
  background: radial-gradient(circle, rgba(191, 219, 254, 0.86), rgba(239, 246, 255, 0.36));
  box-shadow: inset 0 0 26px rgba(59, 130, 246, 0.18), 0 12px 26px rgba(37, 99, 235, 0.14);
}

.radar::before {
  content: "";
  position: absolute;
  inset: 18px;
  border: 1px solid #93c5fd;
  border-radius: 50%;
}

.radar i.icon {
  margin: 0 !important;
  font-size: 30px;
}

/* 旋转扫描扇区(雷达扫描的活跃感) */
.radar-sweep {
  position: absolute;
  inset: 3px;
  z-index: 1;
  border-radius: 50%;
  background: conic-gradient(from 0deg,
    rgba(59, 130, 246, 0) 0deg,
    rgba(59, 130, 246, 0) 268deg,
    rgba(59, 130, 246, 0.16) 320deg,
    rgba(59, 130, 246, 0.42) 360deg);
  animation: radarSweep 3.6s linear infinite;
}

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

/* 中心护盾核心:白色发光圆盘,让护盾从雷达里"浮"出来 */
.radar-core {
  position: relative;
  z-index: 2;
  width: 58px;
  height: 58px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 35%, #ffffff, #eaf2ff);
  box-shadow: 0 6px 16px rgba(37, 99, 235, 0.26), inset 0 0 0 1px rgba(147, 197, 253, 0.75);
}

.radar-core i.icon {
  margin: 0 !important;
  font-size: 26px;
  color: #2563eb;
}

.mini-card {
  bottom: 22px;
  width: 142px;
  min-height: 88px;
  display: grid;
  grid-template-columns: 38px 1fr;
  align-items: center;
  padding: 14px 16px;
}

.mini-card i.icon {
  grid-row: 1 / span 2;
  font-size: 15px;
}

/* 小卡副标题单行(如"实时风险洞察"6 字恰好超出 1fr 列宽会换行,禁止换行让它单行显示) */
.mini-card small {
  white-space: nowrap;
}

.node-card { left: 22px; }
.policy-card { left: 182px; }
.monitor-card { right: 22px; }

/* 能力标签(hero 下方,快速体现核心能力) */
.cap-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 20px;
}

.cap-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border: 1px solid rgba(147, 197, 253, 0.6);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.66);
  color: #1e3a8a;
  font-size: 12.5px;
  font-weight: 600;
  white-space: nowrap;
  box-shadow: 0 6px 16px rgba(37, 99, 235, 0.08);
}

.cap-pill i.icon {
  margin: 0 !important;
  font-size: 12px;
  /* 不锁 line-height 时图标继承 pill 的 ~20px 行高，字形按 20px 行盒排进 12px 的 icon 盒里被顶高，
     和中文字不在一条中线上；line-height:1 让字形行盒=icon 盒，配合 flex align-items:center 真正居中。 */
  line-height: 1;
  color: #2563eb;
}

/* WAF 检测类型标签(主卡片) */
.threat-tags {
  clear: both;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 14px;
}

.threat-tags span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px 4px 8px;
  border-radius: 8px;
  border: 1px solid rgba(37, 99, 235, 0.2);
  background: linear-gradient(135deg, rgba(239, 246, 255, 0.92), rgba(219, 234, 254, 0.72));
  color: #1d4ed8;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.threat-tags span::before {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #3b82f6;
  box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.18);
}

/* 雷达脉冲(活跃感) */
.radar::after {
  content: "";
  position: absolute;
  inset: 8px;
  border: 1px solid rgba(37, 99, 235, 0.45);
  border-radius: 50%;
  animation: radarPulse 2.8s ease-out infinite;
}

@keyframes radarPulse {
  0% { transform: scale(0.65); opacity: 0.8; }
  70% { opacity: 0.12; }
  100% { transform: scale(1.3); opacity: 0; }
}

.login-card {
  width: 100%;
  max-width: 494px;
  padding: 0;
  background: transparent;
  box-shadow: none;
}

.card-header {
  margin-bottom: 26px;
}

.login-lock {
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 22px;
  border-radius: 14px;
  color: #2563eb;
  background: linear-gradient(135deg, #dbeafe, #bfdbfe);
}

.login-lock .login-lock-svg {
  width: 20px;
  height: 20px;
}

.card-header h2 {
  margin: 0 0 12px;
  color: #1e3a8a;
  font-size: 26px;
  line-height: 1.2;
  font-weight: 400;
  letter-spacing: -0.03em;
}

.header-title {
  margin: 0;
  color: var(--text-sub);
  font-size: 15px;
  line-height: 1.6;
}

.login-form {
  margin: 0;
}

.login-form .input-group {
  margin-bottom: 22px;
}

.login-form .input-label {
  display: block;
  margin-bottom: 8px;
  color: #334155;
  font-size: 14px;
  font-weight: 600;
}

.login-form .ui.left.icon.input {
  width: 100%;
  position: relative;
}

.login-form .ui.left.icon.input .input-icon {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  width: 18px;
  height: 18px;
  color: #64748b;
  pointer-events: none;
  z-index: 2;
  transition: color 0.2s ease;
}

.login-form .ui.left.icon.input input {
  width: 100%;
  height: 52px;
  padding: 14px 18px 14px 48px;
  border: 1px solid var(--border-color);
  border-radius: 16px;
  outline: none;
  color: #111827;
  background: rgba(241, 247, 255, 0.72);
  font-size: 14px !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.74), 0 1px 2px rgba(15, 23, 42, 0.04);
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.login-form .ui.left.icon.input input::placeholder {
  color: #94a3b8;
}

.login-form .ui.left.icon.input input:focus {
  border-color: #2563eb;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

/* 覆盖 Chrome 自动填充的黄色底色，保持与普通输入框一致的浅蓝底 */
.login-form .ui.left.icon.input input:-webkit-autofill,
.login-form .ui.left.icon.input input:-webkit-autofill:hover {
  -webkit-text-fill-color: #111827;
  -webkit-box-shadow: inset 0 0 0 1000px #f1f7ff, inset 0 1px 0 rgba(255, 255, 255, 0.74);
  caret-color: #111827;
  transition: background-color 9999s ease-in-out 0s;
}

.login-form .ui.left.icon.input input:-webkit-autofill:focus {
  border-color: #2563eb;
  -webkit-box-shadow: inset 0 0 0 1000px #ffffff, 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.login-form .ui.left.icon.input:focus-within .input-icon {
  color: #2563eb;
}

.remember-wrap {
  margin: -4px 0 14px;
}

.remember-wrap .ui.checkbox label {
  color: #64748b;
  font-size: 13px;
}

.submit-btn.ui.button.primary {
  width: 100%;
  height: 50px;
  margin-top: 2px;
  border: none;
  border-radius: 16px;
  color: #ffffff;
  background: linear-gradient(100deg, #3b82f6 0%, #2563eb 55%, #1d4ed8 100%) !important;
  box-shadow: 0 16px 32px rgba(37, 99, 235, 0.20);
  font-size: 18px !important;
  font-weight: 400;
  letter-spacing: 0.08em;
  transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease;
}

.submit-btn.ui.button.primary:hover {
  transform: translateY(-1px);
  filter: saturate(1.08);
  box-shadow: 0 20px 38px rgba(37, 99, 235, 0.24);
}

/* 密码 显示/隐藏 切换 */
.login-form .input-field-wrapper {
  position: relative;
}

.login-form .password-field .ui.left.icon.input input {
  padding-right: 46px;
}

.login-form .password-toggle {
  position: absolute;
  top: 0;
  right: 6px;
  width: 40px;
  height: 52px;
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #94a3b8;
  font-size: 15px;
  cursor: pointer;
  z-index: 3;
  transition: color 0.2s ease;
}

.login-form .password-toggle:hover {
  color: #2563eb;
}

.login-form .password-toggle .pw-eye {
  width: 18px;
  height: 18px;
}

/* ==== 宽度档:横向管布局/占比,与高度档(纵向)叠加 ==== */

/* 顶宽受限(viewport < ~1517,含 150%/175% 缩放):login-layout 用 80vw 后在受限宽度被压窄,
   固定 px 的能力胶囊相对变大→第 4 枚会被挤到第二行。此区间缩小胶囊(padding/字号/间距)保证 4 枚同行;
   并整体收小内容(品牌/文案/表单,输入框/按钮 52/50→44)抵消缩放放大的观感,让登录卡不显臃肿(两栏 + 单卡共用)。 */
@media screen and (max-width: 1400px) {
  .cap-pills {
    gap: 5px;
  }

  .cap-pill {
    padding: 5px 8px;
    font-size: 11.5px;
    gap: 5px;
  }

  .cap-pill i.icon {
    font-size: 12px;
  }

  .brand-row .brand-logo-wrap,
  .brand-logo,
  .brand-logo-fallback {
    width: 38px;
    height: 38px;
  }

  .brand-logo-fallback i.icon {
    font-size: 18px;
  }

  .brand-name {
    font-size: 24px;
  }

  .hero-copy p {
    font-size: 13.5px;
    line-height: 1.55;
  }

  .intro-panel,
  .login-panel {
    padding: 30px 40px;
  }

  /* 右侧登录表单整体收小(输入框/按钮 52/50→44),与单卡共用 */
  .login-lock {
    width: 38px;
    height: 38px;
    margin-bottom: 12px;
    border-radius: 11px;
  }

  .login-lock .login-lock-svg {
    width: 17px;
    height: 17px;
  }

  .card-header {
    margin-bottom: 16px;
  }

  .card-header h2 {
    font-size: 21px;
  }

  .login-form .input-label {
    font-size: 13px;
    margin-bottom: 6px;
  }

  .login-form .input-group {
    margin-bottom: 14px;
  }

  .login-form .ui.left.icon.input input {
    height: 44px;
    border-radius: 12px;
    padding: 12px 16px 12px 42px;
  }

  .login-form .ui.left.icon.input .input-icon {
    left: 14px;
  }

  .login-form .password-field .ui.left.icon.input input {
    padding-right: 42px;
  }

  .login-form .password-toggle {
    height: 44px;
  }

  .submit-btn.ui.button.primary {
    height: 44px;
    border-radius: 12px;
    font-size: 15px !important;
  }
}

@media screen and (max-width: 1180px) {
  /* 窄屏(含 1366 笔记本 @150% ≈ 911 宽 / 1080p @175% ≈ 1097 宽):隐藏左侧介绍面板,只留右侧登录卡,
     收窄为聚焦单卡(350px)、垂直居中。两栏低于 ~1180 会挤到胶囊换行/内容过窄,直接切单卡更干净
     (对齐 deepgate 登录页)。内容尺寸沿用上面 max-width:1400 的统一收小,这里只管布局。 */
  .form-box {
    padding: 20px;
    align-items: center;
  }

  .login-layout {
    width: min(350px, calc(100vw - 40px));
    min-height: auto;
    grid-template-columns: 1fr;
  }

  .intro-panel {
    display: none !important;
  }

  /* login-panel padding 用 !important 压过矮屏 max-height 档的宽 padding,否则单卡会被塞窄 */
  .login-panel {
    border-left: none !important;
    border-top: none !important;
    padding: 28px 24px !important;
  }

  .login-card {
    max-width: none;
  }

  .submit-btn.ui.button.primary {
    margin-top: 4px;
  }
}

@media screen and (max-width: 640px) {
  /* 手机:单卡铺满宽度(此宽度下 intro 已被 1180 档隐藏,故只调单卡本身) */
  .form-box {
    padding: 14px;
    align-items: flex-start;
  }

  .login-layout {
    width: 100%;
    border-radius: 24px;
  }

  .login-panel {
    padding: 28px 18px !important;
  }
}

/* ==== 高度档:纵向管高度不滚动,逐级收内外边距/间距,内容全保留;输入框/按钮不再缩(已在宽度档收到 44)。
   三档 850→680→560,越矮越紧;卡高另由 .main-card 的 clamp 随视口高连续收缩兜底。 ==== */
@media screen and (max-height: 850px) {
  .form-box {
    padding: 20px;
    align-items: flex-start;
  }

  .login-layout {
    min-height: auto;
  }

  /* 只压纵向 padding;横向保持 60,使内容宽与默认一致(~516),示意图(506)依旧近似铺满,左右不空 */
  .intro-panel,
  .login-panel {
    padding: 32px 60px;
  }

  .hero-copy p {
    line-height: 1.6;
  }

  .cap-pills {
    margin-top: 14px;
  }

  .security-illustration {
    margin-top: 18px;
    padding: 18px;
  }
}

@media screen and (max-height: 680px) {
  .intro-panel,
  .login-panel {
    padding: 26px 56px;
  }

  .brand-row {
    margin-bottom: 8px;
  }

  .hero-copy p {
    line-height: 1.5;
  }

  .cap-pills {
    margin-top: 10px;
    gap: 6px;
  }

  .security-illustration {
    margin-top: 14px;
    padding: 14px;
  }
}

/* 更矮(宽屏但窗口很矮 / 更高缩放):逐级压缩,让登录卡不再需要纵向滚动。内容全保留不隐藏,
   只收内外边距/间距与示意卡内边距;输入框/按钮尺寸不动。 */
@media screen and (max-height: 560px) {
  .intro-panel {
    padding: 20px 52px;
  }

  .login-panel {
    padding: 22px 52px;
  }

  .brand-row {
    margin-bottom: 6px;
  }

  .hero-copy p {
    font-size: 13.5px;
    line-height: 1.45;
  }

  .cap-pills {
    margin-top: 8px;
    gap: 6px;
  }

  .security-illustration {
    margin-top: 10px;
    padding: 10px;
  }

  .main-card,
  .shield-card {
    padding: 14px 12px;
  }

  /* 表单竖向留白微收(输入框/按钮本身不缩) */
  .login-card .card-header {
    margin-bottom: 12px;
  }

  .login-lock {
    margin-bottom: 12px;
  }

  .login-form .input-group {
    margin-bottom: 12px;
  }
}


/* SweetAlert2 fallback on login page */
body.login-page.swal2-height-auto {
  height: 100% !important;
}

body.login-page .swal2-container {
  position: fixed !important;
  inset: 0 !important;
  z-index: 20000 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 0.625em !important;
}

body.login-page .swal2-container.swal2-backdrop-show {
  background: rgba(0, 0, 0, 0.42) !important;
}

/* 提示弹窗(如登录页过期)确定按钮:统一为品牌蓝渐变,与登录按钮一致,覆盖 swal2 默认蓝 */
body.login-page .swal2-actions .swal2-confirm {
  background: linear-gradient(100deg, #3b82f6 0%, #2563eb 55%, #1d4ed8 100%) !important;
  color: #ffffff !important;
  border: none !important;
  border-radius: 12px !important;
  box-shadow: 0 12px 24px rgba(37, 99, 235, 0.22) !important;
  transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease !important;
}
body.login-page .swal2-actions .swal2-confirm:hover {
  transform: translateY(-1px) !important;
  filter: saturate(1.08) !important;
  box-shadow: 0 16px 30px rgba(37, 99, 235, 0.26) !important;
}
body.login-page .swal2-actions .swal2-confirm:focus {
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.35) !important;
}


