/* ============================================================================
   58-period-report.css - v0.27.0.0: the week and month report
   (Components/Reports/PeriodReportModal) and its door in the board's progress row.

   ONE HEIGHT. The card is as tall on a seven-bar week as on a thirty-one-bar month,
   in its empty state, its loading skeleton and its error (owner rule: windows never
   jump in size). The head stays put; the body is the one box that scrolls, inside
   itself, with overscroll contained so a swipe never drags the board behind it.

   PHONE FIRST. At 375px the card is the screen minus a 8px rim, the chips scroll
   sideways in their own row, every tap target is at least 44px, and the tiles stay
   two by two. From 600px it becomes a centred 600px card.

   DAYS RUN LEFT TO RIGHT in every language, like the timeline's axis: the bars are
   time. 95-rtl.css pins them (section 1) and turns the two arrows and the delta's
   trend line round (section 3); everything else follows the page's direction through
   logical properties.

   Colours come from the base tokens; the dark theme's own twins (quality, the delta,
   the bar glow) are declared at the end of this file. Before 95-rtl and the dark theme
   in ChronosHead, like every component sheet.
   ============================================================================ */

/* ---- the door ------------------------------------------------------------------------------ */
.board-door-report { gap: 6px; }
.board-door-report .board-door-text {
    display: none;
    font-size: var(--text-sm);
    font-weight: var(--weight-semibold);
}
@media (min-width: 721px) {
    .board-door-report { padding: 0 12px 0 10px; }
    .board-door-report .board-door-text { display: inline; }
}

/* ---- the card ------------------------------------------------------------------------------ */
/* Above the top bar and the pet's advice bubble, which can be open when the door is pressed (the
   plain modal layer, 200, sits under them), at the weather card's level; under the confirm dialog
   (1200) and the notices (1400). */
.rp-backdrop {
    z-index: 1100;
    padding: 8px;
    backdrop-filter: blur(2px);
}
.modal-card.rp-card {
    --rp-pad: 16px;
    --rp-up: #16A34A;
    --rp-down: #D97706;
    --rp-strong: #059669;
    --rp-fair: #D97706;
    --rp-weak: #DC2626;
    position: relative;
    width: 100%;
    max-width: 600px;
    min-width: 0;
    height: calc(100svh - 16px);
    max-height: 760px;
    padding: 0;
    gap: 0;
    overflow: hidden;
    border-radius: 18px;
    background:
        radial-gradient(120% 60% at 0% 0%, color-mix(in srgb, var(--chronos-violet) 7%, transparent), transparent 55%),
        var(--chronos-card-bg);
}
@supports not (height: 1svh) {
    .modal-card.rp-card { height: calc(100vh - 16px); }
}
@media (min-width: 600px) {
    .rp-backdrop { padding: 24px; }
    .modal-card.rp-card {
        --rp-pad: 22px;
        height: min(760px, calc(100svh - 48px));
    }
}

/* ---- the head ------------------------------------------------------------------------------ */
.rp-head {
    flex: none;
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 14px var(--rp-pad) 12px;
    border-bottom: 1px solid var(--chronos-outline);
}
.rp-head-row {
    display: flex;
    align-items: center;
    gap: 10px;
}
.rp-head-icon {
    flex: none;
    display: inline-grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border-radius: 10px;
    font-size: 20px;
    color: #FFFFFF;
    background: linear-gradient(135deg, var(--chronos-violet), var(--chronos-pink));
    box-shadow: 0 4px 12px color-mix(in srgb, var(--chronos-violet) 35%, transparent);
}
.rp-title {
    flex: 1;
    min-width: 0;
    margin: 0;
    font-size: var(--text-xl);
    font-weight: var(--weight-bold);
    color: var(--chronos-fg-primary);
}
.rp-close {
    flex: none;
    display: inline-grid;
    place-items: center;
    width: 44px;
    height: 44px;
    margin-inline-end: -8px;
    border: 1px solid transparent;
    border-radius: var(--radius-pill);
    background: transparent;
    color: var(--chronos-fg-muted);
    cursor: pointer;
    transition: border-color 0.15s ease, color 0.15s ease;
}
.rp-close:hover {
    color: var(--chronos-fg-primary);
    border-color: color-mix(in srgb, var(--hover-ink) var(--hover-lift), transparent);
}

