:root {
    /* Primary colors */
    --bdo-primary-color: #174734;
    --bdo-primary-hover-opacity: 0.92;

    /* Text colors */
    --bdo-heading-color: #000000;
    --bdo-text-color: #1e293b;
    --bdo-text-inverse: #ffffff;
    --bdo-field-text: #1f2124;

    /* Border colors */
    --bdo-border-color: #69727d;
    --bdo-border-light: #e2e8f0;

    /* Status colors */
    --bdo-color-required: #b42318;
    --bdo-color-success: #18753c;
    --bdo-color-warning: #b7791f;
    --bdo-color-focus: #2563eb;

    /* Background colors */
    --bdo-background-color: #ffffff;
    --bdo-background-secondary: #e2e8f0;
    --bdo-background-warning: #fff8e5;

    /* Button */
    --bdo-button-bg-color: #69727d;
    --bdo-button-bg-color-hover: #000000;
}
.mb-1 {
    margin-bottom: 16px;
}
/* Onboarding container */
.bdo-onboarding {
    width: 100%;
    margin: 0 auto;
    padding: 30px;
    background-color: var(--bdo-background-color);
    box-shadow: 0px 0px 100px 9px rgba(0, 0, 0, 0.22);
    box-sizing: border-box;
}
.bdo-onboarding:has(.bdo-access-gate) {
    width: fit-content;
}
.bdo-form-wrapper {
    width: 100%;
}
.bdo-form-header {
    margin-bottom: 32px;
}
.bdo-form-header h2 {
    margin: 0 0 12px;
    font-size: 28px;
    line-height: 1.3;
}
.bdo-form-header p {
    margin: 0;
    line-height: 1.7;
}
.bdo-form-fields {
    display: flex;
    flex-direction: column;
    gap: 24px;
}
.bdo-field-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px;
}
.bdo-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-width: 0;
}
.bdo-field__label,
.bdo-field>label:not(.bdo-field__option) {
    font-weight: 600;
    line-height: 1.5;
}
.bdo-field__required {
    color: var(--bdo-color-required);
}
.bdo-field__input {
    width: 100%;
    background-color: var(--bdo-background-color) !important;
    border: 1px solid var(--bdo-border-color) !important;
    border-radius: 2px;
    min-height: 50px;
    color: var(--bdo-field-text);
}
.bdo-field--file .bdo-field__input {
    background: transparent;
    border: none !important;
    padding: 0;
    width: max-content;
    min-height: unset;
}
textarea.bdo-field__input {
    min-height: 120px;
    resize: vertical;
}
.bdo-field__options {
    display: flex;
    flex-direction: row;
    gap: 15px;
}
.bdo-field__option {
    display: flex;
    align-items: center;
    gap: 12px;
    line-height: 1.6;
    max-width: max-content;
    cursor: pointer;
}
.bdo-field__option input {
    flex: 0 0 auto;
    width: 20px;
    height: 20px;
    margin: 2px 0 0;
}
.bdo-field__option input[type="checkbox"] {
    min-height: unset;
    margin: 0;
    appearance: none;
    -webkit-appearance: none;
    width: 20px;
    height: 20px;
    border: 1px solid var(--bdo-button-bg-color-hover);
    border-radius: 3px;
    background-color: var(--bdo-background-color);
    cursor: pointer;
    display: inline-grid;
    place-content: center;
    vertical-align: middle;
}
.bdo-field__option input[type="checkbox"]:checked {
    background-color: var(--bdo-button-bg-color-hover) !important;
    border-color: var(--bdo-button-bg-color-hover) !important;
}
.bdo-field__option input[type="checkbox"]:checked::after {
    content: "✓";
    color: var(--bdo-background-color);
    font-size: 18px;
    font-weight: 600;
    line-height: 1;
}
.bdo-field--radio .bdo-field__options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr));
    gap: 12px;
}
.bdo-field--radio .bdo-field__option {
    align-items: center;
    box-sizing: border-box;
    max-width: none;
    min-height: 42px;
    padding: 8px 10px;
    border: 1px solid #d7dce2;
    color: #111827;
    cursor: pointer;
    line-height: 1.4;
}
.bdo-field--radio .bdo-field__option:has(input:checked) {
    border-color: #000000;
    background: #000000;
    color: #ffffff;
}
.bdo-field--radio .bdo-field__option input[type="radio"] {
    appearance: none;
    box-sizing: border-box;
    width: 20px;
    height: 20px;
    margin: 0;
    border: 1px solid #bdc5d0;
    border-radius: 50%;
    background: #ffffff;
    cursor: pointer;
}
.bdo-field--radio .bdo-field__option input[type="radio"]:checked {
    border-color: #ffffff;
    box-shadow: inset 0 0 0 4px #000000;
}
.bdo-field--radio .bdo-field__option input[type="radio"]:focus-visible {
    outline: 3px solid var(--bdo-color-focus);
    outline-offset: 3px;
}
.bdo-field__help {
    margin: 0;
    font-size: 14px;
    line-height: 1.6;
}
.bdo-field__error {
    color: #d63638;
    font-size: 14px;
    line-height: 1.4;
}
.bdo-field__error[hidden] {
    display: none;
}
.bdo-field__saved-file {
    margin: 0;
    overflow-wrap: anywhere;
}
.bdo-field [aria-invalid="true"] {
    border-color: #d63638 !important;
}
.bdo-declaration,
.bdo-step-declaration {
    display: flex;
    flex-direction: column;
    gap: 24px;
    margin-top: 32px;
    padding-top: 24px;
    border-top: 1px solid var(--bdo-border-light);
}
.bdo-form-actions {
    display: flex;
    gap: 12px;
    margin-top: 32px;
}
.bdo-button {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    min-height: 50px;
    padding: 16px 40px;
    border: 0;
    background: var(--bdo-button-bg-color);
    color: var(--bdo-text-inverse);
    font: inherit;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 2px;
    cursor: pointer;
    transition: background 0.2s ease-in-out;
}
.bdo-button:hover {
    background: var(--bdo-button-bg-color-hover);
    color: var(--bdo-background-color);
}
.bdo-thank-you a.bdo-button {
    text-decoration: none !important;
}
.bdo-submit-spinner {
    display: inline-block;
    width: 1em;
    height: 1em;
    margin-left: 10px;
    border: 2px solid currentColor;
    border-right-color: transparent;
    border-radius: 50%;
    animation: bdo-spin 0.7s linear infinite;
}
.bdo-submit-spinner[hidden] {
    display: none;
}
@keyframes bdo-spin {
    to {
        transform: rotate(360deg);
    }
}
@media (prefers-reduced-motion: reduce) {
    .bdo-submit-spinner {
        animation-duration: 1.5s;
    }
}
.bdo-field__input:focus-visible,
.bdo-button:focus-visible,
.bdo-field__option input:focus-visible {
    outline: 3px solid var(--bdo-color-focus);
    outline-offset: 3px;
}
/* Step progress */
.bdo-step-progress {
    display: flex;
    align-items: center;
    height: 20px;
    overflow: hidden;
    border-radius: 999px;
    background: #eeeeee;
    margin-bottom: 32px;
}
.bdo-step-progress__bar {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    border-radius: inherit;
    background: #000000;
    color: #ffffff;
    transition: width 0.3s ease;
}
.bdo-step-progress__label {
    font-size: 12px;
    line-height: 1;
    white-space: nowrap;
}
.bdo-step[hidden] {
    display: none !important;
}
.bdo-step__header {
    margin-bottom: 24px;
}
.bdo-step__counter {
    font-size: 14px;
    margin-bottom: 8px;
}
.bdo-form-status {
    margin-bottom: 16px !important;
    font-size: 14px;
}
.bdo-form-status.is-error {
    color: var(--bdo-color-required);
}
.bdo-thank-you {
    padding: 24px;
    text-align: center;
}
.bdo-thank-you h2 {
    margin: 0 0 12px;
}
.bdo-thank-you p {
    margin: 0;
}

