Files
pbakaus_impeccable/picker/styles/screens/depth.css
T
2026-09-01 10:02:40 +05:00

122 lines
6.6 KiB
CSS

/* ============================================================
Screen 10: depth style.
How far off the page an element sits. Boundaries fills section grounds;
this file lifts individual elements, and the two answers compose instead
of arguing.
Every answer here is a cast shadow. They go in the --pvs-shadow-* slots and
need something solid under them, which is why the block at the bottom moves
the card's lift onto the picture inside it wherever the boundary answer left
the card transparent: a shadow around an invisible rectangle reads as a bug.
Shadows are sized for the artboard rather than for a real page. The frame
is about a third of browser width, so a blur that would read as gentle at
full size disappears here; the offsets and blurs below are already scaled.
They are also black rather than mixed from the artboard's ink. Ink follows
the ground, so on a drenched page an ink shadow turns pale and the lift
comes out as a glow. Light falls the same way whatever color the page is.
============================================================ */
/* ── Flat ────────────────────────────────────────────────────
One plane. Nothing casts. */
#picker-form:has(.picker-strategy-option:hover input[name="depth-style"][value="flat"]) .picker-preview-depth,
:where(#picker-form:not(:has(.picker-strategy-option:hover input[name="depth-style"])):has(input[name="depth-style"][value="flat"]:checked)) [data-carry] {
--pvs-shadow-chrome: none;
--pvs-shadow-card: none;
--pvs-shadow-control: none;
--pvs-shadow-surface: none;
}
/* ── Soft lift ───────────────────────────────────────────────
Cards and controls come off the page by a millimetre. Two shadows on the
cards: a tight one for the contact edge, a wider one for the ambient. */
#picker-form:has(.picker-strategy-option:hover input[name="depth-style"][value="soft-lift"]) .picker-preview-depth,
:where(#picker-form:not(:has(.picker-strategy-option:hover input[name="depth-style"])):has(input[name="depth-style"][value="soft-lift"]:checked)) [data-carry] {
--pvs-shadow-chrome: 0 1px 2px rgb(0 0 0 / 0.1);
--pvs-shadow-card:
0 1px 1px rgb(0 0 0 / 0.15),
0 3px 7px rgb(0 0 0 / 0.14);
--pvs-shadow-control: 0 1px 2px rgb(0 0 0 / 0.24);
--pvs-shadow-surface: 0 2px 5px rgb(0 0 0 / 0.14);
}
/* ── Floating ────────────────────────────────────────────────
A clear gap between the panels and the page. Offsets grow faster than
blurs, so the lift reads as height rather than as fog. */
#picker-form:has(.picker-strategy-option:hover input[name="depth-style"][value="floating"]) .picker-preview-depth,
:where(#picker-form:not(:has(.picker-strategy-option:hover input[name="depth-style"])):has(input[name="depth-style"][value="floating"]:checked)) [data-carry] {
--pvs-shadow-chrome: 0 2px 6px rgb(0 0 0 / 0.16);
--pvs-shadow-card:
0 2px 3px rgb(0 0 0 / 0.2),
0 9px 18px rgb(0 0 0 / 0.24);
--pvs-shadow-control: 0 3px 6px rgb(0 0 0 / 0.32);
--pvs-shadow-surface: 0 6px 14px rgb(0 0 0 / 0.22);
}
/* ── Where a cast shadow is allowed to land ──────────────────
Only off something solid. Under the two boundary answers that give the
card and the proof band a ground, the section itself lifts. Under the two
that leave them transparent, the lift moves inward to the picture, which
is the only part of the card that is a surface in its own right. */
#picker-form:has(input[name="boundary-style"][value="cards-and-panels"]:checked) [data-carry] :is(.ps-gallery-item, .ps-desktop > .ps-proof),
#picker-form:has(input[name="boundary-style"][value="surface-changes"]:checked) [data-carry] .ps-desktop > .ps-proof {
box-shadow: var(--pvs-shadow-card);
}
#picker-form:not(:has(input[name="boundary-style"][value="cards-and-panels"]:checked)) [data-carry] .ps-gallery-item {
box-shadow: none;
}
#picker-form:not(:has(input[name="boundary-style"][value="cards-and-panels"]:checked)) [data-carry] .ps-gallery-item > i {
box-shadow: var(--pvs-shadow-card);
}
/* Chrome is a ground only under the surface answer, so that is the only one
where the bar at the top of the page casts. The footers are left out: a
footer's shadow would fall out of the frame and be clipped away, so the
only trace of it would be a hard line. */
#picker-form:not(:has(input[name="boundary-style"][value="surface-changes"]:checked)) [data-carry] :is(.ps-nav, .ps-phone-top) {
box-shadow: none;
}
/* ── The same rule, on the three region bodies ────────────────
Each part is asked the same question the card above was: does the boundary
answer leave a ground under it. The answer differs part by part, because a
shell's regions, a document's callout, and an index's alternating band are
each filled by a different one of the four answers.
A rail and a document's rail take a ground only where sections are told apart
by tone, so that is the only answer they lift under. The side panel is filled
by that answer and by the card answer, so it lifts under both. */
#picker-form:not(:has(input[name="boundary-style"][value="surface-changes"]:checked)) [data-carry] :is(.ps-ops-rail, .ps-docs-rail) {
box-shadow: none;
}
#picker-form:not(:has(input[name="boundary-style"][value="surface-changes"]:checked)):not(:has(input[name="boundary-style"][value="cards-and-panels"]:checked)) [data-carry] .ps-ops-panel {
box-shadow: none;
}
/* The chart and the table are containers only under the card answer. Under the
others the lift moves inward to the plot's bars, which are the one part of a
chart that is a surface in its own right, exactly as the landing page's card
hands its lift to the picture inside it. */
#picker-form:not(:has(input[name="boundary-style"][value="cards-and-panels"]:checked)) [data-carry] :is(.ps-ops-chart, .ps-ops-table) {
box-shadow: none;
}
#picker-form:not(:has(input[name="boundary-style"][value="cards-and-panels"]:checked)) [data-carry] .ps-ops-plot > i {
box-shadow: var(--pvs-shadow-card);
}
/* The callout and the index's second entry are both filled by the tone answer
alone, so both are held to it. */
#picker-form:not(:has(input[name="boundary-style"][value="surface-changes"]:checked)) [data-carry] .ps-docs-note {
box-shadow: none;
}
#picker-form:has(input[name="boundary-style"][value="surface-changes"]:checked) [data-carry] .ps-index-row--flip {
box-shadow: var(--pvs-shadow-card);
}