/* Reset básico */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* Estilos globales */
body {
  background-image: url('fondo.webp'), url('fondo.jpg'); /* Respaldo para navegadores sin soporte WebP */
  background-color: #fff8f3; /* Color de respaldo */
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-attachment: fixed; /* Compatible con Safari móvil */
  font-family: 'Noto Sans', sans-serif;
  color: #d2d2d279;
  position: relative;
}

@media (max-width: 768px) {
  body {
    background-attachment: scroll; /* Asegura scroll en móvil */
  }
}

/* Overlay oscuro */
body::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.3);
  z-index: -1;
  pointer-events: none; /* Evita interferencia con interacciones */
}

/* Loader */
.loader {
  position: fixed;
  inset: 0;
  background: #fffaf5;
  color: #7a4e3d;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Roboto', sans-serif;
  font-size: 2rem;
  z-index: 9999;
  opacity: 1;
  transition: opacity 0.5s ease-out;
  -webkit-transition: opacity 0.5s ease-out; /* Compatibilidad con Safari */
}

@keyframes desaparecer {
  to { opacity: 0; visibility: hidden; }
  from { opacity: 1; }
}

/* Header */
.header {
  position: sticky;
  top: 0;
  background-color: rgba(255, 255, 255, 0.6);
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
  z-index: 1000;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.04);
  padding: 1rem 0 1.5rem;
  transition: padding 0.5s ease-out, background-color 0.5s ease-out;
  -webkit-transition: padding 0.5s ease-out, background-color 0.5s ease-out; /* Compatibilidad con Safari */
}

.header.shrink {
  padding: 0.5rem 0 0.8rem;
  background-color: rgba(255, 255, 255, 0.6);
  transition: padding 0.1s ease-out, background-color 0.1s ease-out;
  -webkit-transition: padding 0.1s ease-out, background-color 0.1s ease-out;
}

.contenedor-header {
  max-width: 500px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.logo-img {
  max-width: 80px;
  height: fit-content;
  transition: transform 0.3s ease;
  -webkit-transition: transform 0.3s ease;
}

.logo-img:hover {
  transform: scale(0.95);
}

.menu {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 1.2rem;
  margin-top: b;
  opacity: 1;
  transition: opacity 0.3s ease;
  -webkit-transition: opacity 0.3s ease;
}

.menu a {
  color: #872b4d;
  font-weight: 300;
  font-size: 1rem;
  text-decoration: none;
  position: relative;
  padding-bottom: 1px;
  transition: color 0.3s ease;
  -webkit-transition: color 0.3s ease;
}

.menu a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 1px;
  background-color: #a84163;
  transition: width 0.3s ease;
  -webkit-transition: width 0.3s ease;
}

.menu a:hover::after {
  width: 100%;
}

.menu a:hover {
  color: #a84163;
}

.header.shrink .menu {
  opacity: 0;
  height: 0;
  pointer-events: none;
}

/* Presentación */
.presentacion {
  padding: 13rem 2rem;
  text-align: center;
  animation: aparecer 1s ease-in-out forwards;
  opacity: 0;
}

.presentacion h1 {
  font-size: 3.5rem;
  font-family: 'Roboto', sans-serif;
  color: #f9f9f9;
  margin-bottom: 1rem;
  letter-spacing: 2px;
}

.presentacion p {
  font-size: 1.3rem;
  max-width: 750px;
  margin: 0 auto 2rem;
  line-height: 1.8;
}

.boton {
  background-color: #872b4d;
  color: white;
  padding: 0.75rem 1.5rem;
  text-decoration: none;
  font-weight: bold;
  font-family: 'Roboto', sans-serif;
  border-radius: 50px;
  transition: background 0.3s ease, transform 0.3s ease;
  -webkit-transition: background 0.3s ease, transform 0.3s ease;
}

.boton:hover {
  background-color: #a84163;
  transform: scale(1.05);
}

@keyframes aparecer {
  to { opacity: 1; transform: translateY(0); }
  from { opacity: 0; transform: translateY(30px); }
}

/* Footer */
.footer-elegante {
  background-color: #a84163;
  color: white;
  padding: 40px 60px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  font-family: 'Noto Sans', sans-serif;
}

.footer-logo-texto {
  display: flex;
  align-items: center;
  gap: 20px;
}

.footer-logo img {
  max-width: 80px;
  height: auto;
}

.footer-subtitulo p {
  color: rgb(255, 255, 255);
  font-size: 12px;
}

.footer-info {
  text-align: right;
  max-width: 900px;
  font-size: 12px;
}

.footer-info a {
  color: white;
  text-decoration: none;
  margin: 0 5px;
}

.footer-info a:hover {
  text-decoration: underline;
}

.footer-redes {
  margin: 1rem 0;
}

.footer-redes a {
  color: white;
  margin: 0 10px;
  font-size: 1.5rem;
  transition: color 0.3s ease;
  -webkit-transition: color 0.3s ease;
}

.footer-redes a:hover {
  color: #f0f0f0;
}

