/* ═══════════════════════════════════════════════
   CART PAGE — Premium Navy / Gold Design System
   ═══════════════════════════════════════════════ */

/* ── Tablo ── */
#cart-table { width: 100%; border-collapse: collapse; font-size: 12.5px; }

#cart-table thead tr {
    background: linear-gradient(90deg, #0F1E3C 0%, #1A3260 100%);
}
#cart-table thead th {
    color: rgba(255,255,255,0.85);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    padding: 10px 14px;
    border: none;
    white-space: nowrap;
}
#cart-table thead th:first-child { border-radius: 6px 0 0 0; }
#cart-table thead th:last-child  { border-radius: 0 6px 0 0; }

#cart-table tbody tr {
    border-bottom: 1px solid #DDE2EC;
    transition: background 0.15s;
}
#cart-table tbody tr:hover { background: rgba(30,58,115,0.03); }

#cart-table tbody tr.out-of-stock {
    background: rgba(211,47,47,0.04);
    border-left: 3px solid #d32f2f;
}
#cart-table tbody tr.out-of-stock:hover { background: rgba(211,47,47,0.07); }

#cart-table td {
    padding: 10px 14px;
    vertical-align: middle;
    color: #1A2540;
    text-align: left;
}

/* Fiyat ve toplam sütunları sağa hizalı */
#cart-table td:nth-child(2) { text-align: right; }
#cart-table td:nth-child(4) { text-align: right; }
#cart-table td:nth-child(3),
#cart-table td:nth-child(5) { text-align: center; }

#cart-table tfoot tr { background: #F4F6FA; border-top: 2px solid #C9A84C; }
#cart-table tfoot th {
    padding: 12px 14px;
    font-size: 13px;
    color: #0F1E3C;
    border: none;
}

/* ── Ürün bilgi bloğu ── */
.product-info {
    display: flex;
    flex-direction: column;
    gap: 5px;
    align-items: flex-start;
    text-align: left;
}

.product-name {
    font-size: 13px;
    font-weight: 700;
    color: #0F1E3C;
    line-height: 1.3;
    text-align: left;
}

.product-code {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
    text-align: left;
}

.product-badge {
    display: inline-block;
    background: #F4F6FA;
    border: 1px solid #DDE2EC;
    color: #1E3A73;
    font-size: 10.5px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 3px;
    letter-spacing: 0.3px;
}

/* Tükenmiş ürün uyarısı */
.stock-warning {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #d32f2f;
    font-size: 10px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 3px;
}

.coded-part-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: #fef3c7;
    border: 1px solid #fcd34d;
    color: #b45309;
    font-size: 10px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 3px;
}

/* ── Fiyat ── */
.price-info { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; }

.current-price {
    font-size: 13px;
    font-weight: 700;
    color: #0F1E3C;
    white-space: nowrap;
}

.line-total {
    font-size: 13.5px;
    font-weight: 800;
    color: #0F1E3C;
    white-space: nowrap;
}

.out-of-stock .current-price,
.out-of-stock .line-total { color: #b0b8cc; }

/* ── Adet kontrolü ── */
.quantity-controls {
    display: inline-flex;
    align-items: center;
    border: 1.5px solid #DDE2EC;
    border-radius: 5px;
    overflow: hidden;
    background: #fff;
}

.quantity-controls .qty-btn {
    background: #F4F6FA;
    border: none;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #6B7A99;
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
    font-size: 11px;
    font-weight: 700;
}
.quantity-controls .qty-btn:hover:not(:disabled) {
    background: #0F1E3C;
    color: #fff;
}
.quantity-controls .qty-btn:disabled { opacity: 0.35; cursor: not-allowed; }

.quantity-controls .qty-display {
    width: 48px;
    min-width: 48px;
    text-align: center;
    padding: 4px 2px;
    background: #fff;
    font-weight: 700;
    font-size: 12.5px;
    color: #0F1E3C;
    border: none;
    outline: none;
    border-left: 1px solid #DDE2EC;
    border-right: 1px solid #DDE2EC;
}

/* Tarayıcı artır/azalt oklarını gizle — +/- butonları zaten var */
.quantity-controls .qty-display::-webkit-outer-spin-button,
.quantity-controls .qty-display::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}
.quantity-controls .qty-display { -moz-appearance: textfield; appearance: textfield; }
.quantity-controls .qty-display:focus { background: #F4F6FA; }
.quantity-controls .qty-display:disabled { opacity: 0.5; }

.out-of-stock .qty-display { opacity: 0.4; }

/* ── İşlem butonları ── */
.actions-group { display: flex; gap: 6px; justify-content: center; }

.btn-remove {
    width: 30px;
    height: 30px;
    background: transparent;
    border: 1.5px solid #DDE2EC;
    color: #6B7A99;
    border-radius: 5px;
    font-size: 11px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s, border-color 0.15s, color 0.15s;
}
.btn-remove:hover {
    background: #fef2f2;
    border-color: #d32f2f;
    color: #d32f2f;
}

/* ── Sepet uyarı banner ── */
#cart-alert {
    padding: 10px 16px;
    border-radius: 6px;
    font-size: 12.5px;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}
