/* ==== SIDEBAR ==== */
.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  width: 240px;
  height: 100vh;
  background: linear-gradient(180deg, #ff7aa2, #ffb6c1);
  color: white;
  box-shadow: 3px 0 15px rgba(0,0,0,0.15);
  transition: transform 0.4s ease;
  z-index: 1200;
  display: flex;
  flex-direction: column;
}

.sidebar-header {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 12px;
  padding: 18px 12px;
  border-bottom: 2px solid rgba(255,255,255,0.2);
}

.logo-small {
  width: 58px;
  height: 58px;
  border-radius: 50%;
  box-shadow: 0 0 10px rgba(255,255,255,0.5);
  flex-shrink: 0;
}

.sidebar-header h2 {
  font-family: 'Poppins', sans-serif;
  font-size: 1.15rem;
  font-weight: 700;
  color: #fff;
  margin: 0;
}

.sidebar-menu {
  list-style: none;
  padding: 0;
  margin: 18px 0;
  flex-grow: 1;
}

.sidebar-menu li a {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 16px;
  color: #fff;
  font-weight: 600;
  font-size: 1.15rem;
  text-decoration: none;
  transition: all 0.18s ease;
  border-left: 4px solid transparent;
  border-radius: 8px;
}

.sidebar-menu li a:hover {
  background: rgba(255,255,255,0.15);
  border-left: 4px solid white;
  transform: translateX(4px);
}
/* ===== MODAL LOGIN / REGISTRO ===== */

.auth-modal {
  position: fixed;
  right: 24px;
  bottom: 24px;
  width: 340px;
  max-height: 70vh;
  background: var(--card);
  border-radius: 16px;
  box-shadow: 0 20px 60px rgba(10,10,10,0.18);
  overflow: auto;
  transform: translateY(20px);
  opacity: 0;
  pointer-events: none;
  transition: all .25s ease;
  z-index: 999;
  padding: 22px;
}

.auth-modal.open {
  transform: translateY(0);
  opacity: 1;
  pointer-events: auto;
}

/* Título */
.auth-modal h2 {
  margin-top: 0;
  font-size: 22px;
  color: var(--accent);
  font-weight: 700;
  text-align: center;
}

/* Inputs */
.auth-modal input {
  width: 100%;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid #ddd;
  margin-bottom: 12px;
  font-size: 15px;
  outline: none;
}

.auth-modal input:focus {
  border-color: var(--accent);
}

.auth-btn {
  width: 100%;
  padding: 12px;
  border-radius: 12px;
  background: var(--accent);
  color: white;
  font-weight: 600;
  border: none;
  cursor: pointer;
  margin-top: 8px;
}

.auth-btn:hover {
  background: #ff90b5;
}

/* Google */
.google-btn {
  display: flex;
  justify-content: center;
  gap: 10px;
  align-items: center;
  background: #fff;
  padding: 12px;
  border-radius: 12px;
  border: 1px solid #ddd;
  cursor: pointer;
  font-weight: 600;
  margin-top: 10px;
}

.google-btn:hover {
  background: #f3f3f3;
}

.google-btn img {
  width: 22px;
}

/* Link login ↔ registro */
.auth-link {
  text-align: center;
  color: var(--accent);
  font-size: 14px;
  margin-top: 12px;
  cursor: pointer;
}

.auth-link:hover {
  text-decoration: underline;
}

/* Overlay */
.auth-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.4);
  opacity: 0;
  pointer-events: none;
  transition: .3s;
  z-index: 900;
}

.auth-overlay.show {
  opacity: 1;
  pointer-events: auto;
}

/* Overlay para móviles */
.overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.4);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
  z-index: 1100;
}

/* ==== MENU BUTTON ==== */
.menu-btn {
  position: fixed;
  top: 20px;
  left: 20px;
  background: #ffd166;
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 22px;
  padding: 8px 14px;
  cursor: pointer;
  z-index: 1300;
  transition: transform 0.3s ease, background 0.3s ease;
}

.menu-btn:hover {
  background: #ff6f9d;
  transform: scale(1.05);
}

/* ==== MODO RESPONSIVO ==== */
  .sidebar {
    transform: translateX(-100%);
  }

  .sidebar.open {
    transform: translateX(0);
  }

  .overlay.show {
    opacity: 1;
    pointer-events: auto;
  }


@media (min-width: 901px) {
  body {
    margin-left: 240px; /* deja espacio para el sidebar */
  }
}

a {
  display: flex;
      gap: 25px;
      align-items: center;
      text-decoration: none;
      font-weight: 500;
      color: #444;
      transition: color .3s;
      
    } 

