/* Features page v2 — 2026-08-25, implementing the owner's Claude Design draft
   `PDM Features Page.dc.html` inside the site layout.

   The draft is dark-only with fixed hex; this page also renders in the light
   theme, so every colour maps to a site token. Mono is the local stack — no
   Google Fonts, since Google's font CDN is often unreachable for part of the
   audience.

   Section numbering (01, 02, …) comes from a CSS counter rather than markup,
   so the self-contained demo partial gets numbered in sequence without being
   edited. Only heads that carry a kicker count, which is exactly the four
   narrative sections.

   Responsive rules learned the hard way on the landing and download pages are
   pre-applied: minmax(0,1fr) everywhere, no fixed-width children, clamped
   headings, and the comparison rows restack instead of scrolling. */

html { overflow-x: clip; }
body { counter-reset: f2sec; }

.f2-mono { font-family: ui-monospace, Consolas, "JetBrains Mono", monospace; }

@keyframes f2-rise { from { opacity: 0; transform: translateY(22px); } to { opacity: 1; transform: none; } }
@keyframes f2-pulse { 0%, 100% { opacity: 1; } 50% { opacity: .35; } }

[data-rv] { opacity: 0; transform: translateY(24px); transition: opacity .65s cubic-bezier(.2,.7,.3,1), transform .65s cubic-bezier(.2,.7,.3,1); }
[data-rv].on { opacity: 1; transform: none; }
.f2-rise { animation: f2-rise .6s both; }

@media (prefers-reduced-motion: reduce) {
    .f2-rise, [data-rv] { animation: none; opacity: 1; transform: none; transition: none; }
    .f2-dot { animation: none !important; }
}

/* ---- hero ---------------------------------------------------------------- */
.f2-hero { text-align: center; padding-top: 56px; }
.f2-badge {
    display: inline-flex; align-items: center; gap: 9px;
    height: 34px; padding: 0 17px;
    border: 1px solid color-mix(in srgb, var(--primary) 35%, transparent);
    border-radius: 30px;
    background: color-mix(in srgb, var(--primary) 8%, transparent);
    font-size: 12.5px; font-weight: 600;
    color: color-mix(in srgb, var(--primary) 75%, var(--fg));
}
.f2-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent2); animation: f2-pulse 2s infinite; flex-shrink: 0; }
.f2-hero h1 { margin: 24px auto 0; font-size: clamp(28px, 6vw, 50px); font-weight: 800; line-height: 1.35; letter-spacing: -.5px; }
.f2-hero .lead { margin: 16px auto 0; max-width: 540px; }
.f2-em { color: var(--primary); }

.f2-stats {
    max-width: 860px; margin: 44px auto 0;
    display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 14px;
}
.f2-stat {
    padding: 22px 14px; text-align: center;
    border: 1px solid var(--border); border-radius: 16px; background: var(--card);
    transition: border-color .2s;
}
.f2-stat:hover { border-color: color-mix(in srgb, var(--primary) 40%, transparent); }
.f2-stat-n { font-size: clamp(22px, 5vw, 30px); font-weight: 700; color: var(--primary); line-height: 1.2; }
.f2-stat-l { margin-top: 5px; font-size: 12.5px; font-weight: 600; color: var(--muted); }

/* ---- numbered section heads ---------------------------------------------- */
.section-head .kicker {
    display: flex; align-items: center; justify-content: center; gap: 12px;
    flex-wrap: wrap;
}
.section-head .kicker::before {
    counter-increment: f2sec;
    content: "0" counter(f2sec);
    direction: ltr;
    font-family: ui-monospace, Consolas, "JetBrains Mono", monospace;
    font-size: 12px; font-weight: 700; color: var(--primary);
    padding-inline-end: 2px;
    border-inline-end: 1px solid color-mix(in srgb, var(--primary) 40%, transparent);
    padding-inline-start: 0;
    margin-inline-end: 2px;
}
.section-head .kicker::after {
    content: ""; width: 34px; height: 1px;
    background: color-mix(in srgb, var(--primary) 50%, transparent);
}

