/* CART & CHECKOUT STYLES */

.page-header-section {
    background: linear-gradient(135deg, #ff6b9d10, #4ecdc410);
    padding: 40px 0 30px;
    border-bottom: 1px solid #f0f0f0;
}
.page-title {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--text-dark);
}
.breadcrumb-nav {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #888;
    font-size: 13px;
}
.breadcrumb-nav a {
    color: var(--primary-color);
    text-decoration: none;
}
.breadcrumb-nav a:hover {
    text-decoration: underline;
}
.breadcrumb-nav i {
    font-size: 10px;
    color: #ccc;
}

/* CART PAGE */
.cart-page-section {
    padding: 50px 0;
    background: #fafafa;
    min-height: 60vh;
}
.cart-page-layout {
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 30px;
}
.cart-items-container {
    background: #fff;
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.04);
}
.cart-table {
    width: 100%;
    border-collapse: collapse;
}
.cart-table thead th {
    text-align: left;
    padding: 12px 8px;
    font-size: 13px;
    font-weight: 600;
    color: #666;
    border-bottom: 2px solid #f0f0f0;
}
.cart-table tbody tr {
    border-bottom: 1px solid #f5f5f5;
}
.cart-table td {
    padding: 16px 8px;
    vertical-align: middle;
}
.cart-img-cell img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 10px;
    border: 1px solid #f0f0f0;
}
.cart-product-name {
    color: var(--text-dark);
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
    display: block;
    margin-bottom: 4px;
}
.cart-product-name:hover { color: var(--primary-color); }
.cart-variant {
    font-size: 12px;
    color: #888;
}
.cart-price-cell, .cart-total-cell {
    font-weight: 600;
    color: var(--text-dark);
}
.qty-control {
    display: inline-flex;
    align-items: center;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
}
.qty-btn {
    background: #fafafa;
    border: none;
    width: 32px;
    height: 36px;
    cursor: pointer;
    font-size: 16px;
    color: #555;
    transition: background 0.2s;
}
.qty-btn:hover { background: #f0f0f0; }
.qty-input {
    width: 44px;
    height: 36px;
    border: none;
    text-align: center;
    font-size: 14px;
    font-weight: 600;
    -moz-appearance: textfield;
}
.qty-input::-webkit-inner-spin-button,
.qty-input::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
.remove-item {
    background: #fef2f2;
    color: #ef4444;
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
}
.remove-item:hover {
    background: #ef4444;
    color: #fff;
}

.cart-actions-bottom {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #f0f0f0;
}

.cart-summary {
    background: #fff;
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.04);
    height: fit-content;
    position: sticky;
    top: 20px;
}
.summary-title {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 2px solid #f0f0f0;
}
.summary-row {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    font-size: 14px;
}
.summary-row.total {
    border-top: 1px solid #f0f0f0;
    padding-top: 16px;
    margin-top: 12px;
    font-size: 18px;
}
.summary-row.total strong {
    color: var(--primary-color);
}
.free-shipping {
    color: #22c55e;
    font-weight: 700;
}
.free-shipping-info {
    background: #fffbeb;
    color: #92400e;
    padding: 10px 14px;
    border-radius: 8px;
    font-size: 13px;
    margin: 10px 0;
}
.btn-checkout-cart {
    display: block;
    width: 100%;
    background: linear-gradient(135deg, var(--primary-color), #ff8fab);
    color: #fff;
    border: none;
    padding: 14px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
    text-align: center;
    text-decoration: none;
    margin-top: 16px;
    transition: all 0.2s;
}
.btn-checkout-cart:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(255,107,157,0.3);
    color: #fff;
}
.payment-icons {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-top: 14px;
    color: #aaa;
    font-size: 22px;
}

.empty-cart {
    text-align: center;
    padding: 80px 20px;
    background: #fff;
    border-radius: 16px;
}
.empty-cart i {
    font-size: 60px;
    color: #ddd;
    margin-bottom: 20px;
}
.empty-cart h2 { font-size: 24px; margin-bottom: 10px; }
.empty-cart p { color: #888; margin-bottom: 20px; }

/* CHECKOUT */
.checkout-section {
    padding: 50px 0;
    background: #fafafa;
}
.checkout-layout {
    display: grid;
    grid-template-columns: 1fr 400px;
    gap: 30px;
}
.checkout-block {
    background: #fff;
    border-radius: 16px;
    padding: 24px;
    margin-bottom: 20px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.04);
}
.checkout-block-title {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 17px;
    font-weight: 700;
    margin-bottom: 20px;
    color: var(--text-dark);
}
.step-num {
    width: 32px;
    height: 32px;
    background: var(--primary-color);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 700;
}
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 16px;
}
.form-group, .form-col {
    display: flex;
    flex-direction: column;
}
.form-group label, .form-col label {
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 6px;
    color: #555;
}
.form-group input, .form-col input,
.form-group textarea, .form-group select {
    padding: 12px 14px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    font-size: 14px;
    font-family: inherit;
    transition: border-color 0.2s;
}
.form-group input:focus, .form-col input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
}
.form-group { margin-bottom: 16px; }