/* The four periods: one row that scrolls sideways on a phone instead of wrapping into two. */
.rp-chips {
    display: flex;
    gap: 6px;
    margin-inline: calc(var(--rp-pad) * -1);
    padding-inline: var(--rp-pad);
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
}
.rp-chips::-webkit-scrollbar { display: none; }
.rp-chip {
    flex: none;
    height: 40px;
    padding: 0 14px;
    border: 1px solid var(--chronos-outline);
    border-radius: var(--radius-pill);
    background: var(--chronos-card-bg);
    color: var(--chronos-fg-secondary);
    font: inherit;
    font-size: var(--text-base);
    font-weight: var(--weight-semibold);
    white-space: nowrap;
    cursor: pointer;
    transition: border-color 0.15s ease, color 0.15s ease, background 0.15s ease;
}
.rp-chip:hover { border-color: color-mix(in srgb, var(--hover-ink) var(--hover-lift), transparent); }
.rp-chip.is-active {
    border-color: transparent;
    background: linear-gradient(135deg, var(--chronos-violet), color-mix(in srgb, var(--chronos-violet) 70%, var(--chronos-pink)));
    color: #FFFFFF;
    box-shadow: 0 3px 10px color-mix(in srgb, var(--chronos-violet) 30%, transparent);
}
@media (min-width: 600px) {
    .rp-chip { height: 34px; }
}

.rp-nav {
    display: flex;
    align-items: center;
    gap: 8px;
}
.rp-step {
    flex: none;
    display: inline-grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border: 1px solid var(--chronos-outline);
    border-radius: var(--radius-pill);
    background: var(--chronos-chip-bg);
    color: var(--chronos-fg-primary);
    cursor: pointer;
    transition: border-color 0.15s ease, opacity 0.15s ease;
}
.rp-step:hover:not(:disabled) { border-color: color-mix(in srgb, var(--hover-ink) var(--hover-lift), transparent); }
.rp-step:disabled { opacity: 0.35; cursor: default; }
@media (min-width: 600px) {
    .rp-step { width: 36px; height: 36px; }
}
.rp-period {
    flex: 1;
    min-width: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
    text-align: center;
}
.rp-period-name {
    font-size: var(--text-lg);
    font-weight: var(--weight-bold);
    color: var(--chronos-fg-primary);
    white-space: nowrap;
}
.rp-running {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    height: 22px;
    padding: 0 8px;
    border-radius: var(--radius-pill);
    background: color-mix(in srgb, var(--rp-up) 12%, transparent);
    color: var(--rp-up);
    font-size: var(--text-xs);
    font-weight: var(--weight-semibold);
}
.rp-running-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: currentColor;
    animation: rp-pulse 1.6s ease-in-out infinite;
}
@keyframes rp-pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.35; transform: scale(0.7); }
}

/* ---- the body: the one box that scrolls ---------------------------------------------------- */
.rp-body {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    gap: 14px;
    padding: 16px var(--rp-pad) 22px;
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
}

.rp-sec-title {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
    font-size: var(--text-xs);
    font-weight: var(--weight-bold);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--chronos-fg-muted);
}
.rp-sec-count {
    display: inline-grid;
    place-items: center;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    border-radius: var(--radius-pill);
    background: color-mix(in srgb, var(--rp-weak) 14%, transparent);
    color: var(--rp-weak);
    font-family: var(--chronos-font-mono);
    font-size: var(--text-xs);
    letter-spacing: 0;
}

