/* ============================================================
   Home page plan cards on phones: each feature list starts folded, with a
   "Show what's included" row at the bottom of the card. Loaded by
   index.html only; the /pricing page keeps its lists open.

   The folded state is the CSS default, so the first frame is already
   right. js/home-mobile.js only flips .is-open and aria-expanded.

   Above the phone breakpoint .pr-fold is display: contents, so the list
   sits in .pr-body exactly as it does without this file, and the button
   is not rendered.
   ============================================================ */

.pr-fold,
.pr-fold-in {
    display: contents;
}

.pr-fold-btn {
    display: none;
}

@media (max-width: 767.98px) {
    /* 0fr to 1fr animates to the list's real height without measuring it.
       visibility keeps the folded list out of the accessibility tree and
       flips only after the close has finished. */
    .pr-fold {
        display: grid;
        grid-template-rows: 0fr;
        visibility: hidden;
        transition: grid-template-rows 0.32s var(--ease-out, ease), visibility 0s linear 0.32s;
    }

    .pr-fold.is-open {
        grid-template-rows: 1fr;
        visibility: visible;
        transition: grid-template-rows 0.32s var(--ease-out, ease), visibility 0s linear 0s;
    }

    .pr-fold-in {
        display: block;
        min-height: 0;
        overflow: hidden;
    }

    .pr-fold .pr-features {
        flex: none;
    }

    /* A footer band that mirrors the header band at the top of the card. */
    .pr-fold-btn {
        appearance: none;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 8px;
        width: 100%;
        margin: 0;
        padding: 12px 20px 13px;
        border: 0;
        border-top: 1px solid var(--pr-line);
        background: transparent;
        color: var(--pr-muted);
        font-family: var(--font-body);
        font-size: 0.84rem;
        font-weight: 600;
        letter-spacing: 0.01em;
        cursor: pointer;
        transition: color var(--transition-fast);
    }

    .pr-fold-btn:hover {
        color: var(--pr-ink);
    }

    .pr-fold-btn:focus-visible {
        color: var(--pr-ink);
        outline: 2px solid var(--pr-accent);
        outline-offset: -2px;
    }

    .pr-fold-btn svg {
        width: 12px;
        height: 12px;
        flex: none;
        fill: none;
        stroke: currentColor;
        stroke-width: 1.9;
        stroke-linecap: round;
        stroke-linejoin: round;
        transition: transform 0.32s var(--ease-out, ease);
    }

    .pr-fold-btn[aria-expanded="true"] svg {
        transform: rotate(180deg);
    }
}

@media (max-width: 767.98px) and (prefers-reduced-motion: reduce) {
    .pr-fold,
    .pr-fold.is-open,
    .pr-fold-btn,
    .pr-fold-btn svg {
        transition: none;
    }
}
