/* ============================================================
   Typify 官网样式
   布局与节奏复刻 iina.io，品牌色为现代蓝 (#007AFF / #0066CC)
   深色模式：默认跟随系统 prefers-color-scheme（data-theme 仅作强制覆盖/调试用）
   ============================================================ */

:root {
  --accent: #007AFF;
  --accent-deep: #0066CC;
  --accent-soft: rgba(0, 122, 255, 0.12);

  --bg: #ffffff;
  --bg-hero-top: #fefefe;
  --bg-hero-bottom: #eef1f6;
  --text: #212529;
  --text-soft: #55595f;
  --muted: #777;
  --faint: #aaa;
  --line: rgba(0, 0, 0, 0.1);

  --nav-bg: rgba(255, 255, 255, 0.72);
  --nav-link: rgba(0, 0, 0, 0.55);
  --nav-link-strong: rgba(0, 0, 0, 0.85);
  --nav-pill: rgba(0, 0, 0, 0.06);
  --nav-pill-hover: rgba(0, 0, 0, 0.1);

  --win-bg: #f6f7f9;
  --win-side: #eef0f4;
  --win-border: rgba(0, 0, 0, 0.14);
  --win-text: #2b2f36;
  --win-muted: #8a8f99;
  --card-bg: #ffffff;

  /* 主窗口模拟图（按真实 App 窗口配色） */
  --hw-body: #ececee;
  --hw-titlebar: #ffffff;
  --hw-field: #ffffff;
  --hw-chip: #e9eaec;
  --hw-inset: #d5d6d9;
  --hw-card-border: rgba(0, 0, 0, 0.12);
  --win-radius: 26px;
  --slider-thumb: #ffffff;

  --dl-btn-bg: #007AFF;
  --dl-btn-text: #fff;
  --dl-btn-sub: rgba(255, 255, 255, 0.65);
  --gh-btn-bg: #111318;
  --gh-btn-text: #f2f4f8;
  --gh-btn-sub: #999;

  --footer-bg: #1c2129;
  --footer-text: #b6bcc6;
  --footer-strong: #eef1f5;
  --footer-line: #343b46;

  --hero-shot-shadow: 0 40px 90px -20px rgba(20, 40, 90, 0.35), 0 12px 30px rgba(20, 40, 90, 0.16);
  --shot-shadow: 0 24px 60px -18px rgba(0, 0, 0, 0.5), 0 8px 22px rgba(0, 0, 0, 0.25);
}

[data-theme="dark"] {
  --bg: #0d1117;
  --bg-hero-top: #10141c;
  --bg-hero-bottom: #171d28;
  --text: #e8ebf0;
  --text-soft: #b7bdc7;
  --muted: #8f96a3;
  --faint: #6b7280;
  --line: rgba(255, 255, 255, 0.12);

  --nav-bg: rgba(13, 17, 23, 0.72);
  --nav-link: rgba(255, 255, 255, 0.6);
  --nav-link-strong: rgba(255, 255, 255, 0.9);
  --nav-pill: rgba(255, 255, 255, 0.09);
  --nav-pill-hover: rgba(255, 255, 255, 0.15);

  --win-bg: #23262d;
  --win-side: #1c1f25;
  --win-border: rgba(0, 0, 0, 0.55);
  --win-text: #e6e9ee;
  --win-muted: #9aa0ab;
  --card-bg: #2a2e36;

  /* 主窗口模拟图（按真实 App 窗口配色） */
  --hw-body: #181b20;
  --hw-titlebar: #2b2e34;
  --hw-field: #23262d;
  --hw-chip: #3a3e46;
  --hw-inset: #3d4149;
  --hw-card-border: rgba(255, 255, 255, 0.1);
  --slider-thumb: #e6e6e8;

  --gh-btn-bg: rgba(255, 255, 255, 0.1);
  --gh-btn-text: #f2f4f8;
  --gh-btn-sub: #a7adb8;

  --footer-bg: #12161d;
  --footer-text: #9aa1ac;
  --footer-strong: #e8ebf0;
  --footer-line: #2b323d;

  --hero-shot-shadow: 0 40px 90px -20px rgba(0, 0, 0, 0.7), 0 12px 30px rgba(0, 0, 0, 0.45);
  --shot-shadow: 0 24px 60px -18px rgba(0, 0, 0, 0.65), 0 8px 22px rgba(0, 0, 0, 0.4);
}

