/**
 * CNPA Checkbox & Radio Styles
 *
 * Custom styled checkboxes for the registration form.
 */

/* ========================================
   Checkboxes
   ======================================== */

.checkbox-wrapper {
    display: flex;
    align-items: flex-start;
    gap: var(--space-3);
    cursor: pointer;
    padding: var(--space-3);
    border-radius: var(--radius-md);
    transition: background-color var(--transition-fast);
}

.checkbox-wrapper:hover {
    background-color: var(--gray-50);
}

.checkbox-wrapper input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.checkbox-custom {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    background-color: var(--bg-surface);
    border: 2px solid var(--gray-300);
    border-radius: var(--radius-sm);
    transition: all var(--transition-fast);
    display: flex;
    align-items: center;
    justify-content: center;
}

.checkbox-custom::after {
    content: "";
    width: 12px;
    height: 12px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='white' stroke-width='3'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M5 13l4 4L19 7'%3E%3C/path%3E%3C/svg%3E");
    background-size: contain;
    opacity: 0;
    transform: scale(0);
    transition: all var(--transition-fast);
}

.checkbox-wrapper input:checked+.checkbox-custom {
    background-color: var(--primary);
    border-color: var(--primary);
}

.checkbox-wrapper input:checked+.checkbox-custom::after {
    opacity: 1;
    transform: scale(1);
}

.checkbox-wrapper input:focus+.checkbox-custom {
    box-shadow: 0 0 0 3px rgba(var(--primary-rgb), 0.2);
}

.checkbox-label {
    font-size: var(--text-sm);
    color: var(--text-primary);
    line-height: var(--leading-normal);
}