/* ---- the hero ------------------------------------------------------------------------------ */
.rp-hero {
    flex: none;
    display: flex;
    align-items: center;
    gap: 16px;
    min-height: 104px;
    padding: 16px 18px;
    border: 1px solid var(--chronos-outline);
    border-radius: 16px;
    background:
        radial-gradient(90% 140% at 0% 0%, color-mix(in srgb, var(--chronos-violet) 16%, transparent), transparent 60%),
        radial-gradient(70% 120% at 100% 100%, color-mix(in srgb, var(--chronos-pink) 12%, transparent), transparent 60%),
        var(--chronos-card-inset);
}
.rp-hero-num {
    flex: none;
    font-family: var(--chronos-font-mono);
    font-size: 56px;
    font-weight: var(--weight-black);
    line-height: 1;
    letter-spacing: -0.03em;
    font-variant-numeric: tabular-nums;
    background: linear-gradient(135deg, var(--chronos-violet) 10%, var(--chronos-pink));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
.rp-hero-meta {
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
}
.rp-hero-cap {
    font-size: var(--text-md);
    font-weight: var(--weight-semibold);
    color: var(--chronos-fg-primary);
}
.rp-delta {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    min-height: 24px;
    padding: 2px 10px 2px 8px;
    border-radius: var(--radius-pill);
    font-size: var(--text-sm);
    font-weight: var(--weight-semibold);
}
.rp-delta .material-icons { font-size: 16px; }
.rp-delta.is-up { background: color-mix(in srgb, var(--rp-up) 13%, transparent); color: var(--rp-up); }
.rp-delta.is-down { background: color-mix(in srgb, var(--rp-down) 13%, transparent); color: var(--rp-down); }
.rp-delta.is-flat { background: var(--chronos-chip-bg); color: var(--chronos-fg-muted); }
.rp-hero-note { font-size: var(--text-xs); color: var(--chronos-fg-muted); }

/* ---- the bars ------------------------------------------------------------------------------ */
.rp-bars-card {
    flex: none;
    padding: 14px 14px 10px;
    border: 1px solid var(--chronos-outline);
    border-radius: 16px;
    background: var(--chronos-card-bg);
}
.rp-bars {
    display: grid;
    grid-template-columns: repeat(var(--rp-days, 7), minmax(0, 1fr));
    gap: 8px;
    height: 150px;
}
.rp-bars.is-month { gap: 3px; }
.rp-bar-col {
    display: grid;
    grid-template-rows: 18px minmax(0, 1fr) 20px;
    justify-items: center;
    min-width: 0;
}
.rp-bar-count {
    grid-row: 1;
    align-self: end;
    font-family: var(--chronos-font-mono);
    font-size: var(--text-xs);
    font-weight: var(--weight-bold);
    color: var(--chronos-fg-secondary);
    white-space: nowrap;
}
.rp-bar {
    grid-row: 2;
    align-self: end;
    width: 100%;
    max-width: 36px;
    height: calc(var(--h, 0) * 1%);
    min-height: 4px;
    border-radius: 8px 8px 3px 3px;
    background: linear-gradient(180deg, var(--chronos-lavender), var(--chronos-violet));
    transition: height 0.45s cubic-bezier(0.22, 1, 0.36, 1);
}
.rp-bars.is-month .rp-bar { border-radius: 4px 4px 2px 2px; }
/* A day with nothing closed keeps a stub, so the row reads as days and not as holes. */
.rp-bar-col.is-zero .rp-bar {
    background: color-mix(in srgb, var(--chronos-fg-muted) 22%, transparent);
}
.rp-bar-col.is-best .rp-bar {
    background: linear-gradient(180deg, var(--chronos-pink), var(--chronos-violet));
    box-shadow: 0 6px 16px color-mix(in srgb, var(--chronos-pink) 35%, transparent);
}
.rp-bar-col.is-best .rp-bar-count { color: var(--chronos-pink); }
.rp-bar-col.is-future .rp-bar {
    background: transparent;
    border: 1px dashed color-mix(in srgb, var(--chronos-fg-muted) 45%, transparent);
}
.rp-bar-label {
    grid-row: 3;
    align-self: end;
    font-size: var(--text-xs);
    color: var(--chronos-fg-muted);
    white-space: nowrap;
    text-transform: capitalize;
}
.rp-bar-col.is-today .rp-bar-label {
    color: var(--chronos-violet);
    font-weight: var(--weight-bold);
}
.rp-bar-col.is-future .rp-bar-label { opacity: 0.5; }

/* ---- the tiles ----------------------------------------------------------------------------- */
.rp-tiles {
    flex: none;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}
.rp-tile {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
    min-height: 104px;
    padding: 12px 14px;
    border: 1px solid var(--chronos-outline);
    border-radius: 14px;
    background: var(--chronos-card-inset);
}
.rp-tile-cap {
    font-size: var(--text-sm);
    font-weight: var(--weight-semibold);
    color: var(--chronos-fg-muted);
}
.rp-tile-val {
    font-family: var(--chronos-font-mono);
    font-size: var(--text-3xl);
    font-weight: var(--weight-black);
    line-height: 1.1;
    font-variant-numeric: tabular-nums;
    color: var(--chronos-fg-primary);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.rp-tile-val-text {
    font-family: var(--chronos-font-sans);
    font-size: var(--text-xl);
    font-weight: var(--weight-bold);
}
.rp-tile-val.is-none { color: var(--chronos-fg-muted); }
.rp-tile-of {
    margin-inline-start: 2px;
    font-size: var(--text-md);
    font-weight: var(--weight-bold);
    color: var(--chronos-fg-muted);
}
/* May wrap to a second line: "of 12 h 30 min planned" is two words in English and five in Hebrew.
   The tiles of one row stretch together, so a wrap moves no neighbour. */
.rp-tile-sub {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    min-width: 0;
    font-size: var(--text-sm);
    line-height: 1.35;
    color: var(--chronos-fg-muted);
    overflow-wrap: anywhere;
}
.rp-tile-sub .material-icons { font-size: 15px; color: var(--chronos-violet); }
.rp-meter {
    margin-top: auto;
    height: 6px;
    border-radius: var(--radius-pill);
    background: color-mix(in srgb, var(--chronos-fg-muted) 18%, transparent);
    overflow: hidden;
}
.rp-meter-fill {
    display: block;
    width: calc(var(--p, 0) * 1%);
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--chronos-violet), var(--chronos-lavender));
}
.rp-quality.is-strong .rp-tile-val { color: var(--rp-strong); }
.rp-quality.is-fair .rp-tile-val { color: var(--rp-fair); }
.rp-quality.is-weak .rp-tile-val { color: var(--rp-weak); }
.rp-quality.is-strong .rp-meter-fill { background: var(--rp-strong); }
.rp-quality.is-fair .rp-meter-fill { background: var(--rp-fair); }
.rp-quality.is-weak .rp-meter-fill { background: var(--rp-weak); }