/* Sección Sobre Mí */
.sobre-mi {
  padding: 6rem 2rem;
  text-align: center;
  background-color: #fff8f3;
  animation: aparecer 1s ease-in-out forwards;
  opacity: 0;
}

.sobre-mi h1 {
  font-size: 3rem;
  font-family: 'Roboto', sans-serif;
  color: #872b4d;
  margin-bottom: 2rem;
}

.contenido-sobre-mi {
  max-width: 1000px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  align-items: center;
  justify-content: center;
}

.img-sobre-mi {
  max-width: 300px;
  border-radius: 1rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease;
  -webkit-transition: transform 0.3s ease;
}

.img-sobre-mi:hover {
  transform: scale(1.05);
}

.texto-sobre-mi {
  max-width: 600px;
  text-align: left;
  color: #333;
  font-size: 1.1rem;
  line-height: 1.8;
}

.texto-sobre-mi p {
  margin-bottom: 1.5rem;
}

.texto-sobre-mi .boton {
  display: inline-block;
  margin-top: 1rem;
}

/* Galería previa */
.galeria-previa {
  padding: 4rem 2rem;
  text-align: center;
  background-color: #fff8f3;
}

.galeria-previa h2 {
  font-size: 2.5rem;
  font-family: 'Roboto', sans-serif;
  color: #872b4d;
  margin-bottom: 1rem;
}

.galeria-previa p {
  font-size: 1.2rem;
  color: #333;
  max-width: 800px;
  margin: 0 auto 2rem;
}

.grid-galeria-previa {
  display: grid;
  gap: 2rem;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  max-width: 1200px;
  margin: 0 auto 2rem;
}

.img-galeria {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-radius: 10px;
  transition: transform 0.3s ease;
  -webkit-transition: transform 0.3s ease;
  cursor: pointer;
}

.img-galeria:hover {
  transform: scale(1.05);
}

/* Cómo trabajamos */
.trabajo {
  padding: 4rem 2rem;
  text-align: center;
  background-color: white;
}

.trabajo h2 {
  font-size: 2.5rem;
  font-family: 'Roboto', sans-serif;
  color: #872b4d;
  margin-bottom: 2rem;
}

.contenido-trabajo {
  max-width: 800px;
  margin: 0 auto;
  color: #333;
  font-size: 1.1rem;
  line-height: 1.8;
}

.contenido-trabajo p {
  margin-bottom: 1.5rem;
}

.contenido-trabajo ul {
  list-style: none;
  margin: 1.5rem 0;
  text-align: left;
}

.contenido-trabajo li {
  margin-bottom: 1rem;
  position: relative;
  padding-left: 1.5rem;
}

.contenido-trabajo li:before {
  content: '✦';
  color: #872b4d;
  position: absolute;
  left: 0;
}

/* Contacto */
.contacto {
  padding: 4rem 2rem;
  text-align: center;
  background-color: #fff8f3;
}

.contacto h2 {
  font-size: 2.5rem;
  font-family: 'Roboto', sans-serif;
  color: #872b4d;
  margin-bottom: 1rem;
}

.contacto p {
  font-size: 1.2rem;
  color: #333;
  max-width: 800px;
  margin: 0 auto 2rem;
}

.formulario {
  max-width: 600px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.formulario label {
  text-align: left;
  color: #333;
  font-size: 1.1rem;
}

.formulario input,
.formulario textarea {
  padding: 0.75rem;
  border: 1px solid #ccc;
  border-radius: 5px;
  font-size: 1rem;
  font-family: 'Noto Sans', sans-serif;
}

.formulario textarea {
  resize: vertical;
  min-height: 100px;
}

.formulario button {
  align-self: center;
}

/* Lightbox (para galería previa) */
.lightbox {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.85);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  opacity: 0;
  transition: opacity 0.5s ease-in-out;
  -webkit-transition: opacity 0.5s ease-in-out;
}

.lightbox.show {
  display: flex;
  opacity: 1;
}

.lightbox img {
  max-width: 90%;
  max-height: 80%;
  border: 5px solid white;
  border-radius: 12px;
  transition: transform 0.3s ease;
  -webkit-transition: transform 0.3s ease;
}

.lightbox img:hover {
  transform: scale(1.05);
}

/* Galería de lujo */
.galeria-lujo {
  padding: 6rem 2rem;
  text-align: center;
  background-color: #fff8f3;
  min-height: 100vh;
}

.galeria-lujo h1 {
  font-size: 3.5rem;
  font-family: 'Roboto', sans-serif;
  color: #872b4d;
  margin-bottom: 1rem;
}

.galeria-lujo .subtitulo {
  font-size: 1.3rem;
  color: #333;
  max-width: 800px;
  margin: 0 auto 3rem;
  line-height: 1.8;
}

.grid-galeria-lujo {
  display: grid;
  gap: 2rem;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  padding: 0 2rem;
  max-width: 1400px;
  margin: 0 auto;
}

