/* ============================================================
   ZIRO 网站页脚样式 —— 配合 /footer.js 使用
   ziro.com.my 各页面, warranty.ziro.com.my 和浅色的 /keycap/ 都引用这一份
   (其他站点用绝对地址 https://ziro.com.my/footer.css),
   所以颜色 / 字体 token 定义在 .site-footer 自己身上, 不依赖宿主页面.
   ============================================================ */
.site-footer {
  --f-bg:          #0d0f12;
  --f-input:       #14171e;
  --f-line:        rgba(255, 255, 255, 0.06);
  --f-line-strong: rgba(255, 255, 255, 0.14);
  --f-text:        #f4f5f7;
  --f-text-dim:    #8b909a;
  --f-text-mute:   #545861;
  --f-accent:      #5fd4ff;
  --f-glow:        rgba(95, 212, 255, 0.12);
  --f-display:     "Oswald", "Noto Sans SC", -apple-system, sans-serif;
  --f-body:        "Inter", "Noto Sans SC", -apple-system, sans-serif;
  --f-mono:        "JetBrains Mono", ui-monospace, "SF Mono", monospace;
  --f-ease:        cubic-bezier(0.4, 0, 0.2, 1);

  position: relative;
  z-index: 5;
  padding: 72px max(8vw, 24px) 32px;
  border-top: 1px solid var(--f-line);
  background:
    radial-gradient(ellipse at 15% 0%, var(--f-glow) 0%, transparent 55%),
    var(--f-bg);
  color: var(--f-text-dim);
  font-family: var(--f-body);
  font-size: 14px;
  line-height: 1.6;
  text-align: left;
  -webkit-font-smoothing: antialiased;
}
.site-footer *,
.site-footer *::before,
.site-footer *::after { box-sizing: border-box; margin: 0; padding: 0; }
.site-footer a { color: inherit; text-decoration: none; }

.footer-main,
.footer-legal {
  max-width: 1400px;
  margin: 0 auto;
}
.footer-main {
  display: grid;
  grid-template-columns: 1.6fr repeat(3, 1fr) 1.4fr;
  gap: 40px;
  padding-bottom: 48px;
}

.footer-brand-block {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.footer-mark { width: 28px; height: 28px; object-fit: contain; }
.footer-brand {
  font-family: var(--f-display);
  font-weight: 600;
  font-size: 18px;
  letter-spacing: 0.22em;
  color: var(--f-text);
}
/* 商标申请中用 ™; 注册后改成 ® */
.footer-tm {
  margin-left: 2px;
  font-size: 0.5em;
  font-weight: 500;
  letter-spacing: 0;
  vertical-align: super;
  line-height: 0;
}
.footer-about {
  margin: 18px 0 22px;
  max-width: 320px;
  line-height: 1.7;
}
.footer-social {
  list-style: none;
  display: flex;
  gap: 8px;
}
.footer-social a {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--f-line-strong);
  transition: color 0.2s var(--f-ease), border-color 0.2s var(--f-ease);
}
.footer-social a:hover,
.footer-social a:focus-visible { color: var(--f-accent); border-color: var(--f-accent); }

/* 标题: 桌面是普通标题, 手机是折叠栏的开关 */
.footer-col > summary,
.footer-heading {
  font-family: var(--f-display);
  font-weight: 500;
  font-size: 13px;
  line-height: 1.4;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--f-accent);
  margin-bottom: 18px;
}
.footer-col > summary {
  list-style: none;
  cursor: default;
}
.footer-col > summary::-webkit-details-marker { display: none; }
.footer-col ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.footer-col a { transition: color 0.2s var(--f-ease); }
.footer-col a:hover,
.footer-col a:focus-visible { color: var(--f-text); }

.footer-newsletter p { line-height: 1.7; }
.footer-subscribe {
  display: flex;
  margin-top: 16px;
  border: 1px solid var(--f-line-strong);
  background: var(--f-input);
  transition: border-color 0.2s var(--f-ease);
}
.footer-subscribe:focus-within { border-color: var(--f-accent); }
.footer-subscribe input {
  flex: 1;
  min-width: 0;
  padding: 13px 14px;
  background: transparent;
  border: none;
  outline: none;
  color: var(--f-text);
  font-family: var(--f-body);
  font-size: 14px;
}
.footer-subscribe input::placeholder { color: var(--f-text-mute); }
.footer-subscribe button {
  width: 48px;
  background: transparent;
  border: none;
  border-left: 1px solid var(--f-line-strong);
  color: var(--f-accent);
  cursor: pointer;
}
.footer-subscribe button:hover { background: var(--f-glow); }
.footer-newsletter .footer-subscribe-note {
  min-height: 22px;
  margin-top: 8px;
  font-size: 12px;
  color: var(--f-accent);
}

/* 商业注册资料 (政府要求公开) */
.footer-legal {
  padding-top: 24px;
  border-top: 1px solid var(--f-line);
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  line-height: 1.8;
  color: var(--f-text-mute);
}
.footer-company strong { color: var(--f-text-dim); font-weight: 500; }
.footer-reg { white-space: nowrap; }

.site-footer .visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* 平板: 链接三栏一排, 品牌和电子报各占一整行 */
@media (max-width: 960px) {
  .footer-main { grid-template-columns: repeat(3, 1fr); }
  .footer-brand-col,
  .footer-newsletter { grid-column: 1 / -1; }
}

/* 手机: 链接栏收成可点开的折叠栏 */
@media (max-width: 720px) {
  .site-footer { padding: 48px 20px 28px; }
  .footer-main { grid-template-columns: 1fr; gap: 0; padding-bottom: 32px; }
  .footer-brand-col { padding-bottom: 28px; }
  .footer-col { border-top: 1px solid var(--f-line); }
  .footer-col > summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 0;
    padding: 18px 0;
    cursor: pointer;
  }
  .footer-col > summary::after {
    content: "";
    width: 8px;
    height: 8px;
    margin-right: 4px;
    border-right: 1.5px solid currentColor;
    border-bottom: 1.5px solid currentColor;
    transform: rotate(45deg) translateY(-2px);
    transition: transform 0.2s var(--f-ease);
  }
  .footer-col[open] > summary::after { transform: rotate(-135deg) translateY(-2px); }
  .footer-col ul { padding-bottom: 20px; }
  .footer-newsletter { border-top: 1px solid var(--f-line); padding-top: 24px; }
}
