/**
 * Multi-Step Wizard Component Styles
 * Reusable wizard/form stepper component
 */

/* ============================================================================
   Wizard Container
   ========================================================================== */

/* Wizard shared utilities (replace inline styles in JS templates) */
.wizard-grid-full {
    grid-column: 1 / -1;
    text-align: center;
    padding: var(--ds-space-8);
}

.wizard-empty-icon {
    font-size: var(--ds-font-size-5xl);
    color: var(--ds-color-neutral-400);
}

.wizard-empty-text {
    color: var(--ds-color-text-secondary);
    margin-top: var(--ds-space-4);
}

.wizard-empty-hint {
    color: var(--ds-color-neutral-500);
    font-size: var(--ds-font-size-xs);
}

.wizard-error-block {
    grid-column: 1 / -1;
    text-align: center;
    padding: var(--ds-space-8);
    color: var(--ds-color-error);
}

.wizard-cover-selected {
    border-color: var(--ds-color-primary) !important;
}

.wizard-cover-default {
    border-color: var(--ds-border-color-light) !important;
}

.wizard-covers-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: var(--ds-space-4);
    margin-bottom: var(--ds-space-8);
}

.wizard-divider-or {
    margin: var(--ds-space-8) 0;
    border-top: var(--ds-border-width-thin) solid var(--ds-border-color-light);
    position: relative;
}

.wizard-divider-or span {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--ds-color-surface);
    padding: 0 var(--ds-space-4);
    color: var(--ds-color-text-secondary);
    font-size: var(--ds-font-size-sm);
}

.wizard-cover-item {
    position: relative;
    cursor: pointer;
    border: 2px solid var(--ds-border-color-light);
    border-radius: var(--ds-radius-md);
    overflow: hidden;
    transition: all var(--ds-transition-fast);
}

.wizard-cover-item.selected,
.wizard-cover-item.wizard-cover-selected {
    border-color: var(--ds-color-primary);
}

.wizard-cover-badge {
    position: absolute;
    top: var(--ds-space-2);
    right: var(--ds-space-2);
    background: rgba(255, 255, 255, 0.9);
    color: var(--ds-color-text-secondary);
    border-radius: var(--ds-radius-full);
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: var(--ds-font-size-sm);
    z-index: 10;
}

.wizard-cover-badge.is-selected {
    background: var(--ds-color-primary);
    color: var(--ds-color-hero-text);
}

.wizard-gallery-delete-btn {
    position: absolute;
    top: var(--ds-space-2);
    left: var(--ds-space-2);
    background: rgba(220, 53, 69, 0.92);
    color: #fff;
    border: none;
    border-radius: var(--ds-radius-full);
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: var(--ds-font-size-sm);
    z-index: 11;
    cursor: pointer;
    opacity: 0;
    transition: opacity var(--ds-transition-fast);
}

.wizard-cover-item:hover .wizard-gallery-delete-btn,
.wizard-gallery-delete-btn:focus {
    opacity: 1;
}

.wizard-gallery-delete-btn:hover {
    background: rgba(200, 35, 51, 1);
}

.wizard-cover-img {
    width: 100%;
    height: 150px;
    object-fit: cover;
}

.wizard-cover-label {
    padding: var(--ds-space-2);
    font-size: var(--ds-font-size-xs);
    color: var(--ds-color-text-secondary);
    background: var(--ds-color-neutral-100);
}

.wizard-empty-icon-sm { font-size: var(--ds-font-size-2xl); color: var(--ds-color-neutral-400); }
.wizard-empty-muted { grid-column: 1 / -1; text-align: center; padding: var(--ds-space-8); color: var(--ds-color-neutral-500); }
.wizard-hidden { display: none !important; }
.wizard-upload-preview { margin-top: var(--ds-space-4); text-align: center; }
.wizard-upload-preview img { max-width: 100%; max-height: 300px; border-radius: var(--ds-radius-lg); box-shadow: var(--ds-shadow-md); }
.wizard-card-image-gradient { background: linear-gradient(135deg, var(--ds-color-primary) 0%, var(--ds-color-hero-gradient-end) 100%); display: flex; align-items: center; justify-content: center; color: var(--ds-color-hero-text); font-size: var(--ds-font-size-2xl); }

.wizard-selection-bar {
    margin-bottom: var(--ds-space-4);
    padding: var(--ds-space-3);
    background: var(--ds-color-success-bg);
    border-radius: var(--ds-radius-md);
}

.wizard-selection-bar-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: var(--ds-space-2);
}

