:root {
  --bg: #eef2f7;
  --surface: rgba(255, 255, 255, 0.72);
  --surface-strong: rgba(255, 255, 255, 0.92);
  --line: rgba(148, 163, 184, 0.22);
  --text: #0f172a;
  --muted: #5b6475;
  --accent: #0a84ff;
  --accent-soft: rgba(10, 132, 255, 0.14);
  --green-soft: rgba(16, 185, 129, 0.14);
  --shadow: 0 28px 60px rgba(15, 23, 42, 0.12);
  --radius-xl: 32px;
  --radius-lg: 24px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "SF Pro Display", "PingFang SC", "Helvetica Neue", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(10, 132, 255, 0.18), transparent 30%),
    radial-gradient(circle at top right, rgba(110, 231, 183, 0.16), transparent 26%),
    linear-gradient(180deg, #f6f9fd 0%, #eaf0f7 48%, #eef2f7 100%);
}

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

.inline-link {
  color: var(--accent);
}

[hidden] {
  display: none !important;
}

button,
input,
select,
textarea {
  font: inherit;
}

.page-shell {
  width: min(1240px, calc(100% - 32px));
  margin: 24px auto 48px;
}

.hero,
.section,
.tool-card,
.glass-card {
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

.hero {
  padding: 28px;
  border-radius: 40px;
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.72), rgba(255, 255, 255, 0.5));
  box-shadow: var(--shadow);
  overflow: hidden;
}

.hero-nav,
.hero-body,
.action-row,
.tool-head,
.inline-fields {
  display: flex;
  align-items: center;
}

.hero-nav,
.hero-body,
.scenario-grid,
.tool-grid,
.action-grid,
.privacy-grid {
  gap: 18px;
}

.hero-nav {
  justify-content: space-between;
  margin-bottom: 40px;
}

.brand-lockup {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
}

.brand-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: linear-gradient(180deg, #37c9ff, #0a84ff);
  box-shadow: 0 0 18px rgba(10, 132, 255, 0.42);
}

.brand-name {
  font-weight: 600;
  letter-spacing: 0.02em;
}

.hero-links {
  display: inline-flex;
  gap: 18px;
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.5);
  color: var(--muted);
}

.hero-links a:hover {
  color: var(--text);
}

.hero-body {
  justify-content: space-between;
  align-items: stretch;
}

.hero-copy,
.hero-panel {
  flex: 1;
}

.hero-copy {
  max-width: 620px;
  padding: 12px 4px 12px 2px;
}

.eyebrow,
.section-kicker,
.pill {
  display: inline-flex;
  align-items: center;
  padding: 8px 12px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 13px;
  font-weight: 600;
}

.hero-copy h1 {
  margin: 16px 0 14px;
  font-size: clamp(42px, 5vw, 72px);
  line-height: 1.02;
  letter-spacing: -0.05em;
}

.hero-copy p,
.tool-card p,
.glass-card p {
  color: var(--muted);
  line-height: 1.72;
  font-size: 16px;
}

.hero-actions {
  display: flex;
  gap: 12px;
  margin-top: 28px;
}

.button {
  border: 0;
  border-radius: 999px;
  padding: 14px 22px;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.button:hover {
  transform: translateY(-1px);
}

.button-primary {
  background: linear-gradient(180deg, #2b95ff, #0a84ff);
  color: #fff;
  box-shadow: 0 16px 28px rgba(10, 132, 255, 0.26);
}

.button-secondary {
  background: rgba(255, 255, 255, 0.84);
  color: var(--text);
  border: 1px solid rgba(148, 163, 184, 0.18);
}

.hero-panel {
  display: flex;
  justify-content: center;
  align-items: center;
  flex: 1.12;
}

.motion-scene {
  position: relative;
  width: min(100%, 620px);
  min-height: 540px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.hero-demo-shell {
  position: relative;
  z-index: 1;
  width: min(100%, 604px);
  padding: 10px;
  border-radius: 38px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.88), rgba(244, 248, 255, 0.62));
  border: 1px solid rgba(255, 255, 255, 0.82);
  box-shadow: 0 28px 54px rgba(15, 23, 42, 0.14);
}

.hero-demo-video {
  width: 100%;
  display: block;
  border: 0;
  border-radius: 30px;
  background: #eaf1fb;
  box-shadow: inset 0 0 0 1px rgba(148, 163, 184, 0.18);
  aspect-ratio: 960 / 820;
  object-fit: cover;
}

.motion-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(12px);
  animation: float 8s ease-in-out infinite;
}