/* ---- the pet's narrative ------------------------------------------------------------------- */
/* A gradient frame: the border is the gradient showing through a 1.5px gap around the card. */
.rp-story {
    flex: none;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 14px 16px;
    border: 1.5px solid transparent;
    border-radius: 16px;
    background:
        linear-gradient(var(--chronos-card-bg), var(--chronos-card-bg)) padding-box,
        linear-gradient(135deg, color-mix(in srgb, var(--chronos-violet) 70%, transparent), color-mix(in srgb, var(--chronos-pink) 60%, transparent)) border-box;
}
.rp-story-pet {
    flex: none;
    display: inline-grid;
    place-items: center;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    font-size: 30px;
    background: color-mix(in srgb, var(--chronos-violet) 12%, var(--chronos-card-inset));
}
.rp-story-pet.is-asleep { filter: grayscale(0.7); opacity: 0.75; }
.rp-story-main {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.rp-story-cap {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: var(--text-xs);
    font-weight: var(--weight-bold);
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--chronos-violet);
}
.rp-story-cap .material-icons { font-size: 14px; }
.rp-story-text {
    margin: 0;
    font-size: var(--text-md);
    line-height: 1.55;
    color: var(--chronos-fg-primary);
    overflow-wrap: anywhere;
}
.rp-story.is-quiet { background: var(--chronos-card-inset); border-color: var(--chronos-outline); }
.rp-story.is-quiet .rp-story-text { color: var(--chronos-fg-muted); font-size: var(--text-base); }
.rp-story.is-loading .rp-sk-line { height: 12px; }

