/* dueseweb-newprod DMS upload — patient document upload feature.
 *
 * Scoped under .dueseweb-modern so it inherits the palette tokens
 * from modernize.css. Loaded by wp/mu-plugins/dms-upload.php.
 *
 * Covers:
 *   .dw-dms-pill      — floating upload trigger (nav area)
 *   .dw-dms-card      — email-entry dropdown (desktop only)
 *   .dw-dms-backdrop  — click-outside overlay
 *   .dw-dms           — full DMS page wrapper
 *   .dw-dms-verify    — OTP / verification screen
 *   Upload screen:
 *     .dw-dms-type-btn  — document type selector pills
 *     .dw-dms-dropzone  — drag-and-drop area
 *     .dw-dms-file-row  — uploaded file rows + progress
 *     .dw-dms-submit    — final submit button
 *   .dw-dms-done      — confirmation / thank-you screen
 */

/* ===== 1. Upload pill (.dw-dms-pill) ==============================*/

.dw-dms-pill {
    position: fixed;
    top: 14px;
    left: 14px;
    z-index: 1004;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(3, 19, 33, 0.65);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 220, 184, 0.20);
    border-radius: 999px;
    color: var(--dw-ink, #ffdcb8);
    cursor: pointer;
    transition:
        background var(--dw-dur-fast, 150ms) var(--dw-ease, ease),
        border-color var(--dw-dur-fast, 150ms) var(--dw-ease, ease),
        transform var(--dw-dur-fast, 150ms) var(--dw-ease, ease);
    padding: 0;
    appearance: none;
    -webkit-appearance: none;
    text-decoration: none;
}

.dw-dms-pill:hover,
.dw-dms-pill:focus-visible {
    background: rgba(3, 19, 33, 0.88);
    border-color: rgba(255, 220, 184, 0.45);
    transform: translateY(-1px);
    outline: none;
}

.dw-dms-pill svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    pointer-events: none;
}

/* Hide pill when nav drawer is open */
body.dw-nav-open .dw-dms-pill {
    display: none !important;
}

/* Hide on non-home pages */
.dw-dms-pill[data-home="0"] {
    display: none !important;
}

/* Mobile: same position, slightly smaller */
@media (max-width: 767px) {
    .dw-dms-pill {
        width: 40px;
        height: 40px;
    }
    .dw-dms-pill svg {
        width: 18px;
        height: 18px;
    }
}


/* ===== 2. Email card (.dw-dms-card) ================================*/

.dw-dms-backdrop {
    position: fixed;
    inset: 0;
    z-index: 9991;
    background: transparent;
    /* Invisible overlay — captures clicks outside card */
}

.dw-dms-card {
    position: fixed;
    top: 86px;
    left: 14px;
    z-index: 9992;
    width: 300px;
    background: rgba(3, 19, 33, 0.92);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border: 1px solid rgba(255, 220, 184, 0.22);
    border-radius: 16px;
    padding: var(--dw-sp-5, 1.5rem);
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.45);
    color: var(--dw-ink, #ffdcb8);
    font-family: var(--dw-font-sans, system-ui, sans-serif);
}

.dw-dms-card-label {
    display: block;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--dw-muted, #a0b4c8);
    margin-bottom: var(--dw-sp-3, 0.75rem);
}

