/* =========================================================
   IMPORTS
========================================================= */
@import url("font.css");
@import url("fontawesome/all.css");
@import url("colors.css");

/* =========================================================
   VARIABLES Y BASE
========================================================= */
:root {
  --brand-yellow: #ffd200;
  --brand-black: #000;
  --brand-gray: #151515;
  --muted: #9ca3af;
}

body {
  background: var(--brand-black);
  color: #fff;
}

/* =========================================================
   NAVBAR PRINCIPAL
========================================================= */
.navbar-nav .nav-link {
  transition: color 0.2s, transform 0.2s, text-shadow 0.2s;
}

.navbar-nav .nav-link:hover {
  color: #ffc107 !important;
  transform: scale(1.1);
  text-shadow: 0 0 1px #ffc107, 0 0 1px #ffc107, 0 0 1px #ffc107;
  font-weight: 700;
}

/* Dropdown principal */
.dropdown-menu .dropdown-item:hover {
  background-color: #ffc107;
  color: #111 !important;
}

/* =========================================================
   NAVBAR SECUNDARIO (CATEGORÍAS)
========================================================= */
.category-navbar {
  background-color: #000;
  border-top: 1px solid #222;
  border-bottom: 1px solid #222;
}

/* Barra de categorías */
.category-bar {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 2rem;
  padding: 0.5rem 0;
  margin: 0;
  list-style: none;
}

.category-bar .nav-item {
  position: relative;
}

.category-bar .nav-link {
  transition: color 0.2s, transform 0.2s, text-shadow 0.2s;
  color: #fff;
}

.category-bar .nav-link:hover {
  color: #ffc107 !important;
  transform: scale(1.1);
  text-shadow: 0 0 1px #ffc107, 0 0 1px #ffc107, 0 0 1px #ffc107;
  font-weight: 700;
}

.category-bar .dropdown-menu {
  min-width: auto;
  border-radius: 12px;
  overflow: hidden;
}

/* =========================================================
   HERO PRINCIPAL
========================================================= */
.hero {
  background: radial-gradient(1200px 600px at 70% 50%, rgba(255,210,0,.12), transparent 60%),
              linear-gradient(180deg, #050505, #0b0b0b);
  min-height: 64vh;
  display: grid;
  place-items: center;
  padding: 48px 0;
}

.hero .tag {
  color: #111;
  background: var(--brand-yellow);
  font-weight: 800;
  border-radius: 999px;
  padding: 6px 12px;
  display: inline-flex;
  gap: 8px;
  align-items: center;
}

.hero h1 {
  font-weight: 800;
  letter-spacing: 0.3px;
}

.hero p.lead {
  color: #d1d5db;
  max-width: 56ch;
}

/* =================================== */
/* BOTÓN CTA - Inspirado en Logo Hermes */
/* =================================== */
.btn-cta {
  position: relative;
  overflow: hidden;
  background: var(--brand-yellow);
  color: #111; /* texto negro */
  border: none;
  font-weight: 800;
  border-radius: 50px;
  letter-spacing: 0.5px;
  transition: color 0.3s ease;
}

/* Barrido CMY (Cian 40%, Amarillo 20%, Magenta 40%) */
.btn-cta::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    #00ffff 0%,       /* Cian */
    #00ffff 40%,       /* 40% */
    #ffff00 50%,       /* Amarillo delgado (20% zona central) */
    #ff00ff 60%,       /* Magenta */
    #ff00ff 100%       /* 40% final */
  );
  transition: all 0.6s ease;
  z-index: 0;
}

/* Texto inicial */
.btn-cta span {
  position: relative;
  z-index: 1;
  display: inline-block;
  transition: transform 0.4s ease, opacity 0.4s ease;
}

/* Texto alternativo */
.btn-cta::after {
  content: "Comprar";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) translateY(100%);
  color: #111; /* también negro para mantener identidad */
  font-weight: 800;
  opacity: 0;
  transition: transform 0.4s ease, opacity 0.4s ease;
  z-index: 1;
}

