@font-face {

  font-family: 'URW Bookman';

  src: url('../fonts/BodoniFLF-Roman.ttf') format('truetype');

  font-weight: 300;

  font-style: italic;

  font-display: swap;

}



/* ===== VARIABLES / CONFIGURACIÓN GLOBAL ===== */

:root {
  --color-bg: #ffffff;
  --color-text: #f9f2f6;
  --color-accent: #e0bd94;
  --color-light: #f5f5f5;

  --font-heading: 'URW Bookman', 'Georgia', serif;
  --font-body: 'URW Bookman', 'Georgia', serif;

  --spacing-unit: 1rem;
  --max-width: 1200px;
}

/* ===== RESET / GLOBAL STYLES ===== */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  color: var(--color-text);
  background-color: var(--color-bg);
  line-height: 1.6;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  text-decoration: none;
  color: inherit;
}

/* ===== CONTENEDOR RESPONSIVE ===== */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1rem;
}

@media (min-width: 768px) {
  .container {
    padding: 0 1.5rem;
  }
}

@media (min-width: 1024px) {
  .container {
    padding: 0 2rem;
  }
}

/* ===== HEADER RESPONSIVE ===== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background: #1C301C;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  z-index: 999;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.header.hide {
  transform: translateY(-100%);
}

.header.show {
  transform: translateY(0);
}

.header-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.75rem 1rem;
  min-height: 60px;
}

/* MOBILE - Stack vertical */
@media (max-width: 767px) {
  .header-container {
    flex-direction: column;
    padding: 0.5rem 1rem;
    gap: 0.5rem;
  }

  .logo {
    font-size: 1.3rem;
    margin-bottom: 0.25rem;
  }
}

/* TABLET */
@media (min-width: 768px) and (max-width: 1023px) {
  .header-container {
    padding: 1rem 1.5rem;
    min-height: 70px;
  }
}

/* DESKTOP */
@media (min-width: 1024px) {
  .header-container {
    padding: 1rem 2rem;
    min-height: 80px;
  }
}

/* Logo responsive */
.logo {
  font-size: 1.5rem;
  font-family: var(--font-heading);
  font-weight: bold;
  white-space: nowrap;
}

@media (max-width: 767px) {
  .logo {
    font-size: 1.3rem;
    text-align: center;
  }
}

@media (min-width: 768px) and (max-width: 1023px) {
  .logo {
    font-size: 1.6rem;
  }
}

@media (min-width: 1024px) {
  .logo {
    font-size: 1.8rem;
  }
}

/* ===== NAVIGATION RESPONSIVE ===== */
.nav-list {
  list-style: none;
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  justify-content: center;
}

.nav-list a {
  color: #f9f2f6 !important;
  text-decoration: none;
}

.header .nav-list a,
.header .nav-list li a {
  color: #f9f2f6 !important;
}

/* MOBILE */
@media (max-width: 767px) {
  .nav-list {
    gap: 0.25rem;
    width: 100%;
    justify-content: center;
    padding: 0.25rem 0;
  }

  .nav-list li {
    flex: 0 0 auto;
  }

  .nav-list a {
    padding: 0.35rem 0.5rem;
    font-size: 0.85rem;
    white-space: nowrap;
  }
}

/* TABLET */
@media (min-width: 768px) and (max-width: 1023px) {
  .nav-list {
    gap: 0.75rem;
  }

  .nav-list a {
    padding: 0.4rem 0.75rem;
    font-size: 0.95rem;
  }
}

/* DESKTOP */
@media (min-width: 1024px) {
  .nav-list {
    gap: 1rem;
  }

  .nav-list a {
    padding: 0.5rem 1rem;
    font-size: 1rem;
  }
}

/* Efectos hover (solo desktop/tablet) */
@media (hover: hover) and (pointer: fine) {
  .nav-list li a {
    position: relative;
    padding: 6px 10px;
    border-radius: 5px;
    transition: 0.3s ease;
  }

  .nav-list li a:hover {
    background-color: rgba(0, 0, 0, 0.15);
    color: var(--color-accent);
  }

  .nav-list li a::after {
    content: "";
    width: 0%;
    height: 2px;
    background: var(--color-accent);
    position: absolute;
    left: 50%;
    bottom: -4px;
    transition: 0.3s ease;
    transform: translateX(-50%);
  }

  .nav-list li a:hover::after {
    width: 100%;
  }
}

/* Para dispositivos táctiles */
@media (hover: none) and (pointer: coarse) {
  .nav-list li a:active {
    background-color: rgba(255, 255, 255, 0.1);
    color: var(--color-accent);
    transform: scale(0.98);
  }
}

/* Ajustes para pantallas muy pequeñas */
@media (max-width: 360px) {
  .nav-list {
    gap: 0.15rem;
  }

  .nav-list a {
    padding: 0.3rem 0.4rem;
    font-size: 0.8rem;
  }

  .logo {
    font-size: 1.2rem;
  }
}

/* Ajustes para pantallas grandes */
@media (min-width: 1400px) {
  .container {
    max-width: 1300px;
  }

  .nav-list {
    gap: 1.5rem;
  }
}

/* Asegurar que el contenido no quede debajo del header fijo */
main {
  margin-top: 60px;
}

@media (min-width: 768px) {
  main {
    margin-top: 70px;
  }
}

@media (min-width: 1024px) {
  main {
    margin-top: 80px;
  }
}



/* Para evitar que el header tape contenido */
body {
  padding-top: 80px;
  /* Espacio para el header fijo */
}

/* Espacio extra para secciones principales */
.gallery,
.collaborations,
section:first-of-type {
  padding-top: 2rem;
}

/* ===== HERO ===== */
.hero {
  position: relative;
  width: 100%;
  height: 100vh;
  min-height: 600px;
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  overflow: hidden;
  padding: 0;
}

/* Capa semitransparente para que el texto siempre se lea */
.hero-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  /* Aumenté la opacidad para mejor contraste */
  z-index: 2;
}

/* Contenido centrado */
.hero-content {
  position: relative;
  z-index: 3;
  max-width: 900px;
  padding: 0 1.5rem;
}






/* Video - Ajustado para evitar zoom excesivo */
.hero-video {
  position: absolute;
  top: 0;
  left: 50%;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 38%; /* 🔥 CLAVE */
  transform: translateX(-50%);
  z-index: 1;
}




/* ===== MEDIA QUERIES PARA HERO ===== */

/* Tablet (768px - 1023px) */
@media (min-width: 768px) and (max-width: 1023px) {
  body {
    padding-top: 80px;
  }

  .hero {
    min-height: 600px;
    padding: 0 2rem;
  }

  .hero-title {
    font-size: 2.5rem;
    margin-bottom: 1rem;
  }

  .hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 1.5rem;
  }

  .hero-content {
    padding: 0 2rem;
  }
}

/* Desktop (1024px en adelante) */
@media (min-width: 1024px) {
  body {
    padding-top: 100px;
    /* Altura original para desktop */
  }

  .hero {
    min-height: 700px;
    padding: 0;
  }

  .hero-title {
    font-size: 3rem;
    margin-bottom: var(--spacing-unit);
  }

  .hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: var(--spacing-unit);
  }

  .hero-content {
    padding: 0;
  }
}

/* Pantallas muy grandes */
@media (min-width: 1400px) {
  .hero {
    min-height: 800px;
  }

  .hero-title {
    font-size: 3.5rem;
  }

  .hero-subtitle {
    font-size: 1.5rem;
  }
}

/* Para móviles en orientación horizontal */
@media (max-height: 500px) and (orientation: landscape) {
  .hero {
    min-height: 400px;
    height: auto;
    padding: 4rem 1rem;
  }
}

/* ===== SECCIÓN PROYECTOS ===== */
.section {
  padding: 3rem 0;
  /* Reducido para móviles */
}

.section-title {
  font-family: var(--font-heading);
  font-size: 1.75rem;
  /* Tamaño base para móvil */
  margin-bottom: 1.5rem;
  text-align: center;
  color: #333;
  padding: 0 1rem;
}

/* Fondo general de la página */
body {
  background-color: #f8f8f8;
}

.projects-section {
  background-color: #fafafa;
  padding: 3rem 5%;
  /* Padding reducido para móviles */
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  /* Gap reducido para móviles */
  justify-items: center;
  padding: 0 1rem;
}

