/* ====================================================
   ARQUIVO: assets/css/pages/planos.css
   ==================================================== */

.plans-container {
    width: 100%;
    max-width: 1200px;
    margin: 60px auto;
    padding: 0 20px;
    z-index: 10;
}

.plans-header {
    text-align: center;
    margin-bottom: 70px;
}

.plans-header h2 {
    font-size: 2.8rem;
    font-weight: 800;
    color: var(--text-color-dark);
    margin-bottom: 15px;
    letter-spacing: -0.5px;
}

.plans-header p {
    font-size: 1.15rem;
    color: var(--text-color-light);
    max-width: 800px;
    margin: 0 auto;
    line-height: 1.7;
}

.plans-header p strong {
    color: var(--primary-color);
}

/* ====================================================
   SEÇÃO: TABELA DE COMPARAÇÃO SAAS
   ==================================================== */
.comparison-section {
    margin-top: 20px;
    margin-bottom: 40px; /* Reduzido um pouco para encaixar o banner institucional abaixo */
}

.table-responsive-wrapper {
    width: 100%;
    overflow-x: auto;
    padding-bottom: 20px;
}

.comparison-table {
    width: 100%;
    min-width: 1000px;
    border-collapse: separate;
    border-spacing: 0;
    background: #ffffff;
    border-radius: 20px;
    box-shadow: 0 20px 40px -10px rgba(0,0,0,0.08);
    overflow: hidden;
    border: 1px solid var(--border-color);
}

/* DEFINIÇÃO DAS LARGURAS DAS COLUNAS */
.col-features { width: 34%; }
.col-bronze { width: 22%; }
.col-prata { width: 22%; }
.col-ouro { width: 22%; }

/* DESTAQUE DA COLUNA PRATA */
.highlight-col {
    background-color: #f8fafc;
    border-left: 2px solid var(--primary-color) !important;
    border-right: 2px solid var(--primary-color) !important;
}

.comparison-table th, 
.comparison-table td {
    padding: 18px 25px;
    text-align: center;
    border-bottom: 1px solid var(--border-color);
    vertical-align: middle;
    transition: background-color 0.2s ease;
}

/* LINHAS HOVER (Efeito visual ao passar o mouse) */
.comparison-table tbody tr:hover td {
    background-color: #f8fafc;
}
/* Mantém o fundo da coluna prata mesmo no hover */
.comparison-table tbody tr:hover td.highlight-td {
    background-color: #f1f5f9;
}

/* ====================================================
   ESTILOS DO CABEÇALHO (THEAD - OS "CARDS")
   ==================================================== */
.comparison-table thead th {
    background: #ffffff;
    vertical-align: top;
    padding: 50px 30px 40px;
    border-bottom: 3px solid var(--border-color);
    position: relative;
}

/* Bloco superior esquerdo vazio/texto */
.th-features-content {
    text-align: left;
    padding-top: 20px;
}
.th-features-content h3 {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--text-color-dark);
    margin-bottom: 10px;
}
.th-features-content p {
    font-size: 0.95rem;
    color: var(--text-color-light);
    font-weight: 500;
    line-height: 1.5;
}

/* Cabeçalho de cada plano */
.plan-header-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    height: 100%;
}

.plan-header-content .plan-icon {
    font-size: 2.2rem;
    margin-bottom: 18px;
    background: #f1f5f9;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.plan-header-content .plan-title {
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--text-color-dark);
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.plan-header-content .plan-price {
    font-size: 3.2rem;
    font-weight: 900;
    color: var(--text-color-dark);
    line-height: 1;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    margin-bottom: 5px;
}

.plan-price .currency {
    font-size: 1.2rem;
    font-weight: 700;
    margin-top: 8px;
    margin-right: 4px;
    color: var(--text-color-light);
}

.plan-price .period {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-color-light);
    align-self: flex-end;
    margin-bottom: 6px;
    margin-left: 2px;
}

.plan-header-content .plan-annual {
    font-size: 0.85rem;
    color: var(--text-color-light);
    line-height: 1.5;
    margin-bottom: 25px;
    min-height: 40px;
    background: #f8fafc;
    padding: 6px 12px;
    border-radius: 6px;
    border: 1px solid #e2e8f0;
}

.plan-header-content .plan-annual span {
    color: var(--primary-color);
    font-weight: 700;
}

.plan-header-content .plan-subtitle {
    font-size: 0.95rem;
    color: var(--text-color-light);
    font-weight: 500;
    line-height: 1.5;
    margin-bottom: 30px;
    min-height: 50px;
}

.plan-header-content .btn-block {
    width: 100%;
    padding: 14px;
    font-size: 1.05rem;
    font-weight: 700;
    border-radius: 10px;
    margin-top: auto;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
}

/* Destaque Header Prata */
.highlight-th {
    background-color: #f8fafc !important;
    border-top: 5px solid var(--primary-color) !important;
    border-left: 2px solid var(--primary-color) !important;
    border-right: 2px solid var(--primary-color) !important;
}

.highlight-th .plan-icon {
    background: rgba(106, 17, 203, 0.1);
}

.popular-badge-table {
    position: absolute;
    top: -5px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    padding: 6px 20px;
    font-size: 0.8rem;
    font-weight: 800;
    letter-spacing: 1px;
    border-radius: 0 0 10px 10px;
    box-shadow: 0 4px 10px rgba(106, 17, 203, 0.3);
}

/* ====================================================
   ESTILOS DO CORPO DA TABELA (TBODY)
   ==================================================== */
.comparison-table td:first-child {
    text-align: left;
    font-weight: 600;
    color: var(--text-color-dark);
    font-size: 0.95rem;
    border-right: 1px solid var(--border-color);
    padding-left: 30px;
}

