/**
 * AppStore MHSYS — Cross-Sell "Potencialize com Tokens Mhax I.A. (Compre Junto)" & Badges de Franquia
 * Bimodal: Light Mode (Default) & Dark Mode ([data-theme="dark"], body.dark-theme)
 * Mobile-First: Responsivo a partir de 375px sem overflow horizontal
 */

.appstore-ai-compre-junto-card {
    background: linear-gradient(135deg, #f8fafc 0%, #eff6ff 55%, #f5f3ff 100%);
    border: 1px solid rgba(99, 102, 241, 0.24);
    border-radius: 1.15rem;
    padding: 1.35rem;
    position: relative;
    overflow: hidden;
    box-shadow: 0 10px 28px -14px rgba(37, 99, 235, 0.2);
}

.appstore-ai-compre-junto-header {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.85rem;
    padding-bottom: 0.9rem;
    margin-bottom: 1rem;
    border-bottom: 1px solid rgba(99, 102, 241, 0.16);
}

.appstore-ai-compre-junto-kicker {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    padding: 0.28rem 0.72rem;
    border-radius: 999px;
    background: linear-gradient(135deg, #4f46e5, #0284c7);
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.28);
}

.appstore-ai-compre-junto-title {
    font-size: 1.12rem;
    font-weight: 800;
    color: #0f172a;
    margin: 0.35rem 0 0.2rem;
    letter-spacing: -0.01em;
}

.appstore-ai-compre-junto-subtitle {
    font-size: 0.82rem;
    color: #475569;
    margin: 0;
    line-height: 1.5;
    max-width: 720px;
}

.appstore-ai-token-pack-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.85rem;
}

.appstore-ai-token-pack-item {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 0.95rem;
    padding: 1rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 0.75rem;
    position: relative;
    transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
    min-width: 0;
}

.appstore-ai-token-pack-item:hover {
    transform: translateY(-2px);
    border-color: rgba(79, 70, 229, 0.45);
    box-shadow: 0 12px 24px -12px rgba(79, 70, 229, 0.22);
}

.appstore-ai-token-pack-item.is-bestseller {
    border: 2px solid #4f46e5;
    background: linear-gradient(180deg, #ffffff 0%, #f5f3ff 100%);
    box-shadow: 0 12px 26px -12px rgba(79, 70, 229, 0.28);
}

.appstore-ai-bestseller-ribbon {
    display: inline-flex;
    align-items: center;
    gap: 0.28rem;
    font-size: 0.68rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    padding: 0.2rem 0.6rem;
    border-radius: 999px;
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    color: #ffffff;
}

.appstore-ai-token-pack-thumb {
    width: 46px;
    height: 46px;
    border-radius: 12px;
    object-fit: cover;
    border: 1px solid rgba(148, 163, 184, 0.28);
    background: #0f172a;
    flex-shrink: 0;
}

.appstore-ai-token-pack-name {
    font-size: 0.88rem;
    font-weight: 800;
    color: #0f172a;
    line-height: 1.3;
    margin: 0;
}

.appstore-ai-token-pack-name a {
    color: inherit;
    text-decoration: none;
}

.appstore-ai-token-pack-name a:hover {
    color: #4f46e5;
}

.appstore-ai-token-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.73rem;
    font-weight: 700;
    padding: 0.22rem 0.62rem;
    border-radius: 999px;
    background: rgba(2, 132, 199, 0.1);
    color: #0369a1;
    border: 1px solid rgba(2, 132, 199, 0.24);
}

.appstore-ai-consumes-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.7rem;
    font-weight: 700;
    padding: 0.2rem 0.58rem;
    border-radius: 999px;
    background: rgba(124, 58, 237, 0.1);
    color: #6d28d9;
    border: 1px solid rgba(124, 58, 237, 0.24);
}

.appstore-ai-token-pack-price {
    font-size: 1.25rem;
    font-weight: 800;
    color: #0284c7;
    line-height: 1.1;
}