#cart-alert.alert-danger {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #d32f2f;
}
#cart-alert.alert-success {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    color: #15803d;
}

/* ── Özet panel ── */
.page-summary { background: #fff; border: 1px solid #DDE2EC; border-radius: 8px; overflow: hidden; }

.page-summary-header {
    background: linear-gradient(90deg, #0F1E3C 0%, #1A3260 100%);
    color: #fff;
    padding: 14px 18px;
    font-size: 13px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.page-summary-body { padding: 16px 18px; }

.page-summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid #DDE2EC;
    font-size: 12.5px;
    color: #1A2540;
}
.page-summary-row:last-child {
    border-bottom: none;
    border-top: 2px solid #C9A84C;
    padding-top: 12px;
    margin-top: 6px;
    font-size: 15px;
    font-weight: 800;
    color: #0F1E3C;
}

.page-price { font-weight: 700; color: #0F1E3C; }
.page-price-lg { font-size: 18px; font-weight: 800; color: #C9A84C; }

/* Checkout butonu */
#btn-checkout {
    width: 100%;
    margin-top: 14px;
    padding: 13px 20px;
    background: linear-gradient(135deg, #C9A84C, #E2C46A);
    color: #0F1E3C;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 800;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: opacity 0.2s, transform 0.15s;
    letter-spacing: 0.2px;
}
#btn-checkout:hover:not(:disabled) { opacity: 0.9; transform: translateY(-1px); }
#btn-checkout:disabled {
    background: #DDE2EC;
    color: #6B7A99;
    cursor: not-allowed;
    transform: none;
}

/* Tükenmiş ürün varken farklı stil */
#btn-checkout.has-stockout {
    background: #DDE2EC;
    color: #d32f2f;
    cursor: not-allowed;
}

.page-summary-footer {
    background: #F4F6FA;
    padding: 10px 18px;
    border-top: 1px solid #DDE2EC;
    font-size: 11px;
    color: #6B7A99;
    text-align: center;
}

/* Bilgi kutusu */
.page-info {
    background: rgba(201,168,76,0.06);
    border: 1px solid rgba(201,168,76,0.3);
    border-radius: 6px;
    padding: 12px 16px;
    font-size: 11.5px;
    color: #1A2540;
    margin-top: 10px;
}
.page-info-title {
    font-weight: 700;
    color: #0F1E3C;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
}
.page-info ul { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 5px; }
.page-info ul li { display: flex; align-items: center; gap: 6px; color: #6B7A99; }
.page-info ul li i { color: #C9A84C; font-size: 11px; width: 14px; }

/* ── Boş sepet ── */
.page-empty { text-align: center; padding: 48px 24px; }
.page-empty-icon { font-size: 48px; color: #DDE2EC; margin-bottom: 14px; }
.page-empty h5 { font-size: 16px; font-weight: 800; color: #0F1E3C; margin-bottom: 6px; }
.page-empty p { font-size: 12.5px; color: #6B7A99; max-width: 300px; margin: 0 auto 16px; }
.page-empty .page-btn { display: inline-flex; align-items: center; gap: 6px; }

/* ── Animasyonlar ── */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(6px); }
    to   { opacity: 1; transform: translateY(0); }
}
.item-enter { animation: fadeIn 0.25s ease forwards; }