.payment-methods {
    display: flex;
    flex-direction: column;
    width: 100%;
    align-items: flex-start;
    gap: 12px;
}
.payment-method-card {
    display: flex;
    align-items: center;
    padding: 16px;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s;
    margin: 0;
    width: 100%;
}
.payment-method-card input { margin-right: 12px; }
.payment-method-card:hover { border-color: var(--primary-color); }
.payment-method-card input:checked ~ .pm-content {
    color: var(--primary-color);
}
.payment-method-card.disabled {
    opacity: 0.5;
    cursor: not-allowed;
}
.pm-content {
    display: flex;
    align-items: center;
    gap: 14px;
    flex: 1;
}
.pm-content i {
    font-size: 28px;
    color: var(--primary-color);
}
.pm-content strong { display: block; font-size: 14px; }
.pm-content small { font-size: 11px; color: #999; font-weight: 500; }
.pm-content p { margin: 2px 0 0; font-size: 12px; color: #888; }

/* select inputs in checkout */
.form-col select, .form-group select {
    padding: 12px 14px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    font-size: 14px;
    font-family: inherit;
    background: #fff;
    cursor: pointer;
    transition: border-color 0.2s;
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23999' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 36px;
}
.form-col select:focus, .form-group select:focus {
    outline: none;
    border-color: var(--primary-color);
}

/* fatura türü tabs */
.invoice-type-tabs { display: flex; gap: 10px; }
.invoice-tab {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    color: #666;
    transition: all 0.2s;
    margin: 0;
}
.invoice-tab input { position: absolute; opacity: 0; width: 0; height: 0; pointer-events: none; }
.invoice-tab.active { border-color: var(--primary-color); color: var(--primary-color); background: #fff0f6; }
.invoice-tab i { font-size: 16px; }

.checkbox-line {
    display: flex;
    gap: 8px;
    align-items: flex-start;
    font-size: 13px;
    color: #555;
    cursor: pointer;
}
.checkbox-line input { margin-top: 3px; width: auto; }
.checkbox-line a { color: var(--primary-color); }

.summary-title {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--bg-light);
}

.checkout-summary {
    background: #fff;
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.04);
    height: fit-content;
    position: sticky;
    top: 20px;
}
.checkout-items {
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 1px solid #f0f0f0;
    max-height: 320px;
    overflow-y: auto;
}
.co-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 0;
    border-bottom: 1px dashed #f0f0f0;
}
.co-item:last-child { border: none; }
.co-item-img {
    position: relative;
    width: 56px;
    height: 56px;
    flex-shrink: 0;
}
.co-item-img img {
    width: 100%; height: 100%;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid #f0f0f0;
}
.co-qty-badge {
    position: absolute;
    top: -6px; right: -6px;
    background: var(--primary-color);
    color: #fff;
    width: 22px; height: 22px;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 11px; font-weight: 700;
}
.co-item-info {
    flex: 1;
    min-width: 0;
}
.co-item-info strong {
    display: block;
    font-size: 13px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.co-item-info small {
    font-size: 11px;
    color: #888;
}
.co-item-price {
    font-weight: 600;
    font-size: 13px;
    flex-shrink: 0;
}

.alert {
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 20px;
}
.alert-success { background: #d1fae5; color: #065f46; }
.alert-danger { background: #fee2e2; color: #991b1b; }
.alert-warning { background: #fef3c7; color: #92400e; }

@media (max-width: 992px) {
    .cart-page-layout, .checkout-layout { grid-template-columns: 1fr; }
    .cart-summary, .checkout-summary { position: relative; top: 0; }
    .form-row { grid-template-columns: 1fr; }
    .cart-table { font-size: 13px; }
    .cart-img-cell img { width: 60px; height: 60px; }
}
