:root {
    --primary: #f27a1a;
    --primary-dark: #d9650b;
    --dark: #1e293b;
    --darker: #0f172a;
    --light-bg: #f8fafc;
    --white: #ffffff;
    --border: #e2e8f0;
    --text: #334155;
    --muted: #64748b;
    --success: #16a34a;
    --danger: #dc2626;
    --shadow: 0 4px 15px rgba(0, 0, 0, 0.06);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
}

body {
    background-color: var(--light-bg);
    color: var(--text);
    line-height: 1.5;
}

.container {
    max-width: 1260px;
    margin: 0 auto;
    padding: 0 16px;
}

.hidden {
    display: none !important;
}

/* ÜST PROMOSYON BARI */
.top-promo-bar {
    background: var(--darker);
    color: #f8fafc;
    text-align: center;
    padding: 7px 12px;
    font-size: 0.85rem;
}

.top-promo-bar strong {
    color: #fb923c;
}

/* NAVBAR */
.navbar {
    background: var(--white);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 90;
    box-shadow: 0 2px 10px rgba(0,0,0,0.03);
}

.nav-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 14px 16px;
}

.brand-logo {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1.6rem;
    color: var(--dark);
    cursor: pointer;
    user-select: none;
}

.brand-logo i {
    color: var(--primary);
}

.brand-logo strong {
    color: var(--primary);
}

.search-box {
    flex: 1;
    max-width: 540px;
    display: flex;
    border: 2px solid var(--border);
    border-radius: 10px;
    overflow: hidden;
    background: var(--light-bg);
}

.search-box:focus-within {
    border-color: var(--primary);
    background: var(--white);
}

.search-box input {
    flex: 1;
    border: none;
    background: transparent;
    padding: 10px 14px;
    font-size: 0.95rem;
    outline: none;
}

.search-box button {
    border: none;
    background: var(--primary);
    color: white;
    padding: 0 18px;
    cursor: pointer;
    font-size: 1rem;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.btn-seller-portal {
    background: var(--light-bg);
    border: 1px solid var(--border);
    color: var(--dark);
    padding: 10px 14px;
    border-radius: 10px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 7px;
    transition: 0.2s;
}

.btn-seller-portal:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.btn-cart {
    background: var(--primary);
    border: none;
    color: white;
    padding: 10px 16px;
    border-radius: 10px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    position: relative;
    transition: 0.2s;
}

.btn-cart:hover {
    background: var(--primary-dark);
}

.cart-badge {
    background: var(--darker);
    color: white;
    font-size: 0.78rem;
    padding: 2px 7px;
    border-radius: 99px;
}

/* KATEGORİ ŞERİDİ */
.category-bar {
    border-top: 1px solid var(--border);
    background: var(--white);
}

.category-list {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding: 8px 16px;
}

.cat-btn {
    border: none;
    background: transparent;
    padding: 6px 14px;
    border-radius: 20px;
    font-weight: 600;
    color: var(--muted);
    cursor: pointer;
    white-space: nowrap;
    transition: 0.2s;
}

.cat-btn:hover, .cat-btn.active {
    background: #fff7ed;
    color: var(--primary);
}

/* HERO BANNER */
.hero-banner {
    margin-top: 20px;
    background: linear-gradient(135deg, #1e293b 0%, #334155 100%);
    color: white;
    border-radius: 16px;
    padding: 28px 32px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.hero-badge {
    background: var(--primary);
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 700;
}

.hero-text h1 {
    font-size: 1.7rem;
    margin: 8px 0 6px;
}

.hero-text p {
    color: #cbd5e1;
    font-size: 0.95rem;
}

.hero-stats {
    display: flex;
    gap: 14px;
}

.stat-box {
    background: rgba(255, 255, 255, 0.1);
    padding: 12px 16px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
    font-weight: 600;
}

/* FİLTRE BARI */
.filter-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    margin: 24px 0 16px;
}

.filter-left {
    display: flex;
    align-items: baseline;
    gap: 10px;
}

.filter-left span {
    color: var(--muted);
    font-size: 0.9rem;
}

.filter-right {
    display: flex;
    align-items: center;
    gap: 14px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.9rem;
    cursor: pointer;
}

#sortSelect {
    padding: 8px 12px;
    border-radius: 8px;
    border: 1px solid var(--border);
    background: white;
    outline: none;
}

/* ÜRÜN KARTLARI GRİD */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(245px, 1fr));
    gap: 20px;
    padding-bottom: 50px;
}

.product-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 14px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: transform 0.2s, box-shadow 0.2s;
    position: relative;
}

.product-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow);
}