a:hover {
      color: #ffd166;
    }
    .btn-primary2, .btn-outline3 {
      padding: 10px 10px;
      border-radius: 25px;
      font-weight: 600;
      cursor: pointer;
      transition: all 0.3s ease;
    }

    .btn-primary2 {
      border: none;
      color: #ff4f83;
    }

    .btn-primary2:hover {
      transform: scale(1.05);
      color: #ffd166;
    }

    .btn-outline3 {
      background: transparent;
      color: #ff4f83;
    }

    .btn-outline3:hover {
      transform: scale(1.05);
    }
    header{
      display:flex;
      justify-content:space-between;
      align-items:center;
      padding:20px 10%;
      background:white;
      box-shadow:var(--shadow);
      position:relative;
      z-index:10;
    }
    header h1{font-size:22px;color:var(--accent);font-weight:700}
    header p{font-size:13px;color:#666}
    .cart{
      background:var(--accent);
      color:white;
      padding:8px 14px;
      border-radius:var(--radius);
      border:none;
      cursor:pointer;
      font-weight:600;
      box-shadow:var(--shadow);
    }

    /* ===== Carrusel ===== */
    .carousel{
      position:relative;
      width:100%;
      max-width:1000px;
      margin:30px auto;
      overflow:hidden;
      border-radius:var(--radius);
      box-shadow:var(--shadow);
    }
    .slides{
      display:flex;
      transition:transform 0.6s ease-in-out;
    }
    .slide{
      min-width:100%;
      height:420px;
      overflow:hidden;
    }
    .slide img{
      width:100%;
      height:100%;
      object-fit:cover;
      display:block;
    }
    .btn-prev,.btn-next{
      position:absolute;
      top:50%;
      transform:translateY(-50%);
      background:rgba(0, 0, 0, 0.1);
      color:white;
      border:none;
      font-size:28px;
      cursor:pointer;
      padding:8px 12px;
      border-radius:50%;
      transition:background .2s;
    }
    .btn-prev:hover,.btn-next:hover{background:rgba(0,0,0,0.4)}
    .btn-prev{left:15px}
    .btn-next{right:15px}

    .dots{
      position:absolute;
      bottom:12px;
      left:50%;
      transform:translateX(-50%);
      display:flex;
      gap:8px;
    }
    .dot{
      width:12px;
      height:12px;
      border-radius:50%;
      background:rgba(255,255,255,0.6);
      cursor:pointer;
      transition:background .3s;
    }
    .dot.active{background:var(--accent)}

    
    footer{
      text-align:center;
      padding:20px;
      font-size:13px;
      color:#555;
      background:white;
      box-shadow:0 -2px 10px rgba(0,0,0,0.05);
      margin-top:50px;
    }
/* ====== Variables y reset ligero ====== */
    :root{
      --bg:#fff7f3;
      --card:#fff;
      --accent:#ff7aa2;
      --accent-2:#ffd166;
      --text:#2b2b2b;
      --muted:#6b6b6b;
      --glass: rgba(255,255,255,0.6);
      --radius:16px;
      --shadow: 0 6px 20px rgba(15,15,15,0.08);
      --glass-shadow: 0 8px 30px rgba(15,15,15,0.06);
      font-family: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial;
    }
    *{box-sizing:border-box}
    html,body{height:100%}
    body{
      margin:0;
      background: linear-gradient(180deg, #fff7f3 0%, #fff1f7 100%);
      color:var(--text);
      -webkit-font-smoothing:antialiased;
      -moz-osx-font-smoothing:grayscale;
      line-height:1.4;
      padding:24px;
    }

    /* ====== Layout ====== */
    .container{
      max-width:1100px;
      margin:0 auto;
      display:grid;
      gap:24px;
      grid-template-columns: 1fr;
    }

    header{
      display:flex;
      align-items:center;
      justify-content:space-between;
      gap:16px;
    }
    .brand{
      display:flex;
      gap:12px;
      align-items:center;
    }
    .logo{
      width:64px;
      height:64px;
      border-radius:12px;
      background: linear-gradient(135deg,#fab4bccb,#e96c7ae3);
      display:flex;
      align-items:center;
      justify-content:center;
      box-shadow:var(--glass-shadow);
      color:white;
      font-weight:700;
      font-size:20px;
    }
    .user-btn {
  font-size: 20px;
  padding: 8px 14px;
  border-radius: 8px;
  background: #ff7aa2;
  border: none;
  cursor: pointer;
  color: white;
}
    h1{font-size:20px; margin:0}
    p.lead{margin:0; color:var(--muted); font-size:13px}

    .cart-btn{
      position:relative;
      background:transparent;
      border:2px solid transparent;
      padding:8px 12px;
      border-radius:12px;
      display:flex;
      gap:10px;
      align-items:center;
      cursor:pointer;
      transition:transform .12s ease;
    }
    .cart-btn:hover{transform:translateY(-3px)}
    .cart-icon{
      width:42px;
      height:42px;
      border-radius:10px;
      background:linear-gradient(180deg,#fff,#ffeef6);
      display:flex;
      align-items:center;
      justify-content:center;
      box-shadow:var(--shadow);
      font-weight:700;
    }
    .cart-count{
      position:absolute;
      top:-6px;
      right:-6px;
      background:var(--accent);
      color:white;
      font-size:12px;
      padding:4px 7px;
      border-radius:999px;
      box-shadow:0 4px 12px rgba(0,0,0,0.15);
    }

    /* ====== Hero ====== */
    .hero{
      display:grid;
      grid-template-columns: 1fr;
      gap:18px;
      align-items:center;
      background: linear-gradient(180deg, rgba(255,255,255,0.6), rgba(255,255,255,0.4));
      border-radius:var(--radius);
      padding:18px;
      box-shadow:var(--glass-shadow);
      overflow:hidden;
    }
    .hero-inner{
      display:flex;
      gap:18px;
      flex-direction:column;
    }
    .hero h2{font-size:26px; margin:0}
    .hero p{margin:0; color:var(--muted)}
    .hero-cta{
      margin-top:8px;
      display:flex;
      gap:10px;
    }
    .btn{
      border:0;
      padding:10px 14px;
      border-radius:12px;
      cursor:pointer;
      font-weight:600;
      box-shadow:var(--shadow);
    }
    .btn-primary{background:var(--accent); color:white}
    .btn-outline{background:var(--accent);; border:1px solid rgba(0,0,0,0.06)}

    .hero-media{
      width:100%;
      height:240px;
      border-radius:12px;
      overflow:hidden;
      box-shadow: var(--shadow);
    }
    .hero-media img{width:100%; height:100%; object-fit:cover; display:block}

    /* ====== Productos ====== */
    .products{
      display:grid;
      grid-template-columns: repeat(3, 1fr);
      gap:18px;
    }
    .card{
      background:var(--card);
      border-radius:14px;
      padding:12px;
      box-shadow:var(--shadow);
      display:flex;
      flex-direction:column;
      gap:8px;
    }
    .product-media{
      width:250;
      height:140px;
      border-radius:10px;
      overflow:hidden;
    }
    .product-media img{width:100%; height:100%; object-fit:cover; display:block}
    .product-info{display:flex; justify-content:space-between; align-items:center; gap:8px}
    .product-title{font-weight:700; font-size:15px}
    .product-price{font-weight:700; color:var(--accent-2)}
    .product-actions{display:flex; gap:8px; margin-top:6px}

    .qty{
      display:inline-flex;
      align-items:center;
      gap:8px;
      background:#fafafa;
      padding:6px 8px;
      border-radius:10px;
      border:1px solid rgba(0,0,0,0.04);
    }
    .qty button{
      border:0; background:transparent; cursor:pointer; font-weight:700;
      padding:4px 6px; border-radius:6px;
    }

    /* ====== Modal carrito simple ====== */
    .modal{
      position:fixed;
      right:24px;
      bottom:24px;
      width:320px;
      max-height:70vh;
      background:var(--card);
      border-radius:14px;
      box-shadow:0 20px 60px rgba(10,10,10,0.18);
      overflow:auto;
      transform:translateY(20px);
      opacity:0;
      transition:all .22s ease;
      z-index:60;
    }
    .modal.open{transform:translateY(0); opacity:1}
    .modal .head{padding:14px; display:flex; justify-content:space-between; align-items:center; border-bottom:1px solid rgba(0,0,0,0.04)}
    .modal .body{padding:12px; display:flex; flex-direction:column; gap:10px}
    .cart-item{display:flex; gap:10px; align-items:center}
    .cart-item img{width:56px; height:56px; border-radius:8px; object-fit:cover}
    .muted{ font-size:13px}

/* ====== Toast ====== */
.toast{
      position:fixed;
      left:50%;
      bottom:24px;
      transform:translateX(-50%);
      background:rgba(40,40,40,0.95);
      color:white;
      padding:10px 14px;
      border-radius:12px;
      opacity:0;
      pointer-events:none;
      transition:all .2s ease;
      z-index:80;
}
.toast.show{opacity:1; transform:translate(-50%,-8px); pointer-events:auto}

/* ====== Responsive ====== */
/* ====== Compactación móvil ====== */
@media (max-width:920px){
  .products{
    grid-template-columns: repeat(2, 1fr);
  }
  .hero-media{
    height:180px;
  }
}

/* ========= SUPER OPTIMIZADO PARA TELÉFONO ======== */
@media (max-width:620px){

  body{
    padding:5px;
  }

  /* HEADER compacto */
  header{
    display:grid;
    grid-template-columns: auto 1fr auto;
    gap:6px;
    align-items:center;
    padding:8px 5px;
  }

  .brand{
    grid-column:1;
    display:flex;
    gap:6px;
    align-items:center;
  }

  .brand h1{
    font-size:17px;
  }

  .brand .logo{
    width:35px;
    height:35px;
    font-size:10px;
  }

  header a,
  header button{
    font-size:14px;
    padding:6px 8px;
    white-space:nowrap;
  }

  .cart-btn{
    padding:6px 8px;
  }

  .cart-icon{
    width:36px;
    height:36px;
    font-size:16px;
  }

  header p{
    font-size:14px;
  }

  /* Ajustes para evitar colisiones entre header y sidebar/menu */
  /* Mover el botón de menú a la derecha para que no tape el logo */
  .menu-btn{
    left: auto;
    right: 12px;
    top: 10px;
    z-index: 1400;
  }

  /* Hacer el sidebar más estrecho en móviles y permitir scroll interno */
  .sidebar{
    width: 78vw;
    max-width: 320px;
    overflow-y: auto;
  }

  /* Aumentar espacio a la derecha del header para el botón y reducir padding lateral */
  header{
    padding-left:12px;
    padding-right:64px; /* espacio para el botón */
  }

  /* HERO compacto en móvil */
  .hero{
    padding:10px;
  }

  .hero-inner{
    flex-direction:column;
    gap:8px;
  }

  .hero-cta{
    display:flex;
    flex-direction:row;       /* 👈 Se mantiene en una línea */
    flex-wrap:wrap;           /* 👈 Permite dos líneas si hay muchos botones */
    gap:6px;
  }

  .btn{
    font-size:13px;
    padding:7px 10px;
  }

  /* Productos en 1 ó 2 columnas compactas */
  .products{
    grid-template-columns: repeat(2, 1fr); /* 👈 Ya no 1 sola columna gigante */
    gap:12px;
  }

  .card{
    padding:8px;
    gap:0px;
  }

  .product-media{
    height:110px;    /* 👈 No se sale */
  }

  .product-title{
    font-size:14px;
  }
  .product-price{
    font-size:14px;
  }
}

/* ==============================
   SECCIÓN: PERSONALIZA TU DONA
   ============================== */

#personaliza {
  background: #fffaf7;
  padding: 40px 10%;
  border-radius: 20px;
  box-shadow: 0 0 15px rgba(255, 170, 190, 0.1);
  font-family: 'Poppins', sans-serif;
}

#personaliza h3 {
  color: #ff7aa2;
  text-align: center;
  font-size: 1.8rem;
  font-weight: 600;
  margin-bottom: 15px;
}

#personaliza p.muted {
  text-align: center;
  color: #777;
}

/* Tarjeta del formulario */
#personaliza .card {
  background: #fff;
  border-radius: 18px;
  box-shadow: 0 3px 10px rgba(0,0,0,0.05);
  transition: all 0.3s ease;
}

