/*
 * Arquivo de Estilos para o Order Bump
 * Versão: 1.6.0
 * Design: Engenharia de Design - "Eixo da Intenção"
 */

/* Container Principal e Estado de Carregamento */
.order-bump-pro-container {
    background: #fdfdfd;
    padding: 25px 20px;
    margin-bottom: 25px;
    border-radius: 12px;
    border: 2px dashed #ff0000;
    text-align: center;
    position: relative;
    overflow: hidden; /* Garante que o loader não vaze */
    transition: border-style 0.3s ease, background-color 0.3s ease;
}

.order-bump-pro-container.obp-container-checked {
    border-style: solid;
    background-color: #fff;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

.order-bump-pro-container.obp-loading {
    opacity: 0.7;
    pointer-events: none;
}

/* Esconde o checkbox real */
#obp-checkbox {
    display: none;
}

/* Eixo Vertical de Alinhamento */
.obp-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px; /* Espaçamento Negativo entre os blocos */
}

/* Imagem do Produto */
.obp-product-image img {
    max-width: 80px;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

/* Detalhes e Hierarquia Visual */
.obp-product-details {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.obp-title {
    font-size: 1.4em;
    font-weight: 700;
    color: #111;
    margin: 0;
}

.obp-product-title {
    font-size: 1.1em;
    color: #444;
    margin: 0;
    line-height: 1.4;
}

.obp-price {
    display: flex;
    justify-content: center;
    align-items: baseline;
    gap: 10px;
    font-size: 1.3em;
    font-weight: 600;
    margin-top: 5px;
}

.obp-price del {
    font-size: 0.8em;
    color: #888;
    font-weight: 400;
}

.obp-price ins {
    color: #008a00;
    text-decoration: none;
    font-weight: 700;
}

/* Área de Ação com Call-to-Action */
.obp-action-area {
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    background-color: #f0f0f0;
    padding: 12px 20px;
    border-radius: 50px; /* Pílula moderna */
    transition: background-color 0.3s ease;
    border: 1px solid #e0e0e0;
}

.obp-action-area:hover {
    background-color: #e8e8e8;
}

.obp-action-text {
    font-weight: 600;
    color: #333;
}

/* Falso checkbox visual */
.obp-fake-checkbox {
    flex-shrink: 0;
    width: 22px;
    height: 22px;
    border: 2px solid #ccc;
    background: #fff;
    border-radius: 50%; /* Checkbox redondo e elegante */
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

#obp-checkbox:checked + .obp-fake-checkbox {
    background-color: #28a745;
    border-color: #28a745;
    transform: scale(1.1);
}

#obp-checkbox:checked + .obp-fake-checkbox::after {
    content: '✓';
    color: #fff;
    font-weight: bold;
    font-size: 16px;
    line-height: 1;
}

/* Loader (Spinner de carregamento) */
.obp-loader {
    display: none;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    border: 3px solid rgba(255, 0, 0, 0.2);
    border-top: 3px solid #ff0000;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    animation: spin 1s linear infinite;
}

.order-bump-pro-container.obp-loading .obp-content {
    filter: blur(2px); /* Efeito de desfoque elegante durante o carregamento */
}

.order-bump-pro-container.obp-loading .obp-loader {
    display: block;
}

@keyframes spin {
    0% { transform: translate(-50%, -50%) rotate(0deg); }
    100% { transform: translate(-50%, -50%) rotate(360deg); }
}