.project-card {
  background-color: #ffffff;
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  text-align: center;
  width: 100%;
  /* Ancho 100% para adaptarse al contenedor */
  max-width: 320px;
  /* Máximo ancho */
  height: auto;
  /* Altura automática para móviles */
  min-height: 400px;
  /* Altura mínima */
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.project-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.1);
}

.project-image {
  width: 100%;
  height: 200px;
  /* Altura reducida para móviles */
  overflow: hidden;
  background-color: #fff;
}

.project-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.project-card:hover img {
  transform: scale(1.05);
}

.project-info {
  flex-grow: 1;
  padding: 1rem 0.75rem 1.5rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.project-info h3 {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  /* Tamaño reducido para móviles */
  margin-bottom: 0.4rem;
  color: #333;
  letter-spacing: 0.5px;
  line-height: 1.3;
}

.project-info p {
  font-size: 0.85rem;
  /* Tamaño reducido para móviles */
  color: #666;
  line-height: 1.5;
}

/* ===== MEDIA QUERIES PARA PROYECTOS ===== */

/* Tablet (768px - 1023px) */
@media (min-width: 768px) and (max-width: 1023px) {
  .section {
    padding: 4rem 0;
  }

  .section-title {
    font-size: 2.25rem;
    margin-bottom: 2rem;
  }

  .projects-section {
    padding: 4rem 6%;
  }

  .projects-grid {
    gap: 2.5rem;
    padding: 0 2rem;
  }

  .project-card {
    height: 420px;
  }

  .project-image {
    height: 220px;
  }

  .project-info h3 {
    font-size: 1.2rem;
  }

  .project-info p {
    font-size: 0.9rem;
  }
}

/* Desktop (1024px en adelante) */
@media (min-width: 1024px) {
  .section {
    padding: 6rem 0;
    /* Espacio original para desktop */
  }

  .section-title {
    font-size: 2.5rem;
    margin-bottom: 2rem;
    padding: 0;
  }

  .projects-section {
    padding: 5rem 0;
  }

  .projects-grid {
    gap: 3rem;
    padding: 0;
  }

  .project-card {
    width: 320px;
    /* Ancho fijo original */
    height: 400px;
    /* Alto fijo original */
  }

  .project-image {
    height: 250px;
    /* Altura original */
  }

  .project-info {
    padding: 1.2rem 1rem 1.8rem;
    /* Padding original */
  }

  .project-info h3 {
    font-size: 1.3rem;
    /* Tamaño original */
  }

  .project-info p {
    font-size: 0.95rem;
    /* Tamaño original */
  }
}

/* Pantallas pequeñas (menos de 480px) */
@media (max-width: 480px) {
  .projects-grid {
    grid-template-columns: 1fr;
    /* Una columna en móviles muy pequeños */
    gap: 1.5rem;
  }

  .project-card {
    max-width: 300px;
    min-height: 380px;
  }

  .project-image {
    height: 180px;
  }

  .section-title {
    font-size: 1.5rem;
  }
}

/* Para tablets en orientación vertical */
@media (min-width: 600px) and (max-width: 767px) and (orientation: portrait) {
  .projects-grid {
    grid-template-columns: repeat(2, 1fr);
    /* 2 columnas en tablets pequeñas */
  }
}

/* Ajustes para pantallas muy grandes */
@media (min-width: 1400px) {
  .projects-section {
    padding: 6rem 8%;
    /* Padding original para pantallas grandes */
  }

  .projects-grid {
    gap: 4rem;
  }
}



/* ===== SOBRE MÍ ===== */
.sobre-mi {
  background-color: #efefef;
  /* gris */
  width: 100%;
  padding: 6rem 2rem;
}

.sobre-mi .idea-container {
  max-width: 900px;
  margin: 0 auto;
}

.about-image {
  flex: 1 1 100%;
  min-height: 300px;
  max-height: 400px;
  background-color: #ddd;
  border-radius: 12px;
  overflow: hidden;
  object-fit: cover;
}

.about-text {
  flex: 1 1 100%;
  padding: 0 0.5rem;
}

.about-text h2 {
  font-family: var(--font-heading);
  font-size: 1.75rem;
  margin-bottom: 1rem;
  color: #333;
}

.about-text p {
  font-size: 1rem;
  line-height: 1.6;
  color: #555;
  margin-bottom: 1rem;
}

/* ===== FOOTER ===== */
.footer {
  background-color: #1C301C;
  color: #f9f7f2;
  padding: 2rem 1rem 1rem;
  text-align: center;
}

/* ----- CONTENEDOR PRINCIPAL ----- */
.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

/* ----- IZQUIERDA: LOGO + NOMBRE ----- */
.footer-left {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  text-align: center;
}

.footer-logo {
  width: 120px;
  height: 120px;

  object-fit: cover;

}

.logo-info {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.logo-name {
  font-weight: bold;
  font-size: 1.3rem;
  color: #ffffff;
  margin-bottom: 0.5rem;
}

.footer-copy {
  font-size: 0.9rem;
  color: #f9f7f2;
  line-height: 1.5;
}

/* ----- DERECHA: LINKS Y CONTACTO ----- */
.footer-right {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  text-align: center;
}

.footer-links-col,
.footer-personal-col {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.footer-links-col h4,
.footer-personal-col h4 {
  margin-bottom: 1rem;
  font-weight: bold;
  color: #e0bd94;
  font-size: 1.1rem;
}

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
}

.footer-links li {
  margin-bottom: 0.3rem;
}

/* ----- ESTILOS UNIFICADOS PARA ENLACES DE NAVEGACIÓN ----- */
.footer-links li a {
  position: relative;
  padding: 8px 12px;
  border-radius: 5px;
  color: #ffffff;
  text-decoration: none;
  transition: all 0.3s ease;
  display: inline-block;
  font-size: 0.95rem;
}

.footer-links li a:hover {
  background-color: rgba(255, 255, 255, 0.1);
  color: var(--color-accent);
}

.footer-links li a::after {
  content: "";
  width: 0%;
  height: 2px;
  background: var(--color-accent);
  position: absolute;
  left: 50%;
  bottom: -2px;
  transition: 0.3s ease;
  transform: translateX(-50%);
}

.footer-links li a:hover::after {
  width: 100%;
}

/* ----- LÍNEA SEPARADORA ----- */
.footer-divider {
  width: 90%;
  max-width: 900px;
  margin: 1.5rem auto 1.5rem;
  height: 1px;
  background-color: rgba(255, 255, 255, 0.2);
}

/* ----- REDES SOCIALES CENTRADAS ----- */
.footer-social {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 0.5rem;
  flex-wrap: wrap;
}

.footer-social a {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 42px;
  height: 42px;
  background-color: #f9f7f2;
  color: #1c301c;
  border-radius: 50%;
  font-size: 1.2rem;
  transition: all 0.3s ease;
}

.footer-social a:hover {
  background-color: #e0bd94;
  color: #f9f7f2;
  transform: scale(1.1);
}

/* ----- COPYRIGHT FINAL ----- */
.footer-bottom {
  font-size: 0.85rem;
  color: #f9f7f2;
  padding-top: 1rem;
}

/* ===== MEDIA QUERIES ===== */

/* Tablet (600px - 767px) */
@media (min-width: 600px) and (max-width: 767px) {
  .about-section {
    padding: 4rem 0;
  }

  .about-section .about-container {
    padding: 0 2rem;
    gap: 2rem;
  }

  .about-image {
    flex: 1 1 45%;
    min-height: 350px;
  }

  .about-text {
    flex: 1 1 50%;
    padding: 0 1rem;
  }

  .about-text h2 {
    font-size: 2rem;
  }

  .about-text p {
    font-size: 1.05rem;
  }

  .footer {
    padding: 2.5rem 1.5rem 1.5rem;
  }

  .footer-container {
    flex-direction: row;
    align-items: flex-start;
    justify-content: space-between;
  }

  .footer-left {
    flex: 1;
    align-items: flex-start;
    text-align: left;
  }

  .logo-info {
    align-items: flex-start;
  }

  .footer-right {
    flex: 1;
    flex-direction: row;
    justify-content: space-around;
    text-align: left;
  }

  .footer-links-col,
  .footer-personal-col {
    align-items: flex-start;
  }

  .footer-links {
    align-items: flex-start;
  }
}

/* Tablet grande (768px - 1023px) */
@media (min-width: 768px) and (max-width: 1023px) {
  .about-section .about-container {
    padding: 0 3rem;
    gap: 3rem;
  }

  .about-image {
    flex: 1 1 40%;
    min-height: 400px;
  }

  .about-text {
    flex: 1 1 55%;
    padding: 0;
  }

  .about-text h2 {
    font-size: 2.25rem;
  }

  .about-text p {
    font-size: 1.1rem;
  }

  .footer {
    padding: 3rem 2rem 1.5rem;
  }

  .footer-logo {
    width: 140px;
    height: 140px;
  }

  .footer-right {
    flex-direction: row;
    gap: 3rem;
    text-align: left;
  }

  .footer-links-col,
  .footer-personal-col {
    align-items: flex-start;
  }

  .footer-links {
    align-items: flex-start;
  }

  .footer-social {
    gap: 1.2rem;
  }
}

/* Desktop (1024px en adelante) */
@media (min-width: 1024px) {
  .about-section {
    padding: 6rem 0;
  }

  .about-section .about-container {
    padding: 0 2rem;
    gap: 4rem;
    flex-wrap: nowrap;
  }

  .about-image {
    flex: 1 1 300px;
    min-height: 450px;
    max-height: 500px;
  }

  .about-text {
    flex: 1 1 400px;
    padding: 0 1rem;
  }

  .about-text h2 {
    font-size: 2.5rem;
  }

  .about-text p {
    font-size: 1.15rem;
  }

  .footer {
    padding: 3rem 2rem 1rem;
  }

  .footer-container {
    flex-direction: row;
    align-items: flex-start;
    justify-content: space-between;
    gap: 2rem;
  }

  .footer-left {
    flex-direction: row;
    align-items: center;
    text-align: left;
    flex: 1;
  }

  .logo-info {
    align-items: flex-start;
  }

  .footer-right {
    flex-direction: row;
    gap: 3rem;
    text-align: left;
    flex: 1;
    justify-content: flex-end;
  }

  .footer-links-col,
  .footer-personal-col {
    align-items: flex-start;
  }

  .footer-links {
    align-items: flex-start;
  }

  .footer-links li a {
    padding: 6px 10px;
    font-size: 1rem;
  }
}

/* Pantallas muy grandes (1400px en adelante) */
@media (min-width: 1400px) {
  .about-section .about-container {
    max-width: 1300px;
    margin: 0 auto;
    padding: 0;
  }

  .footer-container {
    max-width: 1300px;
  }
}

/* Ajustes para móviles pequeños (< 360px) */
@media (max-width: 359px) {
  .about-section .about-container {
    padding: 0 0.5rem;
    gap: 1rem;
  }

  .about-image {
    min-height: 250px;
  }

  .about-text h2 {
    font-size: 1.5rem;
  }

  .about-text p {
    font-size: 0.95rem;
  }

  .footer-logo {
    width: 100px;
    height: 100px;
  }

  .footer-social a {
    width: 38px;
    height: 38px;
    font-size: 1.1rem;
  }
}



/* ===== LOGO DEL HEADER RESPONSIVE ===== */
.logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  /* Espacio reducido para móviles */
  font-family: var(--font-heading);
  font-weight: bold;
  font-size: 1rem;
  /* Tamaño base para móviles */
  color: var(--color-text);
  transition: all 0.3s ease;
}

.logo-img {
  width: 35px;
  /* Tamaño reducido para móviles */
  height: 35px;

  object-fit: cover;

  transition: all 0.3s ease;
}

.logo-text {
  font-size: 1.1rem;
  /* Tamaño reducido para móviles */
  font-weight: normal;
  white-space: nowrap;
  letter-spacing: 0.5px;
}

/* ===== MEDIA QUERIES PARA LOGO ===== */

/* Tablet (600px - 767px) */
@media (min-width: 600px) and (max-width: 767px) {
  .logo {
    gap: 0.65rem;
    font-size: 1.2rem;
  }

  .logo-img {
    width: 40px;
    height: 40px;
  }

  .logo-text {
    font-size: 1.25rem;
  }
}

/* Tablet grande (768px - 1023px) */
@media (min-width: 768px) and (max-width: 1023px) {
  .logo {
    gap: 0.7rem;
    font-size: 1.3rem;
  }

  .logo-img {
    width: 42px;
    height: 42px;
  }

  .logo-text {
    font-size: 1.35rem;
  }
}

/* Desktop (1024px en adelante) */
@media (min-width: 1024px) {
  .logo {
    gap: 0.75rem;
    font-size: 1.5rem;
  }

  .logo-img {
    width: 45px;
    height: 45px;
  }

  .logo-text {
    font-size: 1.4rem;
  }
}

/* Para pantallas muy grandes */
@media (min-width: 1400px) {
  .logo {
    gap: 0.85rem;
    font-size: 1.6rem;
  }

  .logo-img {
    width: 50px;
    height: 50px;
  }

  .logo-text {
    font-size: 1.5rem;
  }
}

/* Para móviles en orientación horizontal */
@media (max-width: 767px) and (orientation: landscape) {
  .logo-img {
    width: 30px;
    height: 30px;
  }

  .logo-text {
    font-size: 1rem;
  }
}

/* Ajustes para pantallas muy pequeñas (< 360px) */
@media (max-width: 359px) {
  .logo {
    gap: 0.4rem;
  }

  .logo-img {
    width: 30px;
    height: 30px;
  }

  .logo-text {
    font-size: 0.9rem;
  }
}

/* ===== PROYECTOS RESPONSIVE ===== */
.project-card {
  position: relative;
  overflow: hidden;
  border-radius: 12px;
  /* Reducido para móviles */
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.1);
  /* Reducido para móviles */
  cursor: pointer;
  width: 100%;
  max-width: 400px;
  margin: 0 auto;
  height: auto;
  min-height: 250px;
  /* Altura mínima para móviles */
}

