/* ESTILOS PRINCIPALES (ajusta según ya tengas) */
:root {
  --bg: #000;
  --fg: #fff;
  --card: #fff;
  --text: #000;
  --border: #333;
}

* { box-sizing: border-box; }

html, body { height: 100%; }
body { font-family: Arial, sans-serif; color: var(--fg); margin: 0; background: var(--bg); }

/* CONTENEDOR PRINCIPAL */
.contenedor { width: 100%; max-width: 1200px; margin: 0 auto; padding: 20px; }

/* BARRA DE FILTROS (si ya la tienes, conserva) */

/* ===========================
   filtros_pubg.css
   Estilo PUBG para buscador
   =========================== */

.filtros {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 500px;
  margin: 20px auto;
  padding: 10px 15px;
  background: linear-gradient(135deg, #2b2b2b, #3c3c3c);
  border: 2px solid #c9a959;
  border-radius: 12px;
  box-shadow: 0 0 12px rgba(201,169,89,0.7);
  position: relative;
}

.filtros input[type="text"] {
  flex: 1;
  padding: 10px 12px 10px 35px;
  font-size: 1em;
  font-family: 'Orbitron', sans-serif;
  border: 1px solid #c9a959;
  border-radius: 8px;
  background: rgba(255,255,255,0.1);
  color: #fff;
  outline: none;
  transition: 0.3s;
}

.filtros input[type="text"]::placeholder {
  color: #ccc;
  font-style: italic;
}

.filtros input[type="text"]:focus {
  background: rgba(255,255,255,0.15);
  box-shadow: 0 0 10px #c9a959;
  border-color: #c9a959;
}

.icono_buscador {
  position: absolute;
  left: 12px;
  font-size: 1.2em;
  color: #c9a959;
  pointer-events: none;
}

/* ================= Dark Mode ================= */
body.dark-mode .filtros {
  background: linear-gradient(135deg, #1c1c1c, #2a2a2a);
  border: 2px solid #ffcc33;
  box-shadow: 0 0 12px rgba(255,204,51,0.6);
}

body.dark-mode .filtros input[type="text"] {
  border: 1px solid #ffcc33;
  color: #fff;
  background: rgba(255,255,255,0.05);
}

body.dark-mode .filtros input[type="text"]:focus {
  box-shadow: 0 0 10px #ffcc33;
  border-color: #ffcc33;
}

body.dark-mode .icono_buscador {
  color: #ffcc33;
}


/*--------------------------------------*/

/*----------TITULO----------*/
/* ===========================
   contenedor_edicion_pubg.css
   Estilo PUBG para edición de personaje
   =========================== */

.contenedor_edicion_del_personaje {
  width: 100%;
  text-align: center;
  margin: 15px 0;
  padding: 12px 0;
  background: linear-gradient(135deg, #3c3c3c, #2b2b2b);
  border: 2px solid #c9a959;
  border-radius: 10px;
  box-shadow: 0 0 12px rgba(201,169,89,0.7);
  position: relative;
}

.edicion_del_personaje {
  font-family: 'Orbitron', sans-serif;
  font-size: 1.2em;
  font-weight: bold;
  color: #fff;
  text-shadow: 0 0 4px #c9a959, 0 0 8px rgba(201,169,89,0.7);
}

/* ================= Dark Mode ================= */
body.dark-mode .contenedor_edicion_del_personaje {
  background: linear-gradient(135deg, #1c1c1c, #2a2a2a);
  border: 2px solid #ffcc33;
  box-shadow: 0 0 12px rgba(255,204,51,0.6);
}

body.dark-mode .edicion_del_personaje {
  text-shadow: 0 0 4px #ffcc33, 0 0 8px rgba(255,204,51,0.7);
  color: #fff;
}


/*------------------------------*/

/* CONTENEDOR DE CUADROS (GRID FLEX) */
.grid-flex {
  display: flex;
  flex-wrap: wrap;
  gap: 16px; /* espaciado entre cuadros */
  align-items: stretch;
  padding: 6px;
  width: 100%;
  /* Asegura que ocupe todo el ancho disponible */
  box-sizing: border-box;
}

/* Cuadro individual (título arriba, imagen abajo) */
.contenedor-cuadro {
  display: flex;
  flex-direction: column;
  width: 100%;            /* toma ancho de la celda asignada por el layout padre */
  min-height: 180px;
  background: #fff;
  color: #000;
  box-shadow: 0 2px 6px rgba(0,0,0,.5);
  border-radius: 6px;
  overflow: hidden;
  position: relative;
}

.contenedor-boton-titulo {
    display: flex;
    border-bottom: 1px solid #C8C8C8;
}

.contenedor-boton button {
    background: #DC0101;
    cursor: pointer;
    padding: .25rem .5rem;
    font-size: .875rem;
    line-height: 1.5;
    border-radius: .2rem;
    color: #f8f9fa;
    border-color: #f8f9fa;
    box-shadow: inset 1px -2px 5px 1px rgba(0,0,0,0.5);
    margin: 2px;
}

.contenedor-titulo {
  margin: auto;
  font-weight: bold;
  color: #000;
  background: #fff;
}
.contenedor-titulo span {
  display: inline-block;
  width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Imagen debajo */
.contenedor-img {
  width: 100%;
  height: 150px;
  background: #c8c8c8;
  display: flex;
}
.contenedor-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Overlay desenfoque/click (opcional) */
.contenedor-desenfoque {
  position: absolute; z-index: 1; width: 100%; height: 80%; top: 40; left: 0;
    background: rgba(0,0,0,0.5);
    display: none;
}
.contenedor-cuadro:hover .contenedor-desenfoque {
    display: block;
}

.contenedor-cuadro .contenedor-desenfoque:hover  textarea {
    display: block;
    
}

.contenedor-desenfoque .click textarea {
    display: none;
    background: none;   
    color: white;
    width: 100%;
    margin: 5px;
    border: none;
    font-size: 13px;
    }


/* MODAL (mantiene igual) */
.modal {
  display: none; position: fixed; z-index: 1000;
  left: 0; top: 0; width: 100%; height: 100%;
  overflow: auto; background-color: rgba(0,0,0,0.4); z-index: 10000;
}
.modal-content {
  background-color: #fefefe; margin: 5% auto; padding: 20px;
  border: 1px solid #888; width: 80%; max-width: 800px;
}
body.dark-mode .modal-content {
    background-color: #000;
}
.close { color: #aaa; float: right; font-size: 28px; font-weight: bold; }
.close:hover, .close:focus { color: black; text-decoration: none; cursor: pointer; }
iframe { width: 100%; height: 500px; }

/* BREAKPOINTS: FLEXBOX (4/3/2/1) */

/* 4 por fila ≥ 1024px */
@media (min-width: 1024px) {
  .grid-flex > .contenedor-cuadro {
    flex: 0 0 calc((100% - 3 * 16px) / 4);
  }
    
    
}
/* 3 por fila entre 768px y 1023px */
@media (min-width: 768px) and (max-width: 1023px) {
  .grid-flex > .contenedor-cuadro {
    flex: 0 0 calc((100% - 2 * 16px) / 3);
  }
    
}
/* 2 por fila entre 460px y 767px */
@media (min-width: 461px) and (max-width: 767px) {
  .grid-flex > .contenedor-cuadro {
    flex: 0 0 calc((100% - 1 * 16px) / 2);  
  }
}
/* 1 por fila ≤ 460px */
@media (max-width: 460px) {
  .grid-flex > .contenedor-cuadro {
    flex: 0 0 100%;
  }
    
}


/*ESTILOS DE LOS BOTONES 3D, TITULO Y SUBTITULO*/
.contenedor-boton_titulo {
    display: flex;
    align-items: center;
    justify-content: space-between;
}


/*.contenedor-titulo {
    flex: 1 1 auto;
    min-width: 0;
}*/

.contenedor-boton button {  
    width: 100%;
    cursor: pointer;
    box-shadow: inset 1px -2px 5px 1px rgba(0,0,0,0.5);
    margin: 3px;
}
.contenedor-boton button img {
    width: 25px;
}

.contenedor-subtitulo {
    text-align: center;
}
/*----------------------*/


/* 4 por fila ≥ 1024px */
@media (min-width: 1024px) {
  .contenedor-cuadro {
    flex: 0 0 calc((100% - 3 * 16px) / 4);
  }
    .contenedor-titulo span {
    font-size: clamp(10px, 1.3vw, 17px);  
}
}

/* 3 por fila entre 768px y 1023px */
@media (min-width: 768px) and (max-width: 1023px) {
  .contenedor-cuadro {
    flex: 0 0 calc((100% - 2 * 16px) / 3);
  }
    .contenedor-titulo span {
    font-size: clamp(10px, 1.7vw, 20px);
    
        
}
}

/* 2 por fila entre 461px y 767px */
@media (min-width: 461px) and (max-width: 767px) {
  .contenedor-cuadro {
    flex: 0 0 calc((100% - 16px) / 2);  
  }
    .contenedor-titulo span {
    font-size: clamp(10px, 2.3vw, 20px);
    white-space: nowrap;
        text-overflow: ellipsis;
        overflow: hidden;
        min-width: 0;
}
    
}

/* 1 por fila ≤ 460px */
@media (max-width: 460px) {
  .contenedor-cuadro {
    flex: 0 0 100%;
  }
}


/*-------------------------FIN---------------------------*/