/* Estilos para Produtos com Brinde */

/* Card de produto com brinde */
.product-card.has-gift {
    position: relative;
    border: 2px solid #ff6b35;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(255, 107, 53, 0.2);
}

.product-card.has-gift:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(255, 107, 53, 0.3);
}

/* Badge de brinde */
.gift-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: linear-gradient(135deg, #ff6b35, #f7931e);
    color: white;
    padding: 8px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 8px rgba(255, 107, 53, 0.4);
    z-index: 10;
}

.gift-badge::before {
    content: '🎁';
    margin-right: 5px;
    font-size: 1rem;
}

/* Preço sem desconto (produto com brinde) */
.product-card.has-gift .current-price {
    color: #ff6b35 !important;
    font-size: 1.5rem !important;
    font-weight: 700 !important;
}

/* Descrição do brinde */
.gift-description {
    background: linear-gradient(135deg, #fff3e0, #ffe0b2);
    border: 1px solid #ffcc02;
    border-radius: 8px;
    padding: 8px 12px;
    margin: 10px 0;
    text-align: center;
    font-size: 0.9rem;
    color: #e65100;
    font-weight: 500;
}

.gift-description::before {
    content: '✨ ';
    margin-right: 5px;
}

/* Comparação de preços */
.price-comparison {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin: 15px 0;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 8px;
}

.price-option {
    text-align: center;
    padding: 10px;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.price-option.discount {
    background: #d4edda;
    border: 2px solid #28a745;
}

.price-option.gift {
    background: #fff3e0;
    border: 2px solid #ff6b35;
}

.price-option:hover {
    transform: scale(1.05);
}

.price-option .price {
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 5px;
}

.price-option.discount .price {
    color: #28a745;
}

.price-option.gift .price {
    color: #ff6b35;
}

.price-option .label {
    font-size: 0.8rem;
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 0.5px;
}

.price-option.discount .label {
    color: #155724;
}

.price-option.gift .label {
    color: #e65100;
}

/* Botão especial para produtos com brinde */
.btn-gift {
    background: linear-gradient(135deg, #ff6b35, #f7931e);
    border: none;
    color: white;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 12px 24px;
    border-radius: 25px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(255, 107, 53, 0.3);
}

.btn-gift:hover {
    background: linear-gradient(135deg, #f7931e, #ff6b35);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 107, 53, 0.4);
    color: white;
}

.btn-gift::before {
    content: '🎁 ';
    margin-right: 8px;
}

/* Responsividade */
@media (max-width: 768px) {
    .price-comparison {
        flex-direction: column;
        gap: 10px;
    }
    
    .gift-badge {
        font-size: 0.7rem;
        padding: 6px 10px;
    }
    
    .product-card.has-gift .current-price {
        font-size: 1.3rem !important;
    }
}

/* Animação de entrada para produtos com brinde */
@keyframes giftPulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

.product-card.has-gift .gift-badge {
    animation: giftPulse 2s ease-in-out infinite;
}

/* Efeito de brilho para produtos com brinde */
.product-card.has-gift::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    transition: left 0.5s;
}

.product-card.has-gift:hover::after {
    left: 100%;
}

/* Estilos para Modal de Opções de Produto */
.product-option-card {
    border: 2px solid #e9ecef;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 15px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    background: #fff;
}

.product-option-card:hover {
    border-color: #28a745;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.1);
}

.product-option-card.selected {
    border-color: #28a745;
    background: linear-gradient(135deg, #d4edda, #c3e6cb);
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.2);
}

.product-option-card.selected::before {
    content: '✓';
    position: absolute;
    top: 10px;
    right: 15px;
    background: #28a745;
    color: white;
    width: 25px;
    height: 25px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 14px;
}

.option-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
}

.option-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #333;
    margin: 0;
}

.option-badge {
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.option-badge.gift {
    background: linear-gradient(135deg, #ff6b35, #f7931e);
    color: white !important;
}

.option-badge.discount {
    background: linear-gradient(135deg, #dc3545, #c82333);
    color: white;
}

.option-badge.delivery {
    background: linear-gradient(135deg, #007bff, #0056b3);
    color: white;
}

.option-badge.pickup {
    background: linear-gradient(135deg, #6c757d, #495057);
    color: white;
}

.option-price {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.current-price {
    font-size: 1.4rem;
    font-weight: 700;
    color: #28a745;
    margin: 0;
}

.original-price {
    font-size: 1rem;
    color: #6c757d;
    text-decoration: line-through;
    margin: 0;
}

.discount-amount {
    background: #dc3545;
    color: white;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 600;
}

.option-description {
    color: #6c757d; /* Volta cor original para descrições normais */
    font-size: 0.9rem;
    margin: 0;
    font-style: italic;
}

/* Classe específica para descrição de brinde no modal */
.option-description.gift-text {
    color: #ffffff; /* Cor branca apenas para texto de brinde */
}

.option-features {
    display: flex;
    gap: 10px;
    margin-top: 10px;
}

.feature-tag {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 0.8rem;
    color: #495057;
}

.feature-tag.gift {
    background: #ff6b35;
    border-color: #ff6b35;
    color: white !important;
}

.feature-tag.discount {
    background: #f8d7da;
    border-color: #dc3545;
    color: #721c24;
}

/* Responsividade para o modal */
@media (max-width: 768px) {
    .product-option-card {
        padding: 15px;
    }
    
    .option-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .option-price {
        flex-direction: column;
        align-items: flex-start;
        gap: 5px;
    }
    
    .current-price {
        font-size: 1.2rem;
    }
    
    .option-features {
        flex-wrap: wrap;
    }
}

/* Estilos para o novo layout dos cards de opções */
.product-option-card {
    border: 1px solid #dee2e6;
    border-radius: 8px;
    margin-bottom: 1rem;
    transition: all 0.3s ease;
}

.option-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem;
}

.option-left {
    flex: 1;
}

.option-right {
    margin-left: 1rem;
}

.option-badges {
    display: flex;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
    flex-wrap: wrap;
}

.option-badge {
    padding: 6px 12px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-right: 0.5rem;
}

.option-badge.delivery {
    background-color: #007bff;
    color: white;
}

.option-badge.pickup {
    background-color: #6c757d;
    color: white;
}

.option-badge.gift {
    background-color: #ff6b35;
    color: white !important;
}

.option-badge.discount {
    background-color: #dc3545;
    color: white;
}

.option-price {
    margin-bottom: 0.5rem;
}

.option-price .price-label {
    font-size: 0.9rem;
    color: #6c757d;
    margin-right: 0.5rem;
}

.option-price .current-price {
    font-size: 1.25rem;
    font-weight: 700;
    color: #007bff;
}

.option-price .original-price {
    font-size: 0.9rem;
    color: #6c757d;
    text-decoration: line-through;
    margin-left: 0.5rem;
}

.option-price .discount-amount {
    font-size: 0.8rem;
    color: #dc3545;
    font-weight: 600;
    margin-left: 0.5rem;
}

.option-description {
    font-size: 0.85rem;
    color: #6c757d; /* Volta cor original para descrições normais */
    margin: 0;
}

/* Classe específica para descrição de brinde no modal */
.option-description.gift-text {
    color: #ffffff; /* Cor branca apenas para texto de brinde */
}

.add-option-btn {
    min-width: 100px;
    white-space: nowrap;
}

.pickup-btn {
    min-width: 100px;
    white-space: nowrap;
}

/* Espaçamento do modal de opções */
#productOptionsModal .modal-body .row {
    margin-bottom: 1.5rem; /* Adiciona espaçamento após a seção de informações do produto */
}

#productOptionsModal #modal-product-image {
    margin-bottom: 1rem; /* Espaçamento abaixo da imagem */
}

#productOptionsModal #modal-product-name {
    margin-top: 0.5rem; /* Pequeno espaçamento acima do título */
    margin-bottom: 1rem; /* Espaçamento abaixo do título */
}

/* Responsividade para mobile - modal */
@media (max-width: 768px) {
    #productOptionsModal .modal-body .row .col-md-4,
    #productOptionsModal .modal-body .row .col-md-8 {
        margin-bottom: 1rem; /* Espaçamento entre imagem e texto no mobile */
    }
}

/* Responsividade para mobile - cards de opções */
@media (max-width: 768px) {
    .option-content {
        flex-direction: column;
        align-items: stretch;
    }
    
    .option-right {
        margin-left: 0;
        margin-top: 1rem;
    }
    
    .add-option-btn {
        width: 100%;
    }
}

/* Estilos para a tabela de preços */
#prices-table-section {
    background-color: #f8f9fa;
}

#prices-table-section .section-title {
    color: #2c3e50;
    font-weight: 700;
    margin-bottom: 1rem;
}

