.dt-rag-form-wrapper {
    max-width: 800px;
    margin: 2rem auto;
    padding: 1rem;
}

.dt-rag-form {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    padding: 2rem;
}

/* Section Styling */
.dt-rag-section {
    display: flex;
    flex-direction: column;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #eee;

}

.dt-rag-section:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

/* Labels */
.dt-rag-label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #333;
}

/* Input Fields */
.dt-rag-input {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1rem;
    line-height: 1.5;
    transition: border-color 0.2s ease;
}

.dt-rag-input:focus {
    outline: none;
    border-color: #0073aa;
    box-shadow: 0 0 0 1px #0073aa;
}

/* Date Picker */
.dt-rag-date-picker {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.dt-rag-attendance.disabled {
    opacity: 0.6;
}

.dt-rag-attendance.disabled input {
    background-color: #f5f5f5;
    cursor: not-allowed;
}

/* Add visual indicator for required fields */
.dt-rag-label.required:after {
    content: "*";
    color: #dc3545;
    margin-left: 4px;
}

/* Checkboxes */
.dt-rag-checkbox-wrapper {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}


input.dt-rag-checkbox {
    appearance: none!important;
    -webkit-appearance: none!important;
    width: 20px!important;
    height: 20px!important;
    border: 2px solid #666;
    border-radius: 4px!important;
    margin: 0!important;
    cursor: pointer!important;
    position: relative!important;
    background-color: #fff!important;
}

input.dt-rag-checkbox:checked {
    background-color: #0073aa!important;
    border-color: #0073aa!important;
}

input.dt-rag-checkbox:checked::after {
    content: "✓"!important;
    position: absolute!important;
    color: #fff!important;
    font-size: 14px!important;
    left: 50%!important;
    top: 50%!important;
    transform: translate(-50%, -50%)!important;
}

/* Meeting Section */
.dt-rag-meeting {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 4px;
    border: 1px solid #e9ecef;
}

h4.dt-rag-meeting-title {
    margin: 0 0 1rem 0!important;
    font-size: 1.1rem!important;
    color: #333!important;
}

.dt-rag-meeting-fields {
    display: flex;
    align-items: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.dt-rag-attendance {
    flex: 1;
    min-width: 200px;
}

/* Input Groups */
.dt-rag-input-group {
    display: flex;
    align-items: center;
}

.dt-rag-input-group .dt-rag-input {
    border-radius: 4px 0 0 4px;
    max-width: 100px;
}

.dt-rag-input-suffix {
    padding: 0.75rem 1rem;
    background: #e9ecef;
    border: 1px solid #ddd;
    border-left: none;
    border-radius: 0 4px 4px 0;
    color: #666;
}

/* RAG Status */
.dt-rag-status {
    margin-bottom: 1.5rem;
}

.dt-rag-status-label {
    display: block;
    padding: 0.75rem 1rem;
    border-radius: 4px 4px 0 0;
    color: white;
    font-weight: 500;
}

.dt-rag-status-red { background-color: #dc3545; }
.dt-rag-status-amber { background-color: #ffc107; color: #000; }
.dt-rag-status-green { background-color: #28a745; }

.dt-rag-textarea {
    width: 100%;
    min-height: 100px;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-top: none;
    border-radius: 0 0 4px 4px;
    resize: vertical;
    font-family: inherit;
    line-height: 1.5;
}

/* Radio Buttons */
.dt-rag-radio-group {
    display: flex;
    gap: 1rem;
    margin-top: 0.5rem;
}

.dt-rag-radio {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.dt-rag-radio-red { background-color: #fde8e8; }
.dt-rag-radio-amber { background-color: #fff3cd; }
.dt-rag-radio-green { background-color: #d4edda; }

.dt-rag-radio:hover {
    transform: translateY(-2px);
}

.dt-rag-radio input[type="radio"] {
    margin-right: 0.5rem;
}

/* Submit Button */
.dt-rag-submit {
    background: #0073aa;
    color: #fff;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 500;
    transition: background-color 0.2s ease;
}

.dt-rag-submit:hover {
    background: #005177;
}

.dt-rag-submit:disabled {
    background: #ccc;
    cursor: not-allowed;
}

/* Spinner */
.dt-rag-spinner {
    display: none;
    width: 20px;
    height: 20px;
    margin-left: 1rem;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #0073aa;
    border-radius: 50%;
    animation: dt-rag-spin 1s linear infinite;
}

@keyframes dt-rag-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Responsive Design */
@media screen and (max-width: 768px) {
    .dt-rag-form {
        padding: 1rem;
    }

    .dt-rag-date-picker {
        grid-template-columns: 1fr;
    }

    .dt-rag-meeting-fields {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .dt-rag-attendance {
        width: 100%;
    }

    .dt-rag-radio-group {
        flex-direction: column;
    }

    .dt-rag-radio {
        width: 100%;
        justify-content: flex-start;
    }
}

/* Validation States */
.dt-rag-input.error,
.dt-rag-textarea.error {
    border-color: #dc3545;
    background-color: #fff8f8;
}

.dt-rag-notice {
    padding: 1rem;
    margin-bottom: 1rem;
    border-radius: 4px;
    border-left: 4px solid;
}

.dt-rag-notice-success {
    background-color: #d4edda;
    border-left-color: #28a745;
    color: #155724;
}

.dt-rag-notice-error {
    background-color: #f8d7da;
    border-left-color: #dc3545;
    color: #721c24;
}

.dt-rag-notice-warning {
    background-color: #fff3cd;
    border-left-color: #ffc107;
    color: #856404;
}

/* RAG Reports Container */
.dt-rag-reports-table {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    margin: 2rem 0;
    padding: 1.5rem;
}

/* Filters Section */
.dt-rag-filters {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2rem;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 6px;
}

.dt-rag-filter-group {
    flex: 1;
    min-width: 200px;
}

.dt-rag-filter-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #344767;
}

.dt-rag-input {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    font-size: 14px;
}

.dt-rag-input:focus {
    outline: none;
    border-color: #80bdff;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

.dt-rag-date-range {
    display: flex;
    gap: 1rem;
}

.dt-rag-button {
    background: #4CAF50;
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 500;
    transition: background-color 0.2s;
}

.dt-rag-button:hover {
    background: #45a049;
}

/* Table Styles */
#dt-rag-reports-data {
    width: 100%;
    /* border-collapse: separate; */
    border-collapse: collapse;
    border-spacing: 0;
    margin-top: 1rem;
}

#dt-rag-reports-data th,
#dt-rag-reports-data td {
    padding: 1rem;
    border-bottom: 1px solid #eee;
    text-align: left;
}

#dt-rag-reports-data th {
    background: #f8f9fa;
    font-weight: 600;
    color: #344767;
}

#dt-rag-reports-data tbody tr:hover {
    background-color: #f8f9fa;
}

/* Meeting Status Styles */
.dt-rag-meeting-status {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

/* RAG Status Indicators */
.dt-rag-status {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 999px;
    font-size: 0.875rem;
    font-weight: 500;
}

.dt-rag-status.dt-rag-red {
    background: #ffebee;
    color: #d32f2f;
}

.dt-rag-status.dt-rag-amber {
    background: #fff3e0;
    color: #f57c00;
}

.dt-rag-status.dt-rag-green {
    background: #e8f5e9;
    color: #2e7d32;
}

/* View Button */
.dt-rag-view-report {
    background: #4CAF50!important;
    color: white!important;
    border: none!important;
    padding: 0.5rem 1rem!important;
    border-radius: 20px!important;
    cursor: pointer!important;
    font-size: 0.875rem!important;
    transition: all 0.2s!important;
    min-width: 60px!important; 
}

.dt-rag-view-report:hover {
    background: #45a049;
    transform: translateY(-1px);
}

/* Report Details Section */
.dt-rag-report-details {
    width: 100%;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    padding: 1.5rem;
    margin: 0;
    transition: opacity 0.3s ease;
}

.dt-rag-details-cell {
    display: table-cell;
    padding: 0 !important;
}

.dt-rag-details-row {
    display: table-row;
    width: 100%;
    transition: all 0.3s ease;
}

.dt-rag-details-row td {
    padding: 0 !important;
}

.dt-rag-detail-section {
    margin-bottom: 1.5rem;
}

.dt-rag-detail-section h4 {
    color: #344767;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #eee;
}

.dt-rag-detail-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1rem;
}

.dt-rag-detail-table th,
.dt-rag-detail-table td {
    padding: 0.75rem;
    border-bottom: 1px solid #eee;
}

.dt-rag-detail-table th {
    width: 30%;
    color: #666;
    font-weight: 600;
}

/* Status Updates in Details */
.dt-rag-status-update {
    margin-bottom: 1rem;
    padding: 1rem;
    border-radius: 6px;
}

.dt-rag-status-update h5 {
    margin: 0 0 0.5rem 0;
    font-weight: 600;
}

.dt-rag-status-update.dt-rag-red {
    background: #ffebee;
}

.dt-rag-status-update.dt-rag-amber {
    background: #fff3e0;
}

.dt-rag-status-update.dt-rag-green {
    background: #e8f5e9;
}

.dt-rag-detail-meta {
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid #eee;
    color: #666;
    font-size: 0.875rem;
}

/* Loading States */
.dt-rag-loading-spinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #4CAF50;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: dt-rag-spin 1s linear infinite;
    margin: 2rem auto;
}

@keyframes dt-rag-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.dt-rag-loading-row td {
    text-align: center;
    padding: 2rem;
}

/* Pagination */
.dt-rag-pagination {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 1.5rem;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 6px;
}

.dt-rag-pagination-controls {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.dt-rag-page-info {
    margin: 0 1rem;
    color: #666;
}

/* Responsive Design */
@media (max-width: 768px) {
    .dt-rag-filters {
        flex-direction: column;

    }
    
    .dt-rag-filter-group {
        width: 100%;
    }
    
    .dt-rag-date-range {
        flex-direction: column;
    }
    
    .dt-rag-pagination {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
    
    .dt-rag-detail-table {
        display: block;
        overflow-x: auto;
    }
}

/* Reports Table */

/* .dt-rag-reports-table {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
}
#dt-rag-reports-data {
    width: 100%;
    border-collapse: collapse;
    margin: 1em 0;
}
#dt-rag-reports-data th,
#dt-rag-reports-data td {
    padding: 8px;
    border: 1px solid #ddd;
}
.dt-rag-loading-spinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #3498db;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: dt-rag-spin 1s linear infinite;
    margin: 20px auto;
}
@keyframes dt-rag-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
} */

/* Add to public/css/dotank-rag-public.css */

/* Edit Form Styles */
.dt-rag-edit-form-wrapper {
    width: 100%;
    padding: 1.5rem;
    background: #f8f9fa;
}

.dt-rag-edit-form {
    width: 100%;
    max-width: none;
    margin: 0;
}

.dt-rag-meeting-edit {
    margin-bottom: 1.5rem;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 4px;
}

.dt-rag-meeting-edit:last-child {
    margin-bottom: 0;
}

.dt-rag-meeting-edit h5 {
    margin: 0 0 0.5rem 0;
    font-weight: 600;
    color: #344767;
}

.dt-rag-attendance {
    margin-top: 0.5rem;
}

.dt-rag-attendance input[type="number"] {
    width: 100px;
    padding: 0.5rem;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.dt-rag-status-edit {
    margin-bottom: 1rem;
    padding: 1rem;
    border-radius: 4px;
}

.dt-rag-status-edit.dt-rag-red {
    background: #fff2f0;
}

.dt-rag-status-edit.dt-rag-amber {
    background: #fffbe6;
}

.dt-rag-status-edit.dt-rag-green {
    background: #f6ffed;
}

.dt-rag-status-edit textarea {
    width: 100%;
    margin-top: 0.5rem;
    padding: 0.5rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    resize: vertical;
}

.dt-rag-form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #eee;
}

.dt-rag-cancel-edit {
    background-color: #6c757d !important;
}

.dt-rag-save-edit {
    background-color: #28a745 !important;
}

.dt-rag-edit-form .dt-rag-radio-group {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

.dt-rag-actions {
    display: flex;
    gap: 0.5rem;
}

.dt-rag-edit-report {
    background-color: #ffa500 !important; /* Orange color to distinguish from view button */
}

.dt-rag-edit-report[disabled],
.dt-rag-view-report[disabled] {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Style for when in edit mode */
.dt-rag-edit-report.editing {
    background-color: #dc3545 !important; /* Red color for cancel state */
}

/* Error states */
.dt-rag-edit-form .error {
    border-color: #dc3545;
    background-color: #fff2f0;
}

/* Loading state */
.dt-rag-save-edit:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .dt-rag-form-actions {
        flex-direction: column;
    }
    
    .dt-rag-form-actions button {
        width: 100%;
    }
    
    .dt-rag-edit-form .dt-rag-radio-group {
        flex-direction: column;
    }
}