@media (prefers-color-scheme: dark) {
  html:not([data-theme="light"]) {
    --bg: #0d1117;
    --bg-hero-top: #10141c;
    --bg-hero-bottom: #171d28;
    --text: #e8ebf0;
    --text-soft: #b7bdc7;
    --muted: #8f96a3;
    --faint: #6b7280;
    --line: rgba(255, 255, 255, 0.12);
    --nav-bg: rgba(13, 17, 23, 0.72);
    --nav-link: rgba(255, 255, 255, 0.6);
    --nav-link-strong: rgba(255, 255, 255, 0.9);
    --nav-pill: rgba(255, 255, 255, 0.09);
    --nav-pill-hover: rgba(255, 255, 255, 0.15);
    --win-bg: #23262d;
    --win-side: #1c1f25;
    --win-border: rgba(0, 0, 0, 0.55);
    --win-text: #e6e9ee;
    --win-muted: #9aa0ab;
    --card-bg: #2a2e36;

    /* 主窗口模拟图（按真实 App 窗口配色） */
    --hw-body: #181b20;
    --hw-titlebar: #2b2e34;
    --hw-field: #23262d;
    --hw-chip: #3a3e46;
    --hw-inset: #3d4149;
    --hw-card-border: rgba(255, 255, 255, 0.1);
    --slider-thumb: #e6e6e8;
    --gh-btn-bg: rgba(255, 255, 255, 0.1);
    --gh-btn-text: #f2f4f8;
    --gh-btn-sub: #a7adb8;
    --footer-bg: #12161d;
    --footer-text: #9aa1ac;
    --footer-strong: #e8ebf0;
    --footer-line: #2b323d;
    --hero-shot-shadow: 0 40px 90px -20px rgba(0, 0, 0, 0.7), 0 12px 30px rgba(0, 0, 0, 0.45);
    --shot-shadow: 0 24px 60px -18px rgba(0, 0, 0, 0.65), 0 8px 22px rgba(0, 0, 0, 0.4);
  }
}

/* ---------- 基础 ---------- */
* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "PingFang SC",
    "Hiragino Sans GB", "Helvetica Neue", "Microsoft YaHei", Arial, sans-serif;
  font-size: 1rem;
  line-height: 1.5;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; vertical-align: middle; border: 0; }
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-deep); text-decoration: underline; }
h1, h2, h3, h4, h5, h6 { margin: 0 0 0.5rem; font-weight: 500; line-height: 1.2; }
p { margin: 0 0 1rem; }
code {
  font-family: "SF Mono", SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 87.5%;
  background: var(--accent-soft);
  color: var(--accent-deep);
  padding: 0.1em 0.35em;
  border-radius: 0.3em;
}
[data-theme="dark"] code { color: #6db3ff; }
@media (prefers-color-scheme: dark) {
  html:not([data-theme="light"]) code { color: #6db3ff; }
}

.container {
  width: 100%;
  max-width: 1140px;
  padding-left: 15px;
  padding-right: 15px;
  margin-left: auto;
  margin-right: auto;
}

.ic { width: 1em; height: 1em; display: inline-block; vertical-align: -0.125em; }

/* ---------- 顶部导航 ---------- */
#header {
  position: absolute;
  left: 0; right: 0; top: 0;
  z-index: 1000;
}

.navbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  padding: 0.5rem 1.25rem;
  transition: all 0.3s ease-out;
}

#header .navbar.scrolled {
  background: var(--nav-bg);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  box-shadow: 0 0 6px rgba(0, 0, 0, 0.18);
}

.navbar-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.5rem;
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--nav-link-strong);
}
.navbar-brand:hover { color: var(--nav-link-strong); text-decoration: none; }
.brand-icon { width: 2rem; height: 2rem; border-radius: 7px; box-shadow: 0 1px 3px rgba(0,0,0,0.2); }

.navbar-nav {
  display: flex;
  align-items: center;
  flex-direction: row;
  padding-left: 0;
  margin: 0;
  list-style: none;
}

#header .nav-link {
  display: inline-block;
  padding: 0.25rem 0.9rem;
  line-height: 2.2;
  color: var(--nav-link);
  font-size: 0.95rem;
}
#header .nav-link:hover { color: var(--nav-link-strong); text-decoration: none; }
#header .nav-link .ic { margin-right: 0.35rem; }

#header .nav-link.stressed {
  background: var(--nav-pill);
  color: var(--nav-link-strong);
  transition: background 0.2s ease;
}
#header .nav-link.stressed:hover { background: var(--nav-pill-hover); }
#header .nav-link.stressed.left { border-radius: 2rem 0 0 2rem; margin-left: 1rem; }
#header .nav-link.stressed.right { border-radius: 0 2rem 2rem 0; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  padding: 12rem 0 13rem 0;
  background: linear-gradient(to bottom, var(--bg-hero-top), var(--bg-hero-bottom));
  overflow: hidden;
}
@media (min-width: 1200px) { .hero { padding: 14rem 0 15rem 0; } }

.hero-bg {
  position: absolute; inset: 0;
  pointer-events: none;
}

.hero-inner { position: relative; }

.small-headline {
  font-size: 1rem;
  font-weight: 500;
  letter-spacing: 0.14rem;
  color: var(--faint);
  padding-left: 0.15em;
}