.project-card:hover {
  transform: scale(1.03);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15);
}

.project-card a {
  text-decoration: none;
  color: inherit;
  display: block;
  height: 100%;
  width: 100%;
}

.project-image {
  position: relative;
  width: 100%;
  height: 220px;
  /* Altura reducida para móviles */
  overflow: hidden;
  border-radius: 10px;
}

.project-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
  display: block;
}

.project-card:hover img {
  transform: scale(1.1);
}

/* Texto por encima de la imagen */
.project-info {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  z-index: 2;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.8), rgba(0, 0, 0, 0.4), transparent);
  color: #f9f7f2;
  text-align: center;
  padding: 0.6rem 0.5rem;
  /* Padding reducido */
  box-sizing: border-box;
  backdrop-filter: blur(2px);
}

.project-info h3 {
  margin: 0;
  font-size: 1rem;
  /* Reducido para móviles */
  font-weight: 600;
  line-height: 1.2;
}

.project-info p {
  font-size: 0.8rem;
  /* Reducido para móviles */
  margin: 0.2rem 0 0;
  color: #eee;
  line-height: 1.3;
  opacity: 0.9;
}

/* ===== MEDIA QUERIES PARA PROYECTOS ===== */

/* Tablet (600px - 767px) */
@media (min-width: 600px) and (max-width: 767px) {
  .project-card {
    border-radius: 13px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    min-height: 280px;
  }

  .project-image {
    height: 260px;
  }

  .project-info {
    padding: 0.7rem 0.6rem;
  }

  .project-info h3 {
    font-size: 1.1rem;
  }

  .project-info p {
    font-size: 0.85rem;
  }
}

/* Tablet grande (768px - 1023px) */
@media (min-width: 768px) and (max-width: 1023px) {
  .project-card {
    border-radius: 14px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    min-height: 300px;
  }

  .project-image {
    height: 280px;
  }

  .project-info {
    padding: 0.75rem 0.6rem;
  }

  .project-info h3 {
    font-size: 1.15rem;
  }

  .project-info p {
    font-size: 0.88rem;
  }
}

/* Desktop (1024px en adelante) */
@media (min-width: 1024px) {
  .project-card {
    border-radius: 15px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    min-height: 320px;
  }

  .project-image {
    height: 320px;
    /* Altura original */
  }

  .project-info {
    padding: 0.8rem 0.5rem;
    /* Padding original */
  }

  .project-info h3 {
    font-size: 1.2rem;
    /* Tamaño original */
  }

  .project-info p {
    font-size: 0.9rem;
    /* Tamaño original */
  }
}

/* Pantallas grandes (≥ 1400px) */
@media (min-width: 1400px) {
  .project-card {
    max-width: 420px;
    min-height: 340px;
  }

  .project-image {
    height: 340px;
  }

  .project-info h3 {
    font-size: 1.3rem;
  }

  .project-info p {
    font-size: 0.95rem;
  }
}

