/* ============================================
   CARRINHO PAGE - TEMA DARK (ESTILO CHECKOUT)
   TechCraftBrasil - Minecraft Server Store
   ============================================ */

.cart-page-grid {
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 2rem;
}

.cart-page-heading {
    margin-bottom: 2rem;
}

.cart-page-heading h1 {
    font-size: 1.875rem;
    margin-bottom: 0.5rem;
    color: #e8eaed;
}

.cart-page-heading p {
    color: #9aa0a6;
    font-size: 0.875rem;
}

/* Lista de itens */
.cart-items-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.cart-product-card {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    background: linear-gradient(135deg, #1a1d24 0%, #111318 100%);
    border: 1px solid #1f2329;
    border-radius: 20px;
    padding: 1.25rem;
    transition: all 0.3s ease;
}

.cart-product-card:hover {
    border-color: #00e676;
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(0, 230, 118, 0.1);
}

.cart-product-card__media {
    width: 100px;
    height: 100px;
    flex-shrink: 0;
    border-radius: 12px;
    overflow: hidden;
    background: #0d0f15;
}

.cart-product-card__media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cart-product-card__body {
    flex: 1;
}

.cart-product-card__label {
    font-size: 0.75rem;
    text-transform: uppercase;
    color: #9aa0a6;
    letter-spacing: 0.05em;
    display: block;
    margin-bottom: 0.25rem;
}

.cart-product-card__body h3 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #e8eaed;
}

.cart-product-card__meta {
    display: flex;
    gap: 1.5rem;
}

.cart-product-card__meta span {
    display: flex;
    flex-direction: column;
}

.cart-product-card__meta small {
    font-size: 0.6875rem;
    color: #9aa0a6;
}

.cart-product-card__meta strong {
    font-size: 1rem;
    color: #e8eaed;
}

