/* =========================
   APPLE STYLE HEADER
========================= */

.apple-header {
    position: sticky;
    top: 0;
    z-index: 2000;
    background: #0b0b0b;
     
    border-bottom: 1px solid rgba(255,255,255,0.08);
}

.apple-nav {
    height: 84px;
    max-width: 1200px;
    margin: auto;
    padding: 0 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* ================= LOGO ================= */

.apple-logo img {
    height: 60px;
    width: auto;
    display: block;
    filter: drop-shadow(0 0 6px rgba(97,255,0,0.35));
}

/* ================= BOTONES ================= */

.apple-actions {
    display: flex;
    gap: 10px;
}

.nav-btn {
    background: none;
    border: none;
    color: #fff;
    cursor: pointer;
    padding: 6px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.25s ease, color 0.25s ease;
}

.nav-btn:hover {
    background: rgba(255,255,255,0.08);
    color: #61FF00;
}

.nav-btn .material-symbols-outlined {
    font-size: 22px;
}

/* ================= HAMBURGUESA ================= */

.burger {
    width: 42px;
    height: 42px;
    position: relative;
}

.burger span {
    position: absolute;
    left: 10px;
    width: 22px;
    height: 2px;
    background: #fff;
    border-radius: 2px;
    transition: 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.burger span:nth-child(1) { top: 16px; }
.burger span:nth-child(2) { top: 24px; }
.burger span:nth-child(3) { top: 32px; }

.burger.active span:nth-child(1) {
    transform: rotate(45deg);
    top: 24px;
}

.burger.active span:nth-child(2) {
    opacity: 0;
    transform: scale(0.5);
}

.burger.active span:nth-child(3) {
    transform: rotate(-45deg);
    top: 24px;
}

/* ================= PANEL DESPLEGABLE ================= */

.apple-panel {
    position: absolute;
    top: 84px;
    left: 0;
    width: 100%;
    background: #0b0b0b;

    display: flex;
    flex-direction: column;
    align-items: center;

    overflow: hidden;
    max-height: 0;

    transition: max-height 0.4s ease;
}

.apple-panel.active {
    max-height: 100vh;
    overflow-y: auto;
}

/* ================= LINKS PANEL ================= */

.apple-panel a {
    color: #0b0b0b;
    text-decoration: none;
    font-size: 1.15rem;
    padding: 16px 0;
    opacity: 0;
    transform: translateY(-20px);
    transition: opacity 0.35s ease, transform 0.35s ease;
}

.apple-panel.active a {
    opacity: 1;
    transform: translateY(0);
}

/* ================= SUBMENÚS ================= */

.menu-item {
    width: 100%;
    text-align: center;
}

.menu-title {
    display: block;
    padding: 14px 0;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    color: #fff;
}

.submenu {
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-height 0.3s ease, opacity 0.25s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.menu-item.open .submenu {
    max-height: 500px;
    opacity: 1;
}

.submenu a {
    padding: 10px 0;
    font-size: 0.95rem;
    color: #cfcfcf;
}

.submenu a:hover,
.menu-title:hover {
    color: #61FF00;
}

/* ================= BUSCADOR ================= */

.header-search {
    position: absolute;
    top: 64px;
    left: 0;
    width: 100%;
    background: #000;
    padding: 1rem;
    display: none;
    z-index: 999;
}

.header-search.active {
    display: block;
}

.header-search input {
    width: 100%;
    padding: 0.8rem 1rem;
    border-radius: 12px;
    border: none;
    outline: none;
    font-size: 1rem;
}

/* ================= CARRITO ================= */

.cart-btn {
    position: relative;
}

#cart-count {
    position: absolute;
    top: -4px;
    right: -6px;
    min-width: 18px;
    height: 18px;
    background: #61FF00;
    color: #000;
    font-size: 11px;
    font-weight: 800;
    border-radius: 999px;
    display: none;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

/* ================= RESPONSIVE ================= */

@media (min-width: 1024px) {

    .apple-panel {
        display: none; /* puedes luego hacer menú desktop horizontal */
    }

}

.cart-btn {
  position: relative;
}

.cart-count {
  position: absolute;
  top: -4px;
  right: -6px;
  background: #3cff00;
  color: #000;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 999px;
  min-width: 18px;
  text-align: center;
  display: none;
}
/* ===== Alinear logo + íconos (fix) ===== */

.apple-nav{
  height: 78px;               /* el alto que quieres */
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Logo centrado verticalmente */
.apple-logo{
  display: flex;
  align-items: center;
}
.apple-logo .logo-img{
  height: 56px;
  width: auto;
  display: block;
}

/* Acciones (search + carrito) alineadas */
.apple-actions{
  display: flex;
  align-items: center;
  gap: 10px;
}

/* Botones con tamaño fijo (clave) */
.nav-btn{
  width: 42px;
  height: 42px;
  padding: 0;                /* evita que se “muevan” */
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Tamaño del ícono */
.nav-btn .material-symbols-outlined{
  font-size: 24px;
  line-height: 1;
}
.top-bar{
  background: #61FF00;
  color: #000;
  text-align: center;
  font-size: 0.85rem;
  font-weight: 700;
  padding: 7px 10px;
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid rgba(0,0,0,0.08);
}
.top-bar{
  background:#61FF00;
  color:#000;
  font-size:.85rem;
  font-weight:700;
  padding:7px 10px;
  overflow:hidden;
  position:relative;
  white-space:nowrap;
}

.top-bar-text{
  display:inline-block;
  will-change: transform, opacity;
}

/* sale a la izquierda */
.top-bar-text.out{
  animation: topOut .35s ease forwards;
}

/* entra desde la derecha */
.top-bar-text.in{
  animation: topIn .45s ease forwards;
}

@keyframes topOut{
  from{ transform: translateX(0); opacity: 1; }
  to{ transform: translateX(-120%); opacity: 0; }
}

@keyframes topIn{
  from{ transform: translateX(120%); opacity: 0; }
  to{ transform: translateX(0); opacity: 1; }
}
