/* Hallmark · genre: editorial · macrostructure: workbench · theme: custom (Avanti paper) · nav: N1a · footer: Ft1 */
:root {
    --paper: #F3EEE4;
    --paper-deep: #EAE4D6;
    --ink: #1B1A20;
    --muted: #6A665E;
    --rule: rgba(27, 26, 32, 0.13);
    --indigo: #5F54F3;
    --green: #6E9E7C;
    --coral: #E07A5F;
    --pink: #F2C4B3;
    --night: #15151A;
    --wrap: 1160px;
    --gutter: clamp(20px, 5vw, 48px);
    --radius: clamp(24px, 3.4vw, 40px);
    --sans: -apple-system, BlinkMacSystemFont, "SF Pro Display", "PingFang SC", "Helvetica Neue", "Noto Sans SC", "Microsoft YaHei", "Segoe UI", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
    margin: 0;
    background: var(--paper);
    color: var(--ink);
    font-family: var(--sans);
    font-size: 17px;
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

h1, h2, h3, p, ul, dl, dd, figure { margin: 0; }
ul { padding: 0; list-style: none; }
a { color: inherit; }
img { display: block; max-width: 100%; }
button { font: inherit; color: inherit; }

:focus-visible { outline: 2px solid var(--indigo); outline-offset: 3px; border-radius: 6px; }

.wrap {
    max-width: calc(var(--wrap) + var(--gutter) * 2);
    margin-inline: auto;
    padding-inline: var(--gutter);
}

/* ---------- Type ---------- */
h1 {
    font-size: clamp(2.7rem, 6.4vw, 5.25rem);
    font-weight: 700;
    line-height: 1.14;
    letter-spacing: -0.01em;
}
h2 {
    font-size: clamp(1.95rem, 4vw, 3.2rem);
    font-weight: 700;
    line-height: 1.18;
    letter-spacing: -0.005em;
    text-wrap: balance;
}
html[lang="zh-Hans"] h2, html[lang="zh-Hans"] .lede { word-break: keep-all; overflow-wrap: anywhere; text-wrap: wrap; }
html[lang="en"] h1 { letter-spacing: -0.035em; line-height: 1.04; }
html[lang="en"] h2 { letter-spacing: -0.028em; line-height: 1.08; }

.lede {
    margin-top: 0.7em;
    font-size: clamp(1.1rem, 1.7vw, 1.35rem);
    line-height: 1.5;
    color: var(--muted);
    text-wrap: balance;
}
.eyebrow {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 18px;
    font-size: 0.82rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--muted);
}
.pro {
    padding: 1px 8px;
    border: 1px solid currentColor;
    border-radius: 99px;
    font-size: 0.7rem;
    letter-spacing: 0.06em;
}
.body { margin-top: 1.4em; max-width: 34em; }

/* ---------- Nav ---------- */
.nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding-block: 22px;
}
.brand {
    display: flex;
    align-items: center;
    gap: 11px;
    font-weight: 700;
    font-size: 1.05rem;
    text-decoration: none;
    white-space: nowrap;
}
.brand i { font-style: normal; font-weight: 500; color: var(--muted); }
main { overflow-x: clip; }
.brand img { width: 34px; height: 34px; border-radius: 8px; }
.nav-links {
    display: flex;
    align-items: center;
    gap: clamp(14px, 2.4vw, 30px);
    font-size: 0.95rem;
}
.nav-links a { text-decoration: none; }
.nav-links a:not(.lang):not(.get) { color: var(--muted); }
.nav-links a { transition: color 0.15s; }
.nav-links a:hover { color: var(--ink); }
.lang {
    padding: 6px 12px;
    border: 1px solid var(--rule);
    border-radius: 99px;
    background: none;
    font-size: 0.85rem;
    color: var(--ink);
    transition: border-color 0.15s;
}
.lang:hover { border-color: var(--ink); }
.nav-links .get {
    padding: 7px 16px;
    border-radius: 99px;
    background: var(--ink);
    color: var(--paper);
    font-weight: 600;
}
.nav-links .get:hover { color: var(--paper); background: var(--indigo); }

/* ---------- Phone ---------- */
.phone {
    --w: 270px;
    position: relative;
    flex: none;
    width: var(--w);
    padding: calc(var(--w) * 0.032);
    border-radius: calc(var(--w) * 0.17);
    background: #0D0D11;
    box-shadow:
        inset 0 0 0 1.5px #77747F,
        0 34px 60px -28px rgba(27, 26, 32, 0.45),
        0 10px 22px -12px rgba(27, 26, 32, 0.25);
}
.phone img {
    width: 100%;
    height: auto;
    aspect-ratio: 1320 / 2868;
    border-radius: calc(var(--w) * 0.14);
    background: #F2F2F7;
}
.phone::after {
    content: "";
    position: absolute;
    top: calc(var(--w) * 0.08);
    left: 50%;
    width: calc(var(--w) * 0.29);
    height: calc(var(--w) * 0.085);
    border-radius: 99px;
    background: #0D0D11;
    transform: translateX(-50%);
}