/* Access gate */
.bdo-access-gate {
    width: 100%;
    max-width: 560px;
    margin: 0 auto;
    padding: 25px;
    background-color: var(--bdo-background-color);
    border: 1px solid var(--bdo-border-light);
    box-sizing: border-box;
}
.bdo-access-gate h2 {
    margin-top: 0;
    font-size: 24px;
    line-height: 1.3;
    text-align: center;
}
.bdo-access-gate .bdo-access-gate-disc {
    text-align: center;
}
.bdo-access-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}
.bdo-access-form [hidden] {
    display: none !important;
}
.bdo-access-status {
    /* min-height: 1.5em; */
    margin: 0;
}
/* Form content */
.bdo-form-content {
    line-height: 1.65;
}
.bdo-form-content a {
    text-decoration: underline !important;
}
.bdo-form-content .notice {
    padding: 15px;
}
.bdo-form p,
.bdo-form-content .notice p{
    margin: 0;
}
.bdo-form-content .notice.form-begin-note {
    background-color: #eff9f1;
    border-left: 2px solid #4ab866;
}
.bdo-form-content .notice.law-section-note {
    background-color: #fef8ee;
    border-left: 2px solid #f0b849;
}
.top-border {
    margin-top: 20px;
    padding-top: 25px;
    border-top: 1px solid var(--bdo-border-light);
}
.bdo-form [data-bdo-condition-field][hidden] {
    display: none !important;
}
.bdo-form-content h4 {
    margin: 0 0 12px;
}
.bdo-policy-card,
.bdo-clawback-policy-card {
    box-sizing: border-box;
    max-height: 240px;
    overflow-y: auto;
    overscroll-behavior: contain;
    padding: 16px;
    border: 1px solid var(--bdo-border-light);
    border-radius: 4px;
}
.bdo-policy-card.has-error,
.bdo-clawback-policy-card.has-error {
    border-color: #d63638;
}
.bdo-form-content .bdo-policy-card__error {
    margin: -10px 0 0;
    color: #d63638;
    font-size: 14px;
    line-height: 1.4;

}
.bdo-policy-card__error[hidden] {
    display: none;
}
.bdo-form-content .bdo-policy-scroll ol,
.bdo-form-content .bdo-policy-scroll ul{
    margin-left: 30px;
}
.bdo-clawback-policy-card {
    max-height: 200px;
}
.bdo-policy-card h4,
.bdo-clawback-policy-card h4 {
    margin-bottom: 12px;
}
.bdo-policy-card p,
.bdo-clawback-policy-card p {
    margin: 0 0 12px;
}
.bdo-policy-card a,
.bdo-clawback-policy-card a {
    text-decoration: underline !important;
}
.bdo-policy-card .bdo-field,
.bdo-clawback-policy-card .bdo-field {
    margin-top: 20px;
}
.bdo-policy-scroll-hint {
    margin: 0 0 8px;
    font-size: 14px;
}
.bdo-policy-scroll {
    padding-right: 6px;
}
.bdo-policy-scroll > p:first-child {
    margin-top: 0;
}
.bdo-policy-scroll > p:last-of-type {
    margin-bottom: 0;
}
.bdo-policy-card:focus-visible,
.bdo-clawback-policy-card:focus-visible {
    outline: 3px solid var(--bdo-color-focus);
    outline-offset: 3px;
}
.bdo-content-pending {
    padding: 12px;
    border-left: 4px solid var(--bdo-color-warning);
    background: var(--bdo-background-warning);
}
.bdo-document-embed {
    display: block;
    width: 100%;
    min-height: 65vh;
    border: 1px solid var(--bdo-border-color);
    border-radius: 6px;
}
.bdo-resource-card {
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 190px;
    box-sizing: border-box;
    padding: 20px;
    border: 1px solid var(--bdo-border-light);
    border-radius: 6px;
    background: var(--bdo-background-color);
}
.bdo-resource-card h4 {
    margin-bottom: 10px;
    color: var(--bdo-heading-color);
}
.bdo-resource-card p {
    margin: 0 0 16px;
}
.bdo-resource-card__link--pending {
    color: var(--bdo-text-color);
    font-weight: 600;
}
.bdo-resource-card > .bdo-field--checkbox {
    margin-top: auto;
    padding-top: 16px;
    border-top: 1px solid var(--bdo-border-light);
}
.bdo-resource-card > .bdo-field--checkbox .bdo-field__option {
    max-width: none;
    padding: 0;
    border: 0;
}
.bdo-resource-card > .bdo-field--checkbox .bdo-field__option input {
    margin-top: 2px;
}
.bdo-resource-card > .bdo-field--checkbox .bdo-field__error {
    margin-top: 8px;
}

/* admin side */
body.wp-admin .tablenav-pages .page-numbers {
    display: inline-flex;
    text-decoration: none;
    min-width: 25px;
    min-height: 25px;
    font-size: 14px;
    line-height: 1;
    border: 1px solid var(--wp-admin-theme-color);
    border-radius: 2px;
    color: var(--wp-admin-theme-color);
    justify-content: center;
    align-content: center;
    flex-direction: row;
    flex-wrap: wrap;
    padding: 4px;
}
body.wp-admin .tablenav-pages .page-numbers.current {
    color: #8a8a8a !important;
    border-color: #d8d8d8 !important;
    background: 0 0 !important;
    box-shadow: none !important;
}
/* end of the admin side  */

/* Responsive styles */
@media (max-width: 767px) {
    .bdo-onboarding {
        padding: 20px;
    }
    .bdo-field-grid {
        grid-template-columns: 1fr;
    }
    .bdo-access-gate {
        padding: 15px;
    }
}
@media (max-width: 480px) {
    .bdo-form-actions {
        flex-direction: column-reverse;
    }
    .bdo-form-header h2 {
        font-size: 24px;
    }
    .bdo-button {
        width: 100%;
    }
}