.dw-dms-card-input {
    width: 100%;
    padding: 0.625rem var(--dw-sp-4, 1rem);
    font-family: var(--dw-font-sans, system-ui, sans-serif);
    font-size: 0.9375rem;
    line-height: 1.4;
    color: var(--dw-ink, #ffdcb8);
    background: rgba(3, 19, 33, 0.60);
    border: 1px solid rgba(255, 220, 184, 0.28);
    border-radius: 12px;
    transition:
        border-color var(--dw-dur-fast, 150ms) var(--dw-ease, ease),
        box-shadow var(--dw-dur-fast, 150ms) var(--dw-ease, ease);
    outline: none;
    min-height: 48px;
    appearance: none;
    -webkit-appearance: none;
}

.dw-dms-card-input::placeholder {
    color: rgba(255, 220, 184, 0.40);
}

.dw-dms-card-input:focus {
    border-color: rgba(255, 220, 184, 0.60);
    box-shadow: 0 0 0 3px rgba(255, 220, 184, 0.15);
}

.dw-dms-card-submit {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    margin-top: var(--dw-sp-3, 0.75rem);
    padding: 0.625rem var(--dw-sp-4, 1rem);
    min-height: 48px;
    font-family: var(--dw-font-sans, system-ui, sans-serif);
    font-size: 0.9375rem;
    font-weight: 600;
    color: rgba(3, 19, 33, 0.95);
    background: var(--dw-ink, #ffdcb8);
    border: none;
    border-radius: 12px;
    cursor: pointer;
    transition:
        background var(--dw-dur-fast, 150ms) var(--dw-ease, ease),
        transform var(--dw-dur-fast, 150ms) var(--dw-ease, ease),
        box-shadow var(--dw-dur-fast, 150ms) var(--dw-ease, ease);
    appearance: none;
    -webkit-appearance: none;
}

.dw-dms-card-submit:hover,
.dw-dms-card-submit:focus-visible {
    background: var(--dw-navy-soft, #ffe9d3);
    transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(255, 220, 184, 0.30);
    outline: none;
}

.dw-dms-card-submit:focus-visible {
    box-shadow: 0 0 0 3px rgba(255, 220, 184, 0.45), 0 4px 14px rgba(255, 220, 184, 0.30);
}

.dw-dms-card-submit:active {
    transform: translateY(0);
    box-shadow: none;
}

.dw-dms-card-error {
    margin-top: var(--dw-sp-2, 0.5rem);
    font-size: 0.8125rem;
    color: #f87171; /* red-400 */
    line-height: 1.4;
    min-height: 1.2em; /* prevents layout shift */
}

/* Card is desktop-only — hidden on mobile entirely */
@media (max-width: 767px) {
    .dw-dms-card,
    .dw-dms-backdrop {
        display: none !important;
    }
}


/* ===== 3. DMS page wrapper (.dw-dms) ================================*/

.dw-dms {
    max-width: 520px;
    margin: 0 auto;
    padding: var(--dw-sp-6, 2rem) var(--dw-sp-5, 1.5rem) var(--dw-sp-8, 4rem);
    min-height: 60vh;
    color: var(--dw-ink, #ffdcb8);
    font-family: var(--dw-font-sans, system-ui, sans-serif);
}

.dw-dms h1,
.dw-dms h2,
.dw-dms h3 {
    font-family: var(--dw-font-serif, Georgia, serif);
    font-weight: 400;
    line-height: var(--dw-lh-tight, 1.2);
    color: var(--dw-ink, #ffdcb8);
    margin-top: 0;
}

.dw-dms h1 {
    font-size: clamp(1.75rem, 4vw, var(--dw-fs-2xl, 1.953rem));
}

.dw-dms h2 {
    font-size: var(--dw-fs-xl, 1.563rem);
    margin-bottom: var(--dw-sp-4, 1rem);
}

.dw-dms p {
    color: var(--dw-muted, #a0b4c8);
    line-height: var(--dw-lh-base, 1.65);
    margin-top: 0;
}

.dw-dms a {
    color: var(--dw-ink, #ffdcb8);
}

/* Utility: visually hidden (SR-only) */
.dw-dms .dw-sr-only {
    position: absolute !important;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}


/* ===== 4. Verification screen (.dw-dms-verify) =====================*/

.dw-dms-verify {
    text-align: center;
    padding-top: var(--dw-sp-7, 3rem);
}

.dw-dms-verify h1,
.dw-dms-verify h2 {
    margin-bottom: var(--dw-sp-3, 0.75rem);
}

.dw-dms-verify p {
    margin-bottom: var(--dw-sp-5, 1.5rem);
}

.dw-dms-verify-input {
    display: block;
    max-width: 280px;
    margin: 0 auto var(--dw-sp-4, 1rem);
    width: 100%;
    padding: 0.75rem var(--dw-sp-4, 1rem);
    font-family: var(--dw-font-sans, system-ui, sans-serif);
    font-size: var(--dw-fs-lg, 1.25rem);
    letter-spacing: 0.25em;
    text-align: center;
    color: var(--dw-ink, #ffdcb8);
    background: rgba(3, 19, 33, 0.72);
    border: 1px solid rgba(255, 220, 184, 0.30);
    border-radius: 12px;
    min-height: 56px;
    transition:
        border-color var(--dw-dur-fast, 150ms) var(--dw-ease, ease),
        box-shadow var(--dw-dur-fast, 150ms) var(--dw-ease, ease);
    outline: none;
    appearance: none;
    -webkit-appearance: none;
}

.dw-dms-verify-input::placeholder {
    letter-spacing: 0.1em;
    color: rgba(255, 220, 184, 0.35);
}

.dw-dms-verify-input:focus {
    border-color: rgba(255, 220, 184, 0.60);
    box-shadow: 0 0 0 3px rgba(255, 220, 184, 0.15);
}

.dw-dms-verify-submit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem var(--dw-sp-6, 2rem);
    min-height: 52px;
    min-width: 180px;
    font-family: var(--dw-font-sans, system-ui, sans-serif);
    font-size: 1rem;
    font-weight: 600;
    color: rgba(3, 19, 33, 0.95);
    background: var(--dw-ink, #ffdcb8);
    border: none;
    border-radius: 12px;
    cursor: pointer;
    transition:
        background var(--dw-dur-fast, 150ms) var(--dw-ease, ease),
        transform var(--dw-dur-fast, 150ms) var(--dw-ease, ease),
        box-shadow var(--dw-dur-fast, 150ms) var(--dw-ease, ease);
    appearance: none;
    -webkit-appearance: none;
}

.dw-dms-verify-submit:hover,
.dw-dms-verify-submit:focus-visible {
    background: var(--dw-navy-soft, #ffe9d3);
    transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(255, 220, 184, 0.30);
    outline: none;
}

.dw-dms-verify-submit:focus-visible {
    box-shadow: 0 0 0 3px rgba(255, 220, 184, 0.45), 0 4px 14px rgba(255, 220, 184, 0.30);
}

.dw-dms-verify-submit:active {
    transform: translateY(0);
    box-shadow: none;
}

.dw-dms-verify-error {
    margin-top: var(--dw-sp-3, 0.75rem);
    font-size: 0.875rem;
    color: #f87171;
    text-align: center;
    line-height: 1.4;
    min-height: 1.2em;
}

.dw-dms-verify-resend {
    display: inline-block;
    margin-top: var(--dw-sp-4, 1rem);
    font-size: 0.875rem;
    color: var(--dw-muted, #a0b4c8);
    background: none;
    border: none;
    cursor: pointer;
    text-decoration: underline;
    text-underline-offset: 0.2em;
    padding: var(--dw-sp-2, 0.5rem) 0;
    min-height: 48px;
    font-family: inherit;
    transition: color var(--dw-dur-fast, 150ms) var(--dw-ease, ease);
}

.dw-dms-verify-resend:hover,
.dw-dms-verify-resend:focus-visible {
    color: var(--dw-ink, #ffdcb8);
    outline: none;
}


/* ===== 5. Upload screen — document type pills ======================*/

.dw-dms-type-label {
    display: block;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--dw-muted, #a0b4c8);
    margin-bottom: var(--dw-sp-3, 0.75rem);
}

.dw-dms-type-grid {
    display: flex;
    flex-wrap: wrap;
    gap: var(--dw-sp-2, 0.5rem);
    margin-bottom: var(--dw-sp-5, 1.5rem);
}

.dw-dms-type-btn {
    flex: 0 0 calc(50% - var(--dw-sp-2, 0.5rem) / 2);
    min-width: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 0.625rem var(--dw-sp-3, 0.75rem);
    min-height: 48px;
    font-family: var(--dw-font-sans, system-ui, sans-serif);
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--dw-ink, #ffdcb8);
    background: rgba(3, 19, 33, 0.55);
    border: 1px solid rgba(255, 220, 184, 0.20);
    border-radius: 999px;
    cursor: pointer;
    transition:
        background var(--dw-dur-fast, 150ms) var(--dw-ease, ease),
        border-color var(--dw-dur-fast, 150ms) var(--dw-ease, ease),
        color var(--dw-dur-fast, 150ms) var(--dw-ease, ease);
    appearance: none;
    -webkit-appearance: none;
    line-height: 1.3;
}

.dw-dms-type-btn:hover,
.dw-dms-type-btn:focus-visible {
    background: rgba(3, 19, 33, 0.80);
    border-color: rgba(255, 220, 184, 0.45);
    outline: none;
}

.dw-dms-type-btn:focus-visible {
    box-shadow: 0 0 0 3px rgba(255, 220, 184, 0.25);
}

/* Active / selected state */
.dw-dms-type-btn.is-active,
.dw-dms-type-btn[aria-pressed="true"] {
    background: rgba(255, 220, 184, 0.15);
    border-color: rgba(255, 220, 184, 0.65);
    color: var(--dw-navy-soft, #ffe9d3);
}

/* Full-width stacked on narrow mobile */
@media (max-width: 400px) {
    .dw-dms-type-btn {
        flex: 0 0 100%;
    }
}


/* ===== 6. Upload screen — drop zone ================================*/

.dw-dms-dropzone {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: var(--dw-sp-3, 0.75rem);
    min-height: 200px;
    padding: var(--dw-sp-6, 2rem) var(--dw-sp-5, 1.5rem);
    background: rgba(3, 19, 33, 0.45);
    border: 2px dashed rgba(255, 220, 184, 0.28);
    border-radius: 16px;
    color: var(--dw-muted, #a0b4c8);
    text-align: center;
    cursor: pointer;
    transition:
        background var(--dw-dur-fast, 150ms) var(--dw-ease, ease),
        border-color var(--dw-dur-fast, 150ms) var(--dw-ease, ease);
    margin-bottom: var(--dw-sp-5, 1.5rem);
}

/* Hidden file input overlaid on the entire drop zone */
.dw-dms-dropzone input[type="file"] {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
    z-index: 1;
}

.dw-dms-dropzone-icon {
    width: 40px;
    height: 40px;
    color: rgba(255, 220, 184, 0.45);
    flex-shrink: 0;
    pointer-events: none;
}

.dw-dms-dropzone-text {
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--dw-muted, #a0b4c8);
    pointer-events: none;
}

.dw-dms-dropzone-hint {
    font-size: 0.8125rem;
    color: rgba(160, 180, 200, 0.65);
    pointer-events: none;
}

/* Hover / drag-over state */
.dw-dms-dropzone:hover,
.dw-dms-dropzone.is-dragover {
    background: rgba(255, 220, 184, 0.07);
    border-color: rgba(255, 220, 184, 0.55);
}

.dw-dms-dropzone:hover .dw-dms-dropzone-icon,
.dw-dms-dropzone.is-dragover .dw-dms-dropzone-icon {
    color: rgba(255, 220, 184, 0.75);
}

.dw-dms-dropzone:hover .dw-dms-dropzone-text,
.dw-dms-dropzone.is-dragover .dw-dms-dropzone-text {
    color: var(--dw-ink, #ffdcb8);
}

/* Mobile */
@media (max-width: 767px) {
    .dw-dms-dropzone {
        min-height: 160px;
        padding: var(--dw-sp-5, 1.5rem) var(--dw-sp-4, 1rem);
    }
}


/* ===== 7. Upload screen — file list ================================*/

.dw-dms-file-list {
    display: flex;
    flex-direction: column;
    gap: var(--dw-sp-2, 0.5rem);
    margin-bottom: var(--dw-sp-5, 1.5rem);
    list-style: none;
    padding: 0;
    margin-top: 0;
}

.dw-dms-file-row {
    display: flex;
    align-items: center;
    gap: var(--dw-sp-3, 0.75rem);
    padding: 0.625rem var(--dw-sp-4, 1rem);
    background: rgba(3, 19, 33, 0.55);
    border: 1px solid rgba(255, 220, 184, 0.15);
    border-radius: 8px;
    min-height: 48px;
    font-size: 0.875rem;
    color: var(--dw-ink, #ffdcb8);
    position: relative;
    overflow: hidden;
    transition: border-color var(--dw-dur-fast, 150ms) var(--dw-ease, ease);
}

.dw-dms-file-name {
    flex: 1 1 auto;
    min-width: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-weight: 500;
}

.dw-dms-file-size {
    flex-shrink: 0;
    font-size: 0.8125rem;
    color: var(--dw-muted, #a0b4c8);
    white-space: nowrap;
}

.dw-dms-file-remove {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    padding: 0;
    background: none;
    border: none;
    border-radius: 6px;
    color: rgba(255, 220, 184, 0.50);
    cursor: pointer;
    transition: color var(--dw-dur-fast, 150ms) var(--dw-ease, ease),
                background var(--dw-dur-fast, 150ms) var(--dw-ease, ease);
    font-family: inherit;
    line-height: 1;
    /* Enlarge tap target without growing layout */
    position: relative;
}

.dw-dms-file-remove::before {
    content: '';
    position: absolute;
    inset: -10px;
}

.dw-dms-file-remove:hover,
.dw-dms-file-remove:focus-visible {
    color: #f87171;
    background: rgba(248, 113, 113, 0.12);
    outline: none;
}

.dw-dms-file-remove:focus-visible {
    box-shadow: 0 0 0 2px rgba(248, 113, 113, 0.40);
}

.dw-dms-file-remove svg {
    width: 16px;
    height: 16px;
    pointer-events: none;
}

/* Progress bar variant */
.dw-dms-file-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: rgba(255, 220, 184, 0.15);
    overflow: hidden;
}

.dw-dms-file-progress-bar {
    height: 100%;
    background: var(--dw-ink, #ffdcb8);
    width: 0%;
    transition: width 0.3s ease;
    border-radius: 0 2px 2px 0;
}

/* Done state */
.dw-dms-file-row.is-done {
    border-color: rgba(52, 211, 153, 0.40);
}

.dw-dms-file-row.is-done .dw-dms-file-progress-bar {
    background: #34d399; /* emerald-400 */
    width: 100%;
}

/* Error state */
.dw-dms-file-row.is-error {
    border-color: rgba(248, 113, 113, 0.45);
}

.dw-dms-file-row.is-error .dw-dms-file-progress-bar {
    background: #f87171; /* red-400 */
    width: 100%;
}

.dw-dms-file-status {
    flex-shrink: 0;
    font-size: 0.8125rem;
    font-weight: 600;
    white-space: nowrap;
}

.dw-dms-file-row.is-done .dw-dms-file-status {
    color: #34d399;
}

.dw-dms-file-row.is-error .dw-dms-file-status {
    color: #f87171;
}


/* ===== 8. Upload screen — submit button (.dw-dms-submit) ===========*/

.dw-dms-submit {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 0.875rem var(--dw-sp-5, 1.5rem);
    min-height: 52px;
    font-family: var(--dw-font-sans, system-ui, sans-serif);
    font-size: 1.0625rem;
    font-weight: 600;
    color: rgba(3, 19, 33, 0.95);
    background: var(--dw-ink, #ffdcb8);
    border: none;
    border-radius: 12px;
    cursor: pointer;
    transition:
        background var(--dw-dur-fast, 150ms) var(--dw-ease, ease),
        transform var(--dw-dur-fast, 150ms) var(--dw-ease, ease),
        box-shadow var(--dw-dur-fast, 150ms) var(--dw-ease, ease);
    appearance: none;
    -webkit-appearance: none;
    margin-top: var(--dw-sp-3, 0.75rem);
}

.dw-dms-submit:hover,
.dw-dms-submit:focus-visible {
    background: var(--dw-navy-soft, #ffe9d3);
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(255, 220, 184, 0.30);
    outline: none;
}

.dw-dms-submit:focus-visible {
    box-shadow: 0 0 0 3px rgba(255, 220, 184, 0.45), 0 6px 20px rgba(255, 220, 184, 0.30);
}

.dw-dms-submit:active {
    transform: translateY(0);
    box-shadow: none;
}

.dw-dms-submit:disabled,
.dw-dms-submit[disabled] {
    opacity: 0.45;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}


/* ===== 9. Confirmation screen (.dw-dms-done) =======================*/

.dw-dms-done {
    text-align: center;
    padding-top: var(--dw-sp-7, 3rem);
}

.dw-dms-done-icon {
    font-size: 4rem;
    line-height: 1;
    color: #34d399; /* emerald-400 — green checkmark */
    margin-bottom: var(--dw-sp-4, 1rem);
    display: block;
}

/* SVG variant of the checkmark icon */
.dw-dms-done-icon svg {
    width: 4rem;
    height: 4rem;
    color: #34d399;
    display: inline-block;
}

.dw-dms-done h1,
.dw-dms-done h2 {
    margin-bottom: var(--dw-sp-3, 0.75rem);
}

.dw-dms-done p {
    max-width: 40ch;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: var(--dw-sp-5, 1.5rem);
}

/* File list inside confirmation — read-only / simplified */
.dw-dms-done .dw-dms-file-list {
    text-align: left;
    max-width: 400px;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: var(--dw-sp-6, 2rem);
}

.dw-dms-done .dw-dms-file-row {
    border-color: rgba(52, 211, 153, 0.30);
}

/* "Upload more" button */
.dw-dms-upload-more {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--dw-sp-2, 0.5rem);
    padding: 0.625rem var(--dw-sp-5, 1.5rem);
    min-height: 48px;
    font-family: var(--dw-font-sans, system-ui, sans-serif);
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--dw-ink, #ffdcb8);
    background: rgba(255, 220, 184, 0.10);
    border: 1px solid rgba(255, 220, 184, 0.30);
    border-radius: 12px;
    cursor: pointer;
    text-decoration: none;
    transition:
        background var(--dw-dur-fast, 150ms) var(--dw-ease, ease),
        border-color var(--dw-dur-fast, 150ms) var(--dw-ease, ease),
        transform var(--dw-dur-fast, 150ms) var(--dw-ease, ease);
    appearance: none;
    -webkit-appearance: none;
}

.dw-dms-upload-more:hover,
.dw-dms-upload-more:focus-visible {
    background: rgba(255, 220, 184, 0.18);
    border-color: rgba(255, 220, 184, 0.55);
    transform: translateY(-1px);
    outline: none;
    color: var(--dw-ink, #ffdcb8);
}

.dw-dms-upload-more:focus-visible {
    box-shadow: 0 0 0 3px rgba(255, 220, 184, 0.25);
}


/* ===== 10. Shared error / info messages ============================*/

.dw-dms-error {
    display: flex;
    align-items: flex-start;
    gap: var(--dw-sp-3, 0.75rem);
    padding: var(--dw-sp-4, 1rem);
    background: rgba(248, 113, 113, 0.10);
    border: 1px solid rgba(248, 113, 113, 0.35);
    border-radius: 12px;
    color: #fca5a5; /* red-300 */
    font-size: 0.9375rem;
    line-height: 1.5;
    margin-bottom: var(--dw-sp-4, 1rem);
}

.dw-dms-info {
    display: flex;
    align-items: flex-start;
    gap: var(--dw-sp-3, 0.75rem);
    padding: var(--dw-sp-4, 1rem);
    background: rgba(255, 220, 184, 0.07);
    border: 1px solid rgba(255, 220, 184, 0.20);
    border-radius: 12px;
    color: var(--dw-muted, #a0b4c8);
    font-size: 0.875rem;
    line-height: 1.5;
    margin-bottom: var(--dw-sp-4, 1rem);
}


/* ===== 11. Loading / spinner state =================================*/

@keyframes dw-dms-spin {
    to { transform: rotate(360deg); }
}

.dw-dms-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid rgba(3, 19, 33, 0.30);
    border-top-color: rgba(3, 19, 33, 0.90);
    border-radius: 50%;
    animation: dw-dms-spin 0.7s linear infinite;
    flex-shrink: 0;
}

/* On light-bg buttons the spinner uses the button's text color */
.dw-dms-submit .dw-dms-spinner,
.dw-dms-verify-submit .dw-dms-spinner,
.dw-dms-card-submit .dw-dms-spinner {
    border-color: rgba(3, 19, 33, 0.25);
    border-top-color: rgba(3, 19, 33, 0.85);
}

/* Dark-bg spinner (inside dropzone / page body) */
.dw-dms-dropzone .dw-dms-spinner,
.dw-dms .dw-dms-spinner {
    border-color: rgba(255, 220, 184, 0.20);
    border-top-color: var(--dw-ink, #ffdcb8);
}