/* Para móviles en orientación horizontal */
@media (max-width: 767px) and (orientation: landscape) {
  .project-card {
    min-height: 200px;
  }

  .project-image {
    height: 180px;
  }

  .project-info {
    padding: 0.5rem 0.4rem;
  }

  .project-info h3 {
    font-size: 0.9rem;
  }

  .project-info p {
    font-size: 0.75rem;
  }
}

/* Ajustes para pantallas muy pequeñas (< 360px) */
@media (max-width: 359px) {
  .project-card {
    min-height: 220px;
    border-radius: 10px;
  }

  .project-image {
    height: 200px;
  }

  .project-info {
    padding: 0.5rem 0.4rem;
  }

  .project-info h3 {
    font-size: 0.9rem;
  }

  .project-info p {
    font-size: 0.75rem;
    margin: 0.1rem 0 0;
  }
}

/* Ajuste de hover solo para dispositivos que lo soporten */
@media (hover: hover) and (pointer: fine) {
  .project-card:hover {
    transform: scale(1.03);
  }

  .project-card:hover img {
    transform: scale(1.1);
  }
}

/* Para dispositivos táctiles */
@media (hover: none) and (pointer: coarse) {
  .project-card:active {
    transform: scale(0.98);
  }
}





/* ===== EFECTO HOVER RESPONSIVE ===== */
.img-hover {
  position: relative;
  overflow: hidden;
  display: block;
  width: 100%;
  height: 100%;
}

.img-hover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease, filter 0.5s ease;
  display: block;
}

.img-hover:hover img {
  transform: scale(1.1);
  /* zoom */
  filter: brightness(70%);
  /* oscurecer un poco */
}

/* Texto que aparece encima */
.img-hover span {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: white;
  font-family: var(--font-body), Arial, sans-serif;
  opacity: 0;
  transition: opacity 0.4s ease;
  text-align: center;
  width: 90%;
  padding: 0 1rem;
  z-index: 2;
  text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.5);

  /* Tamaño base para móviles */
  font-size: 0.9rem;
  font-weight: 500;
}

.img-hover:hover span {
  opacity: 1;
  /* aparece el texto */
}

/* Fondo semitransparente para mejor legibilidad */
.img-hover::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.3);
  opacity: 0;
  transition: opacity 0.4s ease;
  z-index: 1;
}

.img-hover:hover::after {
  opacity: 1;
}

/* ===== MEDIA QUERIES PARA HOVER EFFECT ===== */

/* Tablet (600px - 767px) */
@media (min-width: 600px) and (max-width: 767px) {
  .img-hover span {
    font-size: 1rem;
  }
}

/* Tablet grande (768px - 1023px) */
@media (min-width: 768px) and (max-width: 1023px) {
  .img-hover span {
    font-size: 1.1rem;
  }
}

/* Desktop (1024px en adelante) */
@media (min-width: 1024px) {
  .img-hover span {
    font-size: 1.2rem;
  }
}

/* Pantallas grandes (≥ 1200px) */
@media (min-width: 1200px) {
  .img-hover span {
    font-size: 1.3rem;
  }
}

/* Pantallas muy grandes (≥ 1400px) */
@media (min-width: 1400px) {
  .img-hover span {
    font-size: 1.4rem;
  }
}

/* Para orientación horizontal en móviles */
@media (max-width: 767px) and (orientation: landscape) {
  .img-hover span {
    font-size: 0.8rem;
  }
}

/* Ajustes para pantallas muy pequeñas (< 360px) */
@media (max-width: 359px) {
  .img-hover span {
    font-size: 0.8rem;
    padding: 0 0.5rem;
  }
}

/* Soporte para dispositivos táctiles */
@media (hover: none) and (pointer: coarse) {
  .img-hover:active img {
    transform: scale(1.05);
    filter: brightness(80%);
  }

  .img-hover:active span {
    opacity: 1;
  }

  .img-hover:active::after {
    opacity: 1;
  }
}

/* ===== ESTILOS PARA EL CORREO EN EL FOOTER RESPONSIVE ===== */
.footer-email {
  color: var(--color-text);
  font-size: 0.85rem;
  /* Reducido para móviles */
  margin-top: 0.4rem;
  display: block;
  line-height: 1.4;
  word-break: break-word;
}

.footer-email-text {
  color: var(--color-text);
  font-size: 0.85rem;
  /* Reducido para móviles */
  margin-top: 0.2rem;
  line-height: 1.4;
  opacity: 0.9;
}

/* ===== MEDIA QUERIES PARA EMAIL ===== */

/* Tablet (600px - 1023px) */
@media (min-width: 600px) and (max-width: 1023px) {

  .footer-email,
  .footer-email-text {
    font-size: 0.9rem;
  }
}

/* Desktop (1024px en adelante) */
@media (min-width: 1024px) {

  .footer-email,
  .footer-email-text {
    font-size: 0.95rem;
  }
}

/* Pantallas grandes */
@media (min-width: 1400px) {

  .footer-email,
  .footer-email-text {
    font-size: 1rem;
  }
}

/* Para móviles en modo paisaje */
@media (max-width: 767px) and (orientation: landscape) {

  .footer-email,
  .footer-email-text {
    font-size: 0.8rem;
  }
}

/* Ajustes para pantallas muy pequeñas (< 360px) */
@media (max-width: 359px) {

  .footer-email,
  .footer-email-text {
    font-size: 0.8rem;
    margin-top: 0.3rem;
  }
}

/* ===== LOGO ANIMADO RESPONSIVE ===== */
.animated-logo {
  opacity: 0;
  transform: scale(0.8) rotate(-5deg);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

/* Clase para cuando el logo ya está animado */
.animated-logo.active {
  opacity: 1;
  transform: scale(1) rotate(0);
}

/* Ajustar velocidad de animación según dispositivo */
@media (prefers-reduced-motion: reduce) {
  .animated-logo {
    transition: none;
  }

  .img-hover img,
  .img-hover span,
  .img-hover::after {
    transition: none;
  }
}

/* Optimización de rendimiento para animaciones */
@media (max-width: 767px) {
  .animated-logo {
    transition-duration: 0.6s;
  }

  .img-hover img,
  .img-hover span,
  .img-hover::after {
    transition-duration: 0.3s;
  }
}

/* Mejora de rendimiento en dispositivos móviles */
@media (max-width: 1024px) {
  .img-hover {
    transform: translateZ(0);
    backface-visibility: hidden;
  }
}

/* ===== AJUSTES ESPECIALES PARA DISPOSITIVOS TÁCTILES ===== */
.touch-device .img-hover:hover img {
  transform: none;
  filter: none;
}

.touch-device .img-hover:hover span {
  opacity: 0;
}

.touch-device .img-hover:active img {
  transform: scale(1.05);
  filter: brightness(75%);
}

.touch-device .img-hover:active span {
  opacity: 1;
}

.touch-device .img-hover:active::after {
  opacity: 1;
}

/* ===== MEJORA DE ACCESIBILIDAD ===== */
@media (prefers-contrast: high) {
  .img-hover span {
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.8);
  }

  .footer-email,
  .footer-email-text {
    color: #ffffff;
    font-weight: 500;
  }
}

@media (prefers-color-scheme: dark) {
  .img-hover span {
    color: #ffffff;
    text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.8);
  }
}

/* Asegurar que el texto del email no se rompa de forma extraña */
.footer-email,
.footer-email-text {
  overflow-wrap: break-word;
  hyphens: auto;
}

/* Mejorar visibilidad en dispositivos con pantalla pequeña */
@media (max-width: 480px) {
  .img-hover span {
    font-weight: 600;
    background: rgba(0, 0, 0, 0.4);
    padding: 0.5rem 0.8rem;
    border-radius: 4px;
  }
}



/* Cuando entra en pantalla 



.animated-logo.visible {

  animation: fadeZoomIn 1.6s ease-out forwards;

}



@keyframes fadeZoomIn {

  0% {

    opacity: 0;

    transform: scale(0.8) rotate(-5deg);

  }

  60% {

    opacity: 1;

    transform: scale(1.05) rotate(2deg);

  }

  100% {

    opacity: 1;

    transform: scale(1) rotate(0deg);

  }

} */







/* Animación del logo */

