/* ════════════════════════════════════════════════════════════════
   NAADI AI — CHECKOUT ADDITIONS  (site/checkout.css)
   ─────────────────────────────────────────────────────────────────
   The order summary and the promo strip. Loaded by pricing.html only,
   next to checkout.js, so that adding them did not mean re-versioning
   site.css on thirteen generated pages.

   The .ck-overlay / .ck-card / .ck-h / .ck-msg grammar this builds on
   is in site.css §"CHECKOUT".
   ════════════════════════════════════════════════════════════════ */

/* ── Summary ─────────────────────────────────────────────────── */

.ck-sum {
    text-align: left;
    margin: 6px 0 16px;
    border: 1px solid var(--s200, #e2e8f0);
    border-radius: 14px;
    padding: 6px 16px;
}

.ck-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    padding: 10px 0;
    font-size: .92rem;
    color: var(--s700, #334155);
}

.ck-row + .ck-row {
    border-top: 1px dashed var(--s200, #e2e8f0);
}

.ck-row b {
    font-family: var(--font-mono);
    font-size: .86em;
    letter-spacing: .04em;
}

.ck-off span:last-child {
    color: #1f9e4a;
    font-weight: 700;
}

.ck-dim span:last-child {
    color: var(--s400, #94a3b8);
}

.ck-total {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 1.08rem;
    color: var(--s900, #0f172a);
}

.ck-row.ck-total {
    border-top: 1px solid var(--s300, #cbd5e1);
}

.ck-ends {
    margin: 0 0 10px;
    font-family: var(--font-mono);
    font-size: .7rem;
    letter-spacing: .04em;
    color: var(--amber, #c07c12);
}

.ck-note {
    margin: -6px 0 14px;
    font-size: .82rem;
    line-height: 1.5;
    color: var(--amber, #c07c12);
    text-align: left;
}

.ck-note:empty {
    display: none;
}

.ck-x {
    border: 0;
    background: none;
    color: var(--s400, #94a3b8);
    font-size: .8rem;
    cursor: pointer;
    padding: 2px 6px;
    margin-left: 2px;
    border-radius: 6px;
}

.ck-x:hover {
    background: var(--s100, #f1f5f9);
    color: var(--s700, #334155);
}

/* :not([hidden]) — a bare display rule here would beat the hidden
   attribute and the box would show before "Have a code?" is tapped.
   tools/check_hidden.py exists because this has shipped before. */
.ck-codebox:not([hidden]) {
    display: flex;
    gap: 8px;
    margin: 0 0 12px;
}

.ck-codebox .nd-btn {
    width: auto;
    flex: 0 0 auto;
}

.ck-code {
    flex: 1;
    min-width: 0;
    min-height: 44px;
    border: 1px solid var(--s300, #cbd5e1);
    border-radius: 10px;
    padding: 0 12px;
    font-family: var(--font-mono);
    font-size: 16px;            /* 16px: iOS zooms the page on anything smaller */
    letter-spacing: .06em;
    text-transform: uppercase;
}

.ck-code:focus {
    outline: none;
    border-color: var(--g500, #2f6cb3);
}

#ck-havecode {
    display: block;
    margin: -4px auto 12px;
    text-decoration: underline;
}

#ck-havecode[hidden] {
    display: none;
}

/* ── Promo strip ─────────────────────────────────────────────── */

/* Pinned to the BOTTOM. The top of this page is taken twice over — the
   fixed site nav, and the sticky Plans / What's In Each tabs under it —
   and a third bar there hides one of them. The bottom is where the
   thumb is, which is also where "Get Complete NEET" is on a phone. */
#ck-promobar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 9300;
    box-shadow: 0 -4px 18px rgba(11, 18, 32, .12);
    padding-bottom: calc(10px + env(safe-area-inset-bottom));
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 6px 16px;
    padding-top: 10px;
    padding-left: 16px;
    padding-right: 44px;
    margin: 0;
    font-size: .86rem;
    line-height: 1.4;
    text-align: center;
}

#ck-promobar .ck-x {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    color: inherit;
    opacity: .7;
}

#ck-promobar b {
    font-family: var(--font-mono);
    letter-spacing: .04em;
}

.ck-pb-good {
    background: #e7f6ee;
    color: #146c35;
}

.ck-pb-bad {
    background: #fdf1e3;
    color: #8a5608;
}

.ck-pb-info {
    background: var(--g50, #eef4fb);
    color: var(--g700, #1f4d85);
}

.ck-pb-offer b {
    font-family: var(--font-display);
    letter-spacing: 0;
}

.ck-pb-was {
    opacity: .75;
    font-size: .9em;
}

.ck-pb-ends {
    font-family: var(--font-mono);
    font-size: .76rem;
    font-variant-numeric: tabular-nums;
}

.ck-pb-ends:empty {
    display: none;
}

/* The test-mode bar also sits at the bottom; stack above it. */
body:has(#ck-testbar) #ck-promobar {
    bottom: 27px;
}

/* Room for the strip, so it never sits over the footer's last links. */
body:has(#ck-promobar) {
    padding-bottom: 64px;
}

@media (max-width: 640px) {
    #ck-promobar {
        font-size: .8rem;
        gap: 4px 12px;
    }
}
