/* ====================================================================
   Rumoa Cart v3 — design fixo, prefixo único .rc- (sem conflito com tema)
   ==================================================================== */

/* Ícone trigger (shortcode) — herda cor do menu para contraste automático */
.rc-trigger {
    position: relative;
    background: transparent !important;
    border: 0 !important;
    padding: 8px !important;
    color: inherit !important;
    cursor: pointer !important;
    line-height: 1 !important;
    box-shadow: none !important;
    transition: transform 0.2s ease, opacity 0.2s ease;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
}
.rc-trigger:hover {
    color: inherit !important;
    opacity: 0.75;
    transform: translateY(-1px);
}
.rc-trigger svg {
    width: 28px;
    height: 28px;
    stroke: currentColor;
    display: block;
}
/* Badge: vermelho vibrante — alto contraste em fundo claro E escuro */
.rc-trigger .rc-count {
    position: absolute;
    top: 0;
    right: 0;
    background: #dc2626 !important;
    color: #fff !important;
    font-size: 10.5px !important;
    font-weight: 700 !important;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    border-radius: 999px;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    border: 0;
    box-shadow: 0 0 0 2px rgba(255,255,255,.85), 0 2px 4px rgba(0,0,0,.3);
    line-height: 1 !important;
    font-family: inherit !important;
    box-sizing: border-box;
}
/* O box-shadow duplo cria um "anel" branco semitransparente que destaca o badge em qualquer fundo */

/* Drawer container */
.rc-drawer {
    position: fixed; inset: 0;
    z-index: 999999;
    visibility: hidden; opacity: 0;
    transition: visibility 0.3s, opacity 0.3s;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    color: #1f2937;
}
.rc-drawer.is-open { visibility: visible; opacity: 1; }
.rc-drawer *, .rc-drawer *::before, .rc-drawer *::after { box-sizing: border-box; }

.rc-overlay {
    position: absolute; inset: 0;
    background: rgba(0,0,0,.5);
    backdrop-filter: blur(4px);
}

.rc-panel {
    position: absolute; top: 0; right: -100%;
    width: 100%; max-width: 460px; height: 100%;
    background: #fff;
    display: flex; flex-direction: column;
    transition: right 0.35s cubic-bezier(0.19, 1, 0.22, 1);
    box-shadow: -10px 0 30px rgba(0,0,0,.15);
}
.rc-drawer.is-open .rc-panel { right: 0; }
body.rc-no-scroll { overflow: hidden; }