.motion-orb-a {
  width: 180px;
  height: 180px;
  top: 24px;
  left: 30px;
  background: rgba(10, 132, 255, 0.18);
}

.motion-orb-b {
  width: 120px;
  height: 120px;
  right: 30px;
  top: 52px;
  background: rgba(16, 185, 129, 0.18);
  animation-duration: 7s;
}

.motion-orb-c {
  width: 140px;
  height: 140px;
  right: 60px;
  bottom: 30px;
  background: rgba(139, 92, 246, 0.14);
  animation-duration: 9s;
}

.device-card {
  position: relative;
  z-index: 1;
  width: min(100%, 460px);
  padding: 22px;
  border-radius: 34px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.88), rgba(244, 248, 255, 0.6));
  border: 1px solid rgba(255, 255, 255, 0.8);
  overflow: hidden;
  box-shadow: 0 22px 40px rgba(15, 23, 42, 0.12);
}

.device-header {
  display: flex;
  gap: 8px;
  margin-bottom: 22px;
}

.device-header span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(148, 163, 184, 0.3);
}

.metric strong {
  display: block;
  font-size: 52px;
  letter-spacing: -0.04em;
}

.metric span,
.metric-list {
  color: var(--muted);
}

.metric-list {
  display: grid;
  gap: 10px;
  margin-top: 22px;
}

.float-card {
  padding: 14px 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.86);
  animation: float 6s ease-in-out infinite;
}

.float-fast {
  animation-duration: 5.5s;
}

.float-mid {
  animation-duration: 6.8s;
}

.float-slow {
  animation-duration: 8s;
}

.ps-entry-card {
  margin: 16px 0 8px;
  padding: 18px 18px 16px;
  border-radius: 22px;
  background: rgba(240, 246, 255, 0.82);
  border: 1px solid rgba(148, 163, 184, 0.16);
}

.ps-entry-card h4 {
  margin: 0 0 8px;
  font-size: 18px;
  letter-spacing: -0.02em;
}

.ps-entry-card p {
  margin: 0;
}

.section {
  margin-top: 24px;
  padding: 32px 28px;
  border-radius: 34px;
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.68), rgba(255, 255, 255, 0.5));
  box-shadow: var(--shadow);
}

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

.section-heading h2 {
  margin: 14px 0 0;
  font-size: clamp(30px, 4vw, 48px);
  letter-spacing: -0.04em;
}

.scenario-grid,
.privacy-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.privacy-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.ps-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.glass-card,
.tool-card {
  border-radius: var(--radius-xl);
  border: 1px solid rgba(255, 255, 255, 0.72);
  background: var(--surface);
  box-shadow: 0 18px 35px rgba(15, 23, 42, 0.08);
}

.glass-card {
  padding: 22px;
}

.glass-card h3,
.tool-card h3 {
  margin: 0 0 8px;
  font-size: 22px;
  letter-spacing: -0.03em;
}

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

.tool-card {
  padding: 24px;
}

.tool-card-wide {
  grid-column: 1 / -1;
}

.tool-head {
  justify-content: space-between;
  margin-bottom: 10px;
}

.image-mode-tabs {
  display: inline-flex;
  gap: 10px;
  padding: 8px;
  border-radius: 999px;
  background: rgba(240, 246, 255, 0.9);
  margin-bottom: 16px;
}

