/* =========================================
   VARIABLES
========================================= */
:root{
  --primary:#D9A01B;
  --gold:#B68212;
  --dark:#494136;
  --light:#E3E3E3;
  --white:#ffffff;
}

/* =========================================
   RESET
========================================= */
*{
  margin:0;
  padding:0;
  box-sizing:border-box;
}

body{
  font-family:'Oswald', sans-serif;
  background:var(--white);
  color:var(--dark);
}

/* =========================================
   NAVBAR
========================================= */

.navbar{
  position:fixed;
  top:0;
  left:0;
  width:100%;
  height:80px;
  background:rgba(255,255,255,0.85);
  backdrop-filter:blur(12px);
  box-shadow:0 6px 24px rgba(0,0,0,0.06);
  z-index:1000;
}

.nav-inner{
  max-width:1200px;
  margin:auto;
  height:100%;
  display:flex;
  align-items:center;
  justify-content:flex-start;
  padding:0 20px;
}

/* LOGO */
.logo{
  flex-shrink:0;
}

.logo img{
  height:46px;
  display:block;
  transition:0.25s ease;
}

.logo img:hover{
  transform:scale(1.03);
}

/* =========================================
   LINKS DESKTOP
========================================= */

.nav-links{
  margin-left:auto;
  display:flex;
  gap:26px;
  align-items:center;
}

.nav-links a{
  text-decoration:none;
  color:var(--dark);
  font-weight:500;
  letter-spacing:0.3px;
  position:relative;
}

.nav-links a::after{
  content:"";
  position:absolute;
  left:0;
  bottom:-7px;
  width:0%;
  height:2px;
  background:var(--primary);
  transition:0.25s ease;
}

.nav-links a:hover::after{
  width:100%;
}

/* =========================================
   NAV ACTIONS (CARRITO + HAMBURGER)
========================================= */

.nav-actions{
  display:flex;
  align-items:center;
  gap:18px;
  margin-left:18px;
}

/* =========================================
   CARRITO (DESKTOP)
========================================= */

.cart-icon{
  position:relative;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  font-size:20px;
  color:var(--dark);
  text-decoration:none;
}

.cart-icon:hover{
  color:var(--primary);
}

.cart-count{
  position:absolute;
  top:-6px;
  right:-10px;
  background:var(--primary);
  color:#fff;
  font-size:11px;
  font-weight:600;
  padding:3px 6px;
  border-radius:999px;
  min-width:18px;
  line-height:1;
  text-align:center;
  pointer-events:none;
}

/* =========================================
   HAMBURGER
========================================= */

.hamburger{
  display:none;
  background:none;
  border:none;
  cursor:pointer;
  width:32px;
  height:22px;
  position:relative;
}

.hamburger span{
  position:absolute;
  left:0;
  width:100%;
  height:2px;
  background:var(--dark);
  border-radius:2px;
  transition:0.3s ease;
}

.hamburger span:nth-child(1){ top:0; }
.hamburger span:nth-child(2){ top:9px; }
.hamburger span:nth-child(3){ bottom:0; }

.hamburger.active span:nth-child(1){
  transform:rotate(45deg);
  top:9px;
}
.hamburger.active span:nth-child(2){
  opacity:0;
}
.hamburger.active span:nth-child(3){
  transform:rotate(-45deg);
  bottom:11px;
}

/* =========================================
   MOBILE
========================================= */

@media (max-width:768px){

  /* Header layout sigue intacto */
  .nav-inner{
    justify-content:space-between;
  }

  /* Mostrar hamburguesa */
  .hamburger{
    display:block;
  }

  /* Ocultar carrito SOLO en navbar móvil */
  .nav-actions .cart-icon{
    display:none;
  }

  /* Menú móvil overlay */
  .nav-links{
    position:fixed;
    top:80px;
    right:-320px;
    width:280px;
    height:calc(100vh - 80px);
    background:rgba(255,255,255,0.98);
    backdrop-filter:blur(14px);
    flex-direction:column;
    align-items:flex-start;
    gap:22px;
    padding:30px 24px;
    box-shadow:-10px 0 30px rgba(0,0,0,0.08);
    transition:0.3s ease;
    margin-left:0; /* 🔑 MUY IMPORTANTE */
  }

  .nav-links.active{
    right:0;
  }

  .nav-links a{
    width:100%;
    font-size:18px;
    padding:10px;
    border-radius:12px;
  }

  .nav-links a::after{
    display:none;
  }
}

/* =========================================
   VISIBILIDAD DE CARRITO
========================================= */

/* Por defecto: el carrito del menú NO se ve */
.mobile-cart{
  display:none;
}

/* Desktop: mostrar icono flotante */
.nav-actions .cart-icon{
  display:inline-flex;
}

/* Mobile */
@media (max-width:768px){

  /* Ocultar carrito flotante */
  .nav-actions .cart-icon{
    display:none;
  }

  /* Mostrar carrito dentro del menú */
  .mobile-cart{
    display:flex;
    align-items:center;
    gap:10px;
  }

}


/* =========================================
   PRODUCT TEXT
========================================= */

.name{
  font-weight:500;
  font-size:15px;
}

.price{
  font-weight:600;
  font-size:16px;
  color:var(--primary);
}

.stock{
  font-weight:300;
  font-size:13px;
}
