/* ==========================================================================
   i18n-ar.css —— 阿语站扩展样式（2026-10-16）
   --------------------------------------------------------------------------
   为什么单独一份：
     style.css 是三语共用的原始样式，里面
       ① 一个字都没有适配 RTL（[dir=rtl] 规则数 = 0）
       ② 缺 12 个新内容组件的类（prose / table / faq-item / callout …）
     直接改 style.css 会连带影响中/英/俄三站，所以新增内容组件 + 阿语
     排版适配都收在这一份里，只被 foshan-arabic（阿语站）引用。

   注意：阿拉伯字母的基线、连字高度与拉丁字母差别很大，行高必须放大，
   否则整段会挤在一起 —— 这是「看起来像机翻」之外最伤观感的细节。
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. 阿语字体栈
   Cairo / Tajawal 是中东资讯类站点通用度最高的两套吧，Noto Kufi Arabic
   作为兜底（Google Fonts 已随页面加载）。
   -------------------------------------------------------------------------- */
[dir="rtl"] {
  --font-body: 'Cairo', 'Tajawal', 'Noto Kufi Arabic', 'Segoe UI', system-ui, sans-serif;
  --font-display: 'Cairo', 'Tajawal', 'Noto Kufi Arabic', Georgia, serif;
}

[dir="rtl"] body {
  line-height: 1.95;
  font-size: 1.0625rem;
  letter-spacing: 0;
}

[dir="rtl"] .hero__title { line-height: 1.35; letter-spacing: 0; }
[dir="rtl"] .section-head__title { line-height: 1.45; }
[dir="rtl"] .logo { letter-spacing: 0; }
[dir="rtl"] .label,
[dir="rtl"] .label-line { letter-spacing: 0.05em; }
[dir="rtl"] .side-label { letter-spacing: 0.15em; }

/* --------------------------------------------------------------------------
   2. 子页 hero（内页头图，比首页矮）
   -------------------------------------------------------------------------- */
.hero--sub { min-height: 46vh; }
.hero--sub .hero__title { font-size: clamp(1.75rem, 4.4vw, 3rem); }
@media (max-width: 700px) { .hero--sub { min-height: 38vh; } }

/* --------------------------------------------------------------------------
   3. 窄容器（长文阅读宽度）
   -------------------------------------------------------------------------- */
.container--narrow { width: min(100% - var(--space-lg) * 2, 860px); margin-inline: auto; }
.section--prose { padding-block: var(--space-xl); }

/* --------------------------------------------------------------------------
   4. 富文本（guides 正文）
   -------------------------------------------------------------------------- */
.prose { color: var(--text-muted); font-size: 1.0625rem; }
.prose > * + * { margin-top: var(--space-md); }
.prose h2 {
  font-family: var(--font-display);
  font-size: clamp(1.25rem, 2.6vw, 1.75rem);
  color: var(--text);
  margin-top: var(--space-xl);
  padding-inline-start: var(--space-sm);
  border-inline-start: 2px solid var(--accent);
  line-height: 1.5;
}
.prose h3 {
  font-family: var(--font-display);
  font-size: 1.125rem;
  color: var(--text);
  margin-top: var(--space-lg);
}
.prose p { line-height: 1.95; }
.prose ul, .prose ol { padding-inline-start: 1.4rem; }
.prose li { margin-top: 0.5rem; line-height: 1.9; }
.prose li::marker { color: var(--accent); }
.prose strong { color: var(--text); font-weight: 600; }
.prose a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }

.callout {
  background: var(--accent-ghost);
  border: 1px solid rgba(201, 169, 98, 0.3);
  border-radius: 2px;
  padding: var(--space-md) var(--space-lg);
  color: var(--text);
  line-height: 1.9;
  font-size: 1rem;
}

/* --------------------------------------------------------------------------
   5. 表格（对比 / 参数 / 费用）
   -------------------------------------------------------------------------- */