/* Linha separadora de categoria */
.comparison-table .category-row td {
    background: #f1f5f9;
    border-top: 2px solid #cbd5e1;
    border-bottom: 2px solid #cbd5e1;
    padding: 18px 30px;
}

.cat-title {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--text-color-dark);
    font-weight: 800;
    font-size: 1.05rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.cat-title i {
    color: var(--primary-color);
    font-size: 1.2rem;
}

/* Ícones e Textos de valor */
.check-icon { 
    color: var(--success); 
    font-size: 1.4rem;
    filter: drop-shadow(0 2px 4px rgba(34, 197, 94, 0.2));
}
.times-icon { 
    color: #cbd5e1;
    font-size: 1.2rem;
    opacity: 0.6;
}
.feature-value { 
    font-size: 0.95rem; 
    font-weight: 700; 
    color: var(--text-color-dark); 
}
.text-muted {
    color: #94a3b8;
    font-weight: 600;
}

/* Destaque TD Prata */
.highlight-td {
    background-color: #f8fafc;
    border-left: 2px solid var(--primary-color) !important;
    border-right: 2px solid var(--primary-color) !important;
}

/* Garante que a última linha feche a borda do destaque */
.comparison-table tbody tr:last-child td.highlight-td {
    border-bottom: 2px solid var(--primary-color) !important;
    border-radius: 0 0 16px 16px;
}

/* ====================================================
   NOVO: BANNER PLANO INSTITUCIONAL (ÓRGÃOS PÚBLICOS)
   ==================================================== */
.institutional-plan-banner {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    border-radius: 20px;
    padding: 40px 50px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
    margin-bottom: 60px;
    box-shadow: 0 20px 40px -10px rgba(0,0,0,0.15);
    border: 1px solid rgba(255,255,255,0.1);
    position: relative;
    overflow: hidden;
}

.institutional-plan-banner::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(106, 17, 203, 0.15) 0%, rgba(255,255,255,0) 70%);
    border-radius: 50%;
    z-index: 0;
}

.institutional-content {
    flex-grow: 1;
    z-index: 1;
}

.institutional-badge {
    display: inline-block;
    background-color: rgba(255, 255, 255, 0.1);
    color: #e2e8f0;
    padding: 6px 16px;
    border-radius: 30px;
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-bottom: 15px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.institutional-content h3 {
    font-size: 2.2rem;
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 15px;
    letter-spacing: -0.5px;
}

.institutional-content p {
    font-size: 1.1rem;
    color: #94a3b8;
    line-height: 1.6;
    margin-bottom: 25px;
    max-width: 800px;
}

.institutional-features {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

.institutional-features li {
    color: #f1f5f9;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1rem;
}

.institutional-features li i {
    color: var(--success);
    font-size: 1.2rem;
}

.institutional-action {
    flex-shrink: 0;
    z-index: 1;
}

.institutional-action .btn {
    padding: 18px 40px;
    font-size: 1.1rem;
    box-shadow: 0 10px 25px rgba(106, 17, 203, 0.3);
}

@media (max-width: 992px) {
    .institutional-plan-banner {
        flex-direction: column;
        text-align: center;
        padding: 40px 30px;
    }
    .institutional-features {
        justify-content: center;
    }
}

/* ====================================================
   SEÇÃO: BREAKDOWN DAS FEATURES (O QUE O SISTEMA FAZ)
   ==================================================== */
.features-breakdown {
    margin-top: 100px;
    padding-top: 80px;
    border-top: 1px solid var(--border-color);
}

.features-breakdown > h2 {
    font-size: 2.5rem;
    font-weight: 800;
    text-align: center;
    color: var(--text-color-dark);
    margin-bottom: 70px;
    letter-spacing: -0.5px;
}

.feature-row {
    display: flex;
    align-items: center;
    gap: 60px;
    margin-bottom: 50px;
    background: #ffffff;
    padding: 50px;
    border-radius: 24px;
    border: 1px solid var(--border-color);
    box-shadow: 0 10px 30px -10px rgba(0,0,0,0.05);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.feature-row:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px -10px rgba(106, 17, 203, 0.1);
    border-color: rgba(106, 17, 203, 0.2);
}

.feature-row.reverse {
    flex-direction: row-reverse;
}

.feature-icon {
    flex-shrink: 0;
    width: 140px;
    height: 140px;
    background: linear-gradient(135deg, #f5f3ff, #ffffff);
    border: 3px solid var(--primary-color);
    color: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3.5rem;
    box-shadow: 0 15px 30px rgba(106, 17, 203, 0.15);
}

.feature-text {
    flex-grow: 1;
}

.feature-text h4 {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--text-color-dark);
    margin-bottom: 18px;
    letter-spacing: -0.5px;
}

.feature-text p {
    font-size: 1.15rem;
    line-height: 1.8;
    color: var(--text-color-light);
    margin: 0;
}

.feature-text strong {
    color: var(--text-color-dark);
    font-weight: 700;
    background: linear-gradient(120deg, rgba(106, 17, 203, 0.1) 0%, rgba(106, 17, 203, 0.1) 100%);
    background-repeat: no-repeat;
    background-size: 100% 30%;
    background-position: 0 90%;
}

.text-right {
    text-align: right;
}

/* Responsividade Básica */
@media (max-width: 992px) {
    .feature-row, .feature-row.reverse {
        flex-direction: column;
        text-align: center;
        padding: 40px 30px;
        gap: 30px;
    }
    .feature-text.text-right {
        text-align: center;
    }
}