/* =====================================================================
 * cliente-cloud.css — Polish da loja pública
 * Micro-interações, shimmer, FAB chat, timeline, skeleton, empty state.
 * Carregado APÓS cliente.css.
 * ===================================================================== */

/* ─── Hero: brilho deslizante no CTA principal ──────────────────── */
.hero-content .btn-primary {
    position: relative;
    overflow: hidden;
}
.hero-content .btn-primary::after {
    content: "";
    position: absolute;
    top: 0; left: -120%;
    width: 60%; height: 100%;
    background: linear-gradient(120deg,
        transparent 0%,
        rgba(255, 255, 255, 0.35) 50%,
        transparent 100%);
    transform: skewX(-20deg);
    transition: left 720ms ease;
}
.hero-content .btn-primary:hover::after { left: 130%; }

/* ─── Product card: shimmer suave sobre a imagem no hover ───────── */
.product-card .product-image::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(120deg,
        transparent 0%,
        rgba(255, 255, 255, 0.18) 50%,
        transparent 100%);
    transform: translateX(-100%);
    transition: transform 700ms ease;
    pointer-events: none;
    z-index: 1;
}
.product-card:hover .product-image::before { transform: translateX(100%); }

/* ─── Carrinho com itens: highlight no botão cart ───────────────── */
.btn-cart[data-has-items="true"] {
    position: relative;
}
.btn-cart[data-has-items="true"]::before {
    content: "";
    position: absolute;
    inset: -4px;
    border: 2px dashed var(--brand);
    border-radius: var(--r-pill);
    opacity: 0.6;
    animation: ds-spin 8s linear infinite;
    pointer-events: none;
}

/* ─── Pedido: timeline vertical de status ───────────────────────── */
.order-timeline {
    position: relative;
    padding-left: 32px;
    margin: var(--sp-4) 0;
}
.order-timeline::before {
    content: "";
    position: absolute;
    left: 11px; top: 8px; bottom: 8px;
    width: 2px;
    background: var(--border-soft);
    border-radius: 2px;
}
.order-step {
    position: relative;
    padding: 8px 0 14px;
    color: var(--ink-500);
}
.order-step::before {
    content: "";
    position: absolute;
    left: -24px; top: 11px;
    width: 14px; height: 14px;
    border-radius: 50%;
    background: var(--surface);
    border: 2px solid var(--border);
    transition: all var(--t-base);
}
.order-step.done::before {
    background: var(--success);
    border-color: var(--success);
}
.order-step.done::after {
    content: "\f00c";
    font-family: "Font Awesome 6 Free"; font-weight: 900;
    position: absolute;
    left: -22px; top: 11px;
    color: #fff;
    font-size: 8px;
    width: 14px;
    height: 14px;
    display: grid; place-items: center;
}
.order-step.active::before {
    background: var(--brand);
    border-color: var(--brand);
    box-shadow: 0 0 0 4px rgba(var(--brand-rgb), 0.18);
    animation: ds-pulse 1.8s infinite;
}
.order-step strong { color: var(--ink-900); font-size: var(--text-sm); font-weight: 700; }
.order-step.active strong { color: var(--brand-700); }
.order-step.done strong { color: var(--ink-800); }
.order-step span {
    display: block;
    font-size: var(--text-xs);
    color: var(--ink-500);
    margin-top: 2px;
}

/* ─── Empty state genérico ──────────────────────────────────────── */
.empty-state {
    text-align: center;
    padding: var(--sp-10) var(--sp-4);
    border-radius: var(--r-md);
    background: var(--surface);
    border: 1px dashed var(--border);
    margin: var(--sp-5) 0;
}
.empty-state__icon {
    display: inline-grid;
    place-items: center;
    width: 84px; height: 84px;
    margin-bottom: var(--sp-3);
    border-radius: 50%;
    background: var(--brand-soft);
    color: var(--brand-700);
    font-size: 32px;
}
.empty-state h3 {
    font-family: var(--font-display);
    font-size: var(--text-lg);
    font-weight: 800;
    margin: var(--sp-2) 0 4px;
    color: var(--ink-900);
}
.empty-state p {
    color: var(--ink-500);
    font-size: var(--text-sm);
    margin: 0 0 var(--sp-3);
}

/* ─── Chat FAB (botão flutuante para abrir chat de atendimento) ── */
.chat-fab {
    position: fixed;
    bottom: 22px; right: 22px;
    width: 56px; height: 56px;
    border-radius: 50%;
    background: var(--grad-brand);
    color: #fff;
    display: grid; place-items: center;
    font-size: 22px;
    border: 0;
    cursor: pointer;
    box-shadow: var(--shadow-brand);
    z-index: 600;
    transition: transform var(--t-base);
    animation: ds-pulse 3s infinite;
}
.chat-fab:hover { transform: scale(1.06); }