.wizard-selection-actions {
    display: flex;
    align-items: center;
    gap: var(--ds-space-4);
}

.wizard-btn-compact { padding: var(--ds-space-1) var(--ds-space-3); font-size: var(--ds-font-size-sm); }
.wizard-btn-full { width: 100%; margin-top: var(--ds-space-2); }

.wizard-toolbar-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--ds-space-4);
    padding: var(--ds-space-3);
    background: var(--ds-color-surface);
    border-radius: var(--ds-radius-md);
    border: var(--ds-border-width-thin) solid var(--ds-border-color-light);
}

.wizard-toolbar-group { display: flex; align-items: center; gap: var(--ds-space-3); }
.wizard-toolbar-label { font-size: var(--ds-font-size-sm); font-weight: var(--ds-font-weight-semibold); color: var(--ds-color-text-secondary); }
.wizard-select-inline { width: auto; min-width: 80px; padding: var(--ds-space-2) var(--ds-space-3); font-size: var(--ds-font-size-sm); }
.wizard-category-counts { display: flex; gap: var(--ds-space-4); font-size: var(--ds-font-size-sm); color: var(--ds-color-text-secondary); }

.wizard-pagination-bar {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: var(--ds-space-4);
    margin-top: var(--ds-space-6);
    padding: var(--ds-space-4);
    background: var(--ds-color-surface);
    border-radius: var(--ds-radius-md);
    border: var(--ds-border-width-thin) solid var(--ds-border-color-light);
}

.wizard-page-info { font-size: var(--ds-font-size-sm); font-weight: var(--ds-font-weight-semibold); color: var(--ds-color-text-secondary); }
.wizard-wine-meta { text-align: center; font-size: var(--ds-font-size-sm); color: var(--ds-color-text-secondary); margin-bottom: var(--ds-space-2); }
.wizard-summary-intro { margin-bottom: var(--ds-space-6); }
.wizard-summary-label { font-size: var(--ds-font-size-xs); color: var(--ds-color-text-secondary); }
.wizard-summary-input-label {
    font-size: var(--ds-font-size-xs);
    color: var(--ds-color-text-secondary);
    display: block;
    margin-bottom: var(--ds-space-1);
}

.wizard-success-hero {
    background: linear-gradient(135deg, var(--ds-color-success) 0%, var(--ds-color-success-dark) 100%);
    color: var(--ds-color-hero-text);
    padding: var(--ds-space-8);
    border-radius: var(--ds-radius-xl);
    margin-bottom: var(--ds-space-8);
    text-align: center;
}

.wizard-success-icon { font-size: var(--ds-font-size-5xl); margin-bottom: var(--ds-space-4); }
.wizard-success-title { margin-bottom: var(--ds-space-2); }
.wizard-success-subtitle { opacity: 0.9; margin: 0; }

.wizard-summary-grid { display: grid; gap: var(--ds-space-4); }
.wizard-summary-row {
    display: flex;
    justify-content: space-between;
    padding: var(--ds-space-3);
    background: var(--ds-color-neutral-100);
    border-radius: var(--ds-radius-md);
}

.wizard-summary-row-label { color: var(--ds-color-text-secondary); }

.wizard-tip-box {
    background: var(--ds-color-info-bg);
    border-left: 4px solid var(--ds-color-info);
    padding: var(--ds-space-4);
    border-radius: var(--ds-radius-md);
    margin-top: var(--ds-space-8);
}

.wizard-tip-inner { display: flex; gap: var(--ds-space-3); }
.wizard-tip-icon { color: var(--ds-color-info); font-size: var(--ds-font-size-xl); }
.wizard-tip-title { color: var(--ds-color-info-dark); }
.wizard-tip-text { color: var(--ds-color-info-dark); margin: var(--ds-space-2) 0 0 0; font-size: var(--ds-font-size-sm); }

.wizard-selection-notice {
    margin-bottom: var(--ds-space-4);
    padding: var(--ds-space-3);
    background: var(--ds-color-success-bg);
    border-radius: var(--ds-radius-md);
    border-left: 4px solid var(--ds-color-success);
}

