/**
 * Hotelequip Custom Cart Styles
 */

.hotelequip-cart-wrapper {
    width: 100%;
    max-width: 100%;
    padding: 20px;
    position: relative;
}

/* Carrinho Vazio */
.hotelequip-cart-empty {
    text-align: center;
    padding: 60px 20px;
    background: #fff;
    border-radius: 10px;
    border: 1px solid #e8e8e8;
}

.empty-cart-icon {
    font-size: 64px;
    color: #d0d0d0;
    margin-bottom: 20px;
}

.hotelequip-cart-empty h2 {
    font-size: 22px;
    color: #131313;
    margin-bottom: 10px;
    font-weight: 600;
}

.hotelequip-cart-empty p {
    color: #666;
    margin-bottom: 30px;
    font-size: 15px;
}

.btn-continue-shopping {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 28px;
    background: #fff;
    color: #131313;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 700;
    font-size: 13px;
    letter-spacing: 0.5px;
    border: 1.5px solid #d0d0d0;
    transition: all 0.2s;
}

.btn-continue-shopping:hover {
    background: #004F6B;
    color: #fff;
    border-color: #004F6B;
}

/* Header */
.cart-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 1px solid #e8e8e8;
}

.cart-header h1 {
    font-size: 24px;
    color: #131313;
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0;
    font-weight: 700;
}

.cart-header h1 i {
    color: #004F6B;
    font-size: 22px;
}

.cart-items-count {
    background: #f5f5f5;
    padding: 6px 14px;
    border-radius: 50px;
    font-size: 13px;
    color: #666;
    font-weight: 500;
}

/* Layout */
.cart-layout {
    display: grid;
    grid-template-columns: 1fr 360px;
    gap: 24px;
    align-items: start;
}

/* Produtos */
.cart-products {
    background: #fff;
    border-radius: 10px;
    border: 1px solid #e8e8e8;
    overflow: hidden;
}

.cart-table-header {
    display: grid;
    grid-template-columns: 3fr 1fr 140px 1fr 44px;
    gap: 12px;
    padding: 12px 20px;
    background: #f8f8f8;
    font-weight: 600;
    font-size: 12px;
    color: #888;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1px solid #e8e8e8;
}

.cart-items-list {
    padding: 0;
}

.cart-item {
    display: grid;
    grid-template-columns: 3fr 1fr 140px 1fr 44px;
    gap: 12px;
    padding: 16px 20px;
    border-bottom: 1px solid #f0f0f0;
    align-items: center;
}

.cart-item:last-child {
    border-bottom: none;
}

/* Coluna Produto */
.col-product {
    display: flex;
    gap: 14px;
    align-items: center;
}

.product-thumbnail {
    width: 72px;
    height: 72px;
    border-radius: 10px;
    overflow: hidden;
    flex-shrink: 0;
    background: #fff;
    border: 1px solid #eee;
}

.product-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 4px;
}

.product-info {
    flex: 1;
    min-width: 0;
}

.product-name {
    font-size: 14px;
    font-weight: 600;
    margin: 0 0 4px;
    line-height: 1.3;
}

.product-name a {
    color: #131313;
    text-decoration: none;
}

.product-name a:hover {
    color: #004F6B;
}

.product-variation {
    font-size: 12px;
    color: #666;
    margin-bottom: 2px;
}

.product-sku {
    font-size: 11px;
    color: #aaa;
}

/* Labels mobile */
.price-label,
.quantity-label,
.total-label {
    display: none;
    font-size: 11px;
    color: #999;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

/* Preço */
.col-price {
    font-size: 14px;
    color: #131313;
    font-weight: 500;
}

/* Quantidade */
.quantity-selector {
    display: inline-flex;
    align-items: center;
    border: 1.5px solid #d0d0d0;
    border-radius: 50px;
    overflow: hidden;
}

.qty-btn {
    width: 32px;
    height: 32px;
    border: none;
    background: transparent;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    color: #666;
    font-size: 11px;
}

.qty-btn:hover {
    background: #004F6B;
    color: #fff;
}

.qty-input {
    width: 40px;
    height: 32px;
    border: none;
    border-left: 1px solid #e8e8e8;
    border-right: 1px solid #e8e8e8;
    text-align: center;
    font-size: 13px;
    font-weight: 600;
    color: #131313;
    -moz-appearance: textfield;
}

.qty-input::-webkit-outer-spin-button,
.qty-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
}

