/* ==========================================================================
   Petlito Marketplace Module - Redesigned Premium Stylesheet
   ========================================================================== */

:root {
    --market-primary: #FF6B35;
    --market-primary-hover: #E0531F;
    --market-primary-light: rgba(255, 107, 53, 0.08);
    --market-bg-light: #FAFAFA;
    --market-bg-card-light: #FFFFFF;
    --market-border-light: #EBEBEB;
    --market-text-main-light: #1C1C1E;
    --market-text-muted-light: #8E8E93;
    
    --market-success: #10B981;
    --market-error: #FF3B30;
    
    --market-bg-dark: #0F0F12;
    --market-bg-card-dark: #16161F;
    --market-border-dark: #24242F;
    --market-text-main-dark: #F5F5F7;
    --market-text-muted-dark: #9A9AA2;

    /* Light Theme as Default */
    --market-bg: var(--market-bg-light);
    --market-bg-card: var(--market-bg-card-light);
    --market-border: var(--market-border-light);
    --market-text-main: var(--market-text-main-light);
    --market-text-muted: var(--market-text-muted-light);
}

/* Dark Mode Context */
[data-theme="dark"] {
    --market-bg: var(--market-bg-dark);
    --market-bg-card: var(--market-bg-card-dark);
    --market-border: var(--market-border-dark);
    --market-text-main: var(--market-text-main-dark);
    --market-text-muted: var(--market-text-muted-dark);
}

.marketplace-container {
    background-color: var(--market-bg);
    color: var(--market-text-main);
    min-height: calc(100vh - 70px);
    padding-top: 110px;
    padding-bottom: 50px;
    font-family: 'Poppins', sans-serif;
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* Header & Cart Badge */
.marketplace-header-bar {
    display: flex;
    justify-content: flex-end;
    align-items: center;
}

.cart-trigger {
    background: var(--market-bg-card);
    border: 1.5px solid var(--market-border);
    padding: 10px 18px;
    border-radius: 30px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    position: relative;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.02);
    color: var(--market-text-main);
}

.cart-trigger:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.06);
    border-color: var(--market-primary);
}

.market-account {
    position: relative;
    flex-shrink: 0;
}

.market-account-btn {
    background: var(--market-bg-card);
    border: 1.5px solid var(--market-border);
    padding: 10px 18px;
    border-radius: 30px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 45px;
    color: var(--market-text-main);
    font-family: 'Poppins', sans-serif;
    font-weight: 700;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.02);
}

.market-account-btn:hover,
.market-account.open .market-account-btn {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.06);
    border-color: var(--market-primary);
    color: var(--market-primary);
}

.market-account-menu {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    z-index: 60;
    min-width: 220px;
    padding: 8px;
    background: var(--market-bg-card);
    border: 1.5px solid var(--market-border);
    border-radius: 16px;
    box-shadow: 0 16px 34px rgba(17, 24, 39, 0.14);
    opacity: 0;
    transform: translateY(-6px);
    pointer-events: none;
    transition: opacity .18s ease, transform .18s ease;
}

.market-account.open .market-account-menu {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.market-account-menu button {
    width: 100%;
    min-height: 42px;
    border: none;
    border-radius: 10px;
    background: transparent;
    color: var(--market-text-main);
    cursor: pointer;
    display: flex;
    align-items: center;
    padding: 0 12px;
    font-family: 'Poppins', sans-serif;
    font-size: .9rem;
    font-weight: 700;
    text-align: left;
}

.market-account-menu button:hover {
    background: var(--market-primary-light);
    color: var(--market-primary);
}

.cart-badge {
    background: var(--market-primary);
    color: white;
    font-size: 0.75rem;
    font-weight: 600;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: absolute;
    top: -5px;
    right: -5px;
    border: 2px solid var(--market-bg-card);
    animation: pulse-badge 2s infinite;
}

@keyframes pulse-badge {
    0% { transform: scale(1); }
    50% { transform: scale(1.15); }
    100% { transform: scale(1); }
}

/* "Fly to cart" add animation */
.cart-fly-ghost {
    position: fixed;
    z-index: 10900;
    border-radius: 50%;
    object-fit: cover;
    pointer-events: none;
    transition: left 0.6s cubic-bezier(.15,.85,.35,1),
                top 0.6s cubic-bezier(.15,.85,.35,1),
                width 0.6s cubic-bezier(.15,.85,.35,1),
                height 0.6s cubic-bezier(.15,.85,.35,1),
                opacity 0.6s ease-in;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.25);
    border: 2px solid var(--market-primary);
}

@keyframes cart-bump-anim {
    0% { transform: scale(1); }
    35% { transform: scale(1.28); }
    65% { transform: scale(0.92); }
    100% { transform: scale(1); }
}

.cart-trigger.cart-bump {
    animation: cart-bump-anim 0.4s ease;
}

/* ==========================================================================
   Search & Cart Row Layout
   ========================================================================== */
.search-cart-row {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 2rem;
    width: 100%;
}

@media(min-width: 600px) {
    .search-cart-row {
        flex-direction: row;
        align-items: center;
    }
}

.search-cart-row .search-wrapper {
    flex-grow: 1;
}

.search-cart-row .cart-trigger {
    flex-shrink: 0;
    align-self: stretch;
    display: flex;
    align-items: center;
    justify-content: center;
}

.search-cart-row .market-account {
    align-self: stretch;
}

.search-cart-row .market-account-btn {
    width: 100%;
    height: 100%;
}

.search-wrapper {
    position: relative;
    flex: 1;
}

.search-input {
    width: 100%;
    background: var(--market-bg-card);
    border: 1.5px solid var(--market-border);
    padding: 14px 42px 14px 48px;
    border-radius: 30px;
    font-size: 0.95rem;
    color: var(--market-text-main);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.02);
    transition: all 0.3s ease;
}

.search-input:focus {
    border-color: var(--market-primary);
    box-shadow: 0 4px 20px rgba(255, 107, 53, 0.12);
    outline: none;
}

.search-icon-svg {
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--market-text-muted);
    pointer-events: none;
    width: 18px;
    height: 18px;
}

.search-clear-btn {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    color: var(--market-text-muted);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4px;
    transition: color 0.2s ease;
}

.search-clear-btn:hover {
    color: var(--market-primary);
}

.search-trigger-btn {
    flex-shrink: 0;
    width: 50px;
    height: 50px;
    border: none;
    border-radius: 16px;
    background: var(--market-primary);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 8px rgba(255, 107, 53, 0.35);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.search-trigger-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 14px rgba(255, 107, 53, 0.4);
}

/* ==========================================================================
   Horizontal Category Chips Scrollbar
   ========================================================================== */
.category-navbar {
    display: flex;
    overflow-x: auto;
    gap: 12px;
    padding: 4px 2px 20px 2px;
    margin-bottom: 2rem;
    scrollbar-width: none;
}

.category-navbar::-webkit-scrollbar {
    display: none;
}

.category-chip {
    flex: 0 0 auto;
    background: var(--market-bg-card);
    border: 1.5px solid var(--market-border);
    padding: 11px 22px;
    border-radius: 24px;
    font-weight: 500;
    font-size: 0.88rem;
    cursor: pointer;
    transition: all 0.25s ease;
    color: var(--market-text-main);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.category-chip svg {
    width: 16px;
    height: 16px;
    stroke: currentColor;
    fill: none;
    stroke-width: 2.2;
}

.category-chip:hover {
    border-color: var(--market-primary);
    color: var(--market-primary);
}

.category-chip.active {
    background: var(--market-primary);
    border-color: var(--market-primary);
    color: white;
    box-shadow: 0 6px 14px rgba(255, 107, 53, 0.3);
}

/* Subcategory Chips (children of the selected top-level category) */
.subcategory-navbar {
    display: flex;
    overflow-x: auto;
    gap: 6px;
    padding: 0 2px 20px 2px;
    margin-top: -1.5rem;
    margin-bottom: 2rem;
    scrollbar-width: none;
}

.subcategory-navbar::-webkit-scrollbar {
    display: none;
}

.subcategory-chip {
    flex: 0 0 auto;
    background: var(--market-bg-light);
    border: 1px solid var(--market-primary);
    padding: 6px 13px;
    border-radius: 16px;
    font-weight: 600;
    font-size: 0.72rem;
    color: var(--market-text-muted);
    cursor: pointer;
    transition: all 0.2s ease;
}

/* Breadcrumb: "‹ Geri" + "Kedi › Mama › Kuru Mama" — only shown once path.length > 1 */
.category-breadcrumb {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: -1.5rem 0 2rem;
}

.breadcrumb-back-btn {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 4px;
    background: transparent;
    border: none;
    color: var(--market-primary);
    font-weight: 700;
    font-size: 0.82rem;
    cursor: pointer;
    padding: 4px 2px;
}

.breadcrumb-path {
    color: var(--market-text-muted);
    font-size: 0.8rem;
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Level loading spinner + generic spinner dot animation (reused by infinite scroll) */
.category-level-spinner,
.grid-footer-spinner {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 14px 0;
    margin-bottom: 1rem;
}

.grid-footer-spinner {
    margin-bottom: 0;
    margin-top: 16px;
}

.spinner-dot {
    width: 22px;
    height: 22px;
    border: 3px solid var(--market-primary-light);
    border-top-color: var(--market-primary);
    border-radius: 50%;
    animation: spinner-rotate 0.7s linear infinite;
}

@keyframes spinner-rotate {
    to { transform: rotate(360deg); }
}

/* Root category / product load error state (with retry) */
.category-error-state {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--market-text-muted);
    font-size: 0.85rem;
    padding: 10px 2px;
}

.category-retry-btn {
    background: var(--market-primary);
    color: white;
    border: none;
    border-radius: 8px;
    padding: 6px 14px;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
}

/* ==========================================================================
   Two Column Main Grid Layout
   ========================================================================== */
.marketplace-main-layout {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

@media(min-width: 992px) {
    .marketplace-main-layout {
        flex-direction: row;
        align-items: flex-start;
    }
}

/* Sidebar Filters */
.filter-sidebar {
    width: 100%;
    background: var(--market-bg-card);
    border: 1.5px solid var(--market-border);
    border-radius: 20px;
    padding: 20px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.02);
    height: fit-content;
}

@media(min-width: 992px) {
    .filter-sidebar {
        width: 280px;
        flex-shrink: 0;
    }
}

.filter-sidebar-header {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    font-size: 1.05rem;
    padding-bottom: 16px;
    border-bottom: 1.5px solid var(--market-border);
    margin-bottom: 16px;
}

.filter-sidebar-header svg {
    color: var(--market-primary);
}

/* Sidebar Accordions */
.filter-accordion {
    margin-bottom: 16px;
    border-bottom: 1.5px solid var(--market-border);
    padding-bottom: 16px;
}

.filter-accordion:last-child {
    margin-bottom: 0;
    border-bottom: none;
    padding-bottom: 0;
}

.filter-accordion-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    background: transparent;
    border: 0;
    padding: 0;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.92rem;
    margin-bottom: 12px;
    color: var(--market-text-main);
    user-select: none;
    transition: color 0.2s ease;
}

.filter-accordion-header span {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.filter-accordion-header em {
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--market-primary-light);
    color: var(--market-primary);
    font-size: 0.72rem;
    font-style: normal;
    font-weight: 800;
}

.filter-accordion-header:hover {
    color: var(--market-primary);
}

.filter-accordion-header:hover .chevron-icon {
    color: var(--market-primary);
}

.chevron-icon {
    color: var(--market-text-muted);
    transition: transform 0.25s ease, color 0.2s ease;
}

.filter-accordion.active .chevron-icon {
    transform: rotate(180deg);
}

.filter-accordion-body {
    display: none;
}

.filter-accordion.active .filter-accordion-body {
    display: block;
}