/* Si existe data-text, lo usa */
.btn-cta[data-text]::after {
  content: attr(data-text);
}

/* Hover: activa barrido */
.btn-cta:hover::before {
  left: 0;
}

/* Hover: cambia texto */
.btn-cta:hover span {
  transform: translateY(-100%);
  opacity: 0;
}

.btn-cta:hover::after {
  transform: translate(-50%, -50%) translateY(0);
  opacity: 1;
}



.btn-outline-light {
  border-width: 2px;
}

.carousel-item img {
  filter: brightness(0.9);
  border-radius: 1rem;
  transition: transform 0.6s ease;
}
.carousel-item img:hover {
  transform: scale(1.02);
}
.carousel-control-prev-icon,
.carousel-control-next-icon {
  filter: invert(1) drop-shadow(0 0 3px rgba(0,0,0,.7));
}

/* =========================================================
   CATEGORÍAS DESTACADAS (GRID)
========================================================= */
.cat-card {
  position: relative;
  border: 0;
  overflow: hidden;
  border-radius: 18px;
  background: #0e0e0e;
}

.cat-card img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  transition: transform 0.4s ease;
  filter: contrast(1.05) saturate(1.05);
}

.cat-card:hover img {
  transform: scale(1.04);
}

.cat-card .overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent, rgba(0,0,0,.72) 68%);
  display: flex;
  align-items: end;
  padding: 14px;
}

.cat-chip {
  background: rgba(255,210,0,0.95);
  color: #111;
  font-weight: 800;
  display: inline-block;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.9rem;
}

/* =========================================================
   PRODUCTOS DESTACADOS
========================================================= */
.product-card {
  background: #0e0e0e;
  border: 1px solid #1a1a1a;
  border-radius: 18px;
  overflow: hidden;
}

.product-card img {
  height: 210px;
  width: 100%;
  object-fit: cover;
}

.price {
  color: var(--brand-yellow);
  font-weight: 900;
  font-size: 1.05rem;
}

.btn-cart {
  background: #111;
  border: 1px solid #2a2a2a;
  color: #fff;
}

.btn-cart:hover {
  border-color: var(--brand-yellow);
  color: var(--brand-yellow);
}

/* =========================================================
   MARCAS / PROVEEDORES
========================================================= */
.brand-strip img {
  height: 40px;
  opacity: 0.7;
  filter: grayscale(1);
  transition: opacity 0.2s ease, filter 0.2s ease;
}

.brand-strip img:hover {
  opacity: 1;
  filter: none;
}

/* =========================================================
   FOOTER
========================================================= */
footer {
  background: #080808;
  border-top: 1px solid #141414;
}

footer a {
  color: #d1d5db;
  text-decoration: none;
}

footer a:hover {
  color: var(--brand-yellow);
}

/* =========================================================
   MENÚ LATERAL (CATEGORÍAS DE PRODUCTOS)
   ========================================================= */
#listaCategorias .list-group-item {
  transition: color 0.2s, transform 0.2s, text-shadow 0.2s;
  cursor: pointer;
}

#listaCategorias .list-group-item:hover {
  color: #ffc107 !important;
  transform: scale(1.1);
  text-shadow: 0 0 1px #ffc107, 0 0 1px #ffc107, 0 0 1px #ffc107;
  font-weight: 700;
}

/* =========================================================
   PRODUCTOS - IMÁGENES CUADRADAS (1:1)
========================================================= */
.product-card img,
#carouselProducto img {
  width: 100%;
  aspect-ratio: 1 / 1; /* Fuerza proporción cuadrada */
  object-fit: cover;   /* Corta o amplía sin deformar */
  border-radius: 12px;
  background-color: #0e0e0e; /* Fallback si la imagen carga lento */
}
