/* AL Multiple Attributes - Frontend Styles */

.alma-multiple-attributes-container {
    margin: 20px 0;
    padding: 20px;
    background-color: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.alma-multiple-attributes-container h4 {
    margin: 0 0 15px 0;
    color: #333;
    font-size: 16px;
    font-weight: 600;
    border-bottom: 2px solid #0073aa;
    padding-bottom: 8px;
}

.alma-selections-wrapper {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.alma-attribute-group {
    background-color: #fff;
    padding: 15px;
    border-radius: 6px;
    border: 1px solid #ddd;
}

.alma-attribute-group label {
    display: block;
    font-weight: 600;
    color: #333;
    margin-bottom: 10px;
    font-size: 14px;
}

.alma-selections {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.alma-selection-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px;
    background-color: #f8f9fa;
    border-radius: 4px;
    border: 1px solid #e9ecef;
}

.alma-attribute-select {
    flex: 1;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    background-color: #fff;
    min-width: 150px;
}

.alma-attribute-select:focus {
    outline: none;
    border-color: #0073aa;
    box-shadow: 0 0 0 2px rgba(0, 115, 170, 0.2);
}

.alma-add-selection,
.alma-remove-selection {
    padding: 8px 12px;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s ease;
    min-width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.alma-add-selection {
    background-color: #28a745;
    color: #fff;
}

.alma-add-selection:hover {
    background-color: #218838;
    transform: scale(1.05);
}

.alma-remove-selection {
    background-color: #dc3545;
    color: #fff;
}

.alma-remove-selection:hover {
    background-color: #c82333;
    transform: scale(1.05);
}

/* Cart display styles */
.alma-multiple-attributes {
    color: #666;
    font-size: 12px;
    line-height: 1.4;
}

.alma-multiple-attributes br {
    margin-bottom: 2px;
}

/* Order display styles */
.alma-multiple-attributes-order {
    margin-top: 15px;
    padding: 15px;
    background-color: #f8f9fa;
    border-radius: 6px;
    border: 1px solid #e9ecef;
}

.alma-multiple-attributes-order h4 {
    margin: 0 0 10px 0;
    color: #333;
    font-size: 14px;
    font-weight: 600;
}

.alma-attribute-order {
    margin-bottom: 8px;
    padding: 5px 0;
    border-bottom: 1px solid #e9ecef;
}

.alma-attribute-order:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.alma-attribute-order strong {
    color: #333;
    font-weight: 600;
}

/* Email styles */
.alma-multiple-attributes-email {
    margin-top: 10px;
    padding: 10px;
    background-color: #f8f9fa;
    border-radius: 4px;
}

.alma-attribute-email {
    margin-bottom: 5px;
    font-size: 12px;
}

.alma-attribute-email strong {
    color: #333;
    font-weight: 600;
}

/* Responsive design */
@media (max-width: 768px) {
    .alma-multiple-attributes-container {
        padding: 15px;
        margin: 15px 0;
    }
    
    .alma-attribute-group {
        padding: 12px;
    }
    
    .alma-selection-row {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }
    
    .alma-attribute-select {
        min-width: auto;
    }
    
    .alma-add-selection,
    .alma-remove-selection {
        align-self: center;
        width: 100%;
        max-width: 200px;
    }
}

@media (max-width: 480px) {
    .alma-multiple-attributes-container {
        padding: 10px;
    }
    
    .alma-attribute-group {
        padding: 10px;
    }
    
    .alma-selection-row {
        padding: 6px;
    }
    
    .alma-attribute-select {
        padding: 6px 8px;
        font-size: 13px;
    }
}

/* Animation for adding/removing selections */
.alma-selection-row {
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Loading state */
.alma-loading {
    opacity: 0.6;
    pointer-events: none;
}

.alma-loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #0073aa;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Success/error states */
.alma-success {
    border-color: #28a745;
    background-color: #d4edda;
}

.alma-error {
    border-color: #dc3545;
    background-color: #f8d7da;
}

/* Accessibility */
.alma-add-selection:focus,
.alma-remove-selection:focus {
    outline: 2px solid #0073aa;
    outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .alma-multiple-attributes-container {
        border-width: 2px;
    }
    
    .alma-attribute-group {
        border-width: 2px;
    }
    
    .alma-selection-row {
        border-width: 2px;
    }
} 