/* ============================================================
   泰国TDAC电子入境卡 - 全站样式
   改颜色/字体只需要改这里的 :root 变量
   ============================================================ */
:root {
  --primary: #4338ca;        /* 主色（深紫蓝） */
  --primary-dark: #312e81;
  --primary-light: #eef2ff;
  --accent: #f59e0b;         /* 强调色（金） */
  --text: #1f2937;
  --text-light: #6b7280;
  --bg: #f8fafc;
  --card: #ffffff;
  --border: #e5e7eb;
  --success: #16a34a;
  --danger: #dc2626;
  --radius: 14px;
  --shadow: 0 4px 20px rgba(49, 46, 129, .08);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.75;
}
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; }
.container { max-width: 1080px; margin: 0 auto; padding: 0 20px; }

/* ---------- 顶部导航 ---------- */
.site-header {
  background: #fff;
  border-bottom: 1px solid var(--border);
  position: sticky; top: 0; z-index: 100;
}
.header-inner {
  max-width: 1080px; margin: 0 auto; padding: 0 20px;
  display: flex; align-items: center; justify-content: space-between;
  height: 64px;
}
.logo { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 17px; color: var(--primary-dark); }
.logo:hover { text-decoration: none; }
.logo .flag {
  width: 34px; height: 34px; border-radius: 50%;
  background: linear-gradient(180deg, #b41f2e 0 16%, #fff 16% 33%, #241d4f 33% 67%, #fff 67% 84%, #b41f2e 84%);
  display: inline-block; flex: none;
}
.main-nav { display: flex; align-items: center; gap: 22px; }
.main-nav a { color: var(--text); font-size: 15px; }
.main-nav a.active, .main-nav a:hover { color: var(--primary); text-decoration: none; }
.nav-cta {
  background: var(--primary); color: #fff !important;
  padding: 9px 20px; border-radius: 999px; font-weight: 600;
}
.nav-cta:hover { background: var(--primary-dark); }
.menu-btn { display: none; background: none; border: none; font-size: 24px; cursor: pointer; color: var(--primary-dark); }

/* ---------- Hero 首屏 ---------- */
.hero {
  background: linear-gradient(135deg, #312e81 0%, #4338ca 55%, #6d28d9 100%);
  color: #fff; padding: 72px 0 84px; text-align: center;
}
.hero h1 { font-size: 38px; margin-bottom: 14px; }
.hero p.sub { font-size: 17px; opacity: .92; max-width: 640px; margin: 0 auto 30px; }
.btn {
  display: inline-block; padding: 13px 32px; border-radius: 999px;
  font-weight: 600; font-size: 16px; cursor: pointer; border: none;
}
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { filter: brightness(1.06); text-decoration: none; }
.btn-outline { background: transparent; color: #fff; border: 2px solid rgba(255,255,255,.7); }
.btn-outline:hover { background: rgba(255,255,255,.12); text-decoration: none; }
.btn-ghost { background: var(--primary-light); color: var(--primary); }
.btn-block { display: block; width: 100%; text-align: center; }

/* ---------- 通用区块 ---------- */
.section { padding: 56px 0; }
.section-title { text-align: center; font-size: 27px; margin-bottom: 8px; color: var(--primary-dark); }
.section-sub { text-align: center; color: var(--text-light); margin-bottom: 36px; }

/* 三步流程 */
.steps { display: flex; gap: 24px; justify-content: center; flex-wrap: wrap; }
.step {
  background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 34px 26px; text-align: center; flex: 1; min-width: 240px; max-width: 320px;
}
.step .icon {
  width: 58px; height: 58px; margin: 0 auto 16px; border-radius: 50%;
  background: var(--primary-light); color: var(--primary);
  display: flex; align-items: center; justify-content: center; font-size: 26px;
}
.step h3 { font-size: 18px; margin-bottom: 8px; }
.step p { color: var(--text-light); font-size: 14px; }

/* 优点卡片 */
.grid-4 { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 20px; }
.benefit {
  background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 26px 22px; text-align: center;
}
.benefit .icon {
  width: 52px; height: 52px; margin: 0 auto 14px; border-radius: 12px;
  background: linear-gradient(135deg, var(--primary), #7c3aed);
  color: #fff; display: flex; align-items: center; justify-content: center; font-size: 24px;
}
.benefit h3 { font-size: 16px; margin-bottom: 6px; }
.benefit p { color: var(--text-light); font-size: 13.5px; }

/* 对比表 */
.compare-table { width: 100%; border-collapse: collapse; background: #fff; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.compare-table th, .compare-table td { padding: 13px 16px; border-bottom: 1px solid var(--border); text-align: left; font-size: 14.5px; }
.compare-table thead th { background: var(--primary-dark); color: #fff; font-size: 15px; }
.compare-table td.check { text-align: center; font-weight: 700; }
.yes { color: var(--success); }
.no { color: var(--danger); }

/* 内容卡片（法务/说明页通用） */
.doc-card {
  background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 40px 44px; max-width: 860px; margin: 0 auto;
}
.doc-card h1 { font-size: 26px; color: var(--primary-dark); margin-bottom: 18px; text-align: center; }
.doc-card h2 { font-size: 19px; color: var(--primary-dark); margin: 26px 0 10px; }
.doc-card h3 { font-size: 16px; margin: 20px 0 8px; }
.doc-card p, .doc-card li { color: #374151; font-size: 15px; margin-bottom: 10px; }
.doc-card ul, .doc-card ol { padding-left: 22px; margin-bottom: 12px; }

/* FAQ */
.faq-item {
  background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow);
  margin-bottom: 14px; overflow: hidden;
}
.faq-item summary {
  padding: 18px 22px; font-weight: 600; cursor: pointer; font-size: 15.5px;
  list-style: none; display: flex; justify-content: space-between; align-items: center;
}
.faq-item summary::after { content: "+"; font-size: 20px; color: var(--primary); }
.faq-item[open] summary::after { content: "−"; }
.faq-item .answer { padding: 0 22px 18px; color: var(--text-light); font-size: 14.5px; }

/* ---------- 表单 ---------- */
.form-card {
  background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 36px 40px; max-width: 860px; margin: 0 auto;
}
.form-section-title {
  display: flex; align-items: center; gap: 10px;
  font-size: 18px; color: var(--primary-dark); margin: 30px 0 14px; font-weight: 700;
}
.form-section-title:first-child { margin-top: 0; }
.form-section-title .badge {
  background: var(--primary); color: #fff; border-radius: 8px;
  width: 28px; height: 28px; display: inline-flex; align-items: center; justify-content: center; font-size: 14px; flex: none;
}
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 20px; }
.form-grid .full { grid-column: 1 / -1; }
.field label { display: block; font-size: 14px; font-weight: 600; margin-bottom: 6px; }
.field label .req { color: var(--danger); margin-left: 3px; }
.field input, .field select, .field textarea {
  width: 100%; padding: 11px 14px; border: 1.5px solid var(--border); border-radius: 10px;
  font-size: 15px; font-family: inherit; background: #fff; color: var(--text);
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(67, 56, 202, .12);
}
.field .tip { font-size: 12.5px; color: var(--text-light); margin-top: 4px; }
.radio-row { display: flex; gap: 26px; align-items: center; padding-top: 4px; }
.radio-row label { display: flex; align-items: center; gap: 6px; font-weight: 500; cursor: pointer; }
.checkbox-row { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; color: var(--text-light); }
.checkbox-row input { margin-top: 4px; width: 17px; height: 17px; flex: none; }

/* 套餐选择 */
.package-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin: 10px 0 4px; }
.package {
  border: 2px solid var(--border); border-radius: var(--radius); padding: 20px 22px;
  cursor: pointer; position: relative; background: #fff;
}
.package input { position: absolute; opacity: 0; }
.package .p-name { font-weight: 700; font-size: 16px; color: var(--primary-dark); }
.package .p-desc { font-size: 13.5px; color: var(--text-light); margin: 4px 0 10px; }
.package .p-price { font-size: 26px; font-weight: 800; color: var(--primary); }
.package .p-price small { font-size: 13px; font-weight: 500; color: var(--text-light); }
.package.selected { border-color: var(--primary); background: var(--primary-light); }
.package .hot {
  position: absolute; top: -11px; right: 14px; background: var(--accent); color: #fff;
  font-size: 12px; padding: 2px 12px; border-radius: 999px; font-weight: 700;
}

/* ---------- 支付收银台 ---------- */
.cashier {
  max-width: 520px; margin: 0 auto; background: var(--card); border-radius: var(--radius);
  box-shadow: var(--shadow); overflow: hidden;
}
.cashier-head {
  background: linear-gradient(135deg, var(--primary-dark), var(--primary));
  color: #fff; padding: 26px 30px; text-align: center;
}
.cashier-head h1 { font-size: 20px; margin-bottom: 4px; }
.cashier-head .amount { font-size: 34px; font-weight: 800; }
.cashier-body { padding: 30px; text-align: center; }
.qr-box {
  width: 230px; height: 230px; margin: 0 auto 18px; border: 2px dashed var(--border);
  border-radius: 14px; display: flex; align-items: center; justify-content: center;
  color: var(--text-light); font-size: 14px; background: var(--bg);
}
.qr-box img { width: 100%; height: 100%; object-fit: contain; }
.order-meta { background: var(--bg); border-radius: 10px; padding: 14px 18px; text-align: left; font-size: 14px; margin-bottom: 20px; }
.order-meta div { display: flex; justify-content: space-between; padding: 3px 0; }
.order-meta span:last-child { font-weight: 600; }

/* 成功页 */
.success-icon {
  width: 84px; height: 84px; margin: 0 auto 20px; border-radius: 50%;
  background: var(--success); color: #fff; font-size: 44px;
  display: flex; align-items: center; justify-content: center;
}

/* 查询结果 */
.query-result { max-width: 560px; margin: 24px auto 0; }
.result-card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 26px 30px; text-align: left; }
.result-card .status { font-weight: 800; font-size: 18px; }
.status.ok { color: var(--success); }
.status.pending { color: var(--accent); }

/* ---------- 底部 ---------- */
.site-footer { background: var(--primary-dark); color: #cbd5f5; margin-top: 70px; padding: 46px 0 26px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 34px; margin-bottom: 30px; }
.site-footer h4 { color: #fff; font-size: 15.5px; margin-bottom: 12px; }
.site-footer a { color: #cbd5f5; font-size: 13.5px; display: block; padding: 3px 0; }
.site-footer a:hover { color: #fff; }
.site-footer p { font-size: 13.5px; }
.copyright { border-top: 1px solid rgba(255,255,255,.15); padding-top: 18px; text-align: center; font-size: 12.5px; opacity: .8; }
.disclaimer { background: #fef3c7; color: #92400e; font-size: 13px; padding: 10px 18px; border-radius: 10px; margin-bottom: 22px; }

/* 响应式 */
@media (max-width: 768px) {
  .main-nav {
    display: none; position: absolute; top: 64px; left: 0; right: 0;
    background: #fff; flex-direction: column; padding: 18px 22px; gap: 14px;
    border-bottom: 1px solid var(--border); box-shadow: var(--shadow);
  }
  .main-nav.open { display: flex; }
  .menu-btn { display: block; }
  .hero h1 { font-size: 27px; }
  .form-grid, .package-row { grid-template-columns: 1fr; }
  .form-card, .doc-card { padding: 26px 20px; }
  .footer-grid { grid-template-columns: 1fr; }
}
