/* =====================================================================
   CALI VIVA · LUGARES, CATEGORÍAS Y CRÓNICA DE CADA SITIO
   Va después de site.css. Todas las clases empiezan con "lv-" para
   no chocar con Bootstrap ni con tu site.css.
   ===================================================================== */

:root {
    --lv-verde: #00b140;
    --lv-verde-claro: #00d26a;
    --lv-noche: #0f172a;
    --lv-tinta: #1b1b1b;
    --lv-papel: #f7f3ea;
    --lv-linea: #d9d2c3;
    --lv-gris: #6b6b6b;
    --lv-serif: 'Fraunces', Georgia, 'Times New Roman', serif;
    --lv-texto: 'Source Serif 4', Georgia, serif;
}

.lv-pagina { margin-top: 85px; }   /* site.css le quita el padding a main */

/* Aparición suave al hacer scroll */
.lv-aparece {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity .7s ease, transform .7s cubic-bezier(.2,.7,.2,1);
}
.lv-aparece.visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
    .lv-aparece { opacity: 1; transform: none; transition: none; }
}

/* Foto que no ha cargado: se ve la inicial del sitio en vez de un hueco */
.lv-foto {
    position: relative;
    overflow: hidden;
    background:
        radial-gradient(circle at 30% 20%, rgba(0,210,106,.35), transparent 55%),
        var(--lv-noche);
}
.lv-foto::before {
    content: attr(data-inicial);
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--lv-serif);
    font-size: 6rem;
    font-weight: 700;
    color: rgba(255,255,255,.12);
}
.lv-foto img {
    position: relative;
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .8s cubic-bezier(.2,.7,.2,1);
}

/* =====================================================================
   1. PÁGINA LUGARES
   ===================================================================== */

.lv-portada {
    background: var(--lv-noche);
    color: #fff;
    padding: 90px 8% 70px;
    position: relative;
    overflow: hidden;
}
.lv-portada::after {          /* línea verde que cruza, detalle de marca */
    content: "";
    position: absolute;
    left: 8%;
    bottom: 0;
    width: 120px;
    height: 4px;
    background: var(--lv-verde-claro);
}
.lv-portada small {
    text-transform: uppercase;
    letter-spacing: 3px;
    font-size: .8rem;
    color: var(--lv-verde-claro);
    font-weight: 700;
}
.lv-portada h1 {
    font-family: var(--lv-serif);
    font-size: clamp(3rem, 8vw, 6rem);
    font-weight: 700;
    line-height: .95;
    margin: 14px 0 18px;
    letter-spacing: -1px;
}
.lv-portada p {
    max-width: 560px;
    font-size: 1.15rem;
    color: rgba(255,255,255,.75);
    margin: 0;
}

.lv-categorias {
    padding: 70px 8% 100px;
    background: #f8fafc;
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 18px;
    grid-auto-rows: 260px;
}
/* Mosaico: unas grandes y otras pequeñas para que no se vea como plantilla */
.lv-cat:nth-child(1) { grid-column: span 4; grid-row: span 2; }
.lv-cat:nth-child(2) { grid-column: span 2; }
.lv-cat:nth-child(3) { grid-column: span 2; }
.lv-cat:nth-child(4) { grid-column: span 2; }
.lv-cat:nth-child(5) { grid-column: span 2; }
.lv-cat:nth-child(6) { grid-column: span 2; }
.lv-cat:nth-child(7) { grid-column: span 6; }

.lv-cat {
    position: relative;
    border-radius: 22px;
    overflow: hidden;
    color: #fff;
    text-decoration: none;
    isolation: isolate;
}
.lv-cat .lv-foto { position: absolute; inset: 0; }
.lv-cat::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(10,15,25,.88) 0%, rgba(10,15,25,.15) 55%, transparent);
    transition: background .4s;
    z-index: 1;
}
.lv-cat-texto {
    position: absolute;
    left: 26px;
    right: 26px;
    bottom: 22px;
    z-index: 2;
}
.lv-cat-num {
    font-size: .8rem;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--lv-verde-claro);
}
.lv-cat h2 {
    font-family: var(--lv-serif);
    font-size: 2rem;
    font-weight: 600;
    margin: 4px 0 0;
    line-height: 1.05;
}
.lv-cat:nth-child(1) h2 { font-size: 3.2rem; }
.lv-cat p {
    margin: 0;
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    color: rgba(255,255,255,.85);
    transition: max-height .45s ease, opacity .35s ease, margin .35s;
}
.lv-flecha {
    position: absolute;
    top: 20px;
    right: 20px;
    z-index: 2;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    border: 1px solid rgba(255,255,255,.5);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .3s, border-color .3s, transform .4s;
}
.lv-flecha svg { width: 20px; height: 20px; }

.lv-cat:hover .lv-foto img { transform: scale(1.07); }
.lv-cat:hover::after { background: linear-gradient(to top, rgba(10,15,25,.92) 0%, rgba(10,15,25,.35) 70%, rgba(10,15,25,.1)); }
.lv-cat:hover p { max-height: 80px; opacity: 1; margin-top: 8px; }
.lv-cat:hover .lv-flecha { background: var(--lv-verde); border-color: var(--lv-verde); transform: rotate(-45deg); }
.lv-cat:focus-visible { outline: 3px solid var(--lv-verde-claro); outline-offset: 4px; }

/* =====================================================================
   2. PÁGINA DE UNA CATEGORÍA
   ===================================================================== */

