/* BACS Direct Debit Frontend Styles */

.gf-bacs-field {
    border: 2px solid #ddd;
    border-radius: 8px;
    padding: 20px;
    background: #f9f9f9;
    margin: 15px 0;
}

.gf-bacs-field h4 {
    margin: 0 0 15px 0;
    color: #2c3e50;
    font-size: 18px;
    font-weight: 600;
}

.gf-bacs-details ul {
    list-style: none;
    padding: 0;
    margin: 0 0 15px 0;
}

.gf-bacs-details li {
    padding: 5px 0;
    border-bottom: 1px solid #eee;
}

.gf-bacs-details li:last-child {
    border-bottom: none;
}

.gf-bacs-notice {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 15px;
    margin-top: 15px;
}

.gf-bacs-notice p {
    margin: 0;
    font-size: 14px;
    line-height: 1.5;
}

.gf-bacs-notice p:first-child {
    margin-bottom: 10px;
}

/* New styles for conditional notice and loading states */
.gf-bacs-submit-notice {
    transition: all 0.3s ease-in-out;
}

.gf-bacs-loading {
    text-align: center;
    margin: 15px 0;
}

.gf-bacs-loading .spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #0073aa;
    border-radius: 50%;
    animation: gfbacs-spin 1s linear infinite;
}

@keyframes gfbacs-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* BACS field styling */
.ginput_container_bacs {
    padding: 15px;
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    margin: 10px 0;
}

.ginput_container_bacs .gfield_description {
    color: #495057;
    font-size: 0.9em;
    margin-top: 8px;
}

/* Payment method conditional styling */
.gform_page .gfield {
    transition: opacity 0.3s ease-in-out;
}

/* Error message styling */
.gf-bacs-error {
    background: #f8d7da;
    color: #721c24;
    padding: 12px 16px;
    border: 1px solid #f5c6cb;
    border-radius: 4px;
    margin: 10px 0;
}

.gf-bacs-success {
    background: #d4edda;
    color: #155724;
    padding: 12px 16px;
    border: 1px solid #c3e6cb;
    border-radius: 4px;
    margin: 10px 0;
}

/* Form Editor Preview Styles */
.gf-bacs-field-preview {
    border: 2px dashed #ddd;
    border-radius: 8px;
    padding: 20px;
    background: #f5f5f5;
    text-align: center;
}

.gf-bacs-field-preview h4 {
    margin: 0 0 10px 0;
    color: #555;
}

.gf-bacs-field-preview p {
    margin: 0 0 15px 0;
    color: #777;
    font-size: 14px;
}

.gf-bacs-button-preview {
    margin-top: 15px;
}

.gf-bacs-button {
    background: #0073aa;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 4px;
    font-size: 16px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.gf-bacs-button:hover:not(:disabled) {
    background: #005a87;
}

.gf-bacs-button:disabled {
    background: #ccc;
    cursor: not-allowed;
}

/* Confirmation Messages */
.gf-bacs-success {
    background: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
    padding: 20px;
    border-radius: 4px;
    margin: 20px 0;
}

.gf-bacs-success h3 {
    margin: 0 0 15px 0;
    color: #155724;
}

.gf-bacs-cancelled {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    color: #856404;
    padding: 20px;
    border-radius: 4px;
    margin: 20px 0;
}

.gf-bacs-cancelled h3 {
    margin: 0 0 15px 0;
    color: #856404;
}

.gf-bacs-error {
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
    padding: 20px;
    border-radius: 4px;
    margin: 20px 0;
}

.gf-bacs-error h3 {
    margin: 0 0 15px 0;
    color: #721c24;
}

/* Entry Detail Styles */
.gf-bacs-entry-detail {
    background: #f9f9f9;
    padding: 15px;
    border-radius: 4px;
    border: 1px solid #ddd;
}

.gf-bacs-entry-detail strong {
    color: #2c3e50;
}

/* Responsive Styles */
@media (max-width: 768px) {
    .gf-bacs-field {
        padding: 15px;
    }
    
    .gf-bacs-field h4 {
        font-size: 16px;
    }
    
    .gf-bacs-button {
        width: 100%;
        padding: 15px;
    }
}

.gform_page_footer {
    flex-wrap: wrap;
}