/* ===================================================
   SimpleConta — Páginas Legales (Términos / Privacidad)
   Comparte fondo y tipografía con login_styles.css
   =================================================== */

/* Override del overflow:hidden de login_styles.css para permitir scroll */
body {
    overflow: auto !important;
    align-items: flex-start !important;
}

/* --- Contenedor legal --- */
.legal-container {
    width: 100%;
    max-width: 860px;
    margin: 0 auto;
    padding: 40px 20px;
    min-height: 100vh;
    position: relative;
    z-index: 1;
}

/* --- Card principal --- */
.legal-card {
    background: #ffffff;
    border-radius: 18px;
    box-shadow:
        0 25px 60px rgba(0, 0, 0, 0.25),
        0 0 0 1px rgba(255, 255, 255, 0.05);
    overflow: hidden;
    animation: fadeIn 0.5s ease-out;
}

/* --- Header de la card legal --- */
.legal-header {
    background: #1e2a3a;
    padding: 32px 40px;
    text-align: center;
}

.legal-header-logo {
    margin-bottom: 16px;
}

.legal-header-logo img {
    max-width: 160px;
    height: auto;
}

.legal-header h1 {
    color: #ffffff;
    font-size: 1.6rem;
    font-weight: 700;
    margin: 0;
    letter-spacing: 0.3px;
}

.legal-header .legal-date {
    color: rgba(255, 255, 255, 0.55);
    font-size: 0.85rem;
    margin-top: 8px;
}

/* --- Cuerpo del contenido legal --- */
.legal-body {
    padding: 40px;
    color: #334155;
    font-size: 14.5px;
    line-height: 1.75;
}

.legal-body h2 {
    color: #1e2a3a;
    font-size: 1.15rem;
    font-weight: 700;
    margin: 32px 0 14px;
    padding-bottom: 8px;
    border-bottom: 2px solid #e2e8f0;
}

.legal-body h2:first-child {
    margin-top: 0;
}

.legal-body h3 {
    color: #2a5298;
    font-size: 0.95rem;
    font-weight: 600;
    margin: 20px 0 8px;
}

.legal-body p {
    margin-bottom: 14px;
}

.legal-body ul,
.legal-body ol {
    margin: 10px 0 18px 20px;
    padding: 0;
}

.legal-body li {
    margin-bottom: 8px;
    padding-left: 4px;
}

.legal-body a {
    color: #2a5298;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
}

.legal-body a:hover {
    color: #3b82f6;
    text-decoration: underline;
}

.legal-body strong {
    color: #1e2a3a;
    font-weight: 600;
}

/* --- Highlight box (para info importante) --- */
.legal-highlight {
    background: #f0f5ff;
    border-left: 4px solid #2a5298;
    padding: 16px 20px;
    border-radius: 0 8px 8px 0;
    margin: 18px 0;
    font-size: 14px;
}

/* --- Tabla en contenido legal --- */
.legal-body table {
    width: 100%;
    border-collapse: collapse;
    margin: 16px 0;
    font-size: 13.5px;
}

.legal-body table th {
    background: #f1f5f9;
    color: #1e2a3a;
    font-weight: 600;
    text-align: left;
    padding: 10px 14px;
    border: 1px solid #e2e8f0;
}

.legal-body table td {
    padding: 10px 14px;
    border: 1px solid #e2e8f0;
    vertical-align: top;
}

.legal-body table tr:nth-child(even) {
    background: #f8fafc;
}

/* --- Footer legal --- */
.legal-footer {
    background: #f8fafc;
    border-top: 1px solid #e2e8f0;
    padding: 24px 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

.legal-footer-links {
    display: flex;
    gap: 16px;
    align-items: center;
    flex-wrap: wrap;
}

.legal-footer-links a {
    color: #64748b;
    text-decoration: none;
    font-size: 13.5px;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: color 0.2s;
}

.legal-footer-links a:hover {
    color: #2a5298;
}

.legal-footer-links .separator {
    color: #cbd5e1;
    font-size: 12px;
}

.legal-footer-copy {
    color: #94a3b8;
    font-size: 12.5px;
}

/* --- Responsive --- */
@media (max-width: 768px) {
    .legal-container {
        padding: 20px 12px;
    }

    .legal-header {
        padding: 24px 20px;
    }

    .legal-body {
        padding: 24px 20px;
    }

    .legal-footer {
        padding: 20px;
        flex-direction: column;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .legal-header h1 {
        font-size: 1.3rem;
    }

    .legal-body {
        font-size: 13.5px;
    }
}
