/* Dëmi im — vetëm stilet specifike të formularit; pjesa tjetër trashëgohet nga tema akshi-dpt */
.demi-im { --demi-accent: #1d4f91; --demi-line: #d5dbe3; --demi-muted: #5b6573; --demi-err: #b32d2e; --demi-ok: #1e7a3c; }
.demi-im *, .demi-im *::before, .demi-im *::after { box-sizing: border-box; }
.demi-im-title { font-size: 1.25rem; font-weight: 700; margin: 0 0 .35rem; }
.demi-im-intro { margin: 0 0 1.25rem; color: var(--demi-muted); }
.demi-im-field--full { grid-column: 1 / -1; }
.demi-im-upload + .demi-im-upload { margin-top: 1.25rem; padding-top: 1.25rem; border-top: 1px solid var(--demi-line); }
.demi-im-upload-title { font-weight: 600; margin: 0 0 .5rem; }
.demi-im-doclist { list-style: none; margin: .75rem 0 .5rem; padding: 0; display: flex; flex-direction: column; gap: .5rem; }
.demi-im-doclist li { position: relative; display: flex; align-items: center; gap: .6rem; padding: .55rem 2.75rem .55rem .75rem; border: 1px solid var(--demi-line); border-radius: 6px; background: #f6f7f9; }
.demi-im-doclist .dashicons { color: var(--demi-accent); flex: 0 0 auto; }
.demi-im-docname { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.demi-im-doclist .demi-im-meta { padding: 0; flex: 0 0 auto; }
.demi-im-doclist .demi-im-remove { top: 50%; transform: translateY(-50%); }
.demi-im-req { color: var(--demi-err); }

.demi-im-fieldset { border: 1px solid var(--demi-line); border-radius: 8px; padding: 1.25rem 1.25rem .5rem; margin: 0 0 1.25rem; min-width: 0; }
.demi-im-fieldset legend { font-weight: 600; padding: 0 .5rem; }

.demi-im-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 0 1.25rem; }
.demi-im-field { margin-bottom: .9rem; }
.demi-im-field[hidden] { display: none; }
.demi-im-field label { display: block; font-weight: 600; margin-bottom: .35rem; }
.demi-im-field input[type="text"],
.demi-im-field input[type="email"],
.demi-im-field input[type="tel"],
.demi-im-field select { width: 100%; min-height: 44px; padding: .55rem .75rem; border: 1px solid var(--demi-line); border-radius: 6px; font: inherit; background: #fff; color: inherit; }
.demi-im-field input:focus, .demi-im-field select:focus, .demi-im-drop:focus-visible { outline: 2px solid var(--demi-accent); outline-offset: 1px; border-color: var(--demi-accent); }
.demi-im-field [aria-invalid="true"] { border-color: var(--demi-err); }
.demi-im-help { display: block; font-size: .85em; color: var(--demi-muted); margin: .3rem 0 0; }
.demi-im-error { color: var(--demi-err); font-size: .875em; margin: .3rem 0 0; min-height: 0; }
.demi-im-error:empty { display: none; }

.demi-im-drop { display: flex; flex-direction: column; align-items: center; gap: .35rem; text-align: center; padding: 1.75rem 1rem; border: 2px dashed var(--demi-line); border-radius: 8px; cursor: pointer; transition: border-color .15s, background-color .15s; }
.demi-im-drop:hover, .demi-im-drop.is-over { border-color: var(--demi-accent); background: rgba(29, 79, 145, .04); }
.demi-im-drop.is-full { opacity: .55; cursor: not-allowed; }
.demi-im-drop .dashicons { font-size: 36px; width: 36px; height: 36px; color: var(--demi-accent); }
.demi-im-count { font-size: .875em; color: var(--demi-muted); margin: .6rem 0 0; }
.demi-im-count:empty { display: none; }

.demi-im-previews { list-style: none; margin: .75rem 0 .5rem; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: .75rem; }
.demi-im-previews li { position: relative; border: 1px solid var(--demi-line); border-radius: 6px; overflow: hidden; background: #f6f7f9; }
.demi-im-previews img { display: block; width: 100%; aspect-ratio: 1 / 1; object-fit: cover; }
.demi-im-meta { display: block; font-size: .75em; color: var(--demi-muted); padding: .25rem .4rem; }
.demi-im-remove { position: absolute; top: 4px; right: 4px; width: 28px; height: 28px; border: 0; border-radius: 50%; background: rgba(0, 0, 0, .65); color: #fff; font-size: 18px; line-height: 28px; cursor: pointer; padding: 0; }
.demi-im-remove:hover, .demi-im-remove:focus { background: var(--demi-err); }

.demi-im-consent label { font-weight: 400; display: flex; gap: .6rem; align-items: flex-start; line-height: 1.45; }
.demi-im-consent input { margin-top: .25rem; width: 18px; height: 18px; flex: 0 0 auto; }

.demi-im-hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.demi-im-alert { padding: .8rem 1rem; border-radius: 6px; margin: 0 0 1rem; border-left: 4px solid; }
.demi-im-alert--err { background: #fcf0f1; border-color: var(--demi-err); color: #8a2424; }
.demi-im-alert--ok { background: #edfaef; border-color: var(--demi-ok); }

.demi-im-progress { height: 6px; background: #e6e9ee; border-radius: 3px; overflow: hidden; margin: 0 0 1rem; }
.demi-im-progress span { display: block; height: 100%; width: 0; background: var(--demi-accent); transition: width .2s; }
.demi-im-actions { display: flex; justify-content: flex-end; }
.demi-im-submit { min-height: 44px; padding: .6rem 1.4rem; cursor: pointer; }
.demi-im-submit[disabled] { opacity: .6; cursor: wait; }

.demi-im-success { text-align: center; padding: 2rem 1rem; }
.demi-im-success .dashicons { font-size: 56px; width: 56px; height: 56px; color: var(--demi-ok); }
.demi-im-code { font-size: 1.6rem; font-weight: 700; letter-spacing: .05em; color: var(--demi-accent); margin: .25rem 0 1rem; user-select: all; }

@media (max-width: 600px) {
	.demi-im-fieldset { padding: 1rem .85rem .25rem; }
	.demi-im-actions .view-btn { width: 100%; }
}

/* Kamera (vetëm në pajisje me ekran prekës) dhe pllakat në përgatitje */
.demi-im-camera { display: none; margin-top: .75rem; width: 100%; justify-content: center; align-items: center; gap: .4rem; min-height: 44px; cursor: pointer; }
@media (pointer: coarse) { .demi-im-camera { display: flex; } }
.demi-im-previews li.is-pending { display: flex; flex-direction: column; align-items: center; justify-content: center; aspect-ratio: 1 / 1; gap: .5rem; }
.demi-im-previews li.is-pending .demi-im-meta { text-align: center; }
.demi-im-spinner { width: 28px; height: 28px; border: 3px solid var(--demi-line); border-top-color: var(--demi-accent); border-radius: 50%; animation: demi-spin .8s linear infinite; }
@keyframes demi-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .demi-im-spinner { animation-duration: 2.4s; } }
