/* ============================================================
 * 公开 HOME（spec 20260815-usercenter-public-home · R2.8）
 * 访客门面专用样式；令牌全部来自 main.css 设计体系。
 * 硬阶梯（tests/test_design_tokens_lint.py）：
 * - 字号只走 12/13/14/16/20/28（hero 用 --fs-display=28px，非设计稿 40px）；
 * - 字重 ≤600；禁渐变（设计稿转化带渐变改纯色 var(--brand)）；
 * - 色值只用令牌 / 白名单；z-index 无需新层级。
 * ============================================================ */

/* 全宽画布：base.html main 的 container-fluid 由 main_class 块换成 ph-main */
.ph-main { padding: 0; margin: 0; width: 100%; }
.ph-wrap { width: min(100%, 1160px); margin: 0 auto; padding: 0 24px; }

/* ---------- 通用 ---------- */
.ph-block { padding: 52px 0; }
.ph-block--tight { padding-top: 0; }
.ph-sec-head { max-width: 640px; margin-bottom: 26px; }
.ph-sec-head p { margin: 8px 0 0; color: var(--ink-secondary); }
.ph-sec-kicker { color: var(--brand-dark); font-size: 13px; font-weight: 600; letter-spacing: .5px; }
.ph-sec-title { margin: 6px 0 0; font-size: 20px; font-weight: 600; letter-spacing: -.3px; color: var(--ink); }

