:root {
  /* 浅色主题默认值 */
  --bg: #f5f6fb;
  --bg-elevated: #ffffff;
  --bg-soft: #eef0f8;
  --border-subtle: rgba(15, 23, 42, 0.08);
  --accent: #3756c8;
  --accent-soft: rgba(55, 86, 200, 0.1);
  --text-main: #111827;
  --text-muted: #6b7280;
  --text-soft: #4b5563;
  --shadow-soft: 0 16px 40px rgba(15, 23, 42, 0.12);
  --radius-lg: 20px;
  --radius-md: 14px;
  --radius-pill: 999px;
}

body[data-theme="dark"] {
  --bg: #050608;
  --bg-elevated: #10111a;
  --bg-soft: #141521;
  --border-subtle: rgba(255, 255, 255, 0.08);
  --accent: #5f8bff;
  --accent-soft: rgba(95, 139, 255, 0.18);
  --text-main: #f5f6fb;
  --text-muted: #a0a3b5;
  --text-soft: #6f7385;
  --shadow-soft: 0 18px 45px rgba(0, 0, 0, 0.65);
}

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

html,
body {
  margin: 0;
  padding: 0;
}

body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Inter", "Segoe UI",
    sans-serif;
  background: radial-gradient(circle at top, #e5e7ff, var(--bg) 55%);
  color: var(--text-main);
  -webkit-font-smoothing: antialiased;
}

body[data-theme="dark"] {
  background: radial-gradient(circle at top, #0f172a, var(--bg) 55%);
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
textarea {
  font-family: inherit;
}

.container {
  width: min(1120px, 100% - 40px);
  margin-inline: auto;
}

.section {
  padding: 72px 0;
}

.section-border {
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.01), transparent);
}

.section-alt {
  background: radial-gradient(circle at top left, rgba(148, 163, 253, 0.18), transparent 60%),
    radial-gradient(circle at bottom right, rgba(45, 212, 191, 0.16), transparent 60%);
}

.section-heading {
  margin-bottom: 32px;
}

.section-heading h2 {
  margin: 0 0 8px;
  font-size: 26px;
}

.section-heading p {
  margin: 0;
  color: var(--text-muted);
  font-size: 14px;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(18px);
  background:
    linear-gradient(180deg, rgba(248, 250, 252, 0.94), rgba(241, 245, 249, 0.94));
  border-bottom: 1px solid rgba(15, 23, 42, 0.06);
}

