/* ============================================
   Pricing Page — MegaPulse Hub
   Classes BEM: .mp-pricing-*
   Estilo: Site de vendas (fundo claro, cards premium)
   ============================================ */

/* ============================================
   PAGE WRAPPER
   ============================================ */

.mp-pricing {
    background: #f4f6f9;
    padding: 0 0 72px;
    min-height: 100vh;
}

/* ============================================
   PAGE HEADER (fundo claro, estilo site de vendas)
   ============================================ */

.mp-pricing__head {
    text-align: center;
    padding: 48px 24px 24px;
    max-width: 800px;
    margin: 0 auto;
}

.mp-pricing__title {
    font-size: 2.2rem;
    font-weight: 700;
    color: var(--bs-body-color, #1e293b);
    margin: 0 0 8px;
    line-height: 1.2;
}

.mp-pricing__subtitle {
    font-size: 1.1rem;
    color: var(--bs-gray-600, #64748b);
    margin: 0;
    font-weight: 400;
}

/* ============================================
   ONBOARDING ALERT
   ============================================ */

.mp-pricing__onboarding {
    max-width: 1200px;
    margin: 0 auto 24px;
    padding: 0 16px;
}

/* ============================================
   GRID (CSS Grid - alturas iguais por linha)
   ============================================ */

.mp-pricing__grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 24px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 16px;
}

/* Linha 1: 3 cards ocupando 2 colunas cada */
.mp-pricing__grid > .mp-pricing-card:nth-child(1),
.mp-pricing__grid > .mp-pricing-card:nth-child(2),
.mp-pricing__grid > .mp-pricing-card:nth-child(3) {
    grid-column: span 2;
}

/* Linha 2: 2 cards centralizados (offset de 1 col) */
.mp-pricing__grid > .mp-pricing-card:nth-child(4) {
    grid-column: 2 / span 2;
}

.mp-pricing__grid > .mp-pricing-card:nth-child(5) {
    grid-column: 4 / span 2;
}

/* ============================================
   CARD
   ============================================ */

.mp-pricing-card {
    background: var(--bs-body-bg, #fff);
    border-radius: 18px;
    box-shadow: 0 2px 24px rgba(0, 0, 0, .07);
    border: 1px solid rgba(0, 0, 0, .05);
    position: relative;
    overflow: visible;
    display: flex;
    flex-direction: column;
    padding: 32px 30px 30px;
    height: 100%;
}

/* --- Card popular --- */
.mp-pricing-card--popular {
    border: 2px solid #e8920d;
    padding-top: 42px;
}

/* --- Badge "MAIS POPULAR" --- */
.mp-pricing-card__badge {
    position: absolute;
    top: -14px;
    left: 50%;
    transform: translateX(-50%);
    background: #e8920d;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .8px;
    text-transform: uppercase;
    padding: 5px 16px;
    border-radius: 20px;
    white-space: nowrap;
    z-index: 1;
}

/* --- Card Body (flex-grow to push footer down) --- */
.mp-pricing-card__body {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
}

/* --- Title --- */
.mp-pricing-card__title {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--bs-body-color, #1e293b);
    margin-bottom: 2px;
}

/* --- Subtitle --- */
.mp-pricing-card__subtitle {
    color: var(--bs-gray-500, #94a3b8);
    font-size: .85rem;
    margin-bottom: 0;
}

/* --- Divider --- */
.mp-pricing-card__divider {
    border: 0;
    border-top: 1px solid var(--bs-border-color, #e2e8f0);
    margin: 18px 0;
}

/* --- Price --- */
.mp-pricing-card__price {
    font-size: 2.8rem;
    font-weight: 800;
    color: var(--bs-body-color, #1e293b);
    line-height: 1;
    margin-bottom: 16px;
}

.mp-pricing-card__price-suffix {
    font-size: .95rem;
    font-weight: 400;
    color: var(--bs-gray-500, #94a3b8);
    vertical-align: baseline;
}

/* --- Limits list --- */
.mp-pricing-card__limits {
    list-style: none;
    padding: 0;
    margin: 0;
}

.mp-pricing-card__limits li {
    padding: 10px 0;
    border-bottom: 1px solid var(--bs-border-color-translucent, #f1f5f9);
    font-size: .9rem;
    color: var(--bs-body-color, #475569);
}

.mp-pricing-card__limits li:last-child {
    border-bottom: none;
}

.mp-pricing-card__limits li i {
    color: #818cf8;
    width: 22px;
    display: inline-block;
    text-align: center;
    margin-right: 6px;
}

.mp-pricing-card__limits li strong {
    color: var(--bs-body-color, #1e293b);
}

/* --- Features list --- */
.mp-pricing-card__features {
    list-style: none;
    padding: 0;
    margin: 0;
}

.mp-pricing-card__features li {
    padding: 7px 0;
    font-size: .9rem;
    color: var(--bs-body-color, #475569);
}

.mp-pricing-card__features li i {
    color: #22c55e;
    width: 22px;
    display: inline-block;
    text-align: center;
    margin-right: 6px;
}

/* --- Footer (CTA area - always at bottom) --- */
.mp-pricing-card__footer {
    margin-top: auto;
    padding-top: 24px;
}

/* ============================================
   BUTTONS
   ============================================ */

.btn-mp-primary {
    display: block;
    width: 100%;
    background: #6366f1;
    border: 2px solid #6366f1;
    color: #fff;
    border-radius: 12px;
    padding: 14px;
    font-weight: 600;
    font-size: 1rem;
    text-align: center;
    text-decoration: none;
    transition: background .15s, border-color .15s;
}

.btn-mp-primary:hover {
    background: #4f46e5;
    border-color: #4f46e5;
    color: #fff;
}

.btn-mp-highlight {
    display: block;
    width: 100%;
    background: #e8920d;
    border: 2px solid #e8920d;
    color: #fff;
    border-radius: 12px;
    padding: 14px;
    font-weight: 600;
    font-size: 1rem;
    text-align: center;
    text-decoration: none;
    transition: background .15s, border-color .15s;
}

.btn-mp-highlight:hover {
    background: #d17f06;
    border-color: #d17f06;
    color: #fff;
}

.btn-mp-free {
    display: block;
    width: 100%;
    background: transparent;
    border: 2px solid var(--bs-border-color, #d1d5db);
    color: var(--bs-body-color, #374151);
    border-radius: 12px;
    padding: 14px;
    font-weight: 600;
    font-size: 1rem;
    text-align: center;
    text-decoration: none;
    transition: background .15s, border-color .15s;
}

.btn-mp-free:hover {
    background: var(--bs-gray-100, #f9fafb);
    border-color: var(--bs-gray-500, #9ca3af);
    color: var(--bs-body-color, #1f2937);
}

.mp-pricing-card__free-note {
    font-size: .8rem;
    color: var(--bs-gray-500, #94a3b8);
    margin-bottom: 8px;
    text-align: center;
}

/* ============================================
   DARK MODE
   ============================================ */

html.dark .mp-pricing {
    background: #191d24;
}

html.dark .mp-pricing__title {
    color: #f1f5f9;
}

html.dark .mp-pricing__subtitle {
    color: #cbd5e1;
}

html.dark .mp-pricing-card {
    background: #262b36;
    border-color: rgba(255, 255, 255, .08);
    box-shadow: 0 2px 24px rgba(0, 0, 0, .25);
}

html.dark .mp-pricing-card--popular {
    border-color: #e8920d;
}

html.dark .mp-pricing-card__divider {
    border-color: rgba(255, 255, 255, .08);
}

html.dark .mp-pricing-card__limits li {
    border-color: rgba(255, 255, 255, .06);
}

/* Botão Gratuito - sem fundo, escrita branca */
html.dark .btn-mp-free {
    background: transparent !important;
    border-color: rgba(255, 255, 255, .25) !important;
    color: #ffffff !important;
}

html.dark .btn-mp-free:hover {
    background: rgba(255, 255, 255, .08) !important;
    border-color: rgba(255, 255, 255, .35) !important;
    color: #ffffff !important;
}

/* Botões Start, Scale, Pro - fundo roxo, escrita branca */
html.dark .btn-mp-primary {
    background: #818CF8 !important;
    border-color: #818CF8 !important;
    color: #ffffff !important;
}

html.dark .btn-mp-primary:hover {
    background: #6366f1 !important;
    border-color: #6366f1 !important;
    color: #ffffff !important;
}

/* Botão Mais Popular - fundo laranja, escrita branca */
html.dark .btn-mp-highlight {
    background: #f59e0b !important;
    border-color: #f59e0b !important;
    color: #ffffff !important;
}

html.dark .btn-mp-highlight:hover {
    background: #d97706 !important;
    border-color: #d97706 !important;
    color: #ffffff !important;
}

/* Título do card */
html.dark .mp-pricing-card__title {
    color: #f1f5f9;
}

/* Subtítulo do card */
html.dark .mp-pricing-card__subtitle {
    color: #94a3b8;
}

/* Preço */
html.dark .mp-pricing-card__price {
    color: #f1f5f9;
}

/* Suffix do preço (/mês) */
html.dark .mp-pricing-card__price-suffix {
    color: #94a3b8;
}

/* Texto dos limites */
html.dark .mp-pricing-card__limits li {
    color: #cbd5e1;
}

/* Strong nos limites */
html.dark .mp-pricing-card__limits li strong {
    color: #f1f5f9;
}

/* Texto das features */
html.dark .mp-pricing-card__features li {
    color: #cbd5e1;
}

/* Nota "Sem cartão de crédito" */
html.dark .mp-pricing-card__free-note {
    color: #94a3b8;
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 991.98px) {
    .mp-pricing__grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .mp-pricing__grid > .mp-pricing-card:nth-child(1),
    .mp-pricing__grid > .mp-pricing-card:nth-child(2),
    .mp-pricing__grid > .mp-pricing-card:nth-child(3),
    .mp-pricing__grid > .mp-pricing-card:nth-child(4),
    .mp-pricing__grid > .mp-pricing-card:nth-child(5) {
        grid-column: span 1;
    }

    /* Último card (5º) centralizado se ímpar */
    .mp-pricing__grid > .mp-pricing-card:nth-child(5) {
        grid-column: 1 / -1;
        max-width: calc(50% - 12px);
        justify-self: center;
    }

    .mp-pricing__title {
        font-size: 1.8rem;
    }
}

@media (max-width: 575.98px) {
    .mp-pricing__head {
        padding: 32px 16px 20px;
    }

    .mp-pricing__title {
        font-size: 1.5rem;
    }

    .mp-pricing__subtitle {
        font-size: 1rem;
    }

    .mp-pricing {
        padding-bottom: 48px;
    }

    .mp-pricing__grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .mp-pricing__grid > .mp-pricing-card:nth-child(1),
    .mp-pricing__grid > .mp-pricing-card:nth-child(2),
    .mp-pricing__grid > .mp-pricing-card:nth-child(3),
    .mp-pricing__grid > .mp-pricing-card:nth-child(4),
    .mp-pricing__grid > .mp-pricing-card:nth-child(5) {
        grid-column: 1;
        max-width: none;
        justify-self: stretch;
    }

    .mp-pricing-card {
        padding: 28px 24px 24px;
    }

    .mp-pricing-card--popular {
        padding-top: 38px;
    }

    .mp-pricing-card__price {
        font-size: 2.2rem;
    }
}