.ph-btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    min-height: 42px; padding: 0 22px;
    border: 1px solid transparent; border-radius: var(--radius);
    font-size: 14px; font-weight: 600; white-space: nowrap;
    text-decoration: none; cursor: pointer;
    transition: background var(--dur-fast), color var(--dur-fast), border-color var(--dur-fast);
}
.ph-btn:hover { text-decoration: none; }
.ph-btn--primary { background: var(--brand); color: #fff; }
.ph-btn--primary:hover { background: var(--brand-hover); color: #fff; }
.ph-btn--soft { background: var(--brand-soft); border-color: var(--brand-line); color: var(--brand-heavy); }
.ph-btn--soft:hover { background: var(--brand-soft-strong); color: var(--brand-heavy); }
.ph-btn--outline { background: var(--surface); border-color: var(--border); color: var(--ink-secondary); font-weight: 500; }
.ph-btn--outline:hover { border-color: var(--brand); color: var(--brand-dark); }
.ph-btn--white { margin-top: 22px; background: #fff; color: var(--brand-heavy); border-color: #fff; }
.ph-btn--white:hover { background: var(--brand-soft); color: var(--brand-heavy); }

/* ---------- Hero（R2.1；设计稿渐变底按硬阶梯改纯色 brand-soft） ---------- */
.ph-hero { background: var(--brand-soft); border-bottom: 1px solid var(--line); }
.ph-hero-grid {
    display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
    gap: 40px; align-items: center; padding: 56px 0 48px;
}
.ph-kicker {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 4px 14px; border: 1px solid var(--brand-line);
    border-radius: var(--radius-pill); background: var(--surface);
    color: var(--brand-heavy); font-size: 13px; font-weight: 600;
}
.ph-hero-title { margin: 18px 0 0; font-size: 28px; font-weight: 600; line-height: 1.3; letter-spacing: -.5px; color: var(--ink); }
.ph-hero-title em { font-style: normal; color: var(--brand-dark); }
.ph-hero-sub { margin: 14px 0 0; max-width: 560px; color: var(--ink-secondary); font-size: 16px; line-height: 1.75; }
.ph-hero-sub b { color: var(--ink); font-weight: 600; }
.ph-hero-ctas { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.ph-hero-facts { display: flex; flex-wrap: wrap; gap: 8px 20px; margin-top: 20px; color: var(--muted); font-size: 13px; }
.ph-hero-facts span { display: inline-flex; align-items: center; gap: 6px; }
.ph-dot { width: 5px; height: 5px; border-radius: 50%; background: var(--brand); flex-shrink: 0; }

/* 账户示意卡（右栏视觉，不是真实数据） */
.ph-acct-card {
    border: 1px solid var(--line); border-radius: var(--radius-lg);
    background: var(--surface); box-shadow: var(--shadow-md);
    padding: 20px; max-width: 400px; margin-left: auto;
}
.ph-acct-head { display: flex; align-items: center; gap: 10px; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.ph-acct-avatar {
    display: inline-grid; width: 38px; height: 38px; place-items: center;
    border-radius: 50%; background: var(--brand-soft); color: var(--brand-heavy);
    border: 1px solid var(--brand-line);
}
.ph-acct-head b { display: block; font-size: 14px; color: var(--ink); }
.ph-acct-head small { color: var(--muted); font-size: 12px; }
.ph-acct-pill {
    margin-left: auto; padding: 1px 10px; border-radius: var(--radius-pill);
    background: var(--surface-soft); color: var(--ink-secondary); font-size: 12px; font-weight: 500;
}
.ph-acct-rows { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; padding: 14px 0; }
.ph-acct-cell { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface-soft); padding: 10px 12px; }
.ph-acct-cell small { display: block; color: var(--muted); font-size: 12px; }
.ph-acct-cell b { display: block; margin-top: 2px; font-size: 16px; letter-spacing: .5px; color: var(--ink); }
.ph-acct-cell b.ph-brandnum { color: var(--brand-dark); }
.ph-acct-note { margin: 0; color: var(--muted); font-size: 12px; }
.ph-acct-note a { color: var(--brand-dark); font-weight: 500; text-decoration: none; }

/* ---------- 三词模型（R2.2） ---------- */
.ph-trio { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.ph-trio-card {
    display: flex; flex-direction: column; gap: 10px;
    border: 1px solid var(--line); border-radius: var(--radius-lg);
    background: var(--surface); padding: 22px;
    transition: box-shadow var(--dur-fast), border-color var(--dur-fast);
}
.ph-trio-card:hover { border-color: var(--brand-line); box-shadow: var(--shadow-md); }
.ph-trio-ic {
    display: inline-grid; width: 40px; height: 40px; place-items: center;
    border-radius: var(--radius); background: var(--brand-soft);
    color: var(--brand-dark); border: 1px solid var(--brand-line);
}
.ph-trio-ic svg { width: 20px; height: 20px; }
.ph-trio-title { margin: 0; font-size: 16px; font-weight: 600; color: var(--ink); }
.ph-trio-title small { margin-left: 8px; color: var(--muted); font-size: 12px; font-weight: 500; }
.ph-trio-card p { margin: 0; color: var(--ink-secondary); flex: 1; }
.ph-trio-link { color: var(--brand-dark); font-weight: 600; font-size: 14px; text-decoration: none; }
.ph-trio-link:hover { color: var(--brand-heavy); }
.ph-trio-foot { margin: 14px 0 0; color: var(--muted); font-size: 13px; }
.ph-trio-foot a { color: var(--brand-dark); font-weight: 500; text-decoration: none; }

/* ---------- 去干活（R2.3） ---------- */
.ph-go { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.ph-go-card {
    position: relative; display: flex; flex-direction: column; gap: 8px;
    border: 1px solid var(--line); border-radius: var(--radius-lg);
    background: var(--surface); padding: 22px;
    color: inherit; text-decoration: none;
    transition: box-shadow var(--dur-fast), border-color var(--dur-fast);
}
.ph-go-card:hover { border-color: var(--brand-line); box-shadow: var(--shadow-md); color: inherit; text-decoration: none; }
.ph-go-meta { color: var(--muted); font-size: 12px; font-weight: 600; letter-spacing: .5px; }
.ph-go-title { margin: 0; font-size: 16px; font-weight: 600; color: var(--ink); }
.ph-go-card p { margin: 0; color: var(--ink-secondary); flex: 1; }
.ph-go-cta { color: var(--brand-dark); font-weight: 600; font-size: 14px; }
.ph-go-ext { position: absolute; top: 18px; right: 18px; color: var(--muted); font-size: 13px; }
.ph-go-note { margin: 14px 0 0; color: var(--muted); font-size: 13px; }

/* ---------- 转化带（R2.4：纯色品牌底，无价格数字） ---------- */
.ph-convert {
    border-radius: var(--radius-lg);
    background: var(--brand);
    color: #fff; padding: 36px 40px;
    display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 32px; align-items: center;
}
.ph-convert-title { margin: 0; font-size: 20px; font-weight: 600; letter-spacing: -.3px; color: #fff; }
.ph-convert p { margin: 10px 0 0; color: rgba(255, 255, 255, .85); max-width: 460px; }
.ph-plan-mini { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.ph-plan-card {
    border: 1px solid rgba(255, 255, 255, .35); border-radius: var(--radius);
    background: rgba(255, 255, 255, .12); padding: 16px 18px;
}
.ph-plan-card b { display: block; font-size: 14px; font-weight: 600; }
.ph-plan-price { display: block; margin-top: 6px; font-size: 20px; font-weight: 600; letter-spacing: .5px; }
.ph-plan-price small { font-size: 12px; font-weight: 400; color: rgba(255, 255, 255, .8); margin-left: 6px; }
.ph-plan-terms { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.ph-plan-terms span {
    padding: 1px 8px; border-radius: var(--radius-pill);
    background: rgba(255, 255, 255, .16); font-size: 12px;
}
.ph-plan-note { grid-column: 1 / -1; margin: 0; color: rgba(255, 255, 255, .8); font-size: 12px; }

/* ---------- FAQ（R2.6） ---------- */
.ph-faq-list { display: grid; gap: 10px; max-width: 840px; }
.ph-faq {
    border: 1px solid var(--line); border-radius: var(--radius);
    background: var(--surface); overflow: hidden;
}
.ph-faq[open] { border-color: var(--brand-line); }
.ph-faq summary {
    display: flex; align-items: center; gap: 10px;
    padding: 14px 18px; font-weight: 600; font-size: 14px; color: var(--ink);
    list-style: none; cursor: pointer;
}
.ph-faq summary::-webkit-details-marker { display: none; }
.ph-faq summary::after {
    content: "+"; margin-left: auto; color: var(--muted);
    font-size: 16px; font-weight: 400; line-height: 1;
}
.ph-faq[open] summary::after { content: "−"; color: var(--brand-dark); }
.ph-faq summary:hover { background: var(--surface-soft); }
.ph-faq-a { padding: 0 18px 16px 18px; color: var(--ink-secondary); }
.ph-faq-a a { color: var(--brand-dark); font-weight: 500; text-decoration: none; }

/* ---------- 页脚（R2.7） ---------- */
.ph-footer {
    margin-top: 20px; border-top: 1px solid var(--line);
    background: var(--surface); padding: 40px 0 28px;
}
.ph-foot-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 28px; }
.ph-foot-brand p { margin: 10px 0 0; color: var(--muted); font-size: 13px; max-width: 300px; }
.ph-foot-brand-link {
    display: inline-flex; align-items: center; gap: 8px;
    color: var(--ink); font-size: 16px; font-weight: 600; text-decoration: none;
}
.ph-foot-brand-link:hover { color: var(--ink); text-decoration: none; }
.ph-foot-mark {
    display: inline-grid; width: 26px; height: 26px; place-items: center;
    border-radius: 50%; background: var(--brand); color: #fff; font-size: 13px; line-height: 1;
}
.ph-foot-col b { display: block; margin-bottom: 10px; font-size: 13px; font-weight: 600; color: var(--ink); }
.ph-foot-col a { display: block; padding: 3px 0; color: var(--ink-secondary); font-size: 13px; text-decoration: none; }
.ph-foot-col a:hover { color: var(--brand-dark); }
.ph-foot-bottom {
    display: flex; flex-wrap: wrap; gap: 8px 20px; justify-content: space-between;
    margin-top: 28px; padding-top: 16px; border-top: 1px solid var(--line);
    color: var(--muted); font-size: 12px;
}
.ph-foot-bottom a { color: var(--muted); text-decoration: none; }
.ph-foot-bottom a:hover { color: var(--ink-secondary); }
.ph-beian-ic { display: inline-block; vertical-align: middle; margin-right: 6px; }

/* ---------- 响应式 ---------- */
@media (max-width: 960px) {
    .ph-hero-grid { grid-template-columns: 1fr; gap: 28px; padding: 40px 0 36px; }
    .ph-acct-card { margin-left: 0; }
    .ph-trio, .ph-go { grid-template-columns: 1fr; }
    .ph-convert { grid-template-columns: 1fr; padding: 28px 24px; }
    .ph-foot-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
    .ph-foot-grid { grid-template-columns: 1fr; }
    .ph-plan-mini { grid-template-columns: 1fr; }
}
