/* Compact add-user rows. Deliberately denser than the full user maintenance form — this is a list
   you scan and fill in, not a page you sit on. */

.uqc-toolbar {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 6px;
}

.uqc-summary {
    font-size: 12px;
    color: #6b7280;
    font-style: italic;
}

.uqc-add-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 6px 14px;
    border: 1px solid #cbd5e0;
    border-radius: 8px;
    background: #fff;
    color: #4a5568;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.uqc-add-btn:hover:not(:disabled) {
    background: #f0faf9;
    border-color: #008080;
    color: #008080;
}

.uqc-add-btn:disabled {
    opacity: 0.5;
    cursor: default;
}

/* Applies to every account this control creates, so it lives on the toolbar rather than the rows.
   Pushed to the right end, away from "Add user". */
.uqc-force-password {
    display: flex;
    align-items: center;
    gap: 9px;
    margin-left: auto;
    font-size: 12px;
    font-weight: 500;
    color: #4a5568;
}

/* Smaller than the app-wide 50x26 switch — the toolbar is a compact strip. */
.uqc-force-password .toggle-checkbox {
    width: 38px;
    height: 20px;
    flex: 0 0 auto;
}

.uqc-force-password .toggle-checkbox-slider:before {
    width: 14px;
    height: 14px;
    left: 3px;
    bottom: 3px;
}

.uqc-force-password .toggle-checkbox input:checked + .toggle-checkbox-slider:before {
    transform: translateX(18px);
}

.uqc-disabled .uqc-force-password {
    opacity: 0.5;
}

.uqc-row {
    display: flex;
    align-items: flex-end;
    gap: 10px;
    flex-wrap: wrap;
    padding: 8px 10px;
    margin-bottom: 6px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    background: #fbfdfd;
}

.uqc-cell {
    display: flex;
    flex-direction: column;
    gap: 3px;
    flex: 1 1 130px;
    min-width: 0;
    margin: 0;
}

.uqc-cell-wide {
    flex: 1 1 180px;
}

.uqc-cell-role {
    flex: 0 1 150px;
}

.uqc-cell > span {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    font-weight: 600;
    color: #6b7280;
}

/* Scoped tightly: the organisation page's stylesheet styles bare `input` with a 10px margin that
   would break the row's alignment. */
.uqc-row input,
.uqc-row select {
    width: 100%;
    margin: 0;
    padding: 7px 9px;
    border: 1px solid #cbd5e0;
    border-radius: 6px;
    font-size: 13px;
    background: #fff;
    color: #2d3748;
    box-sizing: border-box;
}

.uqc-row input:focus,
.uqc-row select:focus {
    outline: none;
    border-color: #008080;
    box-shadow: 0 0 0 3px rgba(0, 128, 128, 0.12);
}

/* Compulsory-field marker. Same red as .required-field on the user maintenance page, so a field
   that is mandatory there reads as mandatory here. */
.uqc-required {
    color: #c55;
    font-style: normal;
    font-weight: 700;
}

/* Super Admin selected: the role reaches across every organisation, so say so on the row itself
   rather than leaving it to the confirmation at save time. */
.uqc-row-elevated {
    border-color: #f6c96b;
    background: #fffdf5;
}

.uqc-row-elevated select.uqc-role {
    border-color: #e0a52a;
    background: #fffaf0;
}

.uqc-row-warning {
    flex: 1 1 100%;
    display: flex;
    align-items: center;
    gap: 6px;
    margin: 4px 0 0;
    font-size: 11.5px;
    font-weight: 600;
    color: #8a5a06;
}

/* "taken" / "already in use", shown beside the field label as you type. */
.uqc-field-error {
    color: #c53030;
    font-style: normal;
    font-weight: 500;
    text-transform: lowercase;
}

.uqc-row input.uqc-input-error {
    border-color: #fc8181;
    background: #fffafa;
}

.uqc-generate {
    padding: 0;
    border: 0;
    background: none;
    color: #008080;
    cursor: pointer;
    font-size: 11px;
    line-height: 1;
}

.uqc-generate:hover:not(:disabled) {
    color: #00565a;
}

.uqc-remove {
    flex: 0 0 auto;
    width: 30px;
    height: 32px;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    background: #fff;
    color: #a0aec0;
    cursor: pointer;
    transition: color 0.15s ease, border-color 0.15s ease, background-color 0.15s ease;
}

.uqc-remove:hover:not(:disabled) {
    color: #c53030;
    border-color: #feb2b2;
    background: #fff5f5;
}

.uqc-empty {
    margin: 0;
    font-size: 12px;
    color: #a0aec0;
    font-style: italic;
}

.uqc-disabled {
    opacity: 0.6;
}
