/* ==================================================================
   TÉRMINOS Y SERVICIOS - ESTILOS PRINCIPALES (MODO OSCURO PUI)
   ================================================================== */

/* Reset de estilos base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: rgb(0, 0, 0);
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    color: rgb(255, 255, 255);
    line-height: 1.6;
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
    padding: 80px 24px;
}

/* Rejilla de fondo estética (Heredada exactamente de tu Sección 6) */
.grid-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: 50px 50px;
    background-image: linear-gradient(to right, rgba(255, 255, 255, 0.04) 1px, transparent 1px), 
                      linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px);
    z-index: 1;
    pointer-events: none;
}

/* Contenedor central restrictivo */
.legal-container {
    max-width: 840px;
    margin: 0 auto;
    width: 100%;
    position: relative;
    z-index: 2;
}

/* ==================================================================
   ENCABEZADO (HEADER)
   ================================================================== */
.legal-header {
    text-align: center;
    margin-bottom: 50px;
}

.brand-badge {
    display: inline-block;
    padding: 6px 16px;
    background-color: rgba(60, 162, 244, 0.1);
    border: 1px solid rgba(60, 162, 244, 0.25);
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    color: rgb(60, 162, 244);
    letter-spacing: 0.05em;
    margin-bottom: 24px;
}

.legal-title {
    font-size: 40px;
    font-weight: 800;
    color: rgb(255, 255, 255);
    letter-spacing: -0.02em;
    margin-bottom: 12px;
}

.legal-subtitle {
    font-size: 14px;
    color: rgb(148, 163, 184);
    margin-bottom: 24px;
}

.legal-intro {
    font-size: 16px;
    color: rgb(203, 213, 225);
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.7;
}

/* ==================================================================
   TARJETA CONTENEDORA (CARD CUERPO PRINCIPAL)
   ================================================================== */
.legal-card {
    background-color: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 24px;
    padding: 50px;
    box-shadow: rgba(0, 0, 0, 0.4) 0px 20px 40px;
}

.legal-section {
    margin-bottom: 40px;
}

.legal-section:last-child {
    margin-bottom: 0;
}

.legal-section h2 {
    font-size: 20px;
    font-weight: 700;
    color: rgb(255, 255, 255);
    margin-bottom: 16px;
    letter-spacing: -0.01em;
    border-left: 3px solid rgb(60, 162, 244);
    padding-left: 14px;
}

.legal-section p {
    font-size: 14.5px;
    color: rgb(148, 163, 184);
    margin-bottom: 16px;
    text-align: justify;
}

.legal-section strong {
    color: rgb(255, 255, 255);
}

/* Listas de especificaciones */
.legal-section ul {
    list-style: none;
    margin-left: 4px;
    margin-bottom: 16px;
}

.legal-section ul li {
    font-size: 14px;
    color: rgb(148, 163, 184);
    position: relative;
    padding-left: 20px;
    margin-bottom: 10px;
}

.legal-section ul li::before {
    content: "•";
    position: absolute;
    left: 4px;
    color: rgb(60, 162, 244);
    font-weight: bold;
    font-size: 16px;
    top: -1px;
}

/* ==================================================================
   TABLAS DE CUMPLIMIENTO / AUDITORÍA
   ================================================================== */
table {
    width: 100%;
    border-collapse: collapse;
    margin: 24px 0;
    font-size: 13.5px;
    background-color: rgba(255, 255, 255, 0.01);
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

th, td {
    padding: 14px 18px;
    text-align: left;
}

th {
    background-color: rgba(255, 255, 255, 0.04);
    color: rgb(255, 255, 255);
    font-weight: 700;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

td {
    color: rgb(148, 163, 184);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

tr:last-child td {
    border-bottom: none;
}

tr:hover td {
    background-color: rgba(255, 255, 255, 0.02);
    color: rgb(255, 255, 255);
}

/* ==================================================================
   MALLA DE SEGURIDAD INTERNA (SECURITY GRID)
   ================================================================== */
.security-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-top: 20px;
    margin-bottom: 20px;
}

.security-item {
    background-color: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 14px;
    padding: 20px;
    transition: border-color 0.2s;
}

.security-item:hover {
    border-color: rgba(60, 162, 244, 0.3);
}

.security-item h3 {
    font-size: 15px;
    font-weight: 700;
    color: rgb(255, 255, 255);
    margin-bottom: 8px;
}

.security-item p {
    font-size: 13px;
    color: rgb(148, 163, 184);
    margin-bottom: 0;
    line-height: 1.5;
}

/* ==================================================================
   BOTONES DE CONTROL EN PIE DE PÁGINA
   ================================================================== */
.legal-footer {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin-top: 40px;
}

.btn-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 36px;
    font-size: 14px;
    font-weight: 700;
    border-radius: 30px;
    cursor: pointer;
    text-decoration: none;
    transition: background-color 0.2s, transform 0.1s, border-color 0.2s;
}

.btn-primary {
    color: rgb(255, 255, 255);
    background-color: rgb(60, 162, 244);
    border: none;
    box-shadow: rgba(60, 162, 244, 0.25) 0px 4px 15px;
}

.btn-primary:hover {
    background-color: rgb(37, 140, 219);
}

.btn-secondary {
    color: rgb(255, 255, 255);
    background-color: transparent;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn-secondary:hover {
    background-color: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.4);
}

.btn-action:active {
    transform: scale(0.98);
}

/* ==================================================================
   RESPONSIVE DESIGN (PANTALLAS MÓVILES)
   ================================================================== */
@media (max-width: 768px) {
    body {
        padding: 50px 16px;
    }

    .legal-title {
        font-size: 30px;
    }

    .legal-card {
        padding: 30px 20px;
    }

    .security-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .legal-footer {
        flex-direction: column;
        width: 100%;
    }

    .btn-action {
        width: 100%;
    }
    
    table {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }
}