.filter-btn {
    border-radius: 25px;
    padding: 8px 20px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
}

.filter-btn.active {
    background-color: #007bff;
    border-color: #007bff;
    color: white;
}

.filter-btn:hover:not(.active) {
    background-color: #007bff;
    border-color: #007bff;
    color: white;
    transform: translateY(-2px);
}

#prices-table {
    background-color: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

#prices-table thead th {
    background-color: #2c3e50;
    color: white;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border: none;
    padding: 15px;
}

#prices-table tbody tr {
    transition: all 0.3s ease;
}

#prices-table tbody tr:hover {
    background-color: #f8f9fa;
    transform: scale(1.01);
}

#prices-table tbody td {
    padding: 15px;
    vertical-align: middle;
    border-top: 1px solid #dee2e6;
}

.product-name {
    font-weight: 600;
    color: #2c3e50;
}

.option-name {
    color: #6c757d;
    font-size: 0.9rem;
}

.type-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.type-badge.delivery {
    background-color: #d4edda;
    color: #155724;
}

.type-badge.pickup {
    background-color: #f8d7da;
    color: #721c24;
}

.price-value {
    font-weight: 700;
    font-size: 1.1rem;
    color: #28a745;
}

.price-value.original {
    text-decoration: line-through;
    color: #6c757d;
    font-size: 0.9rem;
    margin-right: 8px;
}