@keyframes fadeInOut {

  0%,
  100% {

    opacity: 0.3;

    transform: scale(0.95);

  }

  50% {

    opacity: 1;

    transform: scale(1.05);

  }

}



/* Sección de mexico  */



/* ===== SECCIÓN PRODUCTOS ===== */

/* ===== SECCIÓN DE PRODUCTOS RESPONSIVE ===== */
.product-section {
  max-width: 1200px;
  margin: 2rem auto;
  /* Reducido para móviles */
  padding: 0 1rem;
  /* Reducido para móviles */
  width: 100%;
}

.section-title {
  text-align: center;
  font-size: 1.5rem;
  /* Reducido para móviles */
  margin-bottom: 1.5rem;
  font-family: var(--font-heading);
  color: #333;
  padding: 0 0.5rem;
  line-height: 1.3;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.5rem;
  /* Reducido para móviles */
  padding: 0 0.5rem;
}

.product-card {
  background: white;
  border-radius: 8px;
  /* Reducido para móviles */
  overflow: hidden;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.08);
  /* Reducido para móviles */
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.product-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.product-image-container {
  width: 100%;
  height: 180px;
  /* Reducido para móviles */
  overflow: hidden;
  background-color: #f8f8f8;
}

.product-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.product-card:hover .product-image {
  transform: scale(1.05);
}

.product-info {
  padding: 1rem;
  /* Reducido para móviles */
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

.product-title {
  font-size: 1.1rem;
  /* Reducido para móviles */
  margin-bottom: 0.4rem;
  font-weight: bold;
  color: #333;
  line-height: 1.3;
}

.product-price {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.8rem;
  flex-wrap: wrap;
}

.current-price {
  font-size: 1.1rem;
  /* Reducido para móviles */
  font-weight: bold;
  color: #e74c3c;
}

.original-price {
  font-size: 0.9rem;
  /* Reducido para móviles */
  text-decoration: line-through;
  color: #999;
}

.tax-info {
  font-size: 0.75rem;
  /* Reducido para móviles */
  color: #666;
  margin-bottom: 0.8rem;
  line-height: 1.3;
}

.quantity-selector {
  display: flex;
  align-items: center;
  margin-bottom: 1rem;
  margin-top: auto;
  /* Empuja hacia abajo */
}

.quantity-btn {
  background: #f0f0f0;
  border: none;
  width: 28px;
  /* Reducido para móviles */
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1rem;
  /* Reducido para móviles */
  border-radius: 4px;
  transition: background-color 0.2s ease;
}

.quantity-btn:active {
  background-color: #e0e0e0;
}

.quantity-input {
  width: 35px;
  /* Reducido para móviles */
  height: 28px;
  text-align: center;
  border: 1px solid #ddd;
  margin: 0 5px;
  border-radius: 4px;
  font-size: 0.9rem;
}

/* ===== MEDIA QUERIES PARA PRODUCTOS ===== */

/* Móviles pequeños (360px - 480px) */
@media (min-width: 360px) and (max-width: 479px) {
  .product-grid {
    grid-template-columns: 1fr;
    /* Una columna en móviles pequeños */
    gap: 1rem;
  }

  .product-card {
    max-width: 300px;
    margin: 0 auto;
  }

  .product-image-container {
    height: 160px;
  }
}

/* Tablet pequeña (600px - 767px) */
@media (min-width: 600px) and (max-width: 767px) {
  .product-section {
    margin: 2.5rem auto;
    padding: 0 1.5rem;
  }

  .section-title {
    font-size: 1.8rem;
    margin-bottom: 1.8rem;
  }

  .product-grid {
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.8rem;
  }

  .product-image-container {
    height: 190px;
  }

  .product-info {
    padding: 1.2rem;
  }

  .product-title {
    font-size: 1.15rem;
  }

  .current-price {
    font-size: 1.15rem;
  }
}

/* Tablet grande (768px - 1023px) */
@media (min-width: 768px) and (max-width: 1023px) {
  .product-section {
    margin: 3rem auto;
    padding: 0 2rem;
  }

  .section-title {
    font-size: 2rem;
    margin-bottom: 2rem;
  }

  .product-grid {
    gap: 2rem;
  }

  .product-card {
    border-radius: 9px;
  }

  .product-image-container {
    height: 200px;
  }

  .product-info {
    padding: 1.3rem;
  }

  .product-title {
    font-size: 1.18rem;
  }

  .current-price {
    font-size: 1.2rem;
  }

  .quantity-btn {
    width: 30px;
    height: 30px;
  }

  .quantity-input {
    width: 40px;
    height: 30px;
  }
}

/* Desktop (1024px en adelante) */
@media (min-width: 1024px) {
  .product-section {
    margin: 4rem auto;
    /* Margen original */
    padding: 0 2rem;
    /* Padding original */
  }

  .section-title {
    font-size: 2rem;
    /* Tamaño original */
    margin-bottom: 2rem;
  }

  .product-grid {
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    /* Grid original */
    gap: 2rem;
    /* Gap original */
  }

  .product-card {
    border-radius: 10px;
    /* Original */
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    /* Original */
  }

  .product-image-container {
    height: 200px;
    /* Original */
  }

  .product-info {
    padding: 1.5rem;
    /* Original */
  }

  .product-title {
    font-size: 1.2rem;
    /* Original */
  }

  .current-price {
    font-size: 1.3rem;
    /* Original */
  }

  .original-price {
    font-size: 1rem;
    /* Original */
  }

  .tax-info {
    font-size: 0.8rem;
    /* Original */
  }

  .quantity-btn {
    width: 30px;
    /* Original */
    height: 30px;
    /* Original */
    font-size: 1.2rem;
    /* Original */
  }

  .quantity-input {
    width: 40px;
    /* Original */
    height: 30px;
    /* Original */
  }
}

/* Pantallas grandes (≥ 1200px) */
@media (min-width: 1200px) {
  .product-grid {
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2.5rem;
  }

  .product-image-container {
    height: 220px;
  }
}

/* Pantallas muy grandes (≥ 1400px) */
@media (min-width: 1400px) {
  .product-section {
    max-width: 1400px;
  }

  .product-grid {
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  }
}

/* Orientación horizontal en móviles */
@media (max-width: 767px) and (orientation: landscape) {
  .product-grid {
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
  }

  .product-image-container {
    height: 140px;
  }

  .product-info {
    padding: 0.8rem;
  }

  .product-title {
    font-size: 1rem;
  }
}

/* Ajustes para touch devices */
@media (hover: none) and (pointer: coarse) {
  .product-card:hover {
    transform: none;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.08);
  }

  .product-card:active {
    transform: scale(0.98);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
  }

  .product-card:hover .product-image {
    transform: none;
  }

  .product-card:active .product-image {
    transform: scale(1.02);
  }

  .quantity-btn:active {
    background-color: #e0e0e0;
    transform: scale(0.95);
  }
}

/* Mejoras de accesibilidad */
@media (prefers-reduced-motion: reduce) {

  .product-card,
  .product-image,
  .quantity-btn {
    transition: none;
  }
}

/* Mejor legibilidad en pantallas pequeñas */
@media (max-width: 480px) {
  .product-title {
    font-weight: 600;
  }

  .current-price {
    font-weight: 700;
  }

  .quantity-btn {
    width: 32px;
    height: 32px;
    font-size: 1.1rem;
  }

  .quantity-input {
    width: 40px;
    height: 32px;
    font-size: 1rem;
  }
}



/* ===== GRUPO DE BOTONES RESPONSIVE ===== */
.btn-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-bottom: 1rem;
  width: 100%;
}