/* Total */
.col-total {
    font-size: 15px;
    font-weight: 700;
    color: #131313;
}

/* Remover */
.btn-remove-item {
    width: 36px;
    height: 36px;
    border: none;
    background: transparent;
    color: #ccc;
    cursor: pointer;
    border-radius: 50%;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-remove-item:hover {
    background: #fef2f2;
    color: #dc2626;
}

/* Ações */
.cart-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-top: 1px solid #e8e8e8;
    background: #fafafa;
}

.btn-clear-cart {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 20px;
    background: transparent;
    border: 1.5px solid #d0d0d0;
    color: #666;
    cursor: pointer;
    border-radius: 50px;
    font-size: 13px;
    font-weight: 600;
    transition: all 0.2s;
}

.btn-clear-cart:hover {
    border-color: #dc2626;
    color: #dc2626;
}

/* Resumo */
.cart-summary {
    position: sticky;
    top: 100px;
}

.summary-box {
    background: #fff;
    border-radius: 10px;
    border: 1px solid #e8e8e8;
    padding: 24px;
}

.summary-box h3 {
    font-size: 17px;
    font-weight: 700;
    color: #131313;
    margin: 0 0 18px;
    padding-bottom: 14px;
    border-bottom: 1px solid #e8e8e8;
}

/* Cupom */
.coupon-section {
    margin-bottom: 18px;
    padding-bottom: 18px;
    border-bottom: 1px solid #f0f0f0;
}

.coupon-input-wrapper {
    display: flex;
    gap: 8px;
}

.coupon-input-wrapper input {
    flex: 1;
    padding: 10px 14px;
    border: 1.5px solid #d0d0d0;
    border-radius: 50px;
    font-size: 13px;
    outline: none;
    transition: border-color 0.2s;
}

.coupon-input-wrapper input:focus {
    border-color: #004F6B;
}

.btn-apply-coupon {
    padding: 10px 18px;
    background: #004F6B;
    color: #fff;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    font-weight: 600;
    font-size: 13px;
    transition: all 0.2s;
    white-space: nowrap;
}

.btn-apply-coupon:hover {
    background: #003a4f;
}

.coupon-message {
    font-size: 13px;
    margin-top: 8px;
    padding-left: 14px;
}

.coupon-message.success {
    color: #16a34a;
}

.coupon-message.error {
    color: #dc2626;
}

.applied-coupons {
    margin-top: 12px;
}

.applied-coupon {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #f0fdf4;
    padding: 8px 12px;
    border-radius: 50px;
    margin-bottom: 6px;
}

.applied-coupon .coupon-code {
    color: #16a34a;
    font-weight: 600;
    font-size: 12px;
}

.applied-coupon .remove-coupon {
    background: transparent;
    border: none;
    color: #dc2626;
    cursor: pointer;
    padding: 2px 6px;
    border-radius: 50%;
    transition: background 0.2s;
}

.applied-coupon .remove-coupon:hover {
    background: #fef2f2;
}

/* Totais */
.summary-totals {
    margin-bottom: 18px;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    font-size: 14px;
    color: #444;
    border-bottom: 1px solid #f5f5f5;
}

.summary-row:last-child {
    border-bottom: none;
}

.summary-row.total {
    font-size: 18px;
    font-weight: 700;
    color: #131313;
    padding-top: 14px;
    margin-top: 4px;
    border-top: 2px solid #131313;
    border-bottom: none;
}

.summary-row.discount .value {
    color: #16a34a;
    font-weight: 600;
}

.shipping-calc {
    font-size: 12px;
    color: #aaa;
    font-style: italic;
}

.shipping-free {
    color: #27ae60;
    font-weight: 600;
}

.shipping-opts {
    display: block;
    font-size: 11px;
    color: #aaa;
    font-style: italic;
}

/* Botão Checkout */
.btn-checkout {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 14px;
    background: #004F6B;
    color: #fff;
    text-decoration: none;
    border-radius: 50px;
    font-size: 15px;
    font-weight: 700;
    letter-spacing: 0.5px;
    transition: all 0.2s;
    margin-bottom: 16px;
}