.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  background: var(--bg-card);
  -webkit-overflow-scrolling: touch;
}
.table-wrap table { width: 100%; border-collapse: collapse; min-width: 520px; }
.table-wrap th, .table-wrap td {
  padding: 0.85rem 1rem;
  text-align: start;
  border-bottom: 1px solid var(--line);
  font-size: 0.95rem;
  line-height: 1.8;
  vertical-align: top;
}
.table-wrap thead th {
  background: var(--bg-elevated);
  color: var(--accent);
  font-family: var(--font-display);
  font-weight: 600;
  white-space: nowrap;
}
.table-wrap tbody tr:last-child td { border-bottom: none; }
.table-wrap tbody tr:hover { background: rgba(244, 241, 234, 0.03); }
/* 数字与货币单元格按内容首字符定方向，避免 RTL 下 "800 CNY" 被拆开 */
.table-wrap td { unicode-bidi: plaintext; }

/* --------------------------------------------------------------------------
   6. FAQ（details/summary 折叠）
   -------------------------------------------------------------------------- */
.faq { display: grid; gap: var(--space-sm); }
.faq-item {
  border: 1px solid var(--line);
  background: var(--bg-card);
  border-radius: 2px;
  overflow: hidden;
}
.faq-item[open] { border-color: rgba(201, 169, 98, 0.35); }
.faq-item__q {
  cursor: pointer;
  padding: var(--space-md) var(--space-lg);
  font-family: var(--font-display);
  font-size: 1.0625rem;
  color: var(--text);
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-md);
  line-height: 1.7;
}
.faq-item__q::-webkit-details-marker { display: none; }
.faq-item__q::after {
  content: '+';
  color: var(--accent);
  font-size: 1.4rem;
  line-height: 1;
  flex: none;
  transition: transform 0.25s ease;
}
.faq-item[open] .faq-item__q::after { transform: rotate(45deg); }
.faq-item__a {
  padding: 0 var(--space-lg) var(--space-md);
  color: var(--text-muted);
  line-height: 1.95;
  border-top: 1px solid var(--line);
  padding-top: var(--space-md);
}
.faq-item__a p { margin: 0; }

/* --------------------------------------------------------------------------
   7. 卡片网格（服务范围 / 决策选项 / 五类卖家）
   -------------------------------------------------------------------------- */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
  gap: var(--space-md);
}
.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: 2px;
  padding: var(--space-lg);
  transition: border-color 0.25s ease, transform 0.25s ease;
}
.feature-card:hover { border-color: rgba(201, 169, 98, 0.4); transform: translateY(-2px); }
.feature-card__title {
  font-family: var(--font-display);
  font-size: 1.0625rem;
  color: var(--text);
  margin: 0 0 var(--space-sm);
  line-height: 1.6;
}
.feature-card__desc {
  color: var(--text-muted);
  font-size: 0.9375rem;
  line-height: 1.9;
  margin: 0;
}

/* --------------------------------------------------------------------------
   8. 链接列表（指南索引）
   -------------------------------------------------------------------------- */
.link-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.5rem; }
.link-list li { border-bottom: 1px solid var(--line); }
.link-list li:last-child { border-bottom: none; }
.link-list a {
  display: block;
  padding: var(--space-sm) 0;
  color: var(--text);
  text-decoration: none;
  line-height: 1.8;
  transition: color 0.2s ease, padding-inline-start 0.2s ease;
}
.link-list a:hover { color: var(--accent); padding-inline-start: 0.5rem; }

/* --------------------------------------------------------------------------
   9. 本地化提示框（时区 / 语言 / 认证 / 物流）
   -------------------------------------------------------------------------- */
