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

:root {
  --primary: #4C5FFF;
  --primary-light: #EEF0FF;
  --warm: #FF7A45;
  --warm-light: #FFF1EA;
  --gold-grad: linear-gradient(270deg, #FFD8B7 0%, #FFE2C1 100%);
  --hero-grad: linear-gradient(135deg, #4C5FFF 0%, #6E5CF0 50%, #8B5CF6 100%);

  --text-primary: #17182B;
  --text-secondary: #5D6178;
  --text-tertiary: #9497AB;

  --border: #EAEAF2;
  --bg: #FFFFFF;
  --bg-soft: #F6F6FB;

  --radius-md: 14px;
  --radius-lg: 22px;
  --radius-pill: 60px;
  --shadow-md: 0 14px 32px rgba(30,30,70,.1);

  --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; }

.navbar { display: flex; align-items: center; justify-content: space-between; padding: 16px 30px; border-bottom: 1px solid var(--border); position: sticky; top: 0; background: rgba(255,255,255,.94); 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: 24px; }
.nav-links a { font-size: 14px; color: var(--text-secondary); }
.nav-links a.active { color: var(--primary); font-weight: 700; }
.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: 1100px; margin: 16px auto 0; padding: 0 24px; font-size: 12px; color: var(--text-tertiary); }
.breadcrumb a { color: var(--text-secondary); }

/* ---------- Editorial hero ---------- */
.hero-banner {
  background: var(--hero-grad); color: #fff; padding: 56px 24px; margin: 20px auto 0; max-width: 1100px;
  border-radius: var(--radius-lg); text-align: center;
}
.hero-eyebrow { display: inline-flex; font-size: 12px; font-weight: 600; background: rgba(255,255,255,.18); padding: 6px 14px; border-radius: var(--radius-pill); margin-bottom: 16px; }
.hero-title { font-size: 32px; font-weight: 800; margin: 0 0 12px; }
.hero-sub { font-size: 14px; opacity: .9; max-width: 640px; margin: 0 auto; line-height: 1.75; }

.app-badge-row { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 22px; }
.btn-app { display: inline-flex; align-items: center; gap: 7px; background: #fff; color: var(--text-primary); padding: 11px 20px; border-radius: var(--radius-pill); font-size: 13px; font-weight: 700; }
.btn-app.secondary { background: rgba(255,255,255,.16); color: #fff; border: 1px solid rgba(255,255,255,.4); }

.lite-translate-wrap { max-width: 820px; margin: -22px auto 0; padding: 0 24px; position: relative; z-index: 5; }
.lite-translate-label { display: flex; align-items: center; justify-content: space-between; background: #fff; border-radius: 10px 10px 0 0; padding: 10px 20px 0; font-size: 12.5px; color: var(--text-tertiary); }
.lite-translate-label a { color: var(--primary); font-weight: 700; }
.translate-box { max-width: 820px; margin: 0 auto 0; background: #fff; border-radius: var(--radius-lg); box-shadow: var(--shadow-md); overflow: hidden; text-align: left; position: relative; z-index: 5; }
.translate-box.compact .pane { min-height: 110px; padding: 14px 20px; }
.translate-grid { display: grid; grid-template-columns: 1fr 1fr; }
.pane { padding: 20px 24px; min-height: 190px; 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: 15px; line-height: 1.6; font-family: inherit; }
.pane-textarea::placeholder { color: var(--text-tertiary); }
.pane-result { flex: 1; font-size: 15px; line-height: 1.6; }
.pane-footer { display: flex; justify-content: space-between; padding-top: 12px; margin-top: 12px; border-top: 1px solid var(--border); }
.char-count { font-size: 12px; color: var(--text-tertiary); }

/* ---------- Section ---------- */
.section { max-width: 1100px; margin: 0 auto; padding: 64px 24px; }
.section-kicker { font-size: 12px; font-weight: 700; color: var(--warm); 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: 720px; margin: 0 0 32px; }

/* ---------- Featured articles ---------- */
.article-grid { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 18px; }
.article-card {
  border-radius: var(--radius-lg); overflow: hidden; border: 1px solid var(--border);
  display: flex; flex-direction: column;
}
.article-card.featured { grid-row: span 2; }
.article-media {
  height: 150px; background: linear-gradient(135deg, var(--primary-light), #fff);
  display: flex; align-items: center; justify-content: center; color: var(--primary);
}
.article-card.featured .article-media { height: 240px; }
.article-media svg { width: 40px; height: 40px; }
.article-body { padding: 18px 20px; flex: 1; display: flex; flex-direction: column; }
.article-tag { display: inline-block; font-size: 11px; font-weight: 700; color: var(--warm); background: var(--warm-light); padding: 3px 10px; border-radius: var(--radius-pill); margin-bottom: 10px; width: fit-content; }
.article-body h3 { font-size: 16px; font-weight: 700; margin: 0 0 8px; }
.article-card.featured .article-body h3 { font-size: 19px; }
.article-body p { font-size: 13px; color: var(--text-secondary); line-height: 1.7; margin: 0; flex: 1; }
.article-more { font-size: 12.5px; font-weight: 700; color: var(--primary); margin-top: 12px; }

/* ---------- Compare strip ---------- */
.compare-strip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.compare-chip { border: 1px solid var(--border); border-radius: var(--radius-md); padding: 20px; }
.compare-chip h4 { font-size: 14.5px; font-weight: 700; margin: 0 0 6px; }
.compare-chip p { font-size: 12.5px; color: var(--text-secondary); line-height: 1.7; margin: 0 0 12px; }
.compare-chip a { font-size: 12.5px; font-weight: 700; color: var(--primary); }

/* ---------- 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; }

/* ---------- shared pages ---------- */
.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; }
.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(--warm); box-shadow: 0 0 0 2px var(--warm-light); }
.plan-badge { position: absolute; top: -11px; left: 50%; transform: translateX(-50%); background: var(--warm); color: #fff; 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 { 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: 900px) {
  .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); }
  .article-grid { grid-template-columns: 1fr; }
  .article-card.featured { grid-row: auto; }
  .compare-strip, .plan-grid { grid-template-columns: 1fr; }
}

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