/* =========================================================
   Kudita homepage demos
   - Chat selling (chat-selling-spec.md)
   - Your storefront (storefront-spec.md)
   - Store & payments (store-payments-spec.md)
   Dark page; light device/browser frames for the product UI.
   ========================================================= */

body.landing-premium {
    --kh-accent: #5E5ADA;
    --kh-accent-hover: #5148C9;
    --kh-mute: #94a3b8;
}

/* Chat selling + Your storefront moved to kd-exact-sections.css */

/* =========================================================
   Store & payments (store-payments-spec.md)
   ========================================================= */

.kh-pay {
    /* Section sits on the dark homepage; the browser mock itself stays light (real storefront UI). */
    --pay-accent: #5E5ADA;
    --pay-accent-hover: #5148C9;
    --pay-ink: #0F172A;
    --pay-mute: #94A3B8;
    --pay-bg: transparent;
    --pay-card: #FFFFFF;
    --pay-line: rgba(255, 255, 255, 0.12);
    --pay-line-light: #E2E8F0;
    --pay-shadow: 0 18px 50px rgba(0, 0, 0, 0.35);
    background: transparent !important;
    color: #F8FAFC;
    padding: 96px 0 !important;
}

.kh-pay__inner {
    width: min(1120px, calc(100% - 48px));
    margin-inline: auto;
}

.kh-pay__intro {
    text-align: center;
    margin-bottom: 2rem;
}

.kh-pay__kicker {
    margin: 0 0 0.65rem;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--pay-accent) !important;
}

.kh-pay__heading {
    margin: 0;
    font-family: Outfit, Inter, system-ui, sans-serif !important;
    font-size: clamp(2rem, 4vw, 3rem) !important;
    font-weight: 700 !important;
    letter-spacing: -0.03em;
    line-height: 1.1 !important;
    color: #FFFFFF !important;
}

.kh-pay__lead {
    max-width: 36rem;
    margin: 0.75rem auto 0;
    font-size: 1.08rem;
    line-height: 1.55;
    color: var(--pay-mute) !important;
}

/* Browser chrome */
.kh-pay__browser {
    position: relative;
    background: var(--pay-card);
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 22px;
    box-shadow: var(--pay-shadow);
    overflow: visible;
    max-width: 1040px;
    margin-inline: auto;
    color: var(--pay-ink);
}

.kh-pay__chrome {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--pay-line-light);
    background: #FAFBFD;
    border-radius: 22px 22px 0 0;
}

.kh-pay__dots {
    display: flex;
    gap: 6px;
}

.kh-pay__dots span {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #E2E8F0;
}

