:root{
  --bg: #0b0f17;
  --bg2:#0f1624;
  --card:#121b2c;

  /* Contraste real (texto) */
  --text: rgba(255,255,255,.92);
  --muted: rgba(255,255,255,.72);
  --muted2: rgba(255,255,255,.60);

  /* Bordes / superficies */
  --white-10: rgba(255,255,255,.10);
  --white-60: rgba(255,255,255,.60);
  --white-70: rgba(255,255,255,.70);
  --white-75: rgba(255,255,255,.75);

  /* Accentos */
  --accent: #0d6efd;      /* bootstrap primary */
  --success: #00e18b;
  --warning: #ffc107;
  --danger:  #ff2d55;
}

/* ===== Base ===== */
html, body { height: 100%; }
body{
  background: var(--bg);
  color: var(--text);
}

/* Evita que Bootstrap deje texto oscuro en secciones oscuras */
.bg-app{ background: var(--bg) !important; }
.text-app{ color: var(--text) !important; }

.bg-dark-1{ background: rgba(255,255,255,.03) !important; }
.bg-dark-2{ background: var(--card) !important; }

.border-white-10{ border-color: var(--white-10) !important; }
.text-white-60{ color: var(--white-60) !important; }
.text-white-70{ color: var(--white-70) !important; }
.text-white-75{ color: var(--white-75) !important; }

