/* Scoped styles for Edit Product page */
#edit-product-form .edit-form-group {
    margin-bottom: 1.5rem;
}

#edit-product-form .edit-form-input {
    margin-top: 0.25rem;
    display: block;
    width: 100%;
    border: 2px solid var(--muted);
    border-radius: 0.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    padding: 0.75rem;
    font-size: 0.875rem;
    transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
    font-family: 'Montserrat', sans-serif;
}

#edit-product-form .edit-form-input:focus {
    border-color: var(--poet-accent);
    box-shadow: 0 0 0 3px rgba(146, 121, 99, 0.2);
    outline: none;
}

#edit-product-form .edit-form-input:hover {
    border-color: var(--poet-accent);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

/* Image Grid */
#edit-product-form .edit-image-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 1rem;
    margin-top: 0.5rem;
}

#edit-product-form .edit-image-item {
    position: relative;
}

#edit-product-form .edit-image-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
}

#edit-product-form .edit-image-item:hover .edit-image-overlay {
    background: rgba(0, 0, 0, 0.5);
    opacity: 1;
}

#edit-product-form .edit-primary-label {
    position: absolute;
    top: 0.5rem;
    left: 0.5rem;
    background-color: var(--poet-accent);
    color: white;
    font-size: 0.75rem;
    padding: 0.25rem 0.5rem;
    border-radius: 9999px;
}

#edit-product-form .edit-image-placeholder {
    border: 2px dashed var(--muted);
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 128px;
    cursor: pointer;
    transition: border-color 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
}

#edit-product-form .edit-image-placeholder:hover {
    border-color: var(--poet-accent);
}

#edit-product-form .edit-add-image-label {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    cursor: pointer;
}

/* Image Preview Grid */
#edit-product-form .edit-image-preview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 1rem;
}

#edit-product-form .edit-image-preview-item {
    position: relative;
    animation: poeticFade 0.3s ease-out;
}

#edit-product-form .edit-image-preview-item img {
    width: 100%;
    height: 128px;
    object-fit: cover;
    border-radius: 0.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

#edit-product-form .edit-image-preview-item .edit-image-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
}

#edit-product-form .edit-image-preview-item:hover .edit-image-overlay {
    background: rgba(0, 0, 0, 0.5);
    opacity: 1;
}

/* File List */
#edit-product-form .edit-file-list {
    margin-top: 0.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

#edit-product-form .edit-file-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #f9fafb;
    padding: 0.5rem;
    border-radius: 0.5rem;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
    animation: poeticFade 0.3s ease-out;
}

#edit-product-form .edit-file-placeholder {
    border: 2px dashed var(--muted);
    border-radius: 0.5rem;
    padding: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: border-color 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
}

#edit-product-form .edit-file-placeholder:hover {
    border-color: var(--poet-accent);
}

#edit-product-form .edit-add-file-label {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    cursor: pointer;
}

/* File Preview List */
#edit-product-form .edit-file-preview-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

#edit-product-form .edit-file-preview-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #f9fafb;
    padding: 0.5rem;
    border-radius: 0.5rem;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
    animation: poeticFade 0.3s ease-out;
}

/* Buttons */
#edit-product-form .edit-btn {
    padding: 0.25rem 0.75rem;
    font-size: 0.75rem;
    border-radius: 0.25rem;
    transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
}

#edit-product-form .edit-btn-primary {
    background-color: var(--primary);
    color: white;
}

#edit-product-form .edit-btn-primary:hover {
    background-color: var(--secondary);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

#edit-product-form .edit-btn-primary::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    transform: translate(-50%, -50%);
    opacity: 0;
    z-index: 1;
}

#edit-product-form .edit-btn-primary:hover::after {
    animation: buttonRipple 1.2s ease-out forwards;
}

#edit-product-form .edit-btn-danger {
    background-color: #ef4444;
    color: white;
}

#edit-product-form .edit-btn-danger:hover {
    background-color: #dc2626;
}

#edit-product-form .edit-btn-remove {
    background-color: #6b7280;
    color: white;
}

#edit-product-form .edit-btn-remove:hover {
    background-color: #4b5563;
}

#edit-product-form .edit-btn-discard {
    padding: 0.75rem 1.5rem;
    background-color: #6b7280;
    color: white;
    font-family: 'Cormorant Garamond', serif;
    font-size: 0.875rem;
    border-radius: 0.5rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
    text-decoration: none;
    text-align: center;
    display: inline-block;
}

#edit-product-form .edit-btn-discard:hover {
    background-color: #4b5563;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

#edit-product-form .edit-submit-btn {
    width: 100%;
    padding: 0.75rem 1.5rem;
    background-color: var(--poet-accent);
    color: white;
    font-family: 'Cormorant Garamond', serif;
    font-size: 0.875rem;
    border-radius: 0.5rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
}

#edit-product-form .edit-submit-btn:hover {
    background-color: #7b6653;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

/* Animations */
@keyframes buttonRipple {
    0% { width: 0; height: 0; opacity: 1; }
    100% { width: 200px; height: 200px; opacity: 0; }
}

@keyframes poeticFade {
    0% { opacity: 0; transform: translateY(5px); }
    100% { opacity: 1; transform: translateY(0); }
}