/*====================================================
  VARIABLES.CSS
  Variables globales del tema visual
====================================================*/

:root{

    /*==================================================
      IDENTIDAD DE LA EMPRESA
      (Modificadas desde config-data.js)
    ==================================================*/

    --color-principal: #206d58;
    --color-secundario: #ffffff;

    --logo-width: 54px;
    --logo-height: 54px;

    /*==================================================
      FONDOS
    ==================================================*/

    --color-fondo: #F5F5F5;

    --color-panel: #FFFFFF;

    --color-panel-secundario: #FAFAFA;

    /*==================================================
      TIPOGRAFÍA
    ==================================================*/

    --font-family:
        Arial,
        Helvetica,
        sans-serif;

    --font-xs: .75rem;
    --font-sm: .85rem;
    --font-md: 1rem;
    --font-lg: 1.20rem;
    --font-xl: 1.50rem;

    --font-weight-normal:400;
    --font-weight-medium:500;
    --font-weight-bold:700;

    /*==================================================
      COLORES DE TEXTO
    ==================================================*/

    --color-texto:#222222;

    --color-texto-secundario:#666666;

    --color-texto-claro:#FFFFFF;

    /*==================================================
      BORDES
    ==================================================*/

    --color-borde:#DDDDDD;

    --color-borde-suave:#EEEEEE;

    --radius-sm:8px;

    --radius-md:12px;

    --radius-lg:16px;

    --radius-pill:999px;

    /*==================================================
      SOMBRAS
    ==================================================*/

    --shadow-sm:
        0 2px 6px rgba(0,0,0,.08);

    --shadow-md:
        0 4px 12px rgba(0,0,0,.10);

    --shadow-lg:
        0 8px 20px rgba(0,0,0,.15);

    /*==================================================
      HEADER
    ==================================================*/

    --header-top-height:74px;

    --header-search-height:62px;

    --header-icon-color:#FFFFFF;

    --header-placeholder:#888888;

    /*==================================================
      INPUTS
    ==================================================*/

    --input-height:44px;

    --input-radius:999px;

    /*==================================================
      BOTONES
    ==================================================*/

    --button-height:44px;

    --button-radius:999px;

    /*==================================================
      PRODUCTOS
    ==================================================*/

    --product-radius:16px;

    --product-image-radius:12px;

    /*==================================================
      ESTADOS
    ==================================================*/

    --color-stock:#2E7D32;

    --color-sin-stock:#D32F2F;

    --color-promocion:#E53935;

    --color-nuevo:#1565C0;

    --color-destacado:#FF9800;

    /*==================================================
      INFORMACIÓN
    ==================================================*/

    --color-exito:#2E7D32;

    --color-alerta:#F9A825;

    --color-error:#C62828;

    --color-info:#1976D2;

    /*==================================================
      ESPACIADOS
    ==================================================*/

    --space-xs:4px;

    --space-sm:8px;

    --space-md:12px;

    --space-lg:16px;

    --space-xl:24px;

    --space-xxl:32px;

    /*==================================================
      TRANSICIONES
    ==================================================*/

    --transition-fast:.15s;

    --transition:.25s;

    --transition-slow:.40s;

    /*==================================================
      CAPAS (z-index)
    ==================================================*/

    --z-header:1000;

    --z-banner:900;

    --z-modal:2000;

    --z-toast:3000;

}

/*====================================================
BOTON COMPARTIR
====================================================*/

.btn-compartir {
  width: 42px;
  height: 42px;
  border: none;
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
}

.btn-compartir svg {
  width: 26px;
  height: 26px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  color: #ffffff;
}

.modal-compartir {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);

  display: none;
  align-items: center;
  justify-content: center;

  z-index: 9999;

  padding: 20px;
}

.modal-compartir.activo {
  display: flex;
}

.modal-compartir-contenido {
  position: relative;

  width: 100%;
  max-width: 400px;

  background: white;
  border-radius: 20px;

  padding: 30px 25px;

  text-align: center;

  box-shadow: 0 15px 40px rgba(0,0,0,.25);

  animation: aparecerModal .2s ease-out;
}

@keyframes aparecerModal {
  from {
      opacity: 0;
      transform: scale(.95);
  }

  to {
      opacity: 1;
      transform: scale(1);
  }
}

.modal-compartir h2 {
  margin: 0 0 25px;
  font-size: 26px;
  color: #FFA500;
}

.cerrar-modal {
  position: absolute;
  top: 10px;
  right: 15px;

  border: none;
  background: none;

  font-size: 32px;
  line-height: 1;

  cursor: pointer;

  color: #666;
}

.opcion-compartir h3 {
  margin-bottom: 15px;
}

#qrCompartir {
  display: flex;
  justify-content: center;
  margin: 10px auto 15px;
}

#qrCompartir img,
#qrCompartir canvas {
  width: 180px !important;
  height: 180px !important;
}

.opcion-compartir p {
  font-size: 14px;
  color: #666;
  margin: 0 auto;
  max-width: 280px;
}

.separador {
  display: flex;
  align-items: center;
  gap: 15px;

  margin: 25px 0;

  color: #999;
}

.separador::before,
.separador::after {
  content: "";
  height: 1px;
  background: #ddd;
  flex: 1;
}

.btn-link-compartir {
  width: 100%;

  border: none;
  border-radius: 12px;

  padding: 15px;

  font-size: 17px;
  font-weight: 600;

  cursor: pointer;

  background: #25D366;
  color: white;

  transition: transform .1s, opacity .1s;
}

.btn-link-compartir:active {
  transform: scale(.97);
  opacity: .9;
}


.toast-compartir {
  position: fixed;

  left: 50%;
  bottom: 30px;

  transform: translateX(-50%) translateY(20px);

  background: #222;
  color: white;

  padding: 14px 20px;

  border-radius: 10px;

  font-size: 15px;

  opacity: 0;
  pointer-events: none;

  z-index: 10000;

  transition:
      opacity .25s ease,
      transform .25s ease;

  white-space: nowrap;
}

.toast-compartir.mostrar {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}