.wizard-category-czerwone { color: #8b0000; }
.wizard-category-biale { color: #c4a574; }
.wizard-category-rozowe { color: #e879a8; }
.wizard-category-default { color: var(--ds-color-neutral-500); }

.wizard-wine-card-image,
.wizard-summary-image {
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
}

.wizard-category-pill {
    display: flex;
    align-items: center;
    gap: var(--ds-space-1);
}

.wizard-container {
    background: var(--ds-color-neutral-50, #ffffff);
    border-radius: var(--ds-radius-xl, 1rem);
    box-shadow: var(--ds-shadow-lg, 0 10px 15px -3px rgba(0, 0, 0, 0.1));
    overflow: hidden;
    max-width: 1200px;
    margin: 0 auto;
}

/* ============================================================================
   Progress Indicator
   ========================================================================== */

.wizard-progress {
    background: linear-gradient(135deg, var(--ds-color-primary) 0%, var(--ds-color-primary-dark) 100%);
    padding: var(--ds-space-8, 2rem) var(--ds-space-6, 1.5rem);
    color: white;
}

.wizard-progress-title {
    font-size: var(--ds-font-size-2xl, 1.5rem);
    font-weight: var(--ds-font-weight-bold, 700);
    margin-bottom: var(--ds-space-6, 1.5rem);
    display: flex;
    align-items: center;
    gap: var(--ds-space-3, 0.75rem);
}

.wizard-progress-steps {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    margin-bottom: var(--ds-space-4, 1rem);
}

.wizard-progress-line {
    position: absolute;
    top: 20px;
    left: 0;
    right: 0;
    height: 3px;
    background: rgba(255, 255, 255, 0.2);
    z-index: 0;
}

.wizard-progress-line-fill {
    height: 100%;
    background: rgba(255, 255, 255, 0.8);
    transition: width 0.3s var(--ds-ease-out, ease-out);
}

.wizard-step-indicator {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--ds-space-2, 0.5rem);
    flex: 1;
    min-width: 0;
}

.wizard-step-circle {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    border: 3px solid rgba(255, 255, 255, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: var(--ds-font-weight-bold, 700);
    transition: all 0.3s var(--ds-ease-out, ease-out);
    cursor: pointer;
}

.wizard-step-indicator.active .wizard-step-circle {
    background: white;
    color: var(--ds-color-primary, #009634);
    border-color: white;
    transform: scale(1.15);
}

.wizard-step-indicator.completed .wizard-step-circle {
    background: rgba(255, 255, 255, 0.8);
    border-color: rgba(255, 255, 255, 0.8);
    color: var(--ds-color-primary, #009634);
}

.wizard-step-label {
    font-size: var(--ds-font-size-sm, 0.875rem);
    font-weight: var(--ds-font-weight-medium, 500);
    opacity: 0.7;
    transition: opacity 0.3s;
    text-align: center;
    max-width: 120px;
}

.wizard-step-indicator.active .wizard-step-label {
    opacity: 1;
    font-weight: var(--ds-font-weight-semibold, 600);
}

.wizard-current-step-info {
    font-size: var(--ds-font-size-sm, 0.875rem);
    opacity: 0.9;
}

/* ============================================================================
   Step Content
   ========================================================================== */

.wizard-content {
    padding: var(--ds-space-8, 2rem);
    min-height: 500px;
}

.wizard-step {
    display: none;
    animation: fadeInStep 0.3s var(--ds-ease-out, ease-out);
}

.wizard-step.active {
    display: block;
}

@keyframes fadeInStep {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.wizard-step-header {
    margin-bottom: var(--ds-space-6, 1.5rem);
    padding-bottom: var(--ds-space-4, 1rem);
    border-bottom: 2px solid var(--ds-color-neutral-200, #e5e7eb);
}

.wizard-step-title {
    font-size: var(--ds-font-size-3xl, 1.875rem);
    font-weight: var(--ds-font-weight-bold, 700);
    color: var(--ds-color-neutral-900, #1a202c);
    margin-bottom: var(--ds-space-2, 0.5rem);
    display: flex;
    align-items: center;
    gap: var(--ds-space-3, 0.75rem);
}

.wizard-step-description {
    font-size: var(--ds-font-size-base, 0.9375rem);
    color: var(--ds-color-neutral-600, #718096);
    line-height: var(--ds-line-height-relaxed, 1.625);
}

.wizard-step-body {
    margin-bottom: var(--ds-space-6, 1.5rem);
}

/* ============================================================================
   Navigation
   ========================================================================== */

.wizard-navigation {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--ds-space-6, 1.5rem) var(--ds-space-8, 2rem);
    background: var(--ds-color-neutral-100, #f7fafc);
    border-top: 1px solid var(--ds-color-neutral-300, #e2e8f0);
}

.wizard-nav-left {
    display: flex;
    gap: var(--ds-space-3, 0.75rem);
    flex-wrap: wrap;
}

.wizard-nav-buttons {
    display: flex;
    gap: var(--ds-space-4, 1rem);
}

.wizard-btn {
    padding: var(--ds-space-3, 0.75rem) var(--ds-space-6, 1.5rem);
    border-radius: var(--ds-radius-lg, 0.75rem);
    font-size: var(--ds-font-size-base, 0.9375rem);
    font-weight: var(--ds-font-weight-semibold, 600);
    cursor: pointer;
    transition: all var(--ds-transition-base, 0.2s ease-out);
    border: none;
    display: inline-flex;
    align-items: center;
    gap: var(--ds-space-2, 0.5rem);
}

.wizard-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.wizard-btn-primary {
    background: var(--ds-color-primary, #009634);
    color: white;
}

.wizard-btn-primary:hover:not(:disabled) {
    background: var(--ds-color-primary-dark, #007a2a);
    transform: translateY(-1px);
    box-shadow: var(--ds-shadow-md, 0 4px 6px -1px rgba(0, 0, 0, 0.1));
}

.wizard-btn-secondary {
    background: var(--ds-color-neutral-200, #e5e7eb);
    color: var(--ds-color-neutral-700, #4a5568);
}

.wizard-btn-secondary:hover:not(:disabled) {
    background: var(--ds-color-neutral-300, #cbd5e0);
}

.wizard-btn-success {
    background: var(--ds-color-success, #10b981);
    color: white;
}

.wizard-btn-success:hover:not(:disabled) {
    background: #059669;
    transform: translateY(-1px);
    box-shadow: var(--ds-shadow-md, 0 4px 6px -1px rgba(0, 0, 0, 0.1));
}

.wizard-btn-outline {
    background: transparent;
    color: var(--ds-color-primary, #009634);
    border: 2px solid var(--ds-color-primary, #009634);
}

.wizard-btn-outline:hover:not(:disabled) {
    background: var(--ds-color-primary-bg, #f0fdf4);
    transform: translateY(-1px);
}

/* ============================================================================
   Validation Messages
   ========================================================================== */

.wizard-validation-error {
    background: #fef2f2;
    border-left: 4px solid #ef4444;
    padding: var(--ds-space-4, 1rem);
    border-radius: var(--ds-radius-md, 0.5rem);
    margin-bottom: var(--ds-space-4, 1rem);
    color: #991b1b;
}

.wizard-validation-error ul {
    margin: var(--ds-space-2, 0.5rem) 0 0 var(--ds-space-5, 1.25rem);
    padding: 0;
}

/* ============================================================================
   Grid Layouts for Steps
   ========================================================================== */

.wizard-grid {
    display: grid;
    gap: var(--ds-space-6, 1.5rem);
}

.wizard-grid-2 {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.wizard-grid-3 {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.wizard-grid-4 {
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

/* ============================================================================
   Selection Cards (for templates, covers, etc.)
   ========================================================================== */

.wizard-card {
    background: white;
    border: 2px solid var(--ds-color-neutral-300, #e2e8f0);
    border-radius: var(--ds-radius-lg, 0.75rem);
    padding: var(--ds-space-4, 1rem);
    cursor: pointer;
    transition: all 0.2s ease-out;
    position: relative;
}

.wizard-card:hover {
    border-color: var(--ds-color-primary, #009634);
    box-shadow: var(--ds-shadow-md, 0 4px 6px -1px rgba(0, 0, 0, 0.1));
    transform: translateY(-2px);
}

.wizard-card.selected {
    border-color: var(--ds-color-primary, #009634);
    background: var(--ds-color-primary-bg, #f0fdf4);
    box-shadow: 0 0 0 3px rgba(0, 150, 52, 0.1);
}

.wizard-card-checkmark {
    position: absolute;
    top: var(--ds-space-3, 0.75rem);
    right: var(--ds-space-3, 0.75rem);
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--ds-color-primary, #009634);
    color: white;
    display: none;
    align-items: center;
    justify-content: center;
    font-size: 14px;
}

.wizard-card.selected .wizard-card-checkmark {
    display: flex;
}

.wizard-card-image {
    width: 100%;
    height: 150px;
    object-fit: cover;
    border-radius: var(--ds-radius-md, 0.5rem);
    margin-bottom: var(--ds-space-3, 0.75rem);
}

.wizard-card-title {
    font-weight: var(--ds-font-weight-semibold, 600);
    color: var(--ds-color-neutral-900, #1a202c);
    margin-bottom: var(--ds-space-1, 0.25rem);
}

.wizard-card-description {
    font-size: var(--ds-font-size-sm, 0.875rem);
    color: var(--ds-color-neutral-600, #718096);
}

/* ============================================================================
   Wine Grid (for product selection)
   ========================================================================== */

.wizard-wine-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: var(--ds-space-4, 1rem);
    margin-top: var(--ds-space-6, 1.5rem);
}
/* Grid column variations */
.wizard-wine-grid-2 {
    grid-template-columns: repeat(2, 1fr);
}

.wizard-wine-grid-3 {
    grid-template-columns: repeat(3, 1fr);
}

.wizard-wine-grid-4 {
    grid-template-columns: repeat(4, 1fr);
}

/* Responsive adjustments */
@media (max-width: 1200px) {
    .wizard-wine-grid-4 {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 640px) {
    .wizard-wine-grid-3,
    .wizard-wine-grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Column switcher: hide options with no visible effect at this width */
@media (max-width: 1200px) {
    .wizard-toolbar-columns [data-columns="4"] {
        display: none;
    }
}

@media (max-width: 640px) {
    .wizard-toolbar-columns [data-columns="3"] {
        display: none;
    }
}

@media (max-width: 600px) {
    .wizard-toolbar-columns {
        display: none;
    }
}

@media (max-width: 600px) {
    .wizard-wine-grid-2,
    .wizard-wine-grid-3,
    .wizard-wine-grid-4 {
        grid-template-columns: 1fr;
    }
}
.wizard-wine-card {
    background: white;
    border: 2px solid var(--ds-color-neutral-200, #e5e7eb);
    border-radius: var(--ds-radius-lg, 0.75rem);
    overflow: hidden;
    cursor: pointer;
    transition: all 0.2s ease-out;
    position: relative;
}

.wizard-wine-card:hover {
    border-color: var(--ds-color-primary, #009634);
    transform: translateY(-2px);
    box-shadow: var(--ds-shadow-lg, 0 10px 15px -3px rgba(0, 0, 0, 0.1));
}

.wizard-wine-card.selected {
    border-color: var(--ds-color-primary, #009634);
    background: var(--ds-color-primary-bg, #f0fdf4);
}

.wizard-wine-card-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    background-color: #ffffff;
}

.wizard-wine-card-body {
    padding: var(--ds-space-4, 1rem);
}

.wizard-wine-card-name {
    font-weight: var(--ds-font-weight-semibold, 600);
    color: var(--ds-color-neutral-900, #1a202c);
    margin-bottom: var(--ds-space-2, 0.5rem);
    font-size: var(--ds-font-size-lg, 1.125rem);
}

.wizard-wine-card-meta {
    display: flex;
    flex-direction: column;
    gap: var(--ds-space-1, 0.25rem);
    font-size: var(--ds-font-size-sm, 0.875rem);
    color: var(--ds-color-neutral-600, #718096);
}

.wizard-wine-card-badge {
    position: absolute;
    top: var(--ds-space-3, 0.75rem);
    right: var(--ds-space-3, 0.75rem);
    background: var(--ds-color-primary, #009634);
    color: white;
    padding: var(--ds-space-1, 0.25rem) var(--ds-space-3, 0.75rem);
    border-radius: var(--ds-radius-full, 9999px);
    font-size: var(--ds-font-size-xs, 0.75rem);
    font-weight: var(--ds-font-weight-semibold, 600);
    display: none;
}

.wizard-wine-card.selected .wizard-wine-card-badge {
    display: block;
}

/* ============================================================================
   Filters & Search
   ========================================================================== */

.wizard-filters {
    background: var(--ds-color-neutral-100, #f7fafc);
    padding: var(--ds-space-4, 1rem);
    border-radius: var(--ds-radius-lg, 0.75rem);
    margin-bottom: var(--ds-space-6, 1.5rem);
    display: flex;
    flex-direction: column;
    gap: var(--ds-space-3, 0.75rem);
}

.wizard-search {
    width: 100%;
}

.wizard-filters-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--ds-space-3, 0.75rem);
}

.wizard-filter-select {
    width: 100%;
}

/* ============================================================================
   Summary List
   ========================================================================== */

.wizard-summary-list {
    list-style: none;
    padding: 0;
    margin: 0;
    min-height: 60px;
    transition: all 0.2s ease-out;
}

.wizard-summary-list.drag-over-category {
    background: var(--ds-color-primary-bg, #f0fdf4);
    border: 2px dashed var(--ds-color-primary, #009634);
    border-radius: var(--ds-radius-lg, 0.75rem);
    padding: var(--ds-space-2, 0.5rem);
}

.wizard-category-section {
    margin-bottom: var(--ds-space-4, 1rem);
    cursor: grab;
    transition: all 0.2s ease-out;
}

.wizard-category-section.dragging-category {
    opacity: 0.4;
    cursor: grabbing;
}

.wizard-category-section.drag-over-category-section {
    transform: translateY(-4px);
    box-shadow: 0 4px 12px rgba(0, 150, 52, 0.3);
}

.wizard-category-header {
    background: linear-gradient(135deg, var(--ds-color-primary) 0%, var(--ds-color-primary-dark) 100%);
    color: white;
    padding: var(--ds-space-3, 0.75rem) var(--ds-space-4, 1rem);
    border-radius: var(--ds-radius-lg, 0.75rem);
    margin-bottom: var(--ds-space-4, 1rem);
    margin-top: var(--ds-space-6, 1.5rem);
    font-size: var(--ds-font-size-lg, 1.125rem);
    font-weight: var(--ds-font-weight-semibold, 600);
    display: flex;
    align-items: center;
    gap: var(--ds-space-2, 0.5rem);
    box-shadow: var(--ds-shadow-sm);
}

.wizard-category-drag-handle {
    cursor: grab;
    color: rgba(255, 255, 255, 0.6);
    font-size: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    transition: color 0.2s ease-out;
    flex-shrink: 0;
}

.wizard-category-section:hover .wizard-category-drag-handle {
    color: rgba(255, 255, 255, 0.9);
}

.wizard-category-section.dragging-category .wizard-category-drag-handle {
    cursor: grabbing;
}

/* Arrow buttons for categories */
.wizard-category-arrows {
    display: flex;
    flex-direction: column;
    gap: 0.125rem;
    margin-right: var(--ds-space-2, 0.5rem);
}

.wizard-category-arrows .wizard-arrow-btn {
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: white;
    padding: 0.25rem 0.5rem;
}

.wizard-category-arrows .wizard-arrow-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    border-color: rgba(255, 255, 255, 0.5);
    color: white;
}

.wizard-category-header:first-child {
    margin-top: 0;
}

.wizard-category-header i {
    font-size: 1.25rem;
}

.wizard-category-name-input {
    background: rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: white;
    padding: var(--ds-space-2, 0.5rem) var(--ds-space-3, 0.75rem);
    border-radius: var(--ds-radius-md, 0.5rem);
    font-size: var(--ds-font-size-lg, 1.125rem);
    font-weight: var(--ds-font-weight-semibold, 600);
    flex: 1;
    transition: all 0.2s ease-out;
}

.wizard-category-name-input:hover {
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.4);
}

.wizard-category-name-input:focus {
    outline: none;
    background: rgba(255, 255, 255, 0.3);
    border-color: rgba(255, 255, 255, 0.5);
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.1);
}

.wizard-category-name-input::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.wizard-category-count {
    opacity: 0.8;
    font-size: 0.875rem;
    white-space: nowrap;
    margin-left: auto;
}

.wizard-summary-item {
    background: white;
    border: 1px solid var(--ds-color-neutral-300, #e2e8f0);
    border-radius: var(--ds-radius-lg, 0.75rem);
    padding: var(--ds-space-4, 1rem);
    margin-bottom: var(--ds-space-4, 1rem);
    display: grid;
    grid-template-columns: auto auto 80px 1fr auto;
    gap: var(--ds-space-4, 1rem);
    align-items: center;
    cursor: grab;
    transition: all 0.2s ease-out;
    position: relative;
}

.wizard-summary-remove-btn {
    position: absolute;
    top: 0.4rem;
    right: 0.4rem;
    width: 1.5rem;
    height: 1.5rem;
    padding: 0;
    border: none;
    border-radius: 50%;
    background: transparent;
    color: var(--ds-color-neutral-400, #cbd5e0);
    font-size: 1rem;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.15s ease-out, color 0.15s ease-out;
    z-index: 10;
}

.wizard-summary-remove-btn:hover {
    background: #fed7d7;
    color: #e53e3e;
}

.wizard-summary-item.dragging {
    opacity: 0.5;
    cursor: grabbing;
    transform: scale(0.98);
}

.wizard-summary-item.drag-over {
    border-color: var(--ds-color-primary, #009634);
    background: var(--ds-color-primary-bg, #f0fdf4);
    transform: translateY(-2px);
}

.wizard-summary-drag-handle {
    cursor: grab;
    color: var(--ds-color-neutral-400, #cbd5e0);
    font-size: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    transition: color 0.2s ease-out;
}

.wizard-summary-item:hover .wizard-summary-drag-handle {
    color: var(--ds-color-neutral-600, #718096);
}

.wizard-summary-item.dragging .wizard-summary-drag-handle {
    cursor: grabbing;
}

/* Arrow buttons for wines */
.wizard-wine-arrows {
    display: flex;
    flex-direction: column;
    gap: 0.125rem;
}

.wizard-arrow-btn {
    background: transparent;
    border: 1px solid var(--ds-color-neutral-300, #e2e8f0);
    border-radius: var(--ds-radius-sm, 0.25rem);
    padding: 0.25rem 0.5rem;
    cursor: pointer;
    color: var(--ds-color-neutral-600, #718096);
    transition: all 0.2s ease-out;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    line-height: 1;
}

.wizard-arrow-btn:hover {
    background: var(--ds-color-primary-bg, #f0fdf4);
    border-color: var(--ds-color-primary, #009634);
    color: var(--ds-color-primary, #009634);
    transform: scale(1.1);
}

.wizard-arrow-btn:active {
    transform: scale(0.95);
}

.wizard-arrow-btn i {
    font-size: 0.875rem;
}

.wizard-summary-image {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: var(--ds-radius-md, 0.5rem);
    background-color: #ffffff;
}

.wizard-summary-info h4 {
    margin: 0 0 var(--ds-space-1, 0.25rem) 0;
    font-size: var(--ds-font-size-lg, 1.125rem);
    font-weight: var(--ds-font-weight-semibold, 600);
    color: var(--ds-color-neutral-900, #1a202c);
}

.wizard-summary-info p {
    margin: 0;
    font-size: var(--ds-font-size-sm, 0.875rem);
    color: var(--ds-color-neutral-600, #718096);
}

.wizard-summary-inputs {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--ds-space-3, 0.75rem);
    align-items: start;
}

.wizard-summary-inputs > div {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.wizard-summary-input {
    width: 100%;
    min-width: 100px;
}

/* Mobile: Stack inputs in single column */
@media (max-width: 768px) {
    .wizard-summary-inputs {
        grid-template-columns: 1fr;
    }
}

/* ============================================================================
   File Upload
   ========================================================================== */

.wizard-upload-area {
    border: 2px dashed var(--ds-color-neutral-300, #e2e8f0);
    border-radius: var(--ds-radius-lg, 0.75rem);
    padding: var(--ds-space-8, 2rem);
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease-out;
}

.wizard-upload-area:hover {
    border-color: var(--ds-color-primary, #009634);
    background: var(--ds-color-primary-bg, #f0fdf4);
}

.wizard-upload-area.dragover {
    border-color: var(--ds-color-primary, #009634);
    background: var(--ds-color-primary-bg, #f0fdf4);
}

/* ============================================================================
   Responsive
   ========================================================================== */

@media (max-width: 768px) {
    .wizard-progress {
        padding: var(--ds-space-4, 1rem) var(--ds-space-3, 0.75rem);
    }

    .wizard-progress-title {
        font-size: var(--ds-font-size-xl, 1.25rem);
        margin-bottom: var(--ds-space-4, 1rem);
    }

    .wizard-progress-steps {
        display: flex;
        justify-content: space-between;
        align-items: flex-start;
        gap: var(--ds-space-1, 0.25rem);
        margin-bottom: var(--ds-space-2, 0.5rem);
        min-width: 0;
    }

    .wizard-progress-line {
        top: 18px;
        left: 5%;
        right: 5%;
    }

    .wizard-step-indicator {
        flex: 1 1 0;
        width: auto;
    }

    .wizard-step-label {
        font-size: var(--ds-font-size-xs, 0.75rem);
        max-width: 100%;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .wizard-step-circle {
        width: 36px;
        height: 36px;
        font-size: var(--ds-font-size-xs, 0.75rem);
        border-width: 2px;
    }

    .wizard-step-indicator.active .wizard-step-circle {
        transform: none;
    }
    
    .wizard-content {
        padding: var(--ds-space-4, 1rem);
    }
    
    .wizard-navigation {
        flex-direction: column;
        gap: var(--ds-space-4, 1rem);
    }

    .wizard-nav-left {
        width: 100%;
        flex-direction: column;
    }
    
    .wizard-nav-buttons {
        width: 100%;
        flex-direction: column;
    }

    .wizard-nav-buttons--final {
        flex-direction: column-reverse;
    }
    
    .wizard-btn {
        width: 100%;
        justify-content: center;
        min-height: var(--ds-touch-target-min);
    }
    
    .wizard-summary-item {
        grid-template-columns: 1fr;
    }
    
    .wizard-filters-row {
        grid-template-columns: 1fr;
    }

    .wizard-toolbar-bar {
        flex-direction: column;
        align-items: stretch;
        gap: var(--ds-space-3, 0.75rem);
    }

    .wizard-toolbar-group {
        flex-wrap: wrap;
        justify-content: space-between;
        width: 100%;
    }

    .wizard-select-inline {
        width: 100%;
        min-width: 0;
    }

    .wizard-category-header {
        flex-wrap: wrap;
        gap: var(--ds-space-2, 0.5rem);
    }

    .wizard-category-name-input {
        min-width: 0;
        flex: 1 1 calc(100% - 80px);
    }

    .wizard-category-count {
        margin-left: 0;
        flex: 0 0 auto;
    }

    .wizard-selection-bar-inner {
        flex-direction: column;
        align-items: stretch;
    }

    .wizard-selection-actions {
        justify-content: flex-end;
    }

    .wizard-btn-compact {
        min-height: var(--ds-touch-target-min);
        padding: var(--ds-space-2) var(--ds-space-3);
    }
}

@media (max-width: 480px) {
    .wizard-step-indicator:not(.active) .wizard-step-label {
        display: none;
    }
}

@media (max-width: 360px) {
    .wizard-step-circle {
        width: 32px;
        height: 32px;
    }

    .wizard-progress-line {
        top: 16px;
    }
}
/* ============================================================================
   Custom Collection Fields in Wizard
   ========================================================================== */

/* Button Group for Grid Controls */
.btn-group {
    display: inline-flex;
    gap: 0;
}

.btn-group .tw-btn {
    border-radius: 0;
    border-right: none;
}

.btn-group .tw-btn:first-child {
    border-top-left-radius: var(--ds-radius-md, 0.5rem);
    border-bottom-left-radius: var(--ds-radius-md, 0.5rem);
}

.btn-group .tw-btn:last-child {
    border-top-right-radius: var(--ds-radius-md, 0.5rem);
    border-bottom-right-radius: var(--ds-radius-md, 0.5rem);
    border-right: 1px solid var(--ds-color-neutral-300, #d1d5db);
}

.btn-group .tw-btn.tw-btn-primary:last-child {
    border-right: 1px solid var(--ds-color-primary, #009634);
}

.wizard-custom-fields {
    margin-top: var(--space-xl, 2rem);
    padding-top: var(--space-lg, 1.5rem);
}

.wizard-custom-fields .tw-divider {
    display: flex;
    align-items: center;
    text-align: center;
    gap: var(--space-md, 1rem);
    color: var(--ds-color-neutral-600, #6b7280);
    font-size: var(--ds-font-size-sm, 0.875rem);
    font-weight: 600;
    margin: var(--space-lg, 1.5rem) 0;
}

.wizard-custom-fields .tw-divider::before,
.wizard-custom-fields .tw-divider::after {
    content: '';
    flex: 1;
    border-bottom: 2px solid var(--ds-color-neutral-200, #e5e7eb);
}

.wizard-custom-fields .tw-form-group {
    margin-bottom: var(--space-lg, 1.5rem);
}

.wizard-custom-fields .form-label {
    font-weight: 600;
    color: var(--ds-color-neutral-900, #111827);
    margin-bottom: var(--space-sm, 0.5rem);
    display: block;
}

.wizard-custom-fields .form-control,
.wizard-custom-fields .form-select {
    width: 100%;
    padding: var(--space-sm, 0.5rem) var(--space-md, 1rem);
    border: 2px solid var(--ds-color-neutral-300, #d1d5db);
    border-radius: var(--radius-md, 0.5rem);
    font-size: var(--ds-font-size-base, 0.9375rem);
    transition: all 0.2s ease;
}

.wizard-custom-fields .form-control:focus,
.wizard-custom-fields .form-select:focus {
    outline: none;
    border-color: var(--ds-color-primary, #009634);
    box-shadow: 0 0 0 3px rgba(0, 150, 52, 0.1);
}

.wizard-custom-fields .form-text {
    font-size: var(--ds-font-size-sm, 0.875rem);
    color: var(--ds-color-neutral-600, #6b7280);
    margin-top: var(--space-xs, 0.25rem);
    display: block;
}

.wizard-custom-fields .text-danger {
    color: var(--color-danger, #dc2626);
}