/* Free: the same card, a sleeping pet and the way to wake it. */
.rp-teaser {
    background:
        radial-gradient(100% 140% at 100% 0%, color-mix(in srgb, var(--chronos-pink) 12%, transparent), transparent 60%) padding-box,
        linear-gradient(var(--chronos-card-bg), var(--chronos-card-bg)) padding-box,
        linear-gradient(135deg, var(--chronos-violet), var(--chronos-pink)) border-box;
}
.rp-teaser .rp-story-text { color: var(--chronos-fg-secondary); font-size: var(--text-base); }
.rp-teaser-cta {
    align-self: flex-start;
    display: inline-flex;
    align-items: center;
    min-height: 40px;
    margin-top: 4px;
    padding: 0 18px;
    border-radius: var(--radius-pill);
    background: linear-gradient(135deg, var(--chronos-violet), var(--chronos-pink));
    color: #FFFFFF;
    font-size: var(--text-base);
    font-weight: var(--weight-bold);
    text-decoration: none;
    box-shadow: 0 4px 14px color-mix(in srgb, var(--chronos-violet) 35%, transparent);
    animation: rp-cta-glow 2.4s ease-in-out infinite;
}
@keyframes rp-cta-glow {
    0%, 100% { box-shadow: 0 4px 14px color-mix(in srgb, var(--chronos-violet) 30%, transparent); }
    50% { box-shadow: 0 4px 22px color-mix(in srgb, var(--chronos-pink) 55%, transparent); }
}

/* ---- labels and leftovers ------------------------------------------------------------------ */
.rp-section { flex: none; }
.rp-labels {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.rp-label {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    min-height: 32px;
    max-width: 100%;
    padding: 0 12px;
    border: 1px solid color-mix(in srgb, var(--lc) 40%, transparent);
    border-radius: var(--radius-pill);
    background: color-mix(in srgb, var(--lc) 12%, var(--chronos-card-bg));
    color: var(--chronos-fg-primary);
    font-size: var(--text-base);
}
.rp-label-dot { flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--lc); }
.rp-label-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rp-label-count {
    font-family: var(--chronos-font-mono);
    font-weight: var(--weight-bold);
    color: var(--chronos-fg-secondary);
}