/* ---- feature grid -------------------------------------------------------- */
.f2-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); gap: 14px; }
.f2-card {
    padding: 26px 24px; border: 1px solid var(--border); border-radius: 18px;
    background: var(--card); transition: border-color .2s, transform .2s;
}
.f2-card:hover { border-color: color-mix(in srgb, var(--primary) 45%, transparent); transform: translateY(-3px); }
.f2-card-head { display: flex; align-items: center; gap: 13px; margin-bottom: 14px; }
.f2-card-head .icon-chip { flex-shrink: 0; }
.f2-card-head h3 { margin: 0; font-size: 16px; font-weight: 800; }
.f2-card p { margin: 0; font-size: 13.5px; line-height: 2.1; color: var(--muted); }

/* ---- deep dive ----------------------------------------------------------- */
.f2-deep-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 270px), 1fr)); gap: 14px; }
.f2-deep { padding: 26px 24px; border: 1px solid var(--border); border-radius: 18px; background: var(--card); }
.f2-tag {
    height: 24px; padding: 0 12px; display: inline-flex; align-items: center;
    border-radius: 20px;
    background: color-mix(in srgb, var(--primary) 10%, transparent);
    border: 1px solid color-mix(in srgb, var(--primary) 35%, transparent);
    font-size: 11px; font-weight: 700; color: var(--primary);
}
.f2-deep h3 { font-size: 17px; font-weight: 800; margin: 16px 0 10px; }
.f2-deep-d { font-size: 13px; line-height: 2.1; color: var(--muted); margin: 0 0 16px; }
.f2-checks { list-style: none; margin: 0; padding: 16px 0 0; border-top: 1px solid var(--border); display: flex; flex-direction: column; gap: 9px; }
.f2-checks li { display: flex; align-items: flex-start; gap: 9px; font-size: 12.5px; line-height: 1.9; }
.f2-checks svg { flex-shrink: 0; margin-top: 5px; color: var(--accent2); }

/* ---- specs + compare ----------------------------------------------------- */
.f2-duo { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr); gap: 16px; align-items: start; }
.f2-panel { border: 1px solid var(--border); border-radius: 18px; background: var(--card); }
.f2-specs { padding: 24px 26px; }
.f2-specs h2 { font-size: 16px; font-weight: 800; margin: 0 0 14px; }
.f2-spec { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--border); }
.f2-spec:last-child { border-bottom: 0; padding-bottom: 0; }
.f2-spec-k { font-size: 13px; color: var(--muted); }
.f2-spec-v { font-size: 12.5px; font-weight: 700; }