.btn-add-cart,
.btn-buy-now {
  padding: 0.6rem 0.75rem;
  /* Reducido para móviles */
  border: none;
  border-radius: 4px;
  /* Reducido para móviles */
  font-weight: bold;
  cursor: pointer;
  transition: all 0.3s ease;
  width: 100%;
  text-align: center;
  font-size: 0.9rem;
  /* Reducido para móviles */
  min-height: 44px;
  /* Altura mínima para touch (accesibilidad) */
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.btn-add-cart {
  background-color: #f0f0f0;
  color: #333;
  border: 1px solid #ddd;
}

.btn-add-cart:hover {
  background-color: #e0e0e0;
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.btn-buy-now {
  background-color: #1c301c;
  color: white;
}

.btn-buy-now:hover {
  background-color: #2a452a;
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

/* Iconos dentro de los botones */
.btn-add-cart i,
.btn-buy-now i {
  font-size: 1rem;
}

/* ===== MEDIA QUERIES PARA BOTONES ===== */

/* Móviles pequeños (< 360px) */
@media (max-width: 359px) {

  .btn-add-cart,
  .btn-buy-now {
    padding: 0.5rem 0.6rem;
    font-size: 0.85rem;
    min-height: 40px;
  }

  .btn-group {
    gap: 0.4rem;
  }
}

/* Móviles (360px - 479px) */
@media (min-width: 360px) and (max-width: 479px) {

  .btn-add-cart,
  .btn-buy-now {
    padding: 0.55rem 0.7rem;
    font-size: 0.88rem;
  }
}

/* Tablet pequeña (600px - 767px) */
@media (min-width: 600px) and (max-width: 767px) {

  .btn-add-cart,
  .btn-buy-now {
    padding: 0.65rem 0.8rem;
    font-size: 0.92rem;
    min-height: 46px;
  }

  .btn-group {
    gap: 0.6rem;
    margin-bottom: 1.2rem;
  }
}

/* Tablet grande (768px - 1023px) */
@media (min-width: 768px) and (max-width: 1023px) {

  .btn-add-cart,
  .btn-buy-now {
    padding: 0.7rem 0.85rem;
    font-size: 0.95rem;
    min-height: 48px;
  }

  .btn-group {
    gap: 0.7rem;
    margin-bottom: 1.3rem;
  }
}

/* Desktop (1024px en adelante) */
@media (min-width: 1024px) {

  .btn-add-cart,
  .btn-buy-now {
    padding: 0.75rem;
    /* Tamaño original */
    border-radius: 5px;
    /* Original */
    font-size: 1rem;
    /* Original */
    min-height: 50px;
  }

  .btn-group {
    gap: 0.5rem;
    /* Original */
    margin-bottom: 1rem;
    /* Original */
  }
}

/* Desktop grande (≥ 1200px) */
@media (min-width: 1200px) {

  .btn-add-cart,
  .btn-buy-now {
    padding: 0.8rem 1rem;
    font-size: 1.05rem;
    min-height: 52px;
  }
}

/* ===== ORIENTACIÓN HORIZONTAL EN MÓVILES ===== */
@media (max-width: 767px) and (orientation: landscape) {
  .btn-group {
    flex-direction: row;
    gap: 0.5rem;
  }

  .btn-add-cart,
  .btn-buy-now {
    flex: 1;
    min-height: 42px;
    font-size: 0.85rem;
    padding: 0.5rem;
  }
}

/* ===== DISPOSITIVOS TÁCTILES ===== */
@media (hover: none) and (pointer: coarse) {
  .btn-add-cart:active {
    background-color: #e0e0e0;
    transform: scale(0.98);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
  }

  .btn-buy-now:active {
    background-color: #2a452a;
    transform: scale(0.98);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
  }

  /* Desactivar transform en hover para dispositivos táctiles */
  .btn-add-cart:hover,
  .btn-buy-now:hover {
    transform: none;
    box-shadow: none;
  }
}

/* ===== ESTADO FOCUS PARA ACCESIBILIDAD ===== */
.btn-add-cart:focus,
.btn-buy-now:focus {
  outline: 2px solid #1c301c;
  outline-offset: 2px;
}

.btn-buy-now:focus {
  outline-color: #e0bd94;
}

/* ===== PREFERS-REDUCED-MOTION ===== */
@media (prefers-reduced-motion: reduce) {

  .btn-add-cart,
  .btn-buy-now {
    transition: none;
  }

  .btn-add-cart:hover,
  .btn-buy-now:hover,
  .btn-add-cart:active,
  .btn-buy-now:active {
    transform: none;
  }
}

/* ===== VARIACIÓN PARA DISPLAY MÁS GRANDE (Tablet/Desktop) ===== */
@media (min-width: 768px) {

  /* Opcional: cambiar a dirección horizontal en tablets/desktop */
  .btn-group.horizontal {
    flex-direction: row;
  }

  .btn-group.horizontal .btn-add-cart,
  .btn-group.horizontal .btn-buy-now {
    flex: 1;
  }
}

/* ===== MEJORAS PARA BOTONES DESHABILITADOS ===== */
.btn-add-cart:disabled,
.btn-buy-now:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none !important;
  box-shadow: none !important;
}

.btn-add-cart:disabled:hover,
.btn-buy-now:disabled:hover {
  background-color: inherit;
  transform: none;
  box-shadow: none;
}

/* ===== ESTILOS PARA CARGANDO/LOADING ===== */
.btn-add-cart.loading,
.btn-buy-now.loading {
  position: relative;
  color: transparent;
}

.btn-add-cart.loading::after,
.btn-buy-now.loading::after {
  content: '';
  position: absolute;
  width: 16px;
  height: 16px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: white;
  border-radius: 50%;
  animation: button-spinner 0.8s linear infinite;
}

.btn-add-cart.loading::after {
  border: 2px solid rgba(0, 0, 0, 0.3);
  border-top-color: #333;
}

@keyframes button-spinner {
  to {
    transform: rotate(360deg);
  }
}

/* Reducir animación si el usuario lo prefiere */
@media (prefers-reduced-motion: reduce) {

  .btn-add-cart.loading::after,
  .btn-buy-now.loading::after {
    animation: none;
    content: '...';
    color: inherit;
    border: none;
    width: auto;
    height: auto;
    position: static;
  }
}

/* ===== AJUSTES PARA PANTALLAS EXTRA GRANDES ===== */
@media (min-width: 1400px) {

  .btn-add-cart,
  .btn-buy-now {
    padding: 0.85rem 1.2rem;
    font-size: 1.1rem;
    min-height: 56px;
  }

  .btn-group {
    gap: 0.6rem;
  }
}



/* ===== DESCRIPCIÓN DEL PRODUCTO RESPONSIVE ===== */
.product-description {
  margin-bottom: 0.8rem;
  /* Reducido para móviles */
  font-size: 0.85rem;
  /* Reducido para móviles */
  color: #555;
  line-height: 1.5;
  padding: 0 0.25rem;
}

.product-description ul {
  padding-left: 0.8rem;
  /* Reducido para móviles */
  margin-top: 0.4rem;
  /* Reducido para móviles */
}

.product-description li {
  margin-bottom: 0.2rem;
  /* Reducido para móviles */
  line-height: 1.4;
}

.product-rating {
  display: flex;
  align-items: center;
  gap: 0.2rem;
  /* Reducido para móviles */
  flex-wrap: wrap;
  margin-bottom: 0.5rem;
}

.star {
  color: #ffc107;
  font-size: 0.9rem;
  /* Reducido para móviles */
}

.review-count {
  font-size: 0.75rem;
  /* Reducido para móviles */
  color: #666;
  margin-left: 0.4rem;
  /* Reducido para móviles */
  line-height: 1.3;
}

/* ===== MEDIA QUERIES PARA DESCRIPCIÓN ===== */

/* Móviles pequeños (< 360px) */
@media (max-width: 359px) {
  .product-description {
    font-size: 0.8rem;
    margin-bottom: 0.7rem;
  }

  .product-description ul {
    padding-left: 0.7rem;
  }

  .star {
    font-size: 0.85rem;
  }

  .review-count {
    font-size: 0.7rem;
  }
}

/* Tablet (600px - 767px) */
@media (min-width: 600px) and (max-width: 767px) {
  .product-description {
    font-size: 0.88rem;
    margin-bottom: 0.9rem;
  }

  .star {
    font-size: 0.95rem;
  }

  .review-count {
    font-size: 0.78rem;
  }
}

/* Tablet grande (768px - 1023px) */
@media (min-width: 768px) and (max-width: 1023px) {
  .product-description {
    font-size: 0.9rem;
    margin-bottom: 1rem;
  }

  .star {
    font-size: 1rem;
  }

  .review-count {
    font-size: 0.8rem;
  }
}

/* Desktop (1024px en adelante) */
@media (min-width: 1024px) {
  .product-description {
    font-size: 0.9rem;
    /* Tamaño original */
    margin-bottom: 1rem;
    /* Original */
  }

  .product-description ul {
    padding-left: 1rem;
    /* Original */
    margin-top: 0.5rem;
    /* Original */
  }

  .product-description li {
    margin-bottom: 0.25rem;
    /* Original */
  }

  .star {
    font-size: 1rem;
  }

  .review-count {
    font-size: 0.8rem;
    /* Original */
    margin-left: 0.5rem;
    /* Original */
  }

  .product-rating {
    gap: 0.25rem;
    /* Original */
  }
}

/* ===== CARRUSEL RESPONSIVE ===== */
.carousel-section {
  max-width: 900px;
  margin: 3rem auto 2rem;
  /* Reducido para móviles */
  text-align: center;
  padding: 0 1rem;
  /* Agregado para móviles */
  width: 100%;
}

.carousel-title {
  font-size: 1.5rem;
  /* Reducido para móviles */
  margin-bottom: 0.8rem;
  /* Reducido para móviles */
  font-weight: bold;
  font-family: var(--font-heading);
  color: #333;
  line-height: 1.3;
  padding: 0 0.5rem;
}

.carousel-container {
  position: relative;
  width: 100%;
  overflow: hidden;
  border-radius: 10px;
  /* Reducido para móviles */
}

.carousel-slide {
  width: 100%;
  height: 300px;
  /* Reducido para móviles */
  overflow: hidden;
  border-radius: 10px;
  /* Reducido para móviles */
  margin-bottom: 0.8rem;
  /* Reducido para móviles */
}

.carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: none;
  transition: transform 0.4s ease;
}

.carousel-slide img.active {
  display: block;
}

.carousel-slide img:hover {
  transform: scale(1.05);
}

/* Controles del carrusel */
.carousel-controls {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1rem;
  margin-top: 1rem;
}

.carousel-btn {
  background-color: #1c301c;
  color: white;
  border: none;
  width: 40px;
  /* Reducido para móviles */
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1.2rem;
  transition: all 0.3s ease;
}

.carousel-btn:hover {
  background-color: #2a452a;
  transform: scale(1.1);
}

.carousel-indicators {
  display: flex;
  gap: 0.5rem;
}

.carousel-indicator {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background-color: #ddd;
  cursor: pointer;
  transition: all 0.3s ease;
}

.carousel-indicator.active {
  background-color: #1c301c;
  transform: scale(1.2);
}

/* ===== MEDIA QUERIES PARA CARRUSEL ===== */

/* Móviles pequeños (< 480px) */
@media (max-width: 479px) {
  .carousel-slide {
    height: 250px;
  }

  .carousel-btn {
    width: 36px;
    height: 36px;
    font-size: 1rem;
  }

  .carousel-indicator {
    width: 8px;
    height: 8px;
  }
}

/* Móviles en orientación horizontal */
@media (max-width: 767px) and (orientation: landscape) {
  .carousel-slide {
    height: 220px;
  }

  .carousel-section {
    margin: 2rem auto 1.5rem;
  }
}

/* Tablet (600px - 767px) */
@media (min-width: 600px) and (max-width: 767px) {
  .carousel-section {
    margin: 4rem auto 2.5rem;
    padding: 0 1.5rem;
  }

  .carousel-title {
    font-size: 1.8rem;
    margin-bottom: 1rem;
  }

  .carousel-slide {
    height: 350px;
    border-radius: 12px;
  }

  .carousel-container {
    border-radius: 12px;
  }
}

/* Tablet grande (768px - 1023px) */
@media (min-width: 768px) and (max-width: 1023px) {
  .carousel-section {
    margin: 5rem auto 3rem;
    padding: 0 2rem;
  }

  .carousel-title {
    font-size: 2rem;
    margin-bottom: 1.2rem;
  }

  .carousel-slide {
    height: 400px;
    border-radius: 13px;
  }

  .carousel-container {
    border-radius: 13px;
  }
}

/* Desktop (1024px en adelante) */
@media (min-width: 1024px) {
  .carousel-section {
    margin: 8rem auto 3rem;
    /* Margen original */
    padding: 0;
  }

  .carousel-title {
    font-size: 2rem;
    /* Original */
    margin-bottom: 1rem;
    /* Original */
  }

  .carousel-slide {
    height: 500px;
    /* Altura original */
    border-radius: 15px;
    /* Original */
    margin-bottom: 1rem;
    /* Original */
  }

  .carousel-container {
    border-radius: 15px;
  }
}

/* Pantallas grandes (≥ 1200px) */
@media (min-width: 1200px) {
  .carousel-section {
    max-width: 1000px;
  }

  .carousel-slide {
    height: 550px;
  }
}

/* Pantallas muy grandes (≥ 1400px) */
@media (min-width: 1400px) {
  .carousel-section {
    max-width: 1100px;
  }

  .carousel-slide {
    height: 600px;
  }
}

/* ===== AJUSTES PARA DISPOSITIVOS TÁCTILES ===== */
@media (hover: none) and (pointer: coarse) {
  .carousel-slide img:hover {
    transform: none;
  }

  .carousel-btn:hover {
    transform: none;
    background-color: #1c301c;
  }

  .carousel-btn:active {
    transform: scale(0.95);
    background-color: #2a452a;
  }

  .carousel-indicator:active {
    transform: scale(1.2);
  }
}

/* ===== MEJORAS DE ACCESIBILIDAD ===== */
.carousel-btn:focus,
.carousel-indicator:focus {
  outline: 2px solid #e0bd94;
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {

  .carousel-slide img,
  .carousel-btn,
  .carousel-indicator {
    transition: none;
  }

  .carousel-slide img:hover,
  .carousel-btn:hover,
  .carousel-indicator:hover {
    transform: none;
  }
}

/* ===== INDICADORES RESPONSIVE ===== */
@media (max-width: 480px) {
  .carousel-indicators {
    gap: 0.4rem;
  }

  .carousel-indicator {
    width: 8px;
    height: 8px;
  }
}

/* ===== SOPORTE PARA TEXTO LARGO EN DESCRIPCIÓN ===== */
.product-description {
  word-wrap: break-word;
  overflow-wrap: break-word;
  hyphens: auto;
}

/* ===== MEJOR VISIBILIDAD DE ESTRELLAS EN MÓVILES ===== */
@media (max-width: 480px) {
  .product-rating {
    gap: 0.15rem;
  }

  .star {
    font-size: 0.85rem;
  }

  .review-count {
    font-size: 0.7rem;
    margin-left: 0.3rem;
  }
}

/* ===== EVITAR DESBORDAMIENTO EN IMÁGENES DEL CARRUSEL ===== */
.carousel-slide {
  position: relative;
}

.carousel-slide img {
  max-width: 100%;
  max-height: 100%;
}

/* ===== BOTONES DE NAVEGACIÓN MÁS GRANDES PARA TOUCH ===== */
@media (max-width: 767px) {
  .carousel-btn {
    min-width: 44px;
    min-height: 44px;
  }

  .carousel-indicator {
    min-width: 12px;
    min-height: 12px;
  }
}



/* ===== CONTROLES DEL CARRUSEL RESPONSIVE ===== */
.prev,
.next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background-color: rgba(0, 0, 0, 0.5);
  color: white;
  border: none;
  cursor: pointer;
  border-radius: 5px;
  z-index: 10;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;

  /* Tamaños base para móviles */
  font-size: 1.5rem;
  padding: 0.4rem 0.8rem;
  min-width: 44px;
  /* Accesibilidad touch */
  min-height: 44px;
}

.prev {
  left: 5px;
  /* Reducido para móviles */
}

.next {
  right: 5px;
  /* Reducido para móviles */
}

.prev:hover,
.next:hover {
  background-color: rgba(0, 0, 0, 0.8);
  transform: translateY(-50%) scale(1.1);
}

/* Flechas Unicode si no hay iconos */
.prev::before {
  content: '‹';
}

.next::before {
  content: '›';
}

/* ===== DESCRIPCIÓN DEL CARRUSEL RESPONSIVE ===== */
.carousel-description {
  font-size: 0.9rem;
  /* Reducido para móviles */
  color: #555;
  margin-bottom: 0.8rem;
  /* Reducido para móviles */
  font-family: var(--font-body);
  line-height: 1.5;
  padding: 0 0.5rem;
  text-align: center;
  max-width: 100%;
  overflow-wrap: break-word;
}

/* ===== MINIATURAS DEL CARRUSEL RESPONSIVE ===== */
.carousel-thumbnails {
  display: flex;
  justify-content: center;
  gap: 8px;
  /* Reducido para móviles */
  flex-wrap: wrap;
  padding: 0.5rem;
  margin-top: 0.5rem;
  overflow-x: auto;
  /* Scroll horizontal en móviles */
  scrollbar-width: thin;
  scrollbar-color: #ddd transparent;
}

/* Estilo scrollbar para navegadores webkit */
.carousel-thumbnails::-webkit-scrollbar {
  height: 4px;
}

.carousel-thumbnails::-webkit-scrollbar-track {
  background: transparent;
}

.carousel-thumbnails::-webkit-scrollbar-thumb {
  background: #ddd;
  border-radius: 2px;
}

.carousel-thumbnails img {
  object-fit: cover;
  border-radius: 4px;
  /* Reducido para móviles */
  cursor: pointer;
  opacity: 0.6;
  transition: opacity 0.3s, transform 0.3s;
  flex-shrink: 0;
  /* Evita que se encojan */

  /* Tamaños base para móviles */
  width: 80px;
  height: 60px;
}

.carousel-thumbnails img.active,
.carousel-thumbnails img:hover {
  opacity: 1;
  transform: scale(1.05);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

/* Borde para imagen activa */
.carousel-thumbnails img.active {
  border: 2px solid #1c301c;
}

/* ===== MEDIA QUERIES PARA CARRUSEL ===== */

/* Móviles pequeños (< 360px) */
@media (max-width: 359px) {

  .prev,
  .next {
    font-size: 1.3rem;
    padding: 0.3rem 0.6rem;
    min-width: 40px;
    min-height: 40px;
  }

  .prev {
    left: 3px;
  }

  .next {
    right: 3px;
  }

  .carousel-description {
    font-size: 0.85rem;
    margin-bottom: 0.7rem;
  }

  .carousel-thumbnails img {
    width: 70px;
    height: 50px;
  }
}

/* Móviles (360px - 479px) */
@media (min-width: 360px) and (max-width: 479px) {

  .prev,
  .next {
    font-size: 1.4rem;
  }

  .carousel-thumbnails img {
    width: 75px;
    height: 55px;
  }
}

/* Tablet pequeña (600px - 767px) */
@media (min-width: 600px) and (max-width: 767px) {

  .prev,
  .next {
    font-size: 1.8rem;
    padding: 0.5rem 1rem;
  }

  .prev {
    left: 10px;
  }

  .next {
    right: 10px;
  }

  .carousel-description {
    font-size: 0.95rem;
    margin-bottom: 0.9rem;
  }

  .carousel-thumbnails {
    gap: 10px;
  }

  .carousel-thumbnails img {
    width: 100px;
    height: 70px;
  }
}

/* Tablet grande (768px - 1023px) */
@media (min-width: 768px) and (max-width: 1023px) {

  .prev,
  .next {
    font-size: 2rem;
    padding: 0.5rem 1rem;
  }

  .prev {
    left: 15px;
  }

  .next {
    right: 15px;
  }

  .carousel-description {
    font-size: 1rem;
    margin-bottom: 1rem;
  }

  .carousel-thumbnails {
    gap: 12px;
  }

  .carousel-thumbnails img {
    width: 110px;
    height: 75px;
  }
}

/* Desktop (1024px en adelante) */
@media (min-width: 1024px) {

  .prev,
  .next {
    font-size: 2rem;
    /* Tamaño original */
    padding: 0.5rem 1rem;
    /* Original */
  }

  .prev {
    left: 10px;
    /* Original */
  }

  .next {
    right: 10px;
    /* Original */
  }

  .carousel-description {
    font-size: 1rem;
    /* Original */
    margin-bottom: 1rem;
    /* Original */
  }

  .carousel-thumbnails {
    gap: 10px;
    /* Original */
  }

  .carousel-thumbnails img {
    width: 120px;
    /* Original */
    height: 80px;
    /* Original */
    border-radius: 5px;
    /* Original */
  }
}

/* Desktop grande (≥ 1200px) */
@media (min-width: 1200px) {
  .prev {
    left: 20px;
  }

  .next {
    right: 20px;
  }

  .prev,
  .next {
    font-size: 2.2rem;
    padding: 0.6rem 1.2rem;
  }

  .carousel-thumbnails img {
    width: 130px;
    height: 85px;
  }
}

/* Pantallas muy grandes (≥ 1400px) */
@media (min-width: 1400px) {
  .prev {
    left: 25px;
  }

  .next {
    right: 25px;
  }

  .prev,
  .next {
    font-size: 2.5rem;
    padding: 0.7rem 1.4rem;
  }

  .carousel-thumbnails img {
    width: 140px;
    height: 90px;
  }
}

/* ===== ORIENTACIÓN HORIZONTAL EN MÓVILES ===== */
@media (max-width: 767px) and (orientation: landscape) {

  .prev,
  .next {
    font-size: 1.5rem;
    padding: 0.3rem 0.7rem;
  }

  .carousel-description {
    font-size: 0.85rem;
  }

  .carousel-thumbnails {
    gap: 6px;
  }

  .carousel-thumbnails img {
    width: 70px;
    height: 50px;
  }
}

/* ===== DISPOSITIVOS TÁCTILES ===== */
@media (hover: none) and (pointer: coarse) {

  .prev:hover,
  .next:hover {
    transform: translateY(-50%) scale(1);
    background-color: rgba(0, 0, 0, 0.5);
  }

  .prev:active,
  .next:active {
    background-color: rgba(0, 0, 0, 0.8);
    transform: translateY(-50%) scale(0.95);
  }

  .carousel-thumbnails img:hover {
    opacity: 0.6;
    transform: scale(1);
  }

  .carousel-thumbnails img:active {
    opacity: 1;
    transform: scale(1.05);
  }
}

/* ===== ACCESIBILIDAD ===== */
.prev:focus,
.next:focus,
.carousel-thumbnails img:focus {
  outline: 2px solid #e0bd94;
  outline-offset: 2px;
}

/* Mejor contraste para botones */
@media (prefers-contrast: high) {

  .prev,
  .next {
    background-color: rgba(0, 0, 0, 0.8);
    border: 2px solid white;
  }

  .carousel-thumbnails img.active {
    border: 3px solid #1c301c;
  }
}

/* Reducir movimiento */
@media (prefers-reduced-motion: reduce) {

  .prev,
  .next,
  .carousel-thumbnails img {
    transition: none;
  }

  .prev:hover,
  .next:hover,
  .carousel-thumbnails img:hover {
    transform: none;
  }
}

/* ===== MEJORAS PARA THUMBNAILS EN DISPOSITIVOS PEQUEÑOS ===== */
@media (max-width: 480px) {
  .carousel-thumbnails {
    justify-content: flex-start;
    /* Scroll horizontal */
    padding-bottom: 0.8rem;
    /* Espacio para scrollbar */
  }

  /* Ocultar scrollbar en algunos casos */
  .carousel-thumbnails.hide-scrollbar {
    scrollbar-width: none;
  }

  .carousel-thumbnails.hide-scrollbar::-webkit-scrollbar {
    display: none;
  }
}

/* ===== VISIBILIDAD MEJORADA EN FONDOS CLAROS ===== */
/* Si la imagen del carrusel es clara, los botones necesitan sombra */
.carousel-slide:has(img[data-bright="light"])~.prev,
.carousel-slide:has(img[data-bright="light"])~.next {
  background-color: rgba(255, 255, 255, 0.7);
  color: #333;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.carousel-slide:has(img[data-bright="light"])~.prev:hover,
.carousel-slide:has(img[data-bright="light"])~.next:hover {
  background-color: rgba(255, 255, 255, 0.9);
}

/* ===== BOTONES INVISIBLES EN DISPOSITIVOS MUY PEQUEÑOS (opcional) ===== */
@media (max-width: 320px) {

  .prev,
  .next {
    opacity: 0.9;
  }

  /* Mostrar solo al tocar/hover */
  .carousel-container:not(:hover) .prev,
  .carousel-container:not(:hover) .next {
    opacity: 0.5;
  }
}

/* ===== INDICADOR DE SCROLL PARA THUMBNAILS ===== */
.carousel-thumbnails::after {
  content: '';
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: 20px;
  background: linear-gradient(to right, transparent, rgba(255, 255, 255, 0.9));
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.3s;
}

.carousel-thumbnails.scrollable::after {
  opacity: 1;
}

/* ===== FIX LÍNEA BLANCA HEADER / HERO ===== */
html,
body {
  margin: 0;
  padding: 0;
}

header,
.header {
  margin-bottom: 0 !important;
  padding-bottom: 0 !important;
  border-bottom: none !important;
}

.hero {
  margin-top: 0 !important;
  padding-top: 0 !important;
  line-height: 0;
  /* elimina espacios fantasmas */
}

