/*
 * R电视 界面系统 v3（2026.10）
 * 方向：电视内容优先的深色界面——大幅主视觉、横向内容行、胶囊导航、
 * 大圆角卡片、柔和色调层级；文字少而大。系统字体，无外部依赖。
 * v3 更新：融入新 R logo 视觉语言——流动飘带渐变（品红→紫→蓝→青）、
 * 电路线条纹理、发光效果。
 */
:root {
  color-scheme: light;
  /* ---- 浅色基底 ---- */
  --bg: #f6f7fc;
  --s1: #ffffff;
  --s2: #eef0f7;
  --s3: #e2e6f1;
  --s4: #d3d9e8;
  --line: rgba(23, 28, 48, 0.09);
  --line-2: rgba(23, 28, 48, 0.16);
  --text: #191d27;
  --text-2: #565e73;
  --text-3: #8b93a8;
  /* ---- R logo 高饱和渐变色系 ---- */
  --r-pink: #ff2d78;
  --r-purple: #8b5cf6;
  --r-blue: #2d7ff9;
  --r-cyan: #00c8f0;
  --r-green: #22c55e;
  --r-orange: #ff9500;
  --gradient-r: linear-gradient(135deg, #ff2d78 0%, #8b5cf6 32%, #2d7ff9 64%, #00c8f0 100%);
  --gradient-r-wide: linear-gradient(120deg, #ff2d78 0%, #b45cf6 25%, #8b5cf6 40%, #2d7ff9 62%, #00c8f0 82%, #ffb020 100%);
  --gradient-r-soft: linear-gradient(135deg, rgba(255, 45, 120, 0.12), rgba(139, 92, 246, 0.12), rgba(45, 127, 249, 0.12), rgba(0, 200, 240, 0.12));
  --gradient-text: linear-gradient(100deg, #f01e6e 0%, #8b5cf6 35%, #2d7ff9 65%, #00a8d8 100%);
  --glow-r: 0 10px 36px rgba(255, 45, 120, 0.35), 0 6px 20px rgba(139, 92, 246, 0.3), 0 4px 14px rgba(45, 127, 249, 0.25);
  --glow-r-sm: 0 6px 20px rgba(139, 92, 246, 0.35), 0 3px 10px rgba(45, 127, 249, 0.22);
  --glow-card: 0 2px 6px rgba(23, 28, 48, 0.05), 0 12px 32px rgba(23, 28, 48, 0.08);
  --primary: #7c4dff;
  --on-primary: #ffffff;
  --primary-hover: #9370ff;
  --accent: #ff9500;
  --live: #ff2d55;
  --ok: #16a34a;
  --ok-bg: rgba(34, 197, 94, 0.1);
  --warn: #d97706;
  --warn-bg: rgba(255, 149, 0, 0.1);
  --bad: #dc2626;
  --bad-bg: rgba(220, 38, 38, 0.08);
  --info-bg: rgba(139, 92, 246, 0.1);
  --alipay: #0f6ae6;
  --wechat: #07a34c;
  --r-xs: 12px;
  --r-sm: 18px;
  --r: 24px;
  --r-lg: 32px;
  --font: "MiSans", "HarmonyOS Sans SC", "PingFang SC", -apple-system, BlinkMacSystemFont, "Noto Sans CJK SC", "Microsoft YaHei", "Segoe UI", sans-serif;
  --mono: "SF Mono", ui-monospace, "JetBrains Mono", Menlo, Consolas, monospace;
  --page: min(1320px, 100% - 64px);
  /* ---- 电路纹：加粗明显版（hero 主装饰）---- */
  --circuit-pattern: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='360' height='360' viewBox='0 0 360 360'%3E%3Cg fill='none' stroke-width='1.6' opacity='0.32'%3E%3Cpath d='M30 30h90v60h60' stroke='%23ff2d78'/%3E%3Ccircle cx='30' cy='30' r='4.5' fill='%23ff2d78' stroke='none'/%3E%3Ccircle cx='180' cy='90' r='4.5' fill='%238b5cf6' stroke='none'/%3E%3Cpath d='M270 60v75h-45v45' stroke='%238b5cf6'/%3E%3Ccircle cx='270' cy='60' r='4.5' fill='%2300c8f0' stroke='none'/%3E%3Cpath d='M60 270h75v-60h45' stroke='%232d7ff9'/%3E%3Ccircle cx='60' cy='270' r='4.5' fill='%23ff2d78' stroke='none'/%3E%3Cpath d='M300 300h-60v-75' stroke='%2300c8f0'/%3E%3Ccircle cx='300' cy='300' r='4.5' fill='%23a78bfa' stroke='none'/%3E%3Cpath d='M150 180h60v60' stroke='%23ff2d78'/%3E%3Ccircle cx='150' cy='180' r='4' fill='%232d7ff9' stroke='none'/%3E%3Cpath d='M90 120v60h-30' stroke='%238b5cf6'/%3E%3Ccircle cx='90' cy='120' r='4' fill='%2300c8f0' stroke='none'/%3E%3Cpath d='M240 240h50' stroke='%23ff9500'/%3E%3Ccircle cx='290' cy='240' r='4' fill='%23ff9500' stroke='none'/%3E%3C/g%3E%3C/svg%3E");
  /* ---- 飘带波浪分隔线（SVG）---- */
  --ribbon-wave: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='1440' height='90' viewBox='0 0 1440 90' preserveAspectRatio='none'%3E%3Cdefs%3E%3ClinearGradient id='g' x1='0' y1='0' x2='1' y2='0'%3E%3Cstop offset='0' stop-color='%23ff2d78'/%3E%3Cstop offset='0.32' stop-color='%238b5cf6'/%3E%3Cstop offset='0.64' stop-color='%232d7ff9'/%3E%3Cstop offset='1' stop-color='%2300c8f0'/%3E%3C/linearGradient%3E%3C/defs%3E%3Cpath d='M0 55 C 240 90, 480 10, 720 45 S 1200 80, 1440 35 L1440 90 L0 90 Z' fill='url(%23g)' opacity='0.9'/%3E%3Cpath d='M0 65 C 260 95, 500 25, 740 58 S 1220 88, 1440 48 L1440 90 L0 90 Z' fill='url(%23g)' opacity='0.35'/%3E%3C/svg%3E");
}
*,
*::before,
*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 88px; }

body {
  margin: 0;
  min-width: 320px;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  /* 浅底 + R 飘带柔光 */
  background-image:
    radial-gradient(1100px 520px at 108% -8%, rgba(255, 45, 120, 0.07), transparent 62%),
    radial-gradient(960px 500px at -12% 28%, rgba(45, 127, 249, 0.08), transparent 62%),
    radial-gradient(900px 460px at 50% 112%, rgba(0, 200, 240, 0.06), transparent 62%),
    radial-gradient(700px 380px at 85% 65%, rgba(139, 92, 246, 0.05), transparent 60%);
  background-attachment: fixed;
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4, p { margin: 0; }
[hidden] { display: none !important; }
::selection { background: rgba(139, 92, 246, 0.25); }
:focus-visible { outline: 3px solid var(--r-purple); outline-offset: 3px; border-radius: 6px; }

.page { width: var(--page); margin-inline: auto; }

/* 渐变文字工具类 */
.grad-text {
  background: var(--gradient-text);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

/* ================= 顶栏 ================= */
.topbar {
  position: sticky;
  top: 0;
  z-index: 40;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.92) 0%, rgba(246, 247, 252, 0.82) 100%);
  backdrop-filter: blur(20px) saturate(150%);
  -webkit-backdrop-filter: blur(20px) saturate(150%);
  border-bottom: 3px solid transparent;
  border-image: linear-gradient(90deg, #ff2d78, #8b5cf6, #2d7ff9, #00c8f0) 1;
}

.topbar-inner { display: flex; align-items: center; gap: 28px; height: 76px; }

.logo { display: inline-flex; align-items: center; gap: 10px; font-size: 21px; font-weight: 700; letter-spacing: 0.02em; white-space: nowrap; }
.logo img { width: 34px; height: 34px; filter: drop-shadow(0 3px 10px rgba(255, 45, 120, 0.35)); }

.tabs { display: flex; align-items: center; gap: 6px; }
.tabs a {
  padding: 8px 18px;
  border-radius: 999px;
  color: var(--text-2);
  font-size: 15px;
  font-weight: 500;
  transition: background 0.2s, color 0.2s, box-shadow 0.2s;
}
.tabs a:hover { background: var(--s2); color: var(--text); }
.tabs a.on { background: var(--gradient-r); color: #ffffff; box-shadow: var(--glow-r-sm); font-weight: 600; }

.topbar-end { display: flex; align-items: center; gap: 10px; margin-left: auto; }

/* ================= 按钮 ================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 24px;
  border: 0;
  border-radius: 999px;
  font-size: 15.5px;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s, box-shadow 0.25s, color 0.2s, filter 0.2s;
}
.btn:active { transform: scale(0.98); }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.btn svg { width: 20px; height: 20px; flex: none; }
.btn-primary {
  background: var(--gradient-r-wide);
  background-size: 180% 180%;
  background-position: 0% 50%;
  color: #ffffff;
  box-shadow: var(--glow-r-sm);
  text-shadow: 0 1px 3px rgba(120, 10, 60, 0.35);
}
.btn-primary:hover {
  background-position: 90% 50%;
  box-shadow: var(--glow-r);
  filter: brightness(1.06) saturate(1.1);
  transform: translateY(-1px);
}
.btn-tonal { background: rgba(139, 92, 246, 0.1); color: var(--text); backdrop-filter: blur(8px); box-shadow: inset 0 0 0 1.5px rgba(139, 92, 246, 0.3); }
.btn-tonal:hover { background: rgba(139, 92, 246, 0.18); box-shadow: inset 0 0 0 1.5px rgba(139, 92, 246, 0.5), 0 4px 14px rgba(139, 92, 246, 0.2); }
.btn-outline { background: transparent; color: var(--text); box-shadow: inset 0 0 0 1px var(--line-2); }
.btn-outline:hover { background: var(--s2); box-shadow: inset 0 0 0 1px rgba(139, 92, 246, 0.4); }
.btn-white { background: #ffffff; color: #191d27; box-shadow: var(--glow-card); }
.btn-white:hover { background: #f2f4fa; box-shadow: 0 4px 18px rgba(23, 28, 48, 0.12); }
.btn-alipay { background: var(--alipay); color: #ffffff; }
.btn-alipay:hover { background: #2a7cf0; }
.btn-wechat { background: var(--wechat); color: #ffffff; }
.btn-wechat:hover { background: #058a45; }
.btn-sm { min-height: 40px; padding: 0 18px; font-size: 14.5px; }
.btn-lg { min-height: 56px; padding: 0 30px; font-size: 16.5px; }
.btn-block { width: 100%; }

/* ================= 主视觉 ================= */
.hero {
  position: relative;
  overflow: hidden;
  min-height: 560px;
  border-radius: var(--r-lg);
  background: #ffffff center / cover no-repeat;
  isolation: isolate;
  box-shadow: var(--glow-card);
}
/* 电路线条主装饰层：明显可见 + 飘带柔光 */
.hero::after {
  position: absolute;
  inset: 0;
  z-index: 0;
  content: "";
  background:
    var(--circuit-pattern),
    radial-gradient(760px 420px at 90% 6%, rgba(255, 45, 120, 0.16), transparent 62%),
    radial-gradient(680px 400px at 70% 55%, rgba(139, 92, 246, 0.14), transparent 62%),
    radial-gradient(600px 380px at 96% 92%, rgba(0, 200, 240, 0.12), transparent 60%),
    radial-gradient(520px 340px at 45% 108%, rgba(45, 127, 249, 0.1), transparent 60%);
  pointer-events: none;
}
/* 左侧文字可读性渐变（浅色版） */
.hero::before {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.96) 0%, rgba(255, 255, 255, 0.82) 38%, rgba(255, 255, 255, 0.15) 70%),
              linear-gradient(0deg, rgba(255, 255, 255, 0.7) 0%, rgba(255, 255, 255, 0) 40%);
  content: "";
  pointer-events: none;
}
/* 底部飘带波浪分隔 */
.hero .hero-wave {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -2px;
  z-index: 2;
  height: 90px;
  background: var(--ribbon-wave) bottom / 100% 100% no-repeat;
  pointer-events: none;
}
.hero-body { position: relative; z-index: 3; }
.hero-body { display: flex; flex-direction: column; justify-content: flex-end; min-height: 560px; max-width: 640px; padding: 56px; }
.live-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  align-self: flex-start;
  padding: 6px 14px 6px 10px;
  border-radius: 999px;
  background: rgba(255, 45, 85, 0.1);
  box-shadow: inset 0 0 0 1px rgba(255, 45, 120, 0.35);
  backdrop-filter: blur(10px);
  font-size: 14px;
  font-weight: 600;
}
.live-pill i { width: 8px; height: 8px; border-radius: 50%; background: var(--live); box-shadow: 0 0 0 4px rgba(255, 45, 85, 0.25), 0 0 12px rgba(255, 45, 120, 0.8); animation: pulse 2s infinite; }
@keyframes pulse { 50% { box-shadow: 0 0 0 7px rgba(255, 45, 85, 0.08), 0 0 16px rgba(255, 45, 120, 0.5); } }
.hero h1 { margin-top: 20px; font-size: clamp(38px, 5vw, 64px); font-weight: 700; line-height: 1.1; letter-spacing: -0.01em; }
/* hero 主标题关键词渐变（给需要强调的 span 用） */
.hero h1 .grad-text {
  background: var(--gradient-text);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}
.hero p.lead { margin-top: 18px; max-width: 520px; color: var(--text-2); font-size: 18px; line-height: 1.7; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.hero-meta { display: flex; flex-wrap: wrap; gap: 8px 22px; margin-top: 26px; color: var(--text-3); font-size: 14px; }
.hero-meta span { display: inline-flex; align-items: center; gap: 7px; }
.hero-meta svg { width: 16px; height: 16px; color: #0a9ec2; }

/* ================= 区块与内容行 ================= */
.block { margin-top: 64px; }
.block-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 20px; }
.block-head h2 { font-size: 26px; font-weight: 700; letter-spacing: 0.01em; }
.block-head p { margin-top: 6px; color: var(--text-3); font-size: 15px; }

.chips { display: flex; gap: 10px; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
.chips::-webkit-scrollbar { display: none; }
.chip {
  flex: none;
  padding: 9px 18px;
  border: 0;
  border-radius: 999px;
  background: var(--s2);
  color: var(--text-2);
  font-size: 14.5px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s, color 0.2s, box-shadow 0.2s;
}
.chip:hover { background: var(--s3); color: var(--text); }
.chip.on { background: var(--gradient-r); color: #ffffff; box-shadow: var(--glow-r-sm); }

.row { display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 3 * 18px) / 4); gap: 18px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; padding: 4px 2px 8px; margin: 0 -2px; }
.row::-webkit-scrollbar { display: none; }

.tile { scroll-snap-align: start; cursor: default; }
.tile-art {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  border-radius: var(--r);
  background: var(--s2) center / cover no-repeat;
  transition: transform 0.35s cubic-bezier(0.2, 0.8, 0.2, 1), box-shadow 0.35s;
}
.tile:hover .tile-art {
  transform: scale(1.03);
  box-shadow: 0 0 0 2px rgba(139, 92, 246, 0.7), 0 0 24px rgba(139, 92, 246, 0.35), 0 18px 40px rgba(0, 0, 0, 0.5);
}
.tile-art b { position: absolute; left: 18px; bottom: 14px; font-size: 22px; font-weight: 700; letter-spacing: 0.02em; color: #ffffff; text-shadow: 0 2px 12px rgba(20, 10, 40, 0.55); }
.tile-tag { position: absolute; top: 12px; left: 12px; padding: 3px 10px; border-radius: 999px; background: rgba(255, 255, 255, 0.85); backdrop-filter: blur(6px); font-size: 12.5px; font-weight: 600; color: #191d27; }
.tile-tag.live { background: linear-gradient(135deg, #ff2d55, #ff2d78); box-shadow: 0 2px 12px rgba(255, 45, 120, 0.5); }
.tile h3 { margin-top: 12px; font-size: 16px; font-weight: 600; }
.tile p { margin-top: 2px; color: var(--text-3); font-size: 14px; }

/* ================= 卡片 ================= */
.card { border-radius: var(--r-lg); background: var(--s1); box-shadow: var(--glow-card); border: 1px solid var(--line); }
.card-pad { padding: 32px; }

.device-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.device {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 28px;
  border-radius: var(--r-lg);
  background: var(--s1);
  transition: transform 0.3s, box-shadow 0.3s;
}
.device::before {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1.5px;
  background: var(--gradient-r);
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  opacity: 0;
  transition: opacity 0.3s;
  content: "";
  pointer-events: none;
}
.device:hover { transform: translateY(-4px); box-shadow: 0 16px 48px rgba(0, 0, 0, 0.45), 0 0 32px rgba(139, 92, 246, 0.18); }
.device:hover::before { opacity: 1; }
.device-icon {
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border-radius: 18px;
  background: var(--gradient-r-soft);
  box-shadow: inset 0 0 0 1px rgba(139, 92, 246, 0.3);
  color: var(--r-cyan);
}
.device-icon svg { width: 28px; height: 28px; }
.device h3 { margin-top: 6px; font-size: 20px; font-weight: 700; }
.device p { flex: 1; color: var(--text-2); font-size: 15px; }
.device .links { display: flex; flex-wrap: wrap; gap: 8px; }
.link-chip { display: inline-flex; align-items: center; gap: 6px; padding: 7px 14px; border-radius: 999px; background: var(--s3); color: var(--text); font-size: 14px; transition: background 0.2s, box-shadow 0.2s; }
.link-chip:hover { background: var(--s4); box-shadow: 0 0 12px rgba(139, 92, 246, 0.25); }
.link-chip small { color: var(--text-3); font-size: 12.5px; }

/* ================= 表单 ================= */
.field { display: grid; gap: 8px; margin-bottom: 18px; }
.label { color: var(--text-2); font-size: 14px; font-weight: 500; }
.input, .select {
  width: 100%;
  height: 52px;
  padding: 0 18px;
  border: 0;
  border-radius: var(--r-sm);
  background: var(--s3);
  color: var(--text);
  font-size: 16px;
  outline: none;
  box-shadow: inset 0 0 0 1px transparent;
  transition: box-shadow 0.2s, background 0.2s;
}
.input::placeholder { color: var(--text-3); }
.input:hover, .select:hover { background: var(--s4); }
.input:focus, .select:focus { background: var(--s3); box-shadow: inset 0 0 0 2px var(--r-purple), 0 0 16px rgba(139, 92, 246, 0.25); }
.input[readonly] { color: var(--text-2); font-family: var(--mono); font-size: 14px; }
.select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23b8bdcb' stroke-width='2'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 16px center; background-size: 20px; padding-right: 48px; }
.input-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; }

/* ================= 提示与徽标 ================= */
.alert-box, .note {
  display: none;
  margin-bottom: 18px;
  padding: 13px 16px;
  border-radius: var(--r-sm);
  font-size: 14.5px;
  line-height: 1.6;
}
.alert-box.success, .note.success { display: block; background: var(--ok-bg); color: var(--ok); }
.alert-box.error, .note.error { display: block; background: var(--bad-bg); color: var(--bad); }
.alert-box.warning, .note.warning { display: block; background: var(--warn-bg); color: var(--warn); }
.alert-box.info, .note.info { display: block; background: var(--info-bg); color: var(--primary); }

.badge { display: inline-flex; align-items: center; gap: 6px; padding: 4px 12px; border-radius: 999px; background: var(--s3); color: var(--text-2); font-size: 13px; font-weight: 600; white-space: nowrap; }
.badge.ok { background: var(--ok-bg); color: var(--ok); }
.badge.warn { background: var(--warn-bg); color: var(--warn); }
.badge.bad { background: var(--bad-bg); color: var(--bad); }
.badge.info { background: var(--info-bg); color: var(--primary); }

/* ================= 侧边面板（登录） ================= */
.scrim { position: fixed; inset: 0; z-index: 60; background: rgba(0, 0, 0, 0.6); opacity: 0; pointer-events: none; transition: opacity 0.25s; }
.sheet {
  position: fixed;
  top: 12px;
  right: 12px;
  bottom: 12px;
  z-index: 61;
  display: flex;
  flex-direction: column;
  width: min(460px, 100% - 24px);
  overflow-y: auto;
  padding: 28px 32px 32px;
  border-radius: var(--r-lg);
  background: var(--s1);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55);
  transform: translateX(calc(100% + 24px));
  visibility: hidden;
  transition: transform 0.35s cubic-bezier(0.2, 0.8, 0.2, 1), visibility 0s linear 0.35s;
}
/* 登录面板顶部渐变装饰条 */
.sheet::before {
  position: absolute;
  top: 0;
  left: 32px;
  right: 32px;
  height: 3px;
  border-radius: 0 0 4px 4px;
  background: var(--gradient-r);
  content: "";
}
.sheet-open .scrim { opacity: 1; pointer-events: auto; }
.sheet-open .sheet { transform: none; visibility: visible; transition: transform 0.35s cubic-bezier(0.2, 0.8, 0.2, 1), visibility 0s; }
.sheet-open { overflow: hidden; }
.sheet-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 26px; }
.icon-btn { display: grid; place-items: center; width: 42px; height: 42px; border: 0; border-radius: 50%; background: var(--s3); cursor: pointer; transition: background 0.2s; }
.icon-btn:hover { background: var(--s4); }
.icon-btn svg { width: 20px; height: 20px; }
.sheet h2 { font-size: 28px; font-weight: 700; }
.sheet .sub { margin: 8px 0 26px; color: var(--text-2); font-size: 15px; }
.fine { margin-top: 16px; color: var(--text-3); font-size: 13.5px; text-align: center; }
.fine a { color: var(--primary); }

.support { display: flex; align-items: center; gap: 16px; margin-top: auto; padding: 16px; border-radius: var(--r); background: var(--s2); }
.support img { flex: none; width: 76px; height: 76px; border-radius: 12px; background: #ffffff; object-fit: cover; }
.support h4 { font-size: 15.5px; font-weight: 600; }
.support p { margin-top: 2px; color: var(--text-3); font-size: 13.5px; }

/* ================= 页脚 ================= */
.footer { margin-top: 96px; padding: 40px 0 56px; border-top: 1px solid transparent; border-image: linear-gradient(90deg, transparent, rgba(139, 92, 246, 0.3), rgba(0, 212, 255, 0.3), transparent) 1; color: var(--text-3); font-size: 14px; }
.footer-inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px; }
.footer nav { display: flex; flex-wrap: wrap; gap: 24px; }
.footer a:hover { color: var(--text); }

/* ================= 响应式 ================= */
@media (max-width: 1100px) {
  .row { grid-auto-columns: calc((100% - 2 * 16px) / 3); gap: 16px; }
}

@media (max-width: 860px) {
  :root { --page: calc(100% - 32px); }
  .tabs { display: none; }
  .topbar-inner { height: 64px; }
  .hero, .hero-body { min-height: 600px; }
  .hero { background-size: cover; background-position: 78% 40%; }
  .hero-body { padding-top: 220px; }
  .hero::before { background: linear-gradient(0deg, rgba(255, 255, 255, 0.98) 0%, rgba(255, 255, 255, 0.88) 42%, rgba(255, 255, 255, 0.2) 72%, rgba(255, 255, 255, 0) 100%); }
  .hero-actions .btn { flex: 1 1 140px; }
  .hero-body { padding: 28px 24px; }
  .hero p.lead { font-size: 16px; }
  .block { margin-top: 48px; }
  .block-head h2 { font-size: 22px; }
  .row { grid-auto-columns: 72%; gap: 12px; }
  .device-grid { grid-template-columns: 1fr; }
  .card-pad { padding: 24px 20px; }
  .sheet { top: auto; left: 0; right: 0; bottom: 0; width: 100%; max-height: 92vh; padding: 22px 20px 28px; border-radius: var(--r-lg) var(--r-lg) 0 0; transform: translateY(100%); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}

/* 内容行左右翻页 */
.row-wrap { position: relative; }
.row-nav { position: absolute; top: calc(50% - 46px); z-index: 2; display: grid; place-items: center; width: 48px; height: 48px; border: 0; border-radius: 50%; background: rgba(30, 32, 42, 0.92); color: var(--text); box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45); cursor: pointer; opacity: 0; transition: opacity 0.2s, background 0.2s, box-shadow 0.2s; }
.row-nav:hover { background: var(--s4); box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45), 0 0 16px rgba(139, 92, 246, 0.3); }
.row-nav svg { width: 22px; height: 22px; }
.row-nav.prev { left: -18px; }
.row-nav.next { right: -18px; }
.row-wrap:hover .row-nav:not([disabled]) { opacity: 1; }
.row-nav[disabled] { opacity: 0 !important; pointer-events: none; }
@media (max-width: 860px), (hover: none) { .row-nav { display: none; } }

/* ================= 单卡片页面（登录、付款、扫码、状态） ================= */
.solo {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background:
    radial-gradient(900px 520px at 85% -10%, rgba(255, 45, 120, 0.14), transparent 60%),
    radial-gradient(800px 480px at 60% -5%, rgba(139, 92, 246, 0.16), transparent 60%),
    radial-gradient(700px 420px at 0% 110%, rgba(0, 212, 255, 0.08), transparent 60%),
    var(--bg);
}
.solo-top { display: flex; align-items: center; justify-content: space-between; gap: 16px; width: var(--page); height: 76px; margin: 0 auto; }
.solo-top a.link { color: var(--text-2); font-size: 15px; }
.solo-top a.link:hover { color: var(--text); }
.solo-main { flex: 1; display: grid; place-items: center; padding: 24px 16px 64px; }
.panel { width: min(480px, 100%); padding: 40px; border-radius: var(--r-lg); background: var(--s1); box-shadow: 0 30px 80px rgba(0, 0, 0, 0.35); position: relative; overflow: hidden; }
/* 面板顶部 R 渐变装饰条 */
.panel::before {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--gradient-r);
  content: "";
}
.panel.wide { width: min(720px, 100%); }
.panel h1 { font-size: 30px; font-weight: 700; line-height: 1.25; }
.panel .sub { margin: 10px 0 28px; color: var(--text-2); font-size: 15.5px; }
.panel .center { text-align: center; }
.panel-icon { display: grid; place-items: center; width: 64px; height: 64px; margin-bottom: 20px; border-radius: 22px; background: var(--s3); }
.panel-icon svg { width: 32px; height: 32px; }
.panel-icon.ok { background: var(--ok-bg); color: var(--ok); }
.panel-icon.warn { background: var(--warn-bg); color: var(--warn); }
.panel-icon.bad { background: var(--bad-bg); color: var(--bad); }
.panel-icon.info { background: var(--info-bg); color: var(--primary); }
.panel-foot { display: flex; justify-content: space-between; gap: 12px; margin-top: 28px; padding-top: 20px; border-top: 1px solid var(--line); color: var(--text-3); font-size: 14px; }
.panel-foot a { color: var(--primary); }

.kv { margin: 0 0 24px; padding: 6px 20px; border-radius: var(--r); background: var(--s2); }
.kv > div { display: flex; justify-content: space-between; gap: 16px; padding: 13px 0; border-bottom: 1px solid var(--line); font-size: 15px; }
.kv > div:last-child { border-bottom: 0; }
.kv dt { color: var(--text-3); }
.kv dd { margin: 0; text-align: right; font-weight: 600; overflow-wrap: anywhere; }
.kv dd.mono { font-family: var(--mono); font-size: 13.5px; font-weight: 500; }

.amount { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 20px; }
.amount span { color: var(--text-2); font-size: 15px; }
.amount b { font-size: 40px; font-weight: 700; letter-spacing: -0.02em; background: var(--gradient-text); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent; }

.seg { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; margin-bottom: 26px; padding: 4px; border-radius: 999px; background: var(--s2); }
.seg button { min-height: 42px; border: 0; border-radius: 999px; background: transparent; color: var(--text-2); font-size: 15px; font-weight: 600; cursor: pointer; transition: background 0.2s, color 0.2s, box-shadow 0.2s; }
.seg button.active { background: var(--gradient-r); color: #ffffff; box-shadow: var(--glow-r-sm); }

.flash-error, .flash-success { display: flex; align-items: center; gap: 10px; margin-bottom: 18px; padding: 13px 16px; border-radius: var(--r-sm); font-size: 14.5px; }
.flash-error { background: var(--bad-bg); color: var(--bad); }
.flash-success { background: var(--ok-bg); color: var(--ok); }
.flash-error svg, .flash-success svg { flex: none; width: 18px; height: 18px; }

.spin { flex: none; width: 18px; height: 18px; border: 2px solid rgba(139, 92, 246, 0.25); border-top-color: var(--r-purple); border-radius: 50%; animation: spin 0.8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.wait { display: flex; align-items: center; gap: 12px; margin-bottom: 20px; padding: 14px 16px; border-radius: var(--r-sm); background: var(--info-bg); color: var(--primary); font-size: 14.5px; }
.wait.ok { background: var(--ok-bg); color: var(--ok); }
.wait.bad { background: var(--bad-bg); color: var(--bad); }

.qr { width: min(260px, 100%); margin: 0 auto 14px; padding: 14px; border-radius: var(--r); background: #ffffff; box-shadow: 0 0 0 1px rgba(139, 92, 246, 0.25), 0 0 32px rgba(139, 92, 246, 0.2); }
.qr svg { display: block; width: 100%; height: auto; }
.btn-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

@media (max-width: 560px) {
  .panel { padding: 28px 22px; border-radius: 24px; }
  .panel h1 { font-size: 26px; }
  .solo-top { height: 64px; }
  .btn-pair { grid-template-columns: 1fr; }
}

/* ============================================================
 * 深色主题（用户手动切换）
 * 用法：<html data-theme="dark">
 * 保留全部 R logo 视觉语言：四色渐变、电路纹、飘带波浪、发光
 * ============================================================ */
[data-theme="dark"] {
  color-scheme: dark;
  /* ---- 深色基底 ---- */
  --bg: #0e1013;
  --s1: #16181c;
  --s2: #1d2025;
  --s3: #262a30;
  --s4: #30353c;
  --line: rgba(255, 255, 255, 0.08);
  --line-2: rgba(255, 255, 255, 0.14);
  --text: #eceef1;
  --text-2: #b4bac3;
  --text-3: #949ba6;
  /* ---- 状态色（深色版） ---- */
  --ok: #6dd58c;
  --ok-bg: rgba(109, 213, 140, 0.12);
  --warn: #ffc56b;
  --warn-bg: rgba(255, 197, 107, 0.12);
  --bad: #ff8a80;
  --bad-bg: rgba(255, 138, 128, 0.12);
  --info-bg: rgba(139, 92, 246, 0.14);
  --glow-card: 0 2px 6px rgba(0, 0, 0, 0.4), 0 12px 32px rgba(0, 0, 0, 0.35);
}

/* 深色：body 飘带柔光增强 */
[data-theme="dark"] body {
  background-image:
    radial-gradient(1100px 520px at 108% -8%, rgba(255, 45, 120, 0.14), transparent 62%),
    radial-gradient(960px 500px at -12% 28%, rgba(45, 127, 249, 0.15), transparent 62%),
    radial-gradient(900px 460px at 50% 112%, rgba(0, 200, 240, 0.12), transparent 62%),
    radial-gradient(700px 380px at 85% 65%, rgba(139, 92, 246, 0.1), transparent 60%);
}

/* 深色：顶栏 */
[data-theme="dark"] .topbar {
  background: linear-gradient(180deg, rgba(14, 16, 19, 0.94) 0%, rgba(14, 16, 19, 0.82) 100%);
}

/* 深色：hero 左侧可读性渐变 */
[data-theme="dark"] .hero::before {
  background: linear-gradient(90deg, rgba(14, 16, 19, 0.96) 0%, rgba(14, 16, 19, 0.82) 38%, rgba(14, 16, 19, 0.15) 70%),
              linear-gradient(0deg, rgba(14, 16, 19, 0.7) 0%, rgba(14, 16, 19, 0) 40%);
}

/* 深色：hero 电路装饰增强 */
[data-theme="dark"] .hero::after {
  background:
    var(--circuit-pattern),
    radial-gradient(760px 420px at 90% 6%, rgba(255, 45, 120, 0.22), transparent 62%),
    radial-gradient(680px 400px at 70% 55%, rgba(139, 92, 246, 0.2), transparent 62%),
    radial-gradient(600px 380px at 96% 92%, rgba(0, 200, 240, 0.16), transparent 60%),
    radial-gradient(520px 340px at 45% 108%, rgba(45, 127, 249, 0.14), transparent 60%);
}

/* 深色：tile 标签 */
[data-theme="dark"] .tile-tag {
  background: rgba(22, 24, 28, 0.85);
  color: var(--text);
}

/* 深色：移动端 hero 渐变 */
@media (max-width: 720px) {
  [data-theme="dark"] .hero::before {
    background: linear-gradient(0deg, rgba(14, 16, 19, 0.98) 0%, rgba(14, 16, 19, 0.88) 42%, rgba(14, 16, 19, 0.2) 72%, rgba(14, 16, 19, 0) 100%);
  }
}

/* ============ 主题切换过渡 ============ */
html.theme-anim,
html.theme-anim *,
html.theme-anim *::before,
html.theme-anim *::after {
  transition: background-color 0.3s ease, color 0.3s ease,
              border-color 0.3s ease, box-shadow 0.3s ease !important;
}

/* ============ 主题切换按钮 ============ */
.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  padding: 0;
  border-radius: 999px;
  cursor: pointer;
  background: transparent;
  border: 1px solid var(--line-2);
  color: var(--text-2);
}
.theme-toggle:hover {
  border-color: var(--r-purple);
  color: var(--r-purple);
  box-shadow: 0 0 12px rgba(139, 92, 246, 0.3);
}
.theme-toggle svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.theme-toggle .icon-sun { display: none; }
.theme-toggle .icon-moon { display: block; }
[data-theme="dark"] .theme-toggle .icon-sun { display: block; }
[data-theme="dark"] .theme-toggle .icon-moon { display: none; }

/* === release徽章 R渐变风 (2026-10-06) === */
.release-tags .badge {
  background: linear-gradient(135deg, rgba(255,45,120,.12), rgba(139,92,246,.12), rgba(45,127,249,.12));
  border: 1px solid rgba(139,92,246,.25);
  color: #6d5bd0;
  font-weight: 700;
}
.release-tags .badge.info {
  background: linear-gradient(135deg, #ff2d78, #8b5cf6, #2d7ff9);
  color: #fff;
  border: none;
  box-shadow: 0 2px 12px rgba(139,92,246,.35);
}
[data-theme="dark"] .release-tags .badge {
  background: linear-gradient(135deg, rgba(255,45,120,.18), rgba(139,92,246,.18), rgba(45,127,249,.18));
  border-color: rgba(139,92,246,.4);
  color: #c4b5fd;
}
