/* Main Container */
.product-create-container {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 1rem;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* Form Header */
.form-header {
    text-align: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #eee;
}

.form-header h1 {
    color: #2c3e50;
    font-weight: 600;
}

.form-header .subtitle {
    color: #7f8c8d;
    font-size: 1.1rem;
}

/* Form Sections */
.form-section {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.section-title {
    color: #3498db;
    font-size: 1.3rem;
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #eee;
}

/* Form Grid Layout */
.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-bottom: 1rem;
}

.form-group {
    margin-bottom: 1.25rem;
}

.full-width {
    grid-column: 1 / -1;
}

/* Form Elements */
.form-control, .form-select {
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 0.75rem;
    transition: all 0.3s;
}

.form-control:focus, .form-select:focus {
    border-color: #3498db;
    box-shadow: 0 0 0 0.2rem rgba(52, 152, 219, 0.25);
}

/* Price Display */
.price-preview, .discount-info {
    font-size: 0.9rem;
    color: #555;
    margin-top: 0.5rem;
}

.price-preview span {
    font-weight: bold;
    color: #27ae60;
}

.discount-info span {
    font-weight: bold;
    color: #e74c3c;
}

/* Stock Indicator */
.stock-indicator {
    margin-top: 0.5rem;
}

.stock-bar {
    height: 5px;
    background: #ecf0f1;
    border-radius: 3px;
    margin-bottom: 0.25rem;
}

.stock-bar::after {
    content: '';
    display: block;
    height: 100%;
    width: 0%;
    background: #27ae60;
    border-radius: 3px;
    transition: width 0.5s;
}

#stockStatus {
    font-size: 0.85rem;
    color: #7f8c8d;
}

/* Color Picker */
.color-picker-group .form-control {
    padding: 0.2rem;
    height: 40px;
    width: 80px;
}

.color-preview {
    width: 40px;
    height: 40px;
    border-radius: 4px;
    margin-top: 0.5rem;
    border: 1px solid #ddd;
}

/* Image Upload */
.image-upload-container {
    margin-top: 1rem;
}

.image-dropzone {
    border: 2px dashed #bdc3c7;
    border-radius: 8px;
    padding: 2rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    margin-bottom: 1rem;
}

.image-dropzone:hover {
    border-color: #3498db;
    background: #f8f9fa;
}

.image-dropzone i {
    font-size: 2rem;
    color: #3498db;
    margin-bottom: 0.5rem;
}

.image-dropzone p {
    margin: 0;
    color: #7f8c8d;
}

#imageInput {
    display: none;
}

.image-preview-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 1rem;
    margin-bottom: 1rem;
}

.image-preview-item {
    position: relative;
    border-radius: 4px;
    overflow: hidden;
    height: 120px;
}

.image-preview-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.image-preview-item .remove-image {
    position: absolute;
    top: 5px;
    right: 5px;
    background: rgba(231, 76, 60, 0.8);
    color: white;
    border: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.image-notes {
    font-size: 0.85rem;
    color: #7f8c8d;
}

.image-notes i {
    margin-right: 0.3rem;
}

/* Toggle Switch */
.feature-toggle {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.toggle-switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 24px;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-switch label {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: .4s;
    border-radius: 24px;
}

.toggle-switch label:before {
    position: absolute;
    content: "";
    height: 16px;
    width: 16px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    transition: .4s;
    border-radius: 50%;
}

.toggle-switch input:checked + label {
    background-color: #2196F3;
}

.toggle-switch input:checked + label:before {
    transform: translateX(26px);
}

/* Form Actions */
.form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    margin-top: 2rem;
}

.btn-submit, .btn-preview, .btn-cancel {
    padding: 0.75rem 1.5rem;
    border-radius: 4px;
    font-weight: 500;
    transition: all 0.3s;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-submit {
    background-color: #3498db;
    color: white;
    border: none;
}

.btn-submit:hover {
    background-color: #2980b9;
}

.btn-preview {
    background-color: #2ecc71;
    color: white;
    border: none;
}

.btn-preview:hover {
    background-color: #27ae60;
}

.btn-cancel {
    background-color: #f8f9fa;
    color: #6c757d;
    border: 1px solid #dee2e6;
    text-decoration: none;
}

.btn-cancel:hover {
    background-color: #e9ecef;
}

/* Modals */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
}

.modal-content {
    background-color: white;
    margin: 5% auto;
    padding: 1.5rem;
    border-radius: 8px;
    max-width: 800px;
    width: 90%;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #eee;
}

.modal-header h3 {
    margin: 0;
    color: #2c3e50;
}

.close-modal {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #7f8c8d;
}

.size-chart table {
    width: 100%;
    border-collapse: collapse;
}

.size-chart th, .size-chart td {
    padding: 0.75rem;
    text-align: left;
    border-bottom: 1px solid #eee;
}

.size-chart th {
    background-color: #f8f9fa;
    font-weight: 600;
}

/* Responsive */
@media (max-width: 768px) {
    .form-grid {
        grid-template-columns: 1fr;
    }
    
    .form-actions {
        flex-direction: column;
    }
    
    .btn-submit, .btn-preview, .btn-cancel {
        width: 100%;
        justify-content: center;
    }
}