.f2-comp { overflow: hidden; }
.f2-comp-row { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) minmax(0, 1fr); border-bottom: 1px solid var(--border); }
.f2-comp-row:last-child { border-bottom: 0; }
.f2-comp-head { background: color-mix(in srgb, var(--fg) 4%, transparent); }
.f2-comp-head > * { padding: 15px 16px; font-size: 12.5px; font-weight: 700; }
.f2-comp-title { color: var(--muted); }
.f2-comp-us { display: flex; align-items: center; justify-content: center; gap: 7px; color: var(--primary); }
.f2-comp-us img { width: 18px; height: 18px; border-radius: 4px; }
.f2-comp-them { text-align: center; color: var(--muted); }
.f2-comp-k { padding: 15px 16px; font-size: 13px; font-weight: 600; }
.f2-comp-a, .f2-comp-b { padding: 15px 10px; display: flex; align-items: center; justify-content: center; gap: 7px; font-size: 12px; text-align: center; }
.f2-comp-a { color: var(--fg); }
.f2-comp-b { color: var(--muted); }
.f2-comp-a svg { color: var(--accent2); flex-shrink: 0; }
.f2-comp-b svg { color: #ff5d6c; flex-shrink: 0; }

/* ---- languages -----------------------------------------------------------
   One download row redrawn in the picked language, exactly as the draft frames
   it: badge, file name, status, progress, speed — then the note underneath.
   The direction swings with the language, which is the point of the section. */
.f2-lang-box { border: 1px solid var(--border); border-radius: 18px; background: var(--card); overflow: hidden; }
.f2-lang-tabs { display: flex; gap: 6px; padding: 12px 14px; border-bottom: 1px solid var(--border); flex-wrap: wrap; }
.f2-lang-tabs .lang-pick {
    height: 34px; padding: 0 16px; border-radius: 9px; cursor: pointer;
    border: 1px solid var(--border); background: transparent; color: var(--muted);
    font: inherit; font-size: 12.5px; font-weight: 700; white-space: nowrap;
    transition: color .18s, background .18s, border-color .18s;
}
.f2-lang-tabs .lang-pick:hover { color: var(--fg); }
.f2-lang-tabs .lang-pick.is-active {
    color: var(--primary);
    background: color-mix(in srgb, var(--primary) 12%, transparent);
    border-color: color-mix(in srgb, var(--primary) 40%, transparent);
}
.f2-lang-body { padding: 18px 20px; }

.f2-lang-row {
    display: flex; align-items: center; gap: 12px;
    padding: 12px 14px; border-radius: 11px;
    background: var(--bg2); border: 1px solid var(--border);
}
.f2-lang-row.is-in { animation: f2-rise .45s both; }
.f2-lang-badge {
    width: 36px; height: 36px; flex-shrink: 0; border-radius: 9px;
    display: flex; align-items: center; justify-content: center;
    font-size: 9px; font-weight: 700; color: #fff; background: #3b6ef5;
}
.f2-lang-main { flex: 1; min-width: 0; }
.f2-lang-line { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; }
.f2-lang-file { font-size: 12.5px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.f2-lang-status { font-size: 12px; font-weight: 600; color: var(--primary); white-space: nowrap; flex-shrink: 0; }
.f2-lang-track { display: block; height: 5px; margin-top: 7px; border-radius: 4px; background: color-mix(in srgb, var(--fg) 8%, transparent); overflow: hidden; }
.f2-lang-fill { display: block; height: 100%; border-radius: 4px; background: var(--primary); }
.f2-lang-speed { flex-shrink: 0; text-align: center; }
.f2-lang-speed-n { display: block; font-size: 13px; font-weight: 700; }
.f2-lang-speed-l { display: block; margin-top: 2px; font-size: 10.5px; color: var(--muted); white-space: nowrap; }

.f2-lang-note { margin: 14px 0 0; text-align: center; font-size: 12px; line-height: 2; color: var(--muted); }

/* ---- CTA ----------------------------------------------------------------- */
.f2-cta {
    display: flex; align-items: center; gap: 24px; padding: 34px 38px;
    border: 1px solid color-mix(in srgb, var(--primary) 25%, transparent);
    border-radius: 22px;
    background: radial-gradient(500px 240px at 12% 50%, color-mix(in srgb, var(--primary) 12%, transparent), transparent 70%), var(--card);
    flex-wrap: wrap;
}
.f2-cta img { width: 52px; height: 52px; border-radius: 14px; box-shadow: 0 14px 38px -8px var(--ring); }
.f2-cta-body { flex: 1; min-width: 240px; }
.f2-cta-t { font-size: 19px; font-weight: 800; }
.f2-cta-d { margin-top: 7px; font-size: 13.5px; line-height: 2; color: var(--muted); }

/* ---- responsive ---------------------------------------------------------- */
@media (max-width: 900px) {
    .f2-duo { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 620px) {
    .f2-hero { padding-top: 36px; }
    .f2-stats { gap: 10px; }
    .f2-stat { padding: 16px 10px; }
    .f2-card, .f2-deep { padding: 22px 18px; }
    .f2-specs { padding: 20px 18px; }
    .f2-cta { padding: 24px 20px; }
    .f2-cta .btn { width: 100%; justify-content: center; }

    /* The speed block would squeeze the file name to nothing on a phone, so
       it drops to its own line under the progress bar. */
    .f2-lang-body { padding: 14px 12px; }
    .f2-lang-row { flex-wrap: wrap; padding: 12px; }
    .f2-lang-main { flex: 1 1 100%; order: 2; min-width: 0; }
    .f2-lang-badge { order: 1; }
    .f2-lang-speed { order: 1; margin-inline-start: auto; text-align: end; }
    .f2-lang-tabs { gap: 5px; padding: 10px; }
    .f2-lang-tabs .lang-pick { height: 30px; padding: 0 11px; font-size: 11.5px; }

    /* The three-column comparison becomes unreadable at phone widths, so each
       row restacks: the label owns a line, the two verdicts share the next. */
    .f2-comp-row { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
    .f2-comp-k { grid-column: 1 / -1; padding: 14px 16px 4px; }
    .f2-comp-a, .f2-comp-b { justify-content: flex-start; text-align: start; padding: 6px 16px 14px; }
    .f2-comp-head .f2-comp-title { grid-column: 1 / -1; padding-bottom: 4px; }
    .f2-comp-head .f2-comp-us, .f2-comp-head .f2-comp-them { justify-content: flex-start; text-align: start; padding-top: 4px; }
    .section-head .kicker::after { display: none; }
}