.sidebar-empty-note {
    color: var(--market-text-muted);
    font-size: 0.82rem;
    line-height: 1.45;
    margin: 0;
    padding: 8px 2px;
}

.sidebar-filter-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding-top: 16px;
    margin-top: 4px;
    border-top: 1.5px solid var(--market-border);
}

.filter-sidebar .filter-field-row,
.filter-sidebar .filter-field-group {
    border-radius: 14px;
    padding: 12px 14px;
}

.filter-sidebar .filter-chip-row {
    gap: 6px;
}

.filter-sidebar .filter-option-chip {
    padding: 7px 10px;
}

/* Checkbox and Radio lists */
.filter-radio-group, .filter-checkbox-group {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.radio-row, .checkbox-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    cursor: pointer;
    color: var(--market-text-main);
    padding: 8px 10px;
    border-radius: 10px;
    border: 1.5px solid transparent;
    transition: background-color 0.18s ease, color 0.18s ease, border-color 0.18s ease;
}

.radio-row:hover, .checkbox-row:hover {
    background: var(--market-primary-light);
    color: var(--market-primary);
}

/* Selected state driven by the native input (no JS needed) */
.radio-row:has(input:checked),
.checkbox-row:has(input:checked) {
    background: var(--market-primary-light);
    border-color: var(--market-primary);
    color: var(--market-primary);
    font-weight: 600;
}

.radio-row:has(input:checked) .filter-count,
.checkbox-row:has(input:checked) .filter-count {
    color: var(--market-primary);
}

.radio-label-wrapper, .checkbox-label-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
}

.radio-row input, .checkbox-row input {
    accent-color: var(--market-primary);
    width: 15px;
    height: 15px;
    cursor: pointer;
}

.filter-count {
    color: var(--market-text-muted);
    font-size: 0.78rem;
    transition: color 0.18s ease;
}

/* Vendor Search Inside Sidebar */
.vendor-filter-search {
    margin-bottom: 12px;
}

.vendor-filter-search input {
    width: 100%;
    background: var(--market-bg);
    border: 1.5px solid var(--market-border);
    padding: 8px 12px;
    border-radius: 8px;
    font-size: 0.8rem;
    color: var(--market-text-main);
}

.vendor-filter-search input:focus {
    border-color: var(--market-primary);
    box-shadow: 0 0 0 3px var(--market-primary-light);
    outline: none;
}

/* "Daha Fazla Göster" — collapses a long vendor list to VENDOR_LIST_COLLAPSED_COUNT rows */
.vendor-list-toggle-btn {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    background: transparent;
    border: none;
    border-top: 1.5px dashed var(--market-border);
    color: var(--market-primary);
    font-size: 0.8rem;
    font-weight: 700;
    padding: 10px 4px 4px;
    margin-top: 4px;
    cursor: pointer;
    transition: color 0.18s ease;
}

.vendor-list-toggle-btn:hover {
    color: var(--market-primary-hover);
}

.vendor-list-toggle-icon {
    transition: transform 0.2s ease;
}

.vendor-list-toggle-icon.expanded {
    transform: rotate(180deg);
}

/* Products listing Area */
.products-list-area {
    flex-grow: 1;
}

/* Toolbar */
.marketplace-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 1.5rem;
}

.market-sort-control {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #6B6B70;
    font-size: 0.78rem;
    font-weight: 600;
}

.market-sort-control select {
    height: 38px;
    min-width: 132px;
    border: 1.5px solid var(--market-border);
    border-radius: 10px;
    background: var(--market-bg-card);
    color: var(--market-text);
    padding: 0 34px 0 12px;
    font: inherit;
    cursor: pointer;
}

.market-sort-control select:focus {
    outline: none;
    border-color: var(--market-primary);
    box-shadow: 0 0 0 3px var(--market-primary-light);
}

.filter-pill-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #F5F5F7;
    border: 1.5px solid transparent;
    color: #6B6B70;
    border-radius: 10px;
    padding: 7px 13px;
    font-size: 0.78rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.filter-pill-btn:hover {
    border-color: var(--market-primary);
    color: var(--market-primary);
}

.filter-pill-btn.active {
    background: #FFF0E8;
    border-color: #FFD4BC;
    color: var(--market-primary);
}

/* ==========================================================================
   Product Grid Layout (Double Column Mobile, Multi Column Desktop)
   ========================================================================== */
.product-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

@media(min-width: 768px) {
    .product-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media(min-width: 1200px) {
    .product-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* ==========================================================================
   Redesigned Product Card
   ========================================================================== */
.product-card {
    background: var(--market-bg-card);
    border: 1.5px solid var(--market-border);
    border-radius: 20px;
    overflow: hidden;
    position: relative;
    display: flex;
    flex-direction: column;
    transition: all 0.35s cubic-bezier(0.25, 0.8, 0.25, 1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.02);
}

.product-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.06);
    border-color: rgba(255, 107, 53, 0.2);
}

/* Badge overlay systems */
/* Vendor name shown subtly under the product title */
.product-vendor {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 0.72rem;
    font-weight: 500;
    color: var(--market-text-muted);
    margin-bottom: 10px;
    line-height: 1.2;
    text-decoration: none;
}

.product-vendor svg {
    width: 11px;
    height: 11px;
    flex-shrink: 0;
    opacity: 0.75;
}

.product-vendor span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.product-vendor:hover {
    color: var(--market-primary);
}
.product-vendor:hover svg {
    color: var(--market-primary);
    opacity: 1;
}

.product-image-container {
    width: 100%;
    aspect-ratio: 1;
    overflow: hidden;
    background: #ffffff;
    position: relative;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
    text-decoration: none;
}

.product-image-container img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    transition: transform 0.5s ease;
}

.product-card:hover .product-image-container img {
    transform: scale(1.03);
}

