/* 有道翻译 — 官方网站 */

:root {
  --primary: #4C5FFF;
  --primary-dark: #3A46E0;
  --primary-light: #EEF0FF;
  --ai-grad: linear-gradient(270deg, #816FF1 0%, #6663F7 55%, #7583FF 100%);
  --gold-grad: linear-gradient(270deg, #FFD8B7 0%, #FFE2C1 100%);

  --text-primary: #16182E;
  --text-secondary: #5B6178;
  --text-tertiary: #9AA0B4;

  --border: #E8E9F1;
  --bg: #FFFFFF;
  --bg-soft: #F6F7FB;

  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-pill: 60px;

  --shadow-sm: 0 1px 2px rgba(16, 24, 40, 0.06);
  --shadow-md: 0 8px 24px rgba(41, 47, 105, 0.08);

  --font: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body { font-family: var(--font); color: var(--text-primary); background: var(--bg); -webkit-font-smoothing: antialiased; }
a { text-decoration: none; color: inherit; }
button { font-family: inherit; cursor: pointer; }
ul { list-style: none; margin: 0; padding: 0; }
img, svg { display: block; }

/* ---------- Nav ---------- */
.navbar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 32px; border-bottom: 1px solid var(--border);
  position: sticky; top: 0; background: rgba(255,255,255,.92); backdrop-filter: blur(8px); z-index: 30;
}
.brand { display: flex; align-items: center; gap: 9px; flex-shrink: 0; min-width: 125px; }
.brand-mark { width: 30px; height: 30px; }
.brand-word { font-size: 16px; font-weight: 700; }
.nav-links { display: flex; align-items: center; gap: 26px; }
.nav-links a { font-size: 14px; color: var(--text-secondary); padding-bottom: 3px; border-bottom: 2px solid transparent; }
.nav-links a.active, .nav-links a:hover { color: var(--text-primary); border-bottom-color: var(--primary); }
.btn-vip { background: var(--gold-grad); color: #7A4A12; font-size: 13px; font-weight: 700; padding: 9px 18px; border-radius: var(--radius-pill); border: none; }

.breadcrumb { max-width: 1080px; margin: 16px auto 0; padding: 0 24px; font-size: 12px; color: var(--text-tertiary); }
.breadcrumb a { color: var(--text-secondary); }

/* ---------- App download hero ---------- */
.app-hero { padding: 40px 24px 0; text-align: center; }
.app-hero-grid { max-width: 780px; margin: 0 auto; text-align: center; }
.app-hero h1 { font-size: 28px; font-weight: 800; margin: 0 0 12px; line-height: 1.35; }
.app-hero-sub { font-size: 14px; color: var(--text-secondary); line-height: 1.75; margin: 0 auto 22px; max-width: 460px; }
.app-badge-row { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.btn-app { display: inline-flex; align-items: center; gap: 8px; background: var(--text-primary); color: #fff; padding: 11px 20px; border-radius: var(--radius-pill); font-size: 13px; font-weight: 700; }
.btn-app svg { width: 16px; height: 16px; }
.btn-app.secondary { background: #fff; color: var(--text-primary); border: 1px solid var(--border); }

.lite-translate-wrap { max-width: 1080px; margin: 28px auto 0; padding: 0 24px; }
.lite-translate-label { display: flex; align-items: center; justify-content: space-between; font-size: 12.5px; color: var(--text-tertiary); margin-bottom: 10px; }
.lite-translate-label a { color: var(--primary); font-weight: 700; }
.translate-box.compact { margin: 0; }
.translate-box.compact .pane { min-height: 120px; padding: 14px 18px; }

/* ---------- Hero + translate (legacy, unused on index) ---------- */
.hero { padding: 40px 24px 0; text-align: center; }
.hero-eyebrow {
  display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600;
  color: var(--primary); background: var(--primary-light); padding: 6px 14px; border-radius: var(--radius-pill); margin-bottom: 14px;
}
.hero-title { font-size: 30px; font-weight: 800; margin: 0 0 10px; }
.hero-sub { font-size: 14px; color: var(--text-secondary); max-width: 660px; margin: 0 auto; line-height: 1.75; }

.translate-box {
  max-width: 980px; margin: 32px auto 0; border: 1px solid var(--border);
  border-radius: var(--radius-lg); box-shadow: var(--shadow-md); overflow: hidden; text-align: left;
}
.translate-grid { display: grid; grid-template-columns: 1fr 1fr; }
.pane { padding: 20px 24px; min-height: 220px; display: flex; flex-direction: column; }
.pane-source { border-right: 1px solid var(--border); }
.pane-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.lang-select { display: flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 500; }
.lang-select svg { width: 14px; height: 14px; color: var(--text-tertiary); }
.pane-textarea { flex: 1; border: none; outline: none; resize: none; font-size: 16px; line-height: 1.6; font-family: inherit; color: var(--text-primary); }
.pane-textarea::placeholder { color: var(--text-tertiary); }
.pane-result { flex: 1; font-size: 16px; line-height: 1.6; }
.pane-footer { display: flex; align-items: center; justify-content: space-between; padding-top: 12px; margin-top: 12px; border-top: 1px solid var(--border); }
.pane-tools { display: flex; gap: 12px; color: var(--text-tertiary); }
.pane-tools svg { width: 16px; height: 16px; }
.char-count { font-size: 12px; color: var(--text-tertiary); }
.btn-ai-polish { background: var(--ai-grad); color: #fff; font-size: 13px; font-weight: 500; border: none; border-radius: 8px; padding: 7px 14px; }

/* ---------- Section shell ---------- */
.section { max-width: 1080px; margin: 0 auto; padding: 64px 24px; }
.section-kicker { font-size: 12px; font-weight: 700; color: var(--primary); text-transform: uppercase; letter-spacing: 1px; margin-bottom: 8px; }
.section-title { font-size: 24px; font-weight: 800; margin: 0 0 10px; }
.section-intro { font-size: 14px; color: var(--text-secondary); line-height: 1.8; max-width: 760px; margin: 0 0 32px; }

/* ---------- Reason grid ---------- */
.reason-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.reason-card { border: 1px solid var(--border); border-radius: var(--radius-md); padding: 22px; }
.reason-icon { width: 40px; height: 40px; border-radius: 10px; background: var(--primary-light); color: var(--primary); display: flex; align-items: center; justify-content: center; margin-bottom: 14px; }
.reason-icon svg { width: 20px; height: 20px; }
.reason-card h3 { font-size: 15px; font-weight: 700; margin: 0 0 8px; }
.reason-card p { font-size: 13px; color: var(--text-secondary); line-height: 1.7; margin: 0; }

/* ---------- Compare table ---------- */
.compare-table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: var(--radius-md); }
.compare-table { width: 100%; border-collapse: collapse; font-size: 13px; min-width: 640px; }
.compare-table th, .compare-table td { padding: 14px 18px; text-align: left; border-bottom: 1px solid var(--border); }
.compare-table th { background: var(--bg-soft); font-weight: 700; color: var(--text-primary); }
.compare-table td { color: var(--text-secondary); }
.compare-table tr:last-child td { border-bottom: none; }
.compare-table td a { color: var(--primary); font-weight: 600; }
.compare-table .tag {
  display: inline-block; font-size: 11px; font-weight: 700; color: var(--primary);
  background: var(--primary-light); padding: 2px 8px; border-radius: var(--radius-pill); margin-left: 6px;
}

/* ---------- Scenario grid ---------- */
.scenario-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.scenario-card { border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 26px; }
.scenario-card .scenario-tag { font-size: 11px; font-weight: 700; color: var(--primary); background: var(--primary-light); padding: 3px 10px; border-radius: var(--radius-pill); display: inline-block; margin-bottom: 12px; }
.scenario-card h3 { font-size: 16px; font-weight: 700; margin: 0 0 8px; }
.scenario-card p { font-size: 13px; color: var(--text-secondary); line-height: 1.75; margin: 0; }

/* ---------- FAQ ---------- */
.faq-list { display: flex; flex-direction: column; gap: 10px; max-width: 820px; }
.faq-item { border: 1px solid var(--border); border-radius: var(--radius-md); padding: 4px 20px; }
.faq-item summary { cursor: pointer; padding: 15px 0; font-size: 14px; font-weight: 600; list-style: none; display: flex; justify-content: space-between; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; color: var(--text-tertiary); font-size: 18px; font-weight: 400; }
.faq-item[open] summary::after { content: "\2013"; }
.faq-item p { font-size: 13px; color: var(--text-secondary); line-height: 1.75; margin: 0 0 16px; }

/* ---------- Generic page pieces (document / vip) ---------- */
.upload-panel { border: 1.5px dashed var(--border); border-radius: var(--radius-lg); padding: 48px 24px; text-align: center; background: var(--bg-soft); }
.upload-icon { width: 52px; height: 52px; border-radius: 14px; background: var(--primary-light); color: var(--primary); display: flex; align-items: center; justify-content: center; margin: 0 auto 14px; }
.upload-icon svg { width: 26px; height: 26px; }
.upload-title { font-size: 15px; font-weight: 700; margin-bottom: 4px; }
.upload-sub { font-size: 13px; color: var(--text-secondary); margin-bottom: 18px; }
.btn-primary { background: var(--primary); color: #fff; border: none; border-radius: var(--radius-pill); padding: 11px 24px; font-size: 14px; font-weight: 700; }
.filetype-row { display: flex; justify-content: center; gap: 10px; margin-top: 20px; }
.filetype-chip { width: 34px; height: 34px; border-radius: 8px; border: 1px solid var(--border); display: flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 700; color: var(--text-secondary); }

.plan-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 8px; }
.plan-card { border: 1px solid var(--border); border-radius: var(--radius-md); padding: 24px 20px; text-align: center; position: relative; }
.plan-card.featured { border-color: var(--primary); box-shadow: 0 0 0 2px var(--primary-light); }
.plan-badge { position: absolute; top: -11px; left: 50%; transform: translateX(-50%); background: var(--gold-grad); color: #7A4A12; font-size: 11px; font-weight: 700; padding: 3px 12px; border-radius: var(--radius-pill); }
.plan-name { font-size: 14px; color: var(--text-secondary); margin-bottom: 8px; }
.plan-price { font-size: 28px; font-weight: 800; margin-bottom: 2px; }
.plan-price span { font-size: 13px; font-weight: 400; color: var(--text-tertiary); }
.plan-desc { font-size: 12px; color: var(--text-tertiary); margin-bottom: 16px; }

/* ---------- Footer ---------- */
.footer { border-top: 1px solid var(--border); padding: 30px 24px; text-align: center; font-size: 12px; color: var(--text-tertiary); }
.footer-links { display: flex; justify-content: center; gap: 18px; flex-wrap: wrap; margin-bottom: 10px; }
.footer-links a { color: var(--text-secondary); }

@media (max-width: 860px) {
  .navbar { padding: 12px 16px; }
  .brand { flex-shrink: 0; min-width: 110px; }
  .nav-links { display: none; }
  .translate-grid { grid-template-columns: 1fr; }
  .pane-source { border-right: none; border-bottom: 1px solid var(--border); }
  .reason-grid { grid-template-columns: 1fr 1fr; }
  .scenario-grid, .plan-grid { grid-template-columns: 1fr; }
}

.brand-logo {
  height: 28px;
  width: auto;
  aspect-ratio: 1280 / 285;
  display: block;
  max-width: none;
  object-fit: contain;
}