body[data-theme="dark"] .site-header {
  background:
    linear-gradient(180deg, rgba(10, 10, 20, 0.9), rgba(10, 10, 20, 0.86)),
    radial-gradient(circle at top, rgba(129, 140, 248, 0.36), transparent 60%);
  border-bottom-color: rgba(255, 255, 255, 0.06);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.logo-visual {
  width: 32px;
  height: 32px;
  border-radius: 12px;
  background: radial-gradient(circle at 20% 0, #e5edff, #5f8bff);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.logo-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.logo-text-wrap {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.logo-title {
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.logo-subtitle {
  font-size: 11px;
  color: var(--text-soft);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.back-home {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid rgba(15, 23, 42, 0.12);
  font-size: 13px;
  color: var(--text-main);
  background: rgba(248, 250, 252, 0.96);
  text-decoration: none;
}

body[data-theme="dark"] .back-home {
  background: rgba(15, 23, 42, 0.85);
  border-color: rgba(255, 255, 255, 0.3);
}

.back-home:hover {
  transform: translateY(-1px);
  background: rgba(15, 23, 42, 0.1);
}

body[data-theme="dark"] .back-home:hover {
  background: rgba(15, 23, 42, 1);
}

.icon-button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-radius: 999px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: rgba(255, 255, 255, 0.9);
  color: var(--text-main);
  padding: 4px 10px 4px 6px;
  font-size: 12px;
  cursor: pointer;
  transition: background 0.16s ease-out, border-color 0.16s ease-out,
    transform 0.12s ease-out;
}

body[data-theme="dark"] .icon-button {
  background: rgba(15, 23, 42, 0.6);
  border-color: rgba(255, 255, 255, 0.14);
}

.icon-button:hover {
  transform: translateY(-1px);
  background: rgba(255, 255, 255, 1);
}

body[data-theme="dark"] .icon-button:hover {
  background: rgba(15, 23, 42, 0.8);
}

.icon-gear {
  width: 18px;
  height: 18px;
  border-radius: 999px;
  border: 1px solid rgba(15, 23, 42, 0.6);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

body[data-theme="dark"] .icon-gear {
  border-color: rgba(255, 255, 255, 0.4);
}

.icon-gear::before,
.icon-gear::after {
  content: "";
  position: absolute;
  inset: 4px;
  border-radius: inherit;
  border: 1px solid rgba(15, 23, 42, 0.6);
}

body[data-theme="dark"] .icon-gear::before,
body[data-theme="dark"] .icon-gear::after {
  border-color: rgba(255, 255, 255, 0.4);
}

.icon-gear::after {
  inset: 7px;
}

.settings-text {
  display: inline-block;
}

@media (max-width: 520px) {
  .settings-text {
    display: none;
  }
}

.settings-panel {
  display: none;
  border-top: 1px solid rgba(15, 23, 42, 0.06);
  background: rgba(248, 250, 252, 0.98);
  padding: 10px 0 12px;
}

body[data-theme="dark"] .settings-panel {
  background: rgba(8, 9, 16, 0.96);
  border-top-color: rgba(255, 255, 255, 0.06);
}

.settings-panel.open {
  display: block;
}

.settings-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-inline: calc((100vw - min(1120px, 100% - 40px)) / 2 + 20px);
  font-size: 13px;
}

.settings-label {
  color: var(--text-soft);
}

.settings-options {
  display: inline-flex;
  gap: 8px;
}

.settings-option {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid rgba(15, 23, 42, 0.12);
  cursor: pointer;
}

body[data-theme="dark"] .settings-option {
  border-color: rgba(255, 255, 255, 0.12);
}

.settings-option input {
  appearance: none;
  width: 10px;
  height: 10px;
  border-radius: 999px;
  border: 1px solid rgba(15, 23, 42, 0.6);
  position: relative;
}

body[data-theme="dark"] .settings-option input {
  border-color: rgba(255, 255, 255, 0.7);
}

.settings-option input::after {
  content: "";
  position: absolute;
  inset: 2px;
  border-radius: inherit;
  background: transparent;
}

.settings-option input:checked::after {
  background: var(--accent);
}

.settings-option span {
  font-size: 12px;
}

.hero {
  padding: 72px 0 64px;
}

.hero-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1.1fr);
  gap: 40px;
  align-items: center;
}

.hero-simple {
  max-width: 640px;
}

@media (max-width: 880px) {
  .hero-inner {
    grid-template-columns: 1fr;
  }
}

.eyebrow {
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-soft);
}

.hero-main h1 {
  margin: 10px 0 12px;
  font-size: clamp(30px, 4vw, 38px);
  line-height: 1.14;
}

.hero-intro {
  margin: 0 0 10px;
  font-size: 14px;
  color: var(--text-muted);
}

body[data-theme="dark"] .hero-intro {
  color: var(--text-main);
}

.hero-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.home-actions {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 10px;
  margin-top: 18px;
  max-width: 280px;
}

.home-btn {
  border-radius: 999px;
  border: 1px solid rgba(15, 23, 42, 0.12);
  padding: 10px 18px;
  font-size: 14px;
  background: rgba(248, 250, 252, 0.96);
  color: var(--text-main);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  transition: background 0.16s ease-out, border-color 0.16s ease-out,
    transform 0.12s ease-out;
}

body[data-theme="dark"] .home-btn {
  background: rgba(15, 23, 42, 0.7);
  border-color: rgba(255, 255, 255, 0.18);
}

.home-btn:hover {
  transform: translateY(-1px);
  background: rgba(255, 255, 255, 1);
}

body[data-theme="dark"] .home-btn:hover {
  background: rgba(15, 23, 42, 0.9);
}

