/*
 * Installed-app navigation (see includes/app_nav.php).
 *
 * Everything here is scoped to html.tk-app, which is set only when the site runs as the
 * installed app, and to phone widths. In a normal browser the bar never shows and the
 * hamburger menu stays exactly as it is.
 */

.tk-appbar,
.tk-appsheet,
.tk-appsheet-backdrop { display: none; }

@media (max-width: 768px) {
    html.tk-app {
        --tk-appbar-h: 62px;
        --tk-appbar-safe: env(safe-area-inset-bottom, 0px);
        --tk-appbar-ink: #18181b;
        --tk-appbar-muted: #71717a;
        --tk-appbar-line: #d4d4d8;
        --tk-appbar-bg: #ffffff;
        --tk-appbar-paper: #f1f1f4;
    }

    /* The burgers (public header + account top bar) and the header home button are replaced
       by the tab bar. Cart stays in the header. */
    html.tk-app .mobile-menu-toggle,
    html.tk-app .mobile-home-btn,
    html.tk-app .acct-burger { display: none !important; }

    /* Room for the bar so nothing ends up hidden behind it. */
    html.tk-app body { padding-bottom: calc(var(--tk-appbar-h) + var(--tk-appbar-safe)) !important; }

    html.tk-app .tk-appbar {
        display: flex;
        position: fixed;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 1500;
        height: calc(var(--tk-appbar-h) + var(--tk-appbar-safe));
        padding: 0 6px var(--tk-appbar-safe);
        background: var(--tk-appbar-bg);
        border-top: 1px solid var(--tk-appbar-line);
        box-shadow: 0 -6px 20px rgba(24, 24, 27, .06);
        -webkit-user-select: none;
        user-select: none;
    }

    /* Perforation along the top edge, like a ticket's tear line. */
    html.tk-app .tk-appbar::before {
        content: "";
        position: absolute;
        left: 14px;
        right: 14px;
        top: 5px;
        height: 1px;
        background-image: linear-gradient(90deg, var(--tk-appbar-line) 50%, transparent 0);
        background-size: 8px 1px;
        opacity: .8;
        pointer-events: none;
    }

    html.tk-app .tk-appbar-tab {
        flex: 1 1 0;
        min-width: 0;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 3px;
        padding-top: 4px;
        color: var(--tk-appbar-muted);
        text-decoration: none;
        font-size: 11px;
        font-weight: 600;
        letter-spacing: .01em;
        -webkit-tap-highlight-color: transparent;
    }

    html.tk-app .tk-appbar-ico {
        display: grid;
        place-items: center;
        width: 46px;
        height: 30px;
        border-radius: 999px;
        font-size: 17px;
        transition: background-color .2s ease, color .2s ease, transform .2s ease;
    }

    html.tk-app .tk-appbar-label {
        max-width: 100%;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    html.tk-app .tk-appbar-tab.is-active,
    html.tk-app .tk-appbar-tab[aria-expanded="true"] { color: var(--tk-appbar-ink); }

    html.tk-app .tk-appbar-tab.is-active .tk-appbar-ico,
    html.tk-app .tk-appbar-tab[aria-expanded="true"] .tk-appbar-ico {
        background: var(--tk-appbar-ink);
        color: #fff;
    }

    html.tk-app .tk-appbar-tab:active .tk-appbar-ico { transform: scale(.92); }

    /* While a panel is open only its tab is highlighted, not the page's tab as well. */
    html.tk-app.tk-appsheet-open .tk-appbar-tab.is-active:not([aria-expanded="true"]) { color: var(--tk-appbar-muted); }
    html.tk-app.tk-appsheet-open .tk-appbar-tab.is-active:not([aria-expanded="true"]) .tk-appbar-ico { background: transparent; color: inherit; }

    html.tk-app .tk-appbar-tab:focus-visible { outline: none; }
    html.tk-app .tk-appbar-tab:focus-visible .tk-appbar-ico {
        box-shadow: 0 0 0 2px var(--tk-appbar-bg), 0 0 0 4px var(--tk-appbar-ink);
    }

    /* ---- Explore sheet ---- */
    html.tk-app .tk-appsheet-backdrop:not([hidden]) {
        display: block;
        position: fixed;
        inset: 0;
        z-index: 1490;
        background: rgba(24, 24, 27, .35);
        opacity: 0;
        transition: opacity .25s ease;
    }
    html.tk-app .tk-appsheet-backdrop.is-open { opacity: 1; }

    html.tk-app .tk-appsheet:not([hidden]) {
        display: block;
        position: fixed;
        left: 10px;
        right: 10px;
        bottom: calc(var(--tk-appbar-h) + var(--tk-appbar-safe) + 10px);
        z-index: 1495;
        padding: 10px 16px 16px;
        background: var(--tk-appbar-bg);
        border: 1px solid var(--tk-appbar-line);
        border-radius: 18px;
        box-shadow: 0 18px 40px rgba(24, 24, 27, .18);
        transform: translateY(16px);
        opacity: 0;
        transition: transform .28s cubic-bezier(.2, .9, .3, 1.15), opacity .2s ease;
        max-height: calc(100vh - var(--tk-appbar-h) - var(--tk-appbar-safe) - 40px);
        overflow-y: auto;
    }
    html.tk-app .tk-appsheet.is-open { transform: none; opacity: 1; }

    html.tk-app .tk-appsheet-grip {
        width: 36px;
        height: 4px;
        margin: 0 auto 8px;
        border-radius: 4px;
        background: var(--tk-appbar-line);
    }

    html.tk-app .tk-appsheet-head {
        display: flex;
        align-items: center;
        justify-content: space-between;
        margin-bottom: 12px;
        color: var(--tk-appbar-ink);
        font-size: 17px;
    }

    html.tk-app .tk-appsheet-user { display: flex; align-items: center; gap: 12px; min-width: 0; }
    html.tk-app .tk-appsheet-avatar {
        flex: 0 0 auto;
        display: grid;
        place-items: center;
        width: 44px;
        height: 44px;
        border-radius: 999px;
        background: var(--tk-appbar-ink);
        color: #fff;
        font-size: 15px;
        font-weight: 700;
    }
    html.tk-app .tk-appsheet-user-text { display: flex; flex-direction: column; min-width: 0; }
    html.tk-app .tk-appsheet-user-text strong,
    html.tk-app .tk-appsheet-user-text small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    html.tk-app .tk-appsheet-user-text small { color: var(--tk-appbar-muted); font-size: 12.5px; font-weight: 500; }
    html.tk-app .tk-appsheet-group {
        display: block;
        margin: 16px 2px 8px;
        color: var(--tk-appbar-muted);
        font-size: 11px;
        font-weight: 700;
        letter-spacing: .12em;
        text-transform: uppercase;
    }
    html.tk-app .tk-appsheet-link.is-here { border-style: solid; border-color: var(--tk-appbar-ink); background: var(--tk-appbar-bg); }

    html.tk-app .tk-appsheet-close {
        display: grid;
        place-items: center;
        width: 34px;
        height: 34px;
        border: 1px solid var(--tk-appbar-line);
        border-radius: 999px;
        background: var(--tk-appbar-bg);
        color: var(--tk-appbar-ink);
        cursor: pointer;
    }

    html.tk-app .tk-appsheet-grid {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }

    html.tk-app .tk-appsheet-link {
        display: flex;
        align-items: center;
        gap: 10px;
        min-height: 56px;
        padding: 10px 12px;
        border: 1px dashed var(--tk-appbar-line);
        border-radius: 14px;
        background: var(--tk-appbar-paper);
        color: var(--tk-appbar-ink);
        font-weight: 600;
        font-size: 14px;
        line-height: 1.2;
        text-decoration: none;
    }
    html.tk-app .tk-appsheet-link:active { transform: scale(.98); }

    html.tk-app .tk-appsheet-ico {
        flex: 0 0 auto;
        display: grid;
        place-items: center;
        width: 34px;
        height: 34px;
        border-radius: 10px;
        background: var(--tk-appbar-ink);
        color: #fff;
        font-size: 14px;
    }

    html.tk-app .tk-appsheet-langs {
        display: flex;
        flex-wrap: wrap;
        align-items: center;
        gap: 8px;
        margin-top: 14px;
        padding-top: 14px;
        border-top: 1px dashed var(--tk-appbar-line);
    }
    html.tk-app .tk-appsheet-sub { color: var(--tk-appbar-muted); margin-right: 2px; }
    html.tk-app .tk-appsheet-lang {
        padding: 7px 12px;
        border: 1px solid var(--tk-appbar-line);
        border-radius: 999px;
        color: var(--tk-appbar-ink);
        font-size: 13px;
        font-weight: 600;
        text-decoration: none;
    }
    html.tk-app .tk-appsheet-lang.is-current {
        background: var(--tk-appbar-ink);
        border-color: var(--tk-appbar-ink);
        color: #fff;
    }

    html.tk-app .tk-appsheet-logout {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 8px;
        margin-top: 14px;
        padding: 12px;
        border-radius: 12px;
        color: #b91c1c;
        font-weight: 600;
        font-size: 14px;
        text-decoration: none;
        background: #fef2f2;
    }

    /* Toasts and floating buttons anchored to the bottom sit above the bar instead of under it. */
    html.tk-app .tkc-toast,
    html.tk-app .cart-toast,
    html.tk-app .tk-share-toast,
    html.tk-app .link-copy-bubble,
    html.tk-app .qr-code-toggle-btn,
    html.tk-app .ad-sidebar-toggle,
    html.tk-app .tk-device-notice {
        margin-bottom: calc(var(--tk-appbar-h) + var(--tk-appbar-safe));
    }

    /* The account sidebar and share sheet open above the bar. */
    html.tk-app .acct-sidebar { z-index: 1600; }
}

/* ---- Pull to refresh (assets/js/app-pull-refresh.js) - app only, any width ----
   A ticket machine. Pulling feeds a ticket out of a slot at the top edge (--p: 0..1, set by
   the script); past the mark a red "validated" stamp lands on it; letting go cuts the ticket
   so the card and its barcode fall off as one piece, and fresh tickets keep printing. */
@property --p { syntax: "<number>"; inherits: true; initial-value: 0; }

.tk-ptr { display: none; }
html.tk-app .tk-ptr {
    --p: 0;
    --tk-ptr-w: 168px;
    --tk-ptr-h: 112px;
    display: block;
    position: fixed;
    top: env(safe-area-inset-top, 0px);
    left: 50%;
    z-index: 2100;
    width: calc(var(--tk-ptr-w) + 20px);
    transform: translateX(-50%);
    opacity: 0;
    pointer-events: none;
}
html.tk-app .tk-ptr.is-settling { transition: --p .3s cubic-bezier(.3, .8, .3, 1); }

/* The machine's slot the ticket comes out of. */
html.tk-app .tk-ptr-slot {
    position: relative;
    z-index: 2;
    display: block;
    height: 10px;
    margin: 0 auto;
    border-radius: 0 0 8px 8px;
    background: linear-gradient(#000, #27272a);
    box-shadow: inset 0 -2px 0 #3f3f46, 0 4px 10px rgba(24, 24, 27, .25);
    transform: scaleX(calc(.6 + var(--p) * .4));
    opacity: calc(.4 + var(--p) * .6);
}

/* Everything that has come out of the slot. */
html.tk-app .tk-ptr-feed {
    display: block;
    width: var(--tk-ptr-w);
    height: calc(var(--tk-ptr-h) + 26px);
    margin: -3px auto 0;
    /* hide what is still inside the machine (above the slot), but let a cut ticket fall freely */
    clip-path: inset(0 -80px -320px -80px);
    padding: 0 0 22px;
    filter: drop-shadow(0 6px 10px rgba(24, 24, 27, .22));   /* here, because the ticket's mask would clip it */
}

html.tk-app .tk-ptr-ticket {
    --notch: 7px;
    position: relative;
    display: flex;
    flex-direction: column;
    height: var(--tk-ptr-h);
    color: #18181b;
    transform: translateY(calc((var(--p) - 1) * 100%));
}

/* Two real pieces, each carrying half of each notch, so the card can be cut away cleanly. */
html.tk-app .tk-ptr-top {
    flex: 0 0 32px;
    background: #fffdf7;
    -webkit-mask:
        radial-gradient(circle var(--notch) at 0 100%, #0000 97%, #000) left / 51% 100% no-repeat,
        radial-gradient(circle var(--notch) at 100% 100%, #0000 97%, #000) right / 51% 100% no-repeat;
            mask:
        radial-gradient(circle var(--notch) at 0 100%, #0000 97%, #000) left / 51% 100% no-repeat,
        radial-gradient(circle var(--notch) at 100% 100%, #0000 97%, #000) right / 51% 100% no-repeat;
}

html.tk-app .tk-ptr-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
    padding: 0 12px;
}
html.tk-app .tk-ptr-brand { font-size: 10.5px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
html.tk-app .tk-ptr-no { font: 600 10px/1 ui-monospace, SFMono-Regular, Menlo, monospace; color: #a1a1aa; }

html.tk-app .tk-ptr-body { display: flex; align-items: center; gap: 10px; flex: 1 1 auto; padding: 8px 54px 0 12px; }
html.tk-app .tk-ptr-arrowbox {
    flex: 0 0 auto;
    display: grid;
    place-items: center;
    width: 30px;
    height: 30px;
    border-radius: 8px;
    background: #18181b;
    color: #fff;
    font-size: 13px;
}
html.tk-app .tk-ptr-arrow { transition: transform .15s ease; }
html.tk-app .tk-ptr-lines { flex: 1 1 auto; display: grid; gap: 5px; }
html.tk-app .tk-ptr-lines span { display: block; height: 5px; border-radius: 3px; background: #e4e4e7; }
html.tk-app .tk-ptr-lines span:nth-child(1) { width: 92%; background: #d4d4d8; }
html.tk-app .tk-ptr-lines span:nth-child(2) { width: 64%; }
html.tk-app .tk-ptr-lines span:nth-child(3) { width: 40%; }

/* The cut-off ticket: the card (arrow, lines, stamp) and the barcode, one piece of paper. */
html.tk-app .tk-ptr-rip {
    position: relative;
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    min-height: 0;
    background: #fffdf7;
    border-radius: 0 0 6px 6px;
    transform-origin: 14% 0;
    -webkit-mask:
        radial-gradient(circle var(--notch) at 0 0, #0000 97%, #000) left / 51% 100% no-repeat,
        radial-gradient(circle var(--notch) at 100% 0, #0000 97%, #000) right / 51% 100% no-repeat;
            mask:
        radial-gradient(circle var(--notch) at 0 0, #0000 97%, #000) left / 51% 100% no-repeat,
        radial-gradient(circle var(--notch) at 100% 0, #0000 97%, #000) right / 51% 100% no-repeat;
}
html.tk-app .tk-ptr-stub {
    display: block;
    padding: 8px 14px 10px;
    background: linear-gradient(90deg, #a1a1aa 50%, #0000 0) top / 7px 1.5px repeat-x;
}
/* While the piece is falling, the bit left in the slot keeps a rough torn edge. */
html.tk-app .tk-ptr-top { position: relative; }
html.tk-app .tk-ptr.is-torn .tk-ptr-top::after {
    content: "";
    position: absolute;
    left: var(--notch);
    right: var(--notch);
    bottom: -3px;
    height: 4px;
    background: linear-gradient(135deg, #fffdf7 33%, #0000 34%) 0 0 / 6px 4px repeat-x,
                linear-gradient(225deg, #fffdf7 33%, #0000 34%) 0 0 / 6px 4px repeat-x;
    animation: tkPtrEdge .7s linear forwards;
}
@keyframes tkPtrEdge {
    0%, 70% { opacity: 1; }
    100% { opacity: 0; }
}
html.tk-app .tk-ptr-bars {
    display: block;
    height: 100%;
    min-height: 16px;
    background: repeating-linear-gradient(90deg,
        #18181b 0 1px, #0000 1px 3px, #18181b 3px 5px, #0000 5px 6px,
        #18181b 6px 7px, #0000 7px 10px, #18181b 10px 13px, #0000 13px 15px);
    opacity: .85;
}

/* The "validated" stamp. */
html.tk-app .tk-ptr-stamp {
    position: absolute;
    top: 8px;
    right: 8px;
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border: 2.5px solid #dc2626;
    border-radius: 999px;
    color: #dc2626;
    font-size: 18px;
    box-shadow: inset 0 0 0 2px #fffdf7, inset 0 0 0 3.5px rgba(220, 38, 38, .55);
    mix-blend-mode: multiply;
    opacity: 0;
    transform: rotate(-16deg) scale(2.2);
}
html.tk-app .tk-ptr-stamp > i { grid-area: 1 / 1; }
html.tk-app .tk-ptr-off { display: none; }
html.tk-app .tk-ptr.is-ready .tk-ptr-stamp,
html.tk-app .tk-ptr.is-loading .tk-ptr-stamp { animation: tkPtrStamp .28s cubic-bezier(.5, 1.8, .6, 1) forwards; }
@keyframes tkPtrStamp {
    0% { opacity: 0; transform: rotate(-16deg) scale(2.2); }
    60% { opacity: .95; transform: rotate(-12deg) scale(.92); }
    100% { opacity: .9; transform: rotate(-12deg) scale(1); }
}
/* the ticket takes the hit */
html.tk-app .tk-ptr.is-ready .tk-ptr-ticket { animation: tkPtrThud .28s ease-out; }
@keyframes tkPtrThud { 55% { translate: 0 3px; } }

/* Let go: the card is cut off and falls with its barcode, then fresh tickets keep printing. */
html.tk-app .tk-ptr.is-torn .tk-ptr-rip {
    animation: tkPtrTear .7s cubic-bezier(.4, 0, .7, .4) forwards;
}
@keyframes tkPtrTear {
    0% { transform: none; opacity: 1; }
    12% { transform: rotate(-5deg); }
    78% { transform: translateY(110px) rotate(16deg); opacity: 1; }
    100% { transform: translateY(190px) rotate(22deg); opacity: 0; }
}
html.tk-app .tk-ptr.is-printing .tk-ptr-rip { transform: none; opacity: 1; }
html.tk-app .tk-ptr.is-printing .tk-ptr-ticket { animation: tkPtrPrint 1.1s cubic-bezier(.3, .7, .3, 1) infinite; }
@keyframes tkPtrPrint {
    0% { transform: translateY(-100%); }
    70%, 100% { transform: translateY(0); }
}
html.tk-app .tk-ptr.is-printing .tk-ptr-stamp { animation: tkPtrStampOff 1.1s infinite; }
@keyframes tkPtrStampOff { 0%, 100% { opacity: 0; } }
html.tk-app .tk-ptr.is-loading .tk-ptr-arrow { transform: none !important; }
html.tk-app .tk-ptr.is-loading .tk-ptr-arrow::before { content: "\f3ff"; }   /* fa-ticket-simple */

/* No connection: a grey "no signal" stamp instead of the red tick, and it goes back in. */
html.tk-app .tk-ptr.is-offline .tk-ptr-stamp { border-color: #71717a; color: #71717a; box-shadow: inset 0 0 0 2px #fffdf7, inset 0 0 0 3.5px rgba(113, 113, 122, .5); animation: tkPtrStamp .28s cubic-bezier(.5, 1.8, .6, 1) forwards; }
html.tk-app .tk-ptr.is-offline .tk-ptr-ok { display: none; }
html.tk-app .tk-ptr.is-offline .tk-ptr-off { display: block; font-size: 15px; }

/* The page itself should not rubber-band while the indicator is being pulled. */
html.tk-app, html.tk-app body { overscroll-behavior-y: none; }

/* ---- Fast navigation (assets/js/app-fast-nav.js) ---- */
html.tk-app a,
html.tk-app button { touch-action: manipulation; }   /* no double-tap-zoom wait on taps */

.tk-navline { display: none; }
html.tk-app .tk-navline {
    display: block;
    position: fixed;
    top: env(safe-area-inset-top, 0px);
    left: 0;
    z-index: 2200;
    width: 100%;
    height: 3px;
    background: #18181b;
    transform-origin: 0 50%;
    transform: scaleX(0);
    opacity: 0;
    pointer-events: none;
}
/* Races most of the way at once, then creeps - the new page replaces it when it lands. */
html.tk-app.tk-navigating .tk-navline {
    opacity: 1;
    animation: tkNavline 8s cubic-bezier(.05, .7, .1, 1) forwards;
}
@keyframes tkNavline {
    0% { transform: scaleX(0); }
    6% { transform: scaleX(.45); }
    100% { transform: scaleX(.94); }
}

/* Page-to-page: a quick cross-fade with the tab bar held still, like switching tabs in a
   native app. Only in the installed app on a phone (browsers without support just jump). */
@media (display-mode: standalone) and (max-width: 768px) {
    @view-transition { navigation: auto; }
}
html.tk-app .tk-appbar { view-transition-name: tk-appbar; }
::view-transition-old(root),
::view-transition-new(root) { animation-duration: .16s; }
::view-transition-group(tk-appbar) { animation: none; }

/* ---- "Install the app" (includes/app_install.php, assets/js/app-install.js) - website only ---- */
[data-tk-install-link][hidden],
.tk-install[hidden],
.tk-install-sheet[hidden],
.tk-install-backdrop[hidden] { display: none !important; }
html.tk-app .tk-install,
html.tk-app .tk-install-sheet,
html.tk-app [data-tk-install-link] { display: none !important; }

.tk-install {
    position: fixed;
    left: 12px;
    right: 12px;
    bottom: calc(12px + env(safe-area-inset-bottom, 0px));
    z-index: 1400;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 10px 12px 12px;
    background: #fff;
    color: #18181b;
    border: 1px solid #d4d4d8;
    border-radius: 18px;
    box-shadow: 0 16px 36px rgba(24, 24, 27, .18);
    transform: translateY(calc(100% + 24px));
    transition: transform .35s cubic-bezier(.2, .9, .3, 1.1);
}
.tk-install.is-in { transform: none; }
.tk-install-icon { flex: 0 0 auto; width: 44px; height: 44px; border-radius: 11px; box-shadow: 0 0 0 1px #e4e4e7; }
.tk-install-text { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; line-height: 1.25; }
.tk-install-text strong { font-size: 15px; }
.tk-install-text small { color: #71717a; font-size: 12.5px; }
.tk-install-go {
    flex: 0 0 auto;
    padding: 10px 16px;
    border: 0;
    border-radius: 999px;
    background: #18181b;
    color: #fff;
    font: inherit;
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
}
.tk-install-go:active { transform: scale(.97); }
.tk-install-x {
    flex: 0 0 auto;
    display: grid;
    place-items: center;
    width: 32px;
    height: 32px;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: #71717a;
    cursor: pointer;
}

.tk-install-backdrop {
    position: fixed;
    inset: 0;
    z-index: 1990;
    background: rgba(24, 24, 27, .4);
    opacity: 0;
    transition: opacity .25s ease;
}
.tk-install-backdrop.is-in { opacity: 1; }

.tk-install-sheet {
    position: fixed;
    left: 50%;
    bottom: calc(16px + env(safe-area-inset-bottom, 0px));
    z-index: 2000;
    width: min(calc(100% - 24px), 420px);
    max-height: min(86vh, 640px);
    overflow: auto;
    padding: 16px 16px 20px;
    background: #fff;
    color: #18181b;
    border: 1px solid #d4d4d8;
    border-radius: 20px;
    box-shadow: 0 20px 44px rgba(24, 24, 27, .22);
    transform: translate(-50%, 24px);
    opacity: 0;
    transition: transform .3s cubic-bezier(.2, .9, .3, 1.1), opacity .2s ease;
}
.tk-install-sheet.is-in { transform: translate(-50%, 0); opacity: 1; }
.tk-install-sheet-head { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.tk-install-sheet-head img { width: 40px; height: 40px; border-radius: 10px; box-shadow: 0 0 0 1px #e4e4e7; }
.tk-install-sheet-head strong { flex: 1 1 auto; font-size: 17px; }
.tk-install-steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.tk-install-steps li {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border: 1px dashed #d4d4d8;
    border-radius: 14px;
    background: #f1f1f4;
    font-size: 14.5px;
    line-height: 1.35;
}
.tk-install-num {
    flex: 0 0 auto;
    display: grid;
    place-items: center;
    width: 28px;
    height: 28px;
    border-radius: 999px;
    background: #18181b;
    color: #fff;
    font-weight: 700;
    font-size: 13px;
}
.tk-install-step { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex: 1 1 auto; }
.tk-install-glyph { flex: 0 0 auto; color: #2563eb; font-size: 17px; }
.tk-install-note { margin: 12px 2px 0; color: #52525b; font-size: 14px; line-height: 1.45; }
/* On iPhone, Safari's Share button sits in the bottom toolbar: point at it. */
.tk-install-pointer {
    display: block;
    margin: 12px auto 0;
    width: max-content;
    color: #71717a;
    animation: tkInstallNudge 1.2s ease-in-out infinite;
}
@keyframes tkInstallNudge { 50% { transform: translateY(5px); } }

@media (prefers-reduced-motion: reduce) {
    html.tk-app .tk-appsheet,
    html.tk-app .tk-appsheet-backdrop,
    html.tk-app .tk-appbar-ico { transition: none !important; }
    html.tk-app.tk-navigating .tk-navline { animation: none; transform: scaleX(.6); }
    html.tk-app .tk-ptr.is-settling { transition: none; }
    html.tk-app .tk-ptr .tk-ptr-stamp { animation: none !important; transform: rotate(-12deg); }
    html.tk-app .tk-ptr.is-ready .tk-ptr-stamp, html.tk-app .tk-ptr.is-loading .tk-ptr-stamp, html.tk-app .tk-ptr.is-offline .tk-ptr-stamp { opacity: .9; }
    html.tk-app .tk-ptr.is-torn .tk-ptr-rip, html.tk-app .tk-ptr.is-printing .tk-ptr-ticket, html.tk-app .tk-ptr.is-ready .tk-ptr-ticket,
    html.tk-app .tk-ptr.is-torn .tk-ptr-top::after { animation: none !important; }
    .tk-install, .tk-install-sheet, .tk-install-backdrop { transition: none !important; }
    .tk-install-pointer { animation: none; }
}