.discount-tag {
    position: absolute;
    top: 10px;
    left: 10px;
    background: var(--danger);
    color: white;
    font-size: 0.78rem;
    font-weight: 700;
    padding: 4px 8px;
    border-radius: 6px;
}

.shipping-tag {
    position: absolute;
    top: 10px;
    right: 10px;
    background: var(--success);
    color: white;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 4px 8px;
    border-radius: 6px;
}

.product-img {
    width: 100%;
    height: 210px;
    object-fit: cover;
    background: #f1f5f9;
}

.product-body {
    padding: 14px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.seller-chip {
    font-size: 0.78rem;
    color: var(--muted);
    margin-bottom: 4px;
}

.product-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--dark);
    margin-bottom: 6px;
}

.product-desc {
    font-size: 0.82rem;
    color: var(--muted);
    margin-bottom: 12px;
    flex: 1;
}

.price-block {
    margin-bottom: 12px;
}

.old-price {
    font-size: 0.85rem;
    color: var(--muted);
    text-decoration: line-through;
    margin-right: 6px;
}

.current-price {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--primary);
}

.shipping-info-text {
    display: block;
    font-size: 0.75rem;
    color: var(--muted);
    margin-top: 2px;
}

.btn-add-cart {
    width: 100%;
    padding: 10px;
    background: var(--dark);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-add-cart:hover {
    background: var(--primary);
}

/* SEPET ÇEKMECESİ */
.drawer-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.5);
    z-index: 150;
}

.cart-drawer {
    position: fixed;
    top: 0;
    right: -420px;
    width: 100%;
    max-width: 400px;
    height: 100vh;
    background: var(--white);
    z-index: 160;
    display: flex;
    flex-direction: column;
    transition: right 0.3s ease;
    box-shadow: -5px 0 25px rgba(0,0,0,0.15);
}

.cart-drawer.open {
    right: 0;
}

.cart-header {
    padding: 16px 20px;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.close-btn {
    background: none;
    border: none;
    font-size: 1.3rem;
    color: var(--muted);
    cursor: pointer;
}

.cart-items-container {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
}

.cart-item {
    display: flex;
    gap: 12px;
    padding-bottom: 12px;
    margin-bottom: 12px;
    border-bottom: 1px solid var(--border);
}

.cart-item img {
    width: 64px;
    height: 64px;
    border-radius: 8px;
    object-fit: cover;
}

.cart-item-info {
    flex: 1;
}

.cart-item-title {
    font-weight: 600;
    font-size: 0.92rem;
}

.cart-item-price {
    color: var(--primary);
    font-weight: 700;
    font-size: 0.9rem;
}

.qty-controls {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 6px;
}

.qty-btn {
    width: 26px;
    height: 26px;
    border: 1px solid var(--border);
    background: var(--light-bg);
    border-radius: 6px;
    font-weight: 700;
    cursor: pointer;
}

.qty-btn:hover {
    background: var(--primary);
    color: white;
}

.cart-coupon-box {
    padding: 12px 16px;
    background: var(--light-bg);
    border-top: 1px solid var(--border);
}

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

.coupon-input-group input {
    flex: 1;
    padding: 8px 10px;
    border: 1px solid var(--border);
    border-radius: 8px;
    text-transform: uppercase;
}

.coupon-input-group button {
    padding: 8px 14px;
    background: var(--dark);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
}

.coupon-msg {
    display: block;
    margin-top: 4px;
    font-size: 0.8rem;
}

.cart-summary {
    padding: 16px 20px;
    border-top: 1px solid var(--border);
    background: white;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 6px;
    font-size: 0.92rem;
}

.discount-row {
    color: var(--success);
    font-weight: 600;
}

.total-row {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--dark);
    border-top: 1px dashed var(--border);
    padding-top: 8px;
    margin-top: 8px;
}

.btn-checkout {
    width: 100%;
    margin-top: 12px;
    padding: 12px;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
}

/* YÖNETİM PANELLERİ (SATICI & ADMIN) */
.dashboard-section {
    padding: 28px 0 60px;
}

.dash-header {
    background: var(--white);
    padding: 20px 24px;
    border-radius: 14px;
    border: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 14px;
    margin-bottom: 20px;
}

.dash-header.admin-theme {
    background: var(--darker);
    color: white;
}

.role-badge {
    font-size: 0.75rem;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 6px;
}

.role-badge.seller {
    background: #fff7ed;
    color: var(--primary);
}

.role-badge.admin {
    background: var(--primary);
    color: white;
}

.dash-header-actions {
    display: flex;
    gap: 10px;
}

.kpi-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.kpi-card {
    background: white;
    padding: 18px;
    border-radius: 12px;
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    gap: 14px;
}

