#form-container {
    display: block;
}
#success-message {
    display: none;
    font-weight: bold;
}
#fail-message {
    display: none;
    font-weight: bold;
    margin-top: 15px;
}
#formio .formio-component-form .alert-success,
#formio > .alert-success,
#formio .formio-form > .alert-success {
    display: none !important;
}
#formio .formio-form .formio-submission-view {
    display: none !important;
}

/* Submission loading overlay */
#snhd-form-loading-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 99999;
    align-items: center;
    justify-content: center;
}
#snhd-form-loading-overlay.is-active {
    display: flex;
}
.snhd-form-loading-content {
    background: #ffffff;
    padding: 30px 50px;
    border-radius: 8px;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    min-width: 200px;
}
.snhd-form-loading-spinner {
    width: 48px;
    height: 48px;
    border: 5px solid #e0e0e0;
    border-top-color: #00417a;
    border-radius: 50%;
    margin: 0 auto 15px;
    animation: snhd-form-spin 0.8s linear infinite;
}
.snhd-form-loading-message {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
    color: #333;
}
@keyframes snhd-form-spin {
    to { transform: rotate(360deg); }
}

/* Read-mode Pending Status card */
#snhd-pending-status {
    display: none;
    max-width: 520px;
    margin: 40px auto;
    padding: 40px 32px;
    background: #ffffff;
    border: 1px solid #e5e5e5;
    border-top: 4px solid #6804cc;
    border-radius: 0; /* square corners per SNHD brand */
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
    text-align: center;
    font-family: 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
}
#snhd-pending-status .snhd-pending-icon {
    font-size: 56px;
    color: #6804cc;
    line-height: 1;
    margin-bottom: 16px;
    display: inline-block;
}
#snhd-pending-status .snhd-pending-label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #6c757d;
    margin-bottom: 8px;
}
#snhd-pending-status .snhd-pending-value {
    display: block;
    font-size: 28px;
    font-weight: 700;
    color: #6804cc;
    margin: 0 0 12px;
}
#snhd-pending-status .snhd-pending-message {
    margin: 0;
    font-size: 15px;
    color: #495057;
    line-height: 1.5;
}

/* Upload progress toast */
#snhd-upload-progress {
    display: none;
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 99999;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
    padding: 14px 16px;
    min-width: 260px;
    max-width: 340px;
    font-family: 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
}
#snhd-upload-progress.is-active {
    display: block;
}
.snhd-upload-label {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
    font-size: 13px;
    color: #333;
    font-weight: 500;
}
.snhd-upload-filename {
    flex: 1;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}
.snhd-upload-pct {
    flex: none;
    font-weight: 700;
    color: #00417a;
}
.snhd-upload-bar-track {
    background: #e0e0e0;
    border-radius: 4px;
    height: 6px;
    overflow: hidden;
}
.snhd-upload-bar-fill {
    height: 100%;
    background: #00417a;
    border-radius: 4px;
    width: 0%;
    transition: width 0.2s ease;
}