/* Links */
a{ color: rgba(255,255,255,.86); }
a:hover{ color: #fff; }

.link-soft{
  color: rgba(255,255,255,.72);
  text-decoration: none;
}
.link-soft:hover{ color:#fff; }

/* Bootstrap helpers típicos que causan contraste malo */
.text-dark,
.text-body,
.text-secondary,
.text-muted{
  color: var(--muted) !important;
}
.bg-light,
.bg-white{
  background: rgba(255,255,255,.04) !important;
  color: var(--text) !important;
}

/* Inputs / selects / forms (Bootstrap por defecto pone texto oscuro) */
.form-control,
.form-select,
.form-control:focus,
.form-select:focus{
  background: rgba(255,255,255,.03) !important;
  border: 1px solid var(--white-10) !important;
  color: var(--text) !important;
  box-shadow: none !important;
}

/* ===== FIX dropdown options dark ===== */
.form-select option {
  background-color: #111827 !important; /* gris oscuro real */
  color: #ffffff !important;
}

/* Para navegadores basados en Webkit */
select {
  background-color: rgba(255,255,255,.03);
  color: var(--text);
}
.form-control::placeholder{
  color: rgba(255,255,255,.45) !important;
}
.input-group-text{
  background: rgba(255,255,255,.04) !important;
  border: 1px solid var(--white-10) !important;
  color: var(--muted) !important;
}

/* Dropdown / modal / offcanvas */
.dropdown-menu,
.modal-content,
.offcanvas{
  background: rgba(15,22,36,.96) !important;
  color: var(--text) !important;
  border: 1px solid var(--white-10) !important;
}
.dropdown-item{
  color: var(--muted) !important;
}
.dropdown-item:hover,
.dropdown-item:focus{
  background: rgba(255,255,255,.06) !important;
  color: #fff !important;
}

/* Cards por defecto de Bootstrap: fuerza texto claro */
.card{
  background: rgba(18,27,44,.72);
  border: 1px solid var(--white-10);
  color: var(--text);
}
.card .card-title{ color: #fff; }
.card .card-text{ color: var(--muted); }

/* Tablas (Bootstrap suele meter texto oscuro) */
.table{ color: var(--text) !important; }
.table thead th{ color:#fff !important; }
.table td, .table th{ border-color: var(--white-10) !important; }
.table-striped>tbody>tr:nth-of-type(odd)>*{ color: var(--text) !important; background-color: rgba(255,255,255,.02) !important; }

/* List groups */
.list-group-item{ color: var(--text) !important; }

/* Badges */
.badge{ border: 1px solid rgba(255,255,255,.08); }

/* ===== UI components ===== */
.nav-blur{
  backdrop-filter: blur(14px);
  background: rgba(11,15,23,.72);
}

/* Pill */
.pill{
  display:inline-block;
  padding:.45rem .75rem;
  border: 1px solid var(--white-10);
  border-radius: 999px;
  background: rgba(255,255,255,.05);
  color: rgba(255,255,255,.88);
  font-weight:600;
  font-size:.9rem;
}

/* Hero */
.hero{
  position:relative;
  min-height: 74vh;
  display:flex;
  align-items:center;
  overflow:hidden;
}
.hero-video{
  position:absolute;
  inset:0;
  width:100%;
  height:100%;
  object-fit:cover;
  filter:saturate(1.05) contrast(1.05);
}
.hero-overlay{
  position:absolute;
  inset:0;
  background: radial-gradient(circle at 20% 10%, rgba(0,153,255,.22), transparent 45%),
              linear-gradient(180deg, rgba(0,0,0,.50), rgba(0,0,0,.70));
}
.hero-content{
  position:relative;
  z-index:2;
  padding: 4rem 0;
}
.hero-card{
  background: rgba(18,27,44,.72);
  border: 1px solid var(--white-10);
  border-radius: 20px;
  padding: 1.2rem;
  box-shadow: 0 22px 60px rgba(0,0,0,.45);
  color: var(--text);
}

/* Mini-stat */
.mini-stat{
  padding:.65rem .85rem;
  border-radius: 14px;
  border: 1px solid var(--white-10);
  background: rgba(255,255,255,.04);
  display:flex; gap:.35rem; flex-direction:column;
  color: var(--text);
}
.mini-stat b{ font-size:.95rem; color:#fff; }
.mini-stat span{ font-size:.85rem; color: var(--white-70); }

/* Categorías */
.cat-card{
  display:block;
  text-decoration:none;
  color: var(--text);
  padding:.75rem;
  border: 1px solid var(--white-10);
  border-radius: 18px;
  background: rgba(255,255,255,.03);
  transition: transform .18s ease, background .18s ease;
}
.cat-card:hover{ transform: translateY(-2px); background: rgba(255,255,255,.05); color:#fff; }

/* ===== Productos: grid 2/3/4/5 + cards responsivas ===== */
.products-grid{
  display:grid;
  gap: 1rem;
  grid-template-columns: repeat(2, minmax(0, 1fr)); /* móviles: 2 */
}
@media (min-width: 768px){ /* tablets */
  .products-grid{ grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (min-width: 1200px){ /* semi grandes */
  .products-grid{ grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (min-width: 1600px){ /* extra grandes */
  .products-grid{ grid-template-columns: repeat(5, minmax(0, 1fr)); }
}

.pcard{
  background: var(--card);
  border: 1px solid var(--white-10);
  border-radius: 18px;
  overflow: hidden;
  height: 100%;
  display:flex;
  flex-direction:column;
  box-shadow: 0 10px 26px rgba(0,0,0,.25);
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.pcard:hover{
  transform: translateY(-3px);
  box-shadow: 0 18px 44px rgba(0,0,0,.38);
  border-color: rgba(255,255,255,.16);
}

/* Imagen: no expandir, ajustar y dejar fondo blanco sobrante */
.pcard-media{ background: #fff; }
.pcard-media img{
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  display:block;
}

.pcard-body{ padding: 12px 12px 10px; display:flex; flex-direction:column; flex:1; }
.pcard-title{
  color:#fff;
  font-weight: 700;
  line-height:1.2;
  margin: 0 0 .5rem;
  display:-webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow:hidden;
  min-height: 2.4em; /* mantiene altura visual */
}

.pcard-actions{ padding: 10px 12px 12px; display:flex; gap:10px; }
.pcard-actions .btn{ border-radius: 12px; }
.pcard-actions .btn i{ font-size: 1.05rem; line-height:0; }

/* Producto card */
.card-prod{
  background: rgba(18,27,44,.72);
  border: 1px solid var(--white-10);
  border-radius: 18px;
  overflow:hidden;
  box-shadow: 0 16px 44px rgba(0,0,0,.34);
  color: var(--text);
}
.badge-discount{
  position:absolute;
  top:12px;
  right:12px;
  background: rgba(255,45,85,.95);
  color:#fff;
  padding:.35rem .55rem;
  border-radius: 12px;
  font-weight:800;
  font-size:.85rem;
  box-shadow: 0 12px 30px rgba(255,45,85,.25);
}

/* Precios */
.price-line{
  display:flex;
  gap:.65rem;
  align-items: baseline;
}
.price-detail{ font-weight:800; font-size:1.1rem; color:#fff; }
.price-detail.strike{ text-decoration: underline; opacity:.88; }
.price-wholesale{ font-weight:900; font-size:1.15rem; color: var(--success); }

/* Reviews */
.review-card{
  min-width: 320px;
  max-width: 320px;
  padding: 1rem;
  border-radius: 18px;
  border: 1px solid var(--white-10);
  background: rgba(255,255,255,.04);
  box-shadow: 0 12px 34px rgba(0,0,0,.25);
  color: var(--text);
}
.star{ color: rgba(255,255,255,.25); font-size: 1rem; }
.star.on{ color: #ffd166; }

/* Marquee */
.marquee{
  position:relative;
  overflow:hidden;
  border-radius: 18px;
  border: 1px solid var(--white-10);
  background: rgba(255,255,255,.02);
}
.marquee-track{
  display:flex;
  gap: 14px;
  padding: 14px;
  width:max-content;
  animation: marquee 26s linear infinite;
}
.marquee:hover .marquee-track{ animation-play-state: paused; }
.marquee-brands .marquee-track{ animation-duration: 22s; }

@keyframes marquee{
  from { transform: translateX(0); }
  to   { transform: translateX(-33.333%); }
}
@media (prefers-reduced-motion: reduce){
  .marquee-track{ animation: none !important; }
}

/* Brands pill */
.brand-pill{
  display:flex;
  align-items:center;
  gap:.65rem;
  padding: .75rem 1rem;
  border: 1px solid var(--white-10);
  border-radius: 999px;
  background: rgba(255,255,255,.04);
  min-width: 220px;
  color: var(--text);
}
.brand-pill img{
  width: 38px;
  height: 38px;
  object-fit: contain;
  border-radius: 10px;
  background: rgba(0,0,0,.2);
  padding: 6px;
}

/* Prefooter score */
.prefooter-score{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap: 14px;
  padding: 1.25rem;
  border-radius: 22px;
  border: 1px solid var(--white-10);
  background: rgba(255,255,255,.03);
  color: var(--text);
}

/* Thumbs */
.thumb{
  border: 1px solid var(--white-10);
  background: rgba(255,255,255,.02);
  border-radius: 12px;
  padding: 0;
  overflow:hidden;
  width: 72px;
  height: 54px;
}
.thumb img{ width:100%; height:100%; object-fit:cover; display:block; }

/* Coupon box */
.coupon-box{
  padding: .9rem 1rem;
  border-radius: 18px;
  border: 1px solid rgba(255,193,7,.35);
  background: rgba(255,193,7,.08);
  color: var(--text);
}

/* Countdown */
.countdown{
  font-weight: 900;
  letter-spacing: .5px;
  font-size: 1.15rem;
  color:#fff;
}

/* HTML content */
.content-html p{ color: rgba(255,255,255,.82); }

/* Pagination */
.pagination-dark .page-link{
  background: rgba(255,255,255,.03);
  border: 1px solid var(--white-10);
  color: rgba(255,255,255,.86);
}
.pagination-dark .page-item.active .page-link{
  background: rgba(13,110,253,.25);
  border-color: rgba(13,110,253,.45);
  color: #fff;
}
.admin-shell{display:flex;min-height:100vh}
.admin-side{
  width:260px;flex:0 0 260px;background:#0b1322;border-right:1px solid rgba(255,255,255,.08);
  position:sticky;top:0;height:100vh;overflow:auto;transition:transform .2s ease;
}
.admin-brand{padding:16px;border-bottom:1px solid rgba(255,255,255,.08)}
.admin-nav{padding:10px;display:flex;flex-direction:column;gap:8px}
.admin-link{
  display:flex;justify-content:space-between;align-items:center;
  padding:10px 12px;border-radius:12px;color:rgba(255,255,255,.85);
  text-decoration:none;border:1px solid rgba(255,255,255,.08);background:rgba(255,255,255,.03)
}
.admin-link:hover{background:rgba(255,255,255,.06)}
.admin-link.active{border-color:rgba(0,153,255,.45);background:rgba(0,153,255,.10)}
.admin-sep{height:1px;background:rgba(255,255,255,.08);margin:10px 0}

.admin-main{flex:1;min-width:0}
.admin-topbar{
  position:sticky;top:0;z-index:20;background:#0b0f17;
  border-bottom:1px solid rgba(255,255,255,.08);
  padding:12px 14px;display:flex;align-items:center;gap:10px
}
.admin-content{padding:16px}

.bg-dark-2{background:#0f1729}
.border-white-10{border-color:rgba(255,255,255,.10)!important}
.text-white-60{color:rgba(255,255,255,.6)!important}
.text-white-70{color:rgba(255,255,255,.7)!important}

@media(max-width:992px){
  .admin-side{position:fixed;left:0;top:0;transform:translateX(-105%);z-index:50}
  .admin-side.open{transform:translateX(0)}
}


/* ===== Admin UX helpers ===== */
.no-scroll{ overflow:hidden; }

.admin-overlay{
  position:fixed; inset:0;
  background: rgba(0,0,0,.55);
  opacity:0; pointer-events:none;
  transition: opacity .18s ease;
  z-index: 40;
}
.admin-overlay.show{ opacity:1; pointer-events:auto; }

@media (max-width: 991.98px){
  .admin-side{
    position:fixed;
    left:0; top:0;
    transform: translateX(-102%);
    z-index: 50;
    box-shadow: 0 20px 60px rgba(0,0,0,.55);
  }
  .admin-side.open{ transform: translateX(0); }
  .admin-topbar{ padding-left: 12px; }
}

/* Cards / surfaces */
.card-soft{
  background: rgba(255,255,255,.035);
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 16px;
  box-shadow: 0 10px 30px rgba(0,0,0,.25);
}
.card-soft .card-header{
  background: transparent;
  border-bottom: 1px solid rgba(255,255,255,.08);
}

/* Tables */
.table-app{
  --bs-table-bg: rgba(255,255,255,.02);
  --bs-table-color: rgba(255,255,255,.88);
  --bs-table-border-color: rgba(255,255,255,.08);
  --bs-table-striped-bg: rgba(255,255,255,.03);
  --bs-table-hover-bg: rgba(255,255,255,.045);
}
.table-app thead th{
  color: rgba(255,255,255,.78);
  font-weight: 600;
  letter-spacing: .2px;
}
.table-app td, .table-app th{ vertical-align: middle; }
.table-app .text-muted{ color: rgba(255,255,255,.62) !important; }

/* Badges */
.badge-soft{
  padding:.38rem .6rem;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.06);
  color: rgba(255,255,255,.86);
  font-weight: 600;
}
.badge-soft.success{ border-color: rgba(0,225,139,.35); background: rgba(0,225,139,.12); }
.badge-soft.warning{ border-color: rgba(255,193,7,.35); background: rgba(255,193,7,.12); }
.badge-soft.danger{ border-color: rgba(255,45,85,.35); background: rgba(255,45,85,.12); }
.badge-soft.info{ border-color: rgba(13,110,253,.35); background: rgba(13,110,253,.12); }

.badge-rating{
  position:absolute;
  top:12px;
  left:12px;
  padding:.35rem .55rem;
  border-radius:12px;
  font-weight:800;
  font-size:.85rem;
  background: rgba(15,22,36,.92);
  color:#fff;
  border: 1px solid rgba(255,255,255,.10);
  box-shadow: 0 12px 30px rgba(0,0,0,.25);
  z-index: 5;
}
.badge-discount{
  z-index: 6; /* por si algún overlay tapa */
}
/* Fix: encabezados de tabla (th) limpios */
.table thead th{
  background: transparent !important;
}
.table thead th *{
  background: transparent !important;
}
/* ===== FIX TABLAS (tbody en claro + texto blanco) ===== */
.table{
  color: var(--text) !important;
}

.table tbody td{
  background: rgba(15,22,36,.70) !important; /* fondo dark */
  color: var(--text) !important;
  border-color: var(--white-10) !important;
}

/* Si estás usando .table-striped o .table-hover */
.table-striped > tbody > tr:nth-of-type(odd) > *{
  background: rgba(15,22,36,.82) !important;
}
.table-hover > tbody > tr:hover > *{
  background: rgba(255,255,255,.06) !important;
}

/* Textos típicos dentro de tablas que a veces quedan raros */
.table td a,
.table td span,
.table td small,
.table td div{
  color: inherit !important;
}

/* Inputs/selects dentro de tablas (si los hay) */
.table .form-control,
.table .form-select{
  background: rgba(255,255,255,.05) !important;
  color: var(--text) !important;
  border: 1px solid var(--white-10) !important;
}
.table .form-select option{
  background: rgba(15,22,36,.98) !important;
  color: #fff !important;
}
.table tbody td[style*="background"],
.table tbody td[style*="background-color"]{
  background: rgba(15,22,36,.70) !important;
}
/* === Posición de botones en card === */
.pcard-body{
  padding: 12px 12px 6px !important;  /* baja el padding bottom (sube acciones) */
}

.pcard .product-actions{
  margin-top: 0 !important;           /* ya NO dependes de mt-2 */
  padding: 8px 12px 12px !important;  /* ajusta aquí para subir/bajar */
}

/* Si aún los quieres MÁS arriba, baja este padding-top a 6px o 4px */

.product-actions .btn-action{
  padding: .25rem .85rem; /* alto/ancho */
  font-size: .95rem;      /* tamaño texto */
  border-radius: 14px;
}
.product-actions .btn-ico svg{
  width: 18px;
  height: 18px;
}

.feature-media{
  border:1px solid rgba(255,255,255,.12);
  background:#ffffff; /* ← BLANCO real */
  border-radius:16px;
  overflow:hidden;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:0; /* ← quitamos padding oscuro */
  min-height:360px;
}

.feature-media img{
  width:60%;
  height:60%;
  object-fit:contain; /* mantiene botella completa */
  object-position:center;
  display:block;
  background:#ffffff; /* ← relleno blanco si sobra espacio */
}

@media (max-width: 991.98px){
  .feature-media{ min-height:240px; }
}

/* =========================
   Footer (front)
   ========================= */
.site-footer{
  background: linear-gradient(180deg, rgba(255,255,255,.02), rgba(255,255,255,0));
}

.footer-brand{ color: var(--text) !important; }

.footer-logo{
  display:block;
  width: 100%;
  max-width: 160px;   
  max-height: 80px;  
  height: auto;
  object-fit: contain;
  background: transparent;
  border: 0;
  border-radius: 0;
}

/* En móvil aún más compacto */
@media (max-width: 575.98px){
  .footer-logo{
    max-width: 260px;
    max-height: 96px;
    margin-inline: auto; /* centra en móvil */
  }
}
.footer-name{
  font-size: 1.05rem;
  letter-spacing: .2px;
}

.footer-title{
  font-size: .82rem;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: var(--white-70);
  margin-bottom: .6rem;
}

.footer-links li,
.footer-contact li{
  margin: .35rem 0;
}

.social-pill{
  width: 40px;
  height: 40px;
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  background: rgba(255,255,255,.04);
  border: 1px solid var(--white-10);
  color: rgba(255,255,255,.86);
  transition: transform .15s ease, background .15s ease, border-color .15s ease;
}
.social-pill:hover{
  transform: translateY(-1px);
  background: rgba(255,255,255,.07);
  border-color: rgba(255,255,255,.18);
  color: #fff;
}

.nl-msg{
  min-height: 1.2rem;
  font-size: .92rem;
  color: var(--white-70);
}
.nl-msg.is-ok{ color: var(--success); }
.nl-msg.is-err{ color: var(--danger); }

/* =====================
   PWA / Mobile Tabbar
   ===================== */

.nav-install-btn{ width:100%; }
@media (min-width: 992px){
  .nav-install-btn{ width:auto; }
}

.front-body{ padding-bottom: 0; }
@media (max-width: 991.98px){
  .front-body{ padding-bottom: 74px; }
}

.mobile-tabbar{
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1030;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 6px;
  padding: 10px 10px calc(10px + env(safe-area-inset-bottom));
  background: rgba(12,15,23,.92);
  border-top: 1px solid rgba(255,255,255,.10);
  backdrop-filter: blur(12px);
}

.mobile-tabbar .tab-item{
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 8px 6px;
  border-radius: 14px;
  color: rgba(255,255,255,.78);
  text-decoration: none;
  border: 1px solid rgba(255,255,255,.08);
  background: rgba(255,255,255,.03);
}

.mobile-tabbar .tab-item i{ font-size: 18px; line-height: 1; }
.mobile-tabbar .tab-item span{ font-size: 11px; line-height: 1.1; }

.mobile-tabbar .tab-item.active{
  color: #fff;
  background: rgba(255,255,255,.08);
  border-color: rgba(255,255,255,.14);
}

.mobile-tabbar .tab-btn{
  appearance: none;
  border: 1px solid rgba(255,255,255,.08);
  background: rgba(255,255,255,.03);
}

button.admin-link{
  width: 100%;
  font: inherit;
  text-align: left;
  cursor: pointer;
}