:root {
  --terracota: #e1933f;
  --terracota-oscuro: #a45d28;
  --gris: #f8f8f8;
  --negro: #222;
}

/* ===== RESET ===== */
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { font-family: "Poppins", sans-serif; color: var(--negro); background: #fff; }

/* ===== HEADER ===== */
header {
  background: var(--terracota);
  display: flex; 
  justify-content: space-between; 
  align-items: center;
  padding: 10px 50px 10px 50px;
  flex-wrap: wrap;
}
.logo-container { 
  display: flex; 
  align-items: center; 
  gap: 10px; 
  flex-shrink: 0; 
}
.brand-logo { 
  width: 100px; 
  height: auto; 
  object-fit: contain; 
  filter: none; 
}
.logo-text { 
  font-size: 1.6rem; 
  font-weight: 700; 
  color: #fff; 
}

nav ul { 
  display: flex; 
  list-style: none; 
  gap: 25px; 
  flex-wrap: wrap; 
}
nav ul li a {
  color: #fff; 
  text-decoration: none; 
  font-weight: 500; 
  transition: color .3s;
}
nav ul li a:hover, 
nav ul li a.active { 
  color: #ffe8d2; 
}

/* ===== HERO ===== */
.hero-galeria {
  position: relative;
  height: 45vh;
  background: url("imagenes/banner-galeria.png") center/cover no-repeat;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: #fff;
}
.hero-galeria .overlay { 
  position: absolute; 
  inset: 0; 
  background: rgba(0, 0, 0, 0.45); 
}
.hero-text { 
  position: relative; 
  z-index: 2; 
  max-width: 800px; 
  padding: 0 20px; 
}
.hero-text h1 { 
  font-size: 2.8rem; 
  font-weight: 700; 
  margin-bottom: 10px; 
}
.hero-text p { 
  font-size: 1.2rem; 
}

/* ===== FILTROS ===== */
.galeria-filtros-container { 
  text-align: center; 
  padding: 60px 20px 20px; 
}
.subtitulo { 
  font-size: 1.8rem; 
  color: var(--terracota-oscuro); 
  margin-bottom: 25px; 
}
.galeria-filtros {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px;
}
.filtro {
  background-color: #fff;
  border: 2px solid var(--terracota-oscuro);
  color: var(--terracota-oscuro);
  padding: 10px 22px;
  border-radius: 25px;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.3s ease;
}
.filtro:hover, 
.filtro.activo {
  background-color: var(--terracota-oscuro);
  color: #fff;
  box-shadow: 0 0 10px rgba(164, 93, 40, 0.4);
}

/* ===== GALERÍA ===== */
.galeria-grid {
  max-width: 1400px;
  margin: 40px auto 100px;
  padding: 0 50px;
  display: grid;
  gap: 50px;
}
.grid-categoria {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 35px;
  justify-items: center;
}
.card {
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
  transition: transform .3s ease, box-shadow .3s ease;
  cursor: pointer;
}
.card img {
  width: 100%;
  height: 230px;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}
.card:hover { 
  transform: scale(1.03); 
  box-shadow: 0 8px 22px rgba(0,0,0,0.2); 
}
.card:hover img { 
  transform: scale(1.05); 
}

/* ===== LIGHTBOX ===== */
.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.85);
  justify-content: center;
  align-items: center;
  z-index: 9999;
}
.lightbox.activo { 
  display: flex; 
  animation: fadeIn 0.3s ease; 
}
@keyframes fadeIn { 
  from {opacity: 0;} 
  to {opacity: 1;} 
}
.lightbox-img {
  max-width: 90%;
  max-height: 85vh;
  border-radius: 10px;
  box-shadow: 0 0 25px rgba(0,0,0,0.6);
  object-fit: contain;
}
.cerrar, .anterior, .siguiente {
  position: absolute;
  color: #fff;
  cursor: pointer;
  font-size: 2.5rem;
  transition: 0.2s;
  user-select: none;
}
.cerrar { 
  top: 20px; 
  right: 30px; 
}
.anterior { 
  left: 60px; 
  top: 50%; 
  transform: translateY(-50%); 
}
.siguiente { 
  right: 60px; 
  top: 50%; 
  transform: translateY(-50%); 
}
.cerrar:hover, 
.anterior:hover, 
.siguiente:hover { 
  color: var(--terracota); 
  transform: scale(1.2); 
}

/* ===== FOOTER ===== */
footer {
  background: #fff;
  border-top: 3px solid var(--terracota);
  padding: 40px 20px;
}
.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: flex-start;
  align-items: flex-start;
  gap: 100px;
  flex-wrap: wrap;
  text-align: left;
  transform: translateX(210px);
}
@media (max-width: 1200px) { 
  .footer-container { 
    transform: none; 
    justify-content: center; 
  } 
}
.footer-col h3 { 
  color: var(--terracota-oscuro); 
  margin-bottom: 15px;
  font-size: 1.1rem;
}
.footer-col p {
  color: #333; 
  margin-bottom: 10px; 
  font-size: .95rem;
  line-height: 1.6;
}
.footer-col a {
  color: #333; 
  font-size: .95rem; 
  text-decoration: none;
  display: block;
  margin-bottom: 8px;
  transition: color 0.3s;
}
.footer-col a:hover {
  color: var(--terracota);
}
.footer-col p i { 
  margin-right: 8px;
  width: 16px;
  display: inline-block;
  text-align: center;
  color: var(--terracota-oscuro);
}
.social-icons { 
  margin-top: 15px;
  display: flex;
  gap: 5px;
}
.social-icons a {
  display: flex; 
  justify-content: center; 
  align-items: center;
  width: 40px; 
  height: 40px; 
  border-radius: 50%;
  border: 2px solid var(--terracota-oscuro); 
  color: var(--terracota-oscuro);
  font-size: 1.1rem; 
  transition: .3s;
  text-decoration: none;
  padding: 0;
}
.social-icons a i {
  display: block;
  line-height: 1;
}
.social-icons a:hover {
  background: var(--terracota-oscuro); 
  color: #fff; 
  transform: translateY(-3px);
}
.copyright {
  text-align: center; 
  color: var(--terracota-oscuro); 
  margin-top: 20px; 
  font-size: .9rem;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
  .hero-text h1 { font-size: 2.2rem; }
  .galeria-filtros-container { padding: 40px 10px; }
  .grid-categoria { gap: 25px; }
  .anterior, .siguiente { font-size: 2rem; }
}
@media (max-width: 600px) {
  .hero-galeria { height: 35vh; }
  .hero-text h1 { font-size: 1.8rem; }
  .hero-text p { font-size: 1rem; }
  .galeria-grid { padding: 0 20px; gap: 30px; }
  .card img { height: 200px; }
  .anterior, .siguiente { display: none; }
}