.manton-card {
  background: white;
  border-radius: 12px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  -webkit-transition: transform 0.3s ease, box-shadow 0.3s ease;
  text-align: left;
  padding-bottom: 1.5rem;
}

.manton-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.manton-img {
  width: 100%;
  height: 300px;
  object-fit: cover;
  border-bottom: 2px solid #872b4d;
}

.manton-card h3 {
  font-size: 1.6rem;
  font-family: 'Roboto', sans-serif;
  color: #872b4d;
  margin: 1rem 1.5rem 0.5rem;
}

.manton-card p {
  font-size: 1rem;
  color: #333;
  margin: 0 1.5rem 1rem;
  line-height: 1.6;
}

.boton-ver {
  display: block;
  margin: 0 auto;
  background-color: #872b4d;
  color: white;
  padding: 0.75rem 1.5rem;
  text-decoration: none;
  font-family: 'Roboto', sans-serif;
  border-radius: 50px;
  border: none;
  cursor: pointer;
  transition: background 0.3s ease, transform 0.3s ease;
  -webkit-transition: background 0.3s ease, transform 0.3s ease;
}

.boton-ver:hover {
  background-color: #a84163;
  transform: scale(1.05);
}

/* Lightbox de lujo */
.lightbox-lujo {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.9);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  opacity: 0;
  transition: opacity 0.5s ease-in-out;
  -webkit-transition: opacity 0.5s ease-in-out;
}

.lightbox-lujo.show {
  display: flex;
  opacity: 1;
}

.lightbox-lujo img {
  max-width: 90%;
  max-height: 80%;
  border: 5px solid #fff;
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  transition: transform 0.3s ease;
  -webkit-transition: transform 0.3s ease;
}

.lightbox-lujo img:hover {
  transform: scale(1.02);
}

/* Botón de volver arriba */
.scroll-top {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background-color: #872b4d;
  color: white;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  text-decoration: none;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease;
  -webkit-transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease;
  z-index: 1000;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  font-size: 1.2rem;
}

.scroll-top.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.scroll-top:hover {
  background-color: #a84163;
  transform: scale(1.1);
}

.scroll-top i {
  line-height: 1;
}

/* Desplazamiento suave */
html {
  scroll-behavior: smooth;
}

/* Testimonios */
.testimonios {
  padding: 4rem 2rem;
  text-align: center;
  background-color: #fff8f3;
}

.testimonios h2 {
  font-size: 2.5rem;
  font-family: 'Roboto', sans-serif;
  color: #872b4d;
  margin-bottom: 2rem;
}

.grid-testimonios {
  display: grid;
  gap: 2rem;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  max-width: 1200px;
  margin: 0 auto;
}

.testimonio-card {
  background: white;
  border-radius: 12px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
  padding: 2rem;
  text-align: left;
}

.testimonio-card p {
  font-size: 1.1rem;
  color: #333;
  line-height: 1.6;
  margin-bottom: 1rem;
}

.testimonio-card h3 {
  font-size: 1.2rem;
  font-family: 'Roboto', sans-serif;
  color: #872b4d;
}

/* Páginas legales */
.legal {
  padding: 6rem 2rem;
  text-align: center;
  background-color: #fff8f3;
}

.legal h1 {
  font-size: 3rem;
  font-family: 'Roboto', sans-serif;
  color: #872b4d;
  margin-bottom: 2rem;
}

.contenido-legal {
  max-width: 800px;
  margin: 0 auto;
  text-align: left;
  color: #333;
  font-size: 1.1rem;
  line-height: 1.8;
}

/* Media Queries */
@media screen and (max-width: 768px) {
  body { background-attachment: scroll; }
  body::before { background: rgba(0, 0, 0, 0.3); }
  .presentacion { padding: 10rem 1rem; }
  .presentacion h1 { font-size: 2.5rem; }
  .presentacion p { font-size: 1.1rem; }
  .sobre-mi h1,
  .galeria-previa h2,
  .trabajo h2,
  .contacto h2,
  .galeria-lujo h1,
  .testimonios h2,
  .legal h1 { font-size: 2.5rem; }
  .contenido-sobre-mi { flex-direction: column; text-align: center; }
  .texto-sobre-mi { text-align: center; }
  .img-sobre-mi { max-width: 250px; }
  .grid-galeria-previa,
  .grid-galeria-lujo,
  .grid-testimonios { grid-template-columns: 1fr; }
  .img-galeria,
  .manton-img { height: 250px; }
  .galeria-lujo { padding: 4rem 1rem; }
  .galeria-lujo .subtitulo { font-size: 1.1rem; }
  .manton-card h3 { font-size: 1.4rem; }
  .contenido-trabajo ul { text-align: center; }
  .contenido-trabajo li:before { display: none; }
  .footer-elegante { flex-direction: column; align-items: flex-start; gap: 20px; text-align: left; }
  .footer-info { text-align: left; }
  .scroll-top { width: 35px; height: 35px; font-size: 1rem; bottom: 15px; right: 15px; }
}