.product-info {
    padding: 16px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.product-title {
    font-size: 0.88rem;
    font-weight: 600;
    margin-bottom: 5px;
    color: var(--market-text-main);
    text-decoration: none;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    height: 2.8em;
    cursor: pointer;
    transition: color 0.2s;
}

.product-title:hover {
    color: var(--market-primary);
}

/* Rating */
.product-rating {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 0.78rem;
    font-weight: 500;
    color: var(--market-text-muted);
    margin-bottom: 12px;
}

.rating-star-svg {
    width: 13px;
    height: 13px;
    fill: #FFB020;
    color: #FFB020;
}

.product-footer {
    margin-top: auto;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

/* Price on its own row — full width, never competes with the action control,
   so a long price can't wrap or overflow on a narrow card. */
.product-price {
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--market-text-main);
    line-height: 1.1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Full-width "Sepete Ekle" action button (icon + label) */
.product-buy-btn {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    background: var(--market-primary);
    border: none;
    border-radius: 12px;
    padding: 10px 12px;
    cursor: pointer;
    color: #ffffff;
    font-size: 0.85rem;
    font-weight: 700;
    box-shadow: 0 4px 12px rgba(255, 107, 53, 0.28);
    transition: background-color 0.2s ease, box-shadow 0.2s ease, transform 0.15s ease;
}

.product-buy-btn:hover {
    background: var(--market-primary-hover);
    box-shadow: 0 6px 16px rgba(255, 107, 53, 0.36);
}

.product-buy-btn:active {
    transform: scale(0.97);
}

.buy-cart-icon {
    width: 17px;
    height: 17px;
    stroke: #ffffff;
    fill: none;
    stroke-width: 2.2;
    flex-shrink: 0;
}

/* Quantity stepper — replaces the button once the item is in the cart, same
   full-width footprint so the footer height doesn't jump */
.product-qty-stepper {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    background: var(--market-primary-light);
    border: 1.5px solid var(--market-primary);
    border-radius: 12px;
    padding: 4px;
    animation: qty-stepper-pop 0.28s cubic-bezier(.22,1,.36,1);
}

@keyframes qty-stepper-pop {
    0% { transform: scale(0.96); opacity: 0.6; }
    100% { transform: scale(1); opacity: 1; }
}

.qty-stepper-btn {
    width: 34px;
    height: 30px;
    border: none;
    border-radius: 9px;
    background: #ffffff;
    color: var(--market-primary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    transition: background-color 0.15s ease, transform 0.1s ease;
}

.qty-stepper-btn svg {
    width: 16px;
    height: 16px;
}

.qty-stepper-btn:active {
    transform: scale(0.9);
}

.qty-stepper-btn-plus {
    background: var(--market-primary);
    color: #ffffff;
}

.qty-stepper-btn-plus:hover {
    background: var(--market-primary-hover);
}

.qty-stepper-count {
    flex: 1;
    text-align: center;
    font-size: 0.95rem;
    font-weight: 800;
    color: var(--market-primary);
}

[data-theme="dark"] .qty-stepper-btn {
    background: #16161F;
}

[data-theme="dark"] .qty-stepper-btn-plus {
    background: var(--market-primary);
    color: #ffffff;
}

/* ==========================================================================
   Shopping Cart Slideout Sheet
   ========================================================================== */
.cart-sheet-overlay {
    position: fixed;
    top: 0;
    right: 0;
    width: 100%;
    height: 100%;
    background: transparent;
    z-index: 10500;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
}

.cart-sheet-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.cart-sheet {
    position: absolute;
    top: 0;
    right: -480px;
    width: 100%;
    max-width: 460px;
    height: 100%;
    background: var(--market-bg-card);
    box-shadow: -8px 0 30px rgba(0, 0, 0, 0.15);
    display: flex;
    flex-direction: column;
    transition: right 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.cart-sheet-overlay.active .cart-sheet {
    right: 0;
}

.cart-sheet-header {
    padding: 24px;
    border-bottom: 1.5px solid var(--market-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cart-sheet-header h2 {
    font-size: 1.3rem;
    font-weight: 700;
}

.cart-close-btn {
    background: transparent;
    border: none;
    cursor: pointer;
    color: var(--market-text-main);
    display: flex;
    align-items: center;
    justify-content: center;
}

.cart-sheet-body {
    flex-grow: 1;
    overflow-y: auto;
    padding: 24px;
}

/* Shipping Progress Bar */
.shipping-threshold-banner {
    background: var(--market-primary-light);
    border: 1px dashed var(--market-primary);
    border-radius: 12px;
    padding: 14px;
    margin-bottom: 20px;
}

.shipping-threshold-text {
    font-size: 0.82rem;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--market-text-main);
}

.shipping-progress-track {
    width: 100%;
    height: 6px;
    background: rgba(0, 0, 0, 0.05);
    border-radius: 3px;
    overflow: hidden;
}

.shipping-progress-bar {
    height: 100%;
    background: var(--market-success);
    width: 0%;
    transition: width 0.4s ease;
}

/* Vendor Grouping in Cart */
.cart-vendor-group {
    margin-bottom: 20px;
    border: 1.5px solid var(--market-border);
    border-radius: 16px;
    padding: 16px;
    background: var(--market-bg);
}

.cart-vendor-title {
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--market-text-muted);
    margin-bottom: 12px;
    border-bottom: 1px solid var(--market-border);
    padding-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.cart-vendor-title-link,
.cart-item-vendor-link {
    appearance: none;
    border: 0;
    background: transparent;
    margin: 0;
    padding: 0;
    cursor: pointer;
    font: inherit;
    color: var(--market-primary);
    text-align: left;
}

.cart-vendor-title-link {
    font-weight: 800;
}

.cart-vendor-title-link:hover,
.cart-item-vendor-link:hover {
    text-decoration: underline;
}

.cart-item-vendor-link {
    display: inline-flex;
    align-self: flex-start;
    margin-top: 4px;
    margin-bottom: 2px;
    font-size: 0.78rem;
    font-weight: 800;
    line-height: 1.25;
}

.cart-vendor-shipping {
    margin-top: 10px;
    padding: 10px 12px;
    border-radius: 10px;
    border: 1px solid rgba(255, 107, 53, 0.22);
    background: rgba(255, 107, 53, 0.08);
    color: #8a3a18;
    font-size: 0.78rem;
    font-weight: 700;
    line-height: 1.35;
}

.cart-item {
    display: flex;
    gap: 12px;
    margin-bottom: 14px;
    border-radius: 12px;
    transition: background-color .18s ease, transform .18s ease;
}

.cart-item:last-child {
    margin-bottom: 0;
}

.cart-item.js-product-detail-link {
    cursor: pointer;
    padding: 8px;
    margin-left: -8px;
    margin-right: -8px;
}

.cart-item.js-product-detail-link:hover {
    background: #fff7f3;
}

.cart-item.js-product-detail-link:active {
    transform: scale(.995);
}

.cart-item-image {
    width: 60px;
    height: 60px;
    border-radius: 10px;
    object-fit: contain;
    background: #ffffff;
    border: 1px solid var(--market-border);
    padding: 2px;
}

.cart-item-details {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.cart-item-name {
    font-size: 0.85rem;
    font-weight: 500;
    line-height: 1.3;
    margin-bottom: 6px;
    color: var(--market-text-main);
}

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

.cart-item-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 6px;
}

.quantity-stepper {
    display: flex;
    align-items: center;
    border: 1px solid var(--market-border);
    border-radius: 20px;
    background: var(--market-bg-card);
    overflow: hidden;
}

.quantity-stepper button {
    border: none;
    background: transparent;
    width: 26px;
    height: 26px;
    cursor: pointer;
    font-weight: 600;
    color: var(--market-text-main);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s;
}

.quantity-stepper button:hover {
    background-color: var(--market-border);
}

.quantity-stepper span {
    padding: 0 10px;
    font-size: 0.8rem;
    font-weight: 600;
}

.cart-item-remove {
    background: transparent;
    border: none;
    cursor: pointer;
    color: var(--market-error);
    font-size: 0.8rem;
    font-weight: 500;
    opacity: 0.8;
    transition: opacity 0.2s;
}

.cart-item-remove:hover {
    opacity: 1;
}

/* Cart Footer */
.cart-sheet-footer {
    padding: 24px;
    border-top: 1.5px solid var(--market-border);
    background: var(--market-bg-card);
}

.cart-summary-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
    font-size: 0.88rem;
    font-weight: 500;
}

.cart-summary-discount {
    color: #059669;
    font-weight: 700;
}

.cart-summary-total {
    display: flex;
    justify-content: space-between;
    margin-bottom: 18px;
    font-size: 1.2rem;
    font-weight: 700;
}

.cart-checkout-btn {
    width: 100%;
    background: var(--market-primary);
    color: white;
    border: none;
    padding: 14px;
    border-radius: 30px;
    font-size: 0.98rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 6px 16px rgba(255, 107, 53, 0.25);
}

.cart-checkout-btn:hover {
    background: var(--market-primary-hover);
    transform: translateY(-2px);
}

.empty-cart-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    text-align: center;
    color: var(--market-text-muted);
}

.empty-cart-state svg {
    width: 56px;
    height: 56px;
    margin-bottom: 16px;
    opacity: 0.4;
}

.empty-cart-benefit {
    max-width: 360px;
    margin-top: 12px;
    color: #059669;
    font-size: 0.92rem;
    font-weight: 700;
    line-height: 1.45;
}

/* ==========================================================================
   Product Detail Modal / Redesigned Premium Center Card
   ========================================================================== */
.detail-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(8px);
    z-index: 10600;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.35s cubic-bezier(0.25, 0.8, 0.25, 1);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.detail-modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.detail-modal-card {
    background: var(--market-bg-card);
    width: 100%;
    max-width: 820px; /* Increased for side-by-side layout */
    border-radius: 28px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 30px 60px rgba(0,0,0,0.18);
    transform: translateY(40px);
    transition: transform 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
    max-height: 85vh;
    display: flex;
    flex-direction: column;
    border: 1px solid var(--market-border);
}

.detail-modal-overlay.active .detail-modal-card {
    transform: translateY(0);
}

.detail-close-btn {
    position: absolute;
    top: 18px;
    right: 18px;
    background: var(--market-bg-card);
    border: 1.5px solid var(--market-border);
    width: 38px;
    height: 38px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 100;
    box-shadow: 0 4px 12px rgba(0,0,0,0.06);
    color: var(--market-text-main);
    transition: all 0.25s ease;
}

.detail-close-btn:hover {
    background: var(--market-primary-light);
    border-color: var(--market-primary);
    color: var(--market-primary);
    transform: scale(1.08);
}

/* Premium Side-by-Side Responsive Grid */
.detail-modal-grid {
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 100%;
}

@media(min-width: 768px) {
    .detail-modal-grid {
        flex-direction: row;
        min-height: 520px;
    }
}

.detail-modal-left {
    width: 100%;
    background: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

@media(min-width: 768px) {
    .detail-modal-left {
        width: 48%;
        border-right: 1.5px solid var(--market-border);
    }
}

.detail-modal-right {
    width: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

@media(min-width: 768px) {
    .detail-modal-right {
        width: 52%;
    }
}

/* Image Slider inside left panel */
.detail-image-slider {
    position: relative;
    width: 100%;
    aspect-ratio: 1.1;
    background: #ffffff;
    overflow: hidden;
}

.slider-track {
    display: flex;
    width: 100%;
    height: 100%;
}

.slider-slide {
    min-width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: #ffffff;
}

.slider-slide img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.slider-dot-container {
    position: absolute;
    bottom: 16px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 6px;
    z-index: 5;
}

.slider-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.15);
    cursor: pointer;
    transition: all 0.2s ease;
}

.slider-dot.active {
    background: var(--market-primary);
    width: 16px;
    border-radius: 4px;
}

/* Details Content Area - Right Panel */
.detail-content {
    padding: 30px;
    flex-grow: 1;
    overflow-y: auto;
    max-height: 380px; /* ensure description section scrolls when long on desktop */
}

@media(min-width: 768px) {
    .detail-content {
        max-height: 440px;
    }
}

.detail-header {
    margin-bottom: 20px;
}

.detail-vendor-name {
    font-size: 0.84rem;
    font-weight: 700;
    color: var(--market-primary);
    margin-bottom: 8px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    text-decoration: none;
    position: relative;
    z-index: 2;
}

.detail-vendor-name:hover {
    text-decoration: underline;
}

.detail-vendor-name svg {
    flex-shrink: 0;
}

.detail-title {
    font-size: 1.4rem;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 12px;
    color: var(--market-text-main);
}

.detail-price {
    color: var(--market-brand);
    font-size: 1.4rem;
    font-weight: 900;
    margin-bottom: 12px;
}

/* Stock Status tag */
.stock-badge {
    display: inline-flex;
    align-items: center;
    padding: 5px 12px;
    border-radius: 30px;
    font-size: 0.75rem;
    font-weight: 600;
}

.stock-badge.in-stock {
    background: rgba(16, 185, 129, 0.1);
    color: var(--market-success);
}

.stock-badge.out-of-stock {
    background: rgba(255, 59, 48, 0.1);
    color: var(--market-error);
}

.detail-page-link {
    margin-top: 12px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--market-primary);
    font-size: 0.84rem;
    font-weight: 700;
    text-decoration: none;
}

.detail-page-link:hover {
    text-decoration: underline;
}

.detail-page-link svg {
    flex-shrink: 0;
}

.detail-description-wrapper {
    margin-top: 20px;
    border-top: 1.5px solid var(--market-border);
    padding-top: 18px;
}

.detail-description-title {
    font-size: 0.92rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--market-text-main);
}

.detail-description {
    font-size: 0.88rem;
    line-height: 1.6;
    color: var(--market-text-muted);
}

/* Footer Control Bar - Right Panel Bottom */
.detail-footer-bar {
    padding: 20px 30px;
    border-top: 1.5px solid var(--market-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--market-bg-card);
    gap: 16px;
    flex-shrink: 0;
}

.detail-buy-btn {
    flex-grow: 1;
    background: var(--market-primary);
    color: white;
    border: none;
    padding: 14px 24px;
    border-radius: 30px;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 6px 20px rgba(255, 107, 53, 0.25);
    transition: all 0.3s ease;
}

.detail-buy-btn:hover {
    background: var(--market-primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(255, 107, 53, 0.35);
}

.detail-buy-btn:active {
    transform: translateY(0);
}

.detail-btn-divider {
    width: 1.5px;
    height: 18px;
    background: rgba(255, 255, 255, 0.4);
    margin: 0 16px;
}

/* ==========================================================================
   Checkout Wizard Modal & Checkout State Machine
   ========================================================================== */
.checkout-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(4px);
    z-index: 10700;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.checkout-modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.checkout-modal {
    background: var(--market-bg-card);
    width: 100%;
    max-width: 680px;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(0,0,0,0.15);
    transform: scale(0.95);
    transition: transform 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    max-height: 90vh;
    display: flex;
    flex-direction: column;
}

.checkout-modal-overlay.active .checkout-modal {
    transform: scale(1);
}

.checkout-header {
    padding: 20px 24px;
    border-bottom: 1.5px solid var(--market-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.checkout-header h3 {
    font-size: 1.25rem;
    font-weight: 700;
}

/* Step Progress Indicator */
.checkout-steps-tracker {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    padding: 14px 24px;
    background: var(--market-bg);
    border-bottom: 1.5px solid var(--market-border);
    overflow-x: auto;
}

.step-indicator-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--market-text-muted);
    flex-shrink: 0;
}

.step-indicator-item.active {
    color: var(--market-primary);
}

.step-indicator-item.completed {
    color: var(--market-success);
}

.step-num {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: rgba(0,0,0,0.06);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.72rem;
}

.step-indicator-item.active .step-num {
    background: var(--market-primary);
    color: white;
}

.step-indicator-item.completed .step-num {
    background: var(--market-success);
    color: white;
}

.checkout-body {
    flex-grow: 1;
    overflow-y: auto;
    padding: 24px;
}

.checkout-step-panel {
    display: none;
}

.checkout-step-panel.active {
    display: block;
}

.mobile-otp-step {
    max-width: 520px;
    margin: 0 auto;
    padding: 8px 0 4px;
}

.checkout-footer-bar {
    padding: 18px 24px;
    border-top: 1.5px solid var(--market-border);
    display: flex;
    justify-content: space-between;
    background: var(--market-bg-card);
}

.checkout-footer-bar button {
    padding: 12px 24px;
    border-radius: 30px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 0.92rem;
}

.btn-checkout-prev {
    background: transparent;
    border: 1.5px solid var(--market-border);
    color: var(--market-text-main);
}

.btn-checkout-prev:hover {
    background: var(--market-bg-light);
}

.btn-checkout-next {
    background: var(--market-primary);
    border: none;
    color: white;
    box-shadow: 0 4px 12px rgba(255, 107, 53, 0.15);
}

.btn-checkout-next:hover {
    background: var(--market-primary-hover);
    transform: translateY(-1px);
}

/* Step 1 & 2 Address Cards */
.address-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
    margin-bottom: 24px;
}

@media(min-width: 600px) {
    .address-grid {
        grid-template-columns: 1fr 1fr;
    }
}

.address-card {
    background: var(--market-bg-card);
    border: 2px solid var(--market-border);
    border-radius: 16px;
    padding: 16px;
    cursor: pointer;
    position: relative;
    transition: all 0.25s ease;
    display: flex;
    flex-direction: column;
}

.address-card:hover {
    border-color: rgba(255,107,53, 0.3);
}

.address-card.selected {
    border-color: var(--market-primary);
    background: var(--market-primary-light);
}

.address-card-header {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    margin-bottom: 8px;
    font-size: 0.9rem;
}

.address-card-body {
    font-size: 0.8rem;
    line-height: 1.45;
    color: var(--market-text-muted);
    flex-grow: 1;
}

.address-card-warning {
    margin-top: 8px;
    color: #ef4444;
    font-weight: 600;
}

.address-card-edit-btn {
    position: absolute;
    top: 14px;
    right: 14px;
    background: transparent;
    border: none;
    color: var(--market-primary);
    font-size: 0.78rem;
    font-weight: 600;
    cursor: pointer;
}

.address-card-edit-btn:hover {
    text-decoration: underline;
}

.add-address-card {
    border: 2px dashed var(--market-border);
    background: transparent;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    border-radius: 16px;
    cursor: pointer;
    transition: all 0.2s;
    color: var(--market-text-muted);
}

.add-address-card:hover {
    border-color: var(--market-primary);
    color: var(--market-primary);
}

/* Address Drawer / Inline Form */
.address-form-wrapper {
    background: var(--market-bg);
    border: 1.5px solid var(--market-border);
    border-radius: 16px;
    padding: 18px;
    margin-top: 16px;
    display: none;
}

.address-form-wrapper.active {
    display: block;
    animation: slide-down-form 0.3s ease-out;
}

@keyframes slide-down-form {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
}

@media(min-width: 600px) {
    .form-grid {
        grid-template-columns: 1fr 1fr;
    }
}

.market-form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

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

.market-form-group label {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--market-text-muted);
}

