/* ============================================================================================
   Buscargo · estilos propios de la app del cliente. Se carga DESPUÉS del theme (swipe.css +
   swipe-app.css): primero ajusta la marca sobre los componentes heredados (cp-*) y luego define
   los componentes propios (bc-*). Claro y oscuro (html.cp-dark).
   ============================================================================================ */
:root {
    --bc-green: #0e4d3a;
    --bc-green-2: #14694f;
    --bc-green-dk: #0a3a2c;
    --bc-orange: #ff5a0a;
    --bc-orange-dk: #e04a00;
    --bc-bg: #f5f8f6;
    --bc-card: #ffffff;
    --bc-tint: #edf4f0;
    --bc-line: #dde8e2;
    --bc-ink: #16261f;
    --bc-ink-2: #62746c;
    --bc-shadow: 0 4px 14px rgba(14, 77, 58, .07);
}
.cp-dark {
    --bc-bg: #06110d;
    --bc-card: #0f231c;
    --bc-tint: #153127;
    --bc-line: #214337;
    --bc-ink: #eef7f3;
    --bc-ink-2: #a3bdb2;
    --bc-shadow: 0 4px 14px rgba(0, 0, 0, .35);
}

/* ---------------------------------------------------------------- marca sobre el theme heredado */
html { background: var(--bc-bg); }
html:not(.cp-dark) body, html:not(.cp-dark) .sidebar, html:not(.cp-dark) .layout { background: var(--bc-bg) !important; }
body { color: var(--bc-ink); }
a { color: var(--bc-orange-dk); }
.cp-dark a { color: #ff9a5c; }

/* Encabezado del Inicio: naranja de marca (claro y oscuro), para que contraste con la tarjeta verde del envío en curso. */
.cp-hd, .cp-dark .cp-hd { background: linear-gradient(165deg, var(--bc-orange) 0%, #e04a00 55%, #c23f00 100%) !important; box-shadow: 0 14px 30px rgba(194, 63, 0, .32) !important; }
/* Logo del encabezado: círculo más grande y el símbolo casi a todo su ancho, para que se distinga bien. */
.cp-logo-badge { width: 56px; height: 56px; overflow: visible; }
.cp-logo-badge img { width: 56px; height: auto; max-width: none; transform: translateX(-6px); margin: 0; }   /* el símbolo llega al borde del círculo */
.cp-bell, .cp-dark .cp-bell { background: rgba(255, 255, 255, .22); color: #fff; border: 0; position: relative; }
.cp-bell-badge { background: var(--bc-green) !important; color: #fff !important; box-shadow: none !important; border: 0 !important; }

/* Inicio con más contenido que la pantalla → vuelve a tener scroll propio. */
#inicio { overflow-y: auto !important; }

/* Barra inferior: verde de marca, botón central naranja. */
.cp-nav.navigation, .cp-dark .cp-nav.navigation { background: var(--bc-green) !important; box-shadow: 0 -4px 18px rgba(14, 77, 58, .22) !important; }
.cp-tabbar a:nth-child(3)::before,
.cp-tabbar a:nth-child(3):not(.active)::before { background: linear-gradient(135deg, #ff8a4d, var(--bc-orange)) !important; box-shadow: 0 6px 16px rgba(255, 90, 10, .38) !important; }
.cp-tabbar a:nth-child(3).active::before,
.cp-dark .cp-tabbar a:nth-child(3).active::before { background: var(--bc-orange-dk) !important; box-shadow: 0 8px 18px rgba(224, 74, 0, .5) !important; }
.cp-tabbar a:nth-child(3).active .cp-hi-fab.cp-hi-sol path,
.cp-dark .cp-tabbar a:nth-child(3).active .cp-hi-fab.cp-hi-sol path { fill: #fff !important; stroke: none !important; }
.cp-tabbar a.active .cp-hi-sol path { stroke: none !important; }
.cp-tabbar a .cp-hi-fab.cp-hi-out path, .cp-dark .cp-tabbar a .cp-hi-fab.cp-hi-out path { stroke: #fff !important; }
/* Aire al final de cada vista: el contenido no queda bajo la curva de la barra ni del botón central. */
.tab-content > .tab-pane { padding-bottom: 34px !important; }
.cp-tabbar a:nth-child(3) .cp-send-wrap { transform: translate(-50%, -50%) translate(0, -20px); filter: none; }   /* sin la sombra verdosa heredada del theme */
.cp-tabbar a:nth-child(3):active .cp-send-wrap { transform: translate(-50%, -50%) translate(0, -20px) scale(.92); }

/* Títulos de vista y Perfil. */
.cp-list-head h1 { color: var(--bc-ink); }
.sidebar .settings .profile h1 a { color: var(--bc-ink); }
.sidebar .settings .profile .bc-avatar {
    width: 84px; height: 84px; border-radius: 50%; margin: 0 auto 12px; padding: 0; display: flex !important; align-items: center; justify-content: center;
    background: linear-gradient(135deg, var(--bc-green-2), var(--bc-green-dk)); color: #fff !important; font-size: 30px; font-weight: 800; letter-spacing: 1px; line-height: 1;
}
html:not(.cp-dark) .sidebar .settings .form-control:disabled { color: var(--bc-ink) !important; -webkit-text-fill-color: var(--bc-ink); background: var(--bc-tint); opacity: 1; }
/* Estadísticas del Perfil: la cantidad es el dato principal (grande y fuerte); la etiqueta la acompaña. */
.sidebar .settings .profile .stats .item h2 { font-size: 17px !important; font-weight: 800 !important; color: var(--bc-ink) !important; margin: 0 0 6px !important; line-height: 1.2 !important; }
.sidebar .settings .profile .stats .item h3 { font-size: 30px !important; font-weight: 800 !important; color: var(--bc-green) !important; margin: 0 !important; line-height: 1.1 !important; }
.cp-dark .sidebar .settings .profile .stats .item h3 { color: #9fe0c6 !important; }
.cp-dark .sidebar .settings .profile .stats { background: var(--bc-card) !important; border: 1px solid var(--bc-line); }
.bc-version { text-align: center; font-size: 12px; color: var(--bc-ink-2); margin: 22px 0 10px; }

/* Hojas inferiores: confirmar en naranja de marca. */
.cp-sheet-confirm { background: var(--bc-orange); }

/* ---------------------------------------------------------------- utilidades */
.bc-ico { width: 20px; height: 20px; flex: 0 0 auto; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.bc-card { background: var(--bc-card); border: 1px solid var(--bc-line); border-radius: 16px; padding: 16px; box-shadow: var(--bc-shadow); }
.bc-lbl { font-size: 12.5px; color: var(--bc-ink-2); font-weight: 600; }
.bc-skel { height: 86px; margin-bottom: 10px; }

/* ---------------------------------------------------------------- botones */
.bc-btn {
    display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; min-height: 52px; padding: 0 18px;
    border: 0; border-radius: 14px; background: var(--bc-orange); color: #fff !important; font-size: 16px; font-weight: 800;
    text-decoration: none !important; cursor: pointer; box-shadow: 0 8px 18px rgba(255, 90, 10, .28);
}
.bc-btn:disabled { opacity: .45; box-shadow: none; }
/* Un solo diseño de botón en toda la app (relleno naranja), en claro y en oscuro. Variantes: la blanca de
   la pantalla de bienvenida (va sobre fondo verde) y la de contorno, para acciones secundarias: "Simular avance"
   (demostración) e "Imprimir" (junto a "Regresar" en el comprobante). */
.bc-btn.outline { background: transparent; color: var(--bc-orange-dk) !important; border: 2px solid var(--bc-orange); box-shadow: none; }
.cp-dark .bc-btn.outline { color: #ff9a5c !important; }
.bc-btn.outline.on { background: rgba(255, 90, 10, .10); }   /* simulación en curso */
/* Cambios de estado suaves en la línea de tiempo (se notan en la simulación). */
.bc-tl .dot { transition: background .3s ease, border-color .3s ease, box-shadow .3s ease; }
.bc-tl li::before { transition: background .3s ease; }
.bc-tl b { transition: color .3s ease; }
.bc-st { transition: background .3s ease, color .3s ease; }
.bc-btn.white { background: #fff; color: var(--bc-green) !important; box-shadow: none; }
.bc-btn.is-loading { color: transparent !important; position: relative; pointer-events: none; }
.bc-btn.is-loading::after {
    content: ''; position: absolute; top: 50%; left: 50%; width: 20px; height: 20px; margin: -10px 0 0 -10px;
    border: 2px solid rgba(255, 255, 255, .45); border-top-color: #fff; border-radius: 50%; animation: cp-spin .6s linear infinite;
}

/* ---------------------------------------------------------------- bienvenida (01) */
body.bc-verde { background: var(--bc-green) !important; padding-bottom: 0 !important; }
.bc-welcome {
    position: fixed; inset: 0; overflow: hidden; display: flex; flex-direction: column; color: #fff;
    padding: calc(28px + env(safe-area-inset-top, 0px)) 26px calc(26px + env(safe-area-inset-bottom, 0px));
    background:
        radial-gradient(120% 60% at 50% -10%, rgba(255, 255, 255, .14), rgba(255, 255, 255, 0) 60%),
        linear-gradient(170deg, #14694f 0%, #0e4d3a 45%, #0a3a2c 100%);
}
.bc-welcome-deco { position: absolute; width: 150%; max-width: none; left: -28%; top: 21%; opacity: .07; pointer-events: none; transform: rotate(-8deg); }
/* Logo en el tercio superior de la pantalla; el resto del espacio queda entre el logo y las acciones. */
.bc-welcome-brand { flex: 0 0 auto; margin-top: 9vh; display: flex; align-items: center; justify-content: center; position: relative; }
.bc-welcome-brand img { width: 100%; max-width: 340px; height: auto; }
.bc-welcome-feats { list-style: none; margin: auto 0 26px; padding: 0; display: flex; justify-content: space-between; gap: 8px; position: relative; }
.bc-welcome-feats li { flex: 1 1 0; display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; font-size: 12px; font-weight: 600; line-height: 1.25; color: rgba(255, 255, 255, .88); }
.bc-welcome-feats svg { width: 22px; height: 22px; fill: none; stroke: #ff8a4d; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.bc-welcome-actions { position: relative; display: flex; flex-direction: column; gap: 12px; width: 100%; max-width: 420px; margin: 0 auto; }
/* La nota queda abajo; el aire sobre ella sube un poco los textos y los botones. */
.bc-welcome-note { margin: 68px 0 0; text-align: center; font-size: 12px; color: rgba(255, 255, 255, .6); }

/* ---------------------------------------------------------------- inicio */
#inicio .bc-hero { padding: 18px 20px 20px; min-height: 148px; cursor: pointer; }
#inicio .bc-hero > * { position: relative; z-index: 1; }
.bc-hero-load { display: flex; flex-direction: column; gap: 12px; }
.bc-hero-load .cp-skeleton { background: rgba(255, 255, 255, .12); height: 22px; border-radius: 8px; }
.bc-hero-load .cp-skeleton:last-child { width: 60%; }
/* Círculo decorativo de la tarjeta: más grande y centrado en el chip del código, que queda dentro con el
   mismo aire a su izquierda (hasta el borde del círculo) que a su derecha (hasta el borde de la tarjeta). */
#inicio .cp-hero.bc-hero::after { width: 210px; height: 210px; right: -65px; top: -74px; }
.bc-hero-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; }
.bc-hero-top > span { padding-top: 5px; }   /* la etiqueta queda a la altura del texto del código */
.bc-hero-cod { display: flex; flex-direction: column; align-items: flex-end; gap: 5px; flex: 0 0 auto; }
/* Con "+N más" bajo el código, la ruta sube un poco para no dejar un hueco a la izquierda. */
.bc-hero-top:has(.bc-hero-mas) + .bc-hero-route { margin-top: 0; }
.bc-hero-mas {
    border: 1px solid rgba(255, 255, 255, .45); background: transparent; color: #fff; border-radius: 20px; padding: 2px 9px;
    font: inherit; font-size: 12px; font-weight: 800; line-height: 1.4; cursor: pointer; white-space: nowrap;
}
.bc-hero-mas:hover, .bc-hero-mas:active { background: rgba(255, 255, 255, .18); }
/* Teléfonos angostos: la fila superior de la tarjeta se compacta para seguir en una sola línea. */
@media (max-width: 379px) {
    #inicio .bc-hero { padding-left: 16px; padding-right: 16px; }
    .bc-hero-top > span { font-size: 11px; letter-spacing: .2px; }
    .bc-hero-top b { font-size: 12px; padding: 3px 8px; }
    .bc-hero-mas { font-size: 11px; padding: 2px 7px; }
    #inicio .cp-hero.bc-hero::after { right: -72px; }
}
.bc-hero-top span { font-size: 12.5px; font-weight: 700; letter-spacing: .4px; text-transform: uppercase; color: rgba(255, 255, 255, .72); }
.bc-hero-top b { font-size: 13px; font-weight: 800; color: #fff; background: rgba(255, 255, 255, .14); padding: 3px 10px; border-radius: 20px; }
.bc-hero-route { display: flex; align-items: center; gap: 10px; margin-top: 10px; font-size: 1.45rem; font-weight: 800; color: #fff; line-height: 1.2; }
.bc-hero-route .bc-ico { width: 22px; height: 22px; color: #ff8a4d; }
.bc-hero-state { margin-top: 6px; font-size: 14px; color: rgba(255, 255, 255, .86); }
.bc-hero-state b { color: #ffb27a; font-weight: 800; }
.bc-steps { display: flex; gap: 5px; margin-top: 14px; }
.bc-steps i { flex: 1 1 0; height: 5px; border-radius: 3px; background: rgba(255, 255, 255, .2); }
.bc-steps i.on { background: #ff8a4d; }
.bc-hero-empty { font-size: 1.2rem; font-weight: 800; color: #fff; margin: 6px 0 4px; }
.bc-hero-empty + p { color: rgba(255, 255, 255, .8); font-size: 14px; margin: 0; }

.bc-quick { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 28px; }
.bc-quick .bc-btn { font-size: 14.5px; padding: 0 8px; }
/* "Ver todos" termina alineado con el CONTENIDO de las tarjetas (17 px adentro: su relleno + borde); el título queda en el borde izquierdo. */
.bc-sec { display: flex; align-items: baseline; justify-content: space-between; margin: 24px 0 10px; padding: 0 17px 0 0; }
.bc-sec h2 { font-size: 17px; font-weight: 800; color: var(--bc-ink); margin: 0; }
.bc-sec a, .cp-dark .bc-sec a { font-size: 14.5px; font-weight: 800; color: var(--bc-ink); }   /* negro en claro, blanco en oscuro */
.bc-feats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 18px 0 20px; }
.bc-feats div { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 12px 6px; border-radius: 14px; background: var(--bc-tint); text-align: center; }
.bc-feats .bc-ico { color: var(--bc-orange); width: 22px; height: 22px; }
.bc-feats span { font-size: 11.5px; font-weight: 700; color: var(--bc-ink); line-height: 1.25; }

/* ---------------------------------------------------------------- tarjeta de envío (listas) */
.bc-list { display: flex; flex-direction: column; gap: 10px; }
.bc-env {
    display: block; width: 100%; text-align: left; background: var(--bc-card); border: 1px solid var(--bc-line); border-radius: 16px;
    padding: 14px 16px; box-shadow: var(--bc-shadow); color: var(--bc-ink); cursor: pointer; font: inherit;
}
.bc-env-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.bc-env-top b { font-size: 14px; font-weight: 800; letter-spacing: .2px; }
.bc-env-route { display: flex; align-items: center; gap: 8px; margin-top: 8px; font-size: 17px; font-weight: 800; }
.bc-env-route .bc-ico { width: 18px; height: 18px; color: var(--bc-orange); }
.bc-env-bot { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 8px; font-size: 13px; color: var(--bc-ink-2); }
.bc-env-bot b { color: var(--bc-ink); font-size: 14.5px; font-weight: 800; }

/* Estado del envío (píldora): 0 confirmado · 1 retirado · 2 en tránsito · 3 en reparto · 4 entregado */
.bc-st { display: inline-block; padding: 3px 10px; border-radius: 20px; font-size: 11.5px; font-weight: 800; white-space: nowrap; line-height: 1.5; }
.bc-st-0 { background: #e6edf7; color: #2c4f86; }
.bc-st-1 { background: #e3f1ec; color: #0e4d3a; }
.bc-st-2 { background: #ffe9dc; color: #c24300; }
.bc-st-3 { background: #fff3cf; color: #8a5a00; }
.bc-st-4 { background: #dcf3e2; color: #1b6e33; }
.cp-dark .bc-st-0 { background: #1d2c44; color: #a9c4f0; }
.cp-dark .bc-st-1 { background: #173a2e; color: #9fe0c6; }
.cp-dark .bc-st-2 { background: #45210d; color: #ffb27a; }
.cp-dark .bc-st-3 { background: #3d2f0a; color: #f5d27a; }
.cp-dark .bc-st-4 { background: #143521; color: #8fe0a6; }

/* Filtros de Mis envíos. */
/* Cuatro filtros en una fila; si la pantalla es angosta, la fila se desliza de lado sin barra visible. */
.bc-chips { display: flex; gap: 6px; margin: 14px 0 16px; overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.bc-chips::-webkit-scrollbar { display: none; }
.bc-chip { flex: 0 0 auto; border: 1px solid var(--bc-line); background: var(--bc-card); color: var(--bc-ink); border-radius: 20px; padding: 7px 12px; font-size: 13.5px; font-weight: 700; cursor: pointer; white-space: nowrap; }
.bc-chip.on { background: var(--bc-green); border-color: var(--bc-green); color: #fff; }
.cp-dark .bc-chip.on { background: var(--bc-orange); border-color: var(--bc-orange); }
.cp-empty { color: var(--bc-ink-2); }
/* Enlace del estado vacío en su propia línea, debajo del texto. */
.bc-empty-link { display: block; margin-top: 6px; font-size: 15px; font-weight: 800; }
.bc-empty-ico { width: 40px; height: 40px; display: block; margin: 0 auto 10px; opacity: .55; }

/* ---------------------------------------------------------------- nuevo envío (02) */
.bc-form { margin-top: 16px; display: flex; flex-direction: column; gap: 14px; }
.bc-field { min-width: 0; }
.bc-field label { display: block; font-size: 12.5px; font-weight: 700; color: var(--bc-ink-2); margin: 0 0 6px; }
.bc-field label em { font-style: normal; font-weight: 500; }
.bc-input, .bc-select select {
    width: 100%; height: 50px; border: 1px solid var(--bc-line); border-radius: 12px; background: var(--bc-card); color: var(--bc-ink);
    font-size: 16px; font-weight: 600; padding: 0 14px; outline: none; -webkit-appearance: none; appearance: none;
}
.bc-input::placeholder { color: #9aa9a2; font-weight: 500; }
.bc-input:focus, .bc-select select:focus { border-color: var(--bc-orange); box-shadow: 0 0 0 3px rgba(255, 90, 10, .18); }
.bc-input.bc-bad { border-color: #dc3545; box-shadow: 0 0 0 3px rgba(220, 53, 69, .15); }
.cp-dark .bc-input, .cp-dark .bc-select select { background: #173229; }
/* Datos del paquete: peso a la izquierda y las tres medidas a la derecha, en una fila. */
.bc-pack { display: grid; grid-template-columns: 92px 1fr; gap: 10px; }
.bc-unit, .bc-dims { display: flex; align-items: center; gap: 6px; }
.bc-unit span, .bc-dims span { font-size: 13px; font-weight: 700; color: var(--bc-ink-2); flex: 0 0 auto; }
.bc-dims i { font-style: normal; color: var(--bc-ink-2); font-weight: 700; flex: 0 0 auto; }
.bc-unit .bc-input, .bc-dims .bc-input { padding: 0 4px; text-align: center; min-width: 0; }
/* Campo con icono al inicio (mismo color y posición que los selectores de ciudad). */
.bc-inico { position: relative; }
.bc-inico .bc-ico { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--bc-orange); pointer-events: none; }
.bc-inico .bc-input { padding-left: 40px; }
.bc-select { position: relative; }
.bc-select .bc-ico { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--bc-orange); pointer-events: none; }
.bc-select select { padding-left: 40px; padding-right: 34px; }
.bc-select::after { content: ''; position: absolute; right: 14px; top: 50%; width: 8px; height: 8px; margin-top: -6px; border-right: 2px solid var(--bc-ink-2); border-bottom: 2px solid var(--bc-ink-2); transform: rotate(45deg); pointer-events: none; }
.bc-route { display: grid; grid-template-columns: 1fr 44px; grid-template-rows: auto auto; gap: 12px 10px; align-items: end; }
.bc-route .bc-field { grid-column: 1; }
.bc-swap { grid-column: 2; grid-row: 1 / span 2; align-self: center; width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--bc-line); background: var(--bc-tint); color: var(--bc-green); display: flex; align-items: center; justify-content: center; margin-top: 18px; }
.cp-dark .bc-swap { color: #9fe0c6; }
.bc-svc { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.bc-svc button {
    display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 12px 8px; border-radius: 14px; cursor: pointer;
    border: 2px solid var(--bc-line); background: var(--bc-card); color: var(--bc-ink); text-align: center; font: inherit;
}
.bc-svc button .bc-ico { width: 24px; height: 24px; color: var(--bc-ink-2); margin-bottom: 2px; }
.bc-svc button b { font-size: 13.5px; font-weight: 800; line-height: 1.2; }
.bc-svc button small { font-size: 11.5px; color: var(--bc-ink-2); }
.bc-svc button.on { border-color: var(--bc-orange); background: #fff4ec; }
.bc-svc button.on .bc-ico, .bc-svc button.on b { color: var(--bc-orange-dk); }
.cp-dark .bc-svc button.on { background: #3a1f10; }
.cp-dark .bc-svc button.on .bc-ico, .cp-dark .bc-svc button.on b { color: #ff9a5c; }
.bc-form-title { font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .5px; color: var(--bc-green-2); margin: 10px 0 -2px; }
.cp-dark .bc-form-title { color: #9fe0c6; }
.bc-quote { display: flex; align-items: center; gap: 12px; margin: 16px 0 12px; padding: 14px 16px; border-radius: 16px; background: var(--bc-tint); border: 1px solid var(--bc-line); }
.bc-quote-ico { flex: 0 0 auto; width: 34px; height: 34px; border-radius: 50%; background: transparent; border: 2px solid var(--bc-green); color: var(--bc-green); display: flex; align-items: center; justify-content: center; }
.cp-dark .bc-quote-ico { border-color: #9fe0c6; color: #9fe0c6; }   /* el verde de marca no se distingue sobre fondo oscuro */
.bc-quote-ico .bc-ico { width: 17px; height: 17px; }
.bc-quote > div { flex: 1 1 auto; min-width: 0; }
.bc-quote > div span { display: block; font-size: 20px; font-weight: 800; color: var(--bc-green); line-height: 1.2; white-space: nowrap; }
/* Teléfonos angostos: el título y el icono se reducen un poco para que todo quepa en una línea. */
@media (max-width: 379px) {
    .bc-quote { gap: 10px; padding: 14px 12px; }
    .bc-quote > div span { font-size: 17px; }
    .bc-quote-ico { width: 30px; height: 30px; }
    .bc-quote-ico .bc-ico { width: 15px; height: 15px; }
}
@media (max-width: 339px) {
    .bc-quote > div span { font-size: 15px; white-space: normal; }   /* en pantallas mínimas puede usar dos líneas antes que encimarse con el monto */
    .bc-quote > b { font-size: 1.35rem; }
}
.bc-quote small { display: block; font-size: 12.5px; color: var(--bc-ink-2); margin-top: 2px; }
.bc-quote small:empty { display: none; }
.bc-quote small.err { color: #dc3545; font-weight: 700; }
.bc-quote > b { flex: 0 0 auto; font-size: 1.6rem; font-weight: 700; color: var(--bc-green); line-height: 1; white-space: nowrap; }
/* Calculando: el monto se oculta (conserva su ancho) y en su lugar gira un indicador verde. */
.bc-quote > b.is-loading { color: transparent !important; position: relative; }
.bc-quote > b.is-loading::after {
    content: ""; position: absolute; top: 50%; right: 4px; width: 24px; height: 24px; margin-top: -12px; box-sizing: border-box;
    border: 3px solid rgba(14, 77, 58, .18); border-top-color: var(--bc-green); border-radius: 50%; animation: cp-spin .7s linear infinite;
}
.cp-dark .bc-quote > b.is-loading::after { border-color: rgba(159, 224, 198, .2); border-top-color: #9fe0c6; }
.cp-dark .bc-quote > div span, .cp-dark .bc-quote > b { color: #9fe0c6; }   /* verde claro sobre fondo oscuro, igual que el icono */
.bc-send-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 24px; }
.bc-btn.outline:disabled { opacity: .45; }

/* Filas etiqueta/valor (resumen de la reserva, detalle del envío). */
.bc-rows { display: flex; flex-direction: column; gap: 14px; }
.bc-row { display: flex; align-items: flex-start; gap: 12px; }
.bc-row > .bc-ico { color: var(--bc-green-2); margin-top: 2px; }
.cp-dark .bc-row > .bc-ico { color: #9fe0c6; }
.bc-row div { min-width: 0; }
.bc-row span { display: block; font-size: 12.5px; color: var(--bc-ink-2); font-weight: 600; }
.bc-row b { display: block; font-size: 15px; font-weight: 800; color: var(--bc-ink); overflow-wrap: anywhere; }
.bc-sum { display: flex; flex-direction: column; gap: 8px; font-size: 14px; }
.bc-sum div { display: flex; justify-content: space-between; gap: 12px; color: var(--bc-ink-2); }
.bc-sum div b { color: var(--bc-ink); font-weight: 700; text-align: right; overflow-wrap: anywhere; }
.bc-sum .tot { border-top: 1px solid var(--bc-line); padding-top: 10px; margin-top: 2px; font-size: 16px; color: var(--bc-ink); font-weight: 800; }
.bc-sum .tot b { font-size: 20px; font-weight: 900; }
.bc-sum-note { font-size: 12px; color: var(--bc-ink-2); text-align: center; margin: 12px 0 0; }

/* ---------------------------------------------------------------- pantalla superpuesta: reserva confirmada (03) */
.bc-screen {
    position: fixed; inset: 0; z-index: 1040; background: var(--bc-bg); display: flex; flex-direction: column;
    transform: translateX(100%); visibility: hidden; transition: transform .28s cubic-bezier(.22, .61, .36, 1), visibility 0s linear .28s;
}
.bc-screen.open { transform: none; visibility: visible; transition: transform .28s cubic-bezier(.22, .61, .36, 1), visibility 0s; }
.bc-screen-bar { flex: 0 0 auto; display: flex; align-items: center; justify-content: center; position: relative; background: var(--bc-green); padding: calc(10px + env(safe-area-inset-top, 0px)) 16px 10px; min-height: calc(56px + env(safe-area-inset-top, 0px)); }
.bc-screen-bar img { height: 30px; width: auto; }
.bc-screen-body { flex: 1 1 auto; overflow-y: auto; -webkit-overflow-scrolling: touch; padding: 16px 16px calc(24px + env(safe-area-inset-bottom, 0px)); display: flex; flex-direction: column; gap: 14px; }
/* Sin barra de desplazamiento visible (como el resto de las vistas), también al usar la app en un computador. */
.bc-screen-body { scrollbar-width: none; }
.bc-screen-body::-webkit-scrollbar { display: none; }
.bc-ok { display: flex; align-items: center; justify-content: center; gap: 8px; background: #dcf3e2; color: #1b6e33; border-radius: 12px; padding: 12px; font-size: 16px; font-weight: 800; }
.cp-dark .bc-ok { background: #143521; color: #8fe0a6; }
.bc-code { font-size: 1.6rem; font-weight: 900; color: var(--bc-ink); letter-spacing: .3px; line-height: 1.2; }
/* Código de barras de la reserva: grande, a todo el ancho de la tarjeta (siempre sobre blanco para que el lector lo lea). */
.bc-codes { margin-top: 12px; background: #fff; border-radius: 12px; padding: 14px 6px 10px; border: 1px solid var(--bc-line); text-align: center; }
.bc-codes img { display: block; width: 100%; height: 58px; }
/* Comprobante compacto: en un teléfono normal cabe entero, con el botón "Ver seguimiento" a la vista. */
#bcReserva .bc-screen-body { gap: 10px; padding-top: 12px; padding-bottom: calc(14px + env(safe-area-inset-bottom, 0px)); }
#bcReserva .bc-ok { padding: 9px 12px; }
#bcReserva .bc-codes { margin-top: 8px; padding: 10px 6px 8px; }
#bcReserva .bc-codes-note { margin-top: 8px; }
#bcReserva .bc-rows { gap: 9px; }
/* Títulos de sección del comprobante, fuera de las tarjetas. */
.bc-res-title { margin: 8px 2px -4px; font-size: 15px; font-weight: 800; color: var(--bc-ink); line-height: 1.2; }
.bc-res-title-1 { margin-top: 14px; }   /* la tarjeta de la orden baja un poco respecto del aviso verde */
#bcReserva .bc-code { text-align: center; }
/* Pantallas de poca altura: barras algo más bajas y sin la nota, para que el botón siga a la vista. */
@media (max-height: 800px) {
    #bcReserva .bc-codes img { height: 46px; }
    #bcReserva .bc-codes-note { display: none; }
    #bcReserva .bc-rows { gap: 8px; }
    .bc-res-title, .bc-res-title-1 { margin-top: 2px; font-size: 14px; }
}
.bc-codes-note { font-size: 12.5px; color: var(--bc-ink-2); margin: 10px 0 0; text-align: center; }

/* ---------------------------------------------------------------- seguimiento (04) */
.bc-track-form { display: flex; gap: 8px; margin: 14px 0 16px; }
.bc-track-form .bc-input { flex: 1 1 auto; min-width: 0; text-transform: uppercase; }
.bc-track-form .bc-input::placeholder { text-transform: none; }
.bc-track-form .bc-btn { flex: 0 0 52px; width: 52px; padding: 0; }
.bc-track { display: flex; flex-direction: column; gap: 14px; padding-bottom: 24px; }
.bc-track-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.bc-track-head .bc-code { font-size: 1.35rem; }
.bc-track-head p { margin: 4px 0 0; font-size: 15px; font-weight: 700; color: var(--bc-ink-2); display: flex; align-items: center; gap: 6px; }
.bc-track-head p .bc-ico { width: 16px; height: 16px; color: var(--bc-orange); }

.bc-tl { list-style: none; margin: 0; padding: 0; }
.bc-tl li { position: relative; padding: 0 0 20px 40px; min-height: 44px; }
.bc-tl li:last-child { padding-bottom: 0; min-height: 26px; }
.bc-tl li::before { content: ''; position: absolute; left: 12px; top: 26px; bottom: 0; width: 2px; background: var(--bc-line); }
.bc-tl li:last-child::before { display: none; }
.bc-tl li.done::before { background: var(--bc-green-2); }
.bc-tl .dot { position: absolute; left: 0; top: 0; width: 26px; height: 26px; border-radius: 50%; border: 2px solid var(--bc-line); background: var(--bc-card); display: flex; align-items: center; justify-content: center; color: #fff; }
.bc-tl .dot .bc-ico { width: 14px; height: 14px; stroke-width: 3; }
.bc-tl li.done .dot { background: var(--bc-green-2); border-color: var(--bc-green-2); }
.bc-tl li.now .dot { background: var(--bc-orange); border-color: var(--bc-orange); box-shadow: 0 0 0 5px rgba(255, 90, 10, .2); }
.bc-tl b { display: block; font-size: 15px; font-weight: 800; color: var(--bc-ink); line-height: 1.3; }
.bc-tl span { display: block; font-size: 13px; color: var(--bc-ink-2); }
.bc-tl li.todo b { color: var(--bc-ink-2); font-weight: 700; }
.bc-tl li.now b { color: var(--bc-orange-dk); }
.cp-dark .bc-tl li.now b { color: #ff9a5c; }

.bc-map { position: relative; border-radius: 14px; overflow: hidden; background: #e8f0ec; border: 1px solid var(--bc-line); }
.cp-dark .bc-map { background: #102820; }
.bc-map svg { display: block; width: 100%; height: auto; }
.bc-map .grid { stroke: #d3e0da; stroke-width: 1; }
.cp-dark .bc-map .grid { stroke: #1b3a30; }
.bc-map .rest { fill: none; stroke: #b6c8c0; stroke-width: 3; stroke-dasharray: 2 7; stroke-linecap: round; }
.bc-map .gone { fill: none; stroke: var(--bc-orange); stroke-width: 3.5; stroke-linecap: round; }
.bc-map text { font-family: 'Nunito', system-ui, sans-serif; font-size: 12px; font-weight: 800; fill: #16261f; }
.cp-dark .bc-map text { fill: #eef7f3; }
.bc-track-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.bc-track-actions .bc-btn { font-size: 14px; padding: 0 8px; min-height: 48px; }

/* Novedades (hoja de la campana). */
.bc-news { display: flex; flex-direction: column; gap: 2px; text-align: left; margin: 0 -8px; }
.bc-new {
    display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; min-height: 62px; padding: 10px 12px;
    background: transparent; border: 0; border-radius: 14px; color: var(--bc-ink); font: inherit; text-align: left; cursor: pointer;
    transition: background .15s ease;
}
.bc-new:hover, .bc-new:focus-visible { background: var(--bc-tint); outline: none; }
.bc-new:active { transform: scale(.985); }
.cp-dark .bc-new:hover, .cp-dark .bc-new:focus-visible { background: #1d4034; }
/* El estado va como texto del color de su etiqueta, sin la píldora de fondo. */
.bc-new .bc-st, .cp-dark .bc-new .bc-st { background: transparent; padding: 0; border-radius: 0; font-size: 13.5px; line-height: 1.2; }
.bc-new-l, .bc-new-r { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.bc-new-r { flex: 0 0 auto; align-items: flex-end; }
.bc-new b { font-size: 15px; font-weight: 800; line-height: 1.2; }
.bc-new small { font-size: 12.5px; color: var(--bc-ink-2); line-height: 1.2; white-space: nowrap; }

/* ---------------------------------------------------------------- pantallas anchas (tablet / escritorio)
   La app es móvil: en pantallas anchas se muestra como una columna centrada del ancho de un teléfono. */
@media (min-width: 992px) {
    html { background: #dfe7e3; }
    .cp-dark { background: #030806 !important; }
    body:not(.bc-verde) { max-width: 460px; margin: 0 auto !important; min-height: 100vh; position: relative; box-shadow: 0 0 40px rgba(14, 77, 58, .15); padding-bottom: 62px !important; }
    .layout { display: block !important; height: auto !important; }
    .sidebar { width: 100% !important; max-width: none !important; min-width: 0 !important; height: auto !important; position: static !important; padding: 0 !important; border: 0 !important; }
    .cp-nav.navigation { position: fixed !important; left: 50% !important; right: auto !important; top: auto !important; bottom: 0 !important; width: 460px !important; height: auto !important; transform: translateX(-50%); z-index: 1030; padding: 0 !important; }
    .cp-nav.navigation { max-width: 460px !important; min-width: 0 !important; }
    .cp-nav .inside { height: auto !important; }
    .cp-nav .menu { flex-direction: row !important; height: auto !important; }
    .sidebar .settings .categories .category:last-of-type { display: block !important; }   /* el theme oculta "Cerrar sesión" en escritorio */
    .tab-content > .tab-pane { height: calc(100vh - 62px) !important; overflow-y: auto; overflow-x: hidden; scrollbar-width: none; }
    .tab-content > .tab-pane::-webkit-scrollbar { display: none; }
    .bc-screen { left: 50%; right: auto; width: 460px; margin-left: -230px; }
    .bc-screen:not(.open) { transform: translateX(60px); opacity: 0; }
    .bc-welcome { left: 50%; right: auto; width: 460px; margin-left: -230px; }
    .cp-sheet-modal .modal-dialog { left: 50%; right: auto; width: 460px; margin-left: -230px; }
}

/* ---------------------------------------------------------------- medios de pago (hoja previa a la reserva) */
.cp-sheet-sub b { color: var(--bc-ink); font-weight: 800; }
.bc-payopts { display: flex; flex-direction: column; gap: 4px; margin: 14px -8px 0; }
.bc-payopt {
    display: flex; align-items: center; gap: 12px; width: 100%; padding: 10px 12px; text-align: left; cursor: pointer; font: inherit;
    background: transparent; border: 0; border-radius: 14px; color: var(--bc-ink); transition: background .15s ease;
}
/* Sin tarjeta alrededor; se resaltan al pasar el mouse o al enfocarlos, igual que las novedades. */
.bc-payopt:hover, .bc-payopt:focus-visible { background: var(--bc-tint); outline: none; }
.cp-dark .bc-payopt:hover, .cp-dark .bc-payopt:focus-visible { background: #1d4034; }
.bc-paylogo { flex: 0 0 96px; height: 48px; border-radius: 10px; background: #fff; border: 1px solid #e6ece9; display: flex; align-items: center; justify-content: center; padding: 5px 8px; }
.bc-paylogo img { max-width: 100%; max-height: 100%; display: block; }
.bc-payname { flex: 1 1 auto; min-width: 0; }
.bc-payname b { display: block; font-size: 15px; font-weight: 800; line-height: 1.25; }
.bc-payname small { display: block; font-size: 12.5px; color: var(--bc-ink-2); }
.bc-payopt > .bc-ico { color: var(--bc-ink-2); }

#bcPago .cp-sheet { display: flex; flex-direction: column; }
#bcPago .cp-sheet-handle { flex: 0 0 auto; }
.bc-pay-state { flex: 1 1 auto; display: flex; flex-direction: column; align-items: center; justify-content: flex-start; text-align: center; padding: 44px 0 0; }
.bc-pay-state.cp-hide { display: none !important; }
.bc-pay-state .cp-sheet-actions { width: 100%; margin-top: auto; padding-top: 18px; }
/* Cotización: mismo documento que el comprobante, con el aviso en azul para que no se lea como "pagado". */
.bc-ok.cot { background: #e6edf7; color: #2c4f86; }
.cp-dark .bc-ok.cot { background: #1d2c44; color: #a9c4f0; }
.bc-pay-state .cp-sheet-sub { margin: 4px auto 0; max-width: 300px; line-height: 1.45; }
.bc-pay-spin { display: block; width: 54px; height: 54px; margin: 6px auto 16px; border-radius: 50%; border: 4px solid var(--bc-line); border-top-color: var(--bc-orange); animation: cp-spin .8s linear infinite; }
.bc-pay-ico { display: flex; align-items: center; justify-content: center; width: 64px; height: 64px; margin: 2px auto 14px; border-radius: 50%; color: #fff; }
.bc-pay-ico .bc-ico { width: 32px; height: 32px; stroke-width: 2.6; }
.bc-pay-ico.ok { background: #28a745; }
.bc-pay-ico.rechazado { background: #dc3545; }
.bc-pay-ico.pendiente { background: #e6951a; }


/* ---------------------------------------------------------------- comprobante: acciones e impresión */
.bc-res-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.bc-print-logo { display: none; }

/* Hoja impresa: solo el comprobante, en blanco y negro donde importa (código de barras) y sin la app alrededor. */
@media print {
    @page { margin: 14mm; }
    html, body { background: #fff !important; height: auto !important; overflow: visible !important; padding: 0 !important; margin: 0 !important; max-width: none !important; box-shadow: none !important; }
    body > main > .layout, .modal, .modal-backdrop, #cpToasts { display: none !important; }
    .bc-screen { position: static !important; transform: none !important; visibility: visible !important; opacity: 1 !important; width: auto !important; margin: 0 !important; background: #fff !important; display: block !important; }
    .bc-screen:not(.open) { display: none !important; }
    .bc-screen-bar, .bc-res-actions { display: none !important; }
    .bc-screen-body { overflow: visible !important; padding: 0 !important; display: block !important; max-width: 150mm; margin: 0 auto; }
    .bc-print-logo { display: block; width: 62mm; height: auto; margin: 0 auto 8mm; }
    .bc-screen .bc-card { box-shadow: none !important; border: 1px solid #b9c4bf !important; background: #fff !important; margin: 0 0 6mm !important; break-inside: avoid; }
    .bc-ok { border: 1px solid #1b6e33; background: #fff !important; color: #1b6e33 !important; margin-bottom: 6mm; }
    .bc-screen, .bc-screen * { color: #111 !important; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
    .bc-ok, .bc-ok * { color: #1b6e33 !important; }
    .bc-ok.cot { border-color: #2c4f86; }
    .bc-ok.cot, .bc-ok.cot * { color: #2c4f86 !important; }
    .bc-row > .bc-ico { color: #0e4d3a !important; }
    #bcReserva .bc-codes { border: 0 !important; padding: 4mm 0 !important; }
    #bcReserva .bc-codes img { height: 22mm !important; max-width: 110mm; margin: 0 auto; }
    #bcReserva .bc-codes-note { display: block !important; }
    .bc-res-title { margin: 0 0 2mm !important; font-size: 11pt; }
    #bcReserva .bc-rows { gap: 4mm !important; }
}