.home-btn.primary {
  border-color: transparent;
  background: linear-gradient(135deg, #5f8bff, #9f7bff);
  box-shadow: 0 12px 26px rgba(95, 139, 255, 0.45);
  color: #f9fafb;
}

body[data-theme="dark"] .home-btn.primary {
  color: #f9fafb;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 38px;
  padding: 0 16px;
  border-radius: var(--radius-pill);
  border: 1px solid transparent;
  font-size: 13px;
  cursor: pointer;
  transition: all 0.16s ease-out;
  background: transparent;
  color: var(--text-main);
}

.btn.primary {
  background: linear-gradient(135deg, #5f8bff, #9f7bff);
  box-shadow: 0 12px 30px rgba(95, 139, 255, 0.4);
}

.btn.primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 16px 38px rgba(95, 139, 255, 0.55);
}

.btn.ghost {
  border-color: rgba(15, 23, 42, 0.12);
  background: rgba(248, 250, 252, 0.9);
}

body[data-theme="dark"] .btn.ghost {
  border-color: rgba(255, 255, 255, 0.16);
  background: rgba(15, 23, 42, 0.5);
}

.btn.ghost:hover {
  background: rgba(255, 255, 255, 1);
}

body[data-theme="dark"] .btn.ghost:hover {
  background: rgba(15, 23, 42, 0.8);
}

.btn.full-width {
  width: 100%;
}

.hero-side {
  display: flex;
  justify-content: flex-end;
}

.hero-card {
  width: 100%;
  max-width: 340px;
  padding: 18px 18px 16px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-subtle);
  background:
    radial-gradient(circle at top left, rgba(129, 140, 248, 0.2), transparent 60%),
    var(--bg-elevated);
  box-shadow: var(--shadow-soft);
}

body[data-theme="dark"] .hero-card {
  background:
    radial-gradient(circle at top left, rgba(95, 139, 255, 0.24), transparent 60%),
    radial-gradient(circle at bottom right, rgba(34, 211, 238, 0.18), transparent 60%),
    var(--bg-elevated);
}

.hero-card-title {
  margin: 0 0 10px;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--text-soft);
}

.hero-meta {
  list-style: none;
  margin: 0 0 10px;
  padding: 0;
  display: grid;
  gap: 6px;
  font-size: 13px;
}

.meta-label {
  color: var(--text-soft);
}

.meta-value {
  color: var(--text-main);
}

.hero-meta li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.hero-note {
  margin: 8px 0 0;
  font-size: 11px;
  color: var(--text-soft);
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

@media (max-width: 900px) {
  .feature-grid {
    grid-template-columns: 1fr;
  }
}

.feature-card {
  position: relative;
  padding: 18px 16px 16px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  background: var(--bg-elevated);
  color: var(--text-main);
  box-shadow: 0 14px 30px rgba(15, 23, 42, 0.12);
  overflow: hidden;
  transition: transform 0.14s ease-out, box-shadow 0.14s ease-out,
    border-color 0.14s ease-out;
}

body[data-theme="dark"] .feature-card {
  box-shadow: 0 14px 35px rgba(0, 0, 0, 0.5);
}

.feature-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at top left, var(--accent-soft), transparent 60%);
  opacity: 0;
  transition: opacity 0.18s ease-out;
}

.feature-card:hover {
  transform: translateY(-3px);
  border-color: rgba(95, 139, 255, 0.6);
  box-shadow: 0 20px 40px rgba(15, 23, 42, 0.18);
}

body[data-theme="dark"] .feature-card:hover {
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.7);
}

.feature-card:hover::after {
  opacity: 1;
}

.feature-card > * {
  position: relative;
  z-index: 1;
}

.feature-tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 2px 8px;
  border-radius: 999px;
  border: 1px solid rgba(15, 23, 42, 0.3);
  font-size: 11px;
  color: var(--text-soft);
  margin-bottom: 8px;
}

body[data-theme="dark"] .feature-tag {
  border-color: rgba(255, 255, 255, 0.3);
}

.feature-card h3 {
  margin: 0 0 8px;
  font-size: 16px;
}

.feature-card p {
  margin: 0 0 10px;
  font-size: 13px;
  color: var(--text-muted);
}

.feature-link {
  font-size: 12px;
  color: var(--accent);
}

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

@media (max-width: 880px) {
  .placeholder-grid {
    grid-template-columns: 1fr;
  }
}

.block-card {
  padding: 16px 16px 14px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  background: var(--bg-elevated);
}

.block-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 8px;
}

.block-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--text-soft);
}

.block-title {
  font-size: 13px;
  font-weight: 500;
}

.block-desc {
  margin: 0 0 10px;
  font-size: 13px;
  color: var(--text-muted);
}

