/* Steritech Services Frontend Styles */

#steritech-report-form-container {
    max-width: 800px;
    margin: 20px auto;
    padding: 20px;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

#steritech-report-form-container h2 {
    color: #333;
    border-bottom: 2px solid #0073aa;
    padding-bottom: 10px;
    margin-bottom: 20px;
}

#steritech-report-form-container h3 {
    color: #555;
    margin-top: 30px;
    margin-bottom: 15px;
    border-left: 4px solid #0073aa;
    padding-left: 15px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-weight: bold;
    margin-bottom: 5px;
    color: #333;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="date"],
.form-group input[type="number"],
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    box-sizing: border-box;
}

.form-group input[type="text"]:focus,
.form-group input[type="email"]:focus,
.form-group input[type="date"]:focus,
.form-group input[type="number"]:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: #0073aa;
    outline: none;
    box-shadow: 0 0 5px rgba(0,115,170,0.3);
}

.form-group textarea {
    resize: vertical;
    min-height: 80px;
}

/* Checklist Styles */
.checklist-group {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 10px;
    margin-top: 10px;
}

.checklist-group label {
    display: flex;
    align-items: center;
    font-weight: normal;
    margin-bottom: 0;
    cursor: pointer;
}

.checklist-group input[type="checkbox"] {
    width: auto;
    margin-right: 8px;
}

/* Parts and Services Rows */
.part-row,
.service-row {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr auto;
    gap: 10px;
    align-items: center;
    margin-bottom: 10px;
    padding: 10px;
    background: #f9f9f9;
    border-radius: 4px;
}

.part-row input,
.service-row input {
    margin-bottom: 0;
}

.part-row button,
.service-row button {
    background: #dc3232;
    color: white;
    border: none;
    padding: 5px 10px;
    border-radius: 3px;
    cursor: pointer;
    font-size: 12px;
}

.part-row button:hover,
.service-row button:hover {
    background: #a00;
}

.add-part-row,
.add-service-row {
    background: #0073aa;
    color: white;
    border: none;
    padding: 8px 15px;
    border-radius: 4px;
    cursor: pointer;
    margin-top: 10px;
}

.add-part-row:hover,
.add-service-row:hover {
    background: #005a87;
}

/* Form Actions */
.form-actions {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #ddd;
    text-align: right;
}

.form-actions .button {
    margin-left: 10px;
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    text-decoration: none;
    display: inline-block;
}

.form-actions .button-primary {
    background: #0073aa;
    color: white;
}

.form-actions .button-primary:hover {
    background: #005a87;
}

.form-actions .button-secondary {
    background: #f1f1f1;
    color: #333;
    border: 1px solid #ccc;
}

.form-actions .button-secondary:hover {
    background: #e1e1e1;
}

/* Totals */
.grand-total {
    font-weight: bold;
    background: #f0f8ff !important;
    border: 2px solid #0073aa !important;
}

/* Responsive Design */
@media (max-width: 768px) {
    #steritech-report-form-container {
        margin: 10px;
        padding: 15px;
    }
    
    .part-row,
    .service-row {
        grid-template-columns: 1fr;
        gap: 5px;
    }
    
    .checklist-group {
        grid-template-columns: 1fr;
    }
    
    .form-actions {
        text-align: center;
    }
    
    .form-actions .button {
        display: block;
        width: 100%;
        margin: 5px 0;
    }
}

/* Success/Error Messages */
.steritech-message {
    padding: 10px 15px;
    margin-bottom: 20px;
    border-radius: 4px;
}

.steritech-message.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.steritech-message.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

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

.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); }
}

