/**
 * Nombre del archivo: style.css
 * Creador: Jose Manuel Reyes
 * Descripción: Estilos globales, Efectos Polaroid, Galería y Layout Responsivo.
 * Actualización: Añadidos estilos de Landing Page (Index) para limpiar PHP.
 */

:root {
    --monica-purple: #6f42c1;
    --monica-blue: #0056b3;
    --shadow-soft: 0 4px 15px rgba(0,0,0,0.05);
    --shadow-polaroid: 0 4px 10px rgba(0,0,0,0.15);
}

/* =====================================================
   BLOQUE 1: ESTRUCTURA BASE (FULL WIDTH)
   ===================================================== */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f4f6f8;
    color: #333;
    margin: 0;
    min-height: 100vh;
}

.container {
    background-color: #fff;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    width: 95%;
    max-width: 100%; 
    overflow: hidden;
    margin: 20px auto;
}

/* =====================================================
   BLOQUE 2: GALERÍA Y EFECTOS POLAROID (MANTENIDO)
   ===================================================== */
.galeria-contenedor {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    padding: 15px;
    justify-items: center;
}

.foto-marco {
    background: white;
    padding: 10px 10px 25px 10px;
    box-shadow: var(--shadow-polaroid);
    transform: rotate(-2deg);
    transition: transform 0.3s, box-shadow 0.3s;
    width: 100%;
    max-width: 140px;
}

.foto-marco:nth-child(even) {
    transform: rotate(3deg);
}

.foto-marco:hover {
    transform: rotate(0deg) scale(1.05);
    z-index: 10;
    box-shadow: 0 8px 20px rgba(0,0,0,0.2);
}

.foto-marco img {
    width: 100%;
    height: 120px;
    object-fit: cover;
    filter: sepia(0.2) contrast(1.1);
}

.foto-texto {
    font-family: 'Permanent Marker', cursive;
    text-align: center;
    font-size: 0.8rem;
    color: #555;
    margin-top: 10px;
}

/* =====================================================
   BLOQUE 3: SELECTOR DE IDIOMAS (MANTENIDO)
   ===================================================== */
.lang-selector-wrapper {
    display: flex;
    justify-content: flex-end;
    padding: 10px;
}

.lang-active-box {
    cursor: pointer;
    background: #fff;
    padding: 5px 12px;
    border-radius: 20px;
    border: 1px solid #ddd;
    font-weight: bold;
    font-size: 0.9rem;
    user-select: none;
    transition: background 0.2s;
}

.lang-dropdown-content {
    display: none;
    position: absolute;
    background: white;
    box-shadow: 0 8px 16px rgba(0,0,0,0.1);
    border-radius: 8px;
    z-index: 100;
    min-width: 100px;
    top: 45px;
}

.lang-dropdown-content.show-menu {
    display: block;
}

.lang-option-btn {
    display: block;
    width: 100%;
    padding: 10px;
    border: none;
    background: none;
    text-align: left;
    cursor: pointer;
    font-size: 0.9rem;
    border-bottom: 1px solid #f0f0f0;
}

/* =====================================================
   BLOQUE 4: LAYOUT RESPONSIVE SPLIT-SCREEN
   ===================================================== */
.split-layout {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    width: 100%;
}

.split-side-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background: linear-gradient(135deg, #0056b3, #00b4db);
    color: white;
    padding: 40px 20px;
    text-align: center;
}

.split-side-form {
    flex: 1.5;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 30px 15px;
    background-color: #f4f6f8;
}

.container-split {
    width: 100%;
    max-width: 400px;
}

/* AJUSTES PC (ACTUALIZADO PARA FOTOS GRANDES) */
@media (min-width: 769px) {
    .split-layout {
        flex-direction: row;
    }
    .split-side-info {
        flex: 1;
        height: 100vh;
        position: sticky;
        top: 0;
        padding: 60px;
    }
    .split-side-form {
        flex: 1.2;
        min-height: 100vh;
    }
    .galeria-contenedor {
        grid-template-columns: repeat(4, 1fr);
    }
    /* Corrección: Fotos grandes en PC */
    .foto-marco {
        max-width: 100%;
        transform: rotate(0deg);
    }
    .foto-marco img {
        height: 220px;
    }
}

/* =====================================================
   BLOQUE 5: COMPONENTES Y BOTONES (MANTENIDO)
   ===================================================== */
.btn-premium {
    display: block;
    width: 100%;
    padding: 16px;
    font-size: 1rem;
    font-weight: 700;
    text-transform: uppercase;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    text-align: center;
    text-decoration: none;
}

.btn-premium:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.15);
}