.kpi-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
}

.kpi-icon.blue { background: #eff6ff; color: #2563eb; }
.kpi-icon.orange { background: #fff7ed; color: #ea580c; }
.kpi-icon.green { background: #f0fdf4; color: #16a34a; }
.kpi-icon.purple { background: #faf5ff; color: #9333ea; }

.kpi-card span {
    font-size: 0.85rem;
    color: var(--muted);
}

.kpi-card h3 {
    font-size: 1.35rem;
    color: var(--dark);
}

.dash-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.tab-btn {
    padding: 10px 18px;
    background: white;
    border: 1px solid var(--border);
    border-radius: 10px;
    font-weight: 600;
    cursor: pointer;
}

.tab-btn.active {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

.panel-card {
    background: white;
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 22px;
    margin-bottom: 20px;
}

.panel-card h3 {
    margin-bottom: 14px;
    color: var(--dark);
}

.grid-form {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 14px;
}

.full-width {
    grid-column: 1 / -1;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 5px;
    margin-bottom: 10px;
}

.form-group label {
    font-size: 0.86rem;
    font-weight: 600;
}

.form-group input, .form-group select, .form-group textarea {
    padding: 10px 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 0.95rem;
}

.file-upload-box {
    border: 2px dashed var(--border);
    padding: 14px;
    border-radius: 10px;
    background: var(--light-bg);
}

.image-preview img {
    max-height: 120px;
    margin-top: 10px;
    border-radius: 8px;
    border: 1px solid var(--border);
}

.inline-form {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.inline-form input, .inline-form select {
    padding: 10px;
    border: 1px solid var(--border);
    border-radius: 8px;
}

/* TABLOLAR */
.table-responsive {
    overflow-x: auto;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.data-table th, .data-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid var(--border);
}

.data-table th {
    background: var(--light-bg);
    font-weight: 600;
}

.table-thumb {
    width: 46px;
    height: 46px;
    border-radius: 6px;
    object-fit: cover;
}

/* BUTONLAR */
.btn-primary {
    background: var(--primary);
    color: white;
    border: none;
    padding: 10px 18px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
}

.btn-primary:hover {
    background: var(--primary-dark);
}

.btn-outline {
    background: white;
    border: 1px solid var(--border);
    color: var(--dark);
    padding: 9px 15px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
}

.btn-danger {
    background: var(--danger);
    color: white;
    border: none;
    padding: 9px 15px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
}

.btn-sm {
    padding: 6px 10px;
    font-size: 0.8rem;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    font-weight: 600;
}

.full-btn {
    width: 100%;
    margin-top: 8px;
}

/* MODALLAR */
.modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.65);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    z-index: 200;
}

.modal-box {
    background: white;
    width: 100%;
    max-width: 500px;
    border-radius: 16px;
    padding: 22px;
    max-height: 90vh;
    overflow-y: auto;
}

.small-modal {
    max-width: 400px;
}

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

.modal-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
}

.m-tab {
    flex: 1;
    padding: 10px;
    border: 1px solid var(--border);
    background: var(--light-bg);
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
}

.m-tab.active {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.info-alert {
    background: #eff6ff;
    border: 1px solid #bfdbfe;
    color: #1e40af;
    padding: 10px;
    border-radius: 8px;
    font-size: 0.85rem;
    margin-bottom: 14px;
}

.helper-text {
    font-size: 0.82rem;
    color: var(--muted);
    margin-bottom: 10px;
}

/* ÖDEME SEÇENEKLERİ */
.payment-methods-grid {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.payment-option {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    border: 1px solid var(--border);
    border-radius: 10px;
    cursor: pointer;
}

.payment-option i {
    font-size: 1.2rem;
    color: var(--primary);
}

.payment-option small {
    display: block;
    color: var(--muted);
}

.card-box {
    background: var(--light-bg);
    padding: 12px;
    border-radius: 10px;
    border: 1px solid var(--border);
    margin-bottom: 12px;
}

.two-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.two-col input {
    padding: 9px;
    border: 1px solid var(--border);
    border-radius: 8px;
}

.checkout-final-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 12px;
    border-top: 1px solid var(--border);
}

/* TOAST BİLDİRİM */
.toast {
    position: fixed;
    bottom: 24px;
    right: 24px;
    background: var(--darker);
    color: white;
    padding: 12px 20px;
    border-radius: 10px;
    font-weight: 600;
    z-index: 300;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
}

@media (max-width: 768px) {
    .nav-content {
        flex-wrap: wrap;
    }
    .search-box {
        order: 3;
        max-width: 100%;
        width: 100%;
    }
}