.action-btn {
    padding: 6px 12px;
    font-size: 0.8rem;
    border-radius: 20px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
}

.action-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

/* Responsividade para a tabela */
@media (max-width: 768px) {
    #prices-table {
        font-size: 0.9rem;
    }
    
    #prices-table thead th,
    #prices-table tbody td {
        padding: 10px 8px;
    }
    
    .filter-btn {
        padding: 6px 15px;
        font-size: 0.8rem;
    }
}

/* Estilos para o modo de edição */
.edit-mode .price-value {
    background-color: #fff3cd;
    border: 1px solid #ffeaa7;
    border-radius: 4px;
    padding: 2px 6px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.edit-mode .price-value:hover {
    background-color: #ffeaa7;
    border-color: #fdcb6e;
}

.price-input {
    width: 100%;
    border: 2px solid #007bff;
    border-radius: 4px;
    padding: 4px 8px;
    font-weight: 700;
    font-size: 1.1rem;
    color: #28a745;
    text-align: right;
}

.price-input:focus {
    outline: none;
    border-color: #0056b3;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

.edit-mode .product-name {
    background-color: #e3f2fd;
    border: 1px solid #90caf9;
    border-radius: 4px;
    padding: 2px 6px;
    cursor: pointer;
}

.edit-mode .option-name {
    background-color: #f3e5f5;
    border: 1px solid #ce93d8;
    border-radius: 4px;
    padding: 2px 6px;
    cursor: pointer;
}

.admin-controls {
    background-color: #fff3cd;
    border: 1px solid #ffeaa7;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 20px;
}

.admin-controls h6 {
    color: #856404;
    margin-bottom: 10px;
}

.admin-controls .btn {
    margin-right: 10px;
    margin-bottom: 5px;
}

.changed-price {
    background-color: #d4edda !important;
    border-color: #c3e6cb !important;
    color: #155724 !important;
}

.original-price-display {
    font-size: 0.9rem;
    color: #6c757d;
    text-decoration: line-through;
    margin-right: 8px;
}