/* ---------- Hero ---------- */
.hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.02fr);
    align-items: center;
    gap: clamp(24px, 4vw, 56px);
    padding-block: clamp(28px, 5vw, 64px) clamp(56px, 8vw, 110px);
}
.hero .lede { color: var(--ink); font-weight: 600; font-size: clamp(1.25rem, 2.1vw, 1.6rem); margin-top: 1em; }
.hero-sub { margin-top: 0.9em; max-width: 30em; color: var(--muted); }
.cta { display: flex; align-items: center; flex-wrap: wrap; gap: 14px 20px; margin-top: 32px; }
.badge { display: inline-block; border-radius: 10px; transition: transform 0.2s ease; }
.badge:hover { transform: translateY(-2px); }
.badge img { height: 54px; width: auto; }
.cta small { font-size: 0.9rem; color: var(--muted); }

.fan {
    position: relative;
    display: flex;
    justify-content: center;
    padding-block: 20px;
}
.fan .phone { --w: clamp(200px, 23vw, 290px); }
.fan .side {
    position: absolute;
    top: 12%;
    --w: clamp(170px, 19.5vw, 246px);
}
.fan .side.l { right: 50%; margin-right: calc(var(--w) * 0.34); transform: rotate(-7deg); }
.fan .side.r { left: 50%; margin-left: calc(var(--w) * 0.34); transform: rotate(7deg); }
.fan .front { z-index: 1; }

/* ---------- Sections ---------- */
section { padding-block: clamp(36px, 5.5vw, 72px); }
.split {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    align-items: center;
    gap: clamp(32px, 6vw, 88px);
}
.split .media { display: flex; justify-content: center; }
.split.flip .media { order: -1; }