.mode-tab {
  border: 0;
  background: transparent;
  color: var(--muted);
  border-radius: 999px;
  padding: 10px 16px;
  font-weight: 600;
}

.mode-tab.is-active {
  background: #fff;
  color: var(--text);
  box-shadow: 0 10px 20px rgba(15, 23, 42, 0.08);
}

button:disabled {
  opacity: 0.52;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.stack,
.preview-card {
  display: grid;
  gap: 12px;
}

.control-panel {
  padding: 16px 18px;
  border-radius: 22px;
  border: 1px solid rgba(148, 163, 184, 0.16);
  background: rgba(255, 255, 255, 0.78);
}

.control-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.control-label,
.control-value {
  font-size: 14px;
  font-weight: 600;
}

.control-value {
  color: var(--accent);
}

.control-panel input[type="range"] {
  width: 100%;
}

.control-hint {
  margin: 10px 0 0;
  font-size: 13px;
  color: var(--muted);
  line-height: 1.6;
}

textarea,
input[type="text"],
input[type="password"],
input[type="file"],
select {
  width: 100%;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.9);
  padding: 14px 16px;
  color: var(--text);
}

textarea {
  min-height: 180px;
  resize: vertical;
}

.action-row,
.action-grid {
  margin-top: 14px;
}

.action-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.result-panel,
.table-wrap,
.download-list,
.preview-card {
  margin-top: 16px;
  border-radius: 22px;
  border: 1px solid rgba(148, 163, 184, 0.16);
  background: rgba(248, 251, 255, 0.9);
}

.result-panel {
  min-height: 180px;
  padding: 18px;
  white-space: pre-wrap;
  line-height: 1.7;
  overflow: auto;
}

.table-wrap {
  overflow: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th,
td {
  padding: 12px 14px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.14);
  text-align: left;
}

th {
  background: rgba(15, 23, 42, 0.92);
  color: #fff;
  position: sticky;
  top: 0;
}

.download-list {
  padding: 14px;
  display: grid;
  gap: 10px;
}

.download-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.92);
}

.download-meta {
  min-width: 0;
}

.download-title {
  font-weight: 600;
}

.download-name {
  margin-top: 4px;
  color: var(--muted);
  word-break: break-all;
}

.download-button {
  border: 0;
  border-radius: 999px;
  padding: 12px 18px;
  background: linear-gradient(180deg, #2b95ff, #0a84ff);
  color: #fff;
  cursor: pointer;
  white-space: nowrap;
}

.preview-card {
  padding: 14px;
}

.ocr-result-card {
  margin-top: 16px;
  padding: 18px;
  border-radius: 22px;
  border: 1px solid rgba(148, 163, 184, 0.16);
  background: rgba(248, 251, 255, 0.9);
}

.ocr-result-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.ocr-result-summary {
  margin-top: 6px;
  color: var(--muted);
  font-size: 14px;
}

.ocr-result-textarea {
  width: 100%;
  min-height: 220px;
  margin-top: 14px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.94);
  padding: 14px 16px;
  color: var(--text);
  line-height: 1.7;
  resize: vertical;
}

.ocr-action-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 14px;
}

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

.preview-pane {
  display: grid;
  gap: 10px;
}

.preview-label {
  font-size: 14px;
  font-weight: 600;
  color: var(--muted);
}

.preview-stage {
  min-height: 220px;
  padding: 14px;
  border-radius: 18px;
  background: #fff;
  border: 1px solid rgba(148, 163, 184, 0.14);
  display: flex;
  align-items: center;
  justify-content: center;
}

.preview-stage.checkerboard {
  background-color: #fff;
  background-image:
    linear-gradient(45deg, rgba(148, 163, 184, 0.18) 25%, transparent 25%),
    linear-gradient(-45deg, rgba(148, 163, 184, 0.18) 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, rgba(148, 163, 184, 0.18) 75%),
    linear-gradient(-45deg, transparent 75%, rgba(148, 163, 184, 0.18) 75%);
  background-size: 24px 24px;
  background-position: 0 0, 0 12px, 12px -12px, -12px 0;
}