/* ─── Product card variação compact (foto à esquerda) ──────────── */
.product-card.compact {
    flex-direction: row;
}
.product-card.compact .product-image {
    flex: 0 0 110px;
    aspect-ratio: 1;
}
.product-card.compact .product-info {
    padding: 12px 14px;
}
.product-card.compact .product-actions {
    padding: 0 14px 12px;
}

/* ─── Promo strip variation (com gradient quente) ──────────────── */
.promo-strip.warm {
    background: var(--grad-warm);
    color: #fff;
}
.promo-strip.warm .promo-strip-track span i { color: #fff; }

/* ─── Quick filter chips (reuso em listagens) ──────────────────── */
.filter-chips {
    display: flex; gap: 8px; flex-wrap: wrap;
    padding: var(--sp-2) 0;
}
.filter-chip {
    padding: 6px 14px;
    border-radius: var(--r-pill);
    background: var(--surface);
    border: 1px solid var(--border-soft);
    color: var(--ink-700);
    font-size: var(--text-xs);
    font-weight: 700;
    cursor: pointer;
    transition: all var(--t-fast);
    text-decoration: none;
}
.filter-chip:hover { border-color: var(--ink-300); color: var(--ink-900); }
.filter-chip.is-active {
    background: var(--ink-900);
    color: #fff;
    border-color: var(--ink-900);
}

/* ─── Toasts ───────────────────────────────────────────────────── */
#toast-container {
    position: fixed; top: 88px; right: 16px;
    z-index: var(--z-toast);
    display: flex; flex-direction: column; gap: 8px;
    pointer-events: none;
}
.toast {
    background: var(--surface);
    border: 1px solid var(--border-soft);
    border-radius: var(--r-md);
    padding: 12px 18px;
    box-shadow: var(--shadow-3);
    font-size: var(--text-sm);
    font-weight: 600;
    color: var(--ink-900);
    pointer-events: auto;
    animation: ds-pop-in var(--t-spring);
    min-width: 240px;
    max-width: 380px;
    display: flex; align-items: center; gap: 10px;
}
.toast.success { border-left: 4px solid var(--success); }
.toast.error   { border-left: 4px solid var(--danger); }
.toast.warning { border-left: 4px solid var(--warning); }
.toast.info    { border-left: 4px solid var(--info); }

/* ─── Floating WhatsApp button ─────────────────────────────────── */
.fab-whatsapp {
    position: fixed;
    bottom: 22px; right: 22px;
    z-index: 999;
    width: 60px; height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, #25d366 0%, #128c7e 100%);
    color: #fff !important;
    display: grid; place-items: center;
    text-decoration: none;
    font-size: 28px;
    box-shadow: 0 14px 32px -10px rgba(37, 211, 102, 0.65), 0 0 0 6px rgba(37, 211, 102, 0.15);
    transition: transform var(--t-base);
}
.fab-whatsapp:hover { transform: scale(1.08); }
.fab-whatsapp::after {
    content: attr(data-label);
    position: absolute;
    right: calc(100% + 14px);
    top: 50%;
    transform: translateY(-50%);
    background: var(--ink-900);
    color: #fff;
    padding: 6px 14px;
    border-radius: var(--r-pill);
    font-size: var(--text-xs);
    font-weight: 600;
    white-space: nowrap;
    opacity: 0;
    transition: opacity var(--t-base);
    pointer-events: none;
}
.fab-whatsapp:hover::after { opacity: 1; }
@media (max-width: 575.98px) {
    .fab-whatsapp { width: 54px; height: 54px; font-size: 24px; bottom: 80px; }
}

/* ─── Sticky badge "Aberto agora" no header (alternativa visual) ─ */
.header-status {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 4px 10px;
    border-radius: var(--r-pill);
    background: var(--accent-mint-soft);
    color: #0a7752;
    font-size: 11px;
    font-weight: 700;
    margin-left: var(--sp-3);
}
.header-status .dot {
    width: 6px; height: 6px;
    border-radius: 50%;
    background: var(--accent-mint);
    animation: ds-pulse-mint 2s infinite;
}

/* ─── Ajustes finais mobile ─────────────────────────────────────── */
@media (max-width: 480px) {
    .chat-fab { bottom: 80px; }
    .empty-state { padding: var(--sp-7) var(--sp-3); }
}
