/* Global Styles */
:root {
    --primary: #6610f2;
    --primary-light: #7b31f4;
    --secondary: #6c757d;
    --success: #20c997;
    --info: #0dcaf0;
    --warning: #ffc107;
    --danger: #dc3545;
    --light: #f8f9fa;
    --dark: #212529;
    --transition-speed: 0.3s;
}

body {
    font-family: 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: linear-gradient(to bottom, #f8f9fa, #e9ecef);
    min-height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

/* Stepper Styles */
.stepper-container {
    padding: 20px 0;
}

.stepper-wrapper {
    display: flex;
    justify-content: space-between;
    margin: 0 auto;
    max-width: 700px;
}

.stepper-item {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    flex: 1;
}

.stepper-item::before {
    position: absolute;
    content: "";
    border-bottom: 2px solid #ccc;
    width: 100%;
    top: 20px;
    left: -50%;
    z-index: 0;
}

.stepper-item::after {
    position: absolute;
    content: "";
    border-bottom: 2px solid #ccc;
    width: 100%;
    top: 20px;
    left: 50%;
    z-index: 0;
}

.stepper-item:first-child::before {
    content: none;
}

.stepper-item:last-child::after {
    content: none;
}

.stepper-item.active .step-counter, 
.stepper-item.completed .step-counter {
    background-color: var(--primary);
    color: white;
}

.stepper-item.active .step-name, 
.stepper-item.completed .step-name {
    color: var(--primary);
    font-weight: 600;
}

.stepper-item.active::before,
.stepper-item.active::after,
.stepper-item.completed::before,
.stepper-item.completed::after {
    border-color: var(--primary);
}

.step-counter {
    position: relative;
    z-index: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: #ccc;
    color: #fff;
    margin-bottom: 6px;
    transition: all var(--transition-speed) ease;
}

.step-name {
    font-size: 14px;
    font-weight: 500;
    color: var(--secondary);
    transition: all var(--transition-speed) ease;
}

/* Step Sections */
.step-section {
    display: none;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.step-section.active-step {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

.section-title {
    margin-bottom: 0.5rem;
    color: var(--dark);
}

/* Card Styles */
.card {
    border: none;
    border-radius: 12px;
    overflow: hidden;
    transition: all var(--transition-speed) ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
}

.card-header {
    padding: 1.5rem 1rem 0.5rem;
}

.card-img-wrapper {
    position: relative;
    overflow: hidden;
}

.card-img-top {
    height: 200px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.card:hover .card-img-top {
    transform: scale(1.05);
}

.card-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.selected-card {
    border: 2px solid var(--primary);
    box-shadow: 0 0 0 2px rgba(102, 16, 242, 0.2), 0 8px 20px rgba(0, 0, 0, 0.1);
}

/* Upload Form Styles */
.image-upload-container {
    position: relative;
    margin-bottom: 1rem;
}

.image-upload-wrapper {
    position: relative;
    width: 100%;
    border: 2px dashed #ced4da;
    border-radius: 8px;
    padding: 1.5rem;
    text-align: center;
    cursor: pointer;
    transition: all var(--transition-speed) ease;
}

.image-upload-wrapper:hover {
    border-color: var(--primary);
    background-color: rgba(102, 16, 242, 0.03);
}

.image-upload-input {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
    z-index: 10;
}

.image-upload-placeholder {
    color: var(--secondary);
}

.image-preview-container {
    position: relative;
    width: 100%;
    margin-top: 1rem;
}

.image-preview {
    width: 100%;
    max-height: 200px;
    object-fit: contain;
    border-radius: 8px;
}

.remove-image {
    position: absolute;
    top: 10px;
    right: 10px;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.8);
}

/* Gallery Styles */
.gallery-card {
    position: relative;
}

.card-actions {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 10;
    opacity: 0;
    transition: opacity var(--transition-speed) ease;
}

.gallery-card:hover .card-actions {
    opacity: 1;
}

.selection-checkbox {
    width: 1.5rem;
    height: 1.5rem;
    cursor: pointer;
}

.form-check-label {
    cursor: pointer;
    font-size: 1.5rem;
    color: var(--primary);
}

.status-indicator {
    position: absolute;
    bottom: 10px;
    right: 10px;
}

/* Sortable Image Styles */
.sortable-card {
    position: relative;
}

.sort-handle {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 10;
    padding: 5px;
    background-color: rgba(255, 255, 255, 0.8);
    border-radius: 4px;
    cursor: move;
    color: var(--secondary);
    font-size: 1.2rem;
}

.sortable-image.dragging .sortable-card {
    opacity: 0.6;
    transform: scale(0.95);
}

.card-order-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background-color: var(--primary);
    color: white;
    width: 25px;
    height: 25px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 0.8rem;
}

/* Buttons */
.btn {
    border-radius: 8px;
    padding: 0.5rem 1.25rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.btn-lg {
    padding: 0.75rem 1.5rem;
}

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

.btn-primary:hover {
    background-color: var(--primary-light);
    border-color: var(--primary-light);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 16, 242, 0.2);
}

.save-order-btn {
    position: relative;
    overflow: hidden;
}

.save-order-btn:after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s ease-out, height 0.6s ease-out;
}

.save-order-btn:hover:after {
    width: 300px;
    height: 300px;
}

/* Stepper Navigation */
.stepper-navigation {
    /* position: fixed;
    bottom: 30px;
    left: 50%; */
    /* transform: translateX(-50%); */
    z-index: 1000;
    /* background: rgba(255, 255, 255, 0.9);
    padding: 10px 10px;
    border-radius: 20px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    transition: all 0.3s ease; */
    margin-bottom: 30px;

}

/* .stepper-navigation:hover {
    background: rgba(255, 255, 255, 1);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15);
} */

.stepper-navigation .btn {
    min-width: 120px;
    transition: all 0.3s ease;
}

.stepper-navigation .btn:hover {
    transform: translateY(-2px);
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .stepper-wrapper {
        max-width: 100%;
    }
    
    .step-name {
        font-size: 12px;
    }
    
    .card-img-top {
        height: 160px;
    }
}

@media (max-width: 576px) {
    .step-counter {
        width: 32px;
        height: 32px;
        font-size: 0.8rem;
    }
    
    .stepper-item::before,
    .stepper-item::after {
        top: 16px;
    }
}

/* Animations */
@keyframes fadeIn {
    0% { opacity: 0; transform: translateY(20px); }
    100% { opacity: 1; transform: translateY(0); }
}

.fade-in {
    animation: fadeIn 0.5s ease forwards;
}

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

.pulse {
    animation: pulse 2s infinite;
}