/* Header */
.rc-header {
    flex: 0 0 auto;
    padding: 20px 24px;
    border-bottom: 1px solid #f3f4f6;
    display: flex; justify-content: space-between; align-items: flex-start;
    background: #fff;
}
.rc-titles { flex: 1; min-width: 0; }
.rc-title {
    margin: 0 !important;
    padding: 0 !important;
    font-size: 20px !important;
    font-weight: 800 !important;
    color: #111827 !important;
    line-height: 1.2 !important;
    font-family: inherit !important;
    text-transform: none !important;
    letter-spacing: 0 !important;
}
.rc-subtitle {
    display: block;
    margin-top: 4px;
    font-size: 13px;
    color: #6b7280;
    font-weight: 400;
}
.rc-close {
    background: transparent !important;
    border: 0 !important;
    cursor: pointer !important;
    color: #9ca3af !important;
    padding: 4px !important;
    display: flex; align-items: center; justify-content: center;
    box-shadow: none !important;
    line-height: 1 !important;
}
.rc-close:hover { color: #111827 !important; }

/* Body (scroll area) */
.rc-body {
    flex: 1;
    overflow-y: auto;
    padding: 20px 24px;
    background: #fff;
    scrollbar-width: thin;
    scrollbar-color: #ddd transparent;
}
.rc-body::-webkit-scrollbar { width: 6px; }
.rc-body::-webkit-scrollbar-thumb { background-color: #ddd; border-radius: 3px; }

/* Items */
.rc-item {
    display: flex; gap: 14px;
    padding-bottom: 18px;
    margin-bottom: 18px;
    border-bottom: 1px solid #f3f4f6;
}
.rc-item:last-child { border-bottom: 0; margin-bottom: 0; padding-bottom: 0; }
.rc-item-image {
    flex-shrink: 0;
    width: 72px; height: 72px;
    background: #f9fafb;
    border-radius: 10px;
    overflow: hidden;
    display: flex; align-items: center; justify-content: center;
}
.rc-item-image img {
    width: 100% !important; height: 100% !important;
    object-fit: cover !important;
    margin: 0 !important;
}
.rc-item-info { flex: 1; min-width: 0; }
.rc-item-name {
    margin: 0 0 2px 0 !important;
    padding: 0 !important;
    font-size: 15px !important;
    font-weight: 700 !important;
    color: #111827 !important;
    line-height: 1.3 !important;
    font-family: inherit !important;
}
.rc-item-name a { color: inherit !important; text-decoration: none !important; }
.rc-item-meta {
    font-size: 12.5px;
    color: #6b7280;
    margin-bottom: 2px;
    line-height: 1.4;
}
.rc-item-destinos {
    font-size: 12.5px;
    color: #6b7280;
    margin-bottom: 8px;
    line-height: 1.4;
}
.rc-item-price {
    font-size: 15px;
    font-weight: 700;
    color: #111827;
    margin-bottom: 10px;
}

/* Controles do item */
.rc-item-controls {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}
.rc-qty {
    display: inline-flex;
    align-items: center;
    background: #f3f4f6;
    border-radius: 999px;
    padding: 3px;
    height: 34px;
}
.rc-qty-btn {
    width: 28px !important; height: 28px !important;
    border: 0 !important;
    background: #fff !important;
    border-radius: 50% !important;
    padding: 0 !important;
    cursor: pointer !important;
    display: flex !important; align-items: center !important; justify-content: center !important;
    color: #111827 !important;
    box-shadow: 0 1px 2px rgba(0,0,0,.06) !important;
    line-height: 1 !important;
}
.rc-qty-btn:hover { background: #f9fafb !important; }
.rc-qty-input {
    width: 32px !important; height: 30px !important;
    border: 0 !important;
    background: transparent !important;
    text-align: center !important;
    font-size: 14px !important;
    font-weight: 700 !important;
    color: #111827 !important;
    padding: 0 !important;
    -moz-appearance: textfield;
    font-family: inherit !important;
}
.rc-qty-input::-webkit-outer-spin-button,
.rc-qty-input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.rc-remove {
    background: transparent !important;
    border: 0 !important;
    cursor: pointer !important;
    color: #9ca3af !important;
    padding: 6px !important;
    border-radius: 6px !important;
    box-shadow: none !important;
    line-height: 1 !important;
}
.rc-remove:hover { color: #ef4444 !important; background: #fef2f2 !important; }

/* Caixa "Envio agendado" verde */
.rc-aviso {
    margin-top: 12px;
    display: flex;
    gap: 10px;
    background: #ecfdf5;
    border: 1px solid #d1fae5;
    border-radius: 10px;
    padding: 10px 12px;
}
.rc-aviso-bar {
    width: 4px;
    background: #2563eb;
    border-radius: 4px;
    flex-shrink: 0;
}
.rc-aviso-body { flex: 1; min-width: 0; }
.rc-aviso-body strong {
    display: block;
    font-size: 13px !important;
    font-weight: 700 !important;
    color: #064e3b !important;
    margin-bottom: 2px;
}
.rc-aviso-body p {
    margin: 0 !important;
    font-size: 12.5px !important;
    color: #065f46 !important;
    line-height: 1.45 !important;
}

/* Estado vazio */
.rc-empty {
    text-align: center;
    padding: 60px 20px;
}
.rc-empty svg { width: 56px; height: 56px; opacity: .4; }
.rc-empty p {
    margin-top: 14px !important;
    font-size: 14px !important;
    color: #6b7280 !important;
}

/* Loading */
.rc-loading {
    text-align: center;
    padding: 40px;
}
.rc-spinner {
    display: inline-block;
    width: 18px; height: 18px;
    border: 2px solid #e5e7eb;
    border-top-color: #2563eb;
    border-radius: 50%;
    animation: rc-spin 0.7s linear infinite;
}
@keyframes rc-spin { to { transform: rotate(360deg); } }

/* Footer */
.rc-footer {
    flex: 0 0 auto;
    padding: 20px 24px;
    background: #f9fafb;
    border-top: 1px solid #f3f4f6;
}
.rc-totals { margin-bottom: 14px; }
.rc-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 14px;
    color: #6b7280;
    padding: 4px 0;
}
.rc-row strong { font-weight: 400 !important; color: inherit !important; }
.rc-row-total {
    border-top: 1px dashed #e5e7eb;
    margin-top: 6px;
    padding-top: 10px;
    font-size: 18px !important;
}
.rc-row-total .rc-label {
    font-weight: 800 !important;
    color: #111827 !important;
}
.rc-row-total .rc-value {
    font-weight: 800 !important;
    color: #111827 !important;
    font-size: 22px !important;
}
.rc-installments {
    margin-top: 8px;
    font-size: 13px;
    color: #111827;
    text-align: center;
    line-height: 1.4;
}
.rc-installments strong { font-weight: 700 !important; color: #111827 !important; }

/* AÇÕES — botões blindados com cores HARDCODED */
html body #rumoa-cart .rc-actions,
.rc-actions {
    display: flex !important;
    flex-direction: column !important;
    gap: 10px !important;
    margin-top: 14px !important;
}
html body #rumoa-cart .rc-btn-primary,
html body #rumoa-cart a.rc-btn-primary {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    width: 100% !important;
    text-align: center !important;
    padding: 16px 14px !important;
    border-radius: 12px !important;
    text-decoration: none !important;
    font-weight: 700 !important;
    font-size: 16px !important;
    line-height: 1.2 !important;
    background: #111827 !important;
    background-color: #111827 !important;
    background-image: none !important;
    color: #ffffff !important;
    border: 0 !important;
    box-shadow: none !important;
    text-shadow: none !important;
    text-transform: none !important;
    letter-spacing: 0 !important;
    font-family: inherit !important;
    cursor: pointer !important;
    transition: background 0.15s ease !important;
    box-sizing: border-box !important;
}
html body #rumoa-cart .rc-btn-primary:hover,
html body #rumoa-cart a.rc-btn-primary:hover,
html body #rumoa-cart .rc-btn-primary:focus,
html body #rumoa-cart .rc-btn-primary:active {
    background: #1f2937 !important;
    background-color: #1f2937 !important;
    color: #ffffff !important;
}
html body #rumoa-cart .rc-btn-secondary,
html body #rumoa-cart a.rc-btn-secondary,
html body #rumoa-cart button.rc-btn-secondary {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    width: 100% !important;
    text-align: center !important;
    padding: 14px !important;
    border-radius: 12px !important;
    text-decoration: none !important;
    font-weight: 600 !important;
    font-size: 14px !important;
    line-height: 1.2 !important;
    background: #ffffff !important;
    background-color: #ffffff !important;
    background-image: none !important;
    color: #111827 !important;
    border: 1.5px solid #e5e7eb !important;
    box-shadow: none !important;
    text-shadow: none !important;
    text-transform: none !important;
    letter-spacing: 0 !important;
    font-family: inherit !important;
    cursor: pointer !important;
    box-sizing: border-box !important;
}
html body #rumoa-cart .rc-btn-secondary:hover,
html body #rumoa-cart .rc-btn-secondary:focus {
    background: #f9fafb !important;
    background-color: #f9fafb !important;
    color: #111827 !important;
    border-color: #9ca3af !important;
}

/* Mobile */
@media (max-width: 480px) {
    .rc-panel { max-width: 100%; }
    .rc-header { padding: 16px 18px; }
    .rc-body, .rc-footer { padding: 16px 18px; }
}

/* v3.6: dólar equivalente sob o total em real */
.rc-total-usd{display:block;font-size:.72em;opacity:.7;font-weight:400;line-height:1.2;}
