/* Wrapper */
.tcp-wrapper {
    font-family: 'Inter', sans-serif;
    padding: 20px;
    border-radius: 12px;
    overflow: hidden;
    box-sizing: border-box;
}

/* Container com Rolagem */
.tcp-table-container {
    position: relative;
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    overflow-y: auto;
    max-height: 90vh;
    border-radius: 12px;
    background: white;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1);
    -webkit-overflow-scrolling: touch; 
}

.tcp-table {
    border-collapse: separate;
    border-spacing: 0;
    table-layout: fixed; 
    width: 100%; 
}

/* --- COLUNA 1: FUNCIONALIDADES E GRUPO FIXO (DESKTOP) --- */
.tcp-col-feature, .tcp-group-title {
    position: sticky;
    left: 0;
    z-index: 30;
    background-color: #ffffff; 
    text-align: left;
    font-weight: 600;
    
    /* Largura Padrão Desktop */
    width: 280px;
    min-width: 280px;
    max-width: 280px;
    
    border-right: 2px solid #e2e8f0;
    box-sizing: border-box;
    transition: width 0.3s ease; /* Suavidade ao redimensionar */
}

/* --- AJUSTE MOBILE CRÍTICO --- */
@media (max-width: 768px) {
    .tcp-col-feature, 
    .tcp-group-title {
        width: 100px !important;
        min-width: 100px !important;
        max-width: 100px !important;
        font-size: 0.85em; /* Fonte um pouco menor para caber */
        padding: 10px 5px; /* Padding reduzido */
        word-wrap: break-word;
        hyphens: auto;
    }
    
    /* Ajusta também a célula de intersecção do topo e rodapé */
    .tcp-thead-feature, 
    .tcp-tfoot-feature {
         width: 100px !important;
         min-width: 100px !important;
         padding: 10px 5px;
    }
}

.tcp-group-title {
    z-index: 35; 
    padding: 12px 20px; 
    font-size: 0.85em; 
    text-transform: uppercase; 
    letter-spacing: 0.05em;
    border-top: 2px solid #e5e7eb;
}

.tcp-group-filler {
    border-top: 2px solid #e5e7eb;
}

/* --- CABEÇALHOS --- */
.tcp-thead-th {
    position: sticky;
    top: 0;
    z-index: 40;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    padding: 15px 10px;
    vertical-align: bottom;
}

/* --- CANTO SUPERIOR ESQUERDO --- */
.tcp-thead-feature {
    position: sticky;
    left: 0;
    top: 0;
    z-index: 50;
    background-color: #ffffff;
    border-right: 2px solid #e2e8f0;
}

/* --- RODAPÉ --- */
.tcp-tfoot-th, .tcp-tfoot-td {
    position: sticky;
    bottom: 0;
    z-index: 40;
    background-color: #f9fafb;
    border-top: 2px solid #e5e7eb;
}

.tcp-tfoot-feature {
    position: sticky;
    left: 0;
    bottom: 0;
    z-index: 50;
    background-color: #f9fafb;
    border-right: 2px solid #e2e8f0;
}

/* --- CÉLULAS GERAIS --- */
.tcp-th, .tcp-td {
    padding: 14px 12px;
    border-right: 1px solid #e5e7eb;
    border-bottom: 1px solid #e5e7eb;
    vertical-align: middle;
    white-space: normal; 
}

.tcp-header-inner {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    align-items: center;
    min-height: 120px;
    height: 100%;
    text-align: center;
}

.tcp-center-content { text-align: center; }
.tcp-check-icon { font-size: 1.2em; display:inline-block; }
.tcp-empty-icon { font-size: 0.9em; opacity: 0.5; display:inline-block; }

.tcp-price-tag { 
    display: block; 
    font-weight: 700; 
    margin: 8px 0; 
    text-align: center; 
    white-space: nowrap;
}

.tcp-btn-buy {
    display: inline-block; 
    padding: 10px 15px; 
    border-radius: 6px; 
    text-decoration: none;
    font-weight: 600; 
    transition: all 0.2s; 
    min-width: 80px;
    max-width: 100%;
    color: white !important;
    text-align: center;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    white-space: nowrap;
}
.tcp-btn-buy:hover { filter: brightness(110%); transform: translateY(-1px); color: white !important; }

.tcp-product-title, .tcp-summary-title {
    font-weight: 700; 
    text-transform: uppercase; 
    letter-spacing: 0.05em;
    display: flex; 
    align-items: center; 
    justify-content: center; 
    text-align: center;
    line-height: 1.2;
}

.tcp-product-title {
    min-height: 50px; 
    margin-bottom: 10px;
    word-break: break-word;
}

.tcp-summary-title { 
    margin-top: 10px; 
    word-break: break-word;
}

.tcp-feature-text { display: block; line-height: 1.4; }
.tcp-feature-detail { display: block; font-size: 0.85em; font-weight: 400; opacity: 0.8; margin-top: 4px; }
.tcp-header-label { font-weight:400; font-size:0.9em; }

.tcp-summary-cell { padding-top:20px; padding-bottom:20px; }
.tcp-mobile-hint { text-align:center; opacity:0.6; font-size:0.85em; margin-top:1rem; }