.preview-card img {
  width: 100%;
  max-height: 360px;
  object-fit: contain;
  border-radius: 18px;
  display: none;
}

.mini-program-card {
  align-items: center;
  text-align: center;
}

.mini-program-qr {
  width: min(100%, 260px);
  margin: 8px auto 0;
  display: block;
  border-radius: 28px;
  background: #fff;
  padding: 10px;
  box-shadow: 0 18px 36px rgba(15, 23, 42, 0.1);
}

.mini-program-caption {
  margin-top: 12px;
  color: var(--muted);
  font-size: 14px;
}

.contact-entry,
.beian-link {
  margin-top: 14px;
}

.site-footer {
  display: flex;
  justify-content: center;
  margin-top: 18px;
  color: var(--muted);
  font-size: 14px;
}

.site-footer a {
  color: var(--muted);
}

.contact-modal,
.ps-modal {
  position: fixed;
  inset: 0;
  z-index: 40;
}

.contact-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.44);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.contact-dialog,
.ps-dialog {
  position: relative;
  width: min(520px, calc(100% - 24px));
  margin: min(12vh, 88px) auto 0;
  padding: 24px;
  border-radius: 30px;
  border: 1px solid rgba(255, 255, 255, 0.8);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 26px 60px rgba(15, 23, 42, 0.18);
}

.ps-dialog {
  width: min(1180px, calc(100% - 24px));
}

.contact-dialog-head,
.contact-dialog-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.contact-dialog-kicker {
  color: var(--accent);
  font-size: 13px;
  font-weight: 600;
}

.contact-dialog h3,
.ps-dialog h3 {
  margin: 8px 0 0;
  font-size: 28px;
  letter-spacing: -0.04em;
}

.contact-close {
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.08);
  color: var(--text);
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
}

.contact-dialog-copy {
  margin: 18px 0 0;
  color: var(--muted);
  line-height: 1.7;
}

.contact-email-card {
  margin-top: 18px;
  padding: 18px;
  border-radius: 22px;
  background: rgba(240, 246, 255, 0.92);
  border: 1px solid rgba(148, 163, 184, 0.16);
}

.contact-email-label {
  font-size: 13px;
  color: var(--muted);
}

.contact-email-link {
  display: inline-block;
  margin-top: 8px;
  color: var(--accent);
  font-size: 22px;
  font-weight: 600;
  word-break: break-all;
}

.contact-dialog-actions {
  margin-top: 18px;
}

.ps-frame {
  width: 100%;
  height: min(72vh, 760px);
  margin-top: 18px;
  border: 0;
  border-radius: 24px;
  background: #fff;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 28px;
  transform: translateX(-50%) translateY(30px);
  padding: 14px 18px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.92);
  color: #fff;
  opacity: 0;
  pointer-events: none;
  transition: all 0.24s ease;
  z-index: 50;
}

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

@keyframes float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-10px);
  }
}

@media (max-width: 960px) {
  .hero-body,
  .tool-grid,
  .scenario-grid,
  .privacy-grid,
  .ps-grid,
  .action-grid {
    grid-template-columns: 1fr;
    display: grid;
  }

  .hero-nav {
    display: grid;
    gap: 14px;
  }

  .hero-links {
    flex-wrap: wrap;
  }

  .tool-card-wide {
    grid-column: auto;
  }

  .image-mode-tabs,
  .action-row {
    flex-direction: column;
    align-items: stretch;
  }

  .image-preview-grid {
    grid-template-columns: 1fr;
  }

  .ocr-action-row {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .page-shell {
    width: min(100% - 18px, 100%);
    margin: 10px auto 28px;
  }

  .hero,
  .section {
    padding: 20px;
    border-radius: 26px;
  }

  .hero-copy h1,
  .section-heading h2 {
    letter-spacing: -0.05em;
  }

  .contact-dialog-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .ps-frame {
    height: 60vh;
  }
}