.local-note {
  border: 1px solid var(--line-strong);
  border-inline-start: 3px solid var(--accent);
  background: var(--bg-elevated);
  padding: var(--space-lg);
}
.local-note__title {
  font-family: var(--font-display);
  font-size: 1.0625rem;
  color: var(--accent);
  margin: 0 0 var(--space-md);
}
.local-note ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.65rem; }
.local-note li {
  color: var(--text-muted);
  line-height: 1.9;
  padding-inline-start: 1.4rem;
  position: relative;
  font-size: 0.9375rem;
}
.local-note li::before {
  content: '—';
  position: absolute;
  inset-inline-start: 0;
  color: var(--accent);
}

/* --------------------------------------------------------------------------
   10. 图片廊
   -------------------------------------------------------------------------- */
.gallery { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: var(--space-md); }
.gallery__item { margin: 0; }
.gallery__item img { width: 100%; height: auto; display: block; }
.gallery__item figcaption {
  color: var(--text-subtle);
  font-size: 0.8125rem;
  padding-top: 0.5rem;
  line-height: 1.7;
}

/* --------------------------------------------------------------------------
   11. RTL 位置翻转
   原样式用的是物理属性（left / padding-left），RTL 下必须镜像，
   否则大号章节数字、流程编号、徽章都会落到错误一侧。
   -------------------------------------------------------------------------- */
[dir="rtl"] .section-marker { left: auto; right: var(--space-lg); }
[dir="rtl"] .section-marker--right { right: auto; left: var(--space-lg); }
[dir="rtl"] .process__num { left: auto; right: 0; }
[dir="rtl"] .team-card__badge { left: auto; right: var(--space-sm); }
[dir="rtl"] .side-label {
  left: auto;
  right: 2rem;
  transform: translateY(-50%) rotate(90deg);
  transform-origin: right center;
}
[dir="rtl"] .hero__content { text-align: right; }
[dir="rtl"] .footer__bottom { text-align: start; }

/* 数字在阿语段落中保持从左到右的独立顺序（价格、天数、百分比） */
[dir="rtl"] .hero__meta-value,
[dir="rtl"] .value-card__num,
[dir="rtl"] .process__num { unicode-bidi: plaintext; }

/* 语言切换项内的拉丁标签不参与阿拉伯语连写 */
.lang-switch { unicode-bidi: isolate; font-family: var(--font-mono); }

/* --------------------------------------------------------------------------
   12. RTL 补漏（2026-10-16 逐条比对 style.css 的方向性硬编码后补齐）
   style.css 里还有 6 处物理方向属性，上一版没覆盖到。逐条列出原因，
   避免以后有人以为「已经适配过 RTL 了」而漏查：
     .process__line   left:1.25rem     竖线画在左边 → 阿语应在右
     .process__item   padding-left:3.5/4rem  编号占位在左 → 阿语应在右
     .comparison      text-align:left  表头/单元格靠左 → 阿语应靠右
     .faq__question   text-align:left  问题靠左 → 阿语应靠右
     .modal__close    right:...        关闭按钮在右上 → 阿语应在左上
     .mobile-nav      translateX(100%) 抽屉从右滑出 → 阿语应从左滑出
   -------------------------------------------------------------------------- */
[dir="rtl"] .process__line { left: auto; right: 1.25rem; }
[dir="rtl"] .process__item { padding-left: 0; padding-right: 3.5rem; }
[dir="rtl"] .comparison th,
[dir="rtl"] .comparison td { text-align: right; }
[dir="rtl"] .faq__question { text-align: right; }
[dir="rtl"] .modal__close { right: auto; left: var(--space-sm); }
[dir="rtl"] .mobile-nav { transform: translateX(-100%); }
[dir="rtl"] .mobile-nav.is-open { transform: translateX(0); }

@media (min-width: 900px) {
  [dir="rtl"] .process__item { padding-right: 4rem; }
}

/* 移动端：阿语长句在窄屏需要更松的行距 */
@media (max-width: 700px) {
  [dir="rtl"] body { line-height: 2.05; }
  [dir="rtl"] .section-marker { font-size: clamp(4rem, 20vw, 7rem); }
}