.block-footer {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.pill {
  padding: 3px 9px;
  border-radius: 999px;
  background: rgba(241, 245, 249, 0.9);
  color: var(--text-soft);
  font-size: 11px;
}

body[data-theme="dark"] .pill {
  background: rgba(15, 23, 42, 0.7);
}

.messages-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1.2fr);
  gap: 28px;
  align-items: start;
}

@media (max-width: 900px) {
  .messages-inner {
    grid-template-columns: 1fr;
  }
}

.messages-intro {
  margin: 12px 0 0;
  font-size: 14px;
  color: var(--text-muted);
}

.messages-layout {
  display: grid;
  grid-template-rows: auto auto;
  gap: 12px;
}

.message-list {
  padding: 14px 14px 10px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  background: var(--bg-elevated);
}

.message-item + .message-item {
  border-top: 1px dashed rgba(15, 23, 42, 0.12);
  margin-top: 8px;
  padding-top: 8px;
}

body[data-theme="dark"] .message-item + .message-item {
  border-top-color: rgba(255, 255, 255, 0.18);
}

.message-content {
  margin: 0 0 6px;
  font-size: 13px;
  color: var(--text-main);
}

.message-meta {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  font-size: 11px;
  color: var(--text-soft);
}

.message-form {
  padding: 14px 14px 12px;
  border-radius: var(--radius-md);
  border: 1px dashed rgba(15, 23, 42, 0.18);
  background: rgba(248, 250, 252, 0.96);
}

body[data-theme="dark"] .message-form {
  border-color: rgba(255, 255, 255, 0.26);
  background: rgba(15, 23, 42, 0.7);
}

.form-row {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 10px;
}

.form-row label {
  font-size: 12px;
  color: var(--text-muted);
}

.form-row input,
.form-row textarea {
  border-radius: 10px;
  border: 1px solid rgba(148, 163, 184, 0.7);
  background: rgba(255, 255, 255, 0.96);
  padding: 7px 10px;
  font-size: 13px;
  color: var(--text-main);
  outline: none;
  transition: border-color 0.16s ease-out, box-shadow 0.16s ease-out,
    background 0.16s ease-out;
}

body[data-theme="dark"] .form-row input,
body[data-theme="dark"] .form-row textarea {
  border-color: rgba(255, 255, 255, 0.2);
  background: rgba(15, 23, 42, 0.8);
}

.form-row input::placeholder,
.form-row textarea::placeholder {
  color: rgba(148, 163, 184, 0.7);
}

body[data-theme="dark"] .form-row input::placeholder,
body[data-theme="dark"] .form-row textarea::placeholder {
  color: rgba(148, 163, 184, 0.7);
}

.form-row input:focus,
.form-row textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 1px rgba(95, 139, 255, 0.4);
  background: rgba(255, 255, 255, 1);
}

body[data-theme="dark"] .form-row input:focus,
body[data-theme="dark"] .form-row textarea:focus {
  background: rgba(15, 23, 42, 0.96);
}

.miniapps-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

@media (max-width: 900px) {
  .miniapps-grid {
    grid-template-columns: 1fr;
  }
}

.mini-card {
  padding: 16px 16px 12px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  background: var(--bg-elevated);
}

.mini-card h3 {
  margin: 0 0 8px;
  font-size: 15px;
}

.mini-card p {
  margin: 0 0 8px;
  font-size: 13px;
  color: var(--text-muted);
}

.mini-status {
  font-size: 11px;
  color: var(--text-soft);
}

.mini-timer .timer-display {
  margin: 6px 0 10px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono",
    "Courier New", monospace;
  font-size: 20px;
  letter-spacing: 0.16em;
  color: var(--text-main);
}

.timer-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 8px;
}

.timer-btn {
  height: 30px;
  padding: 0 12px;
  font-size: 12px;
}

.site-footer {
  border-top: 1px solid rgba(15, 23, 42, 0.08);
  padding: 18px 0 22px;
  font-size: 12px;
  color: var(--text-soft);
  background: linear-gradient(180deg, #f9fafb, #e5e7eb);
}

body[data-theme="dark"] .site-footer {
  background: radial-gradient(circle at top center, rgba(15, 23, 42, 0.8), #020617);
  border-top-color: rgba(255, 255, 255, 0.08);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

@media (max-width: 640px) {
  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
  }
}

.footer-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.footer-title {
  font-weight: 500;
}

.footer-desc {
  color: var(--text-soft);
}