.rp-left {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin: 0;
    padding: 0;
    list-style: none;
}
.rp-left-row {
    --prio: #94A3B8;
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    min-height: 46px;
    padding: 8px 12px;
    border: 1px solid var(--chronos-outline);
    border-inline-start: 3px solid var(--prio);
    border-radius: 10px;
    background: var(--chronos-card-inset);
    color: var(--chronos-fg-primary);
    font: inherit;
    font-size: var(--text-base);
    text-align: start;
    cursor: pointer;
    transition: border-color 0.15s ease;
}
.rp-left-row:hover {
    border-color: color-mix(in srgb, var(--hover-ink) var(--hover-lift), transparent);
    border-inline-start-color: var(--prio);
}
.rp-left-row.prio-blaze { --prio: #EF4444; }
.rp-left-row.prio-surge { --prio: #7C3AED; }
.rp-left-row.prio-tempo { --prio: #0EA5E9; }
.rp-left-row.prio-respite { --prio: #10B981; }
.rp-left-title {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.rp-left-tag {
    flex: none;
    display: inline-flex;
    align-items: center;
    gap: 3px;
    height: 22px;
    padding: 0 7px;
    border-radius: var(--radius-pill);
    background: var(--chronos-chip-bg);
    color: var(--chronos-fg-muted);
    font-size: var(--text-xs);
}
.rp-left-tag .material-icons { font-size: 13px; }
.rp-left-due {
    flex: none;
    font-size: var(--text-sm);
    color: var(--rp-weak);
    white-space: nowrap;
}
.rp-more { margin: 8px 0 0; font-size: var(--text-sm); color: var(--chronos-fg-muted); }
.rp-clean {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
    padding: 12px 14px;
    border-radius: 12px;
    background: color-mix(in srgb, var(--rp-up) 9%, var(--chronos-card-inset));
    color: var(--chronos-fg-secondary);
    font-size: var(--text-base);
}
.rp-clean .material-icons { font-size: 20px; color: var(--rp-up); }

/* ---- empty, error and loading -------------------------------------------------------------- */
.rp-state {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 24px 12px;
    text-align: center;
}
.rp-state-icon {
    display: inline-grid;
    place-items: center;
    width: 64px;
    height: 64px;
    border-radius: 50%;
    font-size: 32px;
    color: var(--chronos-violet);
    background: color-mix(in srgb, var(--chronos-violet) 11%, var(--chronos-card-inset));
}
.rp-state-title {
    margin: 4px 0 0;
    font-size: var(--text-lg);
    font-weight: var(--weight-bold);
    color: var(--chronos-fg-primary);
}
.rp-state-body {
    max-width: 340px;
    margin: 0;
    font-size: var(--text-base);
    line-height: 1.5;
    color: var(--chronos-fg-muted);
}
.rp-retry { min-height: 40px; margin-top: 6px; }

.rp-sk {
    display: block;
    border-radius: 8px;
    background: linear-gradient(90deg,
        var(--chronos-chip-bg) 25%,
        color-mix(in srgb, var(--chronos-fg-muted) 14%, var(--chronos-chip-bg)) 50%,
        var(--chronos-chip-bg) 75%);
    background-size: 200% 100%;
    animation: rp-shimmer 1.4s linear infinite;
}
.rp-sk-num { width: 88px; height: 56px; border-radius: 12px; }
.rp-sk-num-sm { width: 64px; height: 28px; }
.rp-sk-line { width: 100%; max-width: 220px; height: 14px; }
.rp-sk-line.is-short { max-width: 140px; }
.rp-bar.rp-sk { min-height: 0; border-radius: 6px 6px 3px 3px; }
@keyframes rp-shimmer {
    from { background-position: 200% 0; }
    to { background-position: -200% 0; }
}

/* ---- phone --------------------------------------------------------------------------------- */
@media (max-width: 420px) {
    .rp-hero { gap: 14px; padding: 14px; min-height: 96px; }
    .rp-hero-num { font-size: 48px; }
    .rp-bars { height: 132px; gap: 6px; }
    .rp-bars.is-month { gap: 2px; }
    .rp-tile { padding: 11px 12px; min-height: 98px; }
    .rp-tile-val { font-size: var(--text-2xl); }
    .rp-tile-val-text { font-size: var(--text-lg); }
}

@media (prefers-reduced-motion: reduce) {
    .rp-sk, .rp-running-dot, .rp-teaser-cta { animation: none; }
    .rp-bar { transition: none; }
}

/* ---- dark --------------------------------------------------------------------------------- */
:root[data-theme="dark"] .modal-card.rp-card {
    --rp-up: #4ADE80;
    --rp-down: #FBBF24;
    --rp-strong: #34D399;
    --rp-fair: #FBBF24;
    --rp-weak: #F87171;
}
:root[data-theme="dark"] .rp-bar-col.is-best .rp-bar {
    box-shadow: 0 6px 18px color-mix(in srgb, var(--chronos-pink) 45%, transparent);
}

/* ---- /studio --------------------------------------------------------------------------------
   The gallery mounts the live card in the page's flow (section 43): the backdrop gives up its
   fixed position and veil, and the card takes the height it has on a desk, since the gallery's
   viewport is not the one the card was sized against. */
.studio-rp-grid { grid-template-columns: repeat(auto-fill, minmax(min(100%, 560px), 1fr)); }
.studio-rp-scope .rp-backdrop {
    position: static;
    padding: 0;
    background: none;
    backdrop-filter: none;
    animation: none; /* a specimen is on the page from the start; it does not open */
}
.studio-rp-scope .modal-card.rp-card {
    height: 720px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.12);
}
.studio-rp-scope.is-phone { max-width: 375px; }
.studio-rp-scope.is-phone .modal-card.rp-card { height: 760px; --rp-pad: 16px; }
.studio-rp-scope.is-phone .rp-chip { height: 40px; }
.studio-rp-scope.is-phone .rp-step { width: 44px; height: 44px; }
