/* === PROFILE - Glassmorphism Theme === */

body {
    font-family: Arial, Helvetica, sans-serif;
    min-height: 100vh;
    position: relative;
}

h1 {
    margin-top: 40px;
    color: #0099ff;
    text-align: center;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.2);
    position: relative;
    z-index: 1;
}

h2 {
    text-align: left;
}

.panel_alerts{
    position: fixed;
    top: 40px;
    right: 40px;
    color: #fff;
    z-index: 100;
    background: rgba(0, 20, 40, 0.6);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 14px;
    padding: 12px 20px;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.5);
    box-shadow: 0 4px 16px rgba(0, 153, 255, 0.25);
}

/* Glassmorphism card for sections */
.section-card {
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 20px;
    box-shadow: 0 16px 48px rgba(0, 153, 255, 0.2);
    padding: 24px;
    margin: 20px auto;
    max-width: 1100px;
    width: 95%;
    position: relative;
    z-index: 1;
    box-sizing: border-box;
}

table {
    width: 100%;
    border-radius: 8px;
    border:solid 4px #0099ff;
    padding: 0;
}

th {
    color: #fff;
    background: rgba(0, 153, 255, 0.4);
    padding: 12px 14px;
    border: none;
    font-weight: 600;
}

td {
    color: #fff;
    padding: 12px 14px;
    border: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    text-shadow: 1px 1px 3px rgba(0,0,0,0.3);
}

td a {
    color: #53baff;
    text-decoration: none;
}

td a:hover {
    text-decoration: underline;
}

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

th{
    background-color: #0099ff;
}

td{
    background-color: #ceebff;
    color: #0099ff;   
}

tbody{
    border-radius: 14px !important;
}

.addmovbut {
    position: fixed;
    bottom: 10px;
    left: 10px;
    color: white;
    font-size: medium;
    background: linear-gradient(135deg, #0099ff, #53baff);
    padding: 10px 20px;
    text-decoration: none;
    font-family: arial;
    border-radius: 14px;
    border: none;
    box-shadow: 0 4px 16px rgba(0, 153, 255, 0.3);
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 100;
}

.addmovbut:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 28px rgba(0, 153, 255, 0.5);
}

.ayuda{
    left: 240px;
}

.ayuda2{
    left: 10px;
}

.editmovbut {
    color: white;
    background: linear-gradient(135deg, #0099ff, #53baff) !important;
    padding: 10px 20px;
    text-decoration: none;
    font-family: arial;
    border-radius: 14px;
    border: none;
    box-shadow: 0 4px 16px rgba(0, 153, 255, 0.3);
    cursor: pointer;
    transition: all 0.3s ease;
}

.editmovbut:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 28px rgba(0, 153, 255, 0.5);
}

.editmovbut2 {
    color: white;
    background: linear-gradient(135deg, #0099ff, #53baff) !important;
    padding: 10px 20px;
    text-decoration: none;
    font-family: arial;
    border-radius: 14px;
    border: none;
    box-shadow: 0 4px 16px rgba(0, 153, 255, 0.3);
    cursor: pointer;
    transition: all 0.3s ease;
}

.editmovbut2:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 28px rgba(0, 153, 255, 0.5);
}

/* Popup glassmorphism override */
#newMovieForm,
#newEditForm {
    background: rgba(0, 10, 30, 0.65) !important;
    backdrop-filter: blur(24px) !important;
    -webkit-backdrop-filter: blur(24px) !important;
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
    border-radius: 20px !important;
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.5) !important;
    color: #fff !important;
    text-align: left !important;
    width: 620px !important;
    max-width: 90vw !important;
    padding: 28px !important;
    max-height: 85vh;
    overflow-y: auto;
    left: calc(50% - 310px) !important;
}

/* 2-column grid for popup form fields */
.popup-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
    margin-bottom: 16px;
}

.popup-field {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.popup-field label {
    color: rgba(255,255,255,0.8);
    font-size: 0.85em;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.popup-field input {
    width: 100%;
    border: 2px solid rgba(0, 153, 255, 0.25);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.9);
    color: #333;
    padding: 10px 14px;
    font-size: 0.95em;
    font-family: Arial, Helvetica, sans-serif;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.popup-field input:focus {
    border-color: #0099ff;
    box-shadow: 0 0 0 4px rgba(0, 153, 255, 0.15);
    outline: none;
}

.popup-genres {
    margin-bottom: 16px;
}

.popup-genres h2 {
    color: #fff;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.3);
    margin-top: 0;
    margin-bottom: 12px;
    text-align: center;
    font-size: 1.1em;
}

.popup-actions {
    display: flex;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}

/* Genre buttons */
.genre-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 6px 12px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.3s ease;
    width: auto;
    margin: 3px 5px;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.2);
}

.genre-button input {
    display: none;
}

.genre-button:hover {
    background: rgba(0, 153, 255, 0.25);
    border-color: #0099ff;
    color: white;
}

.genre-button input:checked + span {
    background: linear-gradient(135deg, #0099ff, #53baff);
    color: white;
    text-align: center;
    width: 100%;
    padding: 2px 8px;
    border-radius: 14px;
}



@media (max-width: 768px) {
    .section-card {
        padding: 16px;
        width: 98%;
    }

    .popup-grid {
        grid-template-columns: 1fr;
    }

    #newMovieForm,
    #newEditForm {
        width: 95vw !important;
        left: 2.5vw !important;
        padding: 16px !important;
    }

    th, td {
        padding: 8px 10px;
        font-size: 0.85em;
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 1.4em;
    }

    .section-card {
        padding: 12px;
        overflow-x: auto;
    }

    th, td {
        padding: 6px 8px;
        font-size: 0.75em;
    }

    .genre-button {
        font-size: 11px;
        padding: 4px 8px;
    }
}