.market-form-group input, .market-form-group textarea, .market-form-group select {
    background: var(--market-bg-card);
    border: 1.5px solid var(--market-border);
    padding: 9px 12px;
    border-radius: 10px;
    font-size: 0.85rem;
    color: var(--market-text-main);
    width: 100%;
}

.market-form-group input:focus, .market-form-group textarea:focus, .market-form-group select:focus {
    border-color: var(--market-primary);
    outline: none;
}

.address-form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 16px;
}

.address-form-actions button {
    padding: 8px 18px;
    border-radius: 20px;
    font-weight: 600;
    cursor: pointer;
    font-size: 0.82rem;
}

.btn-cancel-address {
    background: transparent;
    border: 1px solid var(--market-border);
    color: var(--market-text-main);
}

.btn-save-address {
    background: var(--market-primary);
    border: none;
    color: white;
}

/* Step 3 - Payment Details (Interactive Card View) */
.payment-grid-wrapper {
    display: flex;
    flex-direction: column;
    gap: 20px;
    align-items: center;
    width: 100%;
}

@media(min-width: 600px) {
    .payment-grid-wrapper {
        flex-direction: row;
        align-items: flex-start;
    }
}

/* Premium Orange/Gold Gradient Mockup Card */
.credit-card-mockup {
    width: 300px;
    height: 180px;
    background: linear-gradient(135deg, #FF6B35 0%, #FF8552 40%, #E04E1B 100%);
    border-radius: 18px;
    box-shadow: 0 12px 28px rgba(255, 107, 53, 0.22);
    padding: 22px;
    color: white;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    overflow: hidden;
    flex-shrink: 0;
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.credit-card-mockup::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.04) 0%, transparent 68%);
    pointer-events: none;
}

.cc-mock-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.cc-mock-chip {
    width: 36px;
    height: 26px;
    background: linear-gradient(135deg, #eed885 0%, #ca9b2c 100%);
    border-radius: 4px;
}

.cc-mock-brand {
    font-weight: 700;
    font-style: italic;
    font-size: 1.05rem;
    letter-spacing: 0.8px;
}

.cc-mock-number {
    font-size: 1.15rem;
    letter-spacing: 2px;
    font-family: 'Courier New', Courier, monospace;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.4);
    margin: 18px 0;
}

.cc-mock-footer {
    display: flex;
    justify-content: space-between;
    font-size: 0.72rem;
}

.cc-mock-holder-label, .cc-mock-expiry-label {
    text-transform: uppercase;
    color: rgba(255,255,255,0.35);
    margin-bottom: 2px;
}

.cc-mock-holder-val, .cc-mock-expiry-val {
    font-weight: 500;
    font-size: 0.8rem;
    letter-spacing: 0.8px;
}

.payment-form-inputs {
    flex-grow: 1;
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.paytr-copy {
    margin: 0 0 18px;
    color: var(--market-muted);
    font-weight: 500;
    line-height: 1.55;
}

.paytr-frame-shell {
    height: min(980px, calc(100vh - 250px));
    min-height: 620px;
    overflow: auto;
    -webkit-overflow-scrolling: touch;
    border: 1px solid var(--market-border);
    border-radius: 22px;
    background: #fff;
}

.paytr-loading,
.paytr-error {
    min-height: 320px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 28px;
    text-align: center;
    color: var(--market-muted);
    font-weight: 700;
}

.paytr-error strong {
    color: var(--market-text-main);
    font-size: 1.05rem;
}

.paytr-error button {
    border: 0;
    border-radius: 999px;
    background: var(--market-primary);
    color: #fff;
    padding: 12px 20px;
    font-weight: 800;
    cursor: pointer;
}

.paytr-discount-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
    border: 1px solid #bbf7d0;
    border-radius: 14px;
    background: #ecfdf5;
    color: #047857;
    padding: 12px 14px;
    font-size: 14px;
    font-weight: 800;
}

.paytr-discount-info span {
    color: #065f46;
    font-weight: 900;
}

/* Step 4: Order Summary and Final Pricing breakdown */
.summary-section {
    border: 1.5px solid var(--market-border);
    border-radius: 16px;
    padding: 16px;
    margin-bottom: 16px;
    background: var(--market-bg);
}

.summary-section-title {
    font-size: 0.9rem;
    font-weight: 700;
    margin-bottom: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.summary-section-link {
    color: var(--market-primary);
    font-size: 0.78rem;
    cursor: pointer;
    font-weight: 600;
    text-decoration: none;
}

.summary-section-link:hover {
    text-decoration: underline;
}

.summary-info-text {
    font-size: 0.82rem;
    line-height: 1.45;
    color: var(--market-text-muted);
}

.summary-product-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.summary-product-item {
    display: flex;
    justify-content: space-between;
    font-size: 0.82rem;
}

.summary-product-name {
    color: var(--market-text-main);
    font-weight: 500;
}

.summary-product-qty-price {
    color: var(--market-text-muted);
}

/* Success View */
.checkout-success-view {
    text-align: center;
    padding: 30px 10px;
}

.success-icon-box {
    width: 64px;
    height: 64px;
    background: rgba(16, 185, 129, 0.1);
    color: var(--market-success);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px auto;
}

.success-icon-box svg {
    width: 32px;
    height: 32px;
}

.checkout-success-view h3 {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 10px;
}

.checkout-success-view p {
    font-size: 0.88rem;
    color: var(--market-text-muted);
    line-height: 1.55;
    margin-bottom: 20px;
}

/* ==========================================================================
   Skeleton Loading Animation Styles
   ========================================================================== */
.skeleton-card {
    background: var(--market-bg-card);
    border: 1.5px solid var(--market-border);
    border-radius: 20px;
    overflow: hidden;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.skeleton-image {
    width: 100%;
    aspect-ratio: 1;
    border-radius: 12px;
    background: var(--market-bg);
}

.skeleton-text {
    height: 14px;
    background: var(--market-bg);
    border-radius: 4px;
}

.skeleton-text.short {
    width: 40%;
}

.skeleton-text.medium {
    width: 70%;
}

.skeleton-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
}

.skeleton-price {
    height: 20px;
    width: 80px;
    background: var(--market-bg);
    border-radius: 6px;
}

.skeleton-btn {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: var(--market-bg);
}

/* Pulsating Animation */
.skeleton-pulse {
    animation: skeleton-pulse 1.4s ease-in-out infinite;
    background: linear-gradient(
        90deg,
        rgba(0, 0, 0, 0.06) 25%,
        rgba(0, 0, 0, 0.12) 37%,
        rgba(0, 0, 0, 0.06) 63%
    );
    background-size: 400% 100%;
}

[data-theme="dark"] .skeleton-pulse {
    background: linear-gradient(
        90deg,
        rgba(255, 255, 255, 0.03) 25%,
        rgba(255, 255, 255, 0.08) 37%,
        rgba(255, 255, 255, 0.03) 63%
    );
    background-size: 400% 100%;
}

@keyframes skeleton-pulse {
    0% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0 50%;
    }
}

/* ==========================================================================
   Order History & Return Request Modals  (compact e-commerce style)
   ========================================================================== */

/* Shared overlay + modal shell */
.orders-modal-overlay,
.return-modal-overlay {
    position: fixed; inset: 0;
    background: rgba(0,0,0,.45); backdrop-filter: blur(3px);
    z-index: 10750; opacity: 0; pointer-events: none;
    transition: opacity .25s ease;
    display: flex; align-items: center; justify-content: center; padding: 16px;
}
.orders-modal-overlay.active,
.return-modal-overlay.active { opacity: 1; pointer-events: auto; }

.orders-modal,
.return-modal {
    background: var(--market-bg-card); color: var(--market-text-main);
    width: 100%; max-width: 640px; border-radius: 14px; overflow: hidden;
    box-shadow: 0 16px 40px rgba(0,0,0,.2);
    transform: translateY(12px); transition: transform .25s ease;
    max-height: 88vh; display: flex; flex-direction: column;
}
.orders-modal-overlay.active .orders-modal,
.return-modal-overlay.active .return-modal { transform: translateY(0); }

/* Headers */
.orders-modal-header,
.return-modal-header {
    padding: 16px 20px; border-bottom: 1px solid var(--market-border);
    display: flex; align-items: center; gap: 12px;
    flex-shrink: 0;
}
.orders-modal-heading h3,
.return-modal-heading h3 { font-size: 1.1rem; font-weight: 700; margin: 0; }
.orders-modal-heading p,
.return-modal-heading p { font-size: .78rem; color: var(--market-text-muted); margin: 1px 0 0; }
.orders-modal-heading, .return-modal-heading { flex: 1; }

.return-back-btn {
    width: 34px; height: 34px; flex-shrink: 0; border-radius: 8px;
    border: 1px solid var(--market-border); background: transparent; color: var(--market-text-main);
    display: flex; align-items: center; justify-content: center; cursor: pointer; transition: all .2s;
}
.return-back-btn:hover { border-color: var(--market-primary); color: var(--market-primary); }

/* Orders modal */
.orders-modal { max-width: 580px; }
.orders-modal-heading h3 { font-size: 1.2rem; }
.orders-modal-body { padding: 16px; }

.orders-modal-header .cart-close-btn,
.return-modal-header .cart-close-btn {
    width: 36px; height: 36px; flex-shrink: 0; border-radius: 9px;
    border: 1px solid var(--market-border); background: var(--market-bg);
    color: var(--market-text-main);
    display: flex; align-items: center; justify-content: center;
    cursor: pointer; transition: border-color .2s, color .2s;
}
.orders-modal-header .cart-close-btn:hover,
.return-modal-header .cart-close-btn:hover { border-color: var(--market-primary); color: var(--market-primary); }

/* Scroll bodies */
.orders-modal-body,
.return-modal-body { flex-grow: 1; overflow-y: auto; padding: 20px; }

/* ===== VENDOR DETAIL MODAL ===== */
.vendor-detail-modal { max-width: 720px; }

.vendor-banner {
    display: flex;
    align-items: center;
    gap: 16px;
    background: #FFF5F0;
    border-bottom: 1px solid #FFE8DC;
    padding: 20px;
}

.vendor-banner-avatar {
    width: 72px;
    height: 72px;
    flex-shrink: 0;
    border-radius: 50%;
    background: #FFFFFF;
    border: 2px solid var(--market-primary);
    color: var(--market-primary);
    display: flex;
    align-items: center;
    justify-content: center;
}

.vendor-banner-info {
    min-width: 0;
}

