.encabezado-artista {
    background-color: #000;
    color: #fff;
    text-align: center;
    padding: 60px 20px;
  }

  .encabezado-artista h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 30px;
  }

  .volver-btn {
    background-color: #fff;
    color: #000;
    padding: 12px 30px;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 600;
    transition: background-color 0.3s, color 0.3s;
  }

  .volver-btn:hover {
    background-color: #b3b3b3;
    color: #000;
  }

  .galeria {
    padding: 50px 20px;
    background-color: #f2f2f2;
    text-align: center;
  }

  .galeria h2 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 40px;
  }

  .grid-galeria {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
    justify-content: center; /* CENTRA las columnas si hay menos que el espacio total */
    align-items: center;     /* CENTRA verticalmente en caso de que haga falta */
    justify-items: center;   /* CENTRA cada imagen dentro de su celda */
  }


 .grid-galeria img {
    width: 100%;
    height: 400px;
    object-fit: contain; /* ✔ Muestra toda la imagen, sin recorte */

    border-radius: 5px;
    cursor: pointer;
    transition: transform 0.3s;
  }

  .grid-galeria img:hover {
    transform: scale(1.05);
  }

  .modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.9);
    justify-content: center;
    align-items: center;
    flex-direction: column;
    text-align: center;
    padding: 20px;
    overflow: auto; /* Permite que se vea todo en pantallas chicas */
  }

  .modal-contenedor {
    position: relative;
    width: 100%;
    max-width: 600px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    max-height: 75vh; /* Para dejar lugar a la instrucción */
  }

  .modal-contenido {
    max-width: 90vw;
    max-height: 80vh;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 5px;
  }

  .cerrar {
    position: absolute;
    top: 20px;
    right: 30px;
    color: #fff;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
  }

  .overlay-texto {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    font-size: 1.5rem;
    padding: 20px;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
    border-radius: 5px;
  }

  .modal-contenedor:hover .overlay-texto {
    opacity: 1;
  }

 .instruccion {
      color: #fff;
      margin-top: 20px;
      font-size: 1.3rem;
      font-weight: bold;
      background-color: #000;
      padding: 12px 24px;
      border-radius: 8px;
      display: inline-block;
    }

  @media screen and (max-width: 768px) {
    .grid-galeria {
        grid-template-columns: 1fr;
        justify-items: center;
    }

    .encabezado-artista h1 {
      font-size: 1.8rem;
    }

    .volver-btn {
      padding: 10px 20px;
      font-size: 0.95rem;
    }

    .overlay-texto {
      font-size: 1rem;
      padding: 10px;
    }

    .instruccion {
      font-size: 1rem;
      padding: 8px 16px;
    }

    .modal-contenedor {
      max-width: 90%;
      max-height: 80%;
    }

    .modal-contenido {
      width: 100%;
    }
  }