.avatar {
    max-width: 80px;
    max-height: 80px;
}

.switch {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: relative;
    vertical-align: middle;
    cursor: pointer;
    line-height: 0;
}

.switch input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    inset: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
    z-index: 1;
}

.switch-slider {
    display: block;
    width: 44px;
    height: 24px;
    background: #e5e7eb;
    border: 1px solid #d1d5db;
    border-radius: 999px;
    position: relative;
    transition: background-color 150ms ease, border-color 150ms ease;
    box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.02);
}

.switch-slider::after {
    content: "";
    position: absolute;
    top: 2px;
    left: 2px;
    width: 20px;
    height: 20px;
    background: #fff;
    border-radius: 999px;
    transition: transform 150ms ease;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.18);
}

.switch input[type="checkbox"]:checked + .switch-slider {
    background: var(--clr-primary, #4f46e5);
    border-color: var(--clr-primary, #4f46e5);
}

.switch input[type="checkbox"]:checked + .switch-slider::after {
    transform: translateX(20px);
}

.switch input[type="checkbox"]:focus-visible + .switch-slider {
    outline: 2px solid rgba(79, 70, 229, 0.35);
    outline-offset: 2px;
}

.switch input[type="checkbox"]:disabled + .switch-slider {
    opacity: 0.55;
    cursor: not-allowed;
}

.switch.switch--sm .switch-slider {
    width: 36px;
    height: 20px;
}

.switch.switch--sm .switch-slider::after {
    width: 16px;
    height: 16px;
}

.switch.switch--sm input[type="checkbox"]:checked + .switch-slider::after {
    transform: translateX(16px);
}

.signature-pad {
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 12px;
    background: #fff;
}

.signature-canvas {
    width: 100%;
    height: 160px;
    background: #fff;
    border: 1px dashed #d1d5db;
    border-radius: 10px;
    display: block;
    touch-action: none;
}

.signature-pad[data-disabled="1"] .signature-canvas {
    background: #f9fafb;
}

/* Searchable dropdowns (Choices.js) */
.choices {
    margin-bottom: 0;
}
.choices__inner {
    min-height: 40px;
    border-radius: 0.375rem;
    border-color: #d1d5db;
    background-color: #fff;
    padding: 6px 10px;
}
.choices__list--dropdown {
    border-color: #e5e7eb;
}
.choices__list--dropdown .choices__item--selectable.is-highlighted {
    background-color: #eef2ff;
}
.choices__input {
    background: transparent;
}
.choices[data-type*="select-one"]::after {
    border-color: #6b7280 transparent transparent transparent;
}