.headline {
  font-size: 4rem;
  font-weight: 600;
  letter-spacing: 0.05rem;
  margin: 0;
}

.sub-headline { font-size: 1.6rem; margin: 1rem 0 0 0; }
.sub-headline .modern { color: var(--accent); }

.product-pr {
  display: flex;
  align-items: center;
  margin-top: 1.75rem;
  padding: 0.25rem 0;
}
.product-pr h6 {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 600;
  color: #e76000;
}
[data-theme="dark"] .product-pr h6 { color: #ffab5e; }
@media (prefers-color-scheme: dark) {
  html:not([data-theme="light"]) .product-pr h6 { color: #ffab5e; }
}
.pr-ic { margin-right: 0.35rem; }
.product-pr .pr-links { margin-left: 2rem; }
.product-pr .pr-links a { color: var(--text-soft); font-size: 0.95rem; }

.download { margin: 4rem 0 1rem 0; }

.dl-btn {
  display: inline-flex;
  align-items: center;
  background: var(--gh-btn-bg);
  color: var(--gh-btn-text);
  font-weight: 500;
  margin: 0.25rem 0;
  padding: 0.75rem 1.5rem;
  border-radius: 2rem;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}
.dl-btn:not(:last-child) { margin-right: 1rem; }
.dl-btn:hover { text-decoration: none; transform: translateY(-1px); color: var(--gh-btn-text); }
.dl-btn .ic { width: 1.1em; height: 1.1em; margin-right: 0.15rem; }
.dl-btn .light { color: var(--gh-btn-sub); margin-left: 0.5rem; font-size: 0.8em; font-weight: normal; }

.dl-btn.dmg { background: var(--dl-btn-bg); color: var(--dl-btn-text); }
.dl-btn.dmg:hover { background: var(--accent-deep); box-shadow: 0 6px 18px rgba(0, 122, 255, 0.35); color: #fff; }
.dl-btn.dmg .light { color: var(--dl-btn-sub); }
.dl-btn.dmg:hover .light { color: rgba(255, 255, 255, 0.7); }
/* beta 小徽标：胶囊形状，不用纯文本 */
.beta-tag {
  display: inline-block;
  margin-left: 0.5rem;
  padding: 0.1em 0.55em;
  font-size: 0.6em;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  line-height: 1.6;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  color: rgba(255, 255, 255, 0.88);
  vertical-align: 0.18em;
}
.dl-btn.github:hover { color: var(--gh-btn-text); background: #1f2228; box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25); }
/* github 按钮里的 MIT 副标在悬浮时保持原灰，不增亮 */
.dl-btn.github:hover .light { color: var(--gh-btn-sub); }

.requirement, .other-downloads {
  font-size: 0.8rem;
  margin: 1rem 0 0 0;
  color: var(--muted);
}
.other-downloads { margin: 0.5rem 0 0 0; }

/* ---------- Hero 主窗口模拟图 ---------- */
.shot { margin: 0; position: relative; }
.shot-img { width: 100%; height: auto; display: none; }
.shot.has-img .shot-img { display: block; }
.shot.has-img .mac-window { display: none; }
.shot.has-img .shot-img { display: block; }

.hero-shot {
  position: absolute;
  left: 47%;
  top: 22%;
  bottom: 20%;
  width: 46%;
  z-index: 5;
}
.hero-shot .mac-window { height: 100%; }

.mac-window {
  display: flex;
  flex-direction: column;
  background: var(--win-bg);
  border: 1px solid var(--win-border);
  border-radius: var(--win-radius, 12px);
  box-shadow: var(--hero-shot-shadow);
  overflow: hidden;
  font-size: 11px;
  line-height: 1.45;
  color: var(--win-text);
}

.mac-titlebar {
  position: relative;
  display: flex;
  align-items: center;
  height: 34px;
  padding: 0 12px;
  background: var(--win-side);
  border-bottom: 1px solid var(--win-border);
  flex: none;
}
.mac-titlebar .tl {
  width: 11px; height: 11px;
  border-radius: 50%;
  margin-right: 7px;
  background: #d8dadf;
  box-shadow: inset 0 0 0 0.5px rgba(0,0,0,0.08);
}
.mac-titlebar .tl:nth-child(1) { background: #ff5f57; }
.mac-titlebar .tl:nth-child(2) { background: #febc2e; }
.mac-titlebar .tl:nth-child(3) { background: #28c840; }
.mac-title {
  position: absolute;
  left: 0; right: 0;
  text-align: center;
  font-weight: 600;
  font-size: 11px;
  color: var(--win-muted);
  pointer-events: none;
}

/* 主窗口模拟图：按真实 App 窗口 1:1 重设计
   实测（2x 截图换算）：圆角 R=26px、标题栏高 2R=52px、
   红绿灯直径 14px 且圆心落在 (R,R)、右上「···」圆心也落在 (R,R)。
   即：窗口圆角的弧心 == 控件的圆心，二者同心。 */
.hero-window {
  --win-radius: 26px;
  --tl-size: 13px;
  background: var(--hw-body);
}
/* 标题栏高度 = 2R，配合 align-items:center 使红绿灯圆心正好落在 (R, R) */
.hero-window .mac-titlebar {
  height: calc(var(--win-radius) * 2);
  padding: 0 calc(var(--win-radius) - var(--tl-size) / 2);
  gap: 7px;
  background: var(--hw-titlebar);
}
.hero-window .mac-titlebar .tl {
  width: var(--tl-size);
  height: var(--tl-size);
  margin-right: 0;
}
/* 标题左对齐，紧跟红绿灯（真实窗口即为左对齐，非居中） */
.hero-window .mac-title {
  position: static;
  margin-left: 12px;
  text-align: left;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--win-text);
}
/* 「···」按钮：圆心与窗口右上角圆角的弧心重合（同心圆） */
.mac-more {
  position: absolute;
  top: var(--win-radius);
  right: var(--win-radius);
  transform: translate(50%, -50%);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  width: 24px; height: 24px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.05);
}
[data-theme="dark"] .mac-more { background: rgba(255, 255, 255, 0.08); }
@media (prefers-color-scheme: dark) {
  html:not([data-theme="light"]) .mac-more { background: rgba(255, 255, 255, 0.08); }
}
.mac-more i { width: 3px; height: 3px; border-radius: 50%; background: var(--win-muted); }

.hero-window-body { display: flex; gap: 10px; flex: 1; min-height: 0; padding: 10px; }

/* 双栏卡片：片段列表 / 内容编辑 */
.hw-pane {
  display: flex;
  flex-direction: column;
  min-width: 0;
  background: var(--card-bg);
  border: 1px solid var(--hw-card-border);
  border-radius: 8px;
}
.hw-list { width: 38%; flex: none; padding: 9px 10px; gap: 7px; }
.hw-editor { flex: 1; padding: 9px 10px; gap: 8px; }

.hw-pane-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  font-weight: 700;
  color: var(--win-text);
}
.hw-head-btns { display: inline-flex; align-items: center; gap: 11px; color: var(--win-muted); }
.hw-head-btns svg { width: 13px; height: 13px; }

.hw-search {
  display: flex;
  align-items: center;
  gap: 5px;
  background: var(--hw-chip);
  border-radius: 7px;
  padding: 5px 8px;
  color: var(--win-muted);
  font-size: 10.5px;
}
.hw-search-ic { width: 10px; height: 10px; flex: none; }

.hw-group-label { font-size: 9.5px; color: var(--win-muted); padding: 2px 2px 0; }

.hw-row {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 6px 7px;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  font-size: 11.5px;
}
.hw-doc {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 21px; height: 21px;
  flex: none;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.22);
}
.hw-doc svg { width: 12px; height: 12px; }
.hw-row-name { flex: 1; white-space: nowrap; overflow: hidden; }
.hw-row-time { font-size: 10px; color: rgba(255, 255, 255, 0.85); flex: none; }

.hw-title-field {
  flex: none;
  border: 1px solid var(--hw-card-border);
  border-radius: 7px;
  background: var(--hw-field);
  padding: 5px 9px;
  font-size: 11.5px;
  color: var(--win-text);
}
.hw-textarea {
  flex: 1;
  border-radius: 7px;
  background: var(--hw-inset);
  padding: 10px 12px;
  font-size: 12px;
  line-height: 1.65;
  color: var(--win-text);
  overflow: hidden;
}

.caret {
  display: inline-block;
  width: 1.5px;
  height: 1em;
  margin-left: 1px;
  vertical-align: -0.12em;
  background: var(--accent);
  animation: blink 1.05s steps(1) infinite;
}
.caret.dark { background: var(--win-text); }
@keyframes blink { 50% { opacity: 0; } }

/* 窗口底部：随手打 + 开始打字 */
.hw-bottom {
  flex: none;
  background: var(--hw-field);
  border-top: 1px solid var(--hw-card-border);
}
.hw-quick { padding: 8px 12px 7px; }
.hw-quick-label {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 10.5px;
  font-weight: 600;
  color: var(--win-text);
  margin-bottom: 7px;
}
.hw-quick-label svg { width: 11px; height: 11px; color: var(--win-muted); }
.hw-quick-row { display: flex; gap: 8px; }
.hw-quick-input {
  flex: 1;
  border: 1px solid var(--hw-card-border);
  border-radius: 7px;
  padding: 5px 9px;
  font-size: 10.5px;
  color: var(--win-muted);
  white-space: nowrap;
  overflow: hidden;
}
.hw-quick-send {
  flex: none;
  background: var(--hw-chip);
  border-radius: 7px;
  padding: 5px 14px;
  font-size: 10.5px;
  color: var(--win-text);
}
.hw-start {
  margin: 8px 12px 12px;
  padding: 8px 0;
  border-radius: 9px;
  background: var(--accent);
  color: #fff;
  text-align: center;
  font-size: 12px;
  font-weight: 600;
  box-shadow: 0 3px 10px rgba(0, 122, 255, 0.35);
}

/* ---------- 通用 Section ---------- */
.highlight { padding: 8rem 0; }
.highlight h2 { font-size: 3rem; font-weight: 600; }
.highlight > .container > p,
.highlight .content > p { line-height: 1.7; }

/* ---------- 核心功能（深色） ---------- */
.highlight--features {
  color: #fff;
  text-align: center;
  background: linear-gradient(to right, #0d1526 0%, #0f2b4d 50%, #0d1526 100%);
  position: relative;
  overflow: hidden;
}
.highlight--features::before {
  content: "";
  position: absolute; inset: 0;
  background:
    radial-gradient(560px 380px at 12% 8%, rgba(0, 122, 255, 0.14), transparent 65%),
    radial-gradient(420px 300px at 88% 90%, rgba(90, 200, 250, 0.1), transparent 65%);
  pointer-events: none;
}
.highlight--features > .container { position: relative; }
.highlight--features h2 { margin: 0.83rem 0; }
.highlight--features > .container > p {
  color: #c6cdd8;
  font-size: 1.2rem;
  margin: 3rem 10% 6rem 10%;
}

.highlight-features { margin-top: 4rem; text-align: left; }
.highlight-features .item {
  display: flex;
  align-items: center;
  gap: 3.5rem;
  padding: 2.5rem 0;
}
.highlight-features .item.reversed { flex-direction: row-reverse; }
.highlight-features .item .left { width: 35%; flex: none; }
.highlight-features .item .right { width: 65%; flex: 1; min-width: 0; }

.decoration-line {
  margin: 2rem 2px 1rem 2px;
  width: 50px; height: 3px;
  background: var(--accent);
  border-radius: 2px;
}
.item-name {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 1rem;
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  width: fit-content;
}
/* 三个小标题：各自的渐变（亮色系，保证深色底上可读） */
.name-1 { background-image: linear-gradient(90deg, #6FD3FF 0%, #0A84FF 90%); }
.name-2 { background-image: linear-gradient(90deg, #7DE3C8 0%, #2F9DC4 90%); }
.name-3 { background-image: linear-gradient(90deg, #B79CFF 0%, #F056A0 90%); }
.item-desc { color: #c6cdd8; line-height: 1.7; font-size: 1.02rem; }

.highlight-features .shot .mac-window {
  box-shadow: var(--shot-shadow);
  width: 100%;
}

/* 功能区内的窗口：文档样式 */
.doc-body { padding: 20px 24px 28px; background: var(--card-bg); flex: 1; }
.doc-text { font-size: 13px; margin: 0; line-height: 1.9; }
.doc-text.dim { color: var(--win-muted); font-size: 11px; margin-top: 14px; }
.typed-line { color: var(--accent); }

/* ---------- 功能区内的窗口：备忘录 ---------- */
.memo-window {
  --win-radius: 26px;
  background: var(--card-bg);
  aspect-ratio: 1.45 / 1;
}

/* ---------- 功能区内的窗口：设置窗口（高级 / 隐私） ---------- */
.settings-window {
  --win-radius: 26px;
  --tl-size: 13px;
  background: var(--card-bg);   /* 内容背景铺满窗口 */
  aspect-ratio: 1.18 / 1;       /* 两个设置窗口统一长宽比 */
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.settings-body {
  display: flex;
  flex: 1;
  min-height: 0;
  gap: 14px;
  padding: 14px;
}

/* 悬浮边栏：含交通灯 + 导航（交通灯在边栏内顶部） */
.set-side {
  width: 152px;
  flex: none;
  background: var(--win-side);
  border-radius: 14px;
  padding: 12px 10px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.set-lights {
  display: flex;
  gap: 7px;
  padding: 4px 4px 12px;
}
.set-lights .tl {
  width: var(--tl-size);
  height: var(--tl-size);
  border-radius: 50%;
  box-shadow: inset 0 0 0 0.5px rgba(0,0,0,0.08);
}
.set-lights .tl:nth-child(1) { background: #ff5f57; }
.set-lights .tl:nth-child(2) { background: #febc2e; }
.set-lights .tl:nth-child(3) { background: #28c840; }
.set-nav { display: flex; flex-direction: column; gap: 2px; }

.set-row {
  display: flex; align-items: center; gap: 8px;
  padding: 6px 9px;
  border-radius: 7px;
  font-size: 12px;
  color: var(--win-text);
  white-space: nowrap;
}
.set-row .ico {
  width: 16px; height: 16px; flex: none;
  display: flex; align-items: center; justify-content: center;
  color: var(--win-muted);
}
.set-row .ico svg { width: 16px; height: 16px; }
.set-row.active { background: var(--accent); color: #fff; }
.set-row.active .ico { color: #fff; }

/* 内容区：标题居左、靠边栏一侧 */
.set-detail {
  flex: 1; min-width: 0;
  display: flex; flex-direction: column; gap: 16px;
  padding-top: 6px;            /* 让标题与边栏交通灯大致对齐 */
  overflow: hidden;
}
.set-window-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--win-text);
  text-align: left;
  letter-spacing: 0.2px;
}
.set-content {
  flex: 1; min-height: 0;
  display: flex; flex-direction: column; gap: 18px;
}
.set-section { display: flex; flex-direction: column; gap: 6px; }
.set-section-title { font-size: 12.5px; font-weight: 700; color: var(--win-text); }
.set-desc { font-size: 11px; color: var(--win-muted); line-height: 1.5; }

/* 下拉菜单行 */
.dropdown-group {
  background: var(--nav-pill);
  border-radius: 10px;
  overflow: hidden;
}
.dropdown-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 13px;
  font-size: 12px;
}
.dropdown-row + .dropdown-row { border-top: 1px solid var(--hw-card-border); }
.dropdown-val { display: flex; align-items: center; gap: 6px; color: var(--win-muted); }
.dropdown-val .chev { width: 14px; height: 14px; opacity: 0.6; flex: none; }  /* 菜单展开：下箭头 */

/* 滑块行 */
.slider-row { display: flex; align-items: center; gap: 10px; padding: 8px 13px; font-size: 12px; border-bottom: 1px solid var(--hw-card-border); }  /* 左右留 13px，避免贴边；行与行之间加分隔线 */
.slider-row .lbl { width: 110px; flex: none; }
.slider-row .val { min-width: 64px; text-align: right; color: var(--win-muted); font-variant-numeric: tabular-nums; }
.slider { flex: 1; height: 4px; border-radius: 2px; background: var(--hw-inset); position: relative; }
.slider i { position: absolute; left: 0; top: 0; bottom: 0; background: var(--accent); border-radius: 2px; }
.slider i::after {
  content: ""; position: absolute; right: -9px; top: 50%; transform: translateY(-50%);
  width: 18px; height: 14px; border-radius: 7px;   /* 药丸形把手（贴合原版） */
  background: var(--slider-thumb);
  box-shadow: 0 2px 5px rgba(0,0,0,0.28);
}
.set-section .set-desc { margin-top: 10px; }   /* 说明文本与上方滑块卡片保持距离 */

/* 忽略应用列表 */
.app-list-card { background: var(--nav-pill); border-radius: 10px; overflow: hidden; }
.app-list-head {
  padding: 10px 13px;
  font-size: 11px;
  color: var(--win-muted);
  border-bottom: 1px solid var(--hw-card-border);
}
.app-row {
  display: flex; align-items: center; gap: 9px;
  padding: 9px 13px;
  font-size: 12px;
  border-bottom: 1px solid var(--hw-card-border);
}
.app-ic { width: 20px; height: 20px; flex: none; border-radius: 5px; display: flex; align-items: center; justify-content: center; }
.app-ic svg { width: 14px; height: 14px; display: block; }
.app-ic.a1 { background: linear-gradient(140deg, #34d058, #1aa64b); }   /* 微信 绿 */
.app-ic.a2 { background: linear-gradient(140deg, #4a90e2, #2f6fd0); }   /* 1Password 蓝 */
.app-ic.a3 { background: linear-gradient(140deg, #5a5f6a, #34373f); }   /* 终端 深 */
.app-toolbar {
  display: flex; align-items: center; gap: 4px;
  padding: 5px 13px;
}
.app-toolbar .tbtn {
  width: 22px; height: 22px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 5px;
  font-size: 14px; font-weight: 500; line-height: 1;
  color: var(--win-text);
  background: var(--card-bg);
  border: 1px solid var(--hw-card-border);
}
.app-toolbar .tsep { width: 1px; height: 14px; background: var(--hw-card-border); margin: 0 2px; }

/* 更多功能（两列） */
.more-features { padding-top: 4rem; text-align: center; }
.more-features h4 { font-size: 1.5rem; margin-bottom: 3rem; font-weight: 600; }
.more-features .features { display: flex; justify-content: center; }
.more-features .fcol {
  width: 50%;
  padding: 0 1rem;
  font-size: 1.35rem;
  font-weight: 700;
  line-height: 2.1;
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}
/* 两列内容：以中线为轴对称的横向渐变 */
.fcol-l {
  text-align: right;
  background-image: linear-gradient(90deg, #7D8BF3 0%, #0A84FF 45%, #5AC8FA 100%);
  background-position: right;
}
.fcol-r {
  text-align: left;
  background-image: linear-gradient(90deg, #5AC8FA 0%, #0A84FF 55%, #7D8BF3 100%);
  background-position: left;
}

.pill-link {
  display: inline-block;
  margin-top: 2.5rem;
  padding: 0.75rem 2rem;
  font-weight: 500;
  border-radius: 2.25rem;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}
.pill-link:hover { text-decoration: none; transform: translateY(-1px); }
/* 防止全局 a:hover 颜色把按钮文字染成同底色 */
.light-pill:hover { color: #0d1526; }
.ghost-pill:hover { color: #fff; }
.light-pill { background: #fff; color: #0d1526; }
.light-pill:hover { box-shadow: 0 6px 20px rgba(0,0,0,0.3); }
.ghost-pill {
  background: var(--dl-btn-bg); color: #fff;
  display: inline-flex; align-items: center; gap: 0.5rem;
}
.ghost-pill:hover { background: var(--accent-deep); box-shadow: 0 6px 18px rgba(0,122,255,0.35); }
.line-pill {
  display: inline-flex; align-items: center; gap: 0.5rem;
  color: var(--text);
  border: 1px solid var(--text);
}
.line-pill:hover { background: var(--accent-soft); border-color: var(--accent); color: var(--accent-deep); }
.pill-link .fa { margin-left: 0.35rem; }

/* ---------- 使用场景（蓝色渐变） ---------- */
.highlight--scenarios {
  text-align: left;
  color: #fff;
  background: linear-gradient(154deg, #05264d 0%, #0b66c3 62%, #2f9dc4 100%);
  position: relative;
  overflow: hidden;
}
.highlight--scenarios::before {
  content: "";
  position: absolute; inset: 0;
  background: radial-gradient(640px 420px at 88% 12%, rgba(255,255,255,0.08), transparent 60%);
  pointer-events: none;
}
.highlight--scenarios > .container { position: relative; }
.highlight--scenarios h2 { margin: 0.83rem 0; }
.highlight--scenarios .content > p {
  font-size: 1.2rem;
  margin: 2.5rem 30% 3rem 0;
  color: rgba(255,255,255,0.92);
  line-height: 1.7;
}
.cards { display: flex; flex-wrap: wrap; gap: 1rem; margin-bottom: 3rem; }
.card {
  flex: 1 1 220px;
  max-width: 260px;
  background: #fff;
  color: #495057;
  border-radius: 8px;
  box-shadow: 0 0 8px rgba(0, 0, 0, 0.25);
  padding: 1.1rem 1.2rem;
  text-align: center;
  font-size: 92%;
  line-height: 1.55;
}
.card-ic { color: #343a40; padding: 0.4rem 0 0.9rem; }
.card-ic svg { width: 2.2rem; height: 2.2rem; }
.card-text { padding-top: 0.7rem; border-top: 1px solid #dee2e6; }
.sc-link {
  display: inline-flex; align-items: center; gap: 0.4rem;
  color: #fff; font-weight: 500; font-size: 1.05rem;
}
.sc-link:hover { color: #fff; text-decoration: underline; }
.sc-link .arrow { font-size: 1.3em; line-height: 1; }

/* ---------- 下载区 ---------- */
.highlight--download {
  text-align: right;
  color: var(--text);
  background: linear-gradient(140deg, rgba(0,122,255,0.08) 0%, rgba(90,200,250,0.14) 100%);
  position: relative;
  overflow: hidden;
}
[data-theme="dark"] .highlight--download {
  background: linear-gradient(140deg, rgba(0,122,255,0.12) 0%, rgba(56,67,143,0.22) 100%);
}
@media (prefers-color-scheme: dark) {
  html:not([data-theme="light"]) .highlight--download {
    background: linear-gradient(140deg, rgba(0,122,255,0.12) 0%, rgba(56,67,143,0.22) 100%);
  }
}
.highlight--download h2 { text-align: center; margin-bottom: 2.5rem; }
.dl-cols { display: flex; gap: 4rem; text-align: left; }
.dl-cols .col { flex: 1; }
.dl-cols p { font-size: 1.15rem; line-height: 1.7; color: var(--text-soft); }
.dl-cols strong { color: var(--text); }
.highlight--download .container { position: relative; }

/* Gatekeeper 提示框 */
.tip {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  margin: 0.5rem 0 0;
  padding: 0.9rem 1.1rem;
  border-radius: 12px;
  background: var(--accent-soft);
  border: 1px solid rgba(0, 122, 255, 0.28);
  text-align: left;
}
.tip .ic { flex: none; width: 1.15rem; height: 1.15rem; margin-top: 0.2rem; color: var(--accent); }
.tip p { margin: 0; font-size: 0.95rem; line-height: 1.7; color: var(--text-soft); }
.tip code { white-space: nowrap; }
.tip strong { color: var(--accent-deep); }
[data-theme="dark"] .tip strong { color: #6db3ff; }
@media (prefers-color-scheme: dark) {
  html:not([data-theme="light"]) .tip strong { color: #6db3ff; }
}

/* ---------- 开源区（暖色，对应 iina.io 的 Swift 区） ---------- */
.highlight--opensource {
  position: relative;
  overflow: hidden;
  text-align: right;
  background: linear-gradient(140deg, #FFEFEF 0%, #FFC084 100%);
  color: #2b1d10;
}
[data-theme="dark"] .highlight--opensource {
  background: linear-gradient(140deg, #2a201a 0%, #3a2a1a 100%);
  color: #ece2d4;
}
@media (prefers-color-scheme: dark) {
  html:not([data-theme="light"]) .highlight--opensource {
    background: linear-gradient(140deg, #2a201a 0%, #3a2a1a 100%);
    color: #ece2d4;
  }
}
.highlight--opensource h2 { margin-bottom: 2.5rem; }
.highlight--opensource .container { position: relative; }
/* 背景 Swift logo（iina.io 同款：自然大尺寸，仅尾部微微出血于左缘，文字叠于其上） */
.highlight--opensource .os-ghost {
  position: absolute;
  left: -4%;
  top: 50%;
  transform: translateY(-50%);
  opacity: 0.5;
  pointer-events: none;
}
.os-ghost img { width: 600px; height: auto; display: block; }
/* 文字层级高于背景图样（iina.io 同款做法：content 相对定位后覆盖在 logo 之上） */
.highlight--opensource .content { position: relative; }
[data-theme="dark"] .highlight--opensource .os-ghost { opacity: 0.4; }
@media (prefers-color-scheme: dark) {
  html:not([data-theme="light"]) .highlight--opensource .os-ghost { opacity: 0.4; }
}
@media (max-width: 767px) {
  .os-ghost img { width: 300px; }
}
@media (min-width: 992px) {
  .highlight--opensource .os-cols { padding-left: 24%; }
}
.os-cols { display: flex; gap: 4rem; text-align: left; }
.os-cols .col { flex: 1; }
.os-cols p { font-size: 1.15rem; line-height: 1.7; color: var(--text-soft); }

/* ---------- 页脚 ---------- */
footer {
  background: var(--footer-bg);
  color: var(--footer-text);
  padding: 2rem 0;
  font-size: 0.9rem;
}
footer a { color: var(--footer-strong); }
footer a:hover, footer a:active { color: #fff; }
footer .contact { display: flex; justify-content: space-between; align-items: baseline; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 0.75rem; }
footer .sep { margin: 0 0.35rem; opacity: 0.6; }
footer hr { margin: 1rem 0; border: 0; border-top: 1px solid var(--footer-line); }
footer .fineprint { color: var(--footer-text); opacity: 0.75; font-size: 0.8rem; }

/* ---------- 响应式 ---------- */
@media (max-width: 991px) {
  .hero-shot { display: none; }
  .hero { padding: 9rem 0 7rem 0; }
  .headline { font-size: 3.2rem; }
  .highlight { padding: 6rem 0; }
  .highlight h2 { font-size: 2.4rem; }
  .highlight--features > .container > p { margin: 2.5rem 0 3rem 0; }
}

@media (max-width: 767px) {
  #header .nav-link { padding: 0.25rem 0.6rem; font-size: 0.9rem; }
  #header .nav-link.stressed.left { margin-left: 0.5rem; }
  .navbar-nav li:first-child, .navbar-nav li:nth-child(2) { display: none; }
  .headline { font-size: 2.6rem; }
  .sub-headline { font-size: 1.3rem; }
  .product-pr { flex-direction: column; align-items: flex-start; gap: 0.25rem; }
  .product-pr .pr-links { margin-left: 0; }
  .dl-btn { display: flex; justify-content: center; }
  .dl-btn:not(:last-child) { margin-right: 0; }
  .highlight-features .item,
  .highlight-features .item.reversed { display: block; padding: 2rem 0; }
  .highlight-features .item .left,
  .highlight-features .item .right { width: 100%; }
  .highlight-features .item:not(.reversed) .left { margin-bottom: 1.75rem; }
  .highlight-features .item.reversed .right { margin-bottom: 1.75rem; }
  .item-name { font-size: 1.6rem; }
  .more-features .features { flex-direction: column; }
  .more-features .fcol { width: 100%; text-align: center !important; line-height: 2; }
  .highlight--scenarios .content > p { margin-right: 0; }
  .cards { flex-direction: column; }
  .card { max-width: none; }
  .dl-cols, .os-cols { flex-direction: column; gap: 2rem; }
  .highlight--download, .highlight--opensource { text-align: left; }
  .os-ghost { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .caret { animation: none; }
  .dl-btn, .pill-link { transition: none; }
}