.appstore-ai-token-pack-actions {
    display: flex;
    flex-direction: column;
    gap: 0.42rem;
}

.appstore-ai-btn-bundle {
    font-size: 0.76rem;
    font-weight: 700;
    border-radius: 999px;
    padding: 0.45rem 0.8rem;
}

/* Dark Mode Support */
[data-theme="dark"] .appstore-ai-compre-junto-card,
body.dark-theme .appstore-ai-compre-junto-card,
[data-bs-theme="dark"] .appstore-ai-compre-junto-card {
    background: linear-gradient(135deg, #0f172a 0%, #1e1b4b 58%, #0f172a 100%);
    border-color: rgba(129, 140, 248, 0.32);
    box-shadow: 0 14px 32px -14px rgba(2, 6, 23, 0.72);
}

[data-theme="dark"] .appstore-ai-compre-junto-header,
body.dark-theme .appstore-ai-compre-junto-header,
[data-bs-theme="dark"] .appstore-ai-compre-junto-header {
    border-bottom-color: rgba(148, 163, 184, 0.18);
}

[data-theme="dark"] .appstore-ai-compre-junto-title,
body.dark-theme .appstore-ai-compre-junto-title,
[data-bs-theme="dark"] .appstore-ai-compre-junto-title {
    color: #f8fafc;
}

[data-theme="dark"] .appstore-ai-compre-junto-subtitle,
body.dark-theme .appstore-ai-compre-junto-subtitle,
[data-bs-theme="dark"] .appstore-ai-compre-junto-subtitle {
    color: #cbd5e1;
}

[data-theme="dark"] .appstore-ai-token-pack-item,
body.dark-theme .appstore-ai-token-pack-item,
[data-bs-theme="dark"] .appstore-ai-token-pack-item {
    background: rgba(30, 41, 59, 0.88);
    border-color: rgba(148, 163, 184, 0.22);
}

[data-theme="dark"] .appstore-ai-token-pack-item.is-bestseller,
body.dark-theme .appstore-ai-token-pack-item.is-bestseller,
[data-bs-theme="dark"] .appstore-ai-token-pack-item.is-bestseller {
    background: linear-gradient(180deg, rgba(30, 41, 59, 0.96) 0%, rgba(49, 46, 129, 0.55) 100%);
    border-color: #818cf8;
}

[data-theme="dark"] .appstore-ai-token-pack-name,
body.dark-theme .appstore-ai-token-pack-name,
[data-bs-theme="dark"] .appstore-ai-token-pack-name {
    color: #f1f5f9;
}

[data-theme="dark"] .appstore-ai-token-pack-name a:hover,
body.dark-theme .appstore-ai-token-pack-name a:hover,
[data-bs-theme="dark"] .appstore-ai-token-pack-name a:hover {
    color: #93c5fd;
}

[data-theme="dark"] .appstore-ai-token-pill,
body.dark-theme .appstore-ai-token-pill,
[data-bs-theme="dark"] .appstore-ai-token-pill {
    background: rgba(56, 189, 248, 0.16);
    color: #7dd3fc;
    border-color: rgba(56, 189, 248, 0.34);
}

[data-theme="dark"] .appstore-ai-consumes-pill,
body.dark-theme .appstore-ai-consumes-pill,
[data-bs-theme="dark"] .appstore-ai-consumes-pill {
    background: rgba(167, 139, 250, 0.16);
    color: #c4b5fd;
    border-color: rgba(167, 139, 250, 0.34);
}

[data-theme="dark"] .appstore-ai-token-pack-price,
body.dark-theme .appstore-ai-token-pack-price,
[data-bs-theme="dark"] .appstore-ai-token-pack-price {
    color: #38bdf8;
}

@media (max-width: 991.98px) {
    .appstore-ai-token-pack-grid {
        grid-template-columns: 1fr;
    }
    .appstore-ai-compre-junto-card {
        padding: 1rem;
    }
}