/* Controles de quantidade */
.cart-product-card__controls {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.cart-quantity-control {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    background: #0d0f15;
    border-radius: 40px;
    padding: 0.25rem;
    border: 1px solid #2a2e35;
}

.cart-quantity-control button {
    width: 32px;
    height: 32px;
    border-radius: 40px;
    background: #1a1d24;
    border: none;
    color: #e8eaed;
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: 600;
}

.cart-quantity-control button:hover {
    background: #00e676;
    color: #1a1d24;
    transform: scale(0.95);
}

.cart-quantity-control input {
    width: 50px;
    text-align: center;
    background: transparent;
    border: none;
    color: #e8eaed;
    font-weight: 600;
    font-size: 0.875rem;
}

.cart-quantity-control input:focus {
    outline: none;
}

.cart-remove-button {
    color: #ef5350;
    font-size: 1.125rem;
    transition: all 0.2s ease;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 8px;
    border-radius: 40px;
}

.cart-remove-button:hover {
    color: #ff6b6b;
    transform: scale(1.1);
    background: rgba(239, 83, 80, 0.1);
}

/* Botão limpar carrinho */
.cart-clear {
    margin-top: 1.5rem;
    text-align: right;
}

.cart-clear a {
    color: #ef5350;
    font-size: 0.875rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.2s ease;
    text-decoration: none;
}

.cart-clear a:hover {
    color: #ff6b6b;
    gap: 0.75rem;
}

/* Painel de resumo - ESTILO CHECKOUT */
.cart-summary-panel {
    position: sticky;
    top: 100px;
    height: fit-content;
    background: linear-gradient(135deg, #1a1d24 0%, #111318 100%);
    border: 1px solid #1f2329;
    border-radius: 20px;
    overflow: hidden;
}

.cart-summary-panel__header {
    padding: 1.5rem 1.5rem 0 1.5rem;
    margin-bottom: 0;
}

.cart-summary-panel__header h2 {
    font-size: 1.5rem;
    margin-bottom: 0;
    color: #e8eaed;
}

.cart-summary-block {
    padding: 0 1.5rem 1.5rem 1.5rem;
    margin-bottom: 0;
    border-bottom: 1px solid #1f2329;
}

/* Cupom de desconto */
.coupon-field--error .coupon-ticket-header {
    color: #ef5350;
}

.coupon-field--success .coupon-ticket-header {
    color: #00e676;
}

.coupon-ticket-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.coupon-ticket-title {
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #e8eaed;
}

.coupon-ticket-status {
    font-size: 0.75rem;
    padding: 0.25rem 0.75rem;
    background: #0d0f15;
    border-radius: 20px;
    color: #9aa0a6;
}

.coupon-input-wrap {
    position: relative;
}

.coupon-input {
    width: 100%;
    padding: 0.875rem 45px 0.875rem 1rem;
    background: #0d0f15;
    border: 1.5px solid #2a2e35;
    border-radius: 12px;
    color: #e8eaed;
    font-size: 0.875rem;
    transition: all 0.2s ease;
}

.coupon-input:focus {
    outline: none;
    border-color: #00e676;
    box-shadow: 0 0 0 2px rgba(0, 230, 118, 0.2);
}

.coupon-input--error {
    border-color: #ef5350;
}

.coupon-input--success {
    border-color: #00e676;
}

.coupon-input-action {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #00e676;
    background: transparent;
    border: none;
    cursor: pointer;
    font-size: 1.125rem;
    transition: all 0.2s ease;
}

.coupon-input-action:hover {
    transform: translateY(-50%) scale(1.1);
    color: #69f0ae;
}

.coupon-message {
    display: block;
    font-size: 0.75rem;
    margin-top: 0.5rem;
}

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

.coupon-message--success {
    color: #00e676;
}

.coupon-discount-value {
    display: inline-block;
    margin-top: 0.5rem;
    font-size: 0.875rem;
    color: #00e676;
    font-weight: 600;
}

/* Gift Checkbox Estilizado */
.cart-summary-gift {
    padding: 1.5rem;
    border-bottom: 1px solid #1f2329;
}

.cart-summary-gift label {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin: 0;
    padding: 1rem;
    border: 1.5px solid #2a2e35;
    border-radius: 16px;
    background: #0d0f15;
    color: #e8eaed;
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.cart-summary-gift label:hover {
    border-color: #00e676;
}

.cart-summary-gift input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: #00e676;
    cursor: pointer;
}

.cart-summary-gift input[type="checkbox"]:checked + label {
    border-color: #00e676;
    background: rgba(0, 230, 118, 0.1);
}

.cart-summary-gift .info {
    margin-top: 0.75rem;
    color: #9aa0a6 !important;
    font-size: 0.75rem;
    line-height: 1.4;
}

.cart-summary-gift .info span {
    color: #9aa0a6 !important;
}

.cart-summary-gift p {
    margin: 0.5rem 0 0;
    font-size: 0.75rem;
    line-height: 1.5;
    color: #9aa0a6;
}

/* Totais - ESTILO CHECKOUT */
.cart-summary-totals {
    padding: 1.5rem;
}

.cart-summary-total-line {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
}

.cart-summary-total-line span:first-child {
    color: #9aa0a6;
    font-size: 0.875rem;
}

.cart-summary-total-line span:last-child {
    color: #e8eaed;
    font-weight: 600;
    font-size: 0.9375rem;
}

.cart-summary-total-line--discount {
    color: #00e676;
}

.cart-summary-total-line--discount span:last-child {
    color: #00e676;
    font-weight: 800;
}

.cart-summary-total-line--grand {
    font-size: 1.25rem;
    font-weight: 700;
    border-top: 1px solid #1f2329;
    margin-top: 0.5rem;
    padding-top: 1rem;
}

.cart-summary-total-line--grand span:first-child {
    font-size: 1rem;
    font-weight: 600;
}

.cart-summary-total-line--grand span:last-child {
    font-size: 1.5rem;
    font-weight: 900;
    color: #00e676;
    text-shadow: 0 0 6px rgba(0, 230, 118, 0.4);
    letter-spacing: -0.5px;
}

/* Botão checkout */
.checkout-action {
    padding: 0 1.5rem 1.5rem 1.5rem;
}

.checkout-action .fag-btn {
    width: 100%;
    justify-content: center;
    padding: 0.875rem 1.5rem;
    background: linear-gradient(135deg, #00e676, #00c853);
    color: #1a1d24;
    border: none;
    border-radius: 12px;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    box-shadow: 0 2px 8px rgba(0, 230, 118, 0.3);
}

.checkout-action .fag-btn:hover {
    background: linear-gradient(135deg, #00c853, #00b248);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 230, 118, 0.4);
}

/* Estado vazio */
.cart-empty-state {
    text-align: center;
    padding: 3rem;
    background: linear-gradient(135deg, #1a1d24 0%, #111318 100%);
    border: 1px solid #1f2329;
    border-radius: 20px;
}

.cart-empty-state i {
    font-size: 4rem;
    color: #3c4043;
    margin-bottom: 1rem;
}

.cart-empty-state h3 {
    margin-bottom: 0.5rem;
    color: #e8eaed;
}

.cart-empty-state p {
    color: #9aa0a6;
    margin-bottom: 1.5rem;
}

.cart-empty-state .fag-btn {
    background: linear-gradient(135deg, #00e676, #00c853);
    color: #1a1d24;
    padding: 0.75rem 1.5rem;
    border-radius: 12px;
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.2s ease;
}

.cart-empty-state .fag-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 230, 118, 0.3);
}

/* Recomendações */
.cart-recommendations {
    background: transparent;
    margin-top: 3rem;
}

.cart-recommendations h3 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    color: #e8eaed;
}

.cart-recommendation-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-top: 0;
}

.cart-recommendation-card {
    display: flex;
    flex-direction: column;
    background: linear-gradient(135deg, #1a1d24 0%, #111318 100%);
    border: 1px solid #1f2329;
    border-radius: 16px;
    padding: 1rem;
    transition: all 0.3s ease;
}

.cart-recommendation-card:hover {
    border-color: #00e676;
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 230, 118, 0.1);
}

.cart-recommendation-card__media {
    margin-bottom: 1rem;
    border-radius: 12px;
    overflow: hidden;
}

.cart-recommendation-card__media img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.cart-recommendation-card:hover .cart-recommendation-card__media img {
    transform: scale(1.05);
}

.cart-recommendation-card__content h3 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
    color: #e8eaed;
}

.cart-recommendation-card__content p {
    font-size: 0.8125rem;
    color: #9aa0a6;
    margin-bottom: 0.75rem;
}

.cart-recommendation-card__footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
    padding-top: 1rem;
}