/* === Control de datos del usuario (22-oct) — clases pf-, no afectan a help.php === */

.pf-contenedor {
    padding: 10px 0 60px;
    position: relative;
    z-index: 1;
}

.pf-contenedor .section-card {
    max-width: 720px;
    background: rgba(0, 20, 50, 0.35);   /* algo más oscuro para leer bien sobre el degradado claro */
}

.pf-contenedor .section-card h1 {
    margin-top: 0;
    font-size: 1.6em;
    color: #fff;
    text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.4);
}

.pf-nota {
    color: rgba(255, 255, 255, 0.9);
    text-align: center;
    line-height: 1.6;
    margin: 0 0 16px;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.3);
}

/* Los <select> con el mismo aspecto que los inputs de .popup-field */
.popup-field select {
    width: 100%;
    border: 2px solid rgba(0, 153, 255, 0.25);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.9);
    color: #333;
    padding: 10px 14px;
    font-size: 0.95em;
    font-family: Arial, Helvetica, sans-serif;
    box-sizing: border-box;
}

.popup-field select:focus {
    border-color: #0099ff;
    box-shadow: 0 0 0 4px rgba(0, 153, 255, 0.15);
    outline: none;
}

.pf-ancho { grid-column: 1 / -1; }

/* Mensajes de éxito / error (sobre .panel_alerts) */
.pf-alerta { max-width: calc(100% - 80px); font-size: 1em; text-align: center; }
.pf-alerta--ok { border-color: rgba(39, 174, 96, 0.8); background: rgba(20, 90, 50, 0.75); }
.pf-alerta--error { border-color: rgba(231, 76, 60, 0.8); background: rgba(110, 25, 20, 0.75); }

/* Zona de peligro */
.pf-peligro {
    border-color: rgba(231, 76, 60, 0.6) !important;
    box-shadow: 0 16px 48px rgba(231, 76, 60, 0.25) !important;
}

.pf-btn-peligro {
    color: #fff;
    background: linear-gradient(135deg, #c0392b, #e74c3c);
    padding: 10px 20px;
    font-family: arial;
    font-size: 1em;
    border-radius: 14px;
    border: none;
    box-shadow: 0 4px 16px rgba(231, 76, 60, 0.35);
    cursor: pointer;
    transition: all 0.3s ease;
}

.pf-btn-peligro:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 28px rgba(231, 76, 60, 0.5);
}

/* Ventana de confirmación de eliminación */
.pf-modal {
    display: none;
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 99999;
    background: rgba(0, 0, 0, 0.6);
    align-items: center;
    justify-content: center;
}

.pf-modal-caja {
    background: rgba(40, 8, 8, 0.85);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid rgba(231, 76, 60, 0.6);
    border-radius: 20px;
    padding: 28px;
    width: 420px;
    max-width: 90vw;
    box-sizing: border-box;
    color: #fff;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.pf-modal-caja h2 { margin: 0; text-align: center; color: #fff; }
.pf-modal-caja p { margin: 0 0 6px; text-align: center; line-height: 1.5; }
.pf-modal-caja form { display: flex; flex-direction: column; gap: 12px; }

@media (max-width: 600px) {
    .pf-alerta { right: 10px; left: 10px; max-width: none; top: 130px; }
    .pf-contenedor .section-card h1 { font-size: 1.3em; }
}

/* === Aportes en el perfil (22-oct) === */
.popup-field textarea {
    width: 100%;
    border: 2px solid rgba(0, 153, 255, 0.25);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.9);
    color: #333;
    padding: 10px 14px;
    font-size: 0.95em;
    font-family: Arial, Helvetica, sans-serif;
    box-sizing: border-box;
    resize: vertical;
}

.popup-field textarea:focus {
    border-color: #0099ff;
    box-shadow: 0 0 0 4px rgba(0, 153, 255, 0.15);
    outline: none;
}

.pf-enlace { color: #fff; font-weight: bold; }

.pf-check {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    text-align: left;
    color: #fff;
    margin: 0 0 16px;
    line-height: 1.5;
    cursor: pointer;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.3);
}

.pf-check input { margin-top: 4px; width: 18px; height: 18px; flex-shrink: 0; }

.pf-tabla-scroll { overflow-x: auto; }

/* Editar y Eliminar uno encima del otro: la tabla cabe sin cortarse */
.pf-opciones form { margin: 0; }
.pf-opciones .pf-mini { display: block; width: 100%; margin: 3px 0; }

.pf-mini {
    color: #fff;
    background: linear-gradient(135deg, #0099ff, #53baff);
    border: none;
    border-radius: 10px;
    padding: 6px 12px;
    font-size: 0.85em;
    cursor: pointer;
    margin: 2px;
}

.pf-mini--peligro { background: linear-gradient(135deg, #c0392b, #e74c3c); }

.pf-modal-caja--azul {
    background: rgba(0, 15, 40, 0.88);
    border-color: rgba(0, 153, 255, 0.6);
    width: 520px;
    max-height: 90vh;
    overflow-y: auto;
}