.kh-pay__dots span:nth-child(1) { background: #F87171; }
.kh-pay__dots span:nth-child(2) { background: #FBBF24; }
.kh-pay__dots span:nth-child(3) { background: #34D399; }

.kh-pay__url {
    justify-self: center;
    max-width: 100%;
    padding: 0.35rem 0.85rem;
    border-radius: 999px;
    background: #fff;
    border: 1px solid var(--pay-line-light);
    font-size: 0.78rem;
    color: #64748B !important;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.kh-pay__chip-wrap {
    position: relative;
}

.kh-pay__chip {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.35rem 0.7rem;
    border-radius: 999px;
    border: 1px solid var(--pay-line-light);
    background: #fff;
    color: var(--pay-ink) !important;
    font-size: 0.8rem;
    font-weight: 600;
}

.kh-pay__chip:hover {
    border-color: rgba(94, 90, 218, 0.45);
}

.kh-pay__menu {
    position: absolute;
    right: 0;
    top: calc(100% + 8px);
    z-index: 20;
    min-width: 200px;
    padding: 0.45rem;
    border-radius: 14px;
    border: 1px solid var(--pay-line-light);
    background: #fff;
    box-shadow: 0 18px 50px rgba(15, 23, 42, 0.12);
}

.kh-pay__menu ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 0.2rem;
}

.kh-pay__menu-item {
    width: 100%;
    display: flex;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.55rem 0.65rem;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: var(--pay-ink) !important;
    text-align: left;
    font-size: 0.85rem;
}

.kh-pay__menu-item span {
    color: #64748B !important;
}

.kh-pay__menu-item.is-active,
.kh-pay__menu-item:hover {
    background: rgba(94, 90, 218, 0.08);
}

.kh-pay__page {
    display: grid;
    grid-template-columns: 1.05fr 1fr;
    gap: 1.5rem;
    padding: 1.5rem 1.75rem 1.75rem;
}

.kh-pay__gallery {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.kh-pay__hero-link {
    display: block;
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid var(--pay-line-light);
    background: #F8FAFC;
}

.kh-pay__hero {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 4 / 5;
    object-fit: cover;
    object-position: center top;
}

.kh-pay__thumbs {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.5rem;
}

.kh-pay__thumb {
    padding: 0;
    border: 1px solid var(--pay-line-light);
    border-radius: 10px;
    overflow: hidden;
    background: #fff;
    line-height: 0;
}

.kh-pay__thumb.is-active {
    border-color: var(--pay-accent);
    box-shadow: inset 0 0 0 1px var(--pay-accent);
}

.kh-pay__thumb img {
    width: 100%;
    height: 64px;
    object-fit: cover;
    display: block;
}

.kh-pay__details {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.kh-pay__title {
    margin: 0 0 0.5rem;
    font-family: Outfit, Inter, system-ui, sans-serif !important;
    font-size: 1.55rem !important;
    font-weight: 700 !important;
    color: #0F172A !important;
}

.kh-pay__price {
    margin: 0;
    font-family: Outfit, Inter, system-ui, sans-serif !important;
    font-size: clamp(2.25rem, 3vw, 2.75rem) !important;
    font-weight: 700 !important;
    line-height: 1.1;
    color: var(--pay-accent) !important;
}

.kh-pay__price-cap {
    margin: 0.35rem 0 1.15rem;
    font-size: 0.9rem;
    color: #64748B !important;
}

.kh-pay__sizes {
    display: flex;
    gap: 0.45rem;
    margin-bottom: 1.15rem;
}

.kh-pay__size {
    min-width: 2.5rem;
    height: 2.5rem;
    border-radius: 999px;
    border: 1px solid var(--pay-line-light);
    background: #fff;
    color: #0F172A !important;
    font-weight: 600;
}

.kh-pay__size.is-selected {
    border-color: var(--pay-accent);
    background: rgba(94, 90, 218, 0.08);
    color: var(--pay-accent) !important;
}

.kh-pay__atc {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 0.9rem 1.25rem;
    border-radius: 999px;
    background: var(--pay-accent);
    color: #fff !important;
    font-weight: 600;
    text-decoration: none !important;
    margin-bottom: 1rem;
}

.kh-pay__atc:hover {
    background: var(--pay-accent-hover);
    color: #fff !important;
}

.kh-pay__trust {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 0.35rem;
}

.kh-pay__trust li {
    position: relative;
    padding-left: 1.2rem;
    font-size: 0.84rem;
    color: #64748B !important;
}

.kh-pay__trust li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.4rem;
    width: 0.55rem;
    height: 0.55rem;
    border-radius: 50%;
    background: #15803D;
}

/* Outcome row */
.kh-pay__outcomes {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    max-width: 1040px;
    margin: 1.25rem auto 0;
}

.kh-pay__outcome {
    background: #fff;
    border: 1px solid #E2E8F0;
    border-radius: 20px;
    padding: 1.15rem 1.25rem;
}

.kh-pay__outcome--dark {
    background: #0F172A;
    border-color: rgba(255, 255, 255, 0.14);
}

.kh-pay__outcome--dark .kh-pay__outcome-label {
    color: rgba(255, 255, 255, 0.7) !important;
}

.kh-pay__outcome--dark .kh-pay__outcome-amount {
    color: #fff !important;
}

.kh-pay__outcome-label {
    margin: 0 0 0.4rem;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #64748B !important;
}

.kh-pay__outcome-amount {
    margin: 0;
    font-family: "Noto Sans", Outfit, Inter, system-ui, sans-serif !important;
    font-size: clamp(1.55rem, 2.4vw, 2rem) !important;
    font-weight: 700 !important;
    color: #0F172A !important;
}

.kh-pay__outcome-amount--accent {
    color: #5E5ADA !important;
}

.kh-pay__caption {
    text-align: center;
    max-width: 36rem;
    margin: 1rem auto 0;
    font-size: 0.875rem;
    color: #94A3B8 !important;
}

.kh-pay__badges {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    margin-top: 1.35rem;
}

.kh-pay__badge {
    display: inline-flex;
    align-items: center;
    padding: 0.4rem 0.8rem;
    border-radius: 999px;
    border: 1px solid #E2E8F0;
    background: #fff;
    color: #0F172A !important;
    font-size: 0.8rem;
    font-weight: 500;
}

.kh-pay__badge-gap {
    width: 0.35rem;
}

.kh-pay__footer-trust {
    text-align: center;
    margin: 1.35rem auto 0;
    font-size: 0.9rem;
    color: #CBD5E1 !important;
}

.kh-pay__cta {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    margin-top: 1.25rem;
}

.kh-pay__cta-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 14rem;
    padding: 0.9rem 1.5rem;
    border-radius: 999px;
    background: var(--pay-accent);
    color: #fff !important;
    font-weight: 600;
    text-decoration: none !important;
}

.kh-pay__cta-btn:hover {
    background: var(--pay-accent-hover);
    color: #fff !important;
}

.kh-pay__live {
    color: var(--pay-accent) !important;
    font-weight: 600;
    font-size: 0.92rem;
    text-decoration: none;
}

/* Mobile: stack product like a phone card */
@media (max-width: 991.98px) {
    .kh-pay {
        padding: 72px 0 !important;
    }

    .kh-pay__chrome {
        grid-template-columns: 1fr auto;
    }

    .kh-pay__dots {
        display: none;
    }

    .kh-pay__url {
        justify-self: start;
        font-size: 0.7rem;
        max-width: 58vw;
    }

    .kh-pay__page {
        grid-template-columns: 1fr;
        padding: 1.1rem;
        gap: 1.1rem;
    }

    .kh-pay__hero {
        aspect-ratio: 3 / 4;
    }

    .kh-pay__thumbs {
        grid-template-columns: repeat(4, 1fr);
    }

    .kh-pay__outcomes {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }

    .kh-pay__cta-btn {
        width: min(100%, 20rem);
    }
}

@media (prefers-reduced-motion: reduce) {
    .kh-device__screen img {
        transition: none;
    }
}

/* Light-mode homepage: chat still sits on dark bands elsewhere;
   ensure pay section never inherits dark text rules. */
@media (prefers-color-scheme: light) {
    .kh-pay h2,
    .kh-pay h3,
    .kh-pay p,
    .kh-pay span,
    .kh-pay li,
    .kh-pay a {
        color: inherit;
    }
}