.btn-checkout:hover {
    background: #003a4f;
    color: #fff;
}

/* Badges de Segurança */
.security-badges {
    display: flex;
    gap: 16px;
    justify-content: center;
    padding-top: 14px;
    border-top: 1px solid #f0f0f0;
}

.cart-related-slot {
    padding: 24px 20px 20px;
    border-top: 1px solid #f3f4f6;
}

.cart-related-slot .produtos-relacionados {
    margin-top: 0 !important;
}

.cart-related-slot .produtos-relacionados h2 {
    font-size: 18px;
    margin-bottom: 14px;
}

.security-badges .badge {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 11px;
    color: #888;
}

.security-badges .badge i {
    color: #16a34a;
    font-size: 13px;
}

/* Loading */
.cart-loading {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255,255,255,0.92);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 100;
    border-radius: 10px;
}

.loading-spinner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    color: #666;
}

.loading-spinner i {
    font-size: 28px;
    color: #004F6B;
}

/* Responsivo */
@media (max-width: 992px) {
    .cart-layout {
        grid-template-columns: 1fr;
    }

    .cart-summary {
        position: static;
    }
}

@media (max-width: 768px) {
    .hotelequip-cart-wrapper {
        padding: 10px;
    }

    .cart-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .cart-header h1 {
        font-size: 18px;
    }

    .cart-header h1 i {
        font-size: 18px;
    }

    .cart-table-header {
        display: none;
    }

    .cart-item {
        grid-template-columns: 1fr;
        gap: 10px;
        padding: 16px;
        position: relative;
    }

    .col-product {
        gap: 12px;
        padding-right: 40px;
    }

    .product-thumbnail {
        width: 72px;
        height: 72px;
    }

    .product-name {
        font-size: 13px;
    }

    .price-label,
    .quantity-label,
    .total-label {
        display: block;
    }

    .col-price,
    .col-quantity,
    .col-total {
        display: flex;
        flex-direction: column;
    }

    .col-remove {
        position: absolute;
        top: 16px;
        right: 16px;
    }

    .cart-actions {
        flex-direction: column;
        gap: 10px;
    }

    .cart-actions .btn-continue-shopping,
    .cart-actions .btn-clear-cart {
        width: 100%;
        justify-content: center;
    }

    .cart-related-slot {
        padding: 20px 16px 16px;
    }

    .cart-related-slot .produtos-relacionados h2 {
        font-size: 16px;
    }

    .summary-box {
        padding: 18px;
    }

    .summary-box h3 {
        font-size: 15px;
    }

    .coupon-input-wrapper {
        flex-direction: column;
    }

    .btn-apply-coupon {
        width: 100%;
        text-align: center;
    }

    .security-badges {
        flex-direction: column;
        align-items: center;
        gap: 8px;
    }

    .btn-checkout {
        font-size: 14px;
        padding: 13px;
    }
}

@media (max-width: 480px) {
    .hotelequip-cart-wrapper {
        padding: 8px;
    }

    .product-thumbnail {
        width: 60px;
        height: 60px;
    }

    .quantity-selector {
        align-self: flex-start;
    }
}

/* Barra de Frete Grátis */
.heq-free-shipping-bar {
    margin-bottom: 18px;
    padding: 14px 16px;
    background: #f0faf4;
    border-radius: 10px;
    border: 1px solid #d1f0e0;
}

.heq-fsb-message {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: #444;
    margin-bottom: 10px;
}

.heq-fsb-message i {
    color: #004F6B;
    font-size: 15px;
}

.heq-fsb-message strong {
    color: #131313;
}

.heq-fsb-achieved {
    color: #16a34a;
}

.heq-fsb-achieved i {
    color: #16a34a;
}

.heq-fsb-track {
    width: 100%;
    height: 8px;
    background: #e5e7eb;
    border-radius: 50px;
    overflow: hidden;
}

.heq-fsb-fill {
    height: 100%;
    background: linear-gradient(90deg, #004F6B, #16a34a);
    border-radius: 50px;
    transition: width 0.5s ease;
}