.lv-cabecera {
    position: relative;
    min-height: 360px;
    display: flex;
    align-items: flex-end;
    color: #fff;
    padding: 0 8% 50px;
}
.lv-cabecera .lv-foto { position: absolute; inset: 0; }
.lv-cabecera::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(10,15,25,.95), rgba(10,15,25,.45));
}
.lv-cabecera-texto { position: relative; z-index: 2; max-width: 700px; }
.lv-migas {
    font-size: .9rem;
    color: rgba(255,255,255,.7);
}
.lv-migas a { color: #fff; text-decoration: none; border-bottom: 1px solid rgba(255,255,255,.4); }
.lv-migas a:hover { color: var(--lv-verde-claro); border-color: var(--lv-verde-claro); }
.lv-cabecera h1 {
    font-family: var(--lv-serif);
    font-size: clamp(2.6rem, 6vw, 4.5rem);
    font-weight: 700;
    margin: 12px 0 8px;
    line-height: 1;
}
.lv-cabecera p { font-size: 1.15rem; color: rgba(255,255,255,.8); margin: 0; }

/* Barra de otras categorías + buscador */
.lv-barra {
    position: sticky;
    top: 85px;
    z-index: 50;
    background: rgba(248,250,252,.92);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid #e5e9f0;
    padding: 14px 8%;
    display: flex;
    gap: 16px;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
}
.lv-chips {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    scrollbar-width: none;
    flex: 1;
    min-width: 0;
    /* se desvanece en el borde para que se note que se puede deslizar */
    -webkit-mask-image: linear-gradient(to right, #000 85%, transparent);
            mask-image: linear-gradient(to right, #000 85%, transparent);
    padding-right: 40px;
}
.lv-chips::-webkit-scrollbar { display: none; }
.lv-chip {
    white-space: nowrap;
    padding: 8px 16px;
    border-radius: 50px;
    border: 1px solid #d6dbe4;
    color: #333;
    text-decoration: none;
    font-weight: 600;
    font-size: .9rem;
    transition: .25s;
}
.lv-chip:hover { border-color: var(--lv-verde); color: var(--lv-verde); }
.lv-chip.activa { background: var(--lv-noche); border-color: var(--lv-noche); color: #fff; }

.lv-buscar {
    position: relative;
    width: 260px;
    max-width: 100%;
}
.lv-buscar svg {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    color: #888;
}
.lv-buscar input {
    width: 100%;
    padding: 10px 16px 10px 40px;
    border-radius: 50px;
    border: 1px solid #d6dbe4;
    background: #fff;
    font: inherit;
    outline: none;
    transition: border-color .2s, box-shadow .2s;
}
.lv-buscar input:focus { border-color: var(--lv-verde); box-shadow: 0 0 0 3px rgba(0,177,64,.15); }

.lv-listado {
    padding: 50px 8% 100px;
    background: #f8fafc;
}
.lv-contador { color: var(--lv-gris); margin-bottom: 26px; font-size: .95rem; }

.lv-sitios {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 28px;
}
.lv-sitio {
    display: block;
    background: #fff;
    border-radius: 22px;
    overflow: hidden;
    text-decoration: none;
    color: inherit;
    border: 1px solid #e5e9f0;
    transition: transform .35s cubic-bezier(.2,.7,.2,1), box-shadow .35s, border-color .35s;
}
.lv-sitio .lv-foto { height: 230px; }
.lv-sitio-info { padding: 22px 24px 24px; }
.lv-sitio-meta {
    font-size: .78rem;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--lv-gris);
    font-weight: 700;
}
.lv-sitio h3 {
    font-family: var(--lv-serif);
    font-size: 1.6rem;
    font-weight: 600;
    margin: 6px 0 8px;
}
.lv-sitio-bajada {
    color: #555;
    line-height: 1.55;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.lv-sitio-pie {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 18px;
    padding-top: 16px;
    border-top: 1px dashed #e0e4ea;
}
.lv-leer {
    font-weight: 700;
    color: var(--lv-noche);
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.lv-leer svg { width: 16px; height: 16px; transition: transform .3s; }

.lv-sello {                         /* el bono, como un sello de cupón */
    position: absolute;
    top: 16px;
    left: 16px;
    background: #fff;
    color: var(--lv-noche);
    font-weight: 800;
    font-size: .8rem;
    padding: 7px 12px 7px 10px;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    box-shadow: 0 6px 18px rgba(0,0,0,.18);
}
.lv-sello i {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--lv-verde);
    box-shadow: 0 0 0 4px rgba(0,177,64,.2);
}

.lv-sitio:hover { transform: translateY(-6px); box-shadow: 0 24px 40px rgba(15,23,42,.12); border-color: transparent; }
.lv-sitio:hover .lv-foto img { transform: scale(1.06); }
.lv-sitio:hover .lv-leer { color: var(--lv-verde); }
.lv-sitio:hover .lv-leer svg { transform: translateX(4px); }

.lv-vacio {
    text-align: center;
    padding: 70px 20px;
    border: 2px dashed #d6dbe4;
    border-radius: 22px;
    color: var(--lv-gris);
}
.lv-vacio h3 { font-family: var(--lv-serif); color: var(--lv-noche); font-size: 1.8rem; }

/* =====================================================================
   3. CRÓNICA DE UN SITIO (estilo periódico)
   ===================================================================== */

.lv-progreso {
    position: fixed;
    top: 85px;
    left: 0;
    height: 3px;
    width: 0;
    background: var(--lv-verde-claro);
    z-index: 9998;
    transition: width .1s linear;
}

.lv-periodico {
    background: var(--lv-papel);
    color: var(--lv-tinta);
    padding: 50px 6% 90px;
}
.lv-hoja { max-width: 1150px; margin: 0 auto; }

/* Cabezote del periódico */
.lv-cabezote {
    text-align: center;
    border-top: 4px solid var(--lv-tinta);
    border-bottom: 1px solid var(--lv-tinta);
    padding: 14px 0 10px;
}
.lv-cabezote strong {
    font-family: var(--lv-serif);
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    font-weight: 800;
    letter-spacing: -.5px;
    display: block;
    line-height: 1;
}
.lv-cabezote-fila {
    display: flex;
    justify-content: space-between;
    border-bottom: 1px solid var(--lv-tinta);
    padding: 6px 0;
    font-size: .78rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: #444;
}

.lv-volver {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin: 24px 0 0;
    color: #444;
    text-decoration: none;
    font-weight: 600;
    font-size: .9rem;
}
.lv-volver:hover { color: var(--lv-verde); }
.lv-volver svg { width: 16px; height: 16px; }

.lv-antetitulo {
    display: inline-block;
    margin-top: 30px;
    font-size: .8rem;
    font-weight: 800;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--lv-verde);
    border-bottom: 2px solid var(--lv-verde);
    padding-bottom: 2px;
}
.lv-titular {
    font-family: var(--lv-serif);
    font-size: clamp(2.3rem, 5.5vw, 4.4rem);
    font-weight: 700;
    line-height: 1.02;
    letter-spacing: -1px;
    margin: 16px 0 18px;
    max-width: 950px;
}
.lv-bajada {
    font-family: var(--lv-texto);
    font-size: 1.35rem;
    line-height: 1.5;
    color: #3d3d3d;
    font-style: italic;
    max-width: 780px;
    margin: 0;
}
.lv-firma {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 20px;
    margin: 24px 0 30px;
    padding: 12px 0;
    border-top: 1px solid var(--lv-linea);
    border-bottom: 1px solid var(--lv-linea);
    font-size: .88rem;
    color: #555;
}
.lv-firma b { color: var(--lv-tinta); }
.lv-compartir {
    margin-left: auto;
    background: none;
    border: 1px solid var(--lv-tinta);
    border-radius: 50px;
    padding: 4px 14px;
    font-weight: 700;
    font-size: .8rem;
    cursor: pointer;
    transition: .25s;
}
.lv-compartir:hover { background: var(--lv-tinta); color: var(--lv-papel); }

.lv-portada-foto { margin: 0 0 40px; }
.lv-portada-foto .lv-foto { height: min(520px, 60vw); border-radius: 4px; }
.lv-portada-foto figcaption {
    font-size: .85rem;
    color: #666;
    padding-top: 8px;
    border-bottom: 1px solid var(--lv-linea);
    padding-bottom: 10px;
}

.lv-cuerpo {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: 60px;
    align-items: start;
}

.lv-texto {
    font-family: var(--lv-texto);
    font-size: 1.18rem;
    line-height: 1.8;
    column-count: 2;
    column-gap: 40px;
    column-rule: 1px solid var(--lv-linea);
}
.lv-texto p { margin: 0 0 1.1em; break-inside: avoid-column; }
.lv-texto > p:first-child::first-letter {    /* letra capital */
    float: left;
    font-family: var(--lv-serif);
    font-size: 4.6em;
    line-height: .8;
    font-weight: 700;
    padding: 6px 10px 0 0;
    color: var(--lv-verde);
}

.lv-cita {
    column-span: all;
    margin: 18px 0 30px;
    padding: 26px 0;
    border-top: 3px solid var(--lv-tinta);
    border-bottom: 1px solid var(--lv-tinta);
    text-align: center;
}
.lv-cita p {
    font-family: var(--lv-serif);
    font-size: clamp(1.5rem, 3vw, 2.1rem);
    line-height: 1.25;
    font-style: italic;
    margin: 0 auto 10px !important;
    max-width: 680px;
}
.lv-cita cite {
    font-family: 'Segoe UI', sans-serif;
    font-size: .85rem;
    font-style: normal;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: #555;
}

/* Columna lateral: ficha + bono */
.lv-lateral { position: sticky; top: 110px; display: flex; flex-direction: column; gap: 26px; }

.lv-ficha {
    border-top: 4px solid var(--lv-tinta);
    padding-top: 14px;
}
.lv-ficha h4 {
    font-size: .8rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: 800;
    margin: 0 0 10px;
}
.lv-ficha dl { margin: 0; }
.lv-ficha div {
    padding: 10px 0;
    border-bottom: 1px solid var(--lv-linea);
}
.lv-ficha dt {
    font-size: .75rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #777;
    font-weight: 700;
}
.lv-ficha dd { margin: 2px 0 0; font-family: var(--lv-texto); font-size: 1.05rem; }

/* El bono: un cupón con borde recortado */
.lv-cupon {
    position: relative;
    background: var(--lv-noche);
    color: #fff;
    border-radius: 18px;
    padding: 26px 24px 24px;
    overflow: hidden;
}
.lv-cupon::before,
.lv-cupon::after {               /* las muescas del cupón */
    content: "";
    position: absolute;
    top: 50%;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: var(--lv-papel);
    transform: translateY(-50%);
}
.lv-cupon::before { left: -11px; }
.lv-cupon::after { right: -11px; }
.lv-cupon small {
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: .72rem;
    font-weight: 700;
    color: var(--lv-verde-claro);
}
.lv-cupon h3 {
    font-family: var(--lv-serif);
    font-size: 1.9rem;
    font-weight: 700;
    line-height: 1.05;
    margin: 6px 0 14px;
}
.lv-cupon p {
    font-size: .88rem;
    color: rgba(255,255,255,.7);
    margin: 0 0 20px;
    padding-top: 14px;
    border-top: 1px dashed rgba(255,255,255,.25);
}
.lv-btn-canjear {
    box-sizing: border-box;
    font-family: 'Segoe UI', sans-serif;
    width: 100%;
    border: none;
    border-radius: 14px;
    padding: 15px;
    font-weight: 800;
    font-size: 1rem;
    background: var(--lv-verde);
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: background .25s, transform .25s, box-shadow .25s;
}
.lv-btn-canjear svg { width: 20px; height: 20px; }
.lv-btn-canjear:hover { background: var(--lv-verde-claro); transform: translateY(-2px); box-shadow: 0 10px 24px rgba(0,210,106,.35); }
.lv-btn-canjear.hecho { background: rgba(255,255,255,.12); cursor: default; transform: none; box-shadow: none; }

.lv-sin-bono {
    border: 1px dashed var(--lv-linea);
    padding: 18px;
    border-radius: 14px;
    font-size: .9rem;
    color: #666;
}

/* Más sitios de la misma categoría */
.lv-mas {
    margin-top: 70px;
    border-top: 4px solid var(--lv-tinta);
    padding-top: 16px;
}
.lv-mas h4 {
    font-size: .8rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: 800;
    margin-bottom: 22px;
}
.lv-mas-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 30px;
}
.lv-mas a { color: inherit; text-decoration: none; display: block; }
.lv-mas .lv-foto { height: 150px; border-radius: 4px; margin-bottom: 12px; }
.lv-mas h5 { font-family: var(--lv-serif); font-size: 1.25rem; font-weight: 600; line-height: 1.2; margin: 0; }
.lv-mas a:hover h5 { color: var(--lv-verde); }
.lv-mas a:hover img { transform: scale(1.05); }

/* Canjear desde la página Lugares: escribir el número o escanear */
.lv-canje-rapido { margin-top: 30px; max-width: 520px; }
.lv-canje-rapido label { display: block; font-size: .85rem; font-weight: 700; color: rgba(255,255,255,.8); margin-bottom: 8px; }
.lv-canje-fila { display: flex; gap: 10px; flex-wrap: wrap; }
.lv-canje-fila input {
    flex: 1 1 200px;
    min-width: 0;
    box-sizing: border-box;
    padding: 14px 18px;
    border-radius: 50px;
    border: 1.5px solid rgba(255,255,255,.25);
    background: rgba(255,255,255,.06);
    color: #fff;
    font-family: 'Courier New', monospace;
    font-size: 1.2rem;
    font-weight: 700;
    letter-spacing: 3px;
    outline: none;
    transition: border-color .2s, background .2s;
}
.lv-canje-fila input::placeholder { color: rgba(255,255,255,.35); }
.lv-canje-fila input:focus { border-color: var(--lv-verde-claro); background: rgba(255,255,255,.1); }
.lv-canje-fila button {
    border: none;
    border-radius: 50px;
    padding: 14px 26px;
    font-weight: 800;
    cursor: pointer;
    background: #fff;
    color: var(--lv-noche);
    transition: background .2s, color .2s;
}
.lv-canje-fila button:hover { background: var(--lv-verde-claro); color: #fff; }
.lv-codigo-aviso { min-height: 1.2em; margin: 8px 0 0 !important; font-size: .88rem !important; color: #ff8a8a !important; }
.lv-canje-o { display: block; margin: 6px 0 10px; color: rgba(255,255,255,.5); font-size: .85rem; }

/* Lector de QR con la cámara (página Lugares) */
.lv-escaner {
    position: absolute; inset: 0; z-index: 5;
    background: #000; border-radius: 24px; overflow: hidden;
    display: flex; flex-direction: column; align-items: center; justify-content: flex-end;
}
.lv-escaner[hidden] { display: none; }
.lv-escaner video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.lv-marco {
    position: absolute; top: 50%; left: 50%;
    width: 62%; aspect-ratio: 1; transform: translate(-50%, -58%);
    border-radius: 22px;
    box-shadow: 0 0 0 9999px rgba(0,0,0,.45);
    border: 3px solid rgba(255,255,255,.9);
    overflow: hidden;
}
.lv-marco i {                     /* línea que baja y sube */
    position: absolute; left: 6%; right: 6%; height: 2px;
    background: var(--lv-verde-claro);
    box-shadow: 0 0 12px var(--lv-verde-claro);
    animation: lv-barrido 1.8s ease-in-out infinite alternate;
}
@keyframes lv-barrido { from { top: 8%; } to { top: 92%; } }
.lv-escaner p { position: relative; color: #fff; font-weight: 600; margin: 0 0 12px; text-shadow: 0 1px 6px rgba(0,0,0,.6); }
.lv-escaner-cancelar {
    position: relative; margin-bottom: 22px;
    background: rgba(255,255,255,.15); color: #fff; border: 1px solid rgba(255,255,255,.4);
    border-radius: 50px; padding: 10px 26px; font-weight: 700; cursor: pointer; backdrop-filter: blur(6px);
}

.lv-escaner-pantalla { position: fixed; border-radius: 0; z-index: 100002; }

.lv-btn-escanear-global {
    margin-top: 0;
    display: inline-flex; align-items: center; gap: 10px;
    padding: 14px 26px; border-radius: 50px; cursor: pointer;
    background: var(--lv-verde); color: #fff; border: none;
    font-weight: 800; font-size: 1rem;
    transition: background .25s, transform .25s;
}
.lv-btn-escanear-global svg { width: 22px; height: 22px; }
.lv-btn-escanear-global:hover { background: var(--lv-verde-claro); transform: translateY(-2px); }

a.lv-btn-canjear { text-decoration: none; }
a.lv-btn-canjear:hover { color: #fff; }
.lv-cupon-estado { font-size: .82rem; color: rgba(255,255,255,.65); text-align: center; margin-top: 10px; }
.lv-cupon-estado:empty { display: none; }

@keyframes lv-sube { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }

/* Mensaje flotante (copiar enlace, etc.) */
.lv-toast {
    position: fixed;
    left: 50%;
    bottom: 30px;
    transform: translate(-50%, 30px);
    background: var(--lv-noche);
    color: #fff;
    padding: 12px 22px;
    border-radius: 50px;
    font-weight: 600;
    opacity: 0;
    transition: .35s;
    z-index: 100001;
    pointer-events: none;
}
.lv-toast.visible { opacity: 1; transform: translate(-50%, 0); }

/* =====================================================================
   CELULAR Y TABLET
   ===================================================================== */

@media (max-width: 991.98px) {
    .lv-categorias { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 210px; }
    .lv-cat:nth-child(n) { grid-column: span 1; grid-row: span 1; }
    .lv-cat:nth-child(1) { grid-column: span 2; grid-row: span 1; }
    .lv-cat:nth-child(1) h2 { font-size: 2.4rem; }

    .lv-cuerpo { grid-template-columns: 1fr; gap: 40px; }
    .lv-lateral { position: static; }
    .lv-texto { column-count: 1; }
}

@media (max-width: 600px) {
    .lv-portada { padding: 60px 6% 50px; }
    .lv-categorias { padding: 40px 5% 70px; gap: 12px; grid-auto-rows: 170px; }
    .lv-cat h2 { font-size: 1.35rem; }
    .lv-cat-texto { left: 16px; right: 16px; bottom: 14px; }
    .lv-flecha { width: 36px; height: 36px; top: 12px; right: 12px; }
    .lv-cat p { display: none; }

    .lv-barra { padding: 12px 5%; }
    .lv-buscar { width: 100%; }
    .lv-listado { padding: 30px 5% 70px; }
    .lv-sitios { grid-template-columns: 1fr; }

    .lv-periodico { padding: 30px 5% 70px; }
    .lv-cabezote-fila span:nth-child(2) { display: none; }
    .lv-bajada { font-size: 1.15rem; }
    .lv-texto { font-size: 1.08rem; }
    .lv-compartir { margin-left: 0; }

}

/* =====================================================================
   4. CANJEAR Y COMPROBANTE
   ===================================================================== */

/* Fondo oscuro con líneas finas tipo billete que giran despacio */
.cj-pagina,
.cp-pagina {
    min-height: 100vh;
    background: #070b14;
    color: #fff;
    position: relative;
    overflow: hidden;
}
.cj-pagina::before,
.cp-pagina::before {
    content: "";
    position: fixed;
    inset: -50%;
    background:
        repeating-radial-gradient(circle at 30% 40%, transparent 0 14px, rgba(0,210,106,.055) 15px 16px),
        repeating-radial-gradient(circle at 70% 60%, transparent 0 18px, rgba(255,255,255,.03) 19px 20px);
    animation: cp-giro 80s linear infinite;
    pointer-events: none;
}
@keyframes cp-giro { to { transform: rotate(360deg); } }

.cj-pagina { min-height: calc(100vh - 85px); }
.cp-pagina { margin: 0; }

/* site.css le quita el padding a <main>, por eso va en el contenedor de adentro */
#lvCanjear,
#lvComprobante {
    position: relative;
    box-sizing: border-box;
    max-width: 462px;
    padding: 40px 16px 60px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* --- Cargando --- */
.cj-cargando {
    margin-top: 25vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    color: rgba(255,255,255,.7);
    font-weight: 600;
}
.cj-cargando span {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 3px solid rgba(255,255,255,.15);
    border-top-color: #00d26a;
    animation: cj-gira .8s linear infinite;
}
@keyframes cj-gira { to { transform: rotate(360deg); } }

/* --- Cajas (login, espera, errores) --- */
.cj-caja {
    box-sizing: border-box;
    width: 100%;
    background: #fff;
    color: #0f172a;
    border-radius: 28px;
    padding: 34px 28px 30px;
    text-align: center;
    box-shadow: 0 30px 80px rgba(0,0,0,.45);
    animation: lv-sube .5s cubic-bezier(.2,.8,.2,1);
}
.cj-caja small {
    display: block;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: .72rem;
    font-weight: 800;
    color: #00b140;
}
.cj-caja h1 {
    font-family: var(--lv-serif);
    font-size: 2rem;
    font-weight: 700;
    line-height: 1.1;
    margin: 8px 0 10px;
}
.cj-caja p { color: #555; line-height: 1.55; margin: 0 0 22px; }
.cj-caja .lv-btn-canjear { margin-top: 4px; }

.cj-logo {
    background: #0f172a;
    border-radius: 18px;
    padding: 14px 22px;
    display: inline-flex;
    margin-bottom: 20px;
}
.cj-logo img { height: 46px; width: auto; display: block; }
.cj-logo strong { color: #fff; font-family: var(--lv-serif); font-size: 1.5rem; }

.cj-botones { display: flex; flex-direction: column; gap: 12px; }
.cj-botones a {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 15px 20px;
    border-radius: 14px;
    font-weight: 700;
    font-size: 1rem;
    text-decoration: none;
    transition: transform .2s, box-shadow .2s;
}
.cj-botones a:hover { transform: translateY(-2px); box-shadow: 0 10px 22px rgba(15,23,42,.15); }
.cj-botones svg { width: 22px; height: 22px; flex-shrink: 0; }
.cj-google { background: #fff; color: #1f1f1f !important; border: 1.5px solid #dadce0; }
.cj-facebook { background: #1877f2; color: #fff !important; border: 1.5px solid #1877f2; }
.cj-nota { font-size: .85rem; color: #888 !important; margin: 18px 0 0 !important; }

/* --- Ya escaneaste: cuenta regresiva --- */
.cj-sello {
    width: 64px;
    height: 64px;
    margin: 0 auto 14px;
    border-radius: 50%;
    background: #e8f8ee;
    color: #00b140;
    display: flex;
    align-items: center;
    justify-content: center;
}
.cj-sello svg { width: 30px; height: 30px; }
.cj-reloj {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    margin: 0 0 10px;
}
.cj-reloj div {
    background: #0f172a;
    color: #fff;
    border-radius: 14px;
    padding: 14px 4px 10px;
}
.cj-reloj b {
    display: block;
    font-size: 2rem;
    font-weight: 800;
    line-height: 1;
    font-variant-numeric: tabular-nums;
}
.cj-reloj span {
    font-size: .7rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #00d26a;
    font-weight: 700;
}
.cj-fecha { font-size: .9rem; font-weight: 600; color: #0f172a !important; }
.cj-otros {
    display: inline-block;
    margin-top: 18px;
    color: #555;
    font-size: .9rem;
    font-weight: 600;
}
.cj-otros:hover { color: #00b140; }

/* --- Aviso arriba del comprobante recién creado --- */
.cp-listo {
    box-sizing: border-box;
    width: 100%;
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(0,210,106,.14);
    border: 1px solid rgba(0,210,106,.4);
    color: #b6f5d2;
    border-radius: 14px;
    padding: 12px 16px;
    font-weight: 600;
    font-size: .92rem;
    margin-bottom: 16px;
    animation: lv-sube .5s ease;
}
.cp-listo svg { width: 20px; height: 20px; color: #00d26a; flex-shrink: 0; }

/* =================== LA TARJETA DEL COMPROBANTE =================== */

.cp-tarjeta {
    --incl: 0;
    position: relative;
    box-sizing: border-box;
    width: 100%;
    background: #fbfcfa;
    color: #0f172a;
    border-radius: 26px;
    overflow: hidden;
    box-shadow: 0 30px 80px rgba(0,0,0,.55), 0 0 0 1px rgba(255,255,255,.1);
    user-select: none;
    -webkit-user-select: none;
    -webkit-touch-callout: none;
    cursor: pointer;
}
.cp-tarjeta.cp-entra { animation: cp-aparece .7s cubic-bezier(.2,.8,.2,1); }
@keyframes cp-aparece {
    from { opacity: 0; transform: translateY(40px) rotateX(18deg) scale(.96); }
    to { opacity: 1; transform: none; }
}

/* Microtexto "CALIVIVA" en diagonal, como en las cédulas.
   Es tan pequeño que a simple vista parece una textura; con zoom se lee. */
.cp-micro {
    position: absolute;
    inset: -60%;
    transform: rotate(-32deg);
    pointer-events: none;
    z-index: 0;
    background-image:
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='74' height='9'%3E%3Ctext x='0' y='6.5' font-family='Arial,Helvetica,sans-serif' font-size='5' font-weight='700' letter-spacing='.55' fill='%230f172a' fill-opacity='.11'%3ECALIVIVA%C2%B7CALIVIVA%C2%B7%3C/text%3E%3C/svg%3E"),
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='74' height='9'%3E%3Ctext x='0' y='6.5' font-family='Arial,Helvetica,sans-serif' font-size='5' font-weight='700' letter-spacing='.55' fill='%2300b140' fill-opacity='.10'%3ECALIVIVA%C2%B7CALIVIVA%C2%B7%3C/text%3E%3C/svg%3E");
    background-size: 74px 9px, 74px 9px;
    background-position: 0 0, 37px 4.5px;
}
.cp-tarjeta > *:not(.cp-micro) { position: relative; z-index: 1; }

/* Encabezado con roseta y logo */
.cp-cabeza {
    background:
        radial-gradient(circle at 85% 30%, rgba(0,210,106,.28), transparent 55%),
        linear-gradient(135deg, #0f172a 0%, #0c2a24 100%);
    color: #fff;
    padding: 20px 22px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    overflow: hidden;
}
.cp-roseta {
    position: absolute;
    right: -40px;
    top: 50%;
    width: 200px;
    height: 200px;
    transform: translateY(-50%);
    animation: cp-giro 40s linear infinite;
    pointer-events: none;
}
.cp-logo { position: relative; display: flex; align-items: center; transition: transform .9s cubic-bezier(.2,.8,.2,1); }
.cp-logo img { height: 50px; width: auto; pointer-events: none; display: block; }
.cp-logo-texto { font-family: var(--lv-serif); font-size: 1.6rem; color: #fff; }
.cp-tipo {
    position: relative;
    font-size: .64rem;
    text-transform: uppercase;
    letter-spacing: 2.4px;
    font-weight: 800;
    color: #7dffb8;
    text-align: right;
    line-height: 1.5;
    max-width: 96px;
}

/* Franja holográfica */
.cp-holograma {
    height: 9px;
    background: linear-gradient(100deg,
        #00b140 0%, #8fffc5 15%, #00d26a 30%, #ffffff 42%, #5ee6ff 55%,
        #00b140 70%, #d9ff8f 85%, #00b140 100%);
    background-size: 300% 100%;
    animation: cp-brillo 3s linear infinite;
    filter: hue-rotate(calc(var(--incl) * 40deg));
}
@keyframes cp-brillo { to { background-position: 300% 0; } }

.cp-cuerpo { padding: 22px 24px 20px; overflow: hidden; }

/* Logo "fantasma" de fondo, como la foto pequeña de la cédula */
.cp-fantasma {
    position: absolute;
    right: -30px;
    bottom: 10px;
    width: 210px;
    opacity: .07;
    filter: grayscale(1);
    pointer-events: none;
    transform: rotate(-12deg);
}
.cp-fantasma img { width: 100%; height: auto; }
.cp-fantasma .cp-logo-texto { color: #0f172a; font-size: 4rem; }

.cp-fila-top { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.cp-fila-top small {
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: .72rem;
    font-weight: 800;
    color: #00a03a;
}
.cp-estado {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    background: #e3f7ea;
    color: #00873a;
    font-weight: 800;
    font-size: .78rem;
    padding: 5px 12px;
    border-radius: 50px;
}
.cp-pulso {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #00b140;
    animation: cp-latido 1.4s ease-out infinite;
}
@keyframes cp-latido {
    0% { box-shadow: 0 0 0 0 rgba(0,177,64,.6); }
    100% { box-shadow: 0 0 0 10px rgba(0,177,64,0); }
}

.cp-cuerpo h1 {
    font-family: var(--lv-serif);
    font-size: 2.3rem;
    font-weight: 700;
    line-height: 1.02;
    letter-spacing: -.5px;
    margin: 8px 0 6px;
}
.cp-condiciones { color: #5b6270; font-size: .86rem; margin: 0 0 18px; }

.cp-usuario {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    background: rgba(15,23,42,.04);
    border: 1px solid rgba(15,23,42,.07);
    border-radius: 16px;
}
.cp-usuario img, .cp-inicial {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #00d26a;
    pointer-events: none;
    flex-shrink: 0;
}
.cp-inicial {
    display: flex;
    align-items: center;
    justify-content: center;
    background: #0f172a;
    color: #fff;
    font-weight: 800;
    font-size: 1.1rem;
}
.cp-usuario small { display: block; font-size: .68rem; color: #8a909b; text-transform: uppercase; letter-spacing: 1.5px; font-weight: 700; }
.cp-usuario b { font-size: 1.05rem; }

.cp-numero { text-align: center; padding-top: 18px; }
.cp-numero small { font-size: .68rem; color: #8a909b; text-transform: uppercase; letter-spacing: 2px; font-weight: 700; }
.cp-numero strong {
    display: block;
    font-family: 'Courier New', monospace;
    font-size: 2.15rem;
    letter-spacing: 4px;
    margin-top: 2px;
    background: linear-gradient(90deg, #0f172a, #0b6b3a, #0f172a);
    background-size: 200% 100%;
    -webkit-background-clip: text;
            background-clip: text;
    color: transparent;
    animation: cp-brillo 6s linear infinite;
}

/* Línea de corte con muescas */
.cp-corte { height: 0; border-top: 2px dashed #d9dde3; margin: 0 16px; }
.cp-corte::before, .cp-corte::after {
    content: "";
    position: absolute;
    top: -13px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #070b14;
}
.cp-corte::before { left: -29px; }
.cp-corte::after { right: -29px; }

.cp-vivo {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 18px 24px 6px;
}
.cp-momento { display: flex; align-items: center; gap: 10px; }
.cp-anillo { width: 44px; height: 44px; transform: rotate(-90deg); flex-shrink: 0; }
.cp-anillo circle { fill: none; stroke-width: 4; }
.cp-anillo circle:first-child { stroke: #e6e9ee; }
.cp-anillo circle:last-child { stroke: #00b140; stroke-linecap: round; transition: stroke-dashoffset 1s linear; }
.cp-momento small, .cp-reloj small { display: block; font-size: .64rem; color: #8a909b; text-transform: uppercase; letter-spacing: 1.2px; font-weight: 700; }
.cp-momento strong { font-family: 'Courier New', monospace; font-size: 1.9rem; letter-spacing: 3px; line-height: 1.05; }
.cp-reloj { text-align: right; }
.cp-reloj strong { font-variant-numeric: tabular-nums; font-size: 1.45rem; font-weight: 800; line-height: 1.1; }

.cp-pie {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 24px 14px;
}
.cp-qr {
    width: 96px;
    height: 96px;
    image-rendering: pixelated;
    pointer-events: none;
    flex-shrink: 0;
    background: #fff;
    border-radius: 10px;
    padding: 4px;
    border: 1px solid #e6e9ee;
}
.cp-qr-caja { margin: 0; text-align: center; flex-shrink: 0; }
.cp-qr-caja figcaption {
    font-family: 'Courier New', monospace;
    font-weight: 700;
    font-size: .78rem;
    letter-spacing: 1.5px;
    margin-top: 4px;
    color: #0f172a;
}
.cp-pie p { font-size: .78rem; color: #5b6270; margin: 0; line-height: 1.45; }

.cp-base {
    display: flex;
    justify-content: space-between;
    background: #0f172a;
    color: rgba(255,255,255,.8);
    font-size: .78rem;
    font-weight: 600;
    padding: 11px 22px;
}
.cp-base span:last-child { color: #00d26a; letter-spacing: 1px; }

.cp-ayuda { position: relative; color: rgba(255,255,255,.55); font-size: .85rem; margin: 16px 0 0; text-align: center; }

/* Al tocar: el logo gira y la tarjeta late */
.cp-tarjeta.toque .cp-logo { transform: rotate(360deg) scale(1.08); }
.cp-tarjeta.toque { animation: cp-toque .5s ease; }
@keyframes cp-toque { 50% { transform: scale(.98); } }

/* Usado o vencido */
.cp-tarjeta[data-estado="usado"] .cp-cuerpo,
.cp-tarjeta[data-estado="usado"] .cp-vivo,
.cp-tarjeta[data-estado="vencido"] .cp-cuerpo,
.cp-tarjeta[data-estado="vencido"] .cp-vivo { filter: grayscale(1); opacity: .55; }
.cp-tarjeta[data-estado="usado"] .cp-holograma,
.cp-tarjeta[data-estado="vencido"] .cp-holograma { animation: none; filter: grayscale(1); }
.cp-tarjeta[data-estado="usado"] .cp-estado { background: #fde8e8; color: #c62828; }
.cp-tarjeta[data-estado="vencido"] .cp-estado { background: #eceff3; color: #555; }
.cp-tarjeta[data-estado="usado"]::after {
    content: "USADO";
    position: absolute;
    top: 40%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(-14deg);
    border: 5px solid #c62828;
    color: #c62828;
    font-weight: 900;
    font-size: 3.4rem;
    letter-spacing: 6px;
    padding: 4px 22px;
    border-radius: 10px;
    z-index: 3;
    opacity: .85;
}

@media (max-width: 380px) {
    .cp-cuerpo h1 { font-size: 1.9rem; }
    .cp-numero strong { font-size: 1.8rem; letter-spacing: 2px; }
    .cp-reloj strong { font-size: 1.2rem; }
    .cp-momento strong { font-size: 1.6rem; }
    .cj-reloj b { font-size: 1.6rem; }
}

/* =====================================================================
   5. VERIFICAR (personal del negocio)
   ===================================================================== */

.vf-pagina { background: #f5f7fb; min-height: calc(100vh - 85px); padding: 50px 6% 80px; }
.vf-centro { max-width: 520px; margin: 0 auto; }
.vf-centro > small { text-transform: uppercase; letter-spacing: 2px; font-size: .75rem; font-weight: 800; color: #00b140; }
.vf-centro h1 { font-family: var(--lv-serif); font-size: 2.6rem; font-weight: 700; margin: 6px 0 8px; }
.vf-centro > p { color: #555; margin-bottom: 24px; }
.vf-buscar { display: flex; gap: 10px; margin-bottom: 26px; }
.vf-buscar input {
    flex: 1; min-width: 0;
    padding: 14px 16px; border: 2px solid #d6dbe4; border-radius: 14px;
    font-family: 'Courier New', monospace; font-size: 1.5rem; font-weight: 700; letter-spacing: 4px; text-align: center;
}
.vf-buscar input:focus { outline: none; border-color: #00b140; }
.vf-buscar button { border: none; border-radius: 14px; background: #0f172a; color: #fff; font-weight: 800; padding: 0 22px; cursor: pointer; }

.vf-caja { background: #fff; border-radius: 20px; padding: 24px; border: 2px solid #e5e9f0; animation: lv-sube .4s ease; }
.vf-caja h2 { font-family: var(--lv-serif); font-size: 1.8rem; margin: 10px 0 2px; }
.vf-caja > p { color: #555; margin: 0 0 14px; }
.vf-etiqueta { display: inline-block; font-weight: 800; font-size: .85rem; padding: 6px 14px; border-radius: 50px; }
.vf-activo { border-color: #00b140; }
.vf-activo .vf-etiqueta { background: #e8f8ee; color: #00873a; }
.vf-usado, .vf-mal { border-color: #e5484d; }
.vf-usado .vf-etiqueta { background: #fde8e8; color: #c62828; }
.vf-vencido .vf-etiqueta { background: #eceff3; color: #555; }
.vf-mal h2 { color: #c62828; margin-top: 0; }
.vf-caja dl { margin: 0 0 18px; }
.vf-caja dl div { display: flex; justify-content: space-between; gap: 12px; padding: 9px 0; border-bottom: 1px solid #edf0f4; }
.vf-caja dt { color: #777; font-weight: 600; }
.vf-caja dd { margin: 0; font-weight: 700; text-align: right; }
.vf-momento { text-align: center; background: #0f172a; color: #fff; border-radius: 16px; padding: 16px; margin-bottom: 16px; }
.vf-momento small { display: block; color: rgba(255,255,255,.65); font-size: .8rem; }
.vf-momento strong { display: block; font-family: 'Courier New', monospace; font-size: 2.6rem; letter-spacing: 8px; color: #00d26a; margin: 4px 0; }
.vf-nota { color: #c62828; margin: 0; }
.cp-pagina #lvComprobante { padding-top: 22px; }
/* =====================================================================
   PLANES PAGOS, CALI VIVA+ Y PIN DEL NEGOCIO
   ===================================================================== */
.lv-insignia {
    position: absolute; top: 12px; right: 12px;
    background: rgba(15, 23, 42, .88); color: #fff;
    font: 700 .72rem/1 system-ui, sans-serif; letter-spacing: .02em;
    padding: 7px 10px; border-radius: 999px; backdrop-filter: blur(4px);
}
.lv-insignia-oro { background: linear-gradient(135deg, #f7c948, #e0a100); color: #2b1d00; }

.lv-cupon-plus {
    display: block; margin: 0 0 14px; padding: 10px 12px; border-radius: 12px;
    background: linear-gradient(135deg, #ecfdf5, #d1fae5); color: #065f46;
    text-decoration: none; font-size: .92rem; border: 1px dashed #059669;
}
.lv-cupon-plus:hover { filter: brightness(.97); color: #064e3b; }

.vf-pin { margin-top: 6px; padding: 16px; border-radius: 14px; background: #f6f8fb; border: 1px solid #e5e9f0; }
.vf-pin p { color: #555; margin: 6px 0 12px; font-size: .95rem; }
.vf-pin small { color: #888; display: block; margin-top: 8px; }
.vf-pin-fila { display: flex; gap: 10px; }
.vf-pin-fila input {
    flex: 1; min-width: 0; font-size: 1.4rem; letter-spacing: .3em; text-align: center;
    border: 2px solid #d5dbe5; border-radius: 12px; padding: 10px;
}
.vf-pin-fila input:focus { outline: none; border-color: var(--lv-verde); }
.vf-pin-fila .lv-btn-canjear { width: auto; margin: 0; padding: 12px 20px; }
.vf-cadena { margin: 16px 0 0; font-size: .85rem; color: #777; }
.vf-cadena a { color: var(--lv-verde); font-weight: 700; }
.vf-salir { border: 0; background: none; color: #777; text-decoration: underline; padding: 0; font: inherit; }

/* Favorito */
.lv-fav { margin-left: 8px; }
.lv-fav.activo { background: #ecfdf5; border-color: #6ee7b7; color: #065f46; }
