@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700&display=swap');

:root {
    --primary: #25D366;
    --primary-dark: #128C7E;
    --secondary: #34B7F1;
    --dark: #075E54;
    --light: #ECE5DD;
    --white: #ffffff;
    --bg-gradient: linear-gradient(135deg, #f0f7f4 0%, #e8f2ee 100%);
    --card-bg: rgba(255, 255, 255, 0.85);
    --glass-border: rgba(255, 255, 255, 0.3);
    --shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.1);
    --radius: 20px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: 'Outfit', sans-serif;
    background: var(--bg-gradient);
    background-attachment: fixed;
    color: #1a1a1a;
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
}

.container {
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
    padding: 20px;
}

header {
    text-align: center;
    padding: 30px 0;
}

.logo-area {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.vendor-logo {
    width: 64px;
    height: 64px;
    background: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    box-shadow: var(--shadow);
    border: 2px solid var(--primary);
}

h1 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--dark);
}

.subtitle {
    color: #666;
    font-size: 0.9rem;
}

.vendor-stats {
    margin-top: 15px;
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
}

.stat-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--primary);
    color: white;
    padding: 6px 16px;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    box-shadow: 0 4px 10px rgba(37, 211, 102, 0.2);
}

.stat-badge.pending {
    background: #f59e0b;
    box-shadow: 0 4px 10px rgba(245, 158, 11, 0.2);
}

.recent-products {
    margin-top: 20px;
    width: 100%;
    overflow: hidden;
}

.small-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #94a3b8;
    margin-bottom: 10px;
    font-weight: 700;
}

.chips-container {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 5px;
    scrollbar-width: none;
    /* Hide scrollbar Firefox */
}

.chips-container::-webkit-scrollbar {
    display: none;
    /* Hide scrollbar Chrome/Safari */
}

.product-chip {
    white-space: nowrap;
    background: white;
    color: var(--dark);
    padding: 6px 12px;
    border-radius: 10px;
    font-size: 0.8rem;
    font-weight: 500;
    border: 1px solid var(--light);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.03);
}

/* Glass Card */
.glass-card {
    background: var(--card-bg);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius);
    padding: 24px;
    box-shadow: var(--shadow);
    margin-bottom: 20px;
    animation: slideUp 0.5s ease-out;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Form Groups */
.form-group {
    margin-bottom: 20px;
}

label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    font-size: 0.9rem;
    color: #444;
}

input,
textarea {
    width: 100%;
    padding: 14px 18px;
    border: 2px solid transparent;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.9);
    font-family: inherit;
    font-size: 1rem;
    transition: var(--transition);
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.02);
}

input:focus,
textarea:focus {
    outline: none;
    border-color: var(--primary);
    background: #fff;
    box-shadow: 0 0 0 4px rgba(37, 211, 102, 0.1);
}

textarea {
    resize: none;
    min-height: 100px;
}

/* Price Toggle */
.price-toggle-container {
    display: flex;
    background: #eef2f1;
    padding: 5px;
    border-radius: 12px;
    margin-bottom: 15px;
}

.toggle-option {
    flex: 1;
    text-align: center;
    padding: 8px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    border-radius: 8px;
    transition: var(--transition);
    color: #888;
}

.toggle-option.active {
    background: white;
    color: var(--primary-dark);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

/* Type Selector */
.type-selector {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
}

.type-option {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 15px;
    background: rgba(255, 255, 255, 0.5);
    border: 2px solid transparent;
    border-radius: 16px;
    cursor: pointer;
    transition: var(--transition);
    color: #64748b;
}

.type-option i {
    font-size: 1.5rem;
}

.type-option.active {
    background: white;
    border-color: var(--primary);
    color: var(--primary-dark);
    box-shadow: 0 4px 12px rgba(37, 211, 102, 0.15);
}

.price-inputs {
    display: flex;
    align-items: center;
    gap: 10px;
}

.input-suffix {
    white-space: nowrap;
    font-weight: 600;
    color: var(--primary-dark);
    font-size: 0.9rem;
    background: white;
    padding: 14px 10px;
    border-radius: 12px;
}

/* Upload Area */
.upload-area {
    border: 2px dashed #cbd5e1;
    border-radius: 16px;
    padding: 30px 20px;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    background: rgba(248, 250, 252, 0.5);
}

.upload-area:hover,
.upload-area.dragover {
    border-color: var(--primary);
    background: rgba(37, 211, 102, 0.05);
}

.upload-icon {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 10px;
}

.upload-text {
    font-size: 0.9rem;
    color: #64748b;
}

.upload-text b {
    color: var(--primary-dark);
}

#preview-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-top: 15px;
}

.preview-item {
    aspect-ratio: 1;
    border-radius: 10px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.preview-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.remove-img {
    position: absolute;
    top: 4px;
    right: 4px;
    background: rgba(239, 68, 68, 0.9);
    color: white;
    border: none;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    font-size: 10px;
    cursor: pointer;
    z-index: 10;
}

.video-badge {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(37, 211, 102, 0.8);
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
}

/* Magic Button */
.magic-btn {
    width: 100%;
    padding: 18px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
    border: none;
    border-radius: 16px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 10px 20px -5px rgba(37, 211, 102, 0.4);
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.magic-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 15px 25px -5px rgba(37, 211, 102, 0.5);
}

.magic-btn:active:not(:disabled) {
    transform: translateY(0);
}

.magic-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background: #94a3b8;
    box-shadow: none;
}

/* Loader Overlay */
#loader-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    color: white;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(255, 255, 255, 0.1);
    border-left-color: var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 20px;
}

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

.progress-bar {
    width: 200px;
    height: 6px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
    overflow: hidden;
    margin-top: 10px;
}

.progress-fill {
    height: 100%;
    width: 0%;
    background: var(--primary);
    transition: width 0.3s;
}

/* Success View */
.success-view {
    text-align: center;
    padding: 40px 20px;
}

.success-icon {
    font-size: 5rem;
    color: var(--primary);
    margin-bottom: 20px;
}

.btn-group {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 30px;
}

.btn-secondary {
    background: transparent;
    border: 2px solid var(--primary);
    color: var(--primary-dark);
}

/* Character Count */
.char-count {
    text-align: right;
    font-size: 0.75rem;
    margin-top: 4px;
    color: #94a3b8;
}

.char-count.valid {
    color: var(--primary);
}

/* Order Options Toggles */
.order-options {
    background: rgba(255, 255, 255, 0.4);
    padding: 15px;
    border-radius: 14px;
}

.option-toggle {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 10px;
    cursor: pointer;
}

.option-toggle:last-child {
    margin-bottom: 0;
}

.toggle-switch {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
    background-color: #cbd5e1;
    border-radius: 20px;
    transition: var(--transition);
    cursor: pointer;
}

.toggle-switch::after {
    content: "";
    position: absolute;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background-color: white;
    top: 2px;
    left: 2px;
    transition: var(--transition);
}

input:checked+.toggle-switch {
    background-color: var(--primary);
}

input:checked+.toggle-switch::after {
    left: 22px;
}

.helper-text {
    display: block;
    margin-top: 6px;
    font-size: 0.75rem;
    color: #64748b;
}