.panel {
    border-radius: var(--radius);
    padding: clamp(28px, 5.4vw, 76px);
    overflow: hidden;
}
.panel.indigo { background: var(--indigo); color: #fff; }
.panel.green { background: var(--green); color: #fff; }
.panel.coral { background: var(--coral); color: #fff; }
.panel.pink { background: var(--pink); }
.panel.night { background: var(--night); color: #F3EEE4; }
.panel.indigo .lede, .panel.green .lede, .panel.coral .lede, .panel.indigo .eyebrow,
.panel.green .eyebrow, .panel.coral .eyebrow { color: rgba(255, 255, 255, 0.82); }
.panel.night .lede, .panel.night .eyebrow { color: rgba(243, 238, 228, 0.62); }
.panel.pink .lede, .panel.pink .eyebrow { color: rgba(27, 26, 32, 0.66); }

.points { margin-top: 30px; border-top: 1px solid var(--rule); }
.points li {
    display: grid;
    grid-template-columns: 6.2em 1fr;
    gap: 14px;
    padding-block: 14px;
    border-bottom: 1px solid var(--rule);
}
.points b { font-weight: 600; }
.points span { color: var(--muted); }
html[lang="en"] .points li { grid-template-columns: 7.5em 1fr; }
.panel .points, .panel .points li { border-color: rgba(255, 255, 255, 0.24); }
.panel .points span { color: inherit; opacity: 0.8; }
.panel.pink .points, .panel.pink .points li { border-color: rgba(27, 26, 32, 0.16); }

.duo { display: flex; justify-content: center; align-items: flex-start; }
.duo .phone { --w: clamp(170px, 20vw, 250px); }
.duo .phone + .phone { margin-left: calc(var(--w) * -0.3); margin-top: calc(var(--w) * 0.26); z-index: 1; }

/* ---------- Recurring demo ---------- */
.demo {
    margin-top: 34px;
    padding: 22px 24px 20px;
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.14);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.2);
}
.demo-head { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; }
.demo-title { font-weight: 600; }
.seg { display: inline-flex; padding: 3px; border-radius: 99px; background: rgba(21, 21, 26, 0.22); }
.seg button {
    padding: 6px 14px;
    border: 0;
    border-radius: 99px;
    background: none;
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.88rem;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
}
.seg button[aria-pressed="true"] { background: #fff; color: var(--indigo); font-weight: 600; }
.track { position: relative; height: 104px; margin: 18px 8px 4px; }
.track::before {
    content: "";
    position: absolute;
    inset: 50% 0 auto 0;
    height: 2px;
    background: rgba(255, 255, 255, 0.35);
    transform: translateY(-50%);
}
.span-bar {
    position: absolute;
    top: 50%;
    left: 0;
    width: 78%;
    height: 2px;
    background: #fff;
    transform: translateY(-50%);
    transition: left 0.45s cubic-bezier(0.3, 0.7, 0.2, 1);
}
.mark {
    position: absolute;
    top: 50%;
    width: 14px;
    height: 14px;
    margin: -7px 0 0 -7px;
    border-radius: 50%;
    background: var(--indigo);
    box-shadow: inset 0 0 0 2px #fff;
    transition: left 0.45s cubic-bezier(0.3, 0.7, 0.2, 1);
}
.mark.done, .mark.next { background: #fff; }
.mark em {
    position: absolute;
    left: 50%;
    font-style: normal;
    font-size: 0.82rem;
    line-height: 1.3;
    white-space: nowrap;
    opacity: 0.85;
}
.mark em b { display: block; font-size: 0.98rem; opacity: 1; }
.mark.due { left: 0; }
.mark.due em { top: 20px; left: -7px; }
.mark.done { left: 22%; }
.mark.done em { bottom: 20px; left: -7px; }
.mark.next { left: 78%; }
.mark.next em { top: 20px; left: auto; right: -7px; text-align: right; }
.demo[data-mode="after"] .mark.next { left: 100%; }
.demo[data-mode="after"] .span-bar { left: 22%; }
.demo .a, .demo[data-mode="after"] .f { display: none; }
.demo[data-mode="after"] .a { display: block; }
.demo-note { margin-top: 6px; font-size: 0.93rem; line-height: 1.55; opacity: 0.9; min-height: 3.1em; }

/* ---------- Habits pair ---------- */
.pair { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(14px, 2vw, 24px); }
.pair .panel { padding-bottom: 0; display: flex; flex-direction: column; }
.pair h2 { font-size: clamp(1.8rem, 3.1vw, 2.6rem); }
.pair .lede { margin-bottom: clamp(28px, 4vw, 48px); }
.peek { --pw: clamp(160px, 17vw, 224px); margin-top: auto; height: calc(var(--pw) * 1.85); }
.peek .phone { --w: var(--pw); }

/* ---------- Widgets ---------- */
.widgets { display: grid; gap: 22px; width: min(100%, 400px); }
.widgets img {
    width: 100%;
    height: auto;
    border-radius: 7.6% / 16.1%;
    box-shadow: 0 18px 30px -14px rgba(27, 26, 32, 0.22);
}

/* ---------- Privacy ---------- */
.night h2 { font-size: clamp(2.3rem, 5.4vw, 4.4rem); }
.night .points, .night .points li { border-color: rgba(243, 238, 228, 0.16); }

/* ---------- Pricing ---------- */
.plans { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(28px, 6vw, 88px); margin-top: clamp(28px, 4vw, 48px); }
.plan { border-top: 2px solid var(--ink); padding-top: 20px; }
.plan h3 { font-size: 1.5rem; font-weight: 700; }
.plan h3 span { color: var(--indigo); }
.plan > p { margin-top: 4px; color: var(--muted); }
.plan ul { margin-top: 18px; }
.plan li { padding-block: 11px; border-top: 1px solid var(--rule); }

/* ---------- Closing ---------- */
.closing { text-align: center; padding-block: clamp(64px, 10vw, 130px) clamp(56px, 8vw, 100px); }
.closing img.icon { width: 88px; height: 88px; margin: 0 auto 28px; border-radius: 20px; box-shadow: 0 16px 30px -14px rgba(27, 26, 32, 0.4); }
.closing .cta { justify-content: center; }

footer { border-top: 1px solid var(--rule); padding-block: 28px 40px; font-size: 0.9rem; color: var(--muted); }
.foot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 28px; }
.foot nav { display: flex; flex-wrap: wrap; gap: 8px 24px; }
.foot a { text-decoration: none; }
.foot a:hover { color: var(--ink); text-decoration: underline; }

/* ---------- Reveal ---------- */
.js .reveal { opacity: 0; transform: translateY(26px); transition: opacity 0.7s ease, transform 0.7s cubic-bezier(0.2, 0.7, 0.2, 1); }
.js .reveal.in { opacity: 1; transform: none; }
.js .fan .side { opacity: 0; transition: opacity 0.8s ease 0.25s, transform 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) 0.25s; }
.js .fan .side.l { transform: translateX(40%) rotate(0deg); }
.js .fan .side.r { transform: translateX(-40%) rotate(0deg); }
.js .fan.in .side { opacity: 1; }
.js .fan.in .side.l { transform: rotate(-7deg); }
.js .fan.in .side.r { transform: rotate(7deg); }

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .js .reveal, .js .fan .side, .mark, .span-bar, .badge { transition: none; }
    .js .reveal { opacity: 1; transform: none; }
}

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
    body { font-size: 16px; }
    .nav-links a:not(.get):not(.lang) { display: none; }
    .hero { grid-template-columns: 1fr; }
    .fan { margin-inline: calc(var(--gutter) * -1); overflow: hidden; padding-bottom: 40px; }
    .fan .phone { --w: min(58vw, 270px); }
    .fan .side { --w: min(49vw, 228px); }
    .split { grid-template-columns: 1fr; }
    .split.flip .media { order: 0; }
    .pair { grid-template-columns: 1fr; }
    .peek { --pw: min(42vw, 210px); }
    .duo .phone { --w: min(42vw, 210px); }
    .split > .media:not(.duo) > .phone { --w: min(68vw, 270px); }
    .plans { grid-template-columns: 1fr; }
}
@media (max-width: 420px) {
    .brand span i { display: none; }
    .demo { padding-inline: 16px; }
    .seg button { padding-inline: 11px; }
}