.msg-box {
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    text-align: center;
    border: 1px solid transparent;
}
.msg-box.error { background: #f8d7da; color: #721c24; border-color: #f5c6cb; }
.msg-box.success { background: #d4edda; color: #155724; border-color: #c3e6cb; }

/* =====================================================
   BLOQUE 6: PIE DE PÁGINA
   ===================================================== */
.footer {
    background-color: #fff;
    border-top: 1px solid #eee;
    padding: 40px 5% 20px 5%;
    margin-top: 60px;
    width: 100%;
    box-sizing: border-box;
}

.footer-container {
    max-width: 100%; 
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 30px;
}

.footer-section {
    flex: 1;
    min-width: 200px;
}

.footer-brand h3 { margin-top: 0; color: #333; }
.footer-slogan { font-style: italic; color: #666; font-size: 0.95rem; max-width: 300px; }
.footer-links-list { list-style: none; padding: 0; margin: 0; }
.footer-links-list li { margin-bottom: 10px; }
.footer-links-list a { text-decoration: none; color: #0056b3; font-size: 0.9rem; transition: color 0.2s; }
.footer-links-list a:hover { color: #003d82; text-decoration: underline; }

.footer-logout-box { text-align: center; width: 100%; margin-bottom: 40px; }
.btn-salir-footer {
    display: inline-block;
    padding: 10px 30px;
    border: 2px solid #dc3545;
    color: #dc3545;
    border-radius: 50px;
    text-decoration: none;
    font-weight: bold;
    transition: all 0.3s;
}
.btn-salir-footer:hover { background: #dc3545; color: #fff; }

.footer-bottom {
    border-top: 1px solid #f0f0f0;
    margin-top: 40px;
    padding-top: 20px;
    text-align: center;
    color: #999;
    font-size: 0.85rem;
    width: 100%;
}

@media (max-width: 768px) {
    .footer-container { flex-direction: column; text-align: center; }
}

/* =====================================================
   BLOQUE 7: ESTILOS LANDING (HOME) - NUEVO
   ===================================================== */
.landing-hero {
    text-align: center;
    margin-bottom: 40px;
    padding: 0 30px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}
.landing-hero h1 { color: #0056b3; font-size: 2rem; margin-bottom: 15px; }
.landing-hero p { font-size: 1.1rem; color: #666; line-height: 1.6; }

.landing-buttons-wrapper {
    margin-top: 50px;
    padding: 0 30px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}
.landing-buttons-wrapper a { width: 100%; }
.btn-green-gradient { background: linear-gradient(135deg, #28a745, #218838); color: white; }
.btn-blue-gradient { background: linear-gradient(135deg, #0056b3, #004085); color: white; }

.landing-info-box {
    background-color: #FFF5F5;
    padding: 35px 25px;
    text-align: center;
    border-radius: 12px;
    border: 1px solid #FED7D7;
    margin: 40px auto 20px auto;
    max-width: 800px;
}
.landing-info-badge {
    background: #fff; color: #e53e3e; padding: 6px 12px;
    border-radius: 20px; font-size: 0.75rem; font-weight: bold;
    border: 1px solid #FEB2B2; display: inline-block; margin-bottom: 15px;
}
.landing-info-title { font-size: 1.4rem; margin-bottom: 15px; color: #c53030; }
.landing-info-desc { font-size: 0.95rem; color: #7b3434; line-height: 1.6; }


/* =========================================
   AJUSTES MÓVIL: CORAZÓN, AMISTAD Y PLANES
   ========================================= */
@media (max-width: 600px) {

    /* 1. CENTRAR CORAZÓN Y BOTÓN AMISTAD */
    .friends-grid {
        justify-content: center !important; /* Fuerza el centrado del grupo */
        gap: 20px; /* Un poco más de espacio entre avatares */
    }

    .friend-item {
        /* Asegura que cada amigo/corazón sea una columna centrada */
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: flex-start;
        width: 100px; /* Un poco más ancho para que quepa el botón */
    }

    .soulmate-circle {
        margin: 0 auto; /* Centrado del círculo */
    }

    .btn-add-mini {
        /* Botón "Conectar" o "Amistad" perfectamente centrado */
        margin: 8px auto 0 auto !important; 
        display: block;
        width: 100%;
        max-width: 90px; /* Que no sea gigante */
        text-align: center;
    }

    /* 2. GESTOR DE PLANES (Estilo Móvil Tarjeta) */
    /* Centramos el título de la sección de planes */
    div[data-id="planes"] .section-header {
        justify-content: center;
        position: relative;
    }
    
    div[data-id="planes"] .section-header h3 {
        text-align: center;
        width: 100%;
    }
    
    div[data-id="planes"] .section-drag-handle {
        position: absolute;
        right: 0;
        top: 0;
    }

    /* Tarjetas de planes: Diseño vertical para que se lea mejor */
    .plan-mini-card {
        flex-direction: column;
        text-align: center;
        padding: 15px;
        gap: 10px;
    }

    .plan-date-box {
        margin-bottom: 5px;
        width: 50px; 
        height: 50px;
    }

    .plan-info {
        width: 100%;
    }

    .plan-title {
        font-size: 1rem;
        margin-bottom: 5px;
        white-space: normal; /* Permite que el título ocupe varias líneas */
    }

    .plan-arrow {
        transform: rotate(90deg); /* Flecha hacia abajo */
        margin-top: 5px;
        color: #6f42c1;
    }
}