.cart-recommendation-card__footer strong {
    font-size: 1.125rem;
    color: #00e676;
    font-weight: 800;
}

.cart-recommendation-card__footer button {
    background: linear-gradient(135deg, #00e676, #00c853);
    color: #1a1d24;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.cart-recommendation-card__footer button:hover {
    transform: scale(0.95);
    box-shadow: 0 2px 8px rgba(0, 230, 118, 0.3);
}

/* Animações de dinheiro - ESTILO CHECKOUT */
.money {
    position: absolute;
    bottom: 0;
    right: 96%;
    font-size: 15px;
    font-weight: bold;
    color: #00e676;
    opacity: 0;
    animation: subirDinheiro 3s infinite ease-out;
    text-shadow: 0 0 5px rgba(0, 230, 118, 0.5);
    pointer-events: none;
}

.money:nth-child(1) {
    right: 13%;
    animation-delay: 0s;
}

.money:nth-child(2) {
    right: 22%;
    animation-delay: .5s;
}

.money:nth-child(3) {
    right: 5%;
    animation-delay: 1s;
}

.money:nth-child(4) {
    right: 15%;
    animation-delay: 1.5s;
}

.money:nth-child(5) {
    right: 41%;
    animation-delay: 2s;
}

@keyframes subirDinheiro {
    0% {
        transform: translateY(0) scale(0.6) rotate(0deg);
        opacity: 0;
    }

    15% {
        opacity: 1;
    }

    100% {
        transform: translateY(-50px) scale(1.2) rotate(18deg);
        opacity: 0;
    }
}

/* Media Queries - Tablet */
@media (min-width: 768px) and (max-width: 1024px) {
    .cart-page-grid {
        grid-template-columns: 1fr 320px;
        gap: 1.5rem;
    }

    .cart-product-card {
        flex-wrap: wrap;
    }

    .cart-product-card__controls {
        width: 100%;
        justify-content: flex-end;
        margin-top: 1rem;
    }

    .cart-recommendation-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Media Queries - Mobile */
@media (max-width: 767px) {
    .cart-page-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .cart-summary-panel {
        position: relative;
        top: 0;
    }

    .cart-product-card {
        flex-direction: column;
        align-items: flex-start;
        text-align: center;
    }

    .cart-product-card__media {
        width: 100%;
        height: auto;
        max-width: 200px;
        margin: 0 auto 1rem;
    }

    .cart-product-card__body {
        text-align: center;
        width: 100%;
    }

    .cart-product-card__meta {
        justify-content: center;
    }

    .cart-product-card__controls {
        width: 100%;
        justify-content: center;
        margin-top: 1rem;
    }

    .cart-recommendation-grid {
        grid-template-columns: 1fr;
    }

    .cart-page-heading {
        text-align: center;
    }

    .cart-page-heading h1 {
        font-size: 1.5rem;
    }

    .cart-clear {
        text-align: center;
    }

    .cart-summary-panel__header {
        padding: 1rem 1rem 0 1rem;
    }

    .cart-summary-block {
        padding: 0 1rem 1rem 1rem;
    }

    .cart-summary-gift {
        padding: 1rem;
    }

    .cart-summary-totals {
        padding: 1rem;
    }

    .checkout-action {
        padding: 0 1rem 1rem 1rem;
    }

    .cart-summary-total-line--grand span:last-child {
        font-size: 1.25rem;
    }
}