#personaliza .card:hover {
  transform: translateY(-3px);
  box-shadow: 0 5px 15px rgba(255, 122, 162, 0.15);
}

/* Campos del formulario */
#personaliza .field {
  display: flex;
  flex-direction: column;
  margin-bottom: 18px;
}

#personaliza label {
  font-size: 15px;
  margin-bottom: 6px;
  color: #444;
}

#personaliza select {
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid rgba(0,0,0,0.1);
  background: #fff;
  font-size: 15px;
  color: #333;
  transition: all 0.2s ease;
}

#personaliza select:focus {
  outline: none;
  border-color: #ff7aa2;
  box-shadow: 0 0 0 2px rgba(255, 122, 162, 0.25);
}

/* Botón principal */
#personaliza .btn.btn-primary {
  background-color: #ff7aa2;
  color: white;
  font-size: 16px;
  border: none;
  border-radius: 30px;
  padding: 10px 30px;
  cursor: pointer;
  transition: background-color 0.25s ease, transform 0.25s ease;
}

#personaliza .btn.btn-primary:hover {
  background-color: #ff97b8;
  transform: scale(1.05);
}

/* Opciones múltiples (checkboxes) */
.multi-options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px 15px;
  padding: 10px;
  background: #fff6fb;
  border-radius: 10px;
  border: 1px solid #ffd0e3;
}

.multi-options label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  cursor: pointer;
}

.multi-options input[type="checkbox"] {
  transform: scale(1.3);
  accent-color: #ff7aa2;
}


/* Adaptación móvil */
@media (max-width: 600px) {
  #personaliza {
    padding: 30px 5%;
  }

  #personaliza .card {
    padding: 16px;
  }

  #personaliza select {
    font-size: 14px;
  }

  #personaliza .btn.btn-primary {
    width: 100%;
  }
}