.vendor-banner-name {
    font-size: 1.05rem;
    font-weight: 800;
    color: var(--market-text-main);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.vendor-banner-location {
    display: flex;
    align-items: center;
    gap: 5px;
    margin-top: 5px;
    color: var(--market-text-muted);
    font-size: 0.78rem;
    font-weight: 500;
}

.vendor-search-wrapper {
    position: relative;
    padding: 16px 20px 0;
}

.vendor-search-input {
    width: 100%;
    background: var(--market-bg);
    border: 1.5px solid var(--market-border);
    padding: 11px 44px 11px 16px;
    border-radius: 12px;
    font-size: 0.88rem;
    color: var(--market-text-main);
}

.vendor-search-input:focus {
    border-color: var(--market-primary);
    outline: none;
}

.vendor-search-btn {
    position: absolute;
    right: 28px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    color: var(--market-text-muted);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.vendor-search-btn:hover {
    color: var(--market-primary);
}

/* ===== FILTER PANEL (Filtrele) ===== */
.filter-panel-overlay {
    position: fixed; inset: 0;
    background: rgba(20,10,5,.5); backdrop-filter: blur(4px);
    z-index: 10800; opacity: 0; pointer-events: none;
    transition: opacity .25s ease;
    display: flex; align-items: center; justify-content: center; padding: 16px;
}
.filter-panel-overlay.active { opacity: 1; pointer-events: auto; }

.filter-panel {
    background: var(--market-bg-card); color: var(--market-text-main);
    width: 100%; max-width: 440px; border-radius: 24px; overflow: hidden;
    box-shadow: 0 24px 60px rgba(255, 107, 53, .22), 0 8px 20px rgba(0,0,0,.12);
    transform: translateY(16px) scale(.98); transition: transform .28s cubic-bezier(.22,1,.36,1);
    max-height: 88vh; display: flex; flex-direction: column;
}
.filter-panel-overlay.active .filter-panel { transform: translateY(0) scale(1); }

.filter-panel-header {
    padding: 18px 22px;
    background: linear-gradient(135deg, var(--market-primary) 0%, #FF8A5C 100%);
    display: flex; align-items: center; justify-content: space-between;
    flex-shrink: 0;
}
.filter-panel-header h3 {
    font-size: 1.15rem; font-weight: 800; margin: 0; color: white;
    display: flex; align-items: center; gap: 10px;
}
.filter-panel-header h3::before {
    content: '';
    width: 32px; height: 32px; border-radius: 10px;
    background: rgba(255,255,255,.22);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2.5'%3E%3Cline x1='4' y1='21' x2='4' y2='14'/%3E%3Cline x1='4' y1='10' x2='4' y2='3'/%3E%3Cline x1='12' y1='21' x2='12' y2='12'/%3E%3Cline x1='12' y1='8' x2='12' y2='3'/%3E%3Cline x1='20' y1='21' x2='20' y2='16'/%3E%3Cline x1='20' y1='12' x2='20' y2='3'/%3E%3Cline x1='1' y1='14' x2='7' y2='14'/%3E%3Cline x1='9' y1='8' x2='15' y2='8'/%3E%3Cline x1='17' y1='16' x2='23' y2='16'/%3E%3C/svg%3E");
    background-repeat: no-repeat; background-position: center; background-size: 17px;
}
.filter-panel-header .cart-close-btn {
    background: rgba(255,255,255,.18); border: none; color: white;
}
.filter-panel-header .cart-close-btn:hover { background: rgba(255,255,255,.32); color: white; }

.filter-panel-body {
    flex-grow: 1; overflow-y: auto; padding: 20px;
    display: flex; flex-direction: column; gap: 14px;
    background: var(--market-bg);
}

.filter-panel-footer {
    padding: 16px 20px; border-top: 1px solid var(--market-border);
    background: var(--market-bg-card);
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
    flex-shrink: 0;
}

.filter-field-row {
    display: flex; align-items: center; justify-content: space-between;
    background: var(--market-bg-card); border: 1.5px solid var(--market-border);
    border-radius: 16px; padding: 14px 16px;
}

.filter-field-label {
    font-size: 0.85rem; font-weight: 700; color: var(--market-text-main);
    margin-bottom: 10px;
}
.filter-field-row .filter-field-label { margin-bottom: 0; }

.filter-field-group {
    display: flex; flex-direction: column;
    background: var(--market-bg-card); border: 1.5px solid var(--market-border);
    border-radius: 16px; padding: 14px 16px;
}

/* iOS-style switch, brand-tinted track when off so it doesn't read as "disabled" */
.filter-switch {
    width: 44px; height: 26px; border-radius: 13px; border: none;
    background: var(--market-primary-light); position: relative; cursor: pointer;
    transition: background-color .2s ease; flex-shrink: 0;
}
.filter-switch::after {
    content: ''; position: absolute; top: 2px; left: 2px;
    width: 22px; height: 22px; border-radius: 50%; background: white;
    box-shadow: 0 2px 4px rgba(0,0,0,.2);
    transition: transform .2s cubic-bezier(.22,1,.36,1);
}
.filter-switch.active {
    background: var(--market-primary);
    box-shadow: 0 2px 8px rgba(255,107,53,.4);
}
.filter-switch.active::after { transform: translateX(18px); }

.filter-price-range {
    display: flex; align-items: center; gap: 10px;
}
.filter-price-input {
    flex: 1; min-width: 0;
    background: var(--market-bg); border: 1.5px solid var(--market-border);
    border-radius: 12px; padding: 10px 13px; font-size: 0.85rem; font-weight: 600;
    color: var(--market-text-main); transition: border-color .18s ease, box-shadow .18s ease;
}
.filter-price-input:focus {
    border-color: var(--market-primary); outline: none;
    box-shadow: 0 0 0 3px var(--market-primary-light);
}
.filter-price-sep {
    color: var(--market-primary); font-weight: 700; flex-shrink: 0;
}

.filter-text-input {
    background: var(--market-bg); border: 1.5px solid var(--market-border);
    border-radius: 12px; padding: 10px 13px; font-size: 0.85rem;
    color: var(--market-text-main); width: 100%;
    transition: border-color .18s ease, box-shadow .18s ease;
}
.filter-text-input:focus {
    border-color: var(--market-primary); outline: none;
    box-shadow: 0 0 0 3px var(--market-primary-light);
}

.filter-chip-row {
    display: flex; flex-wrap: wrap; gap: 7px;
}

.filter-option-chip {
    display: inline-flex; align-items: center; gap: 5px;
    background: var(--market-bg); border: 1.5px solid var(--market-border);
    border-radius: 18px; padding: 8px 14px;
    font-size: 0.78rem; font-weight: 600; color: var(--market-text-main);
    cursor: pointer; transition: all .18s ease;
}
.filter-option-chip:hover:not(.active) {
    border-color: var(--market-primary);
    color: var(--market-primary);
}
.filter-option-chip.active {
    background: linear-gradient(135deg, var(--market-primary) 0%, #FF8A5C 100%);
    border-color: var(--market-primary);
    color: white;
    font-weight: 700;
    box-shadow: 0 4px 10px rgba(255,107,53,.3);
}

.btn-filter-clear {
    background: transparent; border: none;
    color: var(--market-text-muted); border-radius: 10px;
    padding: 10px 6px; font-size: 0.85rem; font-weight: 700; cursor: pointer;
    text-decoration: underline; text-underline-offset: 3px;
}
.btn-filter-clear:hover { color: var(--market-primary); }

/* ===== ORDER TABS ===== */
.orders-tabs {
    display: flex; gap: 4px; padding: 10px 16px 0;
    border-bottom: 1px solid var(--market-border);
    overflow-x: auto; overflow-y: hidden;
    flex-shrink: 0;                 /* never let the flex column squeeze tab labels */
    min-height: 44px;
    scrollbar-width: none;          /* Firefox: hide scrollbar so it doesn't clip labels */
    -ms-overflow-style: none;
}
.orders-tabs::-webkit-scrollbar { display: none; }
.orders-tab {
    flex: 0 0 auto;
    border: none; background: transparent;
    font-family: 'Poppins', sans-serif; font-size: .82rem; font-weight: 600;
    line-height: 1.6; color: var(--market-text-muted);
    padding: 8px 12px 11px; margin-bottom: -1px;
    border-bottom: 2px solid transparent; cursor: pointer; white-space: nowrap;
    transition: color .2s, border-color .2s;
}
.orders-tab:hover { color: var(--market-text-main); }
.orders-tab.active { color: var(--market-primary); border-bottom-color: var(--market-primary); }

/* ===== ORDER CARD ===== */
.order-card {
    background: var(--market-bg-card); border: 1px solid var(--market-border);
    border-radius: 14px; padding: 16px; margin-bottom: 14px;
}
.order-card:last-child { margin-bottom: 0; }

.oc-head {
    display: flex; align-items: center; justify-content: space-between; gap: 10px;
    padding-bottom: 8px;
}
.oc-head-status { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; min-width: 0; }
.oc-date { font-size: .8rem; color: var(--market-text-muted); }
.oc-title-block { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.oc-head-total { flex-shrink: 0; font-size: .98rem; color: var(--market-text-main); }
.oc-status-row {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--market-border);
}
.oc-packages { font-size: .76rem; color: var(--market-text-muted); font-weight: 600; }

.order-status {
    display: inline-flex; align-items: center; gap: 6px;
    font-size: .74rem; font-weight: 700; padding: 5px 11px;
    border-radius: 30px; white-space: nowrap;
}
.order-status svg { width: 14px; height: 14px; }
.status-delivered { color: var(--market-success); background: rgba(16,185,129,.12); }
.status-shipped   { color: var(--market-primary); background: var(--market-primary-light); }
.status-preparing { color: var(--market-primary); background: var(--market-primary-light); }
.status-cancelled { color: var(--market-error); background: rgba(255,59,48,.12); }

.oc-products { padding: 14px 0; display: flex; flex-direction: column; gap: 12px; }
.oc-product {
    display: flex;
    align-items: center;
    gap: 12px;
    border-radius: 12px;
    padding: 6px;
    margin: -6px;
}
.oc-product.clickable {
    cursor: pointer;
    transition: background-color .18s ease, transform .18s ease;
}
.oc-product.clickable:hover {
    background: #fff7f3;
}
.oc-product.clickable:active {
    transform: scale(.995);
}
.oc-product-img {
    width: 50px; height: 50px; border-radius: 9px; object-fit: cover;
    border: 1px solid var(--market-border); background: var(--market-bg-sidebar); flex-shrink: 0;
}
.oc-product-img-fallback {
    display: flex; align-items: center; justify-content: center;
    color: var(--market-text-muted);
}
.oc-product-info { flex: 1; min-width: 0; }
.oc-product-name { font-size: .86rem; font-weight: 600; color: var(--market-text-main); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.oc-product-sub { font-size: .76rem; color: var(--market-text-muted); margin-top: 2px; }
.oc-more { font-size: .78rem; color: var(--market-primary); font-weight: 600; padding-left: 62px; }
.oc-cargo-status {
    margin: 0 0 12px;
    padding: 9px 12px;
    border-radius: 12px;
    background: var(--market-primary-light);
    color: var(--market-primary);
    font-size: .78rem;
    font-weight: 600;
}
.oc-cargo-status strong { color: var(--market-primary); }

.oc-foot {
    display: flex; align-items: center; justify-content: flex-end; gap: 12px;
    padding-top: 14px; border-top: 1px solid var(--market-border); flex-wrap: wrap;
}
.oc-meta { display: flex; flex-direction: column; gap: 3px; }
.oc-no { font-size: .9rem; color: var(--market-text-main); font-weight: 800; }
.oc-total { font-size: .82rem; color: var(--market-text-muted); }
.oc-total strong { font-size: .98rem; color: var(--market-text-main); }

.oc-actions { display: flex; gap: 8px; }
.oc-btn {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 8px 14px; border-radius: 9px;
    font-family: 'Poppins', sans-serif; font-size: .8rem; font-weight: 600; cursor: pointer;
    white-space: nowrap; transition: all .2s;
}
.oc-btn svg { width: 14px; height: 14px; }
.oc-btn-ghost { background: transparent; color: var(--market-text-main); border: 1.5px solid var(--market-border); }
.oc-btn-ghost:hover { border-color: var(--market-primary); color: var(--market-primary); }
.oc-btn-primary { background: transparent; color: var(--market-primary); border: 1.5px solid var(--market-primary); }
.oc-btn-primary:hover { background: var(--market-primary); color: #fff; }
.oc-btn-return { background: #DDF7E8; color: #117A45; border: 1.5px solid #A7E8C1; }
.oc-btn-return:hover { background: #C5F0D7; border-color: #87DDAA; color: #0F6B3D; }
.oc-btn-return svg { stroke: currentColor; }

.orders-empty-state { text-align: center; padding: 44px 20px; color: var(--market-text-muted); }
.orders-empty-state svg { width: 46px; height: 46px; stroke: var(--market-text-muted); opacity: .5; margin-bottom: 12px; }

/* ===== RETURN REQUEST CARDS (İade Taleplerim) ===== */
.rr-body { padding-top: 12px; }
.rr-product-name { font-size: .9rem; font-weight: 700; color: var(--market-text-main); margin-bottom: 4px; }
.rr-meta { font-size: .78rem; color: var(--market-text-muted); margin-bottom: 8px; }
.rr-reason { font-size: .82rem; color: var(--market-text-main); margin-bottom: 4px; }
.rr-reason strong { font-weight: 600; }
.rr-desc { font-size: .8rem; color: var(--market-text-muted); margin-bottom: 8px; font-style: italic; }
.rr-cargo-box {
    margin: 10px 0 12px;
    border: 1px solid #bbf7d0;
    border-radius: 12px;
    background: #f0fdf4;
    padding: 11px 13px;
}
.rr-cargo-label {
    font-size: .68rem;
    font-weight: 800;
    letter-spacing: .04em;
    text-transform: uppercase;
    color: #15803d;
}
.rr-cargo-company {
    margin-top: 5px;
    font-size: .86rem;
    font-weight: 800;
    color: #14532d;
}
.rr-cargo-barcode {
    margin-top: 4px;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
    font-size: 1.1rem;
    font-weight: 800;
    letter-spacing: .08em;
    color: var(--market-text-main);
}
.rr-cargo-message {
    margin-top: 4px;
    font-size: .78rem;
    font-weight: 600;
    line-height: 1.45;
    color: #166534;
}
.rr-photos { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.rr-photos img {
    width: 56px; height: 56px; border-radius: 8px; object-fit: cover;
    border: 1px solid var(--market-border); cursor: pointer; transition: transform .15s;
}
.rr-photos img:hover { transform: scale(1.05); }

/* ===== CARGO TRACKING MODAL ===== */
.tracking-modal-overlay {
    position: fixed; inset: 0;
    background: rgba(0,0,0,.45); backdrop-filter: blur(3px);
    z-index: 10760; opacity: 0; pointer-events: none;
    transition: opacity .25s ease;
    display: flex; align-items: center; justify-content: center; padding: 16px;
}
.tracking-modal-overlay.active { opacity: 1; pointer-events: auto; }
.tracking-modal {
    background: var(--market-bg-card); color: var(--market-text-main);
    width: 100%; max-width: 560px; border-radius: 14px; overflow: hidden;
    box-shadow: 0 16px 40px rgba(0,0,0,.2);
    transform: translateY(12px); transition: transform .25s ease;
    max-height: 88vh; display: flex; flex-direction: column;
}
.tracking-modal-overlay.active .tracking-modal { transform: translateY(0); }
.tracking-modal-header {
    padding: 16px 20px; border-bottom: 1px solid var(--market-border);
    display: flex; align-items: center; gap: 12px;
}
.tracking-modal-body { flex-grow: 1; overflow-y: auto; padding: 20px; }

.trk-summary { border: 1px solid var(--market-border); border-radius: 12px; padding: 14px 16px; margin-bottom: 24px; }
.trk-summary-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 5px 0; }
.trk-summary-label { font-size: .8rem; color: var(--market-text-muted); }
.trk-summary-val { font-size: .85rem; font-weight: 600; color: var(--market-text-main); }
.trk-tracking-no { display: inline-flex; align-items: center; gap: 8px; }
.trk-copy { border: none; background: transparent; cursor: pointer; color: var(--market-text-muted); padding: 2px; display: inline-flex; }
.trk-copy svg { width: 15px; height: 15px; }
.trk-copy:hover { color: var(--market-primary); }
.trk-ext-link { display: inline-block; margin-top: 8px; font-size: .82rem; font-weight: 600; color: var(--market-primary); text-decoration: none; }
.trk-ext-link:hover { text-decoration: underline; }

/* Stepper */
.trk-stepper { display: flex; align-items: flex-start; margin-bottom: 26px; }
.trk-step { display: flex; flex-direction: column; align-items: center; gap: 7px; flex-shrink: 0; width: 60px; }
.trk-dot { width: 16px; height: 16px; border-radius: 50%; border: 2px solid var(--market-border); background: var(--market-bg-card); }
.trk-step-label { font-size: .66rem; text-align: center; color: var(--market-text-muted); line-height: 1.2; }
.trk-line { flex: 1; height: 2px; background: var(--market-border); margin-top: 7px; }
.trk-done .trk-dot { background: var(--market-success); border-color: var(--market-success); }
.trk-done .trk-step-label { color: var(--market-text-main); }
.trk-current .trk-dot { background: var(--market-primary); border-color: var(--market-primary); box-shadow: 0 0 0 4px var(--market-primary-light); }
.trk-current .trk-step-label { color: var(--market-primary); font-weight: 700; }

/* Timeline */
.trk-timeline-title { font-size: .9rem; font-weight: 700; margin-bottom: 14px; }
.trk-timeline { position: relative; }
.trk-event { display: flex; gap: 14px; position: relative; padding-bottom: 18px; }
.trk-event:last-child { padding-bottom: 0; }
.trk-event-dot { width: 11px; height: 11px; border-radius: 50%; background: var(--market-border); flex-shrink: 0; margin-top: 3px; position: relative; z-index: 1; }
.trk-event.latest .trk-event-dot { background: var(--market-primary); box-shadow: 0 0 0 4px var(--market-primary-light); }
.trk-event::before { content: ''; position: absolute; left: 5px; top: 14px; bottom: -4px; width: 2px; background: var(--market-border); }
.trk-event:last-child::before { display: none; }
.trk-event-label { font-size: .85rem; font-weight: 600; color: var(--market-text-main); }
.trk-event.latest .trk-event-label { color: var(--market-primary); }
.trk-event-meta { font-size: .76rem; color: var(--market-text-muted); margin-top: 2px; }

/* ===== RETURN FORM (compact) ===== */
.return-info-line { font-size: .82rem; color: var(--market-text-muted); margin: 0 0 18px; line-height: 1.5; }
.return-block { margin-bottom: 22px; }
.return-block:last-child { margin-bottom: 0; }
.return-block-title { font-size: .82rem; font-weight: 700; margin: 0 0 10px; color: var(--market-text-main); }
.return-block-title .req { color: var(--market-error); }
.return-block-title .opt { color: var(--market-text-muted); font-weight: 500; }

.return-item {
    display: flex; align-items: center; gap: 12px;
    border: 1.5px solid var(--market-border); border-radius: 10px;
    padding: 11px 12px; margin-bottom: 8px; cursor: pointer;
    transition: border-color .18s, background .18s;
}
.return-item-stacked {
    display: block;
    cursor: default;
}
.return-item-main {
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
}
.return-item:last-child { margin-bottom: 0; }
.return-item.selected { border-color: var(--market-primary); background: #FFF8F5; }
.return-item.disabled { opacity: .56; cursor: not-allowed; background: var(--market-bg-sidebar); }
[data-theme="dark"] .return-item.selected { background: rgba(255,107,53,.08); }
.return-check {
    width: 22px; height: 22px; border-radius: 8px;
    border: 2px solid var(--market-border); flex-shrink: 0;
    display: flex; align-items: center; justify-content: center;
    transition: border-color .18s, background .18s;
    color: #fff; font-size: 13px; font-weight: 800;
}
.return-check.checked { border-color: var(--market-primary); background: var(--market-primary); }
.return-radio {
    width: 22px; height: 22px; border-radius: 50%;
    border: 2px solid var(--market-border); flex-shrink: 0;
    display: flex; align-items: center; justify-content: center;
    transition: border-color .18s;
}
.return-radio.checked { border-color: var(--market-primary); }
.return-radio-dot { width: 11px; height: 11px; border-radius: 50%; background: var(--market-primary); }
.return-item-image { width: 54px; height: 54px; border-radius: 8px; object-fit: cover; border: 1px solid var(--market-border); flex-shrink: 0; background: var(--market-bg-sidebar); }
.return-item-no-img { display: flex; align-items: center; justify-content: center; color: var(--market-text-muted); }
.return-item-info { flex: 1; min-width: 0; }
.return-item-name { font-size: .84rem; font-weight: 600; color: var(--market-text-main); overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.return-item-price { font-size: .78rem; margin-top: 3px; }
.return-item-available { font-size: .72rem; color: #117A45; font-weight: 700; margin-top: 2px; }
.return-item.disabled .return-item-available { color: var(--market-text-muted); }
.return-qty { display: flex; align-items: center; gap: 2px; border: 1px solid var(--market-border); border-radius: 7px; padding: 2px; background: var(--market-bg-card); flex-shrink: 0; }
.return-qty button { width: 26px; height: 26px; border: none; background: transparent; color: var(--market-primary); font-size: 1.1rem; cursor: pointer; border-radius: 5px; transition: background .15s; font-weight: 700; }
.return-qty button:hover { background: var(--market-primary-light); }
.return-qty button.disabled { color: var(--market-text-muted); cursor: not-allowed; }
.return-qty span { min-width: 22px; text-align: center; font-size: .84rem; font-weight: 700; color: var(--market-text-main); }
.return-line-details {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid var(--market-border);
    display: grid;
    gap: 9px;
}
.return-inline-label {
    font-size: .76rem;
    font-weight: 700;
    color: var(--market-text-main);
}
.return-inline-label .req { color: var(--market-error); }
.return-inline-label .opt { color: var(--market-text-muted); font-weight: 500; }
.od-sub-actions {
    justify-content: flex-end;
    margin-top: 10px;
}
.rr-line {
    border-top: 1px solid var(--market-border);
    padding-top: 10px;
    margin-top: 10px;
    display: flex;
    gap: 12px;
    align-items: flex-start;
}
.rr-line:first-child {
    border-top: 0;
    padding-top: 0;
}
.rr-line.clickable,
.od-line.clickable {
    cursor: pointer;
    transition: background-color 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}
.rr-line.clickable:hover,
.od-line.clickable:hover {
    background: #fff7f3;
    box-shadow: inset 3px 0 0 var(--market-primary);
}
.rr-line.clickable:active,
.od-line.clickable:active {
    transform: scale(0.995);
}
.rr-product-thumb {
    width: 58px;
    height: 58px;
    border-radius: 12px;
    border: 1px solid var(--market-border);
    background: var(--market-bg-soft);
    color: var(--market-text-muted);
    overflow: hidden;
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
}
.rr-product-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.rr-product-thumb svg {
    width: 24px;
    height: 24px;
}
.rr-line-content {
    min-width: 0;
    flex: 1;
}

.return-select {
    width: 100%; appearance: none; -webkit-appearance: none;
    border: 1px solid var(--market-border); border-radius: 8px;
    padding: 11px 38px 11px 14px;
    font-family: 'Poppins', sans-serif; font-size: .86rem;
    color: var(--market-text-main); background-color: var(--market-bg-card);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%238E8E93' stroke-width='2.5'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
    background-repeat: no-repeat; background-position: right 14px center;
    cursor: pointer; transition: border-color .2s, box-shadow .2s;
}
.return-select:focus { outline: none; border-color: var(--market-primary); box-shadow: 0 0 0 3px var(--market-primary-light); }

.return-textarea {
    width: 100%; border: 1px solid var(--market-border); border-radius: 8px;
    padding: 11px 14px; font-family: 'Poppins', sans-serif; font-size: .86rem;
    color: var(--market-text-main); background: var(--market-bg-card);
    resize: vertical; min-height: 78px; transition: border-color .2s, box-shadow .2s;
}
.return-textarea:focus { outline: none; border-color: var(--market-primary); box-shadow: 0 0 0 3px var(--market-primary-light); }

.return-dropzone {
    display: flex; align-items: center; gap: 10px; justify-content: center;
    border: 1.5px dashed var(--market-border); border-radius: 8px;
    padding: 14px; text-align: center; color: var(--market-text-muted);
    font-size: .8rem; cursor: pointer; transition: border-color .2s, background .2s;
}
.return-dropzone:hover { border-color: var(--market-primary); background: var(--market-primary-light); }
.return-dropzone.uploading { opacity: .6; pointer-events: none; }
.return-dropzone svg { width: 20px; height: 20px; stroke: var(--market-primary); flex-shrink: 0; }
.return-photo-previews { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.return-photo-thumb {
    position: relative; width: 64px; height: 64px; border-radius: 8px; overflow: hidden;
    border: 1px solid var(--market-border);
}
.return-photo-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.return-photo-remove {
    position: absolute; top: 2px; right: 2px;
    width: 18px; height: 18px; border-radius: 50%;
    background: rgba(0,0,0,.65); color: #fff;
    border: none; cursor: pointer; font-size: 13px; line-height: 18px;
    display: flex; align-items: center; justify-content: center; padding: 0;
}

.return-modal-footer {
    padding: 14px 20px; border-top: 1px solid var(--market-border);
    display: flex; justify-content: flex-end; gap: 10px; background: var(--market-bg-card);
}
.btn-return-cancel, .btn-return-submit {
    padding: 10px 20px; border-radius: 8px; font-family: 'Poppins', sans-serif;
    font-weight: 600; font-size: .86rem; cursor: pointer; transition: all .2s;
}
.btn-return-cancel { background: transparent; border: 1px solid var(--market-border); color: var(--market-text-main); }
.btn-return-cancel:hover { border-color: var(--market-text-muted); }
.btn-return-submit { background: #DDF7E8; border: 1px solid #A7E8C1; color: #117A45; }
.btn-return-submit:hover { background: #C5F0D7; border-color: #87DDAA; color: #0F6B3D; }

/* ===== ORDER DETAIL POPUP ===== */
.od-overlay {
    position: fixed; inset: 0; z-index: 10800;
    background: rgba(0,0,0,.55); backdrop-filter: blur(3px);
    display: flex; align-items: center; justify-content: center;
    padding: 20px; opacity: 0; pointer-events: none;
    transition: opacity .22s ease;
}
.od-overlay.active { opacity: 1; pointer-events: auto; }
.od-popup {
    background: var(--market-bg-card);
    border-radius: 16px;
    width: 100%; max-width: 560px; max-height: 88vh;
    display: flex; flex-direction: column;
    box-shadow: 0 24px 64px rgba(0,0,0,.22);
    transform: translateY(20px); transition: transform .25s ease;
    overflow: hidden;
}
.od-overlay.active .od-popup { transform: translateY(0); }
.od-popup-header {
    display: flex; align-items: flex-start; justify-content: space-between;
    gap: 12px; padding: 20px 22px 14px;
    border-bottom: 1px solid var(--market-border); flex-shrink: 0;
}
.od-popup-title { font-size: 1.05rem; font-weight: 700; color: var(--market-text-main); margin-bottom: 5px; }
.od-popup-sub { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.od-popup-body {
    flex: 1; overflow-y: auto; padding: 20px 22px;
    scrollbar-width: thin; scrollbar-color: var(--market-border) transparent;
}
.od-payment-badge { font-size: .72rem; font-weight: 600; padding: 2px 8px; border-radius: 20px; }
.od-pay-pending { background: #FFF3E0; color: #E65100; }
.od-pay-paid    { background: #E8F5E9; color: #2E7D32; }
[data-theme="dark"] .od-pay-pending { background: #3D2000; color: #FFB74D; }
[data-theme="dark"] .od-pay-paid    { background: #003D00; color: #81C784; }

.od-section { margin-bottom: 20px; }
.od-section-title {
    font-size: .72rem; font-weight: 700; text-transform: uppercase;
    letter-spacing: .07em; color: var(--market-text-muted); margin-bottom: 10px;
}
.od-addr-card {
    background: var(--market-bg-sidebar); border: 1px solid var(--market-border);
    border-radius: 9px; padding: 12px 14px;
}
.od-addr-name { font-size: .88rem; font-weight: 700; color: var(--market-text-main); margin-bottom: 4px; }
.od-addr-line  { font-size: .81rem; color: var(--market-text-muted); line-height: 1.7; }

.od-vendor-group { border: 1px solid var(--market-border); border-radius: 10px; margin-bottom: 12px; overflow: hidden; }
.od-vendor-group:last-child { margin-bottom: 0; }
.od-vendor-head {
    display: flex; align-items: center; gap: 7px; flex-wrap: wrap;
    padding: 10px 14px; background: var(--market-bg-sidebar);
    border-bottom: 1px solid var(--market-border);
}
.od-vendor-name { font-size: .83rem; font-weight: 700; color: var(--market-text-main); }
.od-sub-no { font-size: .73rem; color: var(--market-text-muted); margin-left: 2px; }
.od-sub-status { margin-left: auto; font-size: 11px !important; padding: 2px 8px !important; }
.od-cargo-status {
    width: 100%;
    color: var(--market-primary);
    font-size: .74rem;
    font-weight: 700;
}
.od-lines { padding: 0; }
.od-line {
    display: flex; align-items: center; gap: 12px;
    padding: 11px 14px; border-bottom: 1px solid var(--market-border);
}
.od-line:last-child { border-bottom: none; }
.od-line-img {
    width: 50px; height: 50px; border-radius: 7px;
    object-fit: cover; flex-shrink: 0; background: var(--market-bg-sidebar);
}
.od-no-img { display: flex; align-items: center; justify-content: center; color: var(--market-text-muted); }
.od-line-info { flex: 1; min-width: 0; }
.od-line-name { font-size: .85rem; font-weight: 600; color: var(--market-text-main); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.od-line-meta { font-size: .76rem; color: var(--market-text-muted); margin-top: 3px; }
.od-line-price { font-size: .76rem; color: var(--market-text-muted); margin-top: 2px; }
.od-line-amount { font-size: .88rem; font-weight: 700; color: var(--market-text-main); flex-shrink: 0; white-space: nowrap; }
.od-vendor-subtotal {
    display: flex; justify-content: space-between; align-items: center;
    padding: 9px 14px; background: var(--market-bg-sidebar);
    font-size: .8rem; color: var(--market-text-muted);
    border-top: 1px solid var(--market-border);
}
.od-vendor-subtotal strong { color: var(--market-text-main); font-weight: 700; }

.market-product-page {
    padding: 24px 0 54px;
}
.market-vendor-page {
    padding: 24px 0 54px;
}
.market-product-toolbar {
    margin-bottom: 20px;
}
.market-product-page-back {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 0 16px;
    border: 1px solid #ffd8ca;
    border-radius: 999px;
    color: var(--market-brand);
    font-weight: 800;
    text-decoration: none;
    background: #fff;
    margin-bottom: 18px;
}
.market-product-page-card {
    display: grid;
    grid-template-columns: minmax(280px, 480px) minmax(0, 1fr);
    gap: 34px;
    border: 1px solid var(--market-border);
    border-radius: 8px;
    background: #fff;
    padding: 28px;
    box-shadow: 0 16px 44px rgba(15, 23, 42, 0.07);
}
.market-product-page-media {
    aspect-ratio: 1 / 1;
    border-radius: 8px;
    border: 1px solid var(--market-border);
    background: #fff7f3;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--market-text-muted);
}
.market-product-page-media img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}
.market-product-page-media svg {
    width: 72px;
    height: 72px;
}
.market-product-page-media .market-product-page-slider {
    width: 100%;
    height: 100%;
    aspect-ratio: auto;
}
.market-product-page-media .slider-slide {
    padding: 24px;
}
.market-product-page-media .slider-dot {
    border: 0;
    padding: 0;
}
.market-product-page-info h1 {
    margin: 8px 0 12px;
    color: var(--market-text-main);
    font-size: clamp(28px, 4vw, 48px);
    line-height: 1.12;
}
.market-product-page-kicker {
    color: var(--market-brand);
    font-size: 13px;
    font-weight: 900;
}
.market-product-page-price {
    color: var(--market-brand);
    font-size: 30px;
    font-weight: 900;
    margin-bottom: 18px;
}
.market-product-installments {
    margin: 16px 0 20px;
    border: 1px solid var(--market-border);
    border-radius: 8px;
    background: #fff;
    padding: 16px;
}
.market-product-installments h2 {
    margin: 0 0 12px;
    color: var(--market-text-main);
    font-size: 16px;
    font-weight: 900;
}
.market-product-installments #paytr_taksit_tablosu {
    clear: both;
    max-width: 100%;
    text-align: center;
    font-family: Arial, sans-serif;
}
.market-product-installments #paytr_taksit_tablosu::before {
    display: table;
    content: " ";
}
.market-product-installments #paytr_taksit_tablosu::after {
    content: "";
    clear: both;
    display: table;
}
.market-product-installments .taksit-tablosu-wrapper {
    width: 100%;
    max-width: 280px;
    margin: 5px;
    padding: 12px;
    cursor: default;
    text-align: center;
    display: inline-block;
    border: 1px solid var(--market-border);
    border-radius: 8px;
    background: #fff;
}
.market-product-installments .taksit-logo img {
    max-height: 28px;
    padding-bottom: 10px;
}
.market-product-installments .taksit-tutari-text {
    float: left;
    width: 126px;
    color: var(--market-text-muted);
    margin-bottom: 5px;
    font-size: 12px;
}
.market-product-installments .taksit-tutar-wrapper {
    display: inline-block;
    background-color: #f7f7f7;
}
.market-product-installments .taksit-tutar-wrapper:hover {
    background-color: #e8e8e8;
}
.market-product-installments .taksit-tutari {
    float: left;
    width: 126px;
    padding: 6px 0;
    color: #474747;
    border: 2px solid #fff;
    font-size: 12px;
}
.market-product-installments .taksit-tutari-bold {
    font-weight: 700;
}
.market-product-page-vendor {
    width: 100%;
    border: 1px solid var(--market-border);
    border-radius: 8px;
    background: #fff;
    padding: 14px 16px;
    text-align: left;
    cursor: pointer;
}
.market-product-page-vendor span {
    display: block;
    color: var(--market-text-muted);
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
}
.market-product-page-vendor strong {
    display: block;
    color: var(--market-text-main);
    font-size: 16px;
    margin-top: 3px;
}
.market-product-page-stock {
    display: inline-flex;
    margin: 18px 0;
    padding: 8px 12px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 900;
}
.market-product-page-stock.ok {
    background: #ecfdf3;
    color: #147a45;
}
.market-product-page-stock.empty {
    background: #f3f4f6;
    color: #6b7280;
}
.market-product-unavailable {
    border: 1px solid #fed7aa;
    border-radius: 14px;
    background: #fff7ed;
    color: #c2410c;
    font-size: 14px;
    font-weight: 800;
    line-height: 1.55;
    padding: 12px 14px;
    margin-bottom: 18px;
}
.market-product-unavailable.detail-unavailable {
    margin-top: 0;
}
.market-product-page-actions {
    margin-bottom: 24px;
}
.market-product-page-actions .product-buy-btn {
    width: auto;
    min-width: 180px;
}
.market-product-page-actions .market-product-page-stepper {
    width: 100%;
    max-width: 260px;
}
.market-product-tabs {
    border-top: 1px solid var(--market-border);
    padding-top: 18px;
}
.market-product-tab-list {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    margin-bottom: 18px;
    padding: 4px;
    border: 1px solid var(--market-border);
    border-radius: 8px;
    background: #f8fafc;
}
.market-product-tab-btn {
    min-height: 42px;
    border: 0;
    border-radius: 6px;
    background: transparent;
    color: var(--market-text-muted);
    font: inherit;
    font-size: 13px;
    font-weight: 900;
    cursor: pointer;
    transition: background .18s ease, color .18s ease, box-shadow .18s ease;
}
.market-product-tab-btn.active {
    background: #fff;
    color: var(--market-brand);
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.08);
}
.market-product-tab-panel {
    display: none;
}
.market-product-tab-panel.active {
    display: block;
}
.market-product-tab-panel .market-product-installments,
.market-product-tab-panel .product-questions {
    margin-top: 0;
    border-top: 0;
    padding-top: 0;
}
.market-product-page-desc {
    padding-top: 0;
}
.market-product-page-desc h2 {
    margin: 0 0 10px;
    color: var(--market-text-main);
    font-size: 18px;
}
.market-product-page-desc p {
    margin: 0;
    color: var(--market-text-muted);
    line-height: 1.75;
}
.product-questions {
    margin-top: 24px;
    border-top: 1px solid var(--market-border);
    padding-top: 20px;
}
.product-questions-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
}
.product-questions-header h2 {
    margin: 0;
    color: var(--market-text-main);
    font-size: 18px;
    font-weight: 800;
}
.product-questions-header span {
    border-radius: 999px;
    background: var(--market-primary-light);
    color: var(--market-primary);
    padding: 5px 10px;
    font-size: .75rem;
    font-weight: 800;
}
.product-question-form {
    border: 1px solid var(--market-border);
    border-radius: 16px;
    background: var(--market-bg);
    padding: 12px;
}
.product-question-form textarea {
    width: 100%;
    min-height: 92px;
    border: 1px solid var(--market-border);
    border-radius: 12px;
    background: var(--market-surface);
    color: var(--market-text-main);
    padding: 12px;
    resize: vertical;
    font: inherit;
    font-size: .9rem;
    outline: none;
}
.product-question-form textarea:focus {
    border-color: var(--market-primary);
    box-shadow: 0 0 0 3px var(--market-primary-light);
}
.product-question-form-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 10px;
}
.product-question-form-row p {
    min-height: 18px;
    margin: 0;
    color: var(--market-text-muted);
    font-size: .8rem;
    font-weight: 700;
}
.product-question-form-row p.error { color: #DC2626; }
.product-question-form-row p.success { color: #059669; }
.product-question-form-row button {
    border: 0;
    border-radius: 12px;
    background: var(--market-primary);
    color: #fff;
    cursor: pointer;
    padding: 10px 14px;
    font-weight: 800;
    white-space: nowrap;
}
.product-question-list {
    display: grid;
    gap: 10px;
    margin-top: 14px;
}
.product-question-card {
    border: 1px solid var(--market-border);
    border-radius: 16px;
    background: var(--market-surface);
    padding: 14px;
}
.product-question-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: var(--market-text-muted);
    font-size: .72rem;
    font-weight: 800;
    text-transform: uppercase;
}
.product-question-text {
    margin: 8px 0 0;
    color: var(--market-text-main);
    font-size: .92rem;
    font-weight: 800;
    line-height: 1.5;
}
.product-answer-box {
    margin-top: 10px;
    border-radius: 12px;
    background: #F0FDF4;
    padding: 10px;
}
.product-answer-box strong {
    display: block;
    color: #059669;
    font-size: .72rem;
    font-weight: 900;
    text-transform: uppercase;
}
.product-answer-box p {
    margin: 5px 0 0;
    color: #14532D;
    font-size: .86rem;
    font-weight: 700;
    line-height: 1.5;
}
.product-answer-pending,
.product-questions-muted {
    margin: 10px 0 0;
    color: var(--market-text-muted);
    font-size: .84rem;
    font-weight: 700;
}
.product-questions-muted.error { color: #DC2626; }
.market-product-page-state {
    min-height: 360px;
    border: 1px solid var(--market-border);
    border-radius: 8px;
    background: #fff;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 14px;
    color: var(--market-text-muted);
    text-align: center;
}
.market-product-page-state svg {
    width: 56px;
    height: 56px;
}
.market-product-page-state p {
    margin: 0;
    font-size: 17px;
    font-weight: 800;
}
.market-vendor-hero {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 20px;
    border: 1px solid var(--market-border);
    border-radius: 8px;
    background: linear-gradient(135deg, #fff7f3 0%, #fff 70%);
    padding: 24px;
    margin-bottom: 18px;
    box-shadow: 0 16px 44px rgba(15, 23, 42, 0.07);
}
.market-vendor-hero-info {
    min-width: 0;
}
.market-vendor-hero h1 {
    margin: 5px 0 7px;
    color: var(--market-text-main);
    font-size: clamp(28px, 4vw, 46px);
    line-height: 1.12;
}
.market-vendor-hero p {
    margin: 10px 0 0;
    color: var(--market-text-muted);
    line-height: 1.65;
}
.market-vendor-count {
    border: 1px solid #ffd8ca;
    border-radius: 999px;
    background: #fff;
    color: var(--market-primary);
    font-size: 13px;
    font-weight: 900;
    padding: 10px 14px;
    white-space: nowrap;
}
.market-vendor-search {
    padding: 0;
    margin-bottom: 18px;
}
.market-vendor-products {
    border: 1px solid var(--market-border);
    border-radius: 8px;
    background: #fff;
    padding: 20px;
}
.market-vendor-grid {
    padding: 0;
}
.market-vendor-empty {
    grid-column: 1 / -1;
    text-align: center;
    padding: 56px 20px;
    color: var(--market-text-muted);
}
@media (max-width: 800px) {
    .market-product-page-card {
        grid-template-columns: 1fr;
        padding: 18px;
        gap: 20px;
    }
    .product-question-form-row {
        align-items: stretch;
        flex-direction: column;
    }
    .product-question-form-row button {
        width: 100%;
    }
    .market-vendor-hero {
        grid-template-columns: 1fr;
        align-items: start;
        padding: 18px;
    }
    .market-vendor-count {
        justify-self: start;
    }
    .market-vendor-products {
        padding: 14px;
    }
}
.od-grand-total {
    display: flex; justify-content: space-between; align-items: center;
    padding: 14px 0 6px; border-top: 2px solid var(--market-border);
    font-size: .95rem; color: var(--market-text-main); margin-top: 4px;
}
.od-grand-total strong { color: var(--market-primary); font-size: 1.1rem; font-weight: 800; }
.od-popup-actions { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--market-border); }

@media (max-width: 600px) {
    .orders-modal-heading h3 { font-size: 1.1rem; }
    .oc-foot { flex-direction: column; align-items: stretch; }
    .oc-actions { width: 100%; }
    .oc-btn { flex: 1; justify-content: center; }
    .trk-step { width: 52px; }
    .trk-step-label { font-size: .6rem; }
    .od-overlay { padding: 0; align-items: flex-end; }
    .od-popup { max-width: 100%; border-radius: 16px 16px 0 0; max-height: 92vh; }
    .od-overlay.active .od-popup { transform: translateY(0); }
    .od-overlay .od-popup { transform: translateY(100%); }
}

/* Checkout mobile phone verification */
.mobile-otp-overlay {
    position: fixed;
    inset: 0;
    z-index: 11200;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(15, 23, 42, 0.45);
    backdrop-filter: blur(6px);
}

.mobile-otp-overlay.active {
    display: flex;
}

.mobile-otp-modal {
    position: relative;
    width: min(520px, 100%);
    border: 1px solid var(--market-border);
    border-radius: 24px;
    background: var(--market-card-bg);
    color: var(--market-text-main);
    padding: 28px;
    box-shadow: 0 24px 80px rgba(15, 23, 42, 0.22);
}

.mobile-otp-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 36px;
    height: 36px;
    border: 0;
    border-radius: 50%;
    background: var(--market-bg-sidebar);
    color: var(--market-text-muted);
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
}

.mobile-otp-kicker {
    color: var(--market-primary);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin-bottom: 8px;
}

.mobile-otp-modal h3 {
    margin: 0 42px 10px 0;
    font-size: 1.45rem;
    line-height: 1.2;
}

.mobile-otp-copy {
    margin: 0 0 18px;
    color: var(--market-text-muted);
    line-height: 1.6;
    font-size: 0.95rem;
}

.mobile-otp-field {
    display: grid;
    gap: 8px;
    margin: 16px 0;
}

.mobile-otp-field span {
    color: var(--market-text-main);
    font-weight: 700;
    font-size: 0.9rem;
}

.mobile-otp-field input {
    width: 100%;
    border: 1px solid var(--market-border);
    border-radius: 14px;
    background: var(--market-bg-sidebar);
    color: var(--market-text-main);
    font: inherit;
    padding: 14px 16px;
    outline: none;
}

.mobile-otp-field input:focus {
    border-color: var(--market-primary);
    box-shadow: 0 0 0 4px rgba(255, 107, 74, 0.12);
}

.mobile-otp-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    flex-wrap: wrap;
}

.mobile-otp-primary,
.mobile-otp-secondary {
    border: 0;
    border-radius: 14px;
    padding: 13px 18px;
    font-weight: 800;
    cursor: pointer;
    transition: transform 0.18s ease, box-shadow 0.18s ease, opacity 0.18s ease;
}

.mobile-otp-primary {
    background: var(--market-primary);
    color: #fff;
    box-shadow: 0 12px 24px rgba(255, 107, 74, 0.22);
}

.mobile-otp-secondary {
    background: var(--market-bg-sidebar);
    color: var(--market-text-main);
    border: 1px solid var(--market-border);
}

.mobile-otp-primary:hover,
.mobile-otp-secondary:hover {
    transform: translateY(-1px);
}

.mobile-otp-primary:disabled,
.mobile-otp-secondary:disabled {
    cursor: not-allowed;
    opacity: 0.65;
    transform: none;
}

.mobile-otp-primary.full {
    width: 100%;
    margin-top: 4px;
}

.mobile-otp-code-panel {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid var(--market-border);
}

.mobile-otp-verified-box {
    display: grid;
    gap: 6px;
    border: 1px solid rgba(255, 107, 74, 0.24);
    border-radius: 16px;
    background: rgba(255, 107, 74, 0.08);
    padding: 16px;
    margin: 18px 0;
}

.mobile-otp-verified-box span {
    color: var(--market-text-muted);
    font-size: 0.82rem;
    font-weight: 700;
}

.mobile-otp-verified-box strong {
    color: var(--market-text-main);
    font-size: 1.18rem;
}

.mobile-otp-status {
    min-height: 22px;
    margin: 14px 0 0;
    font-size: 0.9rem;
    color: var(--market-text-muted);
}

.mobile-otp-status.error {
    color: #e53935;
}

.mobile-otp-status.success {
    color: #1f9d55;
}

@media (max-width: 600px) {
    .mobile-otp-overlay {
        align-items: flex-end;
        padding: 0;
    }

    .mobile-otp-modal {
        border-radius: 22px 22px 0 0;
        padding: 24px 18px 20px;
    }

    .mobile-otp-actions {
        flex-direction: column-reverse;
    }

    .mobile-otp-primary,
    .mobile-otp-secondary {